diff --git a/README.md b/README.md index d4773b09a6..ed2ec988af 100644 --- a/README.md +++ b/README.md @@ -74,9 +74,13 @@ Once you have installed Ruby, clone this repository to your machine. Once done, **Serving the site after the first install** -All you need to run in consequent builds of the site is `bundle exec jekyll serve`. You can add the suffix `--incremental` to enable incremental building of the site. This saves build times since the regeneration feature is enabled by default (the site rebuilds every time you hit "save"). When `--incremental` is used, Jekyll won't rebuild the entire site on every save, only the affected sections. If you'd like the project to automatically open in a new tab, you can add the `-o` flag to the end of the above command. +You have two options to run the site after the first install: -**Note**: changes that alter site navigation or other changes that change the site as a whole might not show up when using `--incremental`. If that occurs, simply "kill" the build and run `bundle exec jekyll serve` without the suffix. +* **Using gulp.js**. [Gulp](https://gulpjs.com/) is a toolkit for automating painful or time-consuming tasks. By simply typing in `gulp` in your command line, it takes care of all the build commands needed to serve the site. It also watches the root directory and will automatically refresh your browser once any changes were built. Gulp and its dependencies is installed locally in the project, so there's no further installation needed from your end. + +* **Using Jekyll's standard commands**. All you need to run in consequent builds of the site is `bundle exec jekyll serve`. You can add the suffix `--incremental` to enable incremental building of the site. This saves build times since the regeneration feature is enabled by default (the site rebuilds every time you hit "save"). When `--incremental` is used, Jekyll won't rebuild the entire site on every save, only the affected sections. If you'd like the project to automatically open in a new tab, you can add the `-o` flag to the end of the above command. + +**Note**: changes that alter site navigation or other changes that change the site as a whole might not show up when using `--incremental`. If that occurs, simply "kill" the build and run `bundle exec jekyll serve` without the suffix. **This is also true for gulp: you will need to kill your gulp instance and then run the direct Jekyll command**. ### Template diff --git a/gulpfile.js b/gulpfile.js new file mode 100644 index 0000000000..fd691b9550 --- /dev/null +++ b/gulpfile.js @@ -0,0 +1,19 @@ +var gulp = require('gulp'); +var shell = require('gulp-shell'); +var browserSync = require('browser-sync').create(); + +// Task for building blog when something changed: +gulp.task('build', shell.task(['bundle exec jekyll serve --incremental'])); +// If you don't use bundle: +// gulp.task('build', shell.task(['jekyll serve'])); +// If you use Windows Subsystem for Linux (thanks @SamuliAlajarvela): +// gulp.task('build', shell.task(['bundle exec jekyll serve --force_polling'])); + +// Task for serving blog with Browsersync +gulp.task('serve', function () { + browserSync.init({server: {baseDir: '_site/'}}); + // Reloads page when some of the already built files changed: + gulp.watch('_site/**/*.*').on('change', browserSync.reload); +}); + +gulp.task('default', gulp.parallel('build', 'serve')); diff --git a/js/additionalscripts.js b/js/additionalscripts.js index e3e2480e54..f271706a55 100644 --- a/js/additionalscripts.js +++ b/js/additionalscripts.js @@ -108,8 +108,8 @@ function navigateContent(url) { $('.innerpageitem').removeClass("activeitem"); } //jump to top when page loads - var hash = window.location.hash; - if (!hash) { + if (window.location.hash == "") { + console.log(window.location.hash); window.scrollTo(0, 0); } if (/Mobi|Android/i.test(navigator.userAgent) == true) { @@ -559,48 +559,51 @@ function scrollToHash () { } function domainTool() { -let input; -let accountInput; -const csdsButton = document.getElementById("csds-button"); -const csdsResult = document.getElementById("csds-result"); -let csdsUrl; -let html = ""; -csdsButton.addEventListener("click", event => { - input = document.getElementById("account"); - accountInput = input.value; - csdsUrl = 'https://api.liveperson.net/api/account/' + accountInput + '/service/baseURI?version=1.0'; - retrieveDomains(accountInput); -}); -const retrieveDomains = (account) => { - $.ajax({ - url: csdsUrl, - headers: { - 'Accept': 'application/json' - }, - dataType: "json", - success: function(data) { - html = ''; - $(csdsResult).css('display', 'table'); - if (data.baseURIs.length > 0) { - html += 'Service nameBase URI'; - data.baseURIs.sort(function(a, b){ - var m1 = a.service.toLowerCase(); - var m2 = b.service.toLowerCase(); - if(m1< m2) return -1; - if(m1> m2) return 1; - return 0; - }) - data.baseURIs.forEach((entry) => { - html += `${entry.service}${entry.baseURI}`; - }); - html += '' - csdsResult.innerHTML = html; - } else { - csdsResult.innerHTML = "Unable to retrieve base URIs for account, please verify your account number."; - } - } - }); - } + var $title = $('.h1').text(); + if ($title == "Domain API") { + let input; + let accountInput; + const csdsButton = document.getElementById("csds-button"); + const csdsResult = document.getElementById("csds-result"); + let csdsUrl; + let html = ""; + csdsButton.addEventListener("click", event => { + input = document.getElementById("account"); + accountInput = input.value; + csdsUrl = 'https://api.liveperson.net/api/account/' + accountInput + '/service/baseURI?version=1.0'; + retrieveDomains(accountInput); + }); + const retrieveDomains = (account) => { + $.ajax({ + url: csdsUrl, + headers: { + 'Accept': 'application/json' + }, + dataType: "json", + success: function(data) { + html = ''; + $(csdsResult).css('display', 'table'); + if (data.baseURIs.length > 0) { + html += 'Service nameBase URI'; + data.baseURIs.sort(function(a, b){ + var m1 = a.service.toLowerCase(); + var m2 = b.service.toLowerCase(); + if(m1< m2) return -1; + if(m1> m2) return 1; + return 0; + }) + data.baseURIs.forEach((entry) => { + html += `${entry.service}${entry.baseURI}`; + }); + html += '' + csdsResult.innerHTML = html; + } else { + csdsResult.innerHTML = "Unable to retrieve base URIs for account, please verify your account number."; + } + } + }); + } + } } //detect if explorer and then add a bunch of classes with its own CSS because it's oh so special diff --git a/node_modules/.bin/atob b/node_modules/.bin/atob new file mode 120000 index 0000000000..a68344a381 --- /dev/null +++ b/node_modules/.bin/atob @@ -0,0 +1 @@ +../atob/bin/atob.js \ No newline at end of file diff --git a/node_modules/.bin/browser-sync b/node_modules/.bin/browser-sync new file mode 120000 index 0000000000..666f25bd08 --- /dev/null +++ b/node_modules/.bin/browser-sync @@ -0,0 +1 @@ +../browser-sync/dist/bin.js \ No newline at end of file diff --git a/node_modules/.bin/color-support b/node_modules/.bin/color-support new file mode 120000 index 0000000000..fcbcb2865a --- /dev/null +++ b/node_modules/.bin/color-support @@ -0,0 +1 @@ +../color-support/bin.js \ No newline at end of file diff --git a/node_modules/.bin/dev-ip b/node_modules/.bin/dev-ip new file mode 120000 index 0000000000..138e5aca93 --- /dev/null +++ b/node_modules/.bin/dev-ip @@ -0,0 +1 @@ +../dev-ip/lib/dev-ip.js \ No newline at end of file diff --git a/node_modules/.bin/gulp b/node_modules/.bin/gulp new file mode 120000 index 0000000000..5de73328bc --- /dev/null +++ b/node_modules/.bin/gulp @@ -0,0 +1 @@ +../gulp/bin/gulp.js \ No newline at end of file diff --git a/node_modules/.bin/lt b/node_modules/.bin/lt new file mode 120000 index 0000000000..f79fff9e40 --- /dev/null +++ b/node_modules/.bin/lt @@ -0,0 +1 @@ +../localtunnel/bin/client \ No newline at end of file diff --git a/node_modules/.bin/mime b/node_modules/.bin/mime new file mode 120000 index 0000000000..fbb7ee0eed --- /dev/null +++ b/node_modules/.bin/mime @@ -0,0 +1 @@ +../mime/cli.js \ No newline at end of file diff --git a/node_modules/.bin/semver b/node_modules/.bin/semver new file mode 120000 index 0000000000..317eb293d8 --- /dev/null +++ b/node_modules/.bin/semver @@ -0,0 +1 @@ +../semver/bin/semver \ No newline at end of file diff --git a/node_modules/.bin/throttleproxy b/node_modules/.bin/throttleproxy new file mode 120000 index 0000000000..2ec6e307bc --- /dev/null +++ b/node_modules/.bin/throttleproxy @@ -0,0 +1 @@ +../stream-throttle/bin/throttleproxy.js \ No newline at end of file diff --git a/node_modules/.bin/which b/node_modules/.bin/which new file mode 120000 index 0000000000..f62471c851 --- /dev/null +++ b/node_modules/.bin/which @@ -0,0 +1 @@ +../which/bin/which \ No newline at end of file diff --git a/node_modules/.bin/window-size b/node_modules/.bin/window-size new file mode 120000 index 0000000000..e84c8ece59 --- /dev/null +++ b/node_modules/.bin/window-size @@ -0,0 +1 @@ +../window-size/cli.js \ No newline at end of file diff --git a/node_modules/accepts/HISTORY.md b/node_modules/accepts/HISTORY.md new file mode 100644 index 0000000000..0bf041781d --- /dev/null +++ b/node_modules/accepts/HISTORY.md @@ -0,0 +1,236 @@ +1.3.7 / 2019-04-29 +================== + + * deps: negotiator@0.6.2 + - Fix sorting charset, encoding, and language with extra parameters + +1.3.6 / 2019-04-28 +================== + + * deps: mime-types@~2.1.24 + - deps: mime-db@~1.40.0 + +1.3.5 / 2018-02-28 +================== + + * deps: mime-types@~2.1.18 + - deps: mime-db@~1.33.0 + +1.3.4 / 2017-08-22 +================== + + * deps: mime-types@~2.1.16 + - deps: mime-db@~1.29.0 + +1.3.3 / 2016-05-02 +================== + + * deps: mime-types@~2.1.11 + - deps: mime-db@~1.23.0 + * deps: negotiator@0.6.1 + - perf: improve `Accept` parsing speed + - perf: improve `Accept-Charset` parsing speed + - perf: improve `Accept-Encoding` parsing speed + - perf: improve `Accept-Language` parsing speed + +1.3.2 / 2016-03-08 +================== + + * deps: mime-types@~2.1.10 + - Fix extension of `application/dash+xml` + - Update primary extension for `audio/mp4` + - deps: mime-db@~1.22.0 + +1.3.1 / 2016-01-19 +================== + + * deps: mime-types@~2.1.9 + - deps: mime-db@~1.21.0 + +1.3.0 / 2015-09-29 +================== + + * deps: mime-types@~2.1.7 + - deps: mime-db@~1.19.0 + * deps: negotiator@0.6.0 + - Fix including type extensions in parameters in `Accept` parsing + - Fix parsing `Accept` parameters with quoted equals + - Fix parsing `Accept` parameters with quoted semicolons + - Lazy-load modules from main entry point + - perf: delay type concatenation until needed + - perf: enable strict mode + - perf: hoist regular expressions + - perf: remove closures getting spec properties + - perf: remove a closure from media type parsing + - perf: remove property delete from media type parsing + +1.2.13 / 2015-09-06 +=================== + + * deps: mime-types@~2.1.6 + - deps: mime-db@~1.18.0 + +1.2.12 / 2015-07-30 +=================== + + * deps: mime-types@~2.1.4 + - deps: mime-db@~1.16.0 + +1.2.11 / 2015-07-16 +=================== + + * deps: mime-types@~2.1.3 + - deps: mime-db@~1.15.0 + +1.2.10 / 2015-07-01 +=================== + + * deps: mime-types@~2.1.2 + - deps: mime-db@~1.14.0 + +1.2.9 / 2015-06-08 +================== + + * deps: mime-types@~2.1.1 + - perf: fix deopt during mapping + +1.2.8 / 2015-06-07 +================== + + * deps: mime-types@~2.1.0 + - deps: mime-db@~1.13.0 + * perf: avoid argument reassignment & argument slice + * perf: avoid negotiator recursive construction + * perf: enable strict mode + * perf: remove unnecessary bitwise operator + +1.2.7 / 2015-05-10 +================== + + * deps: negotiator@0.5.3 + - Fix media type parameter matching to be case-insensitive + +1.2.6 / 2015-05-07 +================== + + * deps: mime-types@~2.0.11 + - deps: mime-db@~1.9.1 + * deps: negotiator@0.5.2 + - Fix comparing media types with quoted values + - Fix splitting media types with quoted commas + +1.2.5 / 2015-03-13 +================== + + * deps: mime-types@~2.0.10 + - deps: mime-db@~1.8.0 + +1.2.4 / 2015-02-14 +================== + + * Support Node.js 0.6 + * deps: mime-types@~2.0.9 + - deps: mime-db@~1.7.0 + * deps: negotiator@0.5.1 + - Fix preference sorting to be stable for long acceptable lists + +1.2.3 / 2015-01-31 +================== + + * deps: mime-types@~2.0.8 + - deps: mime-db@~1.6.0 + +1.2.2 / 2014-12-30 +================== + + * deps: mime-types@~2.0.7 + - deps: mime-db@~1.5.0 + +1.2.1 / 2014-12-30 +================== + + * deps: mime-types@~2.0.5 + - deps: mime-db@~1.3.1 + +1.2.0 / 2014-12-19 +================== + + * deps: negotiator@0.5.0 + - Fix list return order when large accepted list + - Fix missing identity encoding when q=0 exists + - Remove dynamic building of Negotiator class + +1.1.4 / 2014-12-10 +================== + + * deps: mime-types@~2.0.4 + - deps: mime-db@~1.3.0 + +1.1.3 / 2014-11-09 +================== + + * deps: mime-types@~2.0.3 + - deps: mime-db@~1.2.0 + +1.1.2 / 2014-10-14 +================== + + * deps: negotiator@0.4.9 + - Fix error when media type has invalid parameter + +1.1.1 / 2014-09-28 +================== + + * deps: mime-types@~2.0.2 + - deps: mime-db@~1.1.0 + * deps: negotiator@0.4.8 + - Fix all negotiations to be case-insensitive + - Stable sort preferences of same quality according to client order + +1.1.0 / 2014-09-02 +================== + + * update `mime-types` + +1.0.7 / 2014-07-04 +================== + + * Fix wrong type returned from `type` when match after unknown extension + +1.0.6 / 2014-06-24 +================== + + * deps: negotiator@0.4.7 + +1.0.5 / 2014-06-20 +================== + + * fix crash when unknown extension given + +1.0.4 / 2014-06-19 +================== + + * use `mime-types` + +1.0.3 / 2014-06-11 +================== + + * deps: negotiator@0.4.6 + - Order by specificity when quality is the same + +1.0.2 / 2014-05-29 +================== + + * Fix interpretation when header not in request + * deps: pin negotiator@0.4.5 + +1.0.1 / 2014-01-18 +================== + + * Identity encoding isn't always acceptable + * deps: negotiator@~0.4.0 + +1.0.0 / 2013-12-27 +================== + + * Genesis diff --git a/node_modules/accepts/LICENSE b/node_modules/accepts/LICENSE new file mode 100644 index 0000000000..06166077be --- /dev/null +++ b/node_modules/accepts/LICENSE @@ -0,0 +1,23 @@ +(The MIT License) + +Copyright (c) 2014 Jonathan Ong +Copyright (c) 2015 Douglas Christopher Wilson + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +'Software'), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY +CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, +TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE +SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/node_modules/accepts/README.md b/node_modules/accepts/README.md new file mode 100644 index 0000000000..66a2f5400f --- /dev/null +++ b/node_modules/accepts/README.md @@ -0,0 +1,142 @@ +# accepts + +[![NPM Version][npm-version-image]][npm-url] +[![NPM Downloads][npm-downloads-image]][npm-url] +[![Node.js Version][node-version-image]][node-version-url] +[![Build Status][travis-image]][travis-url] +[![Test Coverage][coveralls-image]][coveralls-url] + +Higher level content negotiation based on [negotiator](https://www.npmjs.com/package/negotiator). +Extracted from [koa](https://www.npmjs.com/package/koa) for general use. + +In addition to negotiator, it allows: + +- Allows types as an array or arguments list, ie `(['text/html', 'application/json'])` + as well as `('text/html', 'application/json')`. +- Allows type shorthands such as `json`. +- Returns `false` when no types match +- Treats non-existent headers as `*` + +## Installation + +This is a [Node.js](https://nodejs.org/en/) module available through the +[npm registry](https://www.npmjs.com/). Installation is done using the +[`npm install` command](https://docs.npmjs.com/getting-started/installing-npm-packages-locally): + +```sh +$ npm install accepts +``` + +## API + + + +```js +var accepts = require('accepts') +``` + +### accepts(req) + +Create a new `Accepts` object for the given `req`. + +#### .charset(charsets) + +Return the first accepted charset. If nothing in `charsets` is accepted, +then `false` is returned. + +#### .charsets() + +Return the charsets that the request accepts, in the order of the client's +preference (most preferred first). + +#### .encoding(encodings) + +Return the first accepted encoding. If nothing in `encodings` is accepted, +then `false` is returned. + +#### .encodings() + +Return the encodings that the request accepts, in the order of the client's +preference (most preferred first). + +#### .language(languages) + +Return the first accepted language. If nothing in `languages` is accepted, +then `false` is returned. + +#### .languages() + +Return the languages that the request accepts, in the order of the client's +preference (most preferred first). + +#### .type(types) + +Return the first accepted type (and it is returned as the same text as what +appears in the `types` array). If nothing in `types` is accepted, then `false` +is returned. + +The `types` array can contain full MIME types or file extensions. Any value +that is not a full MIME types is passed to `require('mime-types').lookup`. + +#### .types() + +Return the types that the request accepts, in the order of the client's +preference (most preferred first). + +## Examples + +### Simple type negotiation + +This simple example shows how to use `accepts` to return a different typed +respond body based on what the client wants to accept. The server lists it's +preferences in order and will get back the best match between the client and +server. + +```js +var accepts = require('accepts') +var http = require('http') + +function app (req, res) { + var accept = accepts(req) + + // the order of this list is significant; should be server preferred order + switch (accept.type(['json', 'html'])) { + case 'json': + res.setHeader('Content-Type', 'application/json') + res.write('{"hello":"world!"}') + break + case 'html': + res.setHeader('Content-Type', 'text/html') + res.write('hello, world!') + break + default: + // the fallback is text/plain, so no need to specify it above + res.setHeader('Content-Type', 'text/plain') + res.write('hello, world!') + break + } + + res.end() +} + +http.createServer(app).listen(3000) +``` + +You can test this out with the cURL program: +```sh +curl -I -H'Accept: text/html' http://localhost:3000/ +``` + +## License + +[MIT](LICENSE) + +[coveralls-image]: https://badgen.net/coveralls/c/github/jshttp/accepts/master +[coveralls-url]: https://coveralls.io/r/jshttp/accepts?branch=master +[node-version-image]: https://badgen.net/npm/node/accepts +[node-version-url]: https://nodejs.org/en/download +[npm-downloads-image]: https://badgen.net/npm/dm/accepts +[npm-url]: https://npmjs.org/package/accepts +[npm-version-image]: https://badgen.net/npm/v/accepts +[travis-image]: https://badgen.net/travis/jshttp/accepts/master +[travis-url]: https://travis-ci.org/jshttp/accepts diff --git a/node_modules/accepts/index.js b/node_modules/accepts/index.js new file mode 100644 index 0000000000..e9b2f63fb1 --- /dev/null +++ b/node_modules/accepts/index.js @@ -0,0 +1,238 @@ +/*! + * accepts + * Copyright(c) 2014 Jonathan Ong + * Copyright(c) 2015 Douglas Christopher Wilson + * MIT Licensed + */ + +'use strict' + +/** + * Module dependencies. + * @private + */ + +var Negotiator = require('negotiator') +var mime = require('mime-types') + +/** + * Module exports. + * @public + */ + +module.exports = Accepts + +/** + * Create a new Accepts object for the given req. + * + * @param {object} req + * @public + */ + +function Accepts (req) { + if (!(this instanceof Accepts)) { + return new Accepts(req) + } + + this.headers = req.headers + this.negotiator = new Negotiator(req) +} + +/** + * Check if the given `type(s)` is acceptable, returning + * the best match when true, otherwise `undefined`, in which + * case you should respond with 406 "Not Acceptable". + * + * The `type` value may be a single mime type string + * such as "application/json", the extension name + * such as "json" or an array `["json", "html", "text/plain"]`. When a list + * or array is given the _best_ match, if any is returned. + * + * Examples: + * + * // Accept: text/html + * this.types('html'); + * // => "html" + * + * // Accept: text/*, application/json + * this.types('html'); + * // => "html" + * this.types('text/html'); + * // => "text/html" + * this.types('json', 'text'); + * // => "json" + * this.types('application/json'); + * // => "application/json" + * + * // Accept: text/*, application/json + * this.types('image/png'); + * this.types('png'); + * // => undefined + * + * // Accept: text/*;q=.5, application/json + * this.types(['html', 'json']); + * this.types('html', 'json'); + * // => "json" + * + * @param {String|Array} types... + * @return {String|Array|Boolean} + * @public + */ + +Accepts.prototype.type = +Accepts.prototype.types = function (types_) { + var types = types_ + + // support flattened arguments + if (types && !Array.isArray(types)) { + types = new Array(arguments.length) + for (var i = 0; i < types.length; i++) { + types[i] = arguments[i] + } + } + + // no types, return all requested types + if (!types || types.length === 0) { + return this.negotiator.mediaTypes() + } + + // no accept header, return first given type + if (!this.headers.accept) { + return types[0] + } + + var mimes = types.map(extToMime) + var accepts = this.negotiator.mediaTypes(mimes.filter(validMime)) + var first = accepts[0] + + return first + ? types[mimes.indexOf(first)] + : false +} + +/** + * Return accepted encodings or best fit based on `encodings`. + * + * Given `Accept-Encoding: gzip, deflate` + * an array sorted by quality is returned: + * + * ['gzip', 'deflate'] + * + * @param {String|Array} encodings... + * @return {String|Array} + * @public + */ + +Accepts.prototype.encoding = +Accepts.prototype.encodings = function (encodings_) { + var encodings = encodings_ + + // support flattened arguments + if (encodings && !Array.isArray(encodings)) { + encodings = new Array(arguments.length) + for (var i = 0; i < encodings.length; i++) { + encodings[i] = arguments[i] + } + } + + // no encodings, return all requested encodings + if (!encodings || encodings.length === 0) { + return this.negotiator.encodings() + } + + return this.negotiator.encodings(encodings)[0] || false +} + +/** + * Return accepted charsets or best fit based on `charsets`. + * + * Given `Accept-Charset: utf-8, iso-8859-1;q=0.2, utf-7;q=0.5` + * an array sorted by quality is returned: + * + * ['utf-8', 'utf-7', 'iso-8859-1'] + * + * @param {String|Array} charsets... + * @return {String|Array} + * @public + */ + +Accepts.prototype.charset = +Accepts.prototype.charsets = function (charsets_) { + var charsets = charsets_ + + // support flattened arguments + if (charsets && !Array.isArray(charsets)) { + charsets = new Array(arguments.length) + for (var i = 0; i < charsets.length; i++) { + charsets[i] = arguments[i] + } + } + + // no charsets, return all requested charsets + if (!charsets || charsets.length === 0) { + return this.negotiator.charsets() + } + + return this.negotiator.charsets(charsets)[0] || false +} + +/** + * Return accepted languages or best fit based on `langs`. + * + * Given `Accept-Language: en;q=0.8, es, pt` + * an array sorted by quality is returned: + * + * ['es', 'pt', 'en'] + * + * @param {String|Array} langs... + * @return {Array|String} + * @public + */ + +Accepts.prototype.lang = +Accepts.prototype.langs = +Accepts.prototype.language = +Accepts.prototype.languages = function (languages_) { + var languages = languages_ + + // support flattened arguments + if (languages && !Array.isArray(languages)) { + languages = new Array(arguments.length) + for (var i = 0; i < languages.length; i++) { + languages[i] = arguments[i] + } + } + + // no languages, return all requested languages + if (!languages || languages.length === 0) { + return this.negotiator.languages() + } + + return this.negotiator.languages(languages)[0] || false +} + +/** + * Convert extnames to mime. + * + * @param {String} type + * @return {String} + * @private + */ + +function extToMime (type) { + return type.indexOf('/') === -1 + ? mime.lookup(type) + : type +} + +/** + * Check if mime is valid. + * + * @param {String} type + * @return {String} + * @private + */ + +function validMime (type) { + return typeof type === 'string' +} diff --git a/node_modules/accepts/package.json b/node_modules/accepts/package.json new file mode 100644 index 0000000000..6fd8ec16ea --- /dev/null +++ b/node_modules/accepts/package.json @@ -0,0 +1,87 @@ +{ + "_from": "accepts@~1.3.4", + "_id": "accepts@1.3.7", + "_inBundle": false, + "_integrity": "sha512-Il80Qs2WjYlJIBNzNkK6KYqlVMTbZLXgHx2oT0pU/fjRHyEp+PEfEPY0R3WCwAGVOtauxh1hOxNgIf5bv7dQpA==", + "_location": "/accepts", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "accepts@~1.3.4", + "name": "accepts", + "escapedName": "accepts", + "rawSpec": "~1.3.4", + "saveSpec": null, + "fetchSpec": "~1.3.4" + }, + "_requiredBy": [ + "/engine.io", + "/serve-index" + ], + "_resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.7.tgz", + "_shasum": "531bc726517a3b2b41f850021c6cc15eaab507cd", + "_spec": "accepts@~1.3.4", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/serve-index", + "bugs": { + "url": "https://github.com/jshttp/accepts/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + }, + { + "name": "Jonathan Ong", + "email": "me@jongleberry.com", + "url": "http://jongleberry.com" + } + ], + "dependencies": { + "mime-types": "~2.1.24", + "negotiator": "0.6.2" + }, + "deprecated": false, + "description": "Higher-level content negotiation", + "devDependencies": { + "deep-equal": "1.0.1", + "eslint": "5.16.0", + "eslint-config-standard": "12.0.0", + "eslint-plugin-import": "2.17.2", + "eslint-plugin-markdown": "1.0.0", + "eslint-plugin-node": "8.0.1", + "eslint-plugin-promise": "4.1.1", + "eslint-plugin-standard": "4.0.0", + "mocha": "6.1.4", + "nyc": "14.0.0" + }, + "engines": { + "node": ">= 0.6" + }, + "files": [ + "LICENSE", + "HISTORY.md", + "index.js" + ], + "homepage": "https://github.com/jshttp/accepts#readme", + "keywords": [ + "content", + "negotiation", + "accept", + "accepts" + ], + "license": "MIT", + "name": "accepts", + "repository": { + "type": "git", + "url": "git+https://github.com/jshttp/accepts.git" + }, + "scripts": { + "lint": "eslint --plugin markdown --ext js,md .", + "test": "mocha --reporter spec --check-leaks --bail test/", + "test-cov": "nyc --reporter=html --reporter=text npm test", + "test-travis": "nyc --reporter=text npm test" + }, + "version": "1.3.7" +} diff --git a/node_modules/after/.npmignore b/node_modules/after/.npmignore new file mode 100644 index 0000000000..6c7860241d --- /dev/null +++ b/node_modules/after/.npmignore @@ -0,0 +1,2 @@ +node_modules +.monitor diff --git a/node_modules/after/.travis.yml b/node_modules/after/.travis.yml new file mode 100644 index 0000000000..afd72d0e58 --- /dev/null +++ b/node_modules/after/.travis.yml @@ -0,0 +1,12 @@ +language: node_js +node_js: + - 0.6 + - 0.8 + - 0.9 + - 0.10 + - 0.12 + - 4.2.4 + - 5.4.1 + - iojs-1 + - iojs-2 + - iojs-3 diff --git a/node_modules/after/LICENCE b/node_modules/after/LICENCE new file mode 100644 index 0000000000..7c35130683 --- /dev/null +++ b/node_modules/after/LICENCE @@ -0,0 +1,19 @@ +Copyright (c) 2011 Raynos. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. \ No newline at end of file diff --git a/node_modules/after/README.md b/node_modules/after/README.md new file mode 100644 index 0000000000..fc69096476 --- /dev/null +++ b/node_modules/after/README.md @@ -0,0 +1,115 @@ +# After [![Build Status][1]][2] + +Invoke callback after n calls + +## Status: production ready + +## Example + +```js +var after = require("after") +var db = require("./db") // some db. + +var updateUser = function (req, res) { + // use after to run two tasks in parallel, + // namely get request body and get session + // then run updateUser with the results + var next = after(2, updateUser) + var results = {} + + getJSONBody(req, res, function (err, body) { + if (err) return next(err) + + results.body = body + next(null, results) + }) + + getSessionUser(req, res, function (err, user) { + if (err) return next(err) + + results.user = user + next(null, results) + }) + + // now do the thing! + function updateUser(err, result) { + if (err) { + res.statusCode = 500 + return res.end("Unexpected Error") + } + + if (!result.user || result.user.role !== "admin") { + res.statusCode = 403 + return res.end("Permission Denied") + } + + db.put("users:" + req.params.userId, result.body, function (err) { + if (err) { + res.statusCode = 500 + return res.end("Unexpected Error") + } + + res.statusCode = 200 + res.end("Ok") + }) + } +} +``` + +## Naive Example + +```js +var after = require("after") + , next = after(3, logItWorks) + +next() +next() +next() // it works + +function logItWorks() { + console.log("it works!") +} +``` + +## Example with error handling + +```js +var after = require("after") + , next = after(3, logError) + +next() +next(new Error("oops")) // logs oops +next() // does nothing + +// This callback is only called once. +// If there is an error the callback gets called immediately +// this avoids the situation where errors get lost. +function logError(err) { + console.log(err) +} +``` + +## Installation + +`npm install after` + +## Tests + +`npm test` + +## Contributors + + - Raynos + - defunctzombie + +## MIT Licenced + + [1]: https://secure.travis-ci.org/Raynos/after.png + [2]: http://travis-ci.org/Raynos/after + [3]: http://raynos.org/blog/2/Flow-control-in-node.js + [4]: http://stackoverflow.com/questions/6852059/determining-the-end-of-asynchronous-operations-javascript/6852307#6852307 + [5]: http://stackoverflow.com/questions/6869872/in-javascript-what-are-best-practices-for-executing-multiple-asynchronous-functi/6870031#6870031 + [6]: http://stackoverflow.com/questions/6864397/javascript-performance-long-running-tasks/6889419#6889419 + [7]: http://stackoverflow.com/questions/6597493/synchronous-database-queries-with-node-js/6620091#6620091 + [8]: http://github.com/Raynos/iterators + [9]: http://github.com/Raynos/composite diff --git a/node_modules/after/index.js b/node_modules/after/index.js new file mode 100644 index 0000000000..ec24879744 --- /dev/null +++ b/node_modules/after/index.js @@ -0,0 +1,28 @@ +module.exports = after + +function after(count, callback, err_cb) { + var bail = false + err_cb = err_cb || noop + proxy.count = count + + return (count === 0) ? callback() : proxy + + function proxy(err, result) { + if (proxy.count <= 0) { + throw new Error('after called too many times') + } + --proxy.count + + // after first error, rest are passed to err_cb + if (err) { + bail = true + callback(err) + // future error callbacks will go to error handler + callback = err_cb + } else if (proxy.count === 0 && !bail) { + callback(null, result) + } + } +} + +function noop() {} diff --git a/node_modules/after/package.json b/node_modules/after/package.json new file mode 100644 index 0000000000..d289e56f64 --- /dev/null +++ b/node_modules/after/package.json @@ -0,0 +1,63 @@ +{ + "_from": "after@0.8.2", + "_id": "after@0.8.2", + "_inBundle": false, + "_integrity": "sha1-/ts5T58OAqqXaOcCvaI7UF+ufh8=", + "_location": "/after", + "_phantomChildren": {}, + "_requested": { + "type": "version", + "registry": true, + "raw": "after@0.8.2", + "name": "after", + "escapedName": "after", + "rawSpec": "0.8.2", + "saveSpec": null, + "fetchSpec": "0.8.2" + }, + "_requiredBy": [ + "/engine.io-parser" + ], + "_resolved": "https://registry.npmjs.org/after/-/after-0.8.2.tgz", + "_shasum": "fedb394f9f0e02aa9768e702bda23b505fae7e1f", + "_spec": "after@0.8.2", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/engine.io-parser", + "author": { + "name": "Raynos", + "email": "raynos2@gmail.com" + }, + "bugs": { + "url": "https://github.com/Raynos/after/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "Raynos", + "email": "raynos2@gmail.com", + "url": "http://raynos.org" + } + ], + "deprecated": false, + "description": "after - tiny flow control", + "devDependencies": { + "mocha": "~1.8.1" + }, + "homepage": "https://github.com/Raynos/after#readme", + "keywords": [ + "flowcontrol", + "after", + "flow", + "control", + "arch" + ], + "license": "MIT", + "name": "after", + "repository": { + "type": "git", + "url": "git://github.com/Raynos/after.git" + }, + "scripts": { + "test": "mocha --ui tdd --reporter spec test/*.js" + }, + "version": "0.8.2" +} diff --git a/node_modules/after/test/after-test.js b/node_modules/after/test/after-test.js new file mode 100644 index 0000000000..0d63f4c246 --- /dev/null +++ b/node_modules/after/test/after-test.js @@ -0,0 +1,120 @@ +/*global suite, test*/ + +var assert = require("assert") + , after = require("../") + +test("exists", function () { + assert(typeof after === "function", "after is not a function") +}) + +test("after when called with 0 invokes", function (done) { + after(0, done) +}); + +test("after 1", function (done) { + var next = after(1, done) + next() +}) + +test("after 5", function (done) { + var next = after(5, done) + , i = 5 + + while (i--) { + next() + } +}) + +test("manipulate count", function (done) { + var next = after(1, done) + , i = 5 + + next.count = i + while (i--) { + next() + } +}) + +test("after terminates on error", function (done) { + var next = after(2, function(err) { + assert.equal(err.message, 'test'); + done(); + }) + next(new Error('test')) + next(new Error('test2')) +}) + +test('gee', function(done) { + done = after(2, done) + + function cb(err) { + assert.equal(err.message, 1); + done() + } + + var next = after(3, cb, function(err) { + assert.equal(err.message, 2) + done() + }); + + next() + next(new Error(1)) + next(new Error(2)) +}) + +test('eee', function(done) { + done = after(3, done) + + function cb(err) { + assert.equal(err.message, 1); + done() + } + + var next = after(3, cb, function(err) { + assert.equal(err.message, 2) + done() + }); + + next(new Error(1)) + next(new Error(2)) + next(new Error(2)) +}) + +test('gge', function(done) { + function cb(err) { + assert.equal(err.message, 1); + done() + } + + var next = after(3, cb, function(err) { + // should not happen + assert.ok(false); + }); + + next() + next() + next(new Error(1)) +}) + +test('egg', function(done) { + function cb(err) { + assert.equal(err.message, 1); + done() + } + + var next = after(3, cb, function(err) { + // should not happen + assert.ok(false); + }); + + next(new Error(1)) + next() + next() +}) + +test('throws on too many calls', function(done) { + var next = after(1, done); + next() + assert.throws(next, /after called too many times/); +}); + diff --git a/node_modules/ansi-colors/LICENSE b/node_modules/ansi-colors/LICENSE new file mode 100644 index 0000000000..b70671f0a3 --- /dev/null +++ b/node_modules/ansi-colors/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2015-2017, Brian Woodward. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/ansi-colors/README.md b/node_modules/ansi-colors/README.md new file mode 100644 index 0000000000..2e669fe469 --- /dev/null +++ b/node_modules/ansi-colors/README.md @@ -0,0 +1,105 @@ +# ansi-colors [![NPM version](https://img.shields.io/npm/v/ansi-colors.svg?style=flat)](https://www.npmjs.com/package/ansi-colors) [![NPM monthly downloads](https://img.shields.io/npm/dm/ansi-colors.svg?style=flat)](https://npmjs.org/package/ansi-colors) [![NPM total downloads](https://img.shields.io/npm/dt/ansi-colors.svg?style=flat)](https://npmjs.org/package/ansi-colors) [![Linux Build Status](https://img.shields.io/travis/doowb/ansi-colors.svg?style=flat&label=Travis)](https://travis-ci.org/doowb/ansi-colors) [![Windows Build Status](https://img.shields.io/appveyor/ci/doowb/ansi-colors.svg?style=flat&label=AppVeyor)](https://ci.appveyor.com/project/doowb/ansi-colors) + +> Collection of ansi colors and styles. + +## Install + +Install with [npm](https://www.npmjs.com/): + +```sh +$ npm install --save ansi-colors +``` + +## Usage + +This module exports an object of functions. Each function wraps a string with the ansi codes used to display the string with that color (or style). Use the wrapped string with `console.log`: + +```js +var colors = require('ansi-colors'); +console.log(colors.bold(colors.cyan('[info]')), colors.cyan('This is some information')); +console.log(colors.bold(colors.yellow('[warning]')), colors.yellow('This is a warning')); +console.error(colors.bold(colors.red('[ERROR]')), colors.red('Danger! There was an error!')); +``` + +![image](https://user-images.githubusercontent.com/995160/34897845-3150daae-f7be-11e7-9706-38c42461e0ee.png) + +## Example + +See the [example](./example.js) for more colors and styles. + +## About + +### Related projects + +* [ansi-bgblack](https://www.npmjs.com/package/ansi-bgblack): The color bgblack, in ansi. | [homepage](https://github.com/jonschlinkert/ansi-bgblack "The color bgblack, in ansi.") +* [ansi-bgblue](https://www.npmjs.com/package/ansi-bgblue): The color bgblue, in ansi. | [homepage](https://github.com/jonschlinkert/ansi-bgblue "The color bgblue, in ansi.") +* [ansi-bgcyan](https://www.npmjs.com/package/ansi-bgcyan): The color bgcyan, in ansi. | [homepage](https://github.com/jonschlinkert/ansi-bgcyan "The color bgcyan, in ansi.") +* [ansi-bggreen](https://www.npmjs.com/package/ansi-bggreen): The color bggreen, in ansi. | [homepage](https://github.com/jonschlinkert/ansi-bggreen "The color bggreen, in ansi.") +* [ansi-bgmagenta](https://www.npmjs.com/package/ansi-bgmagenta): The color bgmagenta, in ansi. | [homepage](https://github.com/jonschlinkert/ansi-bgmagenta "The color bgmagenta, in ansi.") +* [ansi-bgred](https://www.npmjs.com/package/ansi-bgred): The color bgred, in ansi. | [homepage](https://github.com/jonschlinkert/ansi-bgred "The color bgred, in ansi.") +* [ansi-bgwhite](https://www.npmjs.com/package/ansi-bgwhite): The color bgwhite, in ansi. | [homepage](https://github.com/jonschlinkert/ansi-bgwhite "The color bgwhite, in ansi.") +* [ansi-bgyellow](https://www.npmjs.com/package/ansi-bgyellow): The color bgyellow, in ansi. | [homepage](https://github.com/jonschlinkert/ansi-bgyellow "The color bgyellow, in ansi.") +* [ansi-black](https://www.npmjs.com/package/ansi-black): The color black, in ansi. | [homepage](https://github.com/jonschlinkert/ansi-black "The color black, in ansi.") +* [ansi-blue](https://www.npmjs.com/package/ansi-blue): The color blue, in ansi. | [homepage](https://github.com/jonschlinkert/ansi-blue "The color blue, in ansi.") +* [ansi-bold](https://www.npmjs.com/package/ansi-bold): The color bold, in ansi. | [homepage](https://github.com/jonschlinkert/ansi-bold "The color bold, in ansi.") +* [ansi-cyan](https://www.npmjs.com/package/ansi-cyan): The color cyan, in ansi. | [homepage](https://github.com/jonschlinkert/ansi-cyan "The color cyan, in ansi.") +* [ansi-dim](https://www.npmjs.com/package/ansi-dim): The color dim, in ansi. | [homepage](https://github.com/jonschlinkert/ansi-dim "The color dim, in ansi.") +* [ansi-gray](https://www.npmjs.com/package/ansi-gray): The color gray, in ansi. | [homepage](https://github.com/jonschlinkert/ansi-gray "The color gray, in ansi.") +* [ansi-green](https://www.npmjs.com/package/ansi-green): The color green, in ansi. | [homepage](https://github.com/jonschlinkert/ansi-green "The color green, in ansi.") +* [ansi-grey](https://www.npmjs.com/package/ansi-grey): The color grey, in ansi. | [homepage](https://github.com/jonschlinkert/ansi-grey "The color grey, in ansi.") +* [ansi-hidden](https://www.npmjs.com/package/ansi-hidden): The color hidden, in ansi. | [homepage](https://github.com/jonschlinkert/ansi-hidden "The color hidden, in ansi.") +* [ansi-inverse](https://www.npmjs.com/package/ansi-inverse): The color inverse, in ansi. | [homepage](https://github.com/jonschlinkert/ansi-inverse "The color inverse, in ansi.") +* [ansi-italic](https://www.npmjs.com/package/ansi-italic): The color italic, in ansi. | [homepage](https://github.com/jonschlinkert/ansi-italic "The color italic, in ansi.") +* [ansi-magenta](https://www.npmjs.com/package/ansi-magenta): The color magenta, in ansi. | [homepage](https://github.com/jonschlinkert/ansi-magenta "The color magenta, in ansi.") +* [ansi-red](https://www.npmjs.com/package/ansi-red): The color red, in ansi. | [homepage](https://github.com/jonschlinkert/ansi-red "The color red, in ansi.") +* [ansi-reset](https://www.npmjs.com/package/ansi-reset): The color reset, in ansi. | [homepage](https://github.com/jonschlinkert/ansi-reset "The color reset, in ansi.") +* [ansi-strikethrough](https://www.npmjs.com/package/ansi-strikethrough): The color strikethrough, in ansi. | [homepage](https://github.com/jonschlinkert/ansi-strikethrough "The color strikethrough, in ansi.") +* [ansi-underline](https://www.npmjs.com/package/ansi-underline): The color underline, in ansi. | [homepage](https://github.com/jonschlinkert/ansi-underline "The color underline, in ansi.") +* [ansi-white](https://www.npmjs.com/package/ansi-white): The color white, in ansi. | [homepage](https://github.com/jonschlinkert/ansi-white "The color white, in ansi.") +* [ansi-wrap](https://www.npmjs.com/package/ansi-wrap): Create ansi colors by passing the open and close codes. | [homepage](https://github.com/jonschlinkert/ansi-wrap "Create ansi colors by passing the open and close codes.") +* [ansi-yellow](https://www.npmjs.com/package/ansi-yellow): The color yellow, in ansi. | [homepage](https://github.com/jonschlinkert/ansi-yellow "The color yellow, in ansi.") + +### Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new). + +### Contributors + +| **Commits** | **Contributor** | +| --- | --- | +| 10 | [doowb](https://github.com/doowb) | +| 3 | [jonschlinkert](https://github.com/jonschlinkert) | + +### Building docs + +_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_ + +To generate the readme, run the following command: + +```sh +$ npm install -g verbose/verb#dev verb-generate-readme && verb +``` + +### Running tests + +Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command: + +```sh +$ npm install && npm test +``` + +### Author + +**Brian Woodward** + +* [github/doowb](https://github.com/doowb) +* [twitter/doowb](https://twitter.com/doowb) + +### License + +Copyright © 2018, [Brian Woodward](https://github.com/doowb). +Released under the [MIT License](LICENSE). + +*** + +_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.6.0, on January 12, 2018._ \ No newline at end of file diff --git a/node_modules/ansi-colors/index.js b/node_modules/ansi-colors/index.js new file mode 100644 index 0000000000..37da67fb49 --- /dev/null +++ b/node_modules/ansi-colors/index.js @@ -0,0 +1,456 @@ +/*! + * ansi-colors + * + * Copyright (c) 2015-2017, Brian Woodward. + * Released under the MIT License. + */ + +'use strict'; + +/** + * Module dependencies + */ + +var wrap = require('ansi-wrap'); + +/** + * Wrap a string with ansi codes to create a black background. + * + * ```js + * console.log(colors.bgblack('some string')); + * ``` + * + * @param {string} message String to wrap with ansi codes. + * @return {string} Wrapped string + * @api public + * @name bgblack + */ + +exports.bgblack = function bgblack(message) { + return wrap(40, 49, message); +}; + +/** + * Wrap a string with ansi codes to create a blue background. + * + * ```js + * console.log(colors.bgblue('some string')); + * ``` + * + * @param {string} message String to wrap with ansi codes. + * @return {string} Wrapped string + * @api public + * @name bgblue + */ + +exports.bgblue = function bgblue(message) { + return wrap(44, 49, message); +}; + +/** + * Wrap a string with ansi codes to create a cyan background. + * + * ```js + * console.log(colors.bgcyan('some string')); + * ``` + * + * @param {string} message String to wrap with ansi codes. + * @return {string} Wrapped string + * @api public + * @name bgcyan + */ + +exports.bgcyan = function bgcyan(message) { + return wrap(46, 49, message); +}; + +/** + * Wrap a string with ansi codes to create a green background. + * + * ```js + * console.log(colors.bggreen('some string')); + * ``` + * + * @param {string} message String to wrap with ansi codes. + * @return {string} Wrapped string + * @api public + * @name bggreen + */ + +exports.bggreen = function bggreen(message) { + return wrap(42, 49, message); +}; + +/** + * Wrap a string with ansi codes to create a magenta background. + * + * ```js + * console.log(colors.bgmagenta('some string')); + * ``` + * + * @param {string} message String to wrap with ansi codes. + * @return {string} Wrapped string + * @api public + * @name bgmagenta + */ + +exports.bgmagenta = function bgmagenta(message) { + return wrap(45, 49, message); +}; + +/** + * Wrap a string with ansi codes to create a red background. + * + * ```js + * console.log(colors.bgred('some string')); + * ``` + * + * @param {string} message String to wrap with ansi codes. + * @return {string} Wrapped string + * @api public + * @name bgred + */ + +exports.bgred = function bgred(message) { + return wrap(41, 49, message); +}; + +/** + * Wrap a string with ansi codes to create a white background. + * + * ```js + * console.log(colors.bgwhite('some string')); + * ``` + * + * @param {string} message String to wrap with ansi codes. + * @return {string} Wrapped string + * @api public + * @name bgwhite + */ + +exports.bgwhite = function bgwhite(message) { + return wrap(47, 49, message); +}; + +/** + * Wrap a string with ansi codes to create a yellow background. + * + * ```js + * console.log(colors.bgyellow('some string')); + * ``` + * + * @param {string} message String to wrap with ansi codes. + * @return {string} Wrapped string + * @api public + * @name bgyellow + */ + +exports.bgyellow = function bgyellow(message) { + return wrap(43, 49, message); +}; + +/** + * Wrap a string with ansi codes to create black text. + * + * ```js + * console.log(colors.black('some string')); + * ``` + * + * @param {string} message String to wrap with ansi codes. + * @return {string} Wrapped string + * @api public + * @name black + */ + +exports.black = function black(message) { + return wrap(30, 39, message); +}; + +/** + * Wrap a string with ansi codes to create blue text. + * + * ```js + * console.log(colors.blue('some string')); + * ``` + * + * @param {string} message String to wrap with ansi codes. + * @return {string} Wrapped string + * @api public + * @name blue + */ + +exports.blue = function blue(message) { + return wrap(34, 39, message); +}; + +/** + * Wrap a string with ansi codes to create bold text. + * + * ```js + * console.log(colors.bold('some string')); + * ``` + * + * @param {string} message String to wrap with ansi codes. + * @return {string} Wrapped string + * @api public + * @name bold + */ + +exports.bold = function bold(message) { + return wrap(1, 22, message); +}; + +/** + * Wrap a string with ansi codes to create cyan text. + * + * ```js + * console.log(colors.cyan('some string')); + * ``` + * + * @param {string} message String to wrap with ansi codes. + * @return {string} Wrapped string + * @api public + * @name cyan + */ + +exports.cyan = function cyan(message) { + return wrap(36, 39, message); +}; + +/** + * Wrap a string with ansi codes to create dim text. + * + * ```js + * console.log(colors.dim('some string')); + * ``` + * + * @param {string} message String to wrap with ansi codes. + * @return {string} Wrapped string + * @api public + * @name dim + */ + +exports.dim = function dim(message) { + return wrap(2, 22, message); +}; + +/** + * Wrap a string with ansi codes to create gray text. + * + * ```js + * console.log(colors.gray('some string')); + * ``` + * + * @param {string} message String to wrap with ansi codes. + * @return {string} Wrapped string + * @api public + * @name gray + */ + +exports.gray = function gray(message) { + return wrap(90, 39, message); +}; + +/** + * Wrap a string with ansi codes to create green text. + * + * ```js + * console.log(colors.green('some string')); + * ``` + * + * @param {string} message String to wrap with ansi codes. + * @return {string} Wrapped string + * @api public + * @name green + */ + +exports.green = function green(message) { + return wrap(32, 39, message); +}; + +/** + * Wrap a string with ansi codes to create grey text. + * + * ```js + * console.log(colors.grey('some string')); + * ``` + * + * @param {string} message String to wrap with ansi codes. + * @return {string} Wrapped string + * @api public + * @name grey + */ + +exports.grey = function grey(message) { + return wrap(90, 39, message); +}; + +/** + * Wrap a string with ansi codes to create hidden text. + * + * ```js + * console.log(colors.hidden('some string')); + * ``` + * + * @param {string} message String to wrap with ansi codes. + * @return {string} Wrapped string + * @api public + * @name hidden + */ + +exports.hidden = function hidden(message) { + return wrap(8, 28, message); +}; + +/** + * Wrap a string with ansi codes to create inverse text. + * + * ```js + * console.log(colors.inverse('some string')); + * ``` + * + * @param {string} message String to wrap with ansi codes. + * @return {string} Wrapped string + * @api public + * @name inverse + */ + +exports.inverse = function inverse(message) { + return wrap(7, 27, message); +}; + +/** + * Wrap a string with ansi codes to create italic text. + * + * ```js + * console.log(colors.italic('some string')); + * ``` + * + * @param {string} message String to wrap with ansi codes. + * @return {string} Wrapped string + * @api public + * @name italic + */ + +exports.italic = function italic(message) { + return wrap(3, 23, message); +}; + +/** + * Wrap a string with ansi codes to create magenta text. + * + * ```js + * console.log(colors.magenta('some string')); + * ``` + * + * @param {string} message String to wrap with ansi codes. + * @return {string} Wrapped string + * @api public + * @name magenta + */ + +exports.magenta = function magenta(message) { + return wrap(35, 39, message); +}; + +/** + * Wrap a string with ansi codes to create red text. + * + * ```js + * console.log(colors.red('some string')); + * ``` + * + * @param {string} message String to wrap with ansi codes. + * @return {string} Wrapped string + * @api public + * @name red + */ + +exports.red = function red(message) { + return wrap(31, 39, message); +}; + +/** + * Wrap a string with ansi codes to reset ansi colors currently on the string. + * + * ```js + * console.log(colors.reset('some string')); + * ``` + * + * @param {string} message String to wrap with ansi codes. + * @return {string} Wrapped string + * @api public + * @name reset + */ + +exports.reset = function reset(message) { + return wrap(0, 0, message); +}; + +/** + * Wrap a string with ansi codes to add a strikethrough to the text. + * + * ```js + * console.log(colors.strikethrough('some string')); + * ``` + * + * @param {string} message String to wrap with ansi codes. + * @return {string} Wrapped string + * @api public + * @name strikethrough + */ + +exports.strikethrough = function strikethrough(message) { + return wrap(9, 29, message); +}; + +/** + * Wrap a string with ansi codes to underline the text. + * + * ```js + * console.log(colors.underline('some string')); + * ``` + * + * @param {string} message String to wrap with ansi codes. + * @return {string} Wrapped string + * @api public + * @name underline + */ + +exports.underline = function underline(message) { + return wrap(4, 24, message); +}; + +/** + * Wrap a string with ansi codes to create white text. + * + * ```js + * console.log(colors.white('some string')); + * ``` + * + * @param {string} message String to wrap with ansi codes. + * @return {string} Wrapped string + * @api public + * @name white + */ + +exports.white = function white(message) { + return wrap(37, 39, message); +}; + +/** + * Wrap a string with ansi codes to create yellow text. + * + * ```js + * console.log(colors.yellow('some string')); + * ``` + * + * @param {string} message String to wrap with ansi codes. + * @return {string} Wrapped string + * @api public + * @name yellow + */ + +exports.yellow = function yellow(message) { + return wrap(33, 39, message); +}; diff --git a/node_modules/ansi-colors/package.json b/node_modules/ansi-colors/package.json new file mode 100644 index 0000000000..3c64e09d39 --- /dev/null +++ b/node_modules/ansi-colors/package.json @@ -0,0 +1,175 @@ +{ + "_from": "ansi-colors@^1.0.1", + "_id": "ansi-colors@1.1.0", + "_inBundle": false, + "_integrity": "sha512-SFKX67auSNoVR38N3L+nvsPjOE0bybKTYbkf5tRvushrAPQ9V75huw0ZxBkKVeRU9kqH3d6HA4xTckbwZ4ixmA==", + "_location": "/ansi-colors", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "ansi-colors@^1.0.1", + "name": "ansi-colors", + "escapedName": "ansi-colors", + "rawSpec": "^1.0.1", + "saveSpec": null, + "fetchSpec": "^1.0.1" + }, + "_requiredBy": [ + "/gulp/gulp-cli" + ], + "_resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-1.1.0.tgz", + "_shasum": "6374b4dd5d4718ff3ce27a671a3b1cad077132a9", + "_spec": "ansi-colors@^1.0.1", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/gulp/node_modules/gulp-cli", + "author": { + "name": "Brian Woodward", + "url": "https://github.com/doowb" + }, + "bugs": { + "url": "https://github.com/doowb/ansi-colors/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "Brian Woodward", + "url": "https://twitter.com/doowb" + }, + { + "name": "Jon Schlinkert", + "url": "http://twitter.com/jonschlinkert" + } + ], + "dependencies": { + "ansi-wrap": "^0.1.0" + }, + "deprecated": false, + "description": "Collection of ansi colors and styles.", + "devDependencies": { + "gulp-format-md": "^1.0.0", + "mocha": "^3.5.3", + "typescript": "^2.7.1" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js", + "types/index.d.ts" + ], + "homepage": "https://github.com/doowb/ansi-colors", + "keywords": [ + "ansi-bgblack", + "ansi-bgblue", + "ansi-bgcyan", + "ansi-bggreen", + "ansi-bgmagenta", + "ansi-bgred", + "ansi-bgwhite", + "ansi-bgyellow", + "ansi-black", + "ansi-blue", + "ansi-bold", + "ansi-cyan", + "ansi-dim", + "ansi-gray", + "ansi-green", + "ansi-grey", + "ansi-hidden", + "ansi-inverse", + "ansi-italic", + "ansi-magenta", + "ansi-red", + "ansi-reset", + "ansi-strikethrough", + "ansi-underline", + "ansi-white", + "ansi-yellow", + "bgblack", + "bgblue", + "bgcyan", + "bggreen", + "bgmagenta", + "bgred", + "bgwhite", + "bgyellow", + "black", + "blue", + "bold", + "cyan", + "dim", + "gray", + "green", + "grey", + "hidden", + "inverse", + "italic", + "magenta", + "red", + "reset", + "strikethrough", + "underline", + "white", + "yellow" + ], + "license": "MIT", + "main": "index.js", + "name": "ansi-colors", + "repository": { + "type": "git", + "url": "git+https://github.com/doowb/ansi-colors.git" + }, + "scripts": { + "test": "mocha && tsc --project types" + }, + "types": "./types/index.d.ts", + "verb": { + "toc": false, + "layout": "default", + "tasks": [ + "readme" + ], + "plugins": [ + "gulp-format-md" + ], + "lint": { + "reflinks": true + }, + "reflinks": [ + "verb-readme-generator", + "verb" + ], + "related": { + "list": [ + "ansi-bgblack", + "ansi-bgblue", + "ansi-bgcyan", + "ansi-bggreen", + "ansi-bgmagenta", + "ansi-bgred", + "ansi-bgwhite", + "ansi-bgyellow", + "ansi-black", + "ansi-blue", + "ansi-bold", + "ansi-cyan", + "ansi-dim", + "ansi-gray", + "ansi-green", + "ansi-grey", + "ansi-hidden", + "ansi-inverse", + "ansi-italic", + "ansi-magenta", + "ansi-red", + "ansi-reset", + "ansi-strikethrough", + "ansi-underline", + "ansi-white", + "ansi-wrap", + "ansi-yellow" + ] + } + }, + "version": "1.1.0" +} diff --git a/node_modules/ansi-colors/types/index.d.ts b/node_modules/ansi-colors/types/index.d.ts new file mode 100644 index 0000000000..5f216a8c3e --- /dev/null +++ b/node_modules/ansi-colors/types/index.d.ts @@ -0,0 +1,31 @@ +// Imported from from DefinitelyTyped project. +// TypeScript definitions for ansi-colors +// Definitions by: Rogier Schouten +// Integrated by: Jordan Mele + +export function bgblack(message: string): string; +export function bgblue(message: string): string; +export function bgcyan(message: string): string; +export function bggreen(message: string): string; +export function bgmagenta(message: string): string; +export function bgred(message: string): string; +export function bgwhite(message: string): string; +export function bgyellow(message: string): string; +export function black(message: string): string; +export function blue(message: string): string; +export function bold(message: string): string; +export function cyan(message: string): string; +export function dim(message: string): string; +export function gray(message: string): string; +export function green(message: string): string; +export function grey(message: string): string; +export function hidden(message: string): string; +export function inverse(message: string): string; +export function italic(message: string): string; +export function magenta(message: string): string; +export function red(message: string): string; +export function reset(message: string): string; +export function strikethrough(message: string): string; +export function underline(message: string): string; +export function white(message: string): string; +export function yellow(message: string): string; diff --git a/node_modules/ansi-gray/LICENSE b/node_modules/ansi-gray/LICENSE new file mode 100644 index 0000000000..41283c9f71 --- /dev/null +++ b/node_modules/ansi-gray/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) <%= year() %>, Jon Schlinkert. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/ansi-gray/index.js b/node_modules/ansi-gray/index.js new file mode 100644 index 0000000000..c22176a3d8 --- /dev/null +++ b/node_modules/ansi-gray/index.js @@ -0,0 +1,14 @@ +/*! + * ansi-gray + * + * Copyright (c) 2015, Jon Schlinkert. + * Licensed under the MIT License. + */ + +'use strict'; + +var wrap = require('ansi-wrap'); + +module.exports = function gray(message) { + return wrap(90, 39, message); +}; diff --git a/node_modules/ansi-gray/package.json b/node_modules/ansi-gray/package.json new file mode 100644 index 0000000000..041fdb0ebd --- /dev/null +++ b/node_modules/ansi-gray/package.json @@ -0,0 +1,86 @@ +{ + "_from": "ansi-gray@^0.1.1", + "_id": "ansi-gray@0.1.1", + "_inBundle": false, + "_integrity": "sha1-KWLPVOyXksSFEKPetSRDaGHvclE=", + "_location": "/ansi-gray", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "ansi-gray@^0.1.1", + "name": "ansi-gray", + "escapedName": "ansi-gray", + "rawSpec": "^0.1.1", + "saveSpec": null, + "fetchSpec": "^0.1.1" + }, + "_requiredBy": [ + "/fancy-log" + ], + "_resolved": "https://registry.npmjs.org/ansi-gray/-/ansi-gray-0.1.1.tgz", + "_shasum": "2962cf54ec9792c48510a3deb524436861ef7251", + "_spec": "ansi-gray@^0.1.1", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/fancy-log", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/jonschlinkert/ansi-gray/issues" + }, + "bundleDependencies": false, + "dependencies": { + "ansi-wrap": "0.1.0" + }, + "deprecated": false, + "description": "The color gray, in ansi.", + "devDependencies": { + "mocha": "*" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/jonschlinkert/ansi-gray", + "keywords": [ + "gray", + "256", + "ansi", + "cli", + "color", + "colors", + "colour", + "command", + "command-line", + "console", + "format", + "formatting", + "iterm", + "log", + "logging", + "rgb", + "shell", + "string", + "style", + "styles", + "styling", + "terminal", + "text", + "tty", + "xterm" + ], + "license": "MIT", + "main": "index.js", + "name": "ansi-gray", + "repository": { + "type": "git", + "url": "git+https://github.com/jonschlinkert/ansi-gray.git" + }, + "scripts": { + "test": "mocha" + }, + "version": "0.1.1" +} diff --git a/node_modules/ansi-gray/readme.md b/node_modules/ansi-gray/readme.md new file mode 100644 index 0000000000..9b59a29a1e --- /dev/null +++ b/node_modules/ansi-gray/readme.md @@ -0,0 +1,74 @@ +# ansi-gray [![NPM version](https://badge.fury.io/js/ansi-gray.svg)](http://badge.fury.io/js/ansi-gray) + +> The color gray, in ansi. + +## Install + +Install with [npm](https://www.npmjs.com/) + +```sh +$ npm i ansi-gray --save +``` + +## Usage + +```js +var gray = require('ansi-gray'); +``` + +## Related projects + +* [ansi-reset](https://github.com/jonschlinkert/ansi-reset) +* [ansi-bold](https://github.com/jonschlinkert/ansi-bold) +* [ansi-dim](https://github.com/jonschlinkert/ansi-dim) +* [ansi-italic](https://github.com/jonschlinkert/ansi-italic) +* [ansi-underline](https://github.com/jonschlinkert/ansi-underline) +* [ansi-inverse](https://github.com/jonschlinkert/ansi-inverse) +* [ansi-hidden](https://github.com/jonschlinkert/ansi-hidden) +* [ansi-strikethrough](https://github.com/jonschlinkert/ansi-strikethrough) +* [ansi-black](https://github.com/jonschlinkert/ansi-black) +* [ansi-red](https://github.com/jonschlinkert/ansi-red) +* [ansi-green](https://github.com/jonschlinkert/ansi-green) +* [ansi-yellow](https://github.com/jonschlinkert/ansi-yellow) +* [ansi-blue](https://github.com/jonschlinkert/ansi-blue) +* [ansi-magenta](https://github.com/jonschlinkert/ansi-magenta) +* [ansi-cyan](https://github.com/jonschlinkert/ansi-cyan) +* [ansi-white](https://github.com/jonschlinkert/ansi-white) +* [ansi-gray](https://github.com/jonschlinkert/ansi-gray) +* [ansi-grey](https://github.com/jonschlinkert/ansi-grey) +* [ansi-bgblack](https://github.com/jonschlinkert/ansi-bgblack) +* [ansi-bgred](https://github.com/jonschlinkert/ansi-bgred) +* [ansi-bggreen](https://github.com/jonschlinkert/ansi-bggreen) +* [ansi-bgyellow](https://github.com/jonschlinkert/ansi-bgyellow) +* [ansi-bgblue](https://github.com/jonschlinkert/ansi-bgblue) +* [ansi-bgmagenta](https://github.com/jonschlinkert/ansi-bgmagenta) +* [ansi-bgcyan](https://github.com/jonschlinkert/ansi-bgcyan) +* [ansi-bgwhite](https://github.com/jonschlinkert/ansi-bgwhite) + +## Running tests + +Install dev dependencies: + +```sh +$ npm i -d && npm test +``` + +## Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](https://github.com/jonschlinkert/ansi-gray/issues/new) + +## Author + +**Jon Schlinkert** + ++ [github/jonschlinkert](https://github.com/jonschlinkert) ++ [twitter/jonschlinkert](http://twitter.com/jonschlinkert) + +## License + +Copyright © 2015 Jon Schlinkert +Released under the MIT license. + +*** + +_This file was generated by [verb-cli](https://github.com/assemble/verb-cli) on May 21, 2015._ \ No newline at end of file diff --git a/node_modules/ansi-regex/index.js b/node_modules/ansi-regex/index.js new file mode 100644 index 0000000000..b9574ed7e8 --- /dev/null +++ b/node_modules/ansi-regex/index.js @@ -0,0 +1,4 @@ +'use strict'; +module.exports = function () { + return /[\u001b\u009b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-PRZcf-nqry=><]/g; +}; diff --git a/node_modules/ansi-regex/license b/node_modules/ansi-regex/license new file mode 100644 index 0000000000..654d0bfe94 --- /dev/null +++ b/node_modules/ansi-regex/license @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) Sindre Sorhus (sindresorhus.com) + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/ansi-regex/package.json b/node_modules/ansi-regex/package.json new file mode 100644 index 0000000000..42e4264842 --- /dev/null +++ b/node_modules/ansi-regex/package.json @@ -0,0 +1,108 @@ +{ + "_from": "ansi-regex@^2.0.0", + "_id": "ansi-regex@2.1.1", + "_inBundle": false, + "_integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=", + "_location": "/ansi-regex", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "ansi-regex@^2.0.0", + "name": "ansi-regex", + "escapedName": "ansi-regex", + "rawSpec": "^2.0.0", + "saveSpec": null, + "fetchSpec": "^2.0.0" + }, + "_requiredBy": [ + "/strip-ansi" + ], + "_resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", + "_shasum": "c3b33ab5ee360d86e0e628f0468ae7ef27d654df", + "_spec": "ansi-regex@^2.0.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/strip-ansi", + "author": { + "name": "Sindre Sorhus", + "email": "sindresorhus@gmail.com", + "url": "sindresorhus.com" + }, + "bugs": { + "url": "https://github.com/chalk/ansi-regex/issues" + }, + "bundleDependencies": false, + "deprecated": false, + "description": "Regular expression for matching ANSI escape codes", + "devDependencies": { + "ava": "0.17.0", + "xo": "0.16.0" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/chalk/ansi-regex#readme", + "keywords": [ + "ansi", + "styles", + "color", + "colour", + "colors", + "terminal", + "console", + "cli", + "string", + "tty", + "escape", + "formatting", + "rgb", + "256", + "shell", + "xterm", + "command-line", + "text", + "regex", + "regexp", + "re", + "match", + "test", + "find", + "pattern" + ], + "license": "MIT", + "maintainers": [ + { + "name": "Sindre Sorhus", + "email": "sindresorhus@gmail.com", + "url": "sindresorhus.com" + }, + { + "name": "Joshua Appelman", + "email": "jappelman@xebia.com", + "url": "jbnicolai.com" + }, + { + "name": "JD Ballard", + "email": "i.am.qix@gmail.com", + "url": "github.com/qix-" + } + ], + "name": "ansi-regex", + "repository": { + "type": "git", + "url": "git+https://github.com/chalk/ansi-regex.git" + }, + "scripts": { + "test": "xo && ava --verbose", + "view-supported": "node fixtures/view-codes.js" + }, + "version": "2.1.1", + "xo": { + "rules": { + "guard-for-in": 0, + "no-loop-func": 0 + } + } +} diff --git a/node_modules/ansi-regex/readme.md b/node_modules/ansi-regex/readme.md new file mode 100644 index 0000000000..6a928edf0f --- /dev/null +++ b/node_modules/ansi-regex/readme.md @@ -0,0 +1,39 @@ +# ansi-regex [![Build Status](https://travis-ci.org/chalk/ansi-regex.svg?branch=master)](https://travis-ci.org/chalk/ansi-regex) + +> Regular expression for matching [ANSI escape codes](http://en.wikipedia.org/wiki/ANSI_escape_code) + + +## Install + +``` +$ npm install --save ansi-regex +``` + + +## Usage + +```js +const ansiRegex = require('ansi-regex'); + +ansiRegex().test('\u001b[4mcake\u001b[0m'); +//=> true + +ansiRegex().test('cake'); +//=> false + +'\u001b[4mcake\u001b[0m'.match(ansiRegex()); +//=> ['\u001b[4m', '\u001b[0m'] +``` + +## FAQ + +### Why do you test for codes not in the ECMA 48 standard? + +Some of the codes we run as a test are codes that we acquired finding various lists of non-standard or manufacturer specific codes. If I recall correctly, we test for both standard and non-standard codes, as most of them follow the same or similar format and can be safely matched in strings without the risk of removing actual string content. There are a few non-standard control codes that do not follow the traditional format (i.e. they end in numbers) thus forcing us to exclude them from the test because we cannot reliably match them. + +On the historical side, those ECMA standards were established in the early 90's whereas the VT100, for example, was designed in the mid/late 70's. At that point in time, control codes were still pretty ungoverned and engineers used them for a multitude of things, namely to activate hardware ports that may have been proprietary. Somewhere else you see a similar 'anarchy' of codes is in the x86 architecture for processors; there are a ton of "interrupts" that can mean different things on certain brands of processors, most of which have been phased out. + + +## License + +MIT © [Sindre Sorhus](http://sindresorhus.com) diff --git a/node_modules/ansi-styles/index.js b/node_modules/ansi-styles/index.js new file mode 100644 index 0000000000..90a871c4d7 --- /dev/null +++ b/node_modules/ansi-styles/index.js @@ -0,0 +1,165 @@ +'use strict'; +const colorConvert = require('color-convert'); + +const wrapAnsi16 = (fn, offset) => function () { + const code = fn.apply(colorConvert, arguments); + return `\u001B[${code + offset}m`; +}; + +const wrapAnsi256 = (fn, offset) => function () { + const code = fn.apply(colorConvert, arguments); + return `\u001B[${38 + offset};5;${code}m`; +}; + +const wrapAnsi16m = (fn, offset) => function () { + const rgb = fn.apply(colorConvert, arguments); + return `\u001B[${38 + offset};2;${rgb[0]};${rgb[1]};${rgb[2]}m`; +}; + +function assembleStyles() { + const codes = new Map(); + const styles = { + modifier: { + reset: [0, 0], + // 21 isn't widely supported and 22 does the same thing + bold: [1, 22], + dim: [2, 22], + italic: [3, 23], + underline: [4, 24], + inverse: [7, 27], + hidden: [8, 28], + strikethrough: [9, 29] + }, + color: { + black: [30, 39], + red: [31, 39], + green: [32, 39], + yellow: [33, 39], + blue: [34, 39], + magenta: [35, 39], + cyan: [36, 39], + white: [37, 39], + gray: [90, 39], + + // Bright color + redBright: [91, 39], + greenBright: [92, 39], + yellowBright: [93, 39], + blueBright: [94, 39], + magentaBright: [95, 39], + cyanBright: [96, 39], + whiteBright: [97, 39] + }, + bgColor: { + bgBlack: [40, 49], + bgRed: [41, 49], + bgGreen: [42, 49], + bgYellow: [43, 49], + bgBlue: [44, 49], + bgMagenta: [45, 49], + bgCyan: [46, 49], + bgWhite: [47, 49], + + // Bright color + bgBlackBright: [100, 49], + bgRedBright: [101, 49], + bgGreenBright: [102, 49], + bgYellowBright: [103, 49], + bgBlueBright: [104, 49], + bgMagentaBright: [105, 49], + bgCyanBright: [106, 49], + bgWhiteBright: [107, 49] + } + }; + + // Fix humans + styles.color.grey = styles.color.gray; + + for (const groupName of Object.keys(styles)) { + const group = styles[groupName]; + + for (const styleName of Object.keys(group)) { + const style = group[styleName]; + + styles[styleName] = { + open: `\u001B[${style[0]}m`, + close: `\u001B[${style[1]}m` + }; + + group[styleName] = styles[styleName]; + + codes.set(style[0], style[1]); + } + + Object.defineProperty(styles, groupName, { + value: group, + enumerable: false + }); + + Object.defineProperty(styles, 'codes', { + value: codes, + enumerable: false + }); + } + + const ansi2ansi = n => n; + const rgb2rgb = (r, g, b) => [r, g, b]; + + styles.color.close = '\u001B[39m'; + styles.bgColor.close = '\u001B[49m'; + + styles.color.ansi = { + ansi: wrapAnsi16(ansi2ansi, 0) + }; + styles.color.ansi256 = { + ansi256: wrapAnsi256(ansi2ansi, 0) + }; + styles.color.ansi16m = { + rgb: wrapAnsi16m(rgb2rgb, 0) + }; + + styles.bgColor.ansi = { + ansi: wrapAnsi16(ansi2ansi, 10) + }; + styles.bgColor.ansi256 = { + ansi256: wrapAnsi256(ansi2ansi, 10) + }; + styles.bgColor.ansi16m = { + rgb: wrapAnsi16m(rgb2rgb, 10) + }; + + for (let key of Object.keys(colorConvert)) { + if (typeof colorConvert[key] !== 'object') { + continue; + } + + const suite = colorConvert[key]; + + if (key === 'ansi16') { + key = 'ansi'; + } + + if ('ansi16' in suite) { + styles.color.ansi[key] = wrapAnsi16(suite.ansi16, 0); + styles.bgColor.ansi[key] = wrapAnsi16(suite.ansi16, 10); + } + + if ('ansi256' in suite) { + styles.color.ansi256[key] = wrapAnsi256(suite.ansi256, 0); + styles.bgColor.ansi256[key] = wrapAnsi256(suite.ansi256, 10); + } + + if ('rgb' in suite) { + styles.color.ansi16m[key] = wrapAnsi16m(suite.rgb, 0); + styles.bgColor.ansi16m[key] = wrapAnsi16m(suite.rgb, 10); + } + } + + return styles; +} + +// Make the export immutable +Object.defineProperty(module, 'exports', { + enumerable: true, + get: assembleStyles +}); diff --git a/node_modules/ansi-styles/license b/node_modules/ansi-styles/license new file mode 100644 index 0000000000..e7af2f7710 --- /dev/null +++ b/node_modules/ansi-styles/license @@ -0,0 +1,9 @@ +MIT License + +Copyright (c) Sindre Sorhus (sindresorhus.com) + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/node_modules/ansi-styles/package.json b/node_modules/ansi-styles/package.json new file mode 100644 index 0000000000..8f23a72cb1 --- /dev/null +++ b/node_modules/ansi-styles/package.json @@ -0,0 +1,88 @@ +{ + "_from": "ansi-styles@^3.2.1", + "_id": "ansi-styles@3.2.1", + "_inBundle": false, + "_integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "_location": "/ansi-styles", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "ansi-styles@^3.2.1", + "name": "ansi-styles", + "escapedName": "ansi-styles", + "rawSpec": "^3.2.1", + "saveSpec": null, + "fetchSpec": "^3.2.1" + }, + "_requiredBy": [ + "/chalk" + ], + "_resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "_shasum": "41fbb20243e50b12be0f04b8dedbf07520ce841d", + "_spec": "ansi-styles@^3.2.1", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/chalk", + "author": { + "name": "Sindre Sorhus", + "email": "sindresorhus@gmail.com", + "url": "sindresorhus.com" + }, + "ava": { + "require": "babel-polyfill" + }, + "bugs": { + "url": "https://github.com/chalk/ansi-styles/issues" + }, + "bundleDependencies": false, + "dependencies": { + "color-convert": "^1.9.0" + }, + "deprecated": false, + "description": "ANSI escape codes for styling strings in the terminal", + "devDependencies": { + "ava": "*", + "babel-polyfill": "^6.23.0", + "svg-term-cli": "^2.1.1", + "xo": "*" + }, + "engines": { + "node": ">=4" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/chalk/ansi-styles#readme", + "keywords": [ + "ansi", + "styles", + "color", + "colour", + "colors", + "terminal", + "console", + "cli", + "string", + "tty", + "escape", + "formatting", + "rgb", + "256", + "shell", + "xterm", + "log", + "logging", + "command-line", + "text" + ], + "license": "MIT", + "name": "ansi-styles", + "repository": { + "type": "git", + "url": "git+https://github.com/chalk/ansi-styles.git" + }, + "scripts": { + "screenshot": "svg-term --command='node screenshot' --out=screenshot.svg --padding=3 --width=55 --height=3 --at=1000 --no-cursor", + "test": "xo && ava" + }, + "version": "3.2.1" +} diff --git a/node_modules/ansi-styles/readme.md b/node_modules/ansi-styles/readme.md new file mode 100644 index 0000000000..3158e2df59 --- /dev/null +++ b/node_modules/ansi-styles/readme.md @@ -0,0 +1,147 @@ +# ansi-styles [![Build Status](https://travis-ci.org/chalk/ansi-styles.svg?branch=master)](https://travis-ci.org/chalk/ansi-styles) + +> [ANSI escape codes](http://en.wikipedia.org/wiki/ANSI_escape_code#Colors_and_Styles) for styling strings in the terminal + +You probably want the higher-level [chalk](https://github.com/chalk/chalk) module for styling your strings. + + + + +## Install + +``` +$ npm install ansi-styles +``` + + +## Usage + +```js +const style = require('ansi-styles'); + +console.log(`${style.green.open}Hello world!${style.green.close}`); + + +// Color conversion between 16/256/truecolor +// NOTE: If conversion goes to 16 colors or 256 colors, the original color +// may be degraded to fit that color palette. This means terminals +// that do not support 16 million colors will best-match the +// original color. +console.log(style.bgColor.ansi.hsl(120, 80, 72) + 'Hello world!' + style.bgColor.close); +console.log(style.color.ansi256.rgb(199, 20, 250) + 'Hello world!' + style.color.close); +console.log(style.color.ansi16m.hex('#ABCDEF') + 'Hello world!' + style.color.close); +``` + +## API + +Each style has an `open` and `close` property. + + +## Styles + +### Modifiers + +- `reset` +- `bold` +- `dim` +- `italic` *(Not widely supported)* +- `underline` +- `inverse` +- `hidden` +- `strikethrough` *(Not widely supported)* + +### Colors + +- `black` +- `red` +- `green` +- `yellow` +- `blue` +- `magenta` +- `cyan` +- `white` +- `gray` ("bright black") +- `redBright` +- `greenBright` +- `yellowBright` +- `blueBright` +- `magentaBright` +- `cyanBright` +- `whiteBright` + +### Background colors + +- `bgBlack` +- `bgRed` +- `bgGreen` +- `bgYellow` +- `bgBlue` +- `bgMagenta` +- `bgCyan` +- `bgWhite` +- `bgBlackBright` +- `bgRedBright` +- `bgGreenBright` +- `bgYellowBright` +- `bgBlueBright` +- `bgMagentaBright` +- `bgCyanBright` +- `bgWhiteBright` + + +## Advanced usage + +By default, you get a map of styles, but the styles are also available as groups. They are non-enumerable so they don't show up unless you access them explicitly. This makes it easier to expose only a subset in a higher-level module. + +- `style.modifier` +- `style.color` +- `style.bgColor` + +###### Example + +```js +console.log(style.color.green.open); +``` + +Raw escape codes (i.e. without the CSI escape prefix `\u001B[` and render mode postfix `m`) are available under `style.codes`, which returns a `Map` with the open codes as keys and close codes as values. + +###### Example + +```js +console.log(style.codes.get(36)); +//=> 39 +``` + + +## [256 / 16 million (TrueColor) support](https://gist.github.com/XVilka/8346728) + +`ansi-styles` uses the [`color-convert`](https://github.com/Qix-/color-convert) package to allow for converting between various colors and ANSI escapes, with support for 256 and 16 million colors. + +To use these, call the associated conversion function with the intended output, for example: + +```js +style.color.ansi.rgb(100, 200, 15); // RGB to 16 color ansi foreground code +style.bgColor.ansi.rgb(100, 200, 15); // RGB to 16 color ansi background code + +style.color.ansi256.hsl(120, 100, 60); // HSL to 256 color ansi foreground code +style.bgColor.ansi256.hsl(120, 100, 60); // HSL to 256 color ansi foreground code + +style.color.ansi16m.hex('#C0FFEE'); // Hex (RGB) to 16 million color foreground code +style.bgColor.ansi16m.hex('#C0FFEE'); // Hex (RGB) to 16 million color background code +``` + + +## Related + +- [ansi-escapes](https://github.com/sindresorhus/ansi-escapes) - ANSI escape codes for manipulating the terminal + + +## Maintainers + +- [Sindre Sorhus](https://github.com/sindresorhus) +- [Josh Junon](https://github.com/qix-) + + +## License + +MIT diff --git a/node_modules/ansi-wrap/LICENSE b/node_modules/ansi-wrap/LICENSE new file mode 100644 index 0000000000..65f90aca8c --- /dev/null +++ b/node_modules/ansi-wrap/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2015, Jon Schlinkert. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/ansi-wrap/README.md b/node_modules/ansi-wrap/README.md new file mode 100644 index 0000000000..032c1e6b2e --- /dev/null +++ b/node_modules/ansi-wrap/README.md @@ -0,0 +1,89 @@ +# ansi-wrap [![NPM version](https://badge.fury.io/js/ansi-wrap.svg)](http://badge.fury.io/js/ansi-wrap) + +> Create ansi colors by passing the open and close codes. + +## Install + +Install with [npm](https://www.npmjs.com/) + +```sh +$ npm i ansi-wrap --save +``` + +## Usage + +```js +var wrap = require('ansi-wrap'); +``` + +**Example** + +Pass codes for [ansi magenta background](https://github.com/jonschlinkert/ansi-bgmagenta): + +```js +console.log(wrap(45, 49, 'This is a message...')); +//=> '\u001b[45mfoo\u001b[49m' +``` + +Which prints out... + +[![screen shot 2015-05-21 at 8 28 32 pm](https://cloud.githubusercontent.com/assets/383994/7761769/12488afa-fff8-11e4-9cc1-71a8a6ec14a4.png)](https://www.npmjs.com/) + +## Related projects + +This is used in these projects: + +* [ansi-reset](https://github.com/jonschlinkert/ansi-reset) +* [ansi-bold](https://github.com/jonschlinkert/ansi-bold) +* [ansi-dim](https://github.com/jonschlinkert/ansi-dim) +* [ansi-italic](https://github.com/jonschlinkert/ansi-italic) +* [ansi-underline](https://github.com/jonschlinkert/ansi-underline) +* [ansi-inverse](https://github.com/jonschlinkert/ansi-inverse) +* [ansi-hidden](https://github.com/jonschlinkert/ansi-hidden) +* [ansi-strikethrough](https://github.com/jonschlinkert/ansi-strikethrough) +* [ansi-black](https://github.com/jonschlinkert/ansi-black) +* [ansi-red](https://github.com/jonschlinkert/ansi-red) +* [ansi-green](https://github.com/jonschlinkert/ansi-green) +* [ansi-yellow](https://github.com/jonschlinkert/ansi-yellow) +* [ansi-blue](https://github.com/jonschlinkert/ansi-blue) +* [ansi-magenta](https://github.com/jonschlinkert/ansi-magenta) +* [ansi-cyan](https://github.com/jonschlinkert/ansi-cyan) +* [ansi-white](https://github.com/jonschlinkert/ansi-white) +* [ansi-gray](https://github.com/jonschlinkert/ansi-gray) +* [ansi-grey](https://github.com/jonschlinkert/ansi-grey) +* [ansi-bgblack](https://github.com/jonschlinkert/ansi-bgblack) +* [ansi-bgred](https://github.com/jonschlinkert/ansi-bgred) +* [ansi-bggreen](https://github.com/jonschlinkert/ansi-bggreen) +* [ansi-bgyellow](https://github.com/jonschlinkert/ansi-bgyellow) +* [ansi-bgblue](https://github.com/jonschlinkert/ansi-bgblue) +* [ansi-bgmagenta](https://github.com/jonschlinkert/ansi-bgmagenta) +* [ansi-bgcyan](https://github.com/jonschlinkert/ansi-bgcyan) +* [ansi-bgwhite](https://github.com/jonschlinkert/ansi-bgwhite) + +## Running tests + +Install dev dependencies: + +```sh +$ npm i -d && npm test +``` + +## Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](https://github.com/jonschlinkert/ansi-wrap/issues/new) + +## Author + +**Jon Schlinkert** + ++ [github/jonschlinkert](https://github.com/jonschlinkert) ++ [twitter/jonschlinkert](http://twitter.com/jonschlinkert) + +## License + +Copyright © 2015 Jon Schlinkert +Released under the MIT license. + +*** + +_This file was generated by [verb-cli](https://github.com/assemble/verb-cli) on May 21, 2015._ \ No newline at end of file diff --git a/node_modules/ansi-wrap/index.js b/node_modules/ansi-wrap/index.js new file mode 100644 index 0000000000..ffc52d75cc --- /dev/null +++ b/node_modules/ansi-wrap/index.js @@ -0,0 +1,5 @@ +'use strict'; + +module.exports = function(a, b, msg) { + return '\u001b['+ a + 'm' + msg + '\u001b[' + b + 'm'; +}; diff --git a/node_modules/ansi-wrap/package.json b/node_modules/ansi-wrap/package.json new file mode 100644 index 0000000000..65ac439659 --- /dev/null +++ b/node_modules/ansi-wrap/package.json @@ -0,0 +1,60 @@ +{ + "_from": "ansi-wrap@^0.1.0", + "_id": "ansi-wrap@0.1.0", + "_inBundle": false, + "_integrity": "sha1-qCJQ3bABXponyoLoLqYDu/pF768=", + "_location": "/ansi-wrap", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "ansi-wrap@^0.1.0", + "name": "ansi-wrap", + "escapedName": "ansi-wrap", + "rawSpec": "^0.1.0", + "saveSpec": null, + "fetchSpec": "^0.1.0" + }, + "_requiredBy": [ + "/ansi-colors", + "/ansi-gray" + ], + "_resolved": "https://registry.npmjs.org/ansi-wrap/-/ansi-wrap-0.1.0.tgz", + "_shasum": "a82250ddb0015e9a27ca82e82ea603bbfa45efaf", + "_spec": "ansi-wrap@^0.1.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/ansi-colors", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/jonschlinkert/ansi-wrap/issues" + }, + "bundleDependencies": false, + "dependencies": {}, + "deprecated": false, + "description": "Create ansi colors by passing the open and close codes.", + "devDependencies": {}, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/jonschlinkert/ansi-wrap", + "keywords": [], + "license": { + "type": "MIT", + "url": "https://github.com/jonschlinkert/ansi-wrap/blob/master/LICENSE" + }, + "main": "index.js", + "name": "ansi-wrap", + "repository": { + "type": "git", + "url": "git+https://github.com/jonschlinkert/ansi-wrap.git" + }, + "scripts": { + "test": "mocha" + }, + "version": "0.1.0" +} diff --git a/node_modules/anymatch/LICENSE b/node_modules/anymatch/LICENSE new file mode 100644 index 0000000000..bc424705fb --- /dev/null +++ b/node_modules/anymatch/LICENSE @@ -0,0 +1,15 @@ +The ISC License + +Copyright (c) 2014 Elan Shanker + +Permission to use, copy, modify, and/or distribute this software for any +purpose with or without fee is hereby granted, provided that the above +copyright notice and this permission notice appear in all copies. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR +IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. diff --git a/node_modules/anymatch/README.md b/node_modules/anymatch/README.md new file mode 100644 index 0000000000..f674f407cf --- /dev/null +++ b/node_modules/anymatch/README.md @@ -0,0 +1,99 @@ +anymatch [![Build Status](https://travis-ci.org/micromatch/anymatch.svg?branch=master)](https://travis-ci.org/micromatch/anymatch) [![Coverage Status](https://img.shields.io/coveralls/micromatch/anymatch.svg?branch=master)](https://coveralls.io/r/micromatch/anymatch?branch=master) +====== +Javascript module to match a string against a regular expression, glob, string, +or function that takes the string as an argument and returns a truthy or falsy +value. The matcher can also be an array of any or all of these. Useful for +allowing a very flexible user-defined config to define things like file paths. + +__Note: This module has Bash-parity, please be aware that Windows-style backslashes are not supported as separators. See https://github.com/micromatch/micromatch#backslashes for more information.__ + +[![NPM](https://nodei.co/npm/anymatch.png?downloads=true&downloadRank=true&stars=true)](https://nodei.co/npm/anymatch/) +[![NPM](https://nodei.co/npm-dl/anymatch.png?height=3&months=9)](https://nodei.co/npm-dl/anymatch/) + +Usage +----- +```sh +npm install anymatch --save +``` + +#### anymatch (matchers, testString, [returnIndex], [startIndex], [endIndex]) +* __matchers__: (_Array|String|RegExp|Function_) +String to be directly matched, string with glob patterns, regular expression +test, function that takes the testString as an argument and returns a truthy +value if it should be matched, or an array of any number and mix of these types. +* __testString__: (_String|Array_) The string to test against the matchers. If +passed as an array, the first element of the array will be used as the +`testString` for non-function matchers, while the entire array will be applied +as the arguments for function matchers. +* __returnIndex__: (_Boolean [optional]_) If true, return the array index of +the first matcher that that testString matched, or -1 if no match, instead of a +boolean result. +* __startIndex, endIndex__: (_Integer [optional]_) Can be used to define a +subset out of the array of provided matchers to test against. Can be useful +with bound matcher functions (see below). When used with `returnIndex = true` +preserves original indexing. Behaves the same as `Array.prototype.slice` (i.e. +includes array members up to, but not including endIndex). + +```js +var anymatch = require('anymatch'); + +var matchers = [ + 'path/to/file.js', + 'path/anyjs/**/*.js', + /foo\.js$/, + function (string) { + return string.indexOf('bar') !== -1 && string.length > 10 + } +]; + +anymatch(matchers, 'path/to/file.js'); // true +anymatch(matchers, 'path/anyjs/baz.js'); // true +anymatch(matchers, 'path/to/foo.js'); // true +anymatch(matchers, 'path/to/bar.js'); // true +anymatch(matchers, 'bar.js'); // false + +// returnIndex = true +anymatch(matchers, 'foo.js', true); // 2 +anymatch(matchers, 'path/anyjs/foo.js', true); // 1 + +// skip matchers +anymatch(matchers, 'path/to/file.js', false, 1); // false +anymatch(matchers, 'path/anyjs/foo.js', true, 2, 3); // 2 +anymatch(matchers, 'path/to/bar.js', true, 0, 3); // -1 + +// using globs to match directories and their children +anymatch('node_modules', 'node_modules'); // true +anymatch('node_modules', 'node_modules/somelib/index.js'); // false +anymatch('node_modules/**', 'node_modules/somelib/index.js'); // true +anymatch('node_modules/**', '/absolute/path/to/node_modules/somelib/index.js'); // false +anymatch('**/node_modules/**', '/absolute/path/to/node_modules/somelib/index.js'); // true +``` + +#### anymatch (matchers) +You can also pass in only your matcher(s) to get a curried function that has +already been bound to the provided matching criteria. This can be used as an +`Array.prototype.filter` callback. + +```js +var matcher = anymatch(matchers); + +matcher('path/to/file.js'); // true +matcher('path/anyjs/baz.js', true); // 1 +matcher('path/anyjs/baz.js', true, 2); // -1 + +['foo.js', 'bar.js'].filter(matcher); // ['foo.js'] +``` + +Change Log +---------- +[See release notes page on GitHub](https://github.com/micromatch/anymatch/releases) + +NOTE: As of v2.0.0, [micromatch](https://github.com/jonschlinkert/micromatch) moves away from minimatch-parity and inline with Bash. This includes handling backslashes differently (see https://github.com/micromatch/micromatch#backslashes for more information). + +NOTE: As of v1.2.0, anymatch uses [micromatch](https://github.com/jonschlinkert/micromatch) +for glob pattern matching. Issues with glob pattern matching should be +reported directly to the [micromatch issue tracker](https://github.com/jonschlinkert/micromatch/issues). + +License +------- +[ISC](https://raw.github.com/micromatch/anymatch/master/LICENSE) diff --git a/node_modules/anymatch/index.js b/node_modules/anymatch/index.js new file mode 100644 index 0000000000..e411618506 --- /dev/null +++ b/node_modules/anymatch/index.js @@ -0,0 +1,67 @@ +'use strict'; + +var micromatch = require('micromatch'); +var normalize = require('normalize-path'); +var path = require('path'); // required for tests. +var arrify = function(a) { return a == null ? [] : (Array.isArray(a) ? a : [a]); }; + +var anymatch = function(criteria, value, returnIndex, startIndex, endIndex) { + criteria = arrify(criteria); + value = arrify(value); + if (arguments.length === 1) { + return anymatch.bind(null, criteria.map(function(criterion) { + return typeof criterion === 'string' && criterion[0] !== '!' ? + micromatch.matcher(criterion) : criterion; + })); + } + startIndex = startIndex || 0; + var string = value[0]; + var altString, altValue; + var matched = false; + var matchIndex = -1; + function testCriteria(criterion, index) { + var result; + switch (Object.prototype.toString.call(criterion)) { + case '[object String]': + result = string === criterion || altString && altString === criterion; + result = result || micromatch.isMatch(string, criterion); + break; + case '[object RegExp]': + result = criterion.test(string) || altString && criterion.test(altString); + break; + case '[object Function]': + result = criterion.apply(null, value); + result = result || altValue && criterion.apply(null, altValue); + break; + default: + result = false; + } + if (result) { + matchIndex = index + startIndex; + } + return result; + } + var crit = criteria; + var negGlobs = crit.reduce(function(arr, criterion, index) { + if (typeof criterion === 'string' && criterion[0] === '!') { + if (crit === criteria) { + // make a copy before modifying + crit = crit.slice(); + } + crit[index] = null; + arr.push(criterion.substr(1)); + } + return arr; + }, []); + if (!negGlobs.length || !micromatch.any(string, negGlobs)) { + if (path.sep === '\\' && typeof string === 'string') { + altString = normalize(string); + altString = altString === string ? null : altString; + if (altString) altValue = [altString].concat(value.slice(1)); + } + matched = crit.slice(startIndex, endIndex).some(testCriteria); + } + return returnIndex === true ? matchIndex : matched; +}; + +module.exports = anymatch; diff --git a/node_modules/anymatch/node_modules/extglob/LICENSE b/node_modules/anymatch/node_modules/extglob/LICENSE new file mode 100644 index 0000000000..e33d14b754 --- /dev/null +++ b/node_modules/anymatch/node_modules/extglob/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2015-2017, Jon Schlinkert. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/anymatch/node_modules/extglob/README.md b/node_modules/anymatch/node_modules/extglob/README.md new file mode 100644 index 0000000000..3255ea2b78 --- /dev/null +++ b/node_modules/anymatch/node_modules/extglob/README.md @@ -0,0 +1,362 @@ +# extglob [![NPM version](https://img.shields.io/npm/v/extglob.svg?style=flat)](https://www.npmjs.com/package/extglob) [![NPM monthly downloads](https://img.shields.io/npm/dm/extglob.svg?style=flat)](https://npmjs.org/package/extglob) [![NPM total downloads](https://img.shields.io/npm/dt/extglob.svg?style=flat)](https://npmjs.org/package/extglob) [![Linux Build Status](https://img.shields.io/travis/micromatch/extglob.svg?style=flat&label=Travis)](https://travis-ci.org/micromatch/extglob) [![Windows Build Status](https://img.shields.io/appveyor/ci/micromatch/extglob.svg?style=flat&label=AppVeyor)](https://ci.appveyor.com/project/micromatch/extglob) + +> Extended glob support for JavaScript. Adds (almost) the expressive power of regular expressions to glob patterns. + +Please consider following this project's author, [Jon Schlinkert](https://github.com/jonschlinkert), and consider starring the project to show your :heart: and support. + +## Install + +Install with [npm](https://www.npmjs.com/): + +```sh +$ npm install --save extglob +``` + +* Convert an extglob string to a regex-compatible string. +* More complete (and correct) support than [minimatch](https://github.com/isaacs/minimatch) (minimatch fails a large percentage of the extglob tests) +* Handles [negation patterns](#extglob-patterns) +* Handles [nested patterns](#extglob-patterns) +* Organized code base, easy to maintain and make changes when edge cases arise +* As you can see by the [benchmarks](#benchmarks), extglob doesn't pay with speed for it's completeness, accuracy and quality. + +**Heads up!**: This library only supports extglobs, to handle full glob patterns and other extended globbing features use [micromatch](https://github.com/jonschlinkert/micromatch) instead. + +## Usage + +The main export is a function that takes a string and options, and returns an object with the parsed AST and the compiled `.output`, which is a regex-compatible string that can be used for matching. + +```js +var extglob = require('extglob'); +console.log(extglob('!(xyz)*.js')); +``` + +## Extglob cheatsheet + +Extended globbing patterns can be defined as follows (as described by the [bash man page](https://www.gnu.org/software/bash/manual/html_node/Pattern-Matching.html)): + +| **pattern** | **regex equivalent** | **description** | +| --- | --- | --- | +| `?(pattern-list)` | `(...|...)?` | Matches zero or one occurrence of the given pattern(s) | +| `*(pattern-list)` | `(...|...)*` | Matches zero or more occurrences of the given pattern(s) | +| `+(pattern-list)` | `(...|...)+` | Matches one or more occurrences of the given pattern(s) | +| `@(pattern-list)` | `(...|...)` [1] | Matches one of the given pattern(s) | +| `!(pattern-list)` | N/A | Matches anything except one of the given pattern(s) | + +## API + +### [extglob](index.js#L36) + +Convert the given `extglob` pattern into a regex-compatible string. Returns an object with the compiled result and the parsed AST. + +**Params** + +* `pattern` **{String}** +* `options` **{Object}** +* `returns` **{String}** + +**Example** + +```js +var extglob = require('extglob'); +console.log(extglob('*.!(*a)')); +//=> '(?!\\.)[^/]*?\\.(?!(?!\\.)[^/]*?a\\b).*?' +``` + +### [.match](index.js#L56) + +Takes an array of strings and an extglob pattern and returns a new array that contains only the strings that match the pattern. + +**Params** + +* `list` **{Array}**: Array of strings to match +* `pattern` **{String}**: Extglob pattern +* `options` **{Object}** +* `returns` **{Array}**: Returns an array of matches + +**Example** + +```js +var extglob = require('extglob'); +console.log(extglob.match(['a.a', 'a.b', 'a.c'], '*.!(*a)')); +//=> ['a.b', 'a.c'] +``` + +### [.isMatch](index.js#L111) + +Returns true if the specified `string` matches the given extglob `pattern`. + +**Params** + +* `string` **{String}**: String to match +* `pattern` **{String}**: Extglob pattern +* `options` **{String}** +* `returns` **{Boolean}** + +**Example** + +```js +var extglob = require('extglob'); + +console.log(extglob.isMatch('a.a', '*.!(*a)')); +//=> false +console.log(extglob.isMatch('a.b', '*.!(*a)')); +//=> true +``` + +### [.contains](index.js#L150) + +Returns true if the given `string` contains the given pattern. Similar to `.isMatch` but the pattern can match any part of the string. + +**Params** + +* `str` **{String}**: The string to match. +* `pattern` **{String}**: Glob pattern to use for matching. +* `options` **{Object}** +* `returns` **{Boolean}**: Returns true if the patter matches any part of `str`. + +**Example** + +```js +var extglob = require('extglob'); +console.log(extglob.contains('aa/bb/cc', '*b')); +//=> true +console.log(extglob.contains('aa/bb/cc', '*d')); +//=> false +``` + +### [.matcher](index.js#L184) + +Takes an extglob pattern and returns a matcher function. The returned function takes the string to match as its only argument. + +**Params** + +* `pattern` **{String}**: Extglob pattern +* `options` **{String}** +* `returns` **{Boolean}** + +**Example** + +```js +var extglob = require('extglob'); +var isMatch = extglob.matcher('*.!(*a)'); + +console.log(isMatch('a.a')); +//=> false +console.log(isMatch('a.b')); +//=> true +``` + +### [.create](index.js#L214) + +Convert the given `extglob` pattern into a regex-compatible string. Returns an object with the compiled result and the parsed AST. + +**Params** + +* `str` **{String}** +* `options` **{Object}** +* `returns` **{String}** + +**Example** + +```js +var extglob = require('extglob'); +console.log(extglob.create('*.!(*a)').output); +//=> '(?!\\.)[^/]*?\\.(?!(?!\\.)[^/]*?a\\b).*?' +``` + +### [.capture](index.js#L248) + +Returns an array of matches captured by `pattern` in `string`, or `null` if the pattern did not match. + +**Params** + +* `pattern` **{String}**: Glob pattern to use for matching. +* `string` **{String}**: String to match +* `options` **{Object}**: See available [options](#options) for changing how matches are performed +* `returns` **{Boolean}**: Returns an array of captures if the string matches the glob pattern, otherwise `null`. + +**Example** + +```js +var extglob = require('extglob'); +extglob.capture(pattern, string[, options]); + +console.log(extglob.capture('test/*.js', 'test/foo.js')); +//=> ['foo'] +console.log(extglob.capture('test/*.js', 'foo/bar.css')); +//=> null +``` + +### [.makeRe](index.js#L281) + +Create a regular expression from the given `pattern` and `options`. + +**Params** + +* `pattern` **{String}**: The pattern to convert to regex. +* `options` **{Object}** +* `returns` **{RegExp}** + +**Example** + +```js +var extglob = require('extglob'); +var re = extglob.makeRe('*.!(*a)'); +console.log(re); +//=> /^[^\/]*?\.(?![^\/]*?a)[^\/]*?$/ +``` + +## Options + +Available options are based on the options from Bash (and the option names used in bash). + +### options.nullglob + +**Type**: `boolean` + +**Default**: `undefined` + +When enabled, the pattern itself will be returned when no matches are found. + +### options.nonull + +Alias for [options.nullglob](#optionsnullglob), included for parity with minimatch. + +### options.cache + +**Type**: `boolean` + +**Default**: `undefined` + +Functions are memoized based on the given glob patterns and options. Disable memoization by setting `options.cache` to false. + +### options.failglob + +**Type**: `boolean` + +**Default**: `undefined` + +Throw an error is no matches are found. + +## Benchmarks + +Last run on December 21, 2017 + +```sh +# negation-nested (49 bytes) + extglob x 2,228,255 ops/sec ±0.98% (89 runs sampled) + minimatch x 207,875 ops/sec ±0.61% (91 runs sampled) + + fastest is extglob (by 1072% avg) + +# negation-simple (43 bytes) + extglob x 2,205,668 ops/sec ±1.00% (91 runs sampled) + minimatch x 311,923 ops/sec ±1.25% (91 runs sampled) + + fastest is extglob (by 707% avg) + +# range-false (57 bytes) + extglob x 2,263,877 ops/sec ±0.40% (94 runs sampled) + minimatch x 271,372 ops/sec ±1.02% (91 runs sampled) + + fastest is extglob (by 834% avg) + +# range-true (56 bytes) + extglob x 2,161,891 ops/sec ±0.41% (92 runs sampled) + minimatch x 268,265 ops/sec ±1.17% (91 runs sampled) + + fastest is extglob (by 806% avg) + +# star-simple (46 bytes) + extglob x 2,211,081 ops/sec ±0.49% (92 runs sampled) + minimatch x 343,319 ops/sec ±0.59% (91 runs sampled) + + fastest is extglob (by 644% avg) + +``` + +## Differences from Bash + +This library has complete parity with Bash 4.3 with only a couple of minor differences. + +* In some cases Bash returns true if the given string "contains" the pattern, whereas this library returns true if the string is an exact match for the pattern. You can relax this by setting `options.contains` to true. +* This library is more accurate than Bash and thus does not fail some of the tests that Bash 4.3 still lists as failing in their unit tests + +## About + +
+Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new). + +
+ +
+Running Tests + +Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command: + +```sh +$ npm install && npm test +``` + +
+
+Building docs + +_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_ + +To generate the readme, run the following command: + +```sh +$ npm install -g verbose/verb#dev verb-generate-readme && verb +``` + +
+ +### Related projects + +You might also be interested in these projects: + +* [braces](https://www.npmjs.com/package/braces): Bash-like brace expansion, implemented in JavaScript. Safer than other brace expansion libs, with complete support… [more](https://github.com/micromatch/braces) | [homepage](https://github.com/micromatch/braces "Bash-like brace expansion, implemented in JavaScript. Safer than other brace expansion libs, with complete support for the Bash 4.3 braces specification, without sacrificing speed.") +* [expand-brackets](https://www.npmjs.com/package/expand-brackets): Expand POSIX bracket expressions (character classes) in glob patterns. | [homepage](https://github.com/jonschlinkert/expand-brackets "Expand POSIX bracket expressions (character classes) in glob patterns.") +* [expand-range](https://www.npmjs.com/package/expand-range): Fast, bash-like range expansion. Expand a range of numbers or letters, uppercase or lowercase. Used… [more](https://github.com/jonschlinkert/expand-range) | [homepage](https://github.com/jonschlinkert/expand-range "Fast, bash-like range expansion. Expand a range of numbers or letters, uppercase or lowercase. Used by [micromatch].") +* [fill-range](https://www.npmjs.com/package/fill-range): Fill in a range of numbers or letters, optionally passing an increment or `step` to… [more](https://github.com/jonschlinkert/fill-range) | [homepage](https://github.com/jonschlinkert/fill-range "Fill in a range of numbers or letters, optionally passing an increment or `step` to use, or create a regex-compatible range with `options.toRegex`") +* [micromatch](https://www.npmjs.com/package/micromatch): Glob matching for javascript/node.js. A drop-in replacement and faster alternative to minimatch and multimatch. | [homepage](https://github.com/micromatch/micromatch "Glob matching for javascript/node.js. A drop-in replacement and faster alternative to minimatch and multimatch.") + +### Contributors + +| **Commits** | **Contributor** | +| --- | --- | +| 49 | [jonschlinkert](https://github.com/jonschlinkert) | +| 2 | [isiahmeadows](https://github.com/isiahmeadows) | +| 1 | [doowb](https://github.com/doowb) | +| 1 | [devongovett](https://github.com/devongovett) | +| 1 | [mjbvz](https://github.com/mjbvz) | +| 1 | [shinnn](https://github.com/shinnn) | + +### Author + +**Jon Schlinkert** + +* [linkedin/in/jonschlinkert](https://linkedin.com/in/jonschlinkert) +* [github/jonschlinkert](https://github.com/jonschlinkert) +* [twitter/jonschlinkert](https://twitter.com/jonschlinkert) + +### License + +Copyright © 2017, [Jon Schlinkert](https://github.com/jonschlinkert). +Released under the [MIT License](LICENSE). + +*** + +_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.6.0, on December 21, 2017._ + +
+
+
    +
  1. `@` isn "'t a RegEx character." + +
  2. +
+
\ No newline at end of file diff --git a/node_modules/anymatch/node_modules/extglob/changelog.md b/node_modules/anymatch/node_modules/extglob/changelog.md new file mode 100644 index 0000000000..c9fc4fcd72 --- /dev/null +++ b/node_modules/anymatch/node_modules/extglob/changelog.md @@ -0,0 +1,25 @@ +## Changelog + +### v2.0.0 + +**Added features** + +- Adds [.capture](readme.md#capture) method for capturing matches, thanks to [devongovett](https://github.com/devongovett) + + +### v1.0.0 + +**Breaking changes** + +- The main export now returns the compiled string, instead of the object returned from the compiler + +**Added features** + +- Adds a `.create` method to do what the main function did before v1.0.0 + +**Other changes** + +- adds `expand-brackets` parsers/compilers to handle nested brackets and extglobs +- uses `to-regex` to build regex for `makeRe` method +- improves coverage +- optimizations \ No newline at end of file diff --git a/node_modules/anymatch/node_modules/extglob/index.js b/node_modules/anymatch/node_modules/extglob/index.js new file mode 100644 index 0000000000..116e6d5cbb --- /dev/null +++ b/node_modules/anymatch/node_modules/extglob/index.js @@ -0,0 +1,331 @@ +'use strict'; + +/** + * Module dependencies + */ + +var extend = require('extend-shallow'); +var unique = require('array-unique'); +var toRegex = require('to-regex'); + +/** + * Local dependencies + */ + +var compilers = require('./lib/compilers'); +var parsers = require('./lib/parsers'); +var Extglob = require('./lib/extglob'); +var utils = require('./lib/utils'); +var MAX_LENGTH = 1024 * 64; + +/** + * Convert the given `extglob` pattern into a regex-compatible string. Returns + * an object with the compiled result and the parsed AST. + * + * ```js + * var extglob = require('extglob'); + * console.log(extglob('*.!(*a)')); + * //=> '(?!\\.)[^/]*?\\.(?!(?!\\.)[^/]*?a\\b).*?' + * ``` + * @param {String} `pattern` + * @param {Object} `options` + * @return {String} + * @api public + */ + +function extglob(pattern, options) { + return extglob.create(pattern, options).output; +} + +/** + * Takes an array of strings and an extglob pattern and returns a new + * array that contains only the strings that match the pattern. + * + * ```js + * var extglob = require('extglob'); + * console.log(extglob.match(['a.a', 'a.b', 'a.c'], '*.!(*a)')); + * //=> ['a.b', 'a.c'] + * ``` + * @param {Array} `list` Array of strings to match + * @param {String} `pattern` Extglob pattern + * @param {Object} `options` + * @return {Array} Returns an array of matches + * @api public + */ + +extglob.match = function(list, pattern, options) { + if (typeof pattern !== 'string') { + throw new TypeError('expected pattern to be a string'); + } + + list = utils.arrayify(list); + var isMatch = extglob.matcher(pattern, options); + var len = list.length; + var idx = -1; + var matches = []; + + while (++idx < len) { + var ele = list[idx]; + + if (isMatch(ele)) { + matches.push(ele); + } + } + + // if no options were passed, uniquify results and return + if (typeof options === 'undefined') { + return unique(matches); + } + + if (matches.length === 0) { + if (options.failglob === true) { + throw new Error('no matches found for "' + pattern + '"'); + } + if (options.nonull === true || options.nullglob === true) { + return [pattern.split('\\').join('')]; + } + } + + return options.nodupes !== false ? unique(matches) : matches; +}; + +/** + * Returns true if the specified `string` matches the given + * extglob `pattern`. + * + * ```js + * var extglob = require('extglob'); + * + * console.log(extglob.isMatch('a.a', '*.!(*a)')); + * //=> false + * console.log(extglob.isMatch('a.b', '*.!(*a)')); + * //=> true + * ``` + * @param {String} `string` String to match + * @param {String} `pattern` Extglob pattern + * @param {String} `options` + * @return {Boolean} + * @api public + */ + +extglob.isMatch = function(str, pattern, options) { + if (typeof pattern !== 'string') { + throw new TypeError('expected pattern to be a string'); + } + + if (typeof str !== 'string') { + throw new TypeError('expected a string'); + } + + if (pattern === str) { + return true; + } + + if (pattern === '' || pattern === ' ' || pattern === '.') { + return pattern === str; + } + + var isMatch = utils.memoize('isMatch', pattern, options, extglob.matcher); + return isMatch(str); +}; + +/** + * Returns true if the given `string` contains the given pattern. Similar to `.isMatch` but + * the pattern can match any part of the string. + * + * ```js + * var extglob = require('extglob'); + * console.log(extglob.contains('aa/bb/cc', '*b')); + * //=> true + * console.log(extglob.contains('aa/bb/cc', '*d')); + * //=> false + * ``` + * @param {String} `str` The string to match. + * @param {String} `pattern` Glob pattern to use for matching. + * @param {Object} `options` + * @return {Boolean} Returns true if the patter matches any part of `str`. + * @api public + */ + +extglob.contains = function(str, pattern, options) { + if (typeof str !== 'string') { + throw new TypeError('expected a string'); + } + + if (pattern === '' || pattern === ' ' || pattern === '.') { + return pattern === str; + } + + var opts = extend({}, options, {contains: true}); + opts.strictClose = false; + opts.strictOpen = false; + return extglob.isMatch(str, pattern, opts); +}; + +/** + * Takes an extglob pattern and returns a matcher function. The returned + * function takes the string to match as its only argument. + * + * ```js + * var extglob = require('extglob'); + * var isMatch = extglob.matcher('*.!(*a)'); + * + * console.log(isMatch('a.a')); + * //=> false + * console.log(isMatch('a.b')); + * //=> true + * ``` + * @param {String} `pattern` Extglob pattern + * @param {String} `options` + * @return {Boolean} + * @api public + */ + +extglob.matcher = function(pattern, options) { + if (typeof pattern !== 'string') { + throw new TypeError('expected pattern to be a string'); + } + + function matcher() { + var re = extglob.makeRe(pattern, options); + return function(str) { + return re.test(str); + }; + } + + return utils.memoize('matcher', pattern, options, matcher); +}; + +/** + * Convert the given `extglob` pattern into a regex-compatible string. Returns + * an object with the compiled result and the parsed AST. + * + * ```js + * var extglob = require('extglob'); + * console.log(extglob.create('*.!(*a)').output); + * //=> '(?!\\.)[^/]*?\\.(?!(?!\\.)[^/]*?a\\b).*?' + * ``` + * @param {String} `str` + * @param {Object} `options` + * @return {String} + * @api public + */ + +extglob.create = function(pattern, options) { + if (typeof pattern !== 'string') { + throw new TypeError('expected pattern to be a string'); + } + + function create() { + var ext = new Extglob(options); + var ast = ext.parse(pattern, options); + return ext.compile(ast, options); + } + + return utils.memoize('create', pattern, options, create); +}; + +/** + * Returns an array of matches captured by `pattern` in `string`, or `null` + * if the pattern did not match. + * + * ```js + * var extglob = require('extglob'); + * extglob.capture(pattern, string[, options]); + * + * console.log(extglob.capture('test/*.js', 'test/foo.js')); + * //=> ['foo'] + * console.log(extglob.capture('test/*.js', 'foo/bar.css')); + * //=> null + * ``` + * @param {String} `pattern` Glob pattern to use for matching. + * @param {String} `string` String to match + * @param {Object} `options` See available [options](#options) for changing how matches are performed + * @return {Boolean} Returns an array of captures if the string matches the glob pattern, otherwise `null`. + * @api public + */ + +extglob.capture = function(pattern, str, options) { + var re = extglob.makeRe(pattern, extend({capture: true}, options)); + + function match() { + return function(string) { + var match = re.exec(string); + if (!match) { + return null; + } + + return match.slice(1); + }; + } + + var capture = utils.memoize('capture', pattern, options, match); + return capture(str); +}; + +/** + * Create a regular expression from the given `pattern` and `options`. + * + * ```js + * var extglob = require('extglob'); + * var re = extglob.makeRe('*.!(*a)'); + * console.log(re); + * //=> /^[^\/]*?\.(?![^\/]*?a)[^\/]*?$/ + * ``` + * @param {String} `pattern` The pattern to convert to regex. + * @param {Object} `options` + * @return {RegExp} + * @api public + */ + +extglob.makeRe = function(pattern, options) { + if (pattern instanceof RegExp) { + return pattern; + } + + if (typeof pattern !== 'string') { + throw new TypeError('expected pattern to be a string'); + } + + if (pattern.length > MAX_LENGTH) { + throw new Error('expected pattern to be less than ' + MAX_LENGTH + ' characters'); + } + + function makeRe() { + var opts = extend({strictErrors: false}, options); + if (opts.strictErrors === true) opts.strict = true; + var res = extglob.create(pattern, opts); + return toRegex(res.output, opts); + } + + var regex = utils.memoize('makeRe', pattern, options, makeRe); + if (regex.source.length > MAX_LENGTH) { + throw new SyntaxError('potentially malicious regex detected'); + } + + return regex; +}; + +/** + * Cache + */ + +extglob.cache = utils.cache; +extglob.clearCache = function() { + extglob.cache.__data__ = {}; +}; + +/** + * Expose `Extglob` constructor, parsers and compilers + */ + +extglob.Extglob = Extglob; +extglob.compilers = compilers; +extglob.parsers = parsers; + +/** + * Expose `extglob` + * @type {Function} + */ + +module.exports = extglob; diff --git a/node_modules/anymatch/node_modules/extglob/lib/compilers.js b/node_modules/anymatch/node_modules/extglob/lib/compilers.js new file mode 100644 index 0000000000..d7bed252a0 --- /dev/null +++ b/node_modules/anymatch/node_modules/extglob/lib/compilers.js @@ -0,0 +1,169 @@ +'use strict'; + +var brackets = require('expand-brackets'); + +/** + * Extglob compilers + */ + +module.exports = function(extglob) { + function star() { + if (typeof extglob.options.star === 'function') { + return extglob.options.star.apply(this, arguments); + } + if (typeof extglob.options.star === 'string') { + return extglob.options.star; + } + return '.*?'; + } + + /** + * Use `expand-brackets` compilers + */ + + extglob.use(brackets.compilers); + extglob.compiler + + /** + * Escaped: "\\*" + */ + + .set('escape', function(node) { + return this.emit(node.val, node); + }) + + /** + * Dot: "." + */ + + .set('dot', function(node) { + return this.emit('\\' + node.val, node); + }) + + /** + * Question mark: "?" + */ + + .set('qmark', function(node) { + var val = '[^\\\\/.]'; + var prev = this.prev(); + + if (node.parsed.slice(-1) === '(') { + var ch = node.rest.charAt(0); + if (ch !== '!' && ch !== '=' && ch !== ':') { + return this.emit(val, node); + } + return this.emit(node.val, node); + } + + if (prev.type === 'text' && prev.val) { + return this.emit(val, node); + } + + if (node.val.length > 1) { + val += '{' + node.val.length + '}'; + } + return this.emit(val, node); + }) + + /** + * Plus: "+" + */ + + .set('plus', function(node) { + var prev = node.parsed.slice(-1); + if (prev === ']' || prev === ')') { + return this.emit(node.val, node); + } + var ch = this.output.slice(-1); + if (!this.output || (/[?*+]/.test(ch) && node.parent.type !== 'bracket')) { + return this.emit('\\+', node); + } + if (/\w/.test(ch) && !node.inside) { + return this.emit('+\\+?', node); + } + return this.emit('+', node); + }) + + /** + * Star: "*" + */ + + .set('star', function(node) { + var prev = this.prev(); + var prefix = prev.type !== 'text' && prev.type !== 'escape' + ? '(?!\\.)' + : ''; + + return this.emit(prefix + star.call(this, node), node); + }) + + /** + * Parens + */ + + .set('paren', function(node) { + return this.mapVisit(node.nodes); + }) + .set('paren.open', function(node) { + var capture = this.options.capture ? '(' : ''; + + switch (node.parent.prefix) { + case '!': + case '^': + return this.emit(capture + '(?:(?!(?:', node); + case '*': + case '+': + case '?': + case '@': + return this.emit(capture + '(?:', node); + default: { + var val = node.val; + if (this.options.bash === true) { + val = '\\' + val; + } else if (!this.options.capture && val === '(' && node.parent.rest[0] !== '?') { + val += '?:'; + } + + return this.emit(val, node); + } + } + }) + .set('paren.close', function(node) { + var capture = this.options.capture ? ')' : ''; + + switch (node.prefix) { + case '!': + case '^': + var prefix = /^(\)|$)/.test(node.rest) ? '$' : ''; + var str = star.call(this, node); + + // if the extglob has a slash explicitly defined, we know the user wants + // to match slashes, so we need to ensure the "star" regex allows for it + if (node.parent.hasSlash && !this.options.star && this.options.slash !== false) { + str = '.*?'; + } + + return this.emit(prefix + ('))' + str + ')') + capture, node); + case '*': + case '+': + case '?': + return this.emit(')' + node.prefix + capture, node); + case '@': + return this.emit(')' + capture, node); + default: { + var val = (this.options.bash === true ? '\\' : '') + ')'; + return this.emit(val, node); + } + } + }) + + /** + * Text + */ + + .set('text', function(node) { + var val = node.val.replace(/[\[\]]/g, '\\$&'); + return this.emit(val, node); + }); +}; diff --git a/node_modules/anymatch/node_modules/extglob/lib/extglob.js b/node_modules/anymatch/node_modules/extglob/lib/extglob.js new file mode 100644 index 0000000000..015f928955 --- /dev/null +++ b/node_modules/anymatch/node_modules/extglob/lib/extglob.js @@ -0,0 +1,78 @@ +'use strict'; + +/** + * Module dependencies + */ + +var Snapdragon = require('snapdragon'); +var define = require('define-property'); +var extend = require('extend-shallow'); + +/** + * Local dependencies + */ + +var compilers = require('./compilers'); +var parsers = require('./parsers'); + +/** + * Customize Snapdragon parser and renderer + */ + +function Extglob(options) { + this.options = extend({source: 'extglob'}, options); + this.snapdragon = this.options.snapdragon || new Snapdragon(this.options); + this.snapdragon.patterns = this.snapdragon.patterns || {}; + this.compiler = this.snapdragon.compiler; + this.parser = this.snapdragon.parser; + + compilers(this.snapdragon); + parsers(this.snapdragon); + + /** + * Override Snapdragon `.parse` method + */ + + define(this.snapdragon, 'parse', function(str, options) { + var parsed = Snapdragon.prototype.parse.apply(this, arguments); + parsed.input = str; + + // escape unmatched brace/bracket/parens + var last = this.parser.stack.pop(); + if (last && this.options.strict !== true) { + var node = last.nodes[0]; + node.val = '\\' + node.val; + var sibling = node.parent.nodes[1]; + if (sibling.type === 'star') { + sibling.loose = true; + } + } + + // add non-enumerable parser reference + define(parsed, 'parser', this.parser); + return parsed; + }); + + /** + * Decorate `.parse` method + */ + + define(this, 'parse', function(ast, options) { + return this.snapdragon.parse.apply(this.snapdragon, arguments); + }); + + /** + * Decorate `.compile` method + */ + + define(this, 'compile', function(ast, options) { + return this.snapdragon.compile.apply(this.snapdragon, arguments); + }); + +} + +/** + * Expose `Extglob` + */ + +module.exports = Extglob; diff --git a/node_modules/anymatch/node_modules/extglob/lib/parsers.js b/node_modules/anymatch/node_modules/extglob/lib/parsers.js new file mode 100644 index 0000000000..2ba7352e9e --- /dev/null +++ b/node_modules/anymatch/node_modules/extglob/lib/parsers.js @@ -0,0 +1,156 @@ +'use strict'; + +var brackets = require('expand-brackets'); +var define = require('define-property'); +var utils = require('./utils'); + +/** + * Characters to use in text regex (we want to "not" match + * characters that are matched by other parsers) + */ + +var TEXT_REGEX = '([!@*?+]?\\(|\\)|[*?.+\\\\]|\\[:?(?=.*\\])|:?\\])+'; +var not = utils.createRegex(TEXT_REGEX); + +/** + * Extglob parsers + */ + +function parsers(extglob) { + extglob.state = extglob.state || {}; + + /** + * Use `expand-brackets` parsers + */ + + extglob.use(brackets.parsers); + extglob.parser.sets.paren = extglob.parser.sets.paren || []; + extglob.parser + + /** + * Extglob open: "*(" + */ + + .capture('paren.open', function() { + var parsed = this.parsed; + var pos = this.position(); + var m = this.match(/^([!@*?+])?\(/); + if (!m) return; + + var prev = this.prev(); + var prefix = m[1]; + var val = m[0]; + + var open = pos({ + type: 'paren.open', + parsed: parsed, + val: val + }); + + var node = pos({ + type: 'paren', + prefix: prefix, + nodes: [open] + }); + + // if nested negation extglobs, just cancel them out to simplify + if (prefix === '!' && prev.type === 'paren' && prev.prefix === '!') { + prev.prefix = '@'; + node.prefix = '@'; + } + + define(node, 'rest', this.input); + define(node, 'parsed', parsed); + define(node, 'parent', prev); + define(open, 'parent', node); + + this.push('paren', node); + prev.nodes.push(node); + }) + + /** + * Extglob close: ")" + */ + + .capture('paren.close', function() { + var parsed = this.parsed; + var pos = this.position(); + var m = this.match(/^\)/); + if (!m) return; + + var parent = this.pop('paren'); + var node = pos({ + type: 'paren.close', + rest: this.input, + parsed: parsed, + val: m[0] + }); + + if (!this.isType(parent, 'paren')) { + if (this.options.strict) { + throw new Error('missing opening paren: "("'); + } + node.escaped = true; + return node; + } + + node.prefix = parent.prefix; + parent.nodes.push(node); + define(node, 'parent', parent); + }) + + /** + * Escape: "\\." + */ + + .capture('escape', function() { + var pos = this.position(); + var m = this.match(/^\\(.)/); + if (!m) return; + + return pos({ + type: 'escape', + val: m[0], + ch: m[1] + }); + }) + + /** + * Question marks: "?" + */ + + .capture('qmark', function() { + var parsed = this.parsed; + var pos = this.position(); + var m = this.match(/^\?+(?!\()/); + if (!m) return; + extglob.state.metachar = true; + return pos({ + type: 'qmark', + rest: this.input, + parsed: parsed, + val: m[0] + }); + }) + + /** + * Character parsers + */ + + .capture('star', /^\*(?!\()/) + .capture('plus', /^\+(?!\()/) + .capture('dot', /^\./) + .capture('text', not); +}; + +/** + * Expose text regex string + */ + +module.exports.TEXT_REGEX = TEXT_REGEX; + +/** + * Extglob parsers + */ + +module.exports = parsers; diff --git a/node_modules/anymatch/node_modules/extglob/lib/utils.js b/node_modules/anymatch/node_modules/extglob/lib/utils.js new file mode 100644 index 0000000000..37a59fbce1 --- /dev/null +++ b/node_modules/anymatch/node_modules/extglob/lib/utils.js @@ -0,0 +1,69 @@ +'use strict'; + +var regex = require('regex-not'); +var Cache = require('fragment-cache'); + +/** + * Utils + */ + +var utils = module.exports; +var cache = utils.cache = new Cache(); + +/** + * Cast `val` to an array + * @return {Array} + */ + +utils.arrayify = function(val) { + if (!Array.isArray(val)) { + return [val]; + } + return val; +}; + +/** + * Memoize a generated regex or function + */ + +utils.memoize = function(type, pattern, options, fn) { + var key = utils.createKey(type + pattern, options); + + if (cache.has(type, key)) { + return cache.get(type, key); + } + + var val = fn(pattern, options); + if (options && options.cache === false) { + return val; + } + + cache.set(type, key, val); + return val; +}; + +/** + * Create the key to use for memoization. The key is generated + * by iterating over the options and concatenating key-value pairs + * to the pattern string. + */ + +utils.createKey = function(pattern, options) { + var key = pattern; + if (typeof options === 'undefined') { + return key; + } + for (var prop in options) { + key += ';' + prop + '=' + String(options[prop]); + } + return key; +}; + +/** + * Create the regex to use for matching text + */ + +utils.createRegex = function(str) { + var opts = {contains: true, strictClose: false}; + return regex(str, opts); +}; diff --git a/node_modules/anymatch/node_modules/extglob/node_modules/define-property/LICENSE b/node_modules/anymatch/node_modules/extglob/node_modules/define-property/LICENSE new file mode 100644 index 0000000000..ec85897eb1 --- /dev/null +++ b/node_modules/anymatch/node_modules/extglob/node_modules/define-property/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2015, 2017, Jon Schlinkert + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/anymatch/node_modules/extglob/node_modules/define-property/README.md b/node_modules/anymatch/node_modules/extglob/node_modules/define-property/README.md new file mode 100644 index 0000000000..2f1af05f3c --- /dev/null +++ b/node_modules/anymatch/node_modules/extglob/node_modules/define-property/README.md @@ -0,0 +1,95 @@ +# define-property [![NPM version](https://img.shields.io/npm/v/define-property.svg?style=flat)](https://www.npmjs.com/package/define-property) [![NPM monthly downloads](https://img.shields.io/npm/dm/define-property.svg?style=flat)](https://npmjs.org/package/define-property) [![NPM total downloads](https://img.shields.io/npm/dt/define-property.svg?style=flat)](https://npmjs.org/package/define-property) [![Linux Build Status](https://img.shields.io/travis/jonschlinkert/define-property.svg?style=flat&label=Travis)](https://travis-ci.org/jonschlinkert/define-property) + +> Define a non-enumerable property on an object. + +## Install + +Install with [npm](https://www.npmjs.com/): + +```sh +$ npm install --save define-property +``` + +Install with [yarn](https://yarnpkg.com): + +```sh +$ yarn add define-property +``` + +## Usage + +**Params** + +* `obj`: The object on which to define the property. +* `prop`: The name of the property to be defined or modified. +* `descriptor`: The descriptor for the property being defined or modified. + +```js +var define = require('define-property'); +var obj = {}; +define(obj, 'foo', function(val) { + return val.toUpperCase(); +}); + +console.log(obj); +//=> {} + +console.log(obj.foo('bar')); +//=> 'BAR' +``` + +**get/set** + +```js +define(obj, 'foo', { + get: function() {}, + set: function() {} +}); +``` + +## About + +### Related projects + +* [assign-deep](https://www.npmjs.com/package/assign-deep): Deeply assign the enumerable properties and/or es6 Symbol properies of source objects to the target… [more](https://github.com/jonschlinkert/assign-deep) | [homepage](https://github.com/jonschlinkert/assign-deep "Deeply assign the enumerable properties and/or es6 Symbol properies of source objects to the target (first) object.") +* [extend-shallow](https://www.npmjs.com/package/extend-shallow): Extend an object with the properties of additional objects. node.js/javascript util. | [homepage](https://github.com/jonschlinkert/extend-shallow "Extend an object with the properties of additional objects. node.js/javascript util.") +* [merge-deep](https://www.npmjs.com/package/merge-deep): Recursively merge values in a javascript object. | [homepage](https://github.com/jonschlinkert/merge-deep "Recursively merge values in a javascript object.") +* [mixin-deep](https://www.npmjs.com/package/mixin-deep): Deeply mix the properties of objects into the first object. Like merge-deep, but doesn't clone. | [homepage](https://github.com/jonschlinkert/mixin-deep "Deeply mix the properties of objects into the first object. Like merge-deep, but doesn't clone.") + +### Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new). + +### Building docs + +_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_ + +To generate the readme, run the following command: + +```sh +$ npm install -g verbose/verb#dev verb-generate-readme && verb +``` + +### Running tests + +Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command: + +```sh +$ npm install && npm test +``` + +### Author + +**Jon Schlinkert** + +* [github/jonschlinkert](https://github.com/jonschlinkert) +* [twitter/jonschlinkert](https://twitter.com/jonschlinkert) + +### License + +Copyright © 2017, [Jon Schlinkert](https://github.com/jonschlinkert). +Released under the [MIT License](LICENSE). + +*** + +_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.5.0, on April 20, 2017._ \ No newline at end of file diff --git a/node_modules/anymatch/node_modules/extglob/node_modules/define-property/index.js b/node_modules/anymatch/node_modules/extglob/node_modules/define-property/index.js new file mode 100644 index 0000000000..27c19ebf6d --- /dev/null +++ b/node_modules/anymatch/node_modules/extglob/node_modules/define-property/index.js @@ -0,0 +1,31 @@ +/*! + * define-property + * + * Copyright (c) 2015, 2017, Jon Schlinkert. + * Released under the MIT License. + */ + +'use strict'; + +var isDescriptor = require('is-descriptor'); + +module.exports = function defineProperty(obj, prop, val) { + if (typeof obj !== 'object' && typeof obj !== 'function') { + throw new TypeError('expected an object or function.'); + } + + if (typeof prop !== 'string') { + throw new TypeError('expected `prop` to be a string.'); + } + + if (isDescriptor(val) && ('set' in val || 'get' in val)) { + return Object.defineProperty(obj, prop, val); + } + + return Object.defineProperty(obj, prop, { + configurable: true, + enumerable: false, + writable: true, + value: val + }); +}; diff --git a/node_modules/anymatch/node_modules/extglob/node_modules/define-property/package.json b/node_modules/anymatch/node_modules/extglob/node_modules/define-property/package.json new file mode 100644 index 0000000000..772127593e --- /dev/null +++ b/node_modules/anymatch/node_modules/extglob/node_modules/define-property/package.json @@ -0,0 +1,93 @@ +{ + "_from": "define-property@^1.0.0", + "_id": "define-property@1.0.0", + "_inBundle": false, + "_integrity": "sha1-dp66rz9KY6rTr56NMEybvnm/sOY=", + "_location": "/anymatch/extglob/define-property", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "define-property@^1.0.0", + "name": "define-property", + "escapedName": "define-property", + "rawSpec": "^1.0.0", + "saveSpec": null, + "fetchSpec": "^1.0.0" + }, + "_requiredBy": [ + "/anymatch/extglob" + ], + "_resolved": "https://registry.npmjs.org/define-property/-/define-property-1.0.0.tgz", + "_shasum": "769ebaaf3f4a63aad3af9e8d304c9bbe79bfb0e6", + "_spec": "define-property@^1.0.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/anymatch/node_modules/extglob", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/jonschlinkert/define-property/issues" + }, + "bundleDependencies": false, + "dependencies": { + "is-descriptor": "^1.0.0" + }, + "deprecated": false, + "description": "Define a non-enumerable property on an object.", + "devDependencies": { + "gulp-format-md": "^0.1.12", + "mocha": "^3.2.0" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/jonschlinkert/define-property", + "keywords": [ + "define", + "define-property", + "enumerable", + "key", + "non", + "non-enumerable", + "object", + "prop", + "property", + "value" + ], + "license": "MIT", + "main": "index.js", + "name": "define-property", + "repository": { + "type": "git", + "url": "git+https://github.com/jonschlinkert/define-property.git" + }, + "scripts": { + "test": "mocha" + }, + "verb": { + "related": { + "list": [ + "extend-shallow", + "merge-deep", + "assign-deep", + "mixin-deep" + ] + }, + "toc": false, + "layout": "default", + "tasks": [ + "readme" + ], + "plugins": [ + "gulp-format-md" + ], + "lint": { + "reflinks": true + } + }, + "version": "1.0.0" +} diff --git a/node_modules/anymatch/node_modules/extglob/node_modules/extend-shallow/LICENSE b/node_modules/anymatch/node_modules/extglob/node_modules/extend-shallow/LICENSE new file mode 100644 index 0000000000..fa30c4cb3e --- /dev/null +++ b/node_modules/anymatch/node_modules/extglob/node_modules/extend-shallow/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2014-2015, Jon Schlinkert. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/anymatch/node_modules/extglob/node_modules/extend-shallow/README.md b/node_modules/anymatch/node_modules/extglob/node_modules/extend-shallow/README.md new file mode 100644 index 0000000000..cdc45d4ff7 --- /dev/null +++ b/node_modules/anymatch/node_modules/extglob/node_modules/extend-shallow/README.md @@ -0,0 +1,61 @@ +# extend-shallow [![NPM version](https://badge.fury.io/js/extend-shallow.svg)](http://badge.fury.io/js/extend-shallow) [![Build Status](https://travis-ci.org/jonschlinkert/extend-shallow.svg)](https://travis-ci.org/jonschlinkert/extend-shallow) + +> Extend an object with the properties of additional objects. node.js/javascript util. + +## Install + +Install with [npm](https://www.npmjs.com/) + +```sh +$ npm i extend-shallow --save +``` + +## Usage + +```js +var extend = require('extend-shallow'); + +extend({a: 'b'}, {c: 'd'}) +//=> {a: 'b', c: 'd'} +``` + +Pass an empty object to shallow clone: + +```js +var obj = {}; +extend(obj, {a: 'b'}, {c: 'd'}) +//=> {a: 'b', c: 'd'} +``` + +## Related + +* [extend-shallow](https://github.com/jonschlinkert/extend-shallow): Extend an object with the properties of additional objects. node.js/javascript util. +* [for-own](https://github.com/jonschlinkert/for-own): Iterate over the own enumerable properties of an object, and return an object with properties… [more](https://github.com/jonschlinkert/for-own) +* [for-in](https://github.com/jonschlinkert/for-in): Iterate over the own and inherited enumerable properties of an objecte, and return an object… [more](https://github.com/jonschlinkert/for-in) +* [is-plain-object](https://github.com/jonschlinkert/is-plain-object): Returns true if an object was created by the `Object` constructor. +* [isobject](https://github.com/jonschlinkert/isobject): Returns true if the value is an object and not an array or null. +* [kind-of](https://github.com/jonschlinkert/kind-of): Get the native type of a value. + +## Running tests + +Install dev dependencies: + +```sh +$ npm i -d && npm test +``` + +## Author + +**Jon Schlinkert** + ++ [github/jonschlinkert](https://github.com/jonschlinkert) ++ [twitter/jonschlinkert](http://twitter.com/jonschlinkert) + +## License + +Copyright © 2015 Jon Schlinkert +Released under the MIT license. + +*** + +_This file was generated by [verb-cli](https://github.com/assemble/verb-cli) on June 29, 2015._ \ No newline at end of file diff --git a/node_modules/anymatch/node_modules/extglob/node_modules/extend-shallow/index.js b/node_modules/anymatch/node_modules/extglob/node_modules/extend-shallow/index.js new file mode 100644 index 0000000000..92a067fcc4 --- /dev/null +++ b/node_modules/anymatch/node_modules/extglob/node_modules/extend-shallow/index.js @@ -0,0 +1,33 @@ +'use strict'; + +var isObject = require('is-extendable'); + +module.exports = function extend(o/*, objects*/) { + if (!isObject(o)) { o = {}; } + + var len = arguments.length; + for (var i = 1; i < len; i++) { + var obj = arguments[i]; + + if (isObject(obj)) { + assign(o, obj); + } + } + return o; +}; + +function assign(a, b) { + for (var key in b) { + if (hasOwn(b, key)) { + a[key] = b[key]; + } + } +} + +/** + * Returns true if the given `key` is an own property of `obj`. + */ + +function hasOwn(obj, key) { + return Object.prototype.hasOwnProperty.call(obj, key); +} diff --git a/node_modules/anymatch/node_modules/extglob/node_modules/extend-shallow/package.json b/node_modules/anymatch/node_modules/extglob/node_modules/extend-shallow/package.json new file mode 100644 index 0000000000..d8f3278e39 --- /dev/null +++ b/node_modules/anymatch/node_modules/extglob/node_modules/extend-shallow/package.json @@ -0,0 +1,87 @@ +{ + "_from": "extend-shallow@^2.0.1", + "_id": "extend-shallow@2.0.1", + "_inBundle": false, + "_integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "_location": "/anymatch/extglob/extend-shallow", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "extend-shallow@^2.0.1", + "name": "extend-shallow", + "escapedName": "extend-shallow", + "rawSpec": "^2.0.1", + "saveSpec": null, + "fetchSpec": "^2.0.1" + }, + "_requiredBy": [ + "/anymatch/extglob" + ], + "_resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "_shasum": "51af7d614ad9a9f610ea1bafbb989d6b1c56890f", + "_spec": "extend-shallow@^2.0.1", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/anymatch/node_modules/extglob", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/jonschlinkert/extend-shallow/issues" + }, + "bundleDependencies": false, + "dependencies": { + "is-extendable": "^0.1.0" + }, + "deprecated": false, + "description": "Extend an object with the properties of additional objects. node.js/javascript util.", + "devDependencies": { + "array-slice": "^0.2.3", + "benchmarked": "^0.1.4", + "chalk": "^1.0.0", + "for-own": "^0.1.3", + "glob": "^5.0.12", + "is-plain-object": "^2.0.1", + "kind-of": "^2.0.0", + "minimist": "^1.1.1", + "mocha": "^2.2.5", + "should": "^7.0.1" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/jonschlinkert/extend-shallow", + "keywords": [ + "assign", + "extend", + "javascript", + "js", + "keys", + "merge", + "obj", + "object", + "prop", + "properties", + "property", + "props", + "shallow", + "util", + "utility", + "utils", + "value" + ], + "license": "MIT", + "main": "index.js", + "name": "extend-shallow", + "repository": { + "type": "git", + "url": "git+https://github.com/jonschlinkert/extend-shallow.git" + }, + "scripts": { + "test": "mocha" + }, + "version": "2.0.1" +} diff --git a/node_modules/anymatch/node_modules/extglob/package.json b/node_modules/anymatch/node_modules/extglob/package.json new file mode 100644 index 0000000000..906e54b3bc --- /dev/null +++ b/node_modules/anymatch/node_modules/extglob/package.json @@ -0,0 +1,160 @@ +{ + "_from": "extglob@^2.0.4", + "_id": "extglob@2.0.4", + "_inBundle": false, + "_integrity": "sha512-Nmb6QXkELsuBr24CJSkilo6UHHgbekK5UiZgfE6UHD3Eb27YC6oD+bhcT+tJ6cl8dmsgdQxnWlcry8ksBIBLpw==", + "_location": "/anymatch/extglob", + "_phantomChildren": { + "is-descriptor": "1.0.2", + "is-extendable": "0.1.1" + }, + "_requested": { + "type": "range", + "registry": true, + "raw": "extglob@^2.0.4", + "name": "extglob", + "escapedName": "extglob", + "rawSpec": "^2.0.4", + "saveSpec": null, + "fetchSpec": "^2.0.4" + }, + "_requiredBy": [ + "/anymatch/micromatch" + ], + "_resolved": "https://registry.npmjs.org/extglob/-/extglob-2.0.4.tgz", + "_shasum": "ad00fe4dc612a9232e8718711dc5cb5ab0285543", + "_spec": "extglob@^2.0.4", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/anymatch/node_modules/micromatch", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/micromatch/extglob/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "Brian Woodward", + "url": "https://twitter.com/doowb" + }, + { + "name": "Devon Govett", + "url": "http://badassjs.com" + }, + { + "name": "Isiah Meadows", + "url": "https://www.isiahmeadows.com" + }, + { + "name": "Jon Schlinkert", + "url": "http://twitter.com/jonschlinkert" + }, + { + "name": "Matt Bierner", + "url": "http://mattbierner.com" + }, + { + "name": "Shinnosuke Watanabe", + "url": "https://shinnn.github.io" + } + ], + "dependencies": { + "array-unique": "^0.3.2", + "define-property": "^1.0.0", + "expand-brackets": "^2.1.4", + "extend-shallow": "^2.0.1", + "fragment-cache": "^0.2.1", + "regex-not": "^1.0.0", + "snapdragon": "^0.8.1", + "to-regex": "^3.0.1" + }, + "deprecated": false, + "description": "Extended glob support for JavaScript. Adds (almost) the expressive power of regular expressions to glob patterns.", + "devDependencies": { + "bash-match": "^1.0.2", + "for-own": "^1.0.0", + "gulp": "^3.9.1", + "gulp-eslint": "^4.0.0", + "gulp-format-md": "^1.0.0", + "gulp-istanbul": "^1.1.2", + "gulp-mocha": "^3.0.1", + "gulp-unused": "^0.2.1", + "helper-changelog": "^0.3.0", + "is-windows": "^1.0.1", + "micromatch": "^3.0.4", + "minimatch": "^3.0.4", + "minimist": "^1.2.0", + "mocha": "^3.5.0", + "multimatch": "^2.1.0" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js", + "lib" + ], + "homepage": "https://github.com/micromatch/extglob", + "keywords": [ + "bash", + "extended", + "extglob", + "glob", + "globbing", + "ksh", + "match", + "pattern", + "patterns", + "regex", + "test", + "wildcard" + ], + "license": "MIT", + "lintDeps": { + "devDependencies": { + "files": { + "options": { + "ignore": [ + "benchmark/**/*.js" + ] + } + } + } + }, + "main": "index.js", + "name": "extglob", + "repository": { + "type": "git", + "url": "git+https://github.com/micromatch/extglob.git" + }, + "scripts": { + "test": "mocha" + }, + "verb": { + "toc": false, + "layout": "default", + "tasks": [ + "readme" + ], + "related": { + "list": [ + "braces", + "expand-brackets", + "expand-range", + "fill-range", + "micromatch" + ] + }, + "helpers": [ + "helper-changelog" + ], + "plugins": [ + "gulp-format-md" + ], + "lint": { + "reflinks": true + } + }, + "version": "2.0.4" +} diff --git a/node_modules/anymatch/node_modules/is-accessor-descriptor/LICENSE b/node_modules/anymatch/node_modules/is-accessor-descriptor/LICENSE new file mode 100644 index 0000000000..e33d14b754 --- /dev/null +++ b/node_modules/anymatch/node_modules/is-accessor-descriptor/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2015-2017, Jon Schlinkert. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/anymatch/node_modules/is-accessor-descriptor/README.md b/node_modules/anymatch/node_modules/is-accessor-descriptor/README.md new file mode 100644 index 0000000000..d198e1f05e --- /dev/null +++ b/node_modules/anymatch/node_modules/is-accessor-descriptor/README.md @@ -0,0 +1,144 @@ +# is-accessor-descriptor [![NPM version](https://img.shields.io/npm/v/is-accessor-descriptor.svg?style=flat)](https://www.npmjs.com/package/is-accessor-descriptor) [![NPM monthly downloads](https://img.shields.io/npm/dm/is-accessor-descriptor.svg?style=flat)](https://npmjs.org/package/is-accessor-descriptor) [![NPM total downloads](https://img.shields.io/npm/dt/is-accessor-descriptor.svg?style=flat)](https://npmjs.org/package/is-accessor-descriptor) [![Linux Build Status](https://img.shields.io/travis/jonschlinkert/is-accessor-descriptor.svg?style=flat&label=Travis)](https://travis-ci.org/jonschlinkert/is-accessor-descriptor) + +> Returns true if a value has the characteristics of a valid JavaScript accessor descriptor. + +Please consider following this project's author, [Jon Schlinkert](https://github.com/jonschlinkert), and consider starring the project to show your :heart: and support. + +## Install + +Install with [npm](https://www.npmjs.com/): + +```sh +$ npm install --save is-accessor-descriptor +``` + +## Usage + +```js +var isAccessor = require('is-accessor-descriptor'); + +isAccessor({get: function() {}}); +//=> true +``` + +You may also pass an object and property name to check if the property is an accessor: + +```js +isAccessor(foo, 'bar'); +``` + +## Examples + +`false` when not an object + +```js +isAccessor('a') +isAccessor(null) +isAccessor([]) +//=> false +``` + +`true` when the object has valid properties + +and the properties all have the correct JavaScript types: + +```js +isAccessor({get: noop, set: noop}) +isAccessor({get: noop}) +isAccessor({set: noop}) +//=> true +``` + +`false` when the object has invalid properties + +```js +isAccessor({get: noop, set: noop, bar: 'baz'}) +isAccessor({get: noop, writable: true}) +isAccessor({get: noop, value: true}) +//=> false +``` + +`false` when an accessor is not a function + +```js +isAccessor({get: noop, set: 'baz'}) +isAccessor({get: 'foo', set: noop}) +isAccessor({get: 'foo', bar: 'baz'}) +isAccessor({get: 'foo', set: 'baz'}) +//=> false +``` + +`false` when a value is not the correct type + +```js +isAccessor({get: noop, set: noop, enumerable: 'foo'}) +isAccessor({set: noop, configurable: 'foo'}) +isAccessor({get: noop, configurable: 'foo'}) +//=> false +``` + +## About + +
+Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new). + +
+ +
+Running Tests + +Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command: + +```sh +$ npm install && npm test +``` + +
+ +
+Building docs + +_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_ + +To generate the readme, run the following command: + +```sh +$ npm install -g verbose/verb#dev verb-generate-readme && verb +``` + +
+ +### Related projects + +You might also be interested in these projects: + +* [is-accessor-descriptor](https://www.npmjs.com/package/is-accessor-descriptor): Returns true if a value has the characteristics of a valid JavaScript accessor descriptor. | [homepage](https://github.com/jonschlinkert/is-accessor-descriptor "Returns true if a value has the characteristics of a valid JavaScript accessor descriptor.") +* [is-data-descriptor](https://www.npmjs.com/package/is-data-descriptor): Returns true if a value has the characteristics of a valid JavaScript data descriptor. | [homepage](https://github.com/jonschlinkert/is-data-descriptor "Returns true if a value has the characteristics of a valid JavaScript data descriptor.") +* [is-descriptor](https://www.npmjs.com/package/is-descriptor): Returns true if a value has the characteristics of a valid JavaScript descriptor. Works for… [more](https://github.com/jonschlinkert/is-descriptor) | [homepage](https://github.com/jonschlinkert/is-descriptor "Returns true if a value has the characteristics of a valid JavaScript descriptor. Works for data descriptors and accessor descriptors.") +* [is-plain-object](https://www.npmjs.com/package/is-plain-object): Returns true if an object was created by the `Object` constructor. | [homepage](https://github.com/jonschlinkert/is-plain-object "Returns true if an object was created by the `Object` constructor.") +* [isobject](https://www.npmjs.com/package/isobject): Returns true if the value is an object and not an array or null. | [homepage](https://github.com/jonschlinkert/isobject "Returns true if the value is an object and not an array or null.") + +### Contributors + +| **Commits** | **Contributor** | +| --- | --- | +| 22 | [jonschlinkert](https://github.com/jonschlinkert) | +| 2 | [realityking](https://github.com/realityking) | + +### Author + +**Jon Schlinkert** + +* [github/jonschlinkert](https://github.com/jonschlinkert) +* [twitter/jonschlinkert](https://twitter.com/jonschlinkert) + +### License + +Copyright © 2017, [Jon Schlinkert](https://github.com/jonschlinkert). +Released under the [MIT License](LICENSE). + +*** + +_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.6.0, on November 01, 2017._ \ No newline at end of file diff --git a/node_modules/anymatch/node_modules/is-accessor-descriptor/index.js b/node_modules/anymatch/node_modules/is-accessor-descriptor/index.js new file mode 100644 index 0000000000..d2e6fe8b9e --- /dev/null +++ b/node_modules/anymatch/node_modules/is-accessor-descriptor/index.js @@ -0,0 +1,69 @@ +/*! + * is-accessor-descriptor + * + * Copyright (c) 2015-2017, Jon Schlinkert. + * Released under the MIT License. + */ + +'use strict'; + +var typeOf = require('kind-of'); + +// accessor descriptor properties +var accessor = { + get: 'function', + set: 'function', + configurable: 'boolean', + enumerable: 'boolean' +}; + +function isAccessorDescriptor(obj, prop) { + if (typeof prop === 'string') { + var val = Object.getOwnPropertyDescriptor(obj, prop); + return typeof val !== 'undefined'; + } + + if (typeOf(obj) !== 'object') { + return false; + } + + if (has(obj, 'value') || has(obj, 'writable')) { + return false; + } + + if (!has(obj, 'get') || typeof obj.get !== 'function') { + return false; + } + + // tldr: it's valid to have "set" be undefined + // "set" might be undefined if `Object.getOwnPropertyDescriptor` + // was used to get the value, and only `get` was defined by the user + if (has(obj, 'set') && typeof obj[key] !== 'function' && typeof obj[key] !== 'undefined') { + return false; + } + + for (var key in obj) { + if (!accessor.hasOwnProperty(key)) { + continue; + } + + if (typeOf(obj[key]) === accessor[key]) { + continue; + } + + if (typeof obj[key] !== 'undefined') { + return false; + } + } + return true; +} + +function has(obj, key) { + return {}.hasOwnProperty.call(obj, key); +} + +/** + * Expose `isAccessorDescriptor` + */ + +module.exports = isAccessorDescriptor; diff --git a/node_modules/anymatch/node_modules/is-accessor-descriptor/package.json b/node_modules/anymatch/node_modules/is-accessor-descriptor/package.json new file mode 100644 index 0000000000..a06361df61 --- /dev/null +++ b/node_modules/anymatch/node_modules/is-accessor-descriptor/package.json @@ -0,0 +1,110 @@ +{ + "_from": "is-accessor-descriptor@^1.0.0", + "_id": "is-accessor-descriptor@1.0.0", + "_inBundle": false, + "_integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", + "_location": "/anymatch/is-accessor-descriptor", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "is-accessor-descriptor@^1.0.0", + "name": "is-accessor-descriptor", + "escapedName": "is-accessor-descriptor", + "rawSpec": "^1.0.0", + "saveSpec": null, + "fetchSpec": "^1.0.0" + }, + "_requiredBy": [ + "/anymatch/is-descriptor" + ], + "_resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz", + "_shasum": "169c2f6d3df1f992618072365c9b0ea1f6878656", + "_spec": "is-accessor-descriptor@^1.0.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/anymatch/node_modules/is-descriptor", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/jonschlinkert/is-accessor-descriptor/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "Jon Schlinkert", + "url": "http://twitter.com/jonschlinkert" + }, + { + "name": "Rouven Weßling", + "url": "www.rouvenwessling.de" + } + ], + "dependencies": { + "kind-of": "^6.0.0" + }, + "deprecated": false, + "description": "Returns true if a value has the characteristics of a valid JavaScript accessor descriptor.", + "devDependencies": { + "gulp-format-md": "^1.0.0", + "mocha": "^3.5.3" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/jonschlinkert/is-accessor-descriptor", + "keywords": [ + "accessor", + "check", + "data", + "descriptor", + "get", + "getter", + "is", + "keys", + "object", + "properties", + "property", + "set", + "setter", + "type", + "valid", + "value" + ], + "license": "MIT", + "main": "index.js", + "name": "is-accessor-descriptor", + "repository": { + "type": "git", + "url": "git+https://github.com/jonschlinkert/is-accessor-descriptor.git" + }, + "scripts": { + "test": "mocha" + }, + "verb": { + "toc": false, + "layout": "default", + "tasks": [ + "readme" + ], + "plugins": [ + "gulp-format-md" + ], + "related": { + "list": [ + "is-accessor-descriptor", + "is-data-descriptor", + "is-descriptor", + "is-plain-object", + "isobject" + ] + }, + "lint": { + "reflinks": true + } + }, + "version": "1.0.0" +} diff --git a/node_modules/anymatch/node_modules/is-data-descriptor/LICENSE b/node_modules/anymatch/node_modules/is-data-descriptor/LICENSE new file mode 100644 index 0000000000..e33d14b754 --- /dev/null +++ b/node_modules/anymatch/node_modules/is-data-descriptor/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2015-2017, Jon Schlinkert. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/anymatch/node_modules/is-data-descriptor/README.md b/node_modules/anymatch/node_modules/is-data-descriptor/README.md new file mode 100644 index 0000000000..42b0714465 --- /dev/null +++ b/node_modules/anymatch/node_modules/is-data-descriptor/README.md @@ -0,0 +1,161 @@ +# is-data-descriptor [![NPM version](https://img.shields.io/npm/v/is-data-descriptor.svg?style=flat)](https://www.npmjs.com/package/is-data-descriptor) [![NPM monthly downloads](https://img.shields.io/npm/dm/is-data-descriptor.svg?style=flat)](https://npmjs.org/package/is-data-descriptor) [![NPM total downloads](https://img.shields.io/npm/dt/is-data-descriptor.svg?style=flat)](https://npmjs.org/package/is-data-descriptor) [![Linux Build Status](https://img.shields.io/travis/jonschlinkert/is-data-descriptor.svg?style=flat&label=Travis)](https://travis-ci.org/jonschlinkert/is-data-descriptor) + +> Returns true if a value has the characteristics of a valid JavaScript data descriptor. + +Please consider following this project's author, [Jon Schlinkert](https://github.com/jonschlinkert), and consider starring the project to show your :heart: and support. + +## Install + +Install with [npm](https://www.npmjs.com/): + +```sh +$ npm install --save is-data-descriptor +``` + +## Usage + +```js +var isDataDesc = require('is-data-descriptor'); +``` + +## Examples + +`true` when the descriptor has valid properties with valid values. + +```js +// `value` can be anything +isDataDesc({value: 'foo'}) +isDataDesc({value: function() {}}) +isDataDesc({value: true}) +//=> true +``` + +`false` when not an object + +```js +isDataDesc('a') +//=> false +isDataDesc(null) +//=> false +isDataDesc([]) +//=> false +``` + +`false` when the object has invalid properties + +```js +isDataDesc({value: 'foo', bar: 'baz'}) +//=> false +isDataDesc({value: 'foo', bar: 'baz'}) +//=> false +isDataDesc({value: 'foo', get: function(){}}) +//=> false +isDataDesc({get: function(){}, value: 'foo'}) +//=> false +``` + +`false` when a value is not the correct type + +```js +isDataDesc({value: 'foo', enumerable: 'foo'}) +//=> false +isDataDesc({value: 'foo', configurable: 'foo'}) +//=> false +isDataDesc({value: 'foo', writable: 'foo'}) +//=> false +``` + +## Valid properties + +The only valid data descriptor properties are the following: + +* `configurable` (required) +* `enumerable` (required) +* `value` (optional) +* `writable` (optional) + +To be a valid data descriptor, either `value` or `writable` must be defined. + +**Invalid properties** + +A descriptor may have additional _invalid_ properties (an error will **not** be thrown). + +```js +var foo = {}; + +Object.defineProperty(foo, 'bar', { + enumerable: true, + whatever: 'blah', // invalid, but doesn't cause an error + get: function() { + return 'baz'; + } +}); + +console.log(foo.bar); +//=> 'baz' +``` + +## About + +
+Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new). + +
+ +
+Running Tests + +Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command: + +```sh +$ npm install && npm test +``` + +
+ +
+Building docs + +_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_ + +To generate the readme, run the following command: + +```sh +$ npm install -g verbose/verb#dev verb-generate-readme && verb +``` + +
+ +### Related projects + +You might also be interested in these projects: + +* [is-accessor-descriptor](https://www.npmjs.com/package/is-accessor-descriptor): Returns true if a value has the characteristics of a valid JavaScript accessor descriptor. | [homepage](https://github.com/jonschlinkert/is-accessor-descriptor "Returns true if a value has the characteristics of a valid JavaScript accessor descriptor.") +* [is-data-descriptor](https://www.npmjs.com/package/is-data-descriptor): Returns true if a value has the characteristics of a valid JavaScript data descriptor. | [homepage](https://github.com/jonschlinkert/is-data-descriptor "Returns true if a value has the characteristics of a valid JavaScript data descriptor.") +* [is-descriptor](https://www.npmjs.com/package/is-descriptor): Returns true if a value has the characteristics of a valid JavaScript descriptor. Works for… [more](https://github.com/jonschlinkert/is-descriptor) | [homepage](https://github.com/jonschlinkert/is-descriptor "Returns true if a value has the characteristics of a valid JavaScript descriptor. Works for data descriptors and accessor descriptors.") +* [isobject](https://www.npmjs.com/package/isobject): Returns true if the value is an object and not an array or null. | [homepage](https://github.com/jonschlinkert/isobject "Returns true if the value is an object and not an array or null.") + +### Contributors + +| **Commits** | **Contributor** | +| --- | --- | +| 21 | [jonschlinkert](https://github.com/jonschlinkert) | +| 2 | [realityking](https://github.com/realityking) | + +### Author + +**Jon Schlinkert** + +* [github/jonschlinkert](https://github.com/jonschlinkert) +* [twitter/jonschlinkert](https://twitter.com/jonschlinkert) + +### License + +Copyright © 2017, [Jon Schlinkert](https://github.com/jonschlinkert). +Released under the [MIT License](LICENSE). + +*** + +_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.6.0, on November 01, 2017._ \ No newline at end of file diff --git a/node_modules/anymatch/node_modules/is-data-descriptor/index.js b/node_modules/anymatch/node_modules/is-data-descriptor/index.js new file mode 100644 index 0000000000..cfeae36190 --- /dev/null +++ b/node_modules/anymatch/node_modules/is-data-descriptor/index.js @@ -0,0 +1,49 @@ +/*! + * is-data-descriptor + * + * Copyright (c) 2015-2017, Jon Schlinkert. + * Released under the MIT License. + */ + +'use strict'; + +var typeOf = require('kind-of'); + +module.exports = function isDataDescriptor(obj, prop) { + // data descriptor properties + var data = { + configurable: 'boolean', + enumerable: 'boolean', + writable: 'boolean' + }; + + if (typeOf(obj) !== 'object') { + return false; + } + + if (typeof prop === 'string') { + var val = Object.getOwnPropertyDescriptor(obj, prop); + return typeof val !== 'undefined'; + } + + if (!('value' in obj) && !('writable' in obj)) { + return false; + } + + for (var key in obj) { + if (key === 'value') continue; + + if (!data.hasOwnProperty(key)) { + continue; + } + + if (typeOf(obj[key]) === data[key]) { + continue; + } + + if (typeof obj[key] !== 'undefined') { + return false; + } + } + return true; +}; diff --git a/node_modules/anymatch/node_modules/is-data-descriptor/package.json b/node_modules/anymatch/node_modules/is-data-descriptor/package.json new file mode 100644 index 0000000000..66a93697ff --- /dev/null +++ b/node_modules/anymatch/node_modules/is-data-descriptor/package.json @@ -0,0 +1,109 @@ +{ + "_from": "is-data-descriptor@^1.0.0", + "_id": "is-data-descriptor@1.0.0", + "_inBundle": false, + "_integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", + "_location": "/anymatch/is-data-descriptor", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "is-data-descriptor@^1.0.0", + "name": "is-data-descriptor", + "escapedName": "is-data-descriptor", + "rawSpec": "^1.0.0", + "saveSpec": null, + "fetchSpec": "^1.0.0" + }, + "_requiredBy": [ + "/anymatch/is-descriptor" + ], + "_resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", + "_shasum": "d84876321d0e7add03990406abbbbd36ba9268c7", + "_spec": "is-data-descriptor@^1.0.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/anymatch/node_modules/is-descriptor", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/jonschlinkert/is-data-descriptor/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "Jon Schlinkert", + "url": "http://twitter.com/jonschlinkert" + }, + { + "name": "Rouven Weßling", + "url": "www.rouvenwessling.de" + } + ], + "dependencies": { + "kind-of": "^6.0.0" + }, + "deprecated": false, + "description": "Returns true if a value has the characteristics of a valid JavaScript data descriptor.", + "devDependencies": { + "gulp-format-md": "^1.0.0", + "mocha": "^3.5.3" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/jonschlinkert/is-data-descriptor", + "keywords": [ + "accessor", + "check", + "data", + "descriptor", + "get", + "getter", + "is", + "keys", + "object", + "properties", + "property", + "set", + "setter", + "type", + "valid", + "value" + ], + "license": "MIT", + "main": "index.js", + "name": "is-data-descriptor", + "repository": { + "type": "git", + "url": "git+https://github.com/jonschlinkert/is-data-descriptor.git" + }, + "scripts": { + "test": "mocha" + }, + "verb": { + "toc": false, + "layout": "default", + "tasks": [ + "readme" + ], + "plugins": [ + "gulp-format-md" + ], + "related": { + "list": [ + "is-accessor-descriptor", + "is-data-descriptor", + "is-descriptor", + "isobject" + ] + }, + "lint": { + "reflinks": true + } + }, + "version": "1.0.0" +} diff --git a/node_modules/anymatch/node_modules/is-descriptor/LICENSE b/node_modules/anymatch/node_modules/is-descriptor/LICENSE new file mode 100644 index 0000000000..c0d7f13627 --- /dev/null +++ b/node_modules/anymatch/node_modules/is-descriptor/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2015-2017, Jon Schlinkert. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. \ No newline at end of file diff --git a/node_modules/anymatch/node_modules/is-descriptor/README.md b/node_modules/anymatch/node_modules/is-descriptor/README.md new file mode 100644 index 0000000000..658e53301b --- /dev/null +++ b/node_modules/anymatch/node_modules/is-descriptor/README.md @@ -0,0 +1,193 @@ +# is-descriptor [![NPM version](https://img.shields.io/npm/v/is-descriptor.svg?style=flat)](https://www.npmjs.com/package/is-descriptor) [![NPM monthly downloads](https://img.shields.io/npm/dm/is-descriptor.svg?style=flat)](https://npmjs.org/package/is-descriptor) [![NPM total downloads](https://img.shields.io/npm/dt/is-descriptor.svg?style=flat)](https://npmjs.org/package/is-descriptor) [![Linux Build Status](https://img.shields.io/travis/jonschlinkert/is-descriptor.svg?style=flat&label=Travis)](https://travis-ci.org/jonschlinkert/is-descriptor) + +> Returns true if a value has the characteristics of a valid JavaScript descriptor. Works for data descriptors and accessor descriptors. + +## Install + +Install with [npm](https://www.npmjs.com/): + +```sh +$ npm install --save is-descriptor +``` + +## Usage + +```js +var isDescriptor = require('is-descriptor'); + +isDescriptor({value: 'foo'}) +//=> true +isDescriptor({get: function(){}, set: function(){}}) +//=> true +isDescriptor({get: 'foo', set: function(){}}) +//=> false +``` + +You may also check for a descriptor by passing an object as the first argument and property name (`string`) as the second argument. + +```js +var obj = {}; +obj.foo = 'abc'; + +Object.defineProperty(obj, 'bar', { + value: 'xyz' +}); + +isDescriptor(obj, 'foo'); +//=> true +isDescriptor(obj, 'bar'); +//=> true +``` + +## Examples + +### value type + +`false` when not an object + +```js +isDescriptor('a'); +//=> false +isDescriptor(null); +//=> false +isDescriptor([]); +//=> false +``` + +### data descriptor + +`true` when the object has valid properties with valid values. + +```js +isDescriptor({value: 'foo'}); +//=> true +isDescriptor({value: noop}); +//=> true +``` + +`false` when the object has invalid properties + +```js +isDescriptor({value: 'foo', bar: 'baz'}); +//=> false +isDescriptor({value: 'foo', bar: 'baz'}); +//=> false +isDescriptor({value: 'foo', get: noop}); +//=> false +isDescriptor({get: noop, value: noop}); +//=> false +``` + +`false` when a value is not the correct type + +```js +isDescriptor({value: 'foo', enumerable: 'foo'}); +//=> false +isDescriptor({value: 'foo', configurable: 'foo'}); +//=> false +isDescriptor({value: 'foo', writable: 'foo'}); +//=> false +``` + +### accessor descriptor + +`true` when the object has valid properties with valid values. + +```js +isDescriptor({get: noop, set: noop}); +//=> true +isDescriptor({get: noop}); +//=> true +isDescriptor({set: noop}); +//=> true +``` + +`false` when the object has invalid properties + +```js +isDescriptor({get: noop, set: noop, bar: 'baz'}); +//=> false +isDescriptor({get: noop, writable: true}); +//=> false +isDescriptor({get: noop, value: true}); +//=> false +``` + +`false` when an accessor is not a function + +```js +isDescriptor({get: noop, set: 'baz'}); +//=> false +isDescriptor({get: 'foo', set: noop}); +//=> false +isDescriptor({get: 'foo', bar: 'baz'}); +//=> false +isDescriptor({get: 'foo', set: 'baz'}); +//=> false +``` + +`false` when a value is not the correct type + +```js +isDescriptor({get: noop, set: noop, enumerable: 'foo'}); +//=> false +isDescriptor({set: noop, configurable: 'foo'}); +//=> false +isDescriptor({get: noop, configurable: 'foo'}); +//=> false +``` + +## About + +### Related projects + +* [is-accessor-descriptor](https://www.npmjs.com/package/is-accessor-descriptor): Returns true if a value has the characteristics of a valid JavaScript accessor descriptor. | [homepage](https://github.com/jonschlinkert/is-accessor-descriptor "Returns true if a value has the characteristics of a valid JavaScript accessor descriptor.") +* [is-data-descriptor](https://www.npmjs.com/package/is-data-descriptor): Returns true if a value has the characteristics of a valid JavaScript data descriptor. | [homepage](https://github.com/jonschlinkert/is-data-descriptor "Returns true if a value has the characteristics of a valid JavaScript data descriptor.") +* [is-descriptor](https://www.npmjs.com/package/is-descriptor): Returns true if a value has the characteristics of a valid JavaScript descriptor. Works for… [more](https://github.com/jonschlinkert/is-descriptor) | [homepage](https://github.com/jonschlinkert/is-descriptor "Returns true if a value has the characteristics of a valid JavaScript descriptor. Works for data descriptors and accessor descriptors.") +* [isobject](https://www.npmjs.com/package/isobject): Returns true if the value is an object and not an array or null. | [homepage](https://github.com/jonschlinkert/isobject "Returns true if the value is an object and not an array or null.") + +### Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new). + +### Contributors + +| **Commits** | **Contributor** | +| --- | --- | +| 24 | [jonschlinkert](https://github.com/jonschlinkert) | +| 1 | [doowb](https://github.com/doowb) | +| 1 | [wtgtybhertgeghgtwtg](https://github.com/wtgtybhertgeghgtwtg) | + +### Building docs + +_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_ + +To generate the readme, run the following command: + +```sh +$ npm install -g verbose/verb#dev verb-generate-readme && verb +``` + +### Running tests + +Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command: + +```sh +$ npm install && npm test +``` + +### Author + +**Jon Schlinkert** + +* [github/jonschlinkert](https://github.com/jonschlinkert) +* [twitter/jonschlinkert](https://twitter.com/jonschlinkert) + +### License + +Copyright © 2017, [Jon Schlinkert](https://github.com/jonschlinkert). +Released under the [MIT License](LICENSE). + +*** + +_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.6.0, on July 22, 2017._ \ No newline at end of file diff --git a/node_modules/anymatch/node_modules/is-descriptor/index.js b/node_modules/anymatch/node_modules/is-descriptor/index.js new file mode 100644 index 0000000000..c9b91d7622 --- /dev/null +++ b/node_modules/anymatch/node_modules/is-descriptor/index.js @@ -0,0 +1,22 @@ +/*! + * is-descriptor + * + * Copyright (c) 2015-2017, Jon Schlinkert. + * Released under the MIT License. + */ + +'use strict'; + +var typeOf = require('kind-of'); +var isAccessor = require('is-accessor-descriptor'); +var isData = require('is-data-descriptor'); + +module.exports = function isDescriptor(obj, key) { + if (typeOf(obj) !== 'object') { + return false; + } + if ('get' in obj) { + return isAccessor(obj, key); + } + return isData(obj, key); +}; diff --git a/node_modules/anymatch/node_modules/is-descriptor/package.json b/node_modules/anymatch/node_modules/is-descriptor/package.json new file mode 100644 index 0000000000..7bc2594131 --- /dev/null +++ b/node_modules/anymatch/node_modules/is-descriptor/package.json @@ -0,0 +1,114 @@ +{ + "_from": "is-descriptor@^1.0.0", + "_id": "is-descriptor@1.0.2", + "_inBundle": false, + "_integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", + "_location": "/anymatch/is-descriptor", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "is-descriptor@^1.0.0", + "name": "is-descriptor", + "escapedName": "is-descriptor", + "rawSpec": "^1.0.0", + "saveSpec": null, + "fetchSpec": "^1.0.0" + }, + "_requiredBy": [ + "/anymatch/extglob/define-property" + ], + "_resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-1.0.2.tgz", + "_shasum": "3b159746a66604b04f8c81524ba365c5f14d86ec", + "_spec": "is-descriptor@^1.0.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/anymatch/node_modules/extglob/node_modules/define-property", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/jonschlinkert/is-descriptor/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "Brian Woodward", + "url": "https://twitter.com/doowb" + }, + { + "name": "Jon Schlinkert", + "url": "http://twitter.com/jonschlinkert" + }, + { + "url": "https://github.com/wtgtybhertgeghgtwtg" + } + ], + "dependencies": { + "is-accessor-descriptor": "^1.0.0", + "is-data-descriptor": "^1.0.0", + "kind-of": "^6.0.2" + }, + "deprecated": false, + "description": "Returns true if a value has the characteristics of a valid JavaScript descriptor. Works for data descriptors and accessor descriptors.", + "devDependencies": { + "gulp-format-md": "^1.0.0", + "mocha": "^3.5.3" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/jonschlinkert/is-descriptor", + "keywords": [ + "accessor", + "check", + "data", + "descriptor", + "get", + "getter", + "is", + "keys", + "object", + "properties", + "property", + "set", + "setter", + "type", + "valid", + "value" + ], + "license": "MIT", + "main": "index.js", + "name": "is-descriptor", + "repository": { + "type": "git", + "url": "git+https://github.com/jonschlinkert/is-descriptor.git" + }, + "scripts": { + "test": "mocha" + }, + "verb": { + "related": { + "list": [ + "is-accessor-descriptor", + "is-data-descriptor", + "is-descriptor", + "isobject" + ] + }, + "plugins": [ + "gulp-format-md" + ], + "toc": false, + "layout": "default", + "tasks": [ + "readme" + ], + "lint": { + "reflinks": true + } + }, + "version": "1.0.2" +} diff --git a/node_modules/anymatch/node_modules/micromatch/CHANGELOG.md b/node_modules/anymatch/node_modules/micromatch/CHANGELOG.md new file mode 100644 index 0000000000..9d8e5ed094 --- /dev/null +++ b/node_modules/anymatch/node_modules/micromatch/CHANGELOG.md @@ -0,0 +1,37 @@ +## History + +### key + +Changelog entries are classified using the following labels _(from [keep-a-changelog][]_): + +- `added`: for new features +- `changed`: for changes in existing functionality +- `deprecated`: for once-stable features removed in upcoming releases +- `removed`: for deprecated features removed in this release +- `fixed`: for any bug fixes +- `bumped`: updated dependencies, only minor or higher will be listed. + +### [3.0.0] - 2017-04-11 + +TODO. There should be no breaking changes. Please report any regressions. I will [reformat these release notes](https://github.com/micromatch/micromatch/pull/76) and add them to the changelog as soon as I have a chance. + +### [1.0.1] - 2016-12-12 + +**Added** + +- Support for windows path edge cases where backslashes are used in brackets or other unusual combinations. + +### [1.0.0] - 2016-12-12 + +Stable release. + +### [0.1.0] - 2016-10-08 + +First release. + + +[Unreleased]: https://github.com/jonschlinkert/micromatch/compare/0.1.0...HEAD +[0.2.0]: https://github.com/jonschlinkert/micromatch/compare/0.1.0...0.2.0 + +[keep-a-changelog]: https://github.com/olivierlacan/keep-a-changelog + diff --git a/node_modules/anymatch/node_modules/micromatch/LICENSE b/node_modules/anymatch/node_modules/micromatch/LICENSE new file mode 100755 index 0000000000..d32ab4426a --- /dev/null +++ b/node_modules/anymatch/node_modules/micromatch/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2014-2018, Jon Schlinkert. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/anymatch/node_modules/micromatch/README.md b/node_modules/anymatch/node_modules/micromatch/README.md new file mode 100644 index 0000000000..5dfa1498a6 --- /dev/null +++ b/node_modules/anymatch/node_modules/micromatch/README.md @@ -0,0 +1,1150 @@ +# micromatch [![NPM version](https://img.shields.io/npm/v/micromatch.svg?style=flat)](https://www.npmjs.com/package/micromatch) [![NPM monthly downloads](https://img.shields.io/npm/dm/micromatch.svg?style=flat)](https://npmjs.org/package/micromatch) [![NPM total downloads](https://img.shields.io/npm/dt/micromatch.svg?style=flat)](https://npmjs.org/package/micromatch) [![Linux Build Status](https://img.shields.io/travis/micromatch/micromatch.svg?style=flat&label=Travis)](https://travis-ci.org/micromatch/micromatch) [![Windows Build Status](https://img.shields.io/appveyor/ci/micromatch/micromatch.svg?style=flat&label=AppVeyor)](https://ci.appveyor.com/project/micromatch/micromatch) + +> Glob matching for javascript/node.js. A drop-in replacement and faster alternative to minimatch and multimatch. + +Please consider following this project's author, [Jon Schlinkert](https://github.com/jonschlinkert), and consider starring the project to show your :heart: and support. + +## Table of Contents + +
+Details + +- [Install](#install) +- [Quickstart](#quickstart) +- [Why use micromatch?](#why-use-micromatch) + * [Matching features](#matching-features) +- [Switching to micromatch](#switching-to-micromatch) + * [From minimatch](#from-minimatch) + * [From multimatch](#from-multimatch) +- [API](#api) +- [Options](#options) + * [options.basename](#optionsbasename) + * [options.bash](#optionsbash) + * [options.cache](#optionscache) + * [options.dot](#optionsdot) + * [options.failglob](#optionsfailglob) + * [options.ignore](#optionsignore) + * [options.matchBase](#optionsmatchbase) + * [options.nobrace](#optionsnobrace) + * [options.nocase](#optionsnocase) + * [options.nodupes](#optionsnodupes) + * [options.noext](#optionsnoext) + * [options.nonegate](#optionsnonegate) + * [options.noglobstar](#optionsnoglobstar) + * [options.nonull](#optionsnonull) + * [options.nullglob](#optionsnullglob) + * [options.snapdragon](#optionssnapdragon) + * [options.sourcemap](#optionssourcemap) + * [options.unescape](#optionsunescape) + * [options.unixify](#optionsunixify) +- [Extended globbing](#extended-globbing) + * [extglobs](#extglobs) + * [braces](#braces) + * [regex character classes](#regex-character-classes) + * [regex groups](#regex-groups) + * [POSIX bracket expressions](#posix-bracket-expressions) +- [Notes](#notes) + * [Bash 4.3 parity](#bash-43-parity) + * [Backslashes](#backslashes) +- [Contributing](#contributing) +- [Benchmarks](#benchmarks) + * [Running benchmarks](#running-benchmarks) + * [Latest results](#latest-results) +- [About](#about) + +
+ +## Install + +Install with [npm](https://www.npmjs.com/): + +```sh +$ npm install --save micromatch +``` + +## Quickstart + +```js +var mm = require('micromatch'); +mm(list, patterns[, options]); +``` + +The [main export](#micromatch) takes a list of strings and one or more glob patterns: + +```js +console.log(mm(['foo', 'bar', 'qux'], ['f*', 'b*'])); +//=> ['foo', 'bar'] +``` + +Use [.isMatch()](#ismatch) to get true/false: + +```js +console.log(mm.isMatch('foo', 'f*')); +//=> true +``` + +[Switching](#switching-to-micromatch) from minimatch and multimatch is easy! + +## Why use micromatch? + +> micromatch is a [drop-in replacement](#switching-to-micromatch) for minimatch and multimatch + +* Supports all of the same matching features as [minimatch](https://github.com/isaacs/minimatch) and [multimatch](https://github.com/sindresorhus/multimatch) +* Micromatch uses [snapdragon](https://github.com/jonschlinkert/snapdragon) for parsing and compiling globs, which provides granular control over the entire conversion process in a way that is easy to understand, reason about, and maintain. +* More consistently accurate matching [than minimatch](https://github.com/yarnpkg/yarn/pull/3339), with more than 36,000 [test assertions](./test) to prove it. +* More complete support for the Bash 4.3 specification than minimatch and multimatch. In fact, micromatch passes _all of the spec tests_ from bash, including some that bash still fails. +* [Faster matching](#benchmarks), from a combination of optimized glob patterns, faster algorithms, and regex caching. +* [Micromatch is safer](https://github.com/micromatch/braces#braces-is-safe), and is not subject to DoS with brace patterns, like minimatch and multimatch. +* More reliable windows support than minimatch and multimatch. + +### Matching features + +* Support for multiple glob patterns (no need for wrappers like multimatch) +* Wildcards (`**`, `*.js`) +* Negation (`'!a/*.js'`, `'*!(b).js']`) +* [extglobs](https://github.com/micromatch/extglob) (`+(x|y)`, `!(a|b)`) +* [POSIX character classes](https://github.com/micromatch/expand-brackets) (`[[:alpha:][:digit:]]`) +* [brace expansion](https://github.com/micromatch/braces) (`foo/{1..5}.md`, `bar/{a,b,c}.js`) +* regex character classes (`foo-[1-5].js`) +* regex logical "or" (`foo/(abc|xyz).js`) + +You can mix and match these features to create whatever patterns you need! + +## Switching to micromatch + +There is one notable difference between micromatch and minimatch in regards to how backslashes are handled. See [the notes about backslashes](#backslashes) for more information. + +### From minimatch + +Use [mm.isMatch()](#ismatch) instead of `minimatch()`: + +```js +mm.isMatch('foo', 'b*'); +//=> false +``` + +Use [mm.match()](#match) instead of `minimatch.match()`: + +```js +mm.match(['foo', 'bar'], 'b*'); +//=> 'bar' +``` + +### From multimatch + +Same signature: + +```js +mm(['foo', 'bar', 'baz'], ['f*', '*z']); +//=> ['foo', 'baz'] +``` + +## API + +### [micromatch](index.js#L41) + +The main function takes a list of strings and one or more glob patterns to use for matching. + +**Params** + +* `list` **{Array}**: A list of strings to match +* `patterns` **{String|Array}**: One or more glob patterns to use for matching. +* `options` **{Object}**: See available [options](#options) for changing how matches are performed +* `returns` **{Array}**: Returns an array of matches + +**Example** + +```js +var mm = require('micromatch'); +mm(list, patterns[, options]); + +console.log(mm(['a.js', 'a.txt'], ['*.js'])); +//=> [ 'a.js' ] +``` + +### [.match](index.js#L93) + +Similar to the main function, but `pattern` must be a string. + +**Params** + +* `list` **{Array}**: Array of strings to match +* `pattern` **{String}**: Glob pattern to use for matching. +* `options` **{Object}**: See available [options](#options) for changing how matches are performed +* `returns` **{Array}**: Returns an array of matches + +**Example** + +```js +var mm = require('micromatch'); +mm.match(list, pattern[, options]); + +console.log(mm.match(['a.a', 'a.aa', 'a.b', 'a.c'], '*.a')); +//=> ['a.a', 'a.aa'] +``` + +### [.isMatch](index.js#L154) + +Returns true if the specified `string` matches the given glob `pattern`. + +**Params** + +* `string` **{String}**: String to match +* `pattern` **{String}**: Glob pattern to use for matching. +* `options` **{Object}**: See available [options](#options) for changing how matches are performed +* `returns` **{Boolean}**: Returns true if the string matches the glob pattern. + +**Example** + +```js +var mm = require('micromatch'); +mm.isMatch(string, pattern[, options]); + +console.log(mm.isMatch('a.a', '*.a')); +//=> true +console.log(mm.isMatch('a.b', '*.a')); +//=> false +``` + +### [.some](index.js#L192) + +Returns true if some of the strings in the given `list` match any of the given glob `patterns`. + +**Params** + +* `list` **{String|Array}**: The string or array of strings to test. Returns as soon as the first match is found. +* `patterns` **{String|Array}**: One or more glob patterns to use for matching. +* `options` **{Object}**: See available [options](#options) for changing how matches are performed +* `returns` **{Boolean}**: Returns true if any patterns match `str` + +**Example** + +```js +var mm = require('micromatch'); +mm.some(list, patterns[, options]); + +console.log(mm.some(['foo.js', 'bar.js'], ['*.js', '!foo.js'])); +// true +console.log(mm.some(['foo.js'], ['*.js', '!foo.js'])); +// false +``` + +### [.every](index.js#L228) + +Returns true if every string in the given `list` matches any of the given glob `patterns`. + +**Params** + +* `list` **{String|Array}**: The string or array of strings to test. +* `patterns` **{String|Array}**: One or more glob patterns to use for matching. +* `options` **{Object}**: See available [options](#options) for changing how matches are performed +* `returns` **{Boolean}**: Returns true if any patterns match `str` + +**Example** + +```js +var mm = require('micromatch'); +mm.every(list, patterns[, options]); + +console.log(mm.every('foo.js', ['foo.js'])); +// true +console.log(mm.every(['foo.js', 'bar.js'], ['*.js'])); +// true +console.log(mm.every(['foo.js', 'bar.js'], ['*.js', '!foo.js'])); +// false +console.log(mm.every(['foo.js'], ['*.js', '!foo.js'])); +// false +``` + +### [.any](index.js#L260) + +Returns true if **any** of the given glob `patterns` match the specified `string`. + +**Params** + +* `str` **{String|Array}**: The string to test. +* `patterns` **{String|Array}**: One or more glob patterns to use for matching. +* `options` **{Object}**: See available [options](#options) for changing how matches are performed +* `returns` **{Boolean}**: Returns true if any patterns match `str` + +**Example** + +```js +var mm = require('micromatch'); +mm.any(string, patterns[, options]); + +console.log(mm.any('a.a', ['b.*', '*.a'])); +//=> true +console.log(mm.any('a.a', 'b.*')); +//=> false +``` + +### [.all](index.js#L308) + +Returns true if **all** of the given `patterns` match the specified string. + +**Params** + +* `str` **{String|Array}**: The string to test. +* `patterns` **{String|Array}**: One or more glob patterns to use for matching. +* `options` **{Object}**: See available [options](#options) for changing how matches are performed +* `returns` **{Boolean}**: Returns true if any patterns match `str` + +**Example** + +```js +var mm = require('micromatch'); +mm.all(string, patterns[, options]); + +console.log(mm.all('foo.js', ['foo.js'])); +// true + +console.log(mm.all('foo.js', ['*.js', '!foo.js'])); +// false + +console.log(mm.all('foo.js', ['*.js', 'foo.js'])); +// true + +console.log(mm.all('foo.js', ['*.js', 'f*', '*o*', '*o.js'])); +// true +``` + +### [.not](index.js#L340) + +Returns a list of strings that _**do not match any**_ of the given `patterns`. + +**Params** + +* `list` **{Array}**: Array of strings to match. +* `patterns` **{String|Array}**: One or more glob pattern to use for matching. +* `options` **{Object}**: See available [options](#options) for changing how matches are performed +* `returns` **{Array}**: Returns an array of strings that **do not match** the given patterns. + +**Example** + +```js +var mm = require('micromatch'); +mm.not(list, patterns[, options]); + +console.log(mm.not(['a.a', 'b.b', 'c.c'], '*.a')); +//=> ['b.b', 'c.c'] +``` + +### [.contains](index.js#L376) + +Returns true if the given `string` contains the given pattern. Similar to [.isMatch](#isMatch) but the pattern can match any part of the string. + +**Params** + +* `str` **{String}**: The string to match. +* `patterns` **{String|Array}**: Glob pattern to use for matching. +* `options` **{Object}**: See available [options](#options) for changing how matches are performed +* `returns` **{Boolean}**: Returns true if the patter matches any part of `str`. + +**Example** + +```js +var mm = require('micromatch'); +mm.contains(string, pattern[, options]); + +console.log(mm.contains('aa/bb/cc', '*b')); +//=> true +console.log(mm.contains('aa/bb/cc', '*d')); +//=> false +``` + +### [.matchKeys](index.js#L432) + +Filter the keys of the given object with the given `glob` pattern and `options`. Does not attempt to match nested keys. If you need this feature, use [glob-object](https://github.com/jonschlinkert/glob-object) instead. + +**Params** + +* `object` **{Object}**: The object with keys to filter. +* `patterns` **{String|Array}**: One or more glob patterns to use for matching. +* `options` **{Object}**: See available [options](#options) for changing how matches are performed +* `returns` **{Object}**: Returns an object with only keys that match the given patterns. + +**Example** + +```js +var mm = require('micromatch'); +mm.matchKeys(object, patterns[, options]); + +var obj = { aa: 'a', ab: 'b', ac: 'c' }; +console.log(mm.matchKeys(obj, '*b')); +//=> { ab: 'b' } +``` + +### [.matcher](index.js#L461) + +Returns a memoized matcher function from the given glob `pattern` and `options`. The returned function takes a string to match as its only argument and returns true if the string is a match. + +**Params** + +* `pattern` **{String}**: Glob pattern +* `options` **{Object}**: See available [options](#options) for changing how matches are performed. +* `returns` **{Function}**: Returns a matcher function. + +**Example** + +```js +var mm = require('micromatch'); +mm.matcher(pattern[, options]); + +var isMatch = mm.matcher('*.!(*a)'); +console.log(isMatch('a.a')); +//=> false +console.log(isMatch('a.b')); +//=> true +``` + +### [.capture](index.js#L536) + +Returns an array of matches captured by `pattern` in `string, or`null` if the pattern did not match. + +**Params** + +* `pattern` **{String}**: Glob pattern to use for matching. +* `string` **{String}**: String to match +* `options` **{Object}**: See available [options](#options) for changing how matches are performed +* `returns` **{Boolean}**: Returns an array of captures if the string matches the glob pattern, otherwise `null`. + +**Example** + +```js +var mm = require('micromatch'); +mm.capture(pattern, string[, options]); + +console.log(mm.capture('test/*.js', 'test/foo.js')); +//=> ['foo'] +console.log(mm.capture('test/*.js', 'foo/bar.css')); +//=> null +``` + +### [.makeRe](index.js#L571) + +Create a regular expression from the given glob `pattern`. + +**Params** + +* `pattern` **{String}**: A glob pattern to convert to regex. +* `options` **{Object}**: See available [options](#options) for changing how matches are performed. +* `returns` **{RegExp}**: Returns a regex created from the given pattern. + +**Example** + +```js +var mm = require('micromatch'); +mm.makeRe(pattern[, options]); + +console.log(mm.makeRe('*.js')); +//=> /^(?:(\.[\\\/])?(?!\.)(?=.)[^\/]*?\.js)$/ +``` + +### [.braces](index.js#L618) + +Expand the given brace `pattern`. + +**Params** + +* `pattern` **{String}**: String with brace pattern to expand. +* `options` **{Object}**: Any [options](#options) to change how expansion is performed. See the [braces](https://github.com/micromatch/braces) library for all available options. +* `returns` **{Array}** + +**Example** + +```js +var mm = require('micromatch'); +console.log(mm.braces('foo/{a,b}/bar')); +//=> ['foo/(a|b)/bar'] + +console.log(mm.braces('foo/{a,b}/bar', {expand: true})); +//=> ['foo/(a|b)/bar'] +``` + +### [.create](index.js#L685) + +Parses the given glob `pattern` and returns an array of abstract syntax trees (ASTs), with the compiled `output` and optional source `map` on each AST. + +**Params** + +* `pattern` **{String}**: Glob pattern to parse and compile. +* `options` **{Object}**: Any [options](#options) to change how parsing and compiling is performed. +* `returns` **{Object}**: Returns an object with the parsed AST, compiled string and optional source map. + +**Example** + +```js +var mm = require('micromatch'); +mm.create(pattern[, options]); + +console.log(mm.create('abc/*.js')); +// [{ options: { source: 'string', sourcemap: true }, +// state: {}, +// compilers: +// { ... }, +// output: '(\\.[\\\\\\/])?abc\\/(?!\\.)(?=.)[^\\/]*?\\.js', +// ast: +// { type: 'root', +// errors: [], +// nodes: +// [ ... ], +// dot: false, +// input: 'abc/*.js' }, +// parsingErrors: [], +// map: +// { version: 3, +// sources: [ 'string' ], +// names: [], +// mappings: 'AAAA,GAAG,EAAC,kBAAC,EAAC,EAAE', +// sourcesContent: [ 'abc/*.js' ] }, +// position: { line: 1, column: 28 }, +// content: {}, +// files: {}, +// idx: 6 }] +``` + +### [.parse](index.js#L732) + +Parse the given `str` with the given `options`. + +**Params** + +* `str` **{String}** +* `options` **{Object}** +* `returns` **{Object}**: Returns an AST + +**Example** + +```js +var mm = require('micromatch'); +mm.parse(pattern[, options]); + +var ast = mm.parse('a/{b,c}/d'); +console.log(ast); +// { type: 'root', +// errors: [], +// input: 'a/{b,c}/d', +// nodes: +// [ { type: 'bos', val: '' }, +// { type: 'text', val: 'a/' }, +// { type: 'brace', +// nodes: +// [ { type: 'brace.open', val: '{' }, +// { type: 'text', val: 'b,c' }, +// { type: 'brace.close', val: '}' } ] }, +// { type: 'text', val: '/d' }, +// { type: 'eos', val: '' } ] } +``` + +### [.compile](index.js#L780) + +Compile the given `ast` or string with the given `options`. + +**Params** + +* `ast` **{Object|String}** +* `options` **{Object}** +* `returns` **{Object}**: Returns an object that has an `output` property with the compiled string. + +**Example** + +```js +var mm = require('micromatch'); +mm.compile(ast[, options]); + +var ast = mm.parse('a/{b,c}/d'); +console.log(mm.compile(ast)); +// { options: { source: 'string' }, +// state: {}, +// compilers: +// { eos: [Function], +// noop: [Function], +// bos: [Function], +// brace: [Function], +// 'brace.open': [Function], +// text: [Function], +// 'brace.close': [Function] }, +// output: [ 'a/(b|c)/d' ], +// ast: +// { ... }, +// parsingErrors: [] } +``` + +### [.clearCache](index.js#L801) + +Clear the regex cache. + +**Example** + +```js +mm.clearCache(); +``` + +## Options + +* [basename](#optionsbasename) +* [bash](#optionsbash) +* [cache](#optionscache) +* [dot](#optionsdot) +* [failglob](#optionsfailglob) +* [ignore](#optionsignore) +* [matchBase](#optionsmatchBase) +* [nobrace](#optionsnobrace) +* [nocase](#optionsnocase) +* [nodupes](#optionsnodupes) +* [noext](#optionsnoext) +* [noglobstar](#optionsnoglobstar) +* [nonull](#optionsnonull) +* [nullglob](#optionsnullglob) +* [snapdragon](#optionssnapdragon) +* [sourcemap](#optionssourcemap) +* [unescape](#optionsunescape) +* [unixify](#optionsunixify) + +### options.basename + +Allow glob patterns without slashes to match a file path based on its basename. Same behavior as [minimatch](https://github.com/isaacs/minimatch) option `matchBase`. + +**Type**: `Boolean` + +**Default**: `false` + +**Example** + +```js +mm(['a/b.js', 'a/c.md'], '*.js'); +//=> [] + +mm(['a/b.js', 'a/c.md'], '*.js', {matchBase: true}); +//=> ['a/b.js'] +``` + +### options.bash + +Enabled by default, this option enforces bash-like behavior with stars immediately following a bracket expression. Bash bracket expressions are similar to regex character classes, but unlike regex, a star following a bracket expression **does not repeat the bracketed characters**. Instead, the star is treated the same as an other star. + +**Type**: `Boolean` + +**Default**: `true` + +**Example** + +```js +var files = ['abc', 'ajz']; +console.log(mm(files, '[a-c]*')); +//=> ['abc', 'ajz'] + +console.log(mm(files, '[a-c]*', {bash: false})); +``` + +### options.cache + +Disable regex and function memoization. + +**Type**: `Boolean` + +**Default**: `undefined` + +### options.dot + +Match dotfiles. Same behavior as [minimatch](https://github.com/isaacs/minimatch) option `dot`. + +**Type**: `Boolean` + +**Default**: `false` + +### options.failglob + +Similar to the `--failglob` behavior in Bash, throws an error when no matches are found. + +**Type**: `Boolean` + +**Default**: `undefined` + +### options.ignore + +String or array of glob patterns to match files to ignore. + +**Type**: `String|Array` + +**Default**: `undefined` + +### options.matchBase + +Alias for [options.basename](#options-basename). + +### options.nobrace + +Disable expansion of brace patterns. Same behavior as [minimatch](https://github.com/isaacs/minimatch) option `nobrace`. + +**Type**: `Boolean` + +**Default**: `undefined` + +See [braces](https://github.com/micromatch/braces) for more information about extended brace expansion. + +### options.nocase + +Use a case-insensitive regex for matching files. Same behavior as [minimatch](https://github.com/isaacs/minimatch). + +**Type**: `Boolean` + +**Default**: `undefined` + +### options.nodupes + +Remove duplicate elements from the result array. + +**Type**: `Boolean` + +**Default**: `undefined` + +**Example** + +Example of using the `unescape` and `nodupes` options together: + +```js +mm.match(['a/b/c', 'a/b/c'], 'a/b/c'); +//=> ['a/b/c', 'a/b/c'] + +mm.match(['a/b/c', 'a/b/c'], 'a/b/c', {nodupes: true}); +//=> ['abc'] +``` + +### options.noext + +Disable extglob support, so that extglobs are regarded as literal characters. + +**Type**: `Boolean` + +**Default**: `undefined` + +**Examples** + +```js +mm(['a/z', 'a/b', 'a/!(z)'], 'a/!(z)'); +//=> ['a/b', 'a/!(z)'] + +mm(['a/z', 'a/b', 'a/!(z)'], 'a/!(z)', {noext: true}); +//=> ['a/!(z)'] (matches only as literal characters) +``` + +### options.nonegate + +Disallow negation (`!`) patterns, and treat leading `!` as a literal character to match. + +**Type**: `Boolean` + +**Default**: `undefined` + +### options.noglobstar + +Disable matching with globstars (`**`). + +**Type**: `Boolean` + +**Default**: `undefined` + +```js +mm(['a/b', 'a/b/c', 'a/b/c/d'], 'a/**'); +//=> ['a/b', 'a/b/c', 'a/b/c/d'] + +mm(['a/b', 'a/b/c', 'a/b/c/d'], 'a/**', {noglobstar: true}); +//=> ['a/b'] +``` + +### options.nonull + +Alias for [options.nullglob](#options-nullglob). + +### options.nullglob + +If `true`, when no matches are found the actual (arrayified) glob pattern is returned instead of an empty array. Same behavior as [minimatch](https://github.com/isaacs/minimatch) option `nonull`. + +**Type**: `Boolean` + +**Default**: `undefined` + +### options.snapdragon + +Pass your own instance of [snapdragon](https://github.com/jonschlinkert/snapdragon), to customize parsers or compilers. + +**Type**: `Object` + +**Default**: `undefined` + +### options.sourcemap + +Generate a source map by enabling the `sourcemap` option with the `.parse`, `.compile`, or `.create` methods. + +_(Note that sourcemaps are currently not enabled for brace patterns)_ + +**Examples** + +``` js +var mm = require('micromatch'); +var pattern = '*(*(of*(a)x)z)'; + +var res = mm.create('abc/*.js', {sourcemap: true}); +console.log(res.map); +// { version: 3, +// sources: [ 'string' ], +// names: [], +// mappings: 'AAAA,GAAG,EAAC,iBAAC,EAAC,EAAE', +// sourcesContent: [ 'abc/*.js' ] } + +var ast = mm.parse('abc/**/*.js'); +var res = mm.compile(ast, {sourcemap: true}); +console.log(res.map); +// { version: 3, +// sources: [ 'string' ], +// names: [], +// mappings: 'AAAA,GAAG,EAAC,2BAAE,EAAC,iBAAC,EAAC,EAAE', +// sourcesContent: [ 'abc/**/*.js' ] } + +var ast = mm.parse(pattern); +var res = mm.compile(ast, {sourcemap: true}); +console.log(res.map); +// { version: 3, +// sources: [ 'string' ], +// names: [], +// mappings: 'AAAA,CAAE,CAAE,EAAE,CAAE,CAAC,EAAC,CAAC,EAAC,CAAC,EAAC', +// sourcesContent: [ '*(*(of*(a)x)z)' ] } +``` + +### options.unescape + +Remove backslashes from returned matches. + +**Type**: `Boolean` + +**Default**: `undefined` + +**Example** + +In this example we want to match a literal `*`: + +```js +mm.match(['abc', 'a\\*c'], 'a\\*c'); +//=> ['a\\*c'] + +mm.match(['abc', 'a\\*c'], 'a\\*c', {unescape: true}); +//=> ['a*c'] +``` + +### options.unixify + +Convert path separators on returned files to posix/unix-style forward slashes. + +**Type**: `Boolean` + +**Default**: `true` on windows, `false` everywhere else + +**Example** + +```js +mm.match(['a\\b\\c'], 'a/**'); +//=> ['a/b/c'] + +mm.match(['a\\b\\c'], {unixify: false}); +//=> ['a\\b\\c'] +``` + +## Extended globbing + +Micromatch also supports extended globbing features. + +### extglobs + +Extended globbing, as described by the bash man page: + +| **pattern** | **regex equivalent** | **description** | +| --- | --- | --- | +| `?(pattern)` | `(pattern)?` | Matches zero or one occurrence of the given patterns | +| `*(pattern)` | `(pattern)*` | Matches zero or more occurrences of the given patterns | +| `+(pattern)` | `(pattern)+` | Matches one or more occurrences of the given patterns | +| `@(pattern)` | `(pattern)` * | Matches one of the given patterns | +| `!(pattern)` | N/A (equivalent regex is much more complicated) | Matches anything except one of the given patterns | + +* Note that `@` isn't a RegEx character. + +Powered by [extglob](https://github.com/micromatch/extglob). Visit that library for the full range of options or to report extglob related issues. + +### braces + +Brace patterns can be used to match specific ranges or sets of characters. For example, the pattern `*/{1..3}/*` would match any of following strings: + +``` +foo/1/bar +foo/2/bar +foo/3/bar +baz/1/qux +baz/2/qux +baz/3/qux +``` + +Visit [braces](https://github.com/micromatch/braces) to see the full range of features and options related to brace expansion, or to create brace matching or expansion related issues. + +### regex character classes + +Given the list: `['a.js', 'b.js', 'c.js', 'd.js', 'E.js']`: + +* `[ac].js`: matches both `a` and `c`, returning `['a.js', 'c.js']` +* `[b-d].js`: matches from `b` to `d`, returning `['b.js', 'c.js', 'd.js']` +* `[b-d].js`: matches from `b` to `d`, returning `['b.js', 'c.js', 'd.js']` +* `a/[A-Z].js`: matches and uppercase letter, returning `['a/E.md']` + +Learn about [regex character classes](http://www.regular-expressions.info/charclass.html). + +### regex groups + +Given `['a.js', 'b.js', 'c.js', 'd.js', 'E.js']`: + +* `(a|c).js`: would match either `a` or `c`, returning `['a.js', 'c.js']` +* `(b|d).js`: would match either `b` or `d`, returning `['b.js', 'd.js']` +* `(b|[A-Z]).js`: would match either `b` or an uppercase letter, returning `['b.js', 'E.js']` + +As with regex, parens can be nested, so patterns like `((a|b)|c)/b` will work. Although brace expansion might be friendlier to use, depending on preference. + +### POSIX bracket expressions + +POSIX brackets are intended to be more user-friendly than regex character classes. This of course is in the eye of the beholder. + +**Example** + +```js +mm.isMatch('a1', '[[:alpha:][:digit:]]'); +//=> true + +mm.isMatch('a1', '[[:alpha:][:alpha:]]'); +//=> false +``` + +See [expand-brackets](https://github.com/jonschlinkert/expand-brackets) for more information about bracket expressions. + +*** + +## Notes + +### Bash 4.3 parity + +Whenever possible matching behavior is based on behavior Bash 4.3, which is mostly consistent with minimatch. + +However, it's suprising how many edge cases and rabbit holes there are with glob matching, and since there is no real glob specification, and micromatch is more accurate than both Bash and minimatch, there are cases where best-guesses were made for behavior. In a few cases where Bash had no answers, we used wildmatch (used by git) as a fallback. + +### Backslashes + +There is an important, notable difference between minimatch and micromatch _in regards to how backslashes are handled_ in glob patterns. + +* Micromatch exclusively and explicitly reserves backslashes for escaping characters in a glob pattern, even on windows. This is consistent with bash behavior. +* Minimatch converts all backslashes to forward slashes, which means you can't use backslashes to escape any characters in your glob patterns. + +We made this decision for micromatch for a couple of reasons: + +* consistency with bash conventions. +* glob patterns are not filepaths. They are a type of [regular language](https://en.wikipedia.org/wiki/Regular_language) that is converted to a JavaScript regular expression. Thus, when forward slashes are defined in a glob pattern, the resulting regular expression will match windows or POSIX path separators just fine. + +**A note about joining paths to globs** + +Note that when you pass something like `path.join('foo', '*')` to micromatch, you are creating a filepath and expecting it to still work as a glob pattern. This causes problems on windows, since the `path.sep` is `\\`. + +In other words, since `\\` is reserved as an escape character in globs, on windows `path.join('foo', '*')` would result in `foo\\*`, which tells micromatch to match `*` as a literal character. This is the same behavior as bash. + +## Contributing + +All contributions are welcome! Please read [the contributing guide](.github/contributing.md) to get started. + +**Bug reports** + +Please create an issue if you encounter a bug or matching behavior that doesn't seem correct. If you find a matching-related issue, please: + +* [research existing issues first](../../issues) (open and closed) +* visit the [GNU Bash documentation](https://www.gnu.org/software/bash/manual/) to see how Bash deals with the pattern +* visit the [minimatch](https://github.com/isaacs/minimatch) documentation to cross-check expected behavior in node.js +* if all else fails, since there is no real specification for globs we will probably need to discuss expected behavior and decide how to resolve it. which means any detail you can provide to help with this discussion would be greatly appreciated. + +**Platform issues** + +It's important to us that micromatch work consistently on all platforms. If you encounter any platform-specific matching or path related issues, please let us know (pull requests are also greatly appreciated). + +## Benchmarks + +### Running benchmarks + +Install dev dependencies: + +```bash +npm i -d && npm run benchmark +``` + +### Latest results + +As of February 18, 2018 (longer bars are better): + +```sh +# braces-globstar-large-list (485691 bytes) + micromatch ██████████████████████████████████████████████████ (517 ops/sec ±0.49%) + minimatch █ (18.92 ops/sec ±0.54%) + multimatch █ (18.94 ops/sec ±0.62%) + + micromatch is faster by an avg. of 2,733% + +# braces-multiple (3362 bytes) + micromatch ██████████████████████████████████████████████████ (33,625 ops/sec ±0.45%) + minimatch (2.92 ops/sec ±3.26%) + multimatch (2.90 ops/sec ±2.76%) + + micromatch is faster by an avg. of 1,156,935% + +# braces-range (727 bytes) + micromatch █████████████████████████████████████████████████ (155,220 ops/sec ±0.56%) + minimatch ██████ (20,186 ops/sec ±1.27%) + multimatch ██████ (19,809 ops/sec ±0.60%) + + micromatch is faster by an avg. of 776% + +# braces-set (2858 bytes) + micromatch █████████████████████████████████████████████████ (24,354 ops/sec ±0.92%) + minimatch █████ (2,566 ops/sec ±0.56%) + multimatch ████ (2,431 ops/sec ±1.25%) + + micromatch is faster by an avg. of 975% + +# globstar-large-list (485686 bytes) + micromatch █████████████████████████████████████████████████ (504 ops/sec ±0.45%) + minimatch ███ (33.36 ops/sec ±1.08%) + multimatch ███ (33.19 ops/sec ±1.35%) + + micromatch is faster by an avg. of 1,514% + +# globstar-long-list (90647 bytes) + micromatch ██████████████████████████████████████████████████ (2,694 ops/sec ±1.08%) + minimatch ████████████████ (870 ops/sec ±1.09%) + multimatch ████████████████ (862 ops/sec ±0.84%) + + micromatch is faster by an avg. of 311% + +# globstar-short-list (182 bytes) + micromatch ██████████████████████████████████████████████████ (328,921 ops/sec ±1.06%) + minimatch █████████ (64,808 ops/sec ±1.42%) + multimatch ████████ (57,991 ops/sec ±2.11%) + + micromatch is faster by an avg. of 536% + +# no-glob (701 bytes) + micromatch █████████████████████████████████████████████████ (415,935 ops/sec ±0.36%) + minimatch ███████████ (92,730 ops/sec ±1.44%) + multimatch █████████ (81,958 ops/sec ±2.13%) + + micromatch is faster by an avg. of 476% + +# star-basename-long (12339 bytes) + micromatch █████████████████████████████████████████████████ (7,963 ops/sec ±0.36%) + minimatch ███████████████████████████████ (5,072 ops/sec ±0.83%) + multimatch ███████████████████████████████ (5,028 ops/sec ±0.40%) + + micromatch is faster by an avg. of 158% + +# star-basename-short (349 bytes) + micromatch ██████████████████████████████████████████████████ (269,552 ops/sec ±0.70%) + minimatch ██████████████████████ (122,457 ops/sec ±1.39%) + multimatch ████████████████████ (110,788 ops/sec ±1.99%) + + micromatch is faster by an avg. of 231% + +# star-folder-long (19207 bytes) + micromatch █████████████████████████████████████████████████ (3,806 ops/sec ±0.38%) + minimatch ████████████████████████████ (2,204 ops/sec ±0.32%) + multimatch ██████████████████████████ (2,020 ops/sec ±1.07%) + + micromatch is faster by an avg. of 180% + +# star-folder-short (551 bytes) + micromatch ██████████████████████████████████████████████████ (249,077 ops/sec ±0.40%) + minimatch ███████████ (59,431 ops/sec ±1.67%) + multimatch ███████████ (55,569 ops/sec ±1.43%) + + micromatch is faster by an avg. of 433% +``` + +## About + +
+Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new). + +Please read the [contributing guide](.github/contributing.md) for advice on opening issues, pull requests, and coding standards. + +
+ +
+Running Tests + +Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command: + +```sh +$ npm install && npm test +``` + +
+ +
+Building docs + +_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_ + +To generate the readme, run the following command: + +```sh +$ npm install -g verbose/verb#dev verb-generate-readme && verb +``` + +
+ +### Related projects + +You might also be interested in these projects: + +* [braces](https://www.npmjs.com/package/braces): Bash-like brace expansion, implemented in JavaScript. Safer than other brace expansion libs, with complete support… [more](https://github.com/micromatch/braces) | [homepage](https://github.com/micromatch/braces "Bash-like brace expansion, implemented in JavaScript. Safer than other brace expansion libs, with complete support for the Bash 4.3 braces specification, without sacrificing speed.") +* [expand-brackets](https://www.npmjs.com/package/expand-brackets): Expand POSIX bracket expressions (character classes) in glob patterns. | [homepage](https://github.com/jonschlinkert/expand-brackets "Expand POSIX bracket expressions (character classes) in glob patterns.") +* [extglob](https://www.npmjs.com/package/extglob): Extended glob support for JavaScript. Adds (almost) the expressive power of regular expressions to glob… [more](https://github.com/micromatch/extglob) | [homepage](https://github.com/micromatch/extglob "Extended glob support for JavaScript. Adds (almost) the expressive power of regular expressions to glob patterns.") +* [fill-range](https://www.npmjs.com/package/fill-range): Fill in a range of numbers or letters, optionally passing an increment or `step` to… [more](https://github.com/jonschlinkert/fill-range) | [homepage](https://github.com/jonschlinkert/fill-range "Fill in a range of numbers or letters, optionally passing an increment or `step` to use, or create a regex-compatible range with `options.toRegex`") +* [nanomatch](https://www.npmjs.com/package/nanomatch): Fast, minimal glob matcher for node.js. Similar to micromatch, minimatch and multimatch, but complete Bash… [more](https://github.com/micromatch/nanomatch) | [homepage](https://github.com/micromatch/nanomatch "Fast, minimal glob matcher for node.js. Similar to micromatch, minimatch and multimatch, but complete Bash 4.3 wildcard support only (no support for exglobs, posix brackets or braces)") + +### Contributors + +| **Commits** | **Contributor** | +| --- | --- | +| 457 | [jonschlinkert](https://github.com/jonschlinkert) | +| 12 | [es128](https://github.com/es128) | +| 8 | [doowb](https://github.com/doowb) | +| 3 | [paulmillr](https://github.com/paulmillr) | +| 2 | [TrySound](https://github.com/TrySound) | +| 2 | [MartinKolarik](https://github.com/MartinKolarik) | +| 2 | [charlike-old](https://github.com/charlike-old) | +| 1 | [amilajack](https://github.com/amilajack) | +| 1 | [mrmlnc](https://github.com/mrmlnc) | +| 1 | [devongovett](https://github.com/devongovett) | +| 1 | [DianeLooney](https://github.com/DianeLooney) | +| 1 | [UltCombo](https://github.com/UltCombo) | +| 1 | [tomByrer](https://github.com/tomByrer) | +| 1 | [fidian](https://github.com/fidian) | + +### Author + +**Jon Schlinkert** + +* [linkedin/in/jonschlinkert](https://linkedin.com/in/jonschlinkert) +* [github/jonschlinkert](https://github.com/jonschlinkert) +* [twitter/jonschlinkert](https://twitter.com/jonschlinkert) + +### License + +Copyright © 2018, [Jon Schlinkert](https://github.com/jonschlinkert). +Released under the [MIT License](LICENSE). + +*** + +_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.6.0, on February 18, 2018._ \ No newline at end of file diff --git a/node_modules/anymatch/node_modules/micromatch/index.js b/node_modules/anymatch/node_modules/micromatch/index.js new file mode 100644 index 0000000000..fe02f2cb23 --- /dev/null +++ b/node_modules/anymatch/node_modules/micromatch/index.js @@ -0,0 +1,877 @@ +'use strict'; + +/** + * Module dependencies + */ + +var util = require('util'); +var braces = require('braces'); +var toRegex = require('to-regex'); +var extend = require('extend-shallow'); + +/** + * Local dependencies + */ + +var compilers = require('./lib/compilers'); +var parsers = require('./lib/parsers'); +var cache = require('./lib/cache'); +var utils = require('./lib/utils'); +var MAX_LENGTH = 1024 * 64; + +/** + * The main function takes a list of strings and one or more + * glob patterns to use for matching. + * + * ```js + * var mm = require('micromatch'); + * mm(list, patterns[, options]); + * + * console.log(mm(['a.js', 'a.txt'], ['*.js'])); + * //=> [ 'a.js' ] + * ``` + * @param {Array} `list` A list of strings to match + * @param {String|Array} `patterns` One or more glob patterns to use for matching. + * @param {Object} `options` See available [options](#options) for changing how matches are performed + * @return {Array} Returns an array of matches + * @summary false + * @api public + */ + +function micromatch(list, patterns, options) { + patterns = utils.arrayify(patterns); + list = utils.arrayify(list); + + var len = patterns.length; + if (list.length === 0 || len === 0) { + return []; + } + + if (len === 1) { + return micromatch.match(list, patterns[0], options); + } + + var omit = []; + var keep = []; + var idx = -1; + + while (++idx < len) { + var pattern = patterns[idx]; + + if (typeof pattern === 'string' && pattern.charCodeAt(0) === 33 /* ! */) { + omit.push.apply(omit, micromatch.match(list, pattern.slice(1), options)); + } else { + keep.push.apply(keep, micromatch.match(list, pattern, options)); + } + } + + var matches = utils.diff(keep, omit); + if (!options || options.nodupes !== false) { + return utils.unique(matches); + } + + return matches; +} + +/** + * Similar to the main function, but `pattern` must be a string. + * + * ```js + * var mm = require('micromatch'); + * mm.match(list, pattern[, options]); + * + * console.log(mm.match(['a.a', 'a.aa', 'a.b', 'a.c'], '*.a')); + * //=> ['a.a', 'a.aa'] + * ``` + * @param {Array} `list` Array of strings to match + * @param {String} `pattern` Glob pattern to use for matching. + * @param {Object} `options` See available [options](#options) for changing how matches are performed + * @return {Array} Returns an array of matches + * @api public + */ + +micromatch.match = function(list, pattern, options) { + if (Array.isArray(pattern)) { + throw new TypeError('expected pattern to be a string'); + } + + var unixify = utils.unixify(options); + var isMatch = memoize('match', pattern, options, micromatch.matcher); + var matches = []; + + list = utils.arrayify(list); + var len = list.length; + var idx = -1; + + while (++idx < len) { + var ele = list[idx]; + if (ele === pattern || isMatch(ele)) { + matches.push(utils.value(ele, unixify, options)); + } + } + + // if no options were passed, uniquify results and return + if (typeof options === 'undefined') { + return utils.unique(matches); + } + + if (matches.length === 0) { + if (options.failglob === true) { + throw new Error('no matches found for "' + pattern + '"'); + } + if (options.nonull === true || options.nullglob === true) { + return [options.unescape ? utils.unescape(pattern) : pattern]; + } + } + + // if `opts.ignore` was defined, diff ignored list + if (options.ignore) { + matches = micromatch.not(matches, options.ignore, options); + } + + return options.nodupes !== false ? utils.unique(matches) : matches; +}; + +/** + * Returns true if the specified `string` matches the given glob `pattern`. + * + * ```js + * var mm = require('micromatch'); + * mm.isMatch(string, pattern[, options]); + * + * console.log(mm.isMatch('a.a', '*.a')); + * //=> true + * console.log(mm.isMatch('a.b', '*.a')); + * //=> false + * ``` + * @param {String} `string` String to match + * @param {String} `pattern` Glob pattern to use for matching. + * @param {Object} `options` See available [options](#options) for changing how matches are performed + * @return {Boolean} Returns true if the string matches the glob pattern. + * @api public + */ + +micromatch.isMatch = function(str, pattern, options) { + if (typeof str !== 'string') { + throw new TypeError('expected a string: "' + util.inspect(str) + '"'); + } + + if (isEmptyString(str) || isEmptyString(pattern)) { + return false; + } + + var equals = utils.equalsPattern(options); + if (equals(str)) { + return true; + } + + var isMatch = memoize('isMatch', pattern, options, micromatch.matcher); + return isMatch(str); +}; + +/** + * Returns true if some of the strings in the given `list` match any of the + * given glob `patterns`. + * + * ```js + * var mm = require('micromatch'); + * mm.some(list, patterns[, options]); + * + * console.log(mm.some(['foo.js', 'bar.js'], ['*.js', '!foo.js'])); + * // true + * console.log(mm.some(['foo.js'], ['*.js', '!foo.js'])); + * // false + * ``` + * @param {String|Array} `list` The string or array of strings to test. Returns as soon as the first match is found. + * @param {String|Array} `patterns` One or more glob patterns to use for matching. + * @param {Object} `options` See available [options](#options) for changing how matches are performed + * @return {Boolean} Returns true if any patterns match `str` + * @api public + */ + +micromatch.some = function(list, patterns, options) { + if (typeof list === 'string') { + list = [list]; + } + for (var i = 0; i < list.length; i++) { + if (micromatch(list[i], patterns, options).length === 1) { + return true; + } + } + return false; +}; + +/** + * Returns true if every string in the given `list` matches + * any of the given glob `patterns`. + * + * ```js + * var mm = require('micromatch'); + * mm.every(list, patterns[, options]); + * + * console.log(mm.every('foo.js', ['foo.js'])); + * // true + * console.log(mm.every(['foo.js', 'bar.js'], ['*.js'])); + * // true + * console.log(mm.every(['foo.js', 'bar.js'], ['*.js', '!foo.js'])); + * // false + * console.log(mm.every(['foo.js'], ['*.js', '!foo.js'])); + * // false + * ``` + * @param {String|Array} `list` The string or array of strings to test. + * @param {String|Array} `patterns` One or more glob patterns to use for matching. + * @param {Object} `options` See available [options](#options) for changing how matches are performed + * @return {Boolean} Returns true if any patterns match `str` + * @api public + */ + +micromatch.every = function(list, patterns, options) { + if (typeof list === 'string') { + list = [list]; + } + for (var i = 0; i < list.length; i++) { + if (micromatch(list[i], patterns, options).length !== 1) { + return false; + } + } + return true; +}; + +/** + * Returns true if **any** of the given glob `patterns` + * match the specified `string`. + * + * ```js + * var mm = require('micromatch'); + * mm.any(string, patterns[, options]); + * + * console.log(mm.any('a.a', ['b.*', '*.a'])); + * //=> true + * console.log(mm.any('a.a', 'b.*')); + * //=> false + * ``` + * @param {String|Array} `str` The string to test. + * @param {String|Array} `patterns` One or more glob patterns to use for matching. + * @param {Object} `options` See available [options](#options) for changing how matches are performed + * @return {Boolean} Returns true if any patterns match `str` + * @api public + */ + +micromatch.any = function(str, patterns, options) { + if (typeof str !== 'string') { + throw new TypeError('expected a string: "' + util.inspect(str) + '"'); + } + + if (isEmptyString(str) || isEmptyString(patterns)) { + return false; + } + + if (typeof patterns === 'string') { + patterns = [patterns]; + } + + for (var i = 0; i < patterns.length; i++) { + if (micromatch.isMatch(str, patterns[i], options)) { + return true; + } + } + return false; +}; + +/** + * Returns true if **all** of the given `patterns` match + * the specified string. + * + * ```js + * var mm = require('micromatch'); + * mm.all(string, patterns[, options]); + * + * console.log(mm.all('foo.js', ['foo.js'])); + * // true + * + * console.log(mm.all('foo.js', ['*.js', '!foo.js'])); + * // false + * + * console.log(mm.all('foo.js', ['*.js', 'foo.js'])); + * // true + * + * console.log(mm.all('foo.js', ['*.js', 'f*', '*o*', '*o.js'])); + * // true + * ``` + * @param {String|Array} `str` The string to test. + * @param {String|Array} `patterns` One or more glob patterns to use for matching. + * @param {Object} `options` See available [options](#options) for changing how matches are performed + * @return {Boolean} Returns true if any patterns match `str` + * @api public + */ + +micromatch.all = function(str, patterns, options) { + if (typeof str !== 'string') { + throw new TypeError('expected a string: "' + util.inspect(str) + '"'); + } + if (typeof patterns === 'string') { + patterns = [patterns]; + } + for (var i = 0; i < patterns.length; i++) { + if (!micromatch.isMatch(str, patterns[i], options)) { + return false; + } + } + return true; +}; + +/** + * Returns a list of strings that _**do not match any**_ of the given `patterns`. + * + * ```js + * var mm = require('micromatch'); + * mm.not(list, patterns[, options]); + * + * console.log(mm.not(['a.a', 'b.b', 'c.c'], '*.a')); + * //=> ['b.b', 'c.c'] + * ``` + * @param {Array} `list` Array of strings to match. + * @param {String|Array} `patterns` One or more glob pattern to use for matching. + * @param {Object} `options` See available [options](#options) for changing how matches are performed + * @return {Array} Returns an array of strings that **do not match** the given patterns. + * @api public + */ + +micromatch.not = function(list, patterns, options) { + var opts = extend({}, options); + var ignore = opts.ignore; + delete opts.ignore; + + var unixify = utils.unixify(opts); + list = utils.arrayify(list).map(unixify); + + var matches = utils.diff(list, micromatch(list, patterns, opts)); + if (ignore) { + matches = utils.diff(matches, micromatch(list, ignore)); + } + + return opts.nodupes !== false ? utils.unique(matches) : matches; +}; + +/** + * Returns true if the given `string` contains the given pattern. Similar + * to [.isMatch](#isMatch) but the pattern can match any part of the string. + * + * ```js + * var mm = require('micromatch'); + * mm.contains(string, pattern[, options]); + * + * console.log(mm.contains('aa/bb/cc', '*b')); + * //=> true + * console.log(mm.contains('aa/bb/cc', '*d')); + * //=> false + * ``` + * @param {String} `str` The string to match. + * @param {String|Array} `patterns` Glob pattern to use for matching. + * @param {Object} `options` See available [options](#options) for changing how matches are performed + * @return {Boolean} Returns true if the patter matches any part of `str`. + * @api public + */ + +micromatch.contains = function(str, patterns, options) { + if (typeof str !== 'string') { + throw new TypeError('expected a string: "' + util.inspect(str) + '"'); + } + + if (typeof patterns === 'string') { + if (isEmptyString(str) || isEmptyString(patterns)) { + return false; + } + + var equals = utils.equalsPattern(patterns, options); + if (equals(str)) { + return true; + } + var contains = utils.containsPattern(patterns, options); + if (contains(str)) { + return true; + } + } + + var opts = extend({}, options, {contains: true}); + return micromatch.any(str, patterns, opts); +}; + +/** + * Returns true if the given pattern and options should enable + * the `matchBase` option. + * @return {Boolean} + * @api private + */ + +micromatch.matchBase = function(pattern, options) { + if (pattern && pattern.indexOf('/') !== -1 || !options) return false; + return options.basename === true || options.matchBase === true; +}; + +/** + * Filter the keys of the given object with the given `glob` pattern + * and `options`. Does not attempt to match nested keys. If you need this feature, + * use [glob-object][] instead. + * + * ```js + * var mm = require('micromatch'); + * mm.matchKeys(object, patterns[, options]); + * + * var obj = { aa: 'a', ab: 'b', ac: 'c' }; + * console.log(mm.matchKeys(obj, '*b')); + * //=> { ab: 'b' } + * ``` + * @param {Object} `object` The object with keys to filter. + * @param {String|Array} `patterns` One or more glob patterns to use for matching. + * @param {Object} `options` See available [options](#options) for changing how matches are performed + * @return {Object} Returns an object with only keys that match the given patterns. + * @api public + */ + +micromatch.matchKeys = function(obj, patterns, options) { + if (!utils.isObject(obj)) { + throw new TypeError('expected the first argument to be an object'); + } + var keys = micromatch(Object.keys(obj), patterns, options); + return utils.pick(obj, keys); +}; + +/** + * Returns a memoized matcher function from the given glob `pattern` and `options`. + * The returned function takes a string to match as its only argument and returns + * true if the string is a match. + * + * ```js + * var mm = require('micromatch'); + * mm.matcher(pattern[, options]); + * + * var isMatch = mm.matcher('*.!(*a)'); + * console.log(isMatch('a.a')); + * //=> false + * console.log(isMatch('a.b')); + * //=> true + * ``` + * @param {String} `pattern` Glob pattern + * @param {Object} `options` See available [options](#options) for changing how matches are performed. + * @return {Function} Returns a matcher function. + * @api public + */ + +micromatch.matcher = function matcher(pattern, options) { + if (Array.isArray(pattern)) { + return compose(pattern, options, matcher); + } + + // if pattern is a regex + if (pattern instanceof RegExp) { + return test(pattern); + } + + // if pattern is invalid + if (!utils.isString(pattern)) { + throw new TypeError('expected pattern to be an array, string or regex'); + } + + // if pattern is a non-glob string + if (!utils.hasSpecialChars(pattern)) { + if (options && options.nocase === true) { + pattern = pattern.toLowerCase(); + } + return utils.matchPath(pattern, options); + } + + // if pattern is a glob string + var re = micromatch.makeRe(pattern, options); + + // if `options.matchBase` or `options.basename` is defined + if (micromatch.matchBase(pattern, options)) { + return utils.matchBasename(re, options); + } + + function test(regex) { + var equals = utils.equalsPattern(options); + var unixify = utils.unixify(options); + + return function(str) { + if (equals(str)) { + return true; + } + + if (regex.test(unixify(str))) { + return true; + } + return false; + }; + } + + var fn = test(re); + Object.defineProperty(fn, 'result', { + configurable: true, + enumerable: false, + value: re.result + }); + return fn; +}; + +/** + * Returns an array of matches captured by `pattern` in `string, or `null` if the pattern did not match. + * + * ```js + * var mm = require('micromatch'); + * mm.capture(pattern, string[, options]); + * + * console.log(mm.capture('test/*.js', 'test/foo.js')); + * //=> ['foo'] + * console.log(mm.capture('test/*.js', 'foo/bar.css')); + * //=> null + * ``` + * @param {String} `pattern` Glob pattern to use for matching. + * @param {String} `string` String to match + * @param {Object} `options` See available [options](#options) for changing how matches are performed + * @return {Boolean} Returns an array of captures if the string matches the glob pattern, otherwise `null`. + * @api public + */ + +micromatch.capture = function(pattern, str, options) { + var re = micromatch.makeRe(pattern, extend({capture: true}, options)); + var unixify = utils.unixify(options); + + function match() { + return function(string) { + var match = re.exec(unixify(string)); + if (!match) { + return null; + } + + return match.slice(1); + }; + } + + var capture = memoize('capture', pattern, options, match); + return capture(str); +}; + +/** + * Create a regular expression from the given glob `pattern`. + * + * ```js + * var mm = require('micromatch'); + * mm.makeRe(pattern[, options]); + * + * console.log(mm.makeRe('*.js')); + * //=> /^(?:(\.[\\\/])?(?!\.)(?=.)[^\/]*?\.js)$/ + * ``` + * @param {String} `pattern` A glob pattern to convert to regex. + * @param {Object} `options` See available [options](#options) for changing how matches are performed. + * @return {RegExp} Returns a regex created from the given pattern. + * @api public + */ + +micromatch.makeRe = function(pattern, options) { + if (typeof pattern !== 'string') { + throw new TypeError('expected pattern to be a string'); + } + + if (pattern.length > MAX_LENGTH) { + throw new Error('expected pattern to be less than ' + MAX_LENGTH + ' characters'); + } + + function makeRe() { + var result = micromatch.create(pattern, options); + var ast_array = []; + var output = result.map(function(obj) { + obj.ast.state = obj.state; + ast_array.push(obj.ast); + return obj.output; + }); + + var regex = toRegex(output.join('|'), options); + Object.defineProperty(regex, 'result', { + configurable: true, + enumerable: false, + value: ast_array + }); + return regex; + } + + return memoize('makeRe', pattern, options, makeRe); +}; + +/** + * Expand the given brace `pattern`. + * + * ```js + * var mm = require('micromatch'); + * console.log(mm.braces('foo/{a,b}/bar')); + * //=> ['foo/(a|b)/bar'] + * + * console.log(mm.braces('foo/{a,b}/bar', {expand: true})); + * //=> ['foo/(a|b)/bar'] + * ``` + * @param {String} `pattern` String with brace pattern to expand. + * @param {Object} `options` Any [options](#options) to change how expansion is performed. See the [braces][] library for all available options. + * @return {Array} + * @api public + */ + +micromatch.braces = function(pattern, options) { + if (typeof pattern !== 'string' && !Array.isArray(pattern)) { + throw new TypeError('expected pattern to be an array or string'); + } + + function expand() { + if (options && options.nobrace === true || !/\{.*\}/.test(pattern)) { + return utils.arrayify(pattern); + } + return braces(pattern, options); + } + + return memoize('braces', pattern, options, expand); +}; + +/** + * Proxy to the [micromatch.braces](#method), for parity with + * minimatch. + */ + +micromatch.braceExpand = function(pattern, options) { + var opts = extend({}, options, {expand: true}); + return micromatch.braces(pattern, opts); +}; + +/** + * Parses the given glob `pattern` and returns an array of abstract syntax + * trees (ASTs), with the compiled `output` and optional source `map` on + * each AST. + * + * ```js + * var mm = require('micromatch'); + * mm.create(pattern[, options]); + * + * console.log(mm.create('abc/*.js')); + * // [{ options: { source: 'string', sourcemap: true }, + * // state: {}, + * // compilers: + * // { ... }, + * // output: '(\\.[\\\\\\/])?abc\\/(?!\\.)(?=.)[^\\/]*?\\.js', + * // ast: + * // { type: 'root', + * // errors: [], + * // nodes: + * // [ ... ], + * // dot: false, + * // input: 'abc/*.js' }, + * // parsingErrors: [], + * // map: + * // { version: 3, + * // sources: [ 'string' ], + * // names: [], + * // mappings: 'AAAA,GAAG,EAAC,kBAAC,EAAC,EAAE', + * // sourcesContent: [ 'abc/*.js' ] }, + * // position: { line: 1, column: 28 }, + * // content: {}, + * // files: {}, + * // idx: 6 }] + * ``` + * @param {String} `pattern` Glob pattern to parse and compile. + * @param {Object} `options` Any [options](#options) to change how parsing and compiling is performed. + * @return {Object} Returns an object with the parsed AST, compiled string and optional source map. + * @api public + */ + +micromatch.create = function(pattern, options) { + return memoize('create', pattern, options, function() { + function create(str, opts) { + return micromatch.compile(micromatch.parse(str, opts), opts); + } + + pattern = micromatch.braces(pattern, options); + var len = pattern.length; + var idx = -1; + var res = []; + + while (++idx < len) { + res.push(create(pattern[idx], options)); + } + return res; + }); +}; + +/** + * Parse the given `str` with the given `options`. + * + * ```js + * var mm = require('micromatch'); + * mm.parse(pattern[, options]); + * + * var ast = mm.parse('a/{b,c}/d'); + * console.log(ast); + * // { type: 'root', + * // errors: [], + * // input: 'a/{b,c}/d', + * // nodes: + * // [ { type: 'bos', val: '' }, + * // { type: 'text', val: 'a/' }, + * // { type: 'brace', + * // nodes: + * // [ { type: 'brace.open', val: '{' }, + * // { type: 'text', val: 'b,c' }, + * // { type: 'brace.close', val: '}' } ] }, + * // { type: 'text', val: '/d' }, + * // { type: 'eos', val: '' } ] } + * ``` + * @param {String} `str` + * @param {Object} `options` + * @return {Object} Returns an AST + * @api public + */ + +micromatch.parse = function(pattern, options) { + if (typeof pattern !== 'string') { + throw new TypeError('expected a string'); + } + + function parse() { + var snapdragon = utils.instantiate(null, options); + parsers(snapdragon, options); + + var ast = snapdragon.parse(pattern, options); + utils.define(ast, 'snapdragon', snapdragon); + ast.input = pattern; + return ast; + } + + return memoize('parse', pattern, options, parse); +}; + +/** + * Compile the given `ast` or string with the given `options`. + * + * ```js + * var mm = require('micromatch'); + * mm.compile(ast[, options]); + * + * var ast = mm.parse('a/{b,c}/d'); + * console.log(mm.compile(ast)); + * // { options: { source: 'string' }, + * // state: {}, + * // compilers: + * // { eos: [Function], + * // noop: [Function], + * // bos: [Function], + * // brace: [Function], + * // 'brace.open': [Function], + * // text: [Function], + * // 'brace.close': [Function] }, + * // output: [ 'a/(b|c)/d' ], + * // ast: + * // { ... }, + * // parsingErrors: [] } + * ``` + * @param {Object|String} `ast` + * @param {Object} `options` + * @return {Object} Returns an object that has an `output` property with the compiled string. + * @api public + */ + +micromatch.compile = function(ast, options) { + if (typeof ast === 'string') { + ast = micromatch.parse(ast, options); + } + + return memoize('compile', ast.input, options, function() { + var snapdragon = utils.instantiate(ast, options); + compilers(snapdragon, options); + return snapdragon.compile(ast, options); + }); +}; + +/** + * Clear the regex cache. + * + * ```js + * mm.clearCache(); + * ``` + * @api public + */ + +micromatch.clearCache = function() { + micromatch.cache.caches = {}; +}; + +/** + * Returns true if the given value is effectively an empty string + */ + +function isEmptyString(val) { + return String(val) === '' || String(val) === './'; +} + +/** + * Compose a matcher function with the given patterns. + * This allows matcher functions to be compiled once and + * called multiple times. + */ + +function compose(patterns, options, matcher) { + var matchers; + + return memoize('compose', String(patterns), options, function() { + return function(file) { + // delay composition until it's invoked the first time, + // after that it won't be called again + if (!matchers) { + matchers = []; + for (var i = 0; i < patterns.length; i++) { + matchers.push(matcher(patterns[i], options)); + } + } + + var len = matchers.length; + while (len--) { + if (matchers[len](file) === true) { + return true; + } + } + return false; + }; + }); +} + +/** + * Memoize a generated regex or function. A unique key is generated + * from the `type` (usually method name), the `pattern`, and + * user-defined options. + */ + +function memoize(type, pattern, options, fn) { + var key = utils.createKey(type + '=' + pattern, options); + + if (options && options.cache === false) { + return fn(pattern, options); + } + + if (cache.has(type, key)) { + return cache.get(type, key); + } + + var val = fn(pattern, options); + cache.set(type, key, val); + return val; +} + +/** + * Expose compiler, parser and cache on `micromatch` + */ + +micromatch.compilers = compilers; +micromatch.parsers = parsers; +micromatch.caches = cache.caches; + +/** + * Expose `micromatch` + * @type {Function} + */ + +module.exports = micromatch; diff --git a/node_modules/anymatch/node_modules/micromatch/lib/cache.js b/node_modules/anymatch/node_modules/micromatch/lib/cache.js new file mode 100644 index 0000000000..fffc4c17a6 --- /dev/null +++ b/node_modules/anymatch/node_modules/micromatch/lib/cache.js @@ -0,0 +1 @@ +module.exports = new (require('fragment-cache'))(); diff --git a/node_modules/anymatch/node_modules/micromatch/lib/compilers.js b/node_modules/anymatch/node_modules/micromatch/lib/compilers.js new file mode 100644 index 0000000000..85cda4f88f --- /dev/null +++ b/node_modules/anymatch/node_modules/micromatch/lib/compilers.js @@ -0,0 +1,77 @@ +'use strict'; + +var nanomatch = require('nanomatch'); +var extglob = require('extglob'); + +module.exports = function(snapdragon) { + var compilers = snapdragon.compiler.compilers; + var opts = snapdragon.options; + + // register nanomatch compilers + snapdragon.use(nanomatch.compilers); + + // get references to some specific nanomatch compilers before they + // are overridden by the extglob and/or custom compilers + var escape = compilers.escape; + var qmark = compilers.qmark; + var slash = compilers.slash; + var star = compilers.star; + var text = compilers.text; + var plus = compilers.plus; + var dot = compilers.dot; + + // register extglob compilers or escape exglobs if disabled + if (opts.extglob === false || opts.noext === true) { + snapdragon.compiler.use(escapeExtglobs); + } else { + snapdragon.use(extglob.compilers); + } + + snapdragon.use(function() { + this.options.star = this.options.star || function(/*node*/) { + return '[^\\\\/]*?'; + }; + }); + + // custom micromatch compilers + snapdragon.compiler + + // reset referenced compiler + .set('dot', dot) + .set('escape', escape) + .set('plus', plus) + .set('slash', slash) + .set('qmark', qmark) + .set('star', star) + .set('text', text); +}; + +function escapeExtglobs(compiler) { + compiler.set('paren', function(node) { + var val = ''; + visit(node, function(tok) { + if (tok.val) val += (/^\W/.test(tok.val) ? '\\' : '') + tok.val; + }); + return this.emit(val, node); + }); + + /** + * Visit `node` with the given `fn` + */ + + function visit(node, fn) { + return node.nodes ? mapVisit(node.nodes, fn) : fn(node); + } + + /** + * Map visit over array of `nodes`. + */ + + function mapVisit(nodes, fn) { + var len = nodes.length; + var idx = -1; + while (++idx < len) { + visit(nodes[idx], fn); + } + } +} diff --git a/node_modules/anymatch/node_modules/micromatch/lib/parsers.js b/node_modules/anymatch/node_modules/micromatch/lib/parsers.js new file mode 100644 index 0000000000..f80498ceef --- /dev/null +++ b/node_modules/anymatch/node_modules/micromatch/lib/parsers.js @@ -0,0 +1,83 @@ +'use strict'; + +var extglob = require('extglob'); +var nanomatch = require('nanomatch'); +var regexNot = require('regex-not'); +var toRegex = require('to-regex'); +var not; + +/** + * Characters to use in negation regex (we want to "not" match + * characters that are matched by other parsers) + */ + +var TEXT = '([!@*?+]?\\(|\\)|\\[:?(?=.*?:?\\])|:?\\]|[*+?!^$.\\\\/])+'; +var createNotRegex = function(opts) { + return not || (not = textRegex(TEXT)); +}; + +/** + * Parsers + */ + +module.exports = function(snapdragon) { + var parsers = snapdragon.parser.parsers; + + // register nanomatch parsers + snapdragon.use(nanomatch.parsers); + + // get references to some specific nanomatch parsers before they + // are overridden by the extglob and/or parsers + var escape = parsers.escape; + var slash = parsers.slash; + var qmark = parsers.qmark; + var plus = parsers.plus; + var star = parsers.star; + var dot = parsers.dot; + + // register extglob parsers + snapdragon.use(extglob.parsers); + + // custom micromatch parsers + snapdragon.parser + .use(function() { + // override "notRegex" created in nanomatch parser + this.notRegex = /^\!+(?!\()/; + }) + // reset the referenced parsers + .capture('escape', escape) + .capture('slash', slash) + .capture('qmark', qmark) + .capture('star', star) + .capture('plus', plus) + .capture('dot', dot) + + /** + * Override `text` parser + */ + + .capture('text', function() { + if (this.isInside('bracket')) return; + var pos = this.position(); + var m = this.match(createNotRegex(this.options)); + if (!m || !m[0]) return; + + // escape regex boundary characters and simple brackets + var val = m[0].replace(/([[\]^$])/g, '\\$1'); + + return pos({ + type: 'text', + val: val + }); + }); +}; + +/** + * Create text regex + */ + +function textRegex(pattern) { + var notStr = regexNot.create(pattern, {contains: true, strictClose: false}); + var prefix = '(?:[\\^]|\\\\|'; + return toRegex(prefix + notStr + ')', {strictClose: false}); +} diff --git a/node_modules/anymatch/node_modules/micromatch/lib/utils.js b/node_modules/anymatch/node_modules/micromatch/lib/utils.js new file mode 100644 index 0000000000..f0ba9177a3 --- /dev/null +++ b/node_modules/anymatch/node_modules/micromatch/lib/utils.js @@ -0,0 +1,309 @@ +'use strict'; + +var utils = module.exports; +var path = require('path'); + +/** + * Module dependencies + */ + +var Snapdragon = require('snapdragon'); +utils.define = require('define-property'); +utils.diff = require('arr-diff'); +utils.extend = require('extend-shallow'); +utils.pick = require('object.pick'); +utils.typeOf = require('kind-of'); +utils.unique = require('array-unique'); + +/** + * Returns true if the platform is windows, or `path.sep` is `\\`. + * This is defined as a function to allow `path.sep` to be set in unit tests, + * or by the user, if there is a reason to do so. + * @return {Boolean} + */ + +utils.isWindows = function() { + return path.sep === '\\' || process.platform === 'win32'; +}; + +/** + * Get the `Snapdragon` instance to use + */ + +utils.instantiate = function(ast, options) { + var snapdragon; + // if an instance was created by `.parse`, use that instance + if (utils.typeOf(ast) === 'object' && ast.snapdragon) { + snapdragon = ast.snapdragon; + // if the user supplies an instance on options, use that instance + } else if (utils.typeOf(options) === 'object' && options.snapdragon) { + snapdragon = options.snapdragon; + // create a new instance + } else { + snapdragon = new Snapdragon(options); + } + + utils.define(snapdragon, 'parse', function(str, options) { + var parsed = Snapdragon.prototype.parse.apply(this, arguments); + parsed.input = str; + + // escape unmatched brace/bracket/parens + var last = this.parser.stack.pop(); + if (last && this.options.strictErrors !== true) { + var open = last.nodes[0]; + var inner = last.nodes[1]; + if (last.type === 'bracket') { + if (inner.val.charAt(0) === '[') { + inner.val = '\\' + inner.val; + } + + } else { + open.val = '\\' + open.val; + var sibling = open.parent.nodes[1]; + if (sibling.type === 'star') { + sibling.loose = true; + } + } + } + + // add non-enumerable parser reference + utils.define(parsed, 'parser', this.parser); + return parsed; + }); + + return snapdragon; +}; + +/** + * Create the key to use for memoization. The key is generated + * by iterating over the options and concatenating key-value pairs + * to the pattern string. + */ + +utils.createKey = function(pattern, options) { + if (utils.typeOf(options) !== 'object') { + return pattern; + } + var val = pattern; + var keys = Object.keys(options); + for (var i = 0; i < keys.length; i++) { + var key = keys[i]; + val += ';' + key + '=' + String(options[key]); + } + return val; +}; + +/** + * Cast `val` to an array + * @return {Array} + */ + +utils.arrayify = function(val) { + if (typeof val === 'string') return [val]; + return val ? (Array.isArray(val) ? val : [val]) : []; +}; + +/** + * Return true if `val` is a non-empty string + */ + +utils.isString = function(val) { + return typeof val === 'string'; +}; + +/** + * Return true if `val` is a non-empty string + */ + +utils.isObject = function(val) { + return utils.typeOf(val) === 'object'; +}; + +/** + * Returns true if the given `str` has special characters + */ + +utils.hasSpecialChars = function(str) { + return /(?:(?:(^|\/)[!.])|[*?+()|\[\]{}]|[+@]\()/.test(str); +}; + +/** + * Escape regex characters in the given string + */ + +utils.escapeRegex = function(str) { + return str.replace(/[-[\]{}()^$|*+?.\\\/\s]/g, '\\$&'); +}; + +/** + * Normalize slashes in the given filepath. + * + * @param {String} `filepath` + * @return {String} + */ + +utils.toPosixPath = function(str) { + return str.replace(/\\+/g, '/'); +}; + +/** + * Strip backslashes before special characters in a string. + * + * @param {String} `str` + * @return {String} + */ + +utils.unescape = function(str) { + return utils.toPosixPath(str.replace(/\\(?=[*+?!.])/g, '')); +}; + +/** + * Strip the prefix from a filepath + * @param {String} `fp` + * @return {String} + */ + +utils.stripPrefix = function(str) { + if (str.charAt(0) !== '.') { + return str; + } + var ch = str.charAt(1); + if (utils.isSlash(ch)) { + return str.slice(2); + } + return str; +}; + +/** + * Returns true if the given str is an escaped or + * unescaped path character + */ + +utils.isSlash = function(str) { + return str === '/' || str === '\\/' || str === '\\' || str === '\\\\'; +}; + +/** + * Returns a function that returns true if the given + * pattern matches or contains a `filepath` + * + * @param {String} `pattern` + * @return {Function} + */ + +utils.matchPath = function(pattern, options) { + return (options && options.contains) + ? utils.containsPattern(pattern, options) + : utils.equalsPattern(pattern, options); +}; + +/** + * Returns true if the given (original) filepath or unixified path are equal + * to the given pattern. + */ + +utils._equals = function(filepath, unixPath, pattern) { + return pattern === filepath || pattern === unixPath; +}; + +/** + * Returns true if the given (original) filepath or unixified path contain + * the given pattern. + */ + +utils._contains = function(filepath, unixPath, pattern) { + return filepath.indexOf(pattern) !== -1 || unixPath.indexOf(pattern) !== -1; +}; + +/** + * Returns a function that returns true if the given + * pattern is the same as a given `filepath` + * + * @param {String} `pattern` + * @return {Function} + */ + +utils.equalsPattern = function(pattern, options) { + var unixify = utils.unixify(options); + options = options || {}; + + return function fn(filepath) { + var equal = utils._equals(filepath, unixify(filepath), pattern); + if (equal === true || options.nocase !== true) { + return equal; + } + var lower = filepath.toLowerCase(); + return utils._equals(lower, unixify(lower), pattern); + }; +}; + +/** + * Returns a function that returns true if the given + * pattern contains a `filepath` + * + * @param {String} `pattern` + * @return {Function} + */ + +utils.containsPattern = function(pattern, options) { + var unixify = utils.unixify(options); + options = options || {}; + + return function(filepath) { + var contains = utils._contains(filepath, unixify(filepath), pattern); + if (contains === true || options.nocase !== true) { + return contains; + } + var lower = filepath.toLowerCase(); + return utils._contains(lower, unixify(lower), pattern); + }; +}; + +/** + * Returns a function that returns true if the given + * regex matches the `filename` of a file path. + * + * @param {RegExp} `re` Matching regex + * @return {Function} + */ + +utils.matchBasename = function(re) { + return function(filepath) { + return re.test(path.basename(filepath)); + }; +}; + +/** + * Determines the filepath to return based on the provided options. + * @return {any} + */ + +utils.value = function(str, unixify, options) { + if (options && options.unixify === false) { + return str; + } + return unixify(str); +}; + +/** + * Returns a function that normalizes slashes in a string to forward + * slashes, strips `./` from beginning of paths, and optionally unescapes + * special characters. + * @return {Function} + */ + +utils.unixify = function(options) { + options = options || {}; + return function(filepath) { + if (utils.isWindows() || options.unixify === true) { + filepath = utils.toPosixPath(filepath); + } + if (options.stripPrefix !== false) { + filepath = utils.stripPrefix(filepath); + } + if (options.unescape === true) { + filepath = utils.unescape(filepath); + } + return filepath; + }; +}; diff --git a/node_modules/anymatch/node_modules/micromatch/package.json b/node_modules/anymatch/node_modules/micromatch/package.json new file mode 100644 index 0000000000..6e8e62fe14 --- /dev/null +++ b/node_modules/anymatch/node_modules/micromatch/package.json @@ -0,0 +1,216 @@ +{ + "_from": "micromatch@^3.1.4", + "_id": "micromatch@3.1.10", + "_inBundle": false, + "_integrity": "sha512-MWikgl9n9M3w+bpsY3He8L+w9eF9338xRl8IAO5viDizwSzziFEyUzo2xrrloB64ADbTf8uA8vRqqttDTOmccg==", + "_location": "/anymatch/micromatch", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "micromatch@^3.1.4", + "name": "micromatch", + "escapedName": "micromatch", + "rawSpec": "^3.1.4", + "saveSpec": null, + "fetchSpec": "^3.1.4" + }, + "_requiredBy": [ + "/anymatch" + ], + "_resolved": "https://registry.npmjs.org/micromatch/-/micromatch-3.1.10.tgz", + "_shasum": "70859bc95c9840952f359a068a3fc49f9ecfac23", + "_spec": "micromatch@^3.1.4", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/anymatch", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/micromatch/micromatch/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "Amila Welihinda", + "url": "amilajack.com" + }, + { + "name": "Bogdan Chadkin", + "url": "https://github.com/TrySound" + }, + { + "name": "Brian Woodward", + "url": "https://twitter.com/doowb" + }, + { + "name": "Devon Govett", + "url": "http://badassjs.com" + }, + { + "name": "Elan Shanker", + "url": "https://github.com/es128" + }, + { + "name": "Fabrício Matté", + "url": "https://ultcombo.js.org" + }, + { + "name": "Jon Schlinkert", + "url": "http://twitter.com/jonschlinkert" + }, + { + "name": "Martin Kolárik", + "url": "https://kolarik.sk" + }, + { + "name": "Olsten Larck", + "url": "https://i.am.charlike.online" + }, + { + "name": "Paul Miller", + "url": "paulmillr.com" + }, + { + "name": "Tom Byrer", + "url": "https://github.com/tomByrer" + }, + { + "name": "Tyler Akins", + "url": "http://rumkin.com" + }, + { + "url": "https://github.com/DianeLooney" + } + ], + "dependencies": { + "arr-diff": "^4.0.0", + "array-unique": "^0.3.2", + "braces": "^2.3.1", + "define-property": "^2.0.2", + "extend-shallow": "^3.0.2", + "extglob": "^2.0.4", + "fragment-cache": "^0.2.1", + "kind-of": "^6.0.2", + "nanomatch": "^1.2.9", + "object.pick": "^1.3.0", + "regex-not": "^1.0.0", + "snapdragon": "^0.8.1", + "to-regex": "^3.0.2" + }, + "deprecated": false, + "description": "Glob matching for javascript/node.js. A drop-in replacement and faster alternative to minimatch and multimatch.", + "devDependencies": { + "bash-match": "^1.0.2", + "for-own": "^1.0.0", + "gulp": "^3.9.1", + "gulp-format-md": "^1.0.0", + "gulp-istanbul": "^1.1.3", + "gulp-mocha": "^5.0.0", + "gulp-unused": "^0.2.1", + "is-windows": "^1.0.2", + "minimatch": "^3.0.4", + "minimist": "^1.2.0", + "mocha": "^3.5.3", + "multimatch": "^2.1.0" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js", + "lib" + ], + "homepage": "https://github.com/micromatch/micromatch", + "keywords": [ + "bash", + "expand", + "expansion", + "expression", + "file", + "files", + "filter", + "find", + "glob", + "globbing", + "globs", + "globstar", + "match", + "matcher", + "matches", + "matching", + "micromatch", + "minimatch", + "multimatch", + "path", + "pattern", + "patterns", + "regex", + "regexp", + "regular", + "shell", + "wildcard" + ], + "license": "MIT", + "lintDeps": { + "dependencies": { + "options": { + "lock": { + "snapdragon": "^0.8.1" + } + } + }, + "devDependencies": { + "files": { + "options": { + "ignore": [ + "benchmark/**" + ] + } + } + } + }, + "main": "index.js", + "name": "micromatch", + "repository": { + "type": "git", + "url": "git+https://github.com/micromatch/micromatch.git" + }, + "scripts": { + "test": "mocha" + }, + "verb": { + "toc": "collapsible", + "layout": "default", + "tasks": [ + "readme" + ], + "plugins": [ + "gulp-format-md" + ], + "helpers": [ + "./benchmark/helper.js" + ], + "related": { + "list": [ + "braces", + "expand-brackets", + "extglob", + "fill-range", + "nanomatch" + ] + }, + "lint": { + "reflinks": true + }, + "reflinks": [ + "expand-brackets", + "extglob", + "glob-object", + "minimatch", + "multimatch", + "snapdragon" + ] + }, + "version": "3.1.10" +} diff --git a/node_modules/anymatch/package.json b/node_modules/anymatch/package.json new file mode 100644 index 0000000000..d9ef9fa874 --- /dev/null +++ b/node_modules/anymatch/package.json @@ -0,0 +1,88 @@ +{ + "_from": "anymatch@^2.0.0", + "_id": "anymatch@2.0.0", + "_inBundle": false, + "_integrity": "sha512-5teOsQWABXHHBFP9y3skS5P3d/WfWXpv3FUpy+LorMrNYaT9pI4oLMQX7jzQ2KklNpGpWHzdCXTDT2Y3XGlZBw==", + "_location": "/anymatch", + "_phantomChildren": { + "arr-diff": "4.0.0", + "array-unique": "0.3.2", + "braces": "2.3.2", + "define-property": "2.0.2", + "expand-brackets": "2.1.4", + "extend-shallow": "3.0.2", + "fragment-cache": "0.2.1", + "is-extendable": "0.1.1", + "kind-of": "6.0.2", + "nanomatch": "1.2.13", + "object.pick": "1.3.0", + "regex-not": "1.0.2", + "snapdragon": "0.8.2", + "to-regex": "3.0.2" + }, + "_requested": { + "type": "range", + "registry": true, + "raw": "anymatch@^2.0.0", + "name": "anymatch", + "escapedName": "anymatch", + "rawSpec": "^2.0.0", + "saveSpec": null, + "fetchSpec": "^2.0.0" + }, + "_requiredBy": [ + "/chokidar", + "/glob-watcher" + ], + "_resolved": "https://registry.npmjs.org/anymatch/-/anymatch-2.0.0.tgz", + "_shasum": "bcb24b4f37934d9aa7ac17b4adaf89e7c76ef2eb", + "_spec": "anymatch@^2.0.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/glob-watcher", + "author": { + "name": "Elan Shanker", + "url": "http://github.com/es128" + }, + "bugs": { + "url": "https://github.com/micromatch/anymatch/issues" + }, + "bundleDependencies": false, + "dependencies": { + "micromatch": "^3.1.4", + "normalize-path": "^2.1.1" + }, + "deprecated": false, + "description": "Matches strings against configurable strings, globs, regular expressions, and/or functions", + "devDependencies": { + "coveralls": "^2.7.0", + "istanbul": "^0.4.5", + "mocha": "^3.0.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/micromatch/anymatch", + "keywords": [ + "match", + "any", + "string", + "file", + "fs", + "list", + "glob", + "regex", + "regexp", + "regular", + "expression", + "function" + ], + "license": "ISC", + "name": "anymatch", + "repository": { + "type": "git", + "url": "git+https://github.com/micromatch/anymatch.git" + }, + "scripts": { + "test": "istanbul cover _mocha && cat ./coverage/lcov.info | coveralls" + }, + "version": "2.0.0" +} diff --git a/node_modules/append-buffer/LICENSE b/node_modules/append-buffer/LICENSE new file mode 100644 index 0000000000..ffb7ec5909 --- /dev/null +++ b/node_modules/append-buffer/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2017, Brian Woodward. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. \ No newline at end of file diff --git a/node_modules/append-buffer/README.md b/node_modules/append-buffer/README.md new file mode 100644 index 0000000000..681a3c36fc --- /dev/null +++ b/node_modules/append-buffer/README.md @@ -0,0 +1,95 @@ +# append-buffer [![NPM version](https://img.shields.io/npm/v/append-buffer.svg?style=flat)](https://www.npmjs.com/package/append-buffer) [![NPM monthly downloads](https://img.shields.io/npm/dm/append-buffer.svg?style=flat)](https://npmjs.org/package/append-buffer) [![NPM total downloads](https://img.shields.io/npm/dt/append-buffer.svg?style=flat)](https://npmjs.org/package/append-buffer) [![Linux Build Status](https://img.shields.io/travis/doowb/append-buffer.svg?style=flat&label=Travis)](https://travis-ci.org/doowb/append-buffer) [![Windows Build Status](https://img.shields.io/appveyor/ci/doowb/append-buffer.svg?style=flat&label=AppVeyor)](https://ci.appveyor.com/project/doowb/append-buffer) + +> Append a buffer to another buffer ensuring to preserve line ending characters. + +## Install + +Install with [npm](https://www.npmjs.com/): + +```sh +$ npm install --save append-buffer +``` + +Install with [yarn](https://yarnpkg.com): + +```sh +$ yarn add append-buffer +``` + +## Usage + +```js +var appendBuffer = require('append-buffer'); +``` + +## API + +### [appendBuffer](index.js#L28) + +Append a buffer to another buffer ensuring to preserve line ending characters. + +**Params** + +* `buf` **{Buffer}**: Buffer that will be used to check for an existing line ending. The suffix is appended to this. +* `suffix` **{Buffer}**: Buffer that will be appended to the buf. +* `returns` **{Buffer}**: Final Buffer + +**Example** + +```js +console.log([appendBuffer(new Buffer('abc\r\n'), new Buffer('def')).toString()]); +//=> [ 'abc\r\ndef\r\n' ] + +console.log([appendBuffer(new Buffer('abc\n'), new Buffer('def')).toString()]); +//=> [ 'abc\ndef\n' ] + +// uses os.EOL when a line ending is not found +console.log([appendBuffer(new Buffer('abc'), new Buffer('def')).toString()]); +//=> [ 'abc\ndef' ] +``` + +## Attribution + +The code in this module was originally added in a [PR](https://github.com/jonschlinkert/file-normalize/pull/3) to [file-normalize](https://github.com/jonschlinkert/file-normalize). It has been split out to allow for standalone use cases. + +## About + +### Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new). + +Please read the [contributing guide](.github/contributing.md) for advice on opening issues, pull requests, and coding standards. + +### Building docs + +_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_ + +To generate the readme, run the following command: + +```sh +$ npm install -g verbose/verb#dev verb-generate-readme && verb +``` + +### Running tests + +Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command: + +```sh +$ npm install && npm test +``` + +### Author + +**Brian Woodward** + +* [github/doowb](https://github.com/doowb) +* [twitter/doowb](https://twitter.com/doowb) + +### License + +Copyright © 2017, [Brian Woodward](https://doowb.com). +Released under the [MIT License](LICENSE). + +*** + +_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.6.0, on August 01, 2017._ \ No newline at end of file diff --git a/node_modules/append-buffer/index.js b/node_modules/append-buffer/index.js new file mode 100644 index 0000000000..a385570bbd --- /dev/null +++ b/node_modules/append-buffer/index.js @@ -0,0 +1,41 @@ +'use strict'; + +var os = require('os'); +var equals = require('buffer-equal'); +var cr = new Buffer('\r\n'); +var nl = new Buffer('\n'); + +/** + * Append a buffer to another buffer ensuring to preserve line ending characters. + * + * ```js + * console.log([appendBuffer(new Buffer('abc\r\n'), new Buffer('def')).toString()]); + * //=> [ 'abc\r\ndef\r\n' ] + * + * console.log([appendBuffer(new Buffer('abc\n'), new Buffer('def')).toString()]); + * //=> [ 'abc\ndef\n' ] + * + * // uses os.EOL when a line ending is not found + * console.log([appendBuffer(new Buffer('abc'), new Buffer('def')).toString()]); + * //=> [ 'abc\ndef' ] + * * ``` + * @param {Buffer} `buf` Buffer that will be used to check for an existing line ending. The suffix is appended to this. + * @param {Buffer} `suffix` Buffer that will be appended to the buf. + * @return {Buffer} Final Buffer + * @api public + */ + +module.exports = function appendBuffer(buf, suffix) { + if (!suffix || !suffix.length) { + return buf; + } + var eol; + if (equals(buf.slice(-2), cr)) { + eol = cr; + } else if (equals(buf.slice(-1), nl)) { + eol = nl; + } else { + return Buffer.concat([buf, new Buffer(os.EOL), new Buffer(suffix)]); + } + return Buffer.concat([buf, new Buffer(suffix), eol]); +}; diff --git a/node_modules/append-buffer/package.json b/node_modules/append-buffer/package.json new file mode 100644 index 0000000000..f73ba00b9c --- /dev/null +++ b/node_modules/append-buffer/package.json @@ -0,0 +1,84 @@ +{ + "_from": "append-buffer@^1.0.2", + "_id": "append-buffer@1.0.2", + "_inBundle": false, + "_integrity": "sha1-2CIM9GYIFSXv6lBhTz3mUU36WPE=", + "_location": "/append-buffer", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "append-buffer@^1.0.2", + "name": "append-buffer", + "escapedName": "append-buffer", + "rawSpec": "^1.0.2", + "saveSpec": null, + "fetchSpec": "^1.0.2" + }, + "_requiredBy": [ + "/vinyl-sourcemap" + ], + "_resolved": "https://registry.npmjs.org/append-buffer/-/append-buffer-1.0.2.tgz", + "_shasum": "d8220cf466081525efea50614f3de6514dfa58f1", + "_spec": "append-buffer@^1.0.2", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/vinyl-sourcemap", + "author": { + "name": "Brian Woodward", + "url": "https://doowb.com" + }, + "bugs": { + "url": "https://github.com/doowb/append-buffer/issues" + }, + "bundleDependencies": false, + "dependencies": { + "buffer-equal": "^1.0.0" + }, + "deprecated": false, + "description": "Append a buffer to another buffer ensuring to preserve line ending characters.", + "devDependencies": { + "gulp-format-md": "^1.0.0", + "mocha": "^3.5.0" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/doowb/append-buffer", + "keywords": [ + "append", + "append-buffer", + "concat", + "concat-buffer", + "eol", + "join", + "join-buffer", + "normalize", + "buffer" + ], + "license": "MIT", + "main": "index.js", + "name": "append-buffer", + "repository": { + "type": "git", + "url": "git+https://github.com/doowb/append-buffer.git" + }, + "scripts": { + "test": "mocha" + }, + "verb": { + "toc": false, + "layout": "default", + "tasks": [ + "readme" + ], + "plugins": [ + "gulp-format-md" + ], + "lint": { + "reflinks": true + } + }, + "version": "1.0.2" +} diff --git a/node_modules/archy/.travis.yml b/node_modules/archy/.travis.yml new file mode 100644 index 0000000000..895dbd3623 --- /dev/null +++ b/node_modules/archy/.travis.yml @@ -0,0 +1,4 @@ +language: node_js +node_js: + - 0.6 + - 0.8 diff --git a/node_modules/archy/LICENSE b/node_modules/archy/LICENSE new file mode 100644 index 0000000000..ee27ba4b44 --- /dev/null +++ b/node_modules/archy/LICENSE @@ -0,0 +1,18 @@ +This software is released under the MIT license: + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/node_modules/archy/examples/beep.js b/node_modules/archy/examples/beep.js new file mode 100644 index 0000000000..9c0704797c --- /dev/null +++ b/node_modules/archy/examples/beep.js @@ -0,0 +1,24 @@ +var archy = require('../'); +var s = archy({ + label : 'beep', + nodes : [ + 'ity', + { + label : 'boop', + nodes : [ + { + label : 'o_O', + nodes : [ + { + label : 'oh', + nodes : [ 'hello', 'puny' ] + }, + 'human' + ] + }, + 'party\ntime!' + ] + } + ] +}); +console.log(s); diff --git a/node_modules/archy/examples/multi_line.js b/node_modules/archy/examples/multi_line.js new file mode 100644 index 0000000000..8afdfada91 --- /dev/null +++ b/node_modules/archy/examples/multi_line.js @@ -0,0 +1,25 @@ +var archy = require('../'); + +var s = archy({ + label : 'beep\none\ntwo', + nodes : [ + 'ity', + { + label : 'boop', + nodes : [ + { + label : 'o_O\nwheee', + nodes : [ + { + label : 'oh', + nodes : [ 'hello', 'puny\nmeat' ] + }, + 'creature' + ] + }, + 'party\ntime!' + ] + } + ] +}); +console.log(s); diff --git a/node_modules/archy/index.js b/node_modules/archy/index.js new file mode 100644 index 0000000000..869d64e653 --- /dev/null +++ b/node_modules/archy/index.js @@ -0,0 +1,35 @@ +module.exports = function archy (obj, prefix, opts) { + if (prefix === undefined) prefix = ''; + if (!opts) opts = {}; + var chr = function (s) { + var chars = { + '│' : '|', + '└' : '`', + '├' : '+', + '─' : '-', + '┬' : '-' + }; + return opts.unicode === false ? chars[s] : s; + }; + + if (typeof obj === 'string') obj = { label : obj }; + + var nodes = obj.nodes || []; + var lines = (obj.label || '').split('\n'); + var splitter = '\n' + prefix + (nodes.length ? chr('│') : ' ') + ' '; + + return prefix + + lines.join(splitter) + '\n' + + nodes.map(function (node, ix) { + var last = ix === nodes.length - 1; + var more = node.nodes && node.nodes.length; + var prefix_ = prefix + (last ? ' ' : chr('│')) + ' '; + + return prefix + + (last ? chr('└') : chr('├')) + chr('─') + + (more ? chr('┬') : chr('─')) + ' ' + + archy(node, prefix_, opts).slice(prefix.length + 2) + ; + }).join('') + ; +}; diff --git a/node_modules/archy/package.json b/node_modules/archy/package.json new file mode 100644 index 0000000000..ab7ec83430 --- /dev/null +++ b/node_modules/archy/package.json @@ -0,0 +1,83 @@ +{ + "_from": "archy@^1.0.0", + "_id": "archy@1.0.0", + "_inBundle": false, + "_integrity": "sha1-+cjBN1fMHde8N5rHeyxipcKGjEA=", + "_location": "/archy", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "archy@^1.0.0", + "name": "archy", + "escapedName": "archy", + "rawSpec": "^1.0.0", + "saveSpec": null, + "fetchSpec": "^1.0.0" + }, + "_requiredBy": [ + "/gulp/gulp-cli" + ], + "_resolved": "https://registry.npmjs.org/archy/-/archy-1.0.0.tgz", + "_shasum": "f9c8c13757cc1dd7bc379ac77b2c62a5c2868c40", + "_spec": "archy@^1.0.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/gulp/node_modules/gulp-cli", + "author": { + "name": "James Halliday", + "email": "mail@substack.net", + "url": "http://substack.net" + }, + "bugs": { + "url": "https://github.com/substack/node-archy/issues" + }, + "bundleDependencies": false, + "deprecated": false, + "description": "render nested hierarchies `npm ls` style with unicode pipes", + "devDependencies": { + "tap": "~0.3.3", + "tape": "~0.1.1" + }, + "homepage": "https://github.com/substack/node-archy#readme", + "keywords": [ + "hierarchy", + "npm ls", + "unicode", + "pretty", + "print" + ], + "license": "MIT", + "main": "index.js", + "name": "archy", + "repository": { + "type": "git", + "url": "git+ssh://git@github.com/substack/node-archy.git" + }, + "scripts": { + "test": "tap test" + }, + "testling": { + "files": "test/*.js", + "browsers": { + "iexplore": [ + "6.0", + "7.0", + "8.0", + "9.0" + ], + "chrome": [ + "20.0" + ], + "firefox": [ + "10.0", + "15.0" + ], + "safari": [ + "5.1" + ], + "opera": [ + "12.0" + ] + } + }, + "version": "1.0.0" +} diff --git a/node_modules/archy/readme.markdown b/node_modules/archy/readme.markdown new file mode 100644 index 0000000000..ef7a5cf34b --- /dev/null +++ b/node_modules/archy/readme.markdown @@ -0,0 +1,88 @@ +# archy + +Render nested hierarchies `npm ls` style with unicode pipes. + +[![browser support](http://ci.testling.com/substack/node-archy.png)](http://ci.testling.com/substack/node-archy) + +[![build status](https://secure.travis-ci.org/substack/node-archy.png)](http://travis-ci.org/substack/node-archy) + +# example + +``` js +var archy = require('archy'); +var s = archy({ + label : 'beep', + nodes : [ + 'ity', + { + label : 'boop', + nodes : [ + { + label : 'o_O', + nodes : [ + { + label : 'oh', + nodes : [ 'hello', 'puny' ] + }, + 'human' + ] + }, + 'party\ntime!' + ] + } + ] +}); +console.log(s); +``` + +output + +``` +beep +├── ity +└─┬ boop + ├─┬ o_O + │ ├─┬ oh + │ │ ├── hello + │ │ └── puny + │ └── human + └── party + time! +``` + +# methods + +var archy = require('archy') + +## archy(obj, prefix='', opts={}) + +Return a string representation of `obj` with unicode pipe characters like how +`npm ls` looks. + +`obj` should be a tree of nested objects with `'label'` and `'nodes'` fields. +`'label'` is a string of text to display at a node level and `'nodes'` is an +array of the descendents of the current node. + +If a node is a string, that string will be used as the `'label'` and an empty +array of `'nodes'` will be used. + +`prefix` gets prepended to all the lines and is used by the algorithm to +recursively update. + +If `'label'` has newlines they will be indented at the present indentation level +with the current prefix. + +To disable unicode results in favor of all-ansi output set `opts.unicode` to +`false`. + +# install + +With [npm](http://npmjs.org) do: + +``` +npm install archy +``` + +# license + +MIT diff --git a/node_modules/archy/test/beep.js b/node_modules/archy/test/beep.js new file mode 100644 index 0000000000..4ea74f9cee --- /dev/null +++ b/node_modules/archy/test/beep.js @@ -0,0 +1,40 @@ +var test = require('tape'); +var archy = require('../'); + +test('beep', function (t) { + var s = archy({ + label : 'beep', + nodes : [ + 'ity', + { + label : 'boop', + nodes : [ + { + label : 'o_O', + nodes : [ + { + label : 'oh', + nodes : [ 'hello', 'puny' ] + }, + 'human' + ] + }, + 'party!' + ] + } + ] + }); + t.equal(s, [ + 'beep', + '├── ity', + '└─┬ boop', + ' ├─┬ o_O', + ' │ ├─┬ oh', + ' │ │ ├── hello', + ' │ │ └── puny', + ' │ └── human', + ' └── party!', + '' + ].join('\n')); + t.end(); +}); diff --git a/node_modules/archy/test/multi_line.js b/node_modules/archy/test/multi_line.js new file mode 100644 index 0000000000..2cf2154d8a --- /dev/null +++ b/node_modules/archy/test/multi_line.js @@ -0,0 +1,45 @@ +var test = require('tape'); +var archy = require('../'); + +test('multi-line', function (t) { + var s = archy({ + label : 'beep\none\ntwo', + nodes : [ + 'ity', + { + label : 'boop', + nodes : [ + { + label : 'o_O\nwheee', + nodes : [ + { + label : 'oh', + nodes : [ 'hello', 'puny\nmeat' ] + }, + 'creature' + ] + }, + 'party\ntime!' + ] + } + ] + }); + t.equal(s, [ + 'beep', + '│ one', + '│ two', + '├── ity', + '└─┬ boop', + ' ├─┬ o_O', + ' │ │ wheee', + ' │ ├─┬ oh', + ' │ │ ├── hello', + ' │ │ └── puny', + ' │ │ meat', + ' │ └── creature', + ' └── party', + ' time!', + '' + ].join('\n')); + t.end(); +}); diff --git a/node_modules/archy/test/non_unicode.js b/node_modules/archy/test/non_unicode.js new file mode 100644 index 0000000000..7204d33271 --- /dev/null +++ b/node_modules/archy/test/non_unicode.js @@ -0,0 +1,40 @@ +var test = require('tape'); +var archy = require('../'); + +test('beep', function (t) { + var s = archy({ + label : 'beep', + nodes : [ + 'ity', + { + label : 'boop', + nodes : [ + { + label : 'o_O', + nodes : [ + { + label : 'oh', + nodes : [ 'hello', 'puny' ] + }, + 'human' + ] + }, + 'party!' + ] + } + ] + }, '', { unicode : false }); + t.equal(s, [ + 'beep', + '+-- ity', + '`-- boop', + ' +-- o_O', + ' | +-- oh', + ' | | +-- hello', + ' | | `-- puny', + ' | `-- human', + ' `-- party!', + '' + ].join('\n')); + t.end(); +}); diff --git a/node_modules/arr-diff/LICENSE b/node_modules/arr-diff/LICENSE new file mode 100755 index 0000000000..d734237bde --- /dev/null +++ b/node_modules/arr-diff/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2014-2017, Jon Schlinkert + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/arr-diff/README.md b/node_modules/arr-diff/README.md new file mode 100644 index 0000000000..961f5c3f1b --- /dev/null +++ b/node_modules/arr-diff/README.md @@ -0,0 +1,130 @@ +# arr-diff [![NPM version](https://img.shields.io/npm/v/arr-diff.svg?style=flat)](https://www.npmjs.com/package/arr-diff) [![NPM monthly downloads](https://img.shields.io/npm/dm/arr-diff.svg?style=flat)](https://npmjs.org/package/arr-diff) [![Linux Build Status](https://img.shields.io/travis/jonschlinkert/arr-diff.svg?style=flat&label=Travis)](https://travis-ci.org/jonschlinkert/arr-diff) + +> Returns an array with only the unique values from the first array, by excluding all values from additional arrays using strict equality for comparisons. + +## Install + +Install with [npm](https://www.npmjs.com/): + +```sh +$ npm install --save arr-diff +``` + +Install with [yarn](https://yarnpkg.com): + +```sh +$ yarn add arr-diff +``` + +Install with [bower](https://bower.io/) + +```sh +$ bower install arr-diff --save +``` + +## Usage + +Returns the difference between the first array and additional arrays. + +```js +var diff = require('arr-diff'); + +var a = ['a', 'b', 'c', 'd']; +var b = ['b', 'c']; + +console.log(diff(a, b)) +//=> ['a', 'd'] +``` + +## Benchmarks + +This library versus [array-differ](https://github.com/sindresorhus/array-differ), on April 14, 2017: + +``` +Benchmarking: (4 of 4) + · long-dupes + · long + · med + · short + +# benchmark/fixtures/long-dupes.js (100804 bytes) + arr-diff-3.0.0 x 822 ops/sec ±0.67% (86 runs sampled) + arr-diff-4.0.0 x 2,141 ops/sec ±0.42% (89 runs sampled) + array-differ x 708 ops/sec ±0.70% (89 runs sampled) + + fastest is arr-diff-4.0.0 + +# benchmark/fixtures/long.js (94529 bytes) + arr-diff-3.0.0 x 882 ops/sec ±0.60% (87 runs sampled) + arr-diff-4.0.0 x 2,329 ops/sec ±0.97% (83 runs sampled) + array-differ x 769 ops/sec ±0.61% (90 runs sampled) + + fastest is arr-diff-4.0.0 + +# benchmark/fixtures/med.js (708 bytes) + arr-diff-3.0.0 x 856,150 ops/sec ±0.42% (89 runs sampled) + arr-diff-4.0.0 x 4,665,249 ops/sec ±1.06% (89 runs sampled) + array-differ x 653,888 ops/sec ±1.02% (86 runs sampled) + + fastest is arr-diff-4.0.0 + +# benchmark/fixtures/short.js (60 bytes) + arr-diff-3.0.0 x 3,078,467 ops/sec ±0.77% (93 runs sampled) + arr-diff-4.0.0 x 9,213,296 ops/sec ±0.65% (89 runs sampled) + array-differ x 1,337,051 ops/sec ±0.91% (92 runs sampled) + + fastest is arr-diff-4.0.0 +``` + +## About + +### Related projects + +* [arr-flatten](https://www.npmjs.com/package/arr-flatten): Recursively flatten an array or arrays. This is the fastest implementation of array flatten. | [homepage](https://github.com/jonschlinkert/arr-flatten "Recursively flatten an array or arrays. This is the fastest implementation of array flatten.") +* [array-filter](https://www.npmjs.com/package/array-filter): Array#filter for older browsers. | [homepage](https://github.com/juliangruber/array-filter "Array#filter for older browsers.") +* [array-intersection](https://www.npmjs.com/package/array-intersection): Return an array with the unique values present in _all_ given arrays using strict equality… [more](https://github.com/jonschlinkert/array-intersection) | [homepage](https://github.com/jonschlinkert/array-intersection "Return an array with the unique values present in _all_ given arrays using strict equality for comparisons.") + +### Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new). + +### Contributors + +| **Commits** | **Contributor** | +| --- | --- | +| 33 | [jonschlinkert](https://github.com/jonschlinkert) | +| 2 | [paulmillr](https://github.com/paulmillr) | + +### Building docs + +_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_ + +To generate the readme, run the following command: + +```sh +$ npm install -g verbose/verb#dev verb-generate-readme && verb +``` + +### Running tests + +Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command: + +```sh +$ npm install && npm test +``` + +### Author + +**Jon Schlinkert** + +* [github/jonschlinkert](https://github.com/jonschlinkert) +* [twitter/jonschlinkert](https://twitter.com/jonschlinkert) + +### License + +Copyright © 2017, [Jon Schlinkert](https://github.com/jonschlinkert). +Released under the [MIT License](LICENSE). + +*** + +_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.5.0, on April 14, 2017._ \ No newline at end of file diff --git a/node_modules/arr-diff/index.js b/node_modules/arr-diff/index.js new file mode 100644 index 0000000000..90f280772a --- /dev/null +++ b/node_modules/arr-diff/index.js @@ -0,0 +1,47 @@ +/*! + * arr-diff + * + * Copyright (c) 2014-2017, Jon Schlinkert. + * Released under the MIT License. + */ + +'use strict'; + +module.exports = function diff(arr/*, arrays*/) { + var len = arguments.length; + var idx = 0; + while (++idx < len) { + arr = diffArray(arr, arguments[idx]); + } + return arr; +}; + +function diffArray(one, two) { + if (!Array.isArray(two)) { + return one.slice(); + } + + var tlen = two.length + var olen = one.length; + var idx = -1; + var arr = []; + + while (++idx < olen) { + var ele = one[idx]; + + var hasEle = false; + for (var i = 0; i < tlen; i++) { + var val = two[i]; + + if (ele === val) { + hasEle = true; + break; + } + } + + if (hasEle === false) { + arr.push(ele); + } + } + return arr; +} diff --git a/node_modules/arr-diff/package.json b/node_modules/arr-diff/package.json new file mode 100644 index 0000000000..46bbda56ed --- /dev/null +++ b/node_modules/arr-diff/package.json @@ -0,0 +1,112 @@ +{ + "_from": "arr-diff@^4.0.0", + "_id": "arr-diff@4.0.0", + "_inBundle": false, + "_integrity": "sha1-1kYQdP6/7HHn4VI1dhoyml3HxSA=", + "_location": "/arr-diff", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "arr-diff@^4.0.0", + "name": "arr-diff", + "escapedName": "arr-diff", + "rawSpec": "^4.0.0", + "saveSpec": null, + "fetchSpec": "^4.0.0" + }, + "_requiredBy": [ + "/anymatch/micromatch", + "/chokidar/micromatch", + "/findup-sync/micromatch", + "/matchdep/micromatch", + "/nanomatch" + ], + "_resolved": "https://registry.npmjs.org/arr-diff/-/arr-diff-4.0.0.tgz", + "_shasum": "d6461074febfec71e7e15235761a329a5dc7c520", + "_spec": "arr-diff@^4.0.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/anymatch/node_modules/micromatch", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/jonschlinkert/arr-diff/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "Jon Schlinkert", + "email": "jon.schlinkert@sellside.com", + "url": "http://twitter.com/jonschlinkert" + }, + { + "name": "Paul Miller", + "email": "paul+gh@paulmillr.com", + "url": "paulmillr.com" + } + ], + "dependencies": {}, + "deprecated": false, + "description": "Returns an array with only the unique values from the first array, by excluding all values from additional arrays using strict equality for comparisons.", + "devDependencies": { + "ansi-bold": "^0.1.1", + "arr-flatten": "^1.0.1", + "array-differ": "^1.0.0", + "benchmarked": "^0.2.4", + "gulp-format-md": "^0.1.9", + "minimist": "^1.2.0", + "mocha": "^2.4.5" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/jonschlinkert/arr-diff", + "keywords": [ + "arr", + "array", + "array differ", + "array-differ", + "diff", + "differ", + "difference" + ], + "license": "MIT", + "main": "index.js", + "name": "arr-diff", + "repository": { + "type": "git", + "url": "git+https://github.com/jonschlinkert/arr-diff.git" + }, + "scripts": { + "test": "mocha" + }, + "verb": { + "toc": false, + "layout": "default", + "tasks": [ + "readme" + ], + "plugins": [ + "gulp-format-md" + ], + "related": { + "list": [ + "arr-flatten", + "array-filter", + "array-intersection" + ] + }, + "reflinks": [ + "array-differ", + "verb" + ], + "lint": { + "reflinks": true + } + }, + "version": "4.0.0" +} diff --git a/node_modules/arr-filter/LICENSE b/node_modules/arr-filter/LICENSE new file mode 100755 index 0000000000..d290fe00b2 --- /dev/null +++ b/node_modules/arr-filter/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2014-2015, 2017, Jon Schlinkert + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/arr-filter/README.md b/node_modules/arr-filter/README.md new file mode 100755 index 0000000000..96435ae842 --- /dev/null +++ b/node_modules/arr-filter/README.md @@ -0,0 +1,72 @@ +# arr-filter [![NPM version](https://img.shields.io/npm/v/arr-filter.svg?style=flat)](https://www.npmjs.com/package/arr-filter) [![NPM monthly downloads](https://img.shields.io/npm/dm/arr-filter.svg?style=flat)](https://npmjs.org/package/arr-filter) [![NPM total downloads](https://img.shields.io/npm/dt/arr-filter.svg?style=flat)](https://npmjs.org/package/arr-filter) [![Linux Build Status](https://img.shields.io/travis/jonschlinkert/arr-filter.svg?style=flat&label=Travis)](https://travis-ci.org/jonschlinkert/arr-filter) + +> Faster alternative to javascript's native filter method. + +## Install + +Install with [npm](https://www.npmjs.com/): + +```sh +$ npm install --save arr-filter +``` + +## Usage + +```js +var filter = require('arr-filter'); + +filter(['a', {a: 'b'}, 1, 'b', 2, {c: 'd'}, 'c'], function (ele) { + return typeof ele === 'string'; +}); +//=> ['a', 'b', 'c'] +``` + +## Why another array filter? + +[array-filter](https://github.com/juliangruber/array-filter) is pretty popular, but it's tuned to be used in older browsers and it falls back on native `.filter()` when available, which is much slower. See [jsperf results](http://jsperf.com/array-filter-while-vs-for/2). The functions used in the benchmarks are the top performers from a dozen or so other functions. + +## About + +### Related projects + +* [arr-map](https://www.npmjs.com/package/arr-map): Faster, node.js focused alternative to JavaScript's native array map. | [homepage](https://github.com/jonschlinkert/arr-map "Faster, node.js focused alternative to JavaScript's native array map.") +* [array-each](https://www.npmjs.com/package/array-each): Loop over each item in an array and call the given function on every element. | [homepage](https://github.com/jonschlinkert/array-each "Loop over each item in an array and call the given function on every element.") +* [collection-map](https://www.npmjs.com/package/collection-map): Returns an array of mapped values from an array or object. | [homepage](https://github.com/jonschlinkert/collection-map "Returns an array of mapped values from an array or object.") + +### Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new). + +### Building docs + +_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_ + +To generate the readme, run the following command: + +```sh +$ npm install -g verbose/verb#dev verb-generate-readme && verb +``` + +### Running tests + +Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command: + +```sh +$ npm install && npm test +``` + +### Author + +**Jon Schlinkert** + +* [github/jonschlinkert](https://github.com/jonschlinkert) +* [twitter/jonschlinkert](https://twitter.com/jonschlinkert) + +### License + +Copyright © 2017, [Jon Schlinkert](https://github.com/jonschlinkert). +Released under the [MIT License](LICENSE). + +*** + +_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.4.2, on February 26, 2017._ \ No newline at end of file diff --git a/node_modules/arr-filter/index.js b/node_modules/arr-filter/index.js new file mode 100755 index 0000000000..29b8c3cd3b --- /dev/null +++ b/node_modules/arr-filter/index.js @@ -0,0 +1,33 @@ +/*! + * arr-filter + * + * Copyright (c) 2014-2015, 2017, Jon Schlinkert. + * Released under the MIT License. + */ + +'use strict'; + +var makeIterator = require('make-iterator'); + +module.exports = function filter(arr, fn, thisArg) { + if (arr == null) { + return []; + } + + if (typeof fn !== 'function') { + throw new TypeError('expected callback to be a function'); + } + + var iterator = makeIterator(fn, thisArg); + var len = arr.length; + var res = arr.slice(); + var i = -1; + + while (len--) { + if (!iterator(arr[len], i++)) { + res.splice(len, 1); + } + } + return res; +}; + diff --git a/node_modules/arr-filter/package.json b/node_modules/arr-filter/package.json new file mode 100644 index 0000000000..d5bb85df12 --- /dev/null +++ b/node_modules/arr-filter/package.json @@ -0,0 +1,92 @@ +{ + "_from": "arr-filter@^1.1.1", + "_id": "arr-filter@1.1.2", + "_inBundle": false, + "_integrity": "sha1-Q/3d0JHo7xGqTEXZzcGOLf8XEe4=", + "_location": "/arr-filter", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "arr-filter@^1.1.1", + "name": "arr-filter", + "escapedName": "arr-filter", + "rawSpec": "^1.1.1", + "saveSpec": null, + "fetchSpec": "^1.1.1" + }, + "_requiredBy": [ + "/bach" + ], + "_resolved": "https://registry.npmjs.org/arr-filter/-/arr-filter-1.1.2.tgz", + "_shasum": "43fdddd091e8ef11aa4c45d9cdc18e2dff1711ee", + "_spec": "arr-filter@^1.1.1", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/bach", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/jonschlinkert/arr-filter/issues" + }, + "bundleDependencies": false, + "dependencies": { + "make-iterator": "^1.0.0" + }, + "deprecated": false, + "description": "Faster alternative to javascript's native filter method.", + "devDependencies": { + "array-filter": "^1.0.0", + "benchmarked": "^0.2.5", + "chalk": "^1.1.3", + "gulp-format-md": "^0.1.11", + "micromatch": "^2.3.11", + "minimist": "^1.2.0", + "mocha": "^3.2.0" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/jonschlinkert/arr-filter", + "keywords": [ + "arr", + "array", + "collection", + "filter", + "util" + ], + "license": "MIT", + "main": "index.js", + "name": "arr-filter", + "repository": { + "type": "git", + "url": "git+https://github.com/jonschlinkert/arr-filter.git" + }, + "scripts": { + "test": "mocha" + }, + "verb": { + "toc": false, + "layout": "default", + "tasks": [ + "readme" + ], + "plugins": [ + "gulp-format-md" + ], + "related": { + "list": [ + "collection-map", + "arr-map", + "array-each" + ] + }, + "lint": { + "reflinks": true + } + }, + "version": "1.1.2" +} diff --git a/node_modules/arr-flatten/LICENSE b/node_modules/arr-flatten/LICENSE new file mode 100755 index 0000000000..3f2eca18f1 --- /dev/null +++ b/node_modules/arr-flatten/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2014-2017, Jon Schlinkert. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/arr-flatten/README.md b/node_modules/arr-flatten/README.md new file mode 100755 index 0000000000..7dc7a9746b --- /dev/null +++ b/node_modules/arr-flatten/README.md @@ -0,0 +1,86 @@ +# arr-flatten [![NPM version](https://img.shields.io/npm/v/arr-flatten.svg?style=flat)](https://www.npmjs.com/package/arr-flatten) [![NPM monthly downloads](https://img.shields.io/npm/dm/arr-flatten.svg?style=flat)](https://npmjs.org/package/arr-flatten) [![NPM total downloads](https://img.shields.io/npm/dt/arr-flatten.svg?style=flat)](https://npmjs.org/package/arr-flatten) [![Linux Build Status](https://img.shields.io/travis/jonschlinkert/arr-flatten.svg?style=flat&label=Travis)](https://travis-ci.org/jonschlinkert/arr-flatten) [![Windows Build Status](https://img.shields.io/appveyor/ci/jonschlinkert/arr-flatten.svg?style=flat&label=AppVeyor)](https://ci.appveyor.com/project/jonschlinkert/arr-flatten) + +> Recursively flatten an array or arrays. + +## Install + +Install with [npm](https://www.npmjs.com/): + +```sh +$ npm install --save arr-flatten +``` + +## Install + +Install with [bower](https://bower.io/) + +```sh +$ bower install arr-flatten --save +``` + +## Usage + +```js +var flatten = require('arr-flatten'); + +flatten(['a', ['b', ['c']], 'd', ['e']]); +//=> ['a', 'b', 'c', 'd', 'e'] +``` + +## Why another flatten utility? + +I wanted the fastest implementation I could find, with implementation choices that should work for 95% of use cases, but no cruft to cover the other 5%. + +## About + +### Related projects + +* [arr-filter](https://www.npmjs.com/package/arr-filter): Faster alternative to javascript's native filter method. | [homepage](https://github.com/jonschlinkert/arr-filter "Faster alternative to javascript's native filter method.") +* [arr-union](https://www.npmjs.com/package/arr-union): Combines a list of arrays, returning a single array with unique values, using strict equality… [more](https://github.com/jonschlinkert/arr-union) | [homepage](https://github.com/jonschlinkert/arr-union "Combines a list of arrays, returning a single array with unique values, using strict equality for comparisons.") +* [array-each](https://www.npmjs.com/package/array-each): Loop over each item in an array and call the given function on every element. | [homepage](https://github.com/jonschlinkert/array-each "Loop over each item in an array and call the given function on every element.") +* [array-unique](https://www.npmjs.com/package/array-unique): Remove duplicate values from an array. Fastest ES5 implementation. | [homepage](https://github.com/jonschlinkert/array-unique "Remove duplicate values from an array. Fastest ES5 implementation.") + +### Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new). + +### Contributors + +| **Commits** | **Contributor** | +| --- | --- | +| 20 | [jonschlinkert](https://github.com/jonschlinkert) | +| 1 | [lukeed](https://github.com/lukeed) | + +### Building docs + +_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_ + +To generate the readme, run the following command: + +```sh +$ npm install -g verbose/verb#dev verb-generate-readme && verb +``` + +### Running tests + +Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command: + +```sh +$ npm install && npm test +``` + +### Author + +**Jon Schlinkert** + +* [github/jonschlinkert](https://github.com/jonschlinkert) +* [twitter/jonschlinkert](https://twitter.com/jonschlinkert) + +### License + +Copyright © 2017, [Jon Schlinkert](https://github.com/jonschlinkert). +Released under the [MIT License](LICENSE). + +*** + +_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.6.0, on July 05, 2017._ \ No newline at end of file diff --git a/node_modules/arr-flatten/index.js b/node_modules/arr-flatten/index.js new file mode 100644 index 0000000000..0cb4ea4ece --- /dev/null +++ b/node_modules/arr-flatten/index.js @@ -0,0 +1,22 @@ +/*! + * arr-flatten + * + * Copyright (c) 2014-2017, Jon Schlinkert. + * Released under the MIT License. + */ + +'use strict'; + +module.exports = function (arr) { + return flat(arr, []); +}; + +function flat(arr, res) { + var i = 0, cur; + var len = arr.length; + for (; i < len; i++) { + cur = arr[i]; + Array.isArray(cur) ? flat(cur, res) : res.push(cur); + } + return res; +} diff --git a/node_modules/arr-flatten/package.json b/node_modules/arr-flatten/package.json new file mode 100644 index 0000000000..c00b8b7d1e --- /dev/null +++ b/node_modules/arr-flatten/package.json @@ -0,0 +1,115 @@ +{ + "_from": "arr-flatten@^1.1.0", + "_id": "arr-flatten@1.1.0", + "_inBundle": false, + "_integrity": "sha512-L3hKV5R/p5o81R7O02IGnwpDmkp6E982XhtbuwSe3O4qOtMMMtodicASA1Cny2U+aCXcNpml+m4dPsvsJ3jatg==", + "_location": "/arr-flatten", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "arr-flatten@^1.1.0", + "name": "arr-flatten", + "escapedName": "arr-flatten", + "rawSpec": "^1.1.0", + "saveSpec": null, + "fetchSpec": "^1.1.0" + }, + "_requiredBy": [ + "/bach", + "/braces", + "/undertaker" + ], + "_resolved": "https://registry.npmjs.org/arr-flatten/-/arr-flatten-1.1.0.tgz", + "_shasum": "36048bbff4e7b47e136644316c99669ea5ae91f1", + "_spec": "arr-flatten@^1.1.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/braces", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/jonschlinkert/arr-flatten/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "Jon Schlinkert", + "url": "http://twitter.com/jonschlinkert" + }, + { + "name": "Luke Edwards", + "url": "https://lukeed.com" + } + ], + "deprecated": false, + "description": "Recursively flatten an array or arrays.", + "devDependencies": { + "ansi-bold": "^0.1.1", + "array-flatten": "^2.1.1", + "array-slice": "^1.0.0", + "benchmarked": "^1.0.0", + "compute-flatten": "^1.0.0", + "flatit": "^1.1.1", + "flatten": "^1.0.2", + "flatten-array": "^1.0.0", + "glob": "^7.1.1", + "gulp-format-md": "^0.1.12", + "just-flatten-it": "^1.1.23", + "lodash.flattendeep": "^4.4.0", + "m_flattened": "^1.0.1", + "mocha": "^3.2.0", + "utils-flatten": "^1.0.0", + "write": "^0.3.3" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/jonschlinkert/arr-flatten", + "keywords": [ + "arr", + "array", + "elements", + "flat", + "flatten", + "nested", + "recurse", + "recursive", + "recursively" + ], + "license": "MIT", + "main": "index.js", + "name": "arr-flatten", + "repository": { + "type": "git", + "url": "git+https://github.com/jonschlinkert/arr-flatten.git" + }, + "scripts": { + "test": "mocha" + }, + "verb": { + "toc": false, + "layout": "default", + "tasks": [ + "readme" + ], + "plugins": [ + "gulp-format-md" + ], + "related": { + "list": [ + "arr-filter", + "arr-union", + "array-each", + "array-unique" + ] + }, + "lint": { + "reflinks": true + } + }, + "version": "1.1.0" +} diff --git a/node_modules/arr-map/LICENSE b/node_modules/arr-map/LICENSE new file mode 100644 index 0000000000..ec85897eb1 --- /dev/null +++ b/node_modules/arr-map/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2015, 2017, Jon Schlinkert + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/arr-map/README.md b/node_modules/arr-map/README.md new file mode 100644 index 0000000000..04e9910c50 --- /dev/null +++ b/node_modules/arr-map/README.md @@ -0,0 +1,78 @@ +# arr-map [![NPM version](https://img.shields.io/npm/v/arr-map.svg?style=flat)](https://www.npmjs.com/package/arr-map) [![NPM monthly downloads](https://img.shields.io/npm/dm/arr-map.svg?style=flat)](https://npmjs.org/package/arr-map) [![NPM total downloads](https://img.shields.io/npm/dt/arr-map.svg?style=flat)](https://npmjs.org/package/arr-map) [![Linux Build Status](https://img.shields.io/travis/jonschlinkert/arr-map.svg?style=flat&label=Travis)](https://travis-ci.org/jonschlinkert/arr-map) + +> Faster, node.js focused alternative to JavaScript's native array map. + +## Install + +Install with [npm](https://www.npmjs.com/): + +```sh +$ npm install --save arr-map +``` + +## Why use this? + +JavaScript's native `Array.map()` is slow, and other popular array map libraries are focused on browser compatibility, which makes them bloated or less than idea for non-browser usage. This implementation is focused on node.js usage keeping it light and fast. + +## Usage + +```js +var map = require('arr-map'); + +map(['a', 'b', 'c'], function(ele) { + return ele + ele; +}); +//=> ['aa', 'bb', 'cc'] + +map(['a', 'b', 'c'], function(ele, i) { + return i + ele; +}); +//=> ['0a', '1b', '2c'] +``` + +## About + +### Related projects + +* [arr-diff](https://www.npmjs.com/package/arr-diff): Returns an array with only the unique values from the first array, by excluding all… [more](https://github.com/jonschlinkert/arr-diff) | [homepage](https://github.com/jonschlinkert/arr-diff "Returns an array with only the unique values from the first array, by excluding all values from additional arrays using strict equality for comparisons.") +* [arr-filter](https://www.npmjs.com/package/arr-filter): Faster alternative to javascript's native filter method. | [homepage](https://github.com/jonschlinkert/arr-filter "Faster alternative to javascript's native filter method.") +* [arr-flatten](https://www.npmjs.com/package/arr-flatten): Recursively flatten an array or arrays. This is the fastest implementation of array flatten. | [homepage](https://github.com/jonschlinkert/arr-flatten "Recursively flatten an array or arrays. This is the fastest implementation of array flatten.") +* [arr-reduce](https://www.npmjs.com/package/arr-reduce): Fast array reduce that also loops over sparse elements. | [homepage](https://github.com/jonschlinkert/arr-reduce "Fast array reduce that also loops over sparse elements.") + +### Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new). + +### Building docs + +_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_ + +To generate the readme, run the following command: + +```sh +$ npm install -g verbose/verb#dev verb-generate-readme && verb +``` + +### Running tests + +Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command: + +```sh +$ npm install && npm test +``` + +### Author + +**Jon Schlinkert** + +* [github/jonschlinkert](https://github.com/jonschlinkert) +* [twitter/jonschlinkert](https://twitter.com/jonschlinkert) + +### License + +Copyright © 2017, [Jon Schlinkert](https://github.com/jonschlinkert). +Released under the [MIT License](LICENSE). + +*** + +_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.4.2, on February 28, 2017._ \ No newline at end of file diff --git a/node_modules/arr-map/index.js b/node_modules/arr-map/index.js new file mode 100644 index 0000000000..8bfb3604e9 --- /dev/null +++ b/node_modules/arr-map/index.js @@ -0,0 +1,23 @@ +/*! + * arr-map + * + * Copyright (c) 2015, 2017, Jon Schlinkert. + * Released under the MIT License. + */ + +'use strict'; + +var iterator = require('make-iterator'); + +module.exports = function map(arr, fn, thisArg) { + if (arr == null) return []; + fn = iterator(fn, thisArg); + + var len = arr.length; + var res = new Array(len); + + for (var i = 0; i < len; i++) { + res[i] = fn(arr[i], i, arr); + } + return res; +}; diff --git a/node_modules/arr-map/package.json b/node_modules/arr-map/package.json new file mode 100644 index 0000000000..14b36fd287 --- /dev/null +++ b/node_modules/arr-map/package.json @@ -0,0 +1,95 @@ +{ + "_from": "arr-map@^2.0.0", + "_id": "arr-map@2.0.2", + "_inBundle": false, + "_integrity": "sha1-Onc0X/wc814qkYJWAfnljy4kysQ=", + "_location": "/arr-map", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "arr-map@^2.0.0", + "name": "arr-map", + "escapedName": "arr-map", + "rawSpec": "^2.0.0", + "saveSpec": null, + "fetchSpec": "^2.0.0" + }, + "_requiredBy": [ + "/bach", + "/collection-map", + "/undertaker" + ], + "_resolved": "https://registry.npmjs.org/arr-map/-/arr-map-2.0.2.tgz", + "_shasum": "3a77345ffc1cf35e2a91825601f9e58f2e24cac4", + "_spec": "arr-map@^2.0.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/undertaker", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/jonschlinkert/arr-map/issues" + }, + "bundleDependencies": false, + "dependencies": { + "make-iterator": "^1.0.0" + }, + "deprecated": false, + "description": "Faster, node.js focused alternative to JavaScript's native array map.", + "devDependencies": { + "array-map": "^0.0.0", + "benchmarked": "^0.2.5", + "braces": "^2.0.3", + "chalk": "^1.1.3", + "glob": "^7.1.1", + "gulp-format-md": "^0.1.11", + "micromatch": "^2.3.11", + "mocha": "^3.2.0" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/jonschlinkert/arr-map", + "keywords": [ + "arr", + "array", + "map" + ], + "license": "MIT", + "main": "index.js", + "name": "arr-map", + "repository": { + "type": "git", + "url": "git+https://github.com/jonschlinkert/arr-map.git" + }, + "scripts": { + "benchmark": "node benchmark", + "test": "mocha" + }, + "verb": { + "toc": false, + "layout": "default", + "tasks": [ + "readme" + ], + "related": { + "list": [ + "arr-diff", + "arr-filter", + "arr-flatten", + "arr-reduce" + ] + }, + "plugins": [ + "gulp-format-md" + ], + "lint": { + "reflinks": true + } + }, + "version": "2.0.2" +} diff --git a/node_modules/arr-union/LICENSE b/node_modules/arr-union/LICENSE new file mode 100644 index 0000000000..39245ac1c6 --- /dev/null +++ b/node_modules/arr-union/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2014-2016, Jon Schlinkert. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/arr-union/README.md b/node_modules/arr-union/README.md new file mode 100644 index 0000000000..b3cd4f48d5 --- /dev/null +++ b/node_modules/arr-union/README.md @@ -0,0 +1,99 @@ +# arr-union [![NPM version](https://img.shields.io/npm/v/arr-union.svg)](https://www.npmjs.com/package/arr-union) [![Build Status](https://img.shields.io/travis/jonschlinkert/arr-union.svg)](https://travis-ci.org/jonschlinkert/arr-union) + +> Combines a list of arrays, returning a single array with unique values, using strict equality for comparisons. + +## Install + +Install with [npm](https://www.npmjs.com/): + +```sh +$ npm i arr-union --save +``` + +## Benchmarks + +This library is **10-20 times faster** and more performant than [array-union](https://github.com/sindresorhus/array-union). + +See the [benchmarks](./benchmark). + +```sh +#1: five-arrays + array-union x 511,121 ops/sec ±0.80% (96 runs sampled) + arr-union x 5,716,039 ops/sec ±0.86% (93 runs sampled) + +#2: ten-arrays + array-union x 245,196 ops/sec ±0.69% (94 runs sampled) + arr-union x 1,850,786 ops/sec ±0.84% (97 runs sampled) + +#3: two-arrays + array-union x 563,869 ops/sec ±0.97% (94 runs sampled) + arr-union x 9,602,852 ops/sec ±0.87% (92 runs sampled) +``` + +## Usage + +```js +var union = require('arr-union'); + +union(['a'], ['b', 'c'], ['d', 'e', 'f']); +//=> ['a', 'b', 'c', 'd', 'e', 'f'] +``` + +Returns only unique elements: + +```js +union(['a', 'a'], ['b', 'c']); +//=> ['a', 'b', 'c'] +``` + +## Related projects + +* [arr-diff](https://www.npmjs.com/package/arr-diff): Returns an array with only the unique values from the first array, by excluding all… [more](https://www.npmjs.com/package/arr-diff) | [homepage](https://github.com/jonschlinkert/arr-diff) +* [arr-filter](https://www.npmjs.com/package/arr-filter): Faster alternative to javascript's native filter method. | [homepage](https://github.com/jonschlinkert/arr-filter) +* [arr-flatten](https://www.npmjs.com/package/arr-flatten): Recursively flatten an array or arrays. This is the fastest implementation of array flatten. | [homepage](https://github.com/jonschlinkert/arr-flatten) +* [arr-map](https://www.npmjs.com/package/arr-map): Faster, node.js focused alternative to JavaScript's native array map. | [homepage](https://github.com/jonschlinkert/arr-map) +* [arr-pluck](https://www.npmjs.com/package/arr-pluck): Retrieves the value of a specified property from all elements in the collection. | [homepage](https://github.com/jonschlinkert/arr-pluck) +* [arr-reduce](https://www.npmjs.com/package/arr-reduce): Fast array reduce that also loops over sparse elements. | [homepage](https://github.com/jonschlinkert/arr-reduce) +* [array-unique](https://www.npmjs.com/package/array-unique): Return an array free of duplicate values. Fastest ES5 implementation. | [homepage](https://github.com/jonschlinkert/array-unique) + +## Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](https://github.com/jonschlinkert/arr-union/issues/new). + +## Building docs + +Generate readme and API documentation with [verb](https://github.com/verbose/verb): + +```sh +$ npm i verb && npm run docs +``` + +Or, if [verb](https://github.com/verbose/verb) is installed globally: + +```sh +$ verb +``` + +## Running tests + +Install dev dependencies: + +```sh +$ npm i -d && npm test +``` + +## Author + +**Jon Schlinkert** + +* [github/jonschlinkert](https://github.com/jonschlinkert) +* [twitter/jonschlinkert](http://twitter.com/jonschlinkert) + +## License + +Copyright © 2016 [Jon Schlinkert](https://github.com/jonschlinkert) +Released under the [MIT license](https://github.com/jonschlinkert/arr-union/blob/master/LICENSE). + +*** + +_This file was generated by [verb](https://github.com/verbose/verb), v0.9.0, on February 23, 2016._ \ No newline at end of file diff --git a/node_modules/arr-union/index.js b/node_modules/arr-union/index.js new file mode 100644 index 0000000000..5ae6c4a08b --- /dev/null +++ b/node_modules/arr-union/index.js @@ -0,0 +1,29 @@ +'use strict'; + +module.exports = function union(init) { + if (!Array.isArray(init)) { + throw new TypeError('arr-union expects the first argument to be an array.'); + } + + var len = arguments.length; + var i = 0; + + while (++i < len) { + var arg = arguments[i]; + if (!arg) continue; + + if (!Array.isArray(arg)) { + arg = [arg]; + } + + for (var j = 0; j < arg.length; j++) { + var ele = arg[j]; + + if (init.indexOf(ele) >= 0) { + continue; + } + init.push(ele); + } + } + return init; +}; diff --git a/node_modules/arr-union/package.json b/node_modules/arr-union/package.json new file mode 100644 index 0000000000..9bff5072da --- /dev/null +++ b/node_modules/arr-union/package.json @@ -0,0 +1,108 @@ +{ + "_from": "arr-union@^3.1.0", + "_id": "arr-union@3.1.0", + "_inBundle": false, + "_integrity": "sha1-45sJrqne+Gao8gbiiK9jkZuuOcQ=", + "_location": "/arr-union", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "arr-union@^3.1.0", + "name": "arr-union", + "escapedName": "arr-union", + "rawSpec": "^3.1.0", + "saveSpec": null, + "fetchSpec": "^3.1.0" + }, + "_requiredBy": [ + "/class-utils", + "/union-value" + ], + "_resolved": "https://registry.npmjs.org/arr-union/-/arr-union-3.1.0.tgz", + "_shasum": "e39b09aea9def866a8f206e288af63919bae39c4", + "_spec": "arr-union@^3.1.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/union-value", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/jonschlinkert/arr-union/issues" + }, + "bundleDependencies": false, + "deprecated": false, + "description": "Combines a list of arrays, returning a single array with unique values, using strict equality for comparisons.", + "devDependencies": { + "ansi-bold": "^0.1.1", + "array-union": "^1.0.1", + "array-unique": "^0.2.1", + "benchmarked": "^0.1.4", + "gulp-format-md": "^0.1.7", + "minimist": "^1.1.1", + "mocha": "*", + "should": "*" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/jonschlinkert/arr-union", + "keywords": [ + "add", + "append", + "array", + "arrays", + "combine", + "concat", + "extend", + "union", + "uniq", + "unique", + "util", + "utility", + "utils" + ], + "license": "MIT", + "main": "index.js", + "name": "arr-union", + "repository": { + "type": "git", + "url": "git+https://github.com/jonschlinkert/arr-union.git" + }, + "scripts": { + "test": "mocha" + }, + "verb": { + "run": true, + "toc": false, + "layout": "default", + "tasks": [ + "readme" + ], + "plugins": [ + "gulp-format-md" + ], + "related": { + "list": [ + "arr-diff", + "arr-flatten", + "arr-filter", + "arr-map", + "arr-pluck", + "arr-reduce", + "array-unique" + ] + }, + "reflinks": [ + "verb", + "array-union" + ], + "lint": { + "reflinks": true + } + }, + "version": "3.1.0" +} diff --git a/node_modules/array-each/LICENSE b/node_modules/array-each/LICENSE new file mode 100644 index 0000000000..ec85897eb1 --- /dev/null +++ b/node_modules/array-each/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2015, 2017, Jon Schlinkert + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/array-each/README.md b/node_modules/array-each/README.md new file mode 100644 index 0000000000..e8602a1a35 --- /dev/null +++ b/node_modules/array-each/README.md @@ -0,0 +1,84 @@ +# array-each [![NPM version](https://img.shields.io/npm/v/array-each.svg?style=flat)](https://www.npmjs.com/package/array-each) [![NPM monthly downloads](https://img.shields.io/npm/dm/array-each.svg?style=flat)](https://npmjs.org/package/array-each) [![NPM total downloads](https://img.shields.io/npm/dt/array-each.svg?style=flat)](https://npmjs.org/package/array-each) [![Linux Build Status](https://img.shields.io/travis/jonschlinkert/array-each.svg?style=flat&label=Travis)](https://travis-ci.org/jonschlinkert/array-each) + +> Loop over each item in an array and call the given function on every element. + +## Install + +Install with [npm](https://www.npmjs.com/): + +```sh +$ npm install --save array-each +``` + +## Usage + +### [each](index.js#L34) + +Loop over each item in an array and call the given function on every element. + +**Params** + +* `array` **{Array}** +* `fn` **{Function}** +* `thisArg` **{Object}**: (optional) pass a `thisArg` to be used as the context in which to call the function. +* `returns` **{undefined}** + +**Example** + +```js +each(['a', 'b', 'c'], function(ele) { + return ele + ele; +}); +//=> ['aa', 'bb', 'cc'] + +each(['a', 'b', 'c'], function(ele, i) { + return i + ele; +}); +//=> ['0a', '1b', '2c'] +``` + +## About + +### Related projects + +* [arr-filter](https://www.npmjs.com/package/arr-filter): Faster alternative to javascript's native filter method. | [homepage](https://github.com/jonschlinkert/arr-filter "Faster alternative to javascript's native filter method.") +* [arr-map](https://www.npmjs.com/package/arr-map): Faster, node.js focused alternative to JavaScript's native array map. | [homepage](https://github.com/jonschlinkert/arr-map "Faster, node.js focused alternative to JavaScript's native array map.") +* [collection-map](https://www.npmjs.com/package/collection-map): Returns an array of mapped values from an array or object. | [homepage](https://github.com/jonschlinkert/collection-map "Returns an array of mapped values from an array or object.") + +### Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new). + +### Building docs + +_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_ + +To generate the readme, run the following command: + +```sh +$ npm install -g verbose/verb#dev verb-generate-readme && verb +``` + +### Running tests + +Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command: + +```sh +$ npm install && npm test +``` + +### Author + +**Jon Schlinkert** + +* [github/jonschlinkert](https://github.com/jonschlinkert) +* [twitter/jonschlinkert](https://twitter.com/jonschlinkert) + +### License + +Copyright © 2017, [Jon Schlinkert](https://github.com/jonschlinkert). +Released under the [MIT License](LICENSE). + +*** + +_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.4.2, on February 26, 2017._ \ No newline at end of file diff --git a/node_modules/array-each/index.js b/node_modules/array-each/index.js new file mode 100644 index 0000000000..12afef4d34 --- /dev/null +++ b/node_modules/array-each/index.js @@ -0,0 +1,46 @@ +/*! + * array-each + * + * Copyright (c) 2015, 2017, Jon Schlinkert. + * Released under the MIT License. + */ + +'use strict'; + +/** + * Loop over each item in an array and call the given function on every element. + * + * ```js + * each(['a', 'b', 'c'], function(ele) { + * return ele + ele; + * }); + * //=> ['aa', 'bb', 'cc'] + * + * each(['a', 'b', 'c'], function(ele, i) { + * return i + ele; + * }); + * //=> ['0a', '1b', '2c'] + * ``` + * + * @name each + * @alias forEach + * @param {Array} `array` + * @param {Function} `fn` + * @param {Object} `thisArg` (optional) pass a `thisArg` to be used as the context in which to call the function. + * @return {undefined} + * @api public + */ + +module.exports = function each(arr, cb, thisArg) { + if (arr == null) return; + + var len = arr.length; + var idx = -1; + + while (++idx < len) { + var ele = arr[idx]; + if (cb.call(thisArg, ele, idx, arr) === false) { + break; + } + } +}; diff --git a/node_modules/array-each/package.json b/node_modules/array-each/package.json new file mode 100644 index 0000000000..4a412876d0 --- /dev/null +++ b/node_modules/array-each/package.json @@ -0,0 +1,82 @@ +{ + "_from": "array-each@^1.0.1", + "_id": "array-each@1.0.1", + "_inBundle": false, + "_integrity": "sha1-p5SvDAWrF1KEbudTofIRoFugxE8=", + "_location": "/array-each", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "array-each@^1.0.1", + "name": "array-each", + "escapedName": "array-each", + "rawSpec": "^1.0.1", + "saveSpec": null, + "fetchSpec": "^1.0.1" + }, + "_requiredBy": [ + "/bach", + "/object.defaults" + ], + "_resolved": "https://registry.npmjs.org/array-each/-/array-each-1.0.1.tgz", + "_shasum": "a794af0c05ab1752846ee753a1f211a05ba0c44f", + "_spec": "array-each@^1.0.1", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/object.defaults", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/jonschlinkert/array-each/issues" + }, + "bundleDependencies": false, + "deprecated": false, + "description": "Loop over each item in an array and call the given function on every element.", + "devDependencies": { + "gulp-format-md": "^0.1.11", + "mocha": "^3.2.0" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/jonschlinkert/array-each", + "keywords": [ + "array", + "each" + ], + "license": "MIT", + "main": "index.js", + "name": "array-each", + "repository": { + "type": "git", + "url": "git+https://github.com/jonschlinkert/array-each.git" + }, + "scripts": { + "test": "mocha" + }, + "verb": { + "toc": false, + "layout": "default", + "tasks": [ + "readme" + ], + "plugins": [ + "gulp-format-md" + ], + "related": { + "list": [ + "collection-map", + "arr-filter", + "arr-map" + ] + }, + "lint": { + "reflinks": true + } + }, + "version": "1.0.1" +} diff --git a/node_modules/array-initial/.jshintrc b/node_modules/array-initial/.jshintrc new file mode 100644 index 0000000000..ffd6173e98 --- /dev/null +++ b/node_modules/array-initial/.jshintrc @@ -0,0 +1,17 @@ +{ + "esnext": true, + "boss": true, + "curly": true, + "eqeqeq": true, + "eqnull": true, + "immed": true, + "indent": 2, + "latedef": true, + "newcap": true, + "noarg": true, + "node": true, + "sub": true, + "undef": true, + "unused": true, + "mocha": true +} diff --git a/node_modules/array-initial/.npmignore b/node_modules/array-initial/.npmignore new file mode 100644 index 0000000000..cbe37ae037 --- /dev/null +++ b/node_modules/array-initial/.npmignore @@ -0,0 +1,59 @@ +# Numerous always-ignore extensions +*.csv +*.dat +*.diff +*.err +*.gz +*.log +*.orig +*.out +*.pid +*.rar +*.rej +*.seed +*.swo +*.swp +*.vi +*.yo-rc.json +*.zip +*~ +.ruby-version +lib-cov +npm-debug.log + +# Always-ignore dirs +/bower_components/ +/node_modules/ +/temp/ +/tmp/ +/vendor/ +_gh_pages + +# OS or Editor folders +*.esproj +*.komodoproject +.komodotools +*.sublime-* +._* +.cache +.DS_Store +.idea +.project +.settings +.tmproj +nbproject +Thumbs.db + +# grunt-html-validation +validation-status.json +validation-report.json + +# misc +TODO.md + +# npmignore +test +test.js +.verb.md +.gitattributes +.editorconfig diff --git a/node_modules/array-initial/.travis.yml b/node_modules/array-initial/.travis.yml new file mode 100644 index 0000000000..67decb245a --- /dev/null +++ b/node_modules/array-initial/.travis.yml @@ -0,0 +1,14 @@ +sudo: false +os: + - linux + - osx +language: node_js +node_js: + - node + - '8' + - '7' + - '6' + - '5' + - '4' + - '0.12' + - '0.10' diff --git a/node_modules/array-initial/LICENSE-MIT b/node_modules/array-initial/LICENSE-MIT new file mode 100644 index 0000000000..f8c06dfe7a --- /dev/null +++ b/node_modules/array-initial/LICENSE-MIT @@ -0,0 +1,24 @@ +The MIT License (MIT) + +Copyright (c) 2014 Jon Schlinkert, contributors. + +Permission is hereby granted, free of charge, to any person +obtaining a copy of this software and associated documentation +files (the "Software"), to deal in the Software without +restriction, including without limitation the rights to use, +copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the +Software is furnished to do so, subject to the following +conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES +OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT +HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +OTHER DEALINGS IN THE SOFTWARE. diff --git a/node_modules/array-initial/README.md b/node_modules/array-initial/README.md new file mode 100644 index 0000000000..5b95675baf --- /dev/null +++ b/node_modules/array-initial/README.md @@ -0,0 +1,39 @@ +# array-initial [![NPM version](https://badge.fury.io/js/array-initial.svg)](http://badge.fury.io/js/array-initial) + +> Get all but the last element or last n elements of an array. + +## Install with [npm](npmjs.org) + +```bash +npm i array-initial --save +``` + +## Usage + +```js +var initial = require('array-initial'); + +initial(['a', 'b', 'c', 'd', 'e', 'f']); +//=> ['a', 'b', 'c', 'd', 'e'] + +initial(['a', 'b', 'c', 'd', 'e', 'f'], 1); +//=> ['a', 'b', 'c', 'd', 'e'] + +initial(['a', 'b', 'c', 'd', 'e', 'f'], 2); +//=> ['a', 'b', 'c', 'd'] +``` + +## Author + +**Jon Schlinkert** + ++ [github/jonschlinkert](https://github.com/jonschlinkert) ++ [twitter/jonschlinkert](http://twitter.com/jonschlinkert) + +## License +Copyright (c) 2014 Jon Schlinkert +Released under the MIT license + +*** + +_This file was generated by [verb](https://github.com/assemble/verb) on December 12, 2014. To update, run `npm i -g verb && verb`._ diff --git a/node_modules/array-initial/index.js b/node_modules/array-initial/index.js new file mode 100644 index 0000000000..239e8c6bea --- /dev/null +++ b/node_modules/array-initial/index.js @@ -0,0 +1,21 @@ +/*! + * array-initial + * + * Copyright (c) 2014 Jon Schlinkert, contributors. + * Licensed under the MIT license. + */ + +var isNumber = require('is-number'); +var slice = require('array-slice'); + +module.exports = function arrayInitial(arr, num) { + if (!Array.isArray(arr)) { + throw new Error('array-initial expects an array as the first argument.'); + } + + if (arr.length === 0) { + return null; + } + + return slice(arr, 0, arr.length - (isNumber(num) ? num : 1)); +}; diff --git a/node_modules/array-initial/node_modules/is-number/LICENSE b/node_modules/array-initial/node_modules/is-number/LICENSE new file mode 100644 index 0000000000..3f2eca18f1 --- /dev/null +++ b/node_modules/array-initial/node_modules/is-number/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2014-2017, Jon Schlinkert. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/array-initial/node_modules/is-number/README.md b/node_modules/array-initial/node_modules/is-number/README.md new file mode 100644 index 0000000000..6436992dcc --- /dev/null +++ b/node_modules/array-initial/node_modules/is-number/README.md @@ -0,0 +1,135 @@ +# is-number [![NPM version](https://img.shields.io/npm/v/is-number.svg?style=flat)](https://www.npmjs.com/package/is-number) [![NPM monthly downloads](https://img.shields.io/npm/dm/is-number.svg?style=flat)](https://npmjs.org/package/is-number) [![NPM total downloads](https://img.shields.io/npm/dt/is-number.svg?style=flat)](https://npmjs.org/package/is-number) [![Linux Build Status](https://img.shields.io/travis/jonschlinkert/is-number.svg?style=flat&label=Travis)](https://travis-ci.org/jonschlinkert/is-number) + +> Returns true if the value is a number. comprehensive tests. + +Please consider following this project's author, [Jon Schlinkert](https://github.com/jonschlinkert), and consider starring the project to show your :heart: and support. + +## Install + +Install with [npm](https://www.npmjs.com/): + +```sh +$ npm install --save is-number +``` + +## Usage + +To understand some of the rationale behind the decisions made in this library (and to learn about some oddities of number evaluation in JavaScript), [see this gist](https://gist.github.com/jonschlinkert/e30c70c713da325d0e81). + +```js +var isNumber = require('is-number'); +``` + +### true + +See the [tests](./test.js) for more examples. + +```js +isNumber(5e3) //=> 'true' +isNumber(0xff) //=> 'true' +isNumber(-1.1) //=> 'true' +isNumber(0) //=> 'true' +isNumber(1) //=> 'true' +isNumber(1.1) //=> 'true' +isNumber(10) //=> 'true' +isNumber(10.10) //=> 'true' +isNumber(100) //=> 'true' +isNumber('-1.1') //=> 'true' +isNumber('0') //=> 'true' +isNumber('012') //=> 'true' +isNumber('0xff') //=> 'true' +isNumber('1') //=> 'true' +isNumber('1.1') //=> 'true' +isNumber('10') //=> 'true' +isNumber('10.10') //=> 'true' +isNumber('100') //=> 'true' +isNumber('5e3') //=> 'true' +isNumber(parseInt('012')) //=> 'true' +isNumber(parseFloat('012')) //=> 'true' +``` + +### False + +See the [tests](./test.js) for more examples. + +```js +isNumber('foo') //=> 'false' +isNumber([1]) //=> 'false' +isNumber([]) //=> 'false' +isNumber(function () {}) //=> 'false' +isNumber(Infinity) //=> 'false' +isNumber(NaN) //=> 'false' +isNumber(new Array('abc')) //=> 'false' +isNumber(new Array(2)) //=> 'false' +isNumber(new Buffer('abc')) //=> 'false' +isNumber(null) //=> 'false' +isNumber(undefined) //=> 'false' +isNumber({abc: 'abc'}) //=> 'false' +``` + +## About + +
+Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new). + +
+ +
+Running Tests + +Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command: + +```sh +$ npm install && npm test +``` + +
+ +
+Building docs + +_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_ + +To generate the readme, run the following command: + +```sh +$ npm install -g verbose/verb#dev verb-generate-readme && verb +``` + +
+ +### Related projects + +You might also be interested in these projects: + +* [even](https://www.npmjs.com/package/even): Get the even numbered items from an array. | [homepage](https://github.com/jonschlinkert/even "Get the even numbered items from an array.") +* [is-even](https://www.npmjs.com/package/is-even): Return true if the given number is even. | [homepage](https://github.com/jonschlinkert/is-even "Return true if the given number is even.") +* [is-odd](https://www.npmjs.com/package/is-odd): Returns true if the given number is odd. | [homepage](https://github.com/jonschlinkert/is-odd "Returns true if the given number is odd.") +* [is-primitive](https://www.npmjs.com/package/is-primitive): Returns `true` if the value is a primitive. | [homepage](https://github.com/jonschlinkert/is-primitive "Returns `true` if the value is a primitive. ") +* [kind-of](https://www.npmjs.com/package/kind-of): Get the native type of a value. | [homepage](https://github.com/jonschlinkert/kind-of "Get the native type of a value.") +* [odd](https://www.npmjs.com/package/odd): Get the odd numbered items from an array. | [homepage](https://github.com/jonschlinkert/odd "Get the odd numbered items from an array.") + +### Contributors + +| **Commits** | **Contributor** | +| --- | --- | +| 38 | [jonschlinkert](https://github.com/jonschlinkert) | +| 5 | [charlike](https://github.com/charlike) | + +### Author + +**Jon Schlinkert** + +* [github/jonschlinkert](https://github.com/jonschlinkert) +* [twitter/jonschlinkert](https://twitter.com/jonschlinkert) + +### License + +Copyright © 2017, [Jon Schlinkert](https://github.com/jonschlinkert). +Released under the [MIT License](LICENSE). + +*** + +_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.6.0, on October 17, 2017._ \ No newline at end of file diff --git a/node_modules/array-initial/node_modules/is-number/index.js b/node_modules/array-initial/node_modules/is-number/index.js new file mode 100644 index 0000000000..5221f4056f --- /dev/null +++ b/node_modules/array-initial/node_modules/is-number/index.js @@ -0,0 +1,21 @@ +/*! + * is-number + * + * Copyright (c) 2014-2017, Jon Schlinkert. + * Released under the MIT License. + */ + +'use strict'; + +module.exports = function isNumber(num) { + var type = typeof num; + + if (type === 'string' || num instanceof String) { + // an empty string would be coerced to true with the below logic + if (!num.trim()) return false; + } else if (type !== 'number' && !(num instanceof Number)) { + return false; + } + + return (num - num + 1) >= 0; +}; diff --git a/node_modules/array-initial/node_modules/is-number/package.json b/node_modules/array-initial/node_modules/is-number/package.json new file mode 100644 index 0000000000..0325a6583f --- /dev/null +++ b/node_modules/array-initial/node_modules/is-number/package.json @@ -0,0 +1,113 @@ +{ + "_from": "is-number@^4.0.0", + "_id": "is-number@4.0.0", + "_inBundle": false, + "_integrity": "sha512-rSklcAIlf1OmFdyAqbnWTLVelsQ58uvZ66S/ZyawjWqIviTWCjg2PzVGw8WUA+nNuPTqb4wgA+NszrJ+08LlgQ==", + "_location": "/array-initial/is-number", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "is-number@^4.0.0", + "name": "is-number", + "escapedName": "is-number", + "rawSpec": "^4.0.0", + "saveSpec": null, + "fetchSpec": "^4.0.0" + }, + "_requiredBy": [ + "/array-initial" + ], + "_resolved": "https://registry.npmjs.org/is-number/-/is-number-4.0.0.tgz", + "_shasum": "0026e37f5454d73e356dfe6564699867c6a7f0ff", + "_spec": "is-number@^4.0.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/array-initial", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/jonschlinkert/is-number/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "Jon Schlinkert", + "url": "http://twitter.com/jonschlinkert" + }, + { + "name": "tunnckoCore", + "url": "https://i.am.charlike.online" + } + ], + "deprecated": false, + "description": "Returns true if the value is a number. comprehensive tests.", + "devDependencies": { + "benchmarked": "^2.0.0", + "chalk": "^2.1.0", + "gulp-format-md": "^1.0.0", + "mocha": "^3.0.1" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/jonschlinkert/is-number", + "keywords": [ + "check", + "coerce", + "coercion", + "integer", + "is", + "is-nan", + "is-num", + "is-number", + "istype", + "kind", + "math", + "nan", + "num", + "number", + "numeric", + "test", + "type", + "typeof", + "value" + ], + "license": "MIT", + "main": "index.js", + "name": "is-number", + "repository": { + "type": "git", + "url": "git+https://github.com/jonschlinkert/is-number.git" + }, + "scripts": { + "test": "mocha" + }, + "verb": { + "related": { + "list": [ + "even", + "is-even", + "is-odd", + "is-primitive", + "kind-of", + "odd" + ] + }, + "toc": false, + "layout": "default", + "tasks": [ + "readme" + ], + "plugins": [ + "gulp-format-md" + ], + "lint": { + "reflinks": true + } + }, + "version": "4.0.0" +} diff --git a/node_modules/array-initial/package.json b/node_modules/array-initial/package.json new file mode 100644 index 0000000000..6aaa6a883c --- /dev/null +++ b/node_modules/array-initial/package.json @@ -0,0 +1,71 @@ +{ + "_from": "array-initial@^1.0.0", + "_id": "array-initial@1.1.0", + "_inBundle": false, + "_integrity": "sha1-L6dLJnOTccOUe9enrcc74zSz15U=", + "_location": "/array-initial", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "array-initial@^1.0.0", + "name": "array-initial", + "escapedName": "array-initial", + "rawSpec": "^1.0.0", + "saveSpec": null, + "fetchSpec": "^1.0.0" + }, + "_requiredBy": [ + "/bach" + ], + "_resolved": "https://registry.npmjs.org/array-initial/-/array-initial-1.1.0.tgz", + "_shasum": "2fa74b26739371c3947bd7a7adc73be334b3d795", + "_spec": "array-initial@^1.0.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/bach", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/jonschlinkert/array-initial/issues" + }, + "bundleDependencies": false, + "dependencies": { + "array-slice": "^1.0.0", + "is-number": "^4.0.0" + }, + "deprecated": false, + "description": "Get all but the last element or last n elements of an array.", + "devDependencies": { + "mocha": "^2.0.0", + "should": "^11.2.1" + }, + "engines": { + "node": ">=0.10.0" + }, + "homepage": "https://github.com/jonschlinkert/array-initial", + "keywords": [ + "array", + "fast", + "first", + "initial", + "javascript", + "js", + "last", + "rest", + "util", + "utility", + "utils" + ], + "license": "MIT", + "main": "index.js", + "name": "array-initial", + "repository": { + "type": "git", + "url": "git://github.com/jonschlinkert/array-initial.git" + }, + "scripts": { + "test": "mocha -R spec" + }, + "version": "1.1.0" +} diff --git a/node_modules/array-last/LICENSE b/node_modules/array-last/LICENSE new file mode 100644 index 0000000000..3f2eca18f1 --- /dev/null +++ b/node_modules/array-last/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2014-2017, Jon Schlinkert. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/array-last/README.md b/node_modules/array-last/README.md new file mode 100755 index 0000000000..d976c93ed7 --- /dev/null +++ b/node_modules/array-last/README.md @@ -0,0 +1,94 @@ +# array-last [![NPM version](https://img.shields.io/npm/v/array-last.svg?style=flat)](https://www.npmjs.com/package/array-last) [![NPM monthly downloads](https://img.shields.io/npm/dm/array-last.svg?style=flat)](https://npmjs.org/package/array-last) [![NPM total downloads](https://img.shields.io/npm/dt/array-last.svg?style=flat)](https://npmjs.org/package/array-last) [![Linux Build Status](https://img.shields.io/travis/jonschlinkert/array-last.svg?style=flat&label=Travis)](https://travis-ci.org/jonschlinkert/array-last) + +> Get the last or last n elements in an array. + +Please consider following this project's author, [Jon Schlinkert](https://github.com/jonschlinkert), and consider starring the project to show your :heart: and support. + +## Install + +Install with [npm](https://www.npmjs.com/): + +```sh +$ npm install --save array-last +``` + +## Usage + +```js +var last = require('array-last'); + +last(['a', 'b', 'c', 'd', 'e', 'f']); +//=> 'f' + +last(['a', 'b', 'c', 'd', 'e', 'f'], 1); +//=> 'f' + +last(['a', 'b', 'c', 'd', 'e', 'f'], 3); +//=> ['d', 'e', 'f'] +``` + +## About + +
+Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new). + +
+ +
+Running Tests + +Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command: + +```sh +$ npm install && npm test +``` + +
+ +
+Building docs + +_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_ + +To generate the readme, run the following command: + +```sh +$ npm install -g verbose/verb#dev verb-generate-readme && verb +``` + +
+ +### Related projects + +You might also be interested in these projects: + +* [arr-union](https://www.npmjs.com/package/arr-union): Combines a list of arrays, returning a single array with unique values, using strict equality… [more](https://github.com/jonschlinkert/arr-union) | [homepage](https://github.com/jonschlinkert/arr-union) +* [array-unique](https://www.npmjs.com/package/array-unique): Remove duplicate values from an array. Fastest ES5 implementation. | [homepage](https://github.com/jonschlinkert/array-unique) +* [array-xor](https://www.npmjs.com/package/array-xor): Returns the symmetric difference (exclusive-or) of an array of elements (elements that are present in… [more](https://github.com/jonschlinkert/array-xor) | [homepage](https://github.com/jonschlinkert/array-xor) + +### Contributors + +| **Commits** | **Contributor** | +| --- | --- | +| 19 | [jonschlinkert](https://github.com/jonschlinkert) | +| 3 | [SpyMaster356](https://github.com/SpyMaster356) | +| 2 | [bendrucker](https://github.com/bendrucker) | +| 2 | [phated](https://github.com/phated) | + +### Author + +**Jon Schlinkert** + +* [github/jonschlinkert](https://github.com/jonschlinkert) +* [twitter/jonschlinkert](https://twitter.com/jonschlinkert) + +### License + +Copyright © 2017, [Jon Schlinkert](https://github.com/jonschlinkert). +Released under the [MIT License](LICENSE). + +*** + +_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.6.0, on November 30, 2017._ \ No newline at end of file diff --git a/node_modules/array-last/index.js b/node_modules/array-last/index.js new file mode 100644 index 0000000000..5b02f18141 --- /dev/null +++ b/node_modules/array-last/index.js @@ -0,0 +1,30 @@ +/*! + * array-last + * + * Copyright (c) 2014-2017, Jon Schlinkert. + * Released under the MIT License. + */ + +var isNumber = require('is-number'); + +module.exports = function last(arr, n) { + if (!Array.isArray(arr)) { + throw new Error('expected the first argument to be an array'); + } + + var len = arr.length; + if (len === 0) { + return null; + } + + n = isNumber(n) ? +n : 1; + if (n === 1) { + return arr[len - 1]; + } + + var res = new Array(n); + while (n--) { + res[n] = arr[--len]; + } + return res; +}; diff --git a/node_modules/array-last/node_modules/is-number/LICENSE b/node_modules/array-last/node_modules/is-number/LICENSE new file mode 100644 index 0000000000..3f2eca18f1 --- /dev/null +++ b/node_modules/array-last/node_modules/is-number/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2014-2017, Jon Schlinkert. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/array-last/node_modules/is-number/README.md b/node_modules/array-last/node_modules/is-number/README.md new file mode 100644 index 0000000000..6436992dcc --- /dev/null +++ b/node_modules/array-last/node_modules/is-number/README.md @@ -0,0 +1,135 @@ +# is-number [![NPM version](https://img.shields.io/npm/v/is-number.svg?style=flat)](https://www.npmjs.com/package/is-number) [![NPM monthly downloads](https://img.shields.io/npm/dm/is-number.svg?style=flat)](https://npmjs.org/package/is-number) [![NPM total downloads](https://img.shields.io/npm/dt/is-number.svg?style=flat)](https://npmjs.org/package/is-number) [![Linux Build Status](https://img.shields.io/travis/jonschlinkert/is-number.svg?style=flat&label=Travis)](https://travis-ci.org/jonschlinkert/is-number) + +> Returns true if the value is a number. comprehensive tests. + +Please consider following this project's author, [Jon Schlinkert](https://github.com/jonschlinkert), and consider starring the project to show your :heart: and support. + +## Install + +Install with [npm](https://www.npmjs.com/): + +```sh +$ npm install --save is-number +``` + +## Usage + +To understand some of the rationale behind the decisions made in this library (and to learn about some oddities of number evaluation in JavaScript), [see this gist](https://gist.github.com/jonschlinkert/e30c70c713da325d0e81). + +```js +var isNumber = require('is-number'); +``` + +### true + +See the [tests](./test.js) for more examples. + +```js +isNumber(5e3) //=> 'true' +isNumber(0xff) //=> 'true' +isNumber(-1.1) //=> 'true' +isNumber(0) //=> 'true' +isNumber(1) //=> 'true' +isNumber(1.1) //=> 'true' +isNumber(10) //=> 'true' +isNumber(10.10) //=> 'true' +isNumber(100) //=> 'true' +isNumber('-1.1') //=> 'true' +isNumber('0') //=> 'true' +isNumber('012') //=> 'true' +isNumber('0xff') //=> 'true' +isNumber('1') //=> 'true' +isNumber('1.1') //=> 'true' +isNumber('10') //=> 'true' +isNumber('10.10') //=> 'true' +isNumber('100') //=> 'true' +isNumber('5e3') //=> 'true' +isNumber(parseInt('012')) //=> 'true' +isNumber(parseFloat('012')) //=> 'true' +``` + +### False + +See the [tests](./test.js) for more examples. + +```js +isNumber('foo') //=> 'false' +isNumber([1]) //=> 'false' +isNumber([]) //=> 'false' +isNumber(function () {}) //=> 'false' +isNumber(Infinity) //=> 'false' +isNumber(NaN) //=> 'false' +isNumber(new Array('abc')) //=> 'false' +isNumber(new Array(2)) //=> 'false' +isNumber(new Buffer('abc')) //=> 'false' +isNumber(null) //=> 'false' +isNumber(undefined) //=> 'false' +isNumber({abc: 'abc'}) //=> 'false' +``` + +## About + +
+Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new). + +
+ +
+Running Tests + +Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command: + +```sh +$ npm install && npm test +``` + +
+ +
+Building docs + +_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_ + +To generate the readme, run the following command: + +```sh +$ npm install -g verbose/verb#dev verb-generate-readme && verb +``` + +
+ +### Related projects + +You might also be interested in these projects: + +* [even](https://www.npmjs.com/package/even): Get the even numbered items from an array. | [homepage](https://github.com/jonschlinkert/even "Get the even numbered items from an array.") +* [is-even](https://www.npmjs.com/package/is-even): Return true if the given number is even. | [homepage](https://github.com/jonschlinkert/is-even "Return true if the given number is even.") +* [is-odd](https://www.npmjs.com/package/is-odd): Returns true if the given number is odd. | [homepage](https://github.com/jonschlinkert/is-odd "Returns true if the given number is odd.") +* [is-primitive](https://www.npmjs.com/package/is-primitive): Returns `true` if the value is a primitive. | [homepage](https://github.com/jonschlinkert/is-primitive "Returns `true` if the value is a primitive. ") +* [kind-of](https://www.npmjs.com/package/kind-of): Get the native type of a value. | [homepage](https://github.com/jonschlinkert/kind-of "Get the native type of a value.") +* [odd](https://www.npmjs.com/package/odd): Get the odd numbered items from an array. | [homepage](https://github.com/jonschlinkert/odd "Get the odd numbered items from an array.") + +### Contributors + +| **Commits** | **Contributor** | +| --- | --- | +| 38 | [jonschlinkert](https://github.com/jonschlinkert) | +| 5 | [charlike](https://github.com/charlike) | + +### Author + +**Jon Schlinkert** + +* [github/jonschlinkert](https://github.com/jonschlinkert) +* [twitter/jonschlinkert](https://twitter.com/jonschlinkert) + +### License + +Copyright © 2017, [Jon Schlinkert](https://github.com/jonschlinkert). +Released under the [MIT License](LICENSE). + +*** + +_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.6.0, on October 17, 2017._ \ No newline at end of file diff --git a/node_modules/array-last/node_modules/is-number/index.js b/node_modules/array-last/node_modules/is-number/index.js new file mode 100644 index 0000000000..5221f4056f --- /dev/null +++ b/node_modules/array-last/node_modules/is-number/index.js @@ -0,0 +1,21 @@ +/*! + * is-number + * + * Copyright (c) 2014-2017, Jon Schlinkert. + * Released under the MIT License. + */ + +'use strict'; + +module.exports = function isNumber(num) { + var type = typeof num; + + if (type === 'string' || num instanceof String) { + // an empty string would be coerced to true with the below logic + if (!num.trim()) return false; + } else if (type !== 'number' && !(num instanceof Number)) { + return false; + } + + return (num - num + 1) >= 0; +}; diff --git a/node_modules/array-last/node_modules/is-number/package.json b/node_modules/array-last/node_modules/is-number/package.json new file mode 100644 index 0000000000..6f4e612ace --- /dev/null +++ b/node_modules/array-last/node_modules/is-number/package.json @@ -0,0 +1,113 @@ +{ + "_from": "is-number@^4.0.0", + "_id": "is-number@4.0.0", + "_inBundle": false, + "_integrity": "sha512-rSklcAIlf1OmFdyAqbnWTLVelsQ58uvZ66S/ZyawjWqIviTWCjg2PzVGw8WUA+nNuPTqb4wgA+NszrJ+08LlgQ==", + "_location": "/array-last/is-number", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "is-number@^4.0.0", + "name": "is-number", + "escapedName": "is-number", + "rawSpec": "^4.0.0", + "saveSpec": null, + "fetchSpec": "^4.0.0" + }, + "_requiredBy": [ + "/array-last" + ], + "_resolved": "https://registry.npmjs.org/is-number/-/is-number-4.0.0.tgz", + "_shasum": "0026e37f5454d73e356dfe6564699867c6a7f0ff", + "_spec": "is-number@^4.0.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/array-last", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/jonschlinkert/is-number/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "Jon Schlinkert", + "url": "http://twitter.com/jonschlinkert" + }, + { + "name": "tunnckoCore", + "url": "https://i.am.charlike.online" + } + ], + "deprecated": false, + "description": "Returns true if the value is a number. comprehensive tests.", + "devDependencies": { + "benchmarked": "^2.0.0", + "chalk": "^2.1.0", + "gulp-format-md": "^1.0.0", + "mocha": "^3.0.1" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/jonschlinkert/is-number", + "keywords": [ + "check", + "coerce", + "coercion", + "integer", + "is", + "is-nan", + "is-num", + "is-number", + "istype", + "kind", + "math", + "nan", + "num", + "number", + "numeric", + "test", + "type", + "typeof", + "value" + ], + "license": "MIT", + "main": "index.js", + "name": "is-number", + "repository": { + "type": "git", + "url": "git+https://github.com/jonschlinkert/is-number.git" + }, + "scripts": { + "test": "mocha" + }, + "verb": { + "related": { + "list": [ + "even", + "is-even", + "is-odd", + "is-primitive", + "kind-of", + "odd" + ] + }, + "toc": false, + "layout": "default", + "tasks": [ + "readme" + ], + "plugins": [ + "gulp-format-md" + ], + "lint": { + "reflinks": true + } + }, + "version": "4.0.0" +} diff --git a/node_modules/array-last/package.json b/node_modules/array-last/package.json new file mode 100644 index 0000000000..267203bd0c --- /dev/null +++ b/node_modules/array-last/package.json @@ -0,0 +1,119 @@ +{ + "_from": "array-last@^1.1.1", + "_id": "array-last@1.3.0", + "_inBundle": false, + "_integrity": "sha512-eOCut5rXlI6aCOS7Z7kCplKRKyiFQ6dHFBem4PwlwKeNFk2/XxTrhRh5T9PyaEWGy/NHTZWbY+nsZlNFJu9rYg==", + "_location": "/array-last", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "array-last@^1.1.1", + "name": "array-last", + "escapedName": "array-last", + "rawSpec": "^1.1.1", + "saveSpec": null, + "fetchSpec": "^1.1.1" + }, + "_requiredBy": [ + "/bach" + ], + "_resolved": "https://registry.npmjs.org/array-last/-/array-last-1.3.0.tgz", + "_shasum": "7aa77073fec565ddab2493f5f88185f404a9d336", + "_spec": "array-last@^1.1.1", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/bach", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/jonschlinkert/array-last/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "Ben Drucker", + "url": "http://www.bendrucker.me" + }, + { + "name": "Blaine Bublitz", + "url": "https://twitter.com/BlaineBublitz" + }, + { + "name": "Jon Schlinkert", + "url": "http://twitter.com/jonschlinkert" + }, + { + "name": "Stephen A. Wilson", + "url": "https://github.com/SpyMaster356" + } + ], + "dependencies": { + "is-number": "^4.0.0" + }, + "deprecated": false, + "description": "Get the last or last n elements in an array.", + "devDependencies": { + "ansi-bold": "^0.1.1", + "array-slice": "^1.0.0", + "benchmarked": "^1.1.1", + "gulp-format-md": "^1.0.0", + "matched": "^1.0.2", + "mocha": "^3.5.0" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/jonschlinkert/array-last", + "keywords": [ + "array", + "fast", + "first", + "initial", + "javascript", + "js", + "last", + "rest", + "util", + "utility", + "utils" + ], + "license": "MIT", + "main": "index.js", + "name": "array-last", + "repository": { + "type": "git", + "url": "git+https://github.com/jonschlinkert/array-last.git" + }, + "scripts": { + "test": "mocha" + }, + "verb": { + "run": true, + "toc": false, + "layout": "default", + "tasks": [ + "readme" + ], + "plugins": [ + "gulp-format-md" + ], + "related": { + "list": [ + "arr-union", + "array-unique", + "array-xor" + ] + }, + "reflinks": [ + "verb" + ], + "lint": { + "reflinks": true + } + }, + "version": "1.3.0" +} diff --git a/node_modules/array-slice/LICENSE b/node_modules/array-slice/LICENSE new file mode 100755 index 0000000000..3f2eca18f1 --- /dev/null +++ b/node_modules/array-slice/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2014-2017, Jon Schlinkert. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/array-slice/README.md b/node_modules/array-slice/README.md new file mode 100755 index 0000000000..e175ca033d --- /dev/null +++ b/node_modules/array-slice/README.md @@ -0,0 +1,82 @@ +# array-slice [![NPM version](https://img.shields.io/npm/v/array-slice.svg?style=flat)](https://www.npmjs.com/package/array-slice) [![NPM monthly downloads](https://img.shields.io/npm/dm/array-slice.svg?style=flat)](https://npmjs.org/package/array-slice) [![NPM total downloads](https://img.shields.io/npm/dt/array-slice.svg?style=flat)](https://npmjs.org/package/array-slice) [![Linux Build Status](https://img.shields.io/travis/jonschlinkert/array-slice.svg?style=flat&label=Travis)](https://travis-ci.org/jonschlinkert/array-slice) + +> Array-slice method. Slices `array` from the `start` index up to, but not including, the `end` index. + +Please consider following this project's author, [Jon Schlinkert](https://github.com/jonschlinkert), and consider starring the project to show your :heart: and support. + +## Install + +Install with [npm](https://www.npmjs.com/): + +```sh +$ npm install --save array-slice +``` + +This function is used instead of `Array#slice` to support node lists in IE < 9 and to ensure dense arrays are returned. This is also faster than native slice in some cases. + +## Usage + +```js +var slice = require('array-slice'); +var arr = ['a', 'b', 'd', 'e', 'f', 'g', 'h', 'i', 'j']; + +slice(arr, 3, 6); +//=> ['e', 'f', 'g'] +``` + +## About + +
+Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new). + +
+ +
+Running Tests + +Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command: + +```sh +$ npm install && npm test +``` + +
+ +
+Building docs + +_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_ + +To generate the readme, run the following command: + +```sh +$ npm install -g verbose/verb#dev verb-generate-readme && verb +``` + +
+ +### Related projects + +You might also be interested in these projects: + +* [arr-flatten](https://www.npmjs.com/package/arr-flatten): Recursively flatten an array or arrays. | [homepage](https://github.com/jonschlinkert/arr-flatten "Recursively flatten an array or arrays.") +* [array-unique](https://www.npmjs.com/package/array-unique): Remove duplicate values from an array. Fastest ES5 implementation. | [homepage](https://github.com/jonschlinkert/array-unique "Remove duplicate values from an array. Fastest ES5 implementation.") +* [array-xor](https://www.npmjs.com/package/array-xor): Returns the symmetric difference (exclusive-or) of an array of elements (elements that are present in… [more](https://github.com/jonschlinkert/array-xor) | [homepage](https://github.com/jonschlinkert/array-xor "Returns the symmetric difference (exclusive-or) of an array of elements (elements that are present in all given arrays and not in their intersections).") + +### Author + +**Jon Schlinkert** + +* [github/jonschlinkert](https://github.com/jonschlinkert) +* [twitter/jonschlinkert](https://twitter.com/jonschlinkert) + +### License + +Copyright © 2017, [Jon Schlinkert](https://github.com/jonschlinkert). +Released under the [MIT License](LICENSE). + +*** + +_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.6.0, on November 30, 2017._ \ No newline at end of file diff --git a/node_modules/array-slice/index.js b/node_modules/array-slice/index.js new file mode 100644 index 0000000000..15cdb7773b --- /dev/null +++ b/node_modules/array-slice/index.js @@ -0,0 +1,33 @@ +/*! + * array-slice + * + * Copyright (c) 2014-2017, Jon Schlinkert. + * Released under the MIT License. + */ + +'use strict'; + +module.exports = function slice(arr, start, end) { + var len = arr.length; + var range = []; + + start = idx(len, start); + end = idx(len, end, len); + + while (start < end) { + range.push(arr[start++]); + } + return range; +}; + +function idx(len, pos, end) { + if (pos == null) { + pos = end || 0; + } else if (pos < 0) { + pos = Math.max(len + pos, 0); + } else { + pos = Math.min(pos, len); + } + + return pos; +} diff --git a/node_modules/array-slice/package.json b/node_modules/array-slice/package.json new file mode 100644 index 0000000000..366976db77 --- /dev/null +++ b/node_modules/array-slice/package.json @@ -0,0 +1,86 @@ +{ + "_from": "array-slice@^1.0.0", + "_id": "array-slice@1.1.0", + "_inBundle": false, + "_integrity": "sha512-B1qMD3RBP7O8o0H2KbrXDyB0IccejMF15+87Lvlor12ONPRHP6gTjXMNkt/d3ZuOGbAe66hFmaCfECI24Ufp6w==", + "_location": "/array-slice", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "array-slice@^1.0.0", + "name": "array-slice", + "escapedName": "array-slice", + "rawSpec": "^1.0.0", + "saveSpec": null, + "fetchSpec": "^1.0.0" + }, + "_requiredBy": [ + "/array-initial", + "/object.defaults" + ], + "_resolved": "https://registry.npmjs.org/array-slice/-/array-slice-1.1.0.tgz", + "_shasum": "e368ea15f89bc7069f7ffb89aec3a6c7d4ac22d4", + "_spec": "array-slice@^1.0.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/object.defaults", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/jonschlinkert/array-slice/issues" + }, + "bundleDependencies": false, + "deprecated": false, + "description": "Array-slice method. Slices `array` from the `start` index up to, but not including, the `end` index.", + "devDependencies": { + "gulp-format-md": "^1.0.0", + "mocha": "^3.5.3" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/jonschlinkert/array-slice", + "keywords": [ + "array", + "javascript", + "js", + "slice", + "util", + "utils" + ], + "license": "MIT", + "main": "index.js", + "name": "array-slice", + "repository": { + "type": "git", + "url": "git+https://github.com/jonschlinkert/array-slice.git" + }, + "scripts": { + "test": "mocha" + }, + "verb": { + "toc": false, + "layout": "default", + "tasks": [ + "readme" + ], + "plugins": [ + "gulp-format-md" + ], + "related": { + "list": [ + "arr-flatten", + "array-unique", + "array-xor" + ] + }, + "lint": { + "reflinks": true + } + }, + "version": "1.1.0" +} diff --git a/node_modules/array-sort/LICENSE b/node_modules/array-sort/LICENSE new file mode 100644 index 0000000000..c0d7f13627 --- /dev/null +++ b/node_modules/array-sort/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2015-2017, Jon Schlinkert. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. \ No newline at end of file diff --git a/node_modules/array-sort/README.md b/node_modules/array-sort/README.md new file mode 100644 index 0000000000..94d9ba7f79 --- /dev/null +++ b/node_modules/array-sort/README.md @@ -0,0 +1,203 @@ +# array-sort [![NPM version](https://img.shields.io/npm/v/array-sort.svg?style=flat)](https://www.npmjs.com/package/array-sort) [![NPM monthly downloads](https://img.shields.io/npm/dm/array-sort.svg?style=flat)](https://npmjs.org/package/array-sort) [![NPM total downloads](https://img.shields.io/npm/dt/array-sort.svg?style=flat)](https://npmjs.org/package/array-sort) [![Linux Build Status](https://img.shields.io/travis/jonschlinkert/array-sort.svg?style=flat&label=Travis)](https://travis-ci.org/jonschlinkert/array-sort) [![Windows Build Status](https://img.shields.io/appveyor/ci/jonschlinkert/array-sort.svg?style=flat&label=AppVeyor)](https://ci.appveyor.com/project/jonschlinkert/array-sort) + +> Fast and powerful array sorting. Sort an array of objects by one or more properties. Any number of nested properties or custom comparison functions may be used. + +## Install + +Install with [npm](https://www.npmjs.com/): + +```sh +$ npm install --save array-sort +``` + +Install with [yarn](https://yarnpkg.com): + +```sh +$ yarn add array-sort +``` + +## Usage + +Sort an array by the given object property: + +```js +var arraySort = require('array-sort'); + +arraySort([{foo: 'y'}, {foo: 'z'}, {foo: 'x'}], 'foo'); +//=> [{foo: 'x'}, {foo: 'y'}, {foo: 'z'}] +``` + +**Reverse order** + +```js +arraySort([{foo: 'y'}, {foo: 'z'}, {foo: 'x'}], 'foo', {reverse: true}); +//=> [{foo: 'z'}, {foo: 'y'}, {foo: 'x'}] +``` + +## Params + +```js +arraySort(array, comparisonArgs); +``` + +* `array`: **{Array}** The array to sort +* `comparisonArgs`: **{Function|String|Array}**: One or more functions or object paths to use for sorting. + +## Examples + +**[Sort blog posts](examples/blog-posts.js)** + +```js +var arraySort = require('array-sort'); + +var posts = [ + { path: 'c.md', locals: { date: '2014-01-09' } }, + { path: 'a.md', locals: { date: '2014-01-02' } }, + { path: 'b.md', locals: { date: '2013-05-06' } }, +]; + +// sort by `locals.date` +console.log(arraySort(posts, 'locals.date')); + +// sort by `path` +console.log(arraySort(posts, 'path')); +``` + +**[Sort by multiple properties](examples/multiple-props.js)** + +```js +var arraySort = require('array-sort'); + +var posts = [ + { locals: { foo: 'bbb', date: '2013-05-06' }}, + { locals: { foo: 'aaa', date: '2012-01-02' }}, + { locals: { foo: 'ccc', date: '2014-01-02' }}, + { locals: { foo: 'ccc', date: '2015-01-02' }}, + { locals: { foo: 'bbb', date: '2014-06-01' }}, + { locals: { foo: 'aaa', date: '2014-02-02' }}, +]; + +// sort by `locals.foo`, then `locals.date` +var result = arraySort(posts, ['locals.foo', 'locals.date']); + +console.log(result); +// [ { locals: { foo: 'aaa', date: '2012-01-02' } }, +// { locals: { foo: 'aaa', date: '2014-02-02' } }, +// { locals: { foo: 'bbb', date: '2013-05-06' } }, +// { locals: { foo: 'bbb', date: '2014-06-01' } }, +// { locals: { foo: 'ccc', date: '2014-01-02' } }, +// { locals: { foo: 'ccc', date: '2015-01-02' } } ] +``` + +**[Custom function](examples/custom-function.js)** + +If custom functions are supplied, array elements are sorted according to the return value of the compare function. See the [docs for ](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/sort)`Array.sort()` for more details. + +```js +var arr = [ + {one: 'w', two: 'b'}, + {one: 'z', two: 'a'}, + {one: 'x', two: 'c'}, + {one: 'y', two: 'd'}, +]; + +function compare(prop) { + return function (a, b) { + return a[prop].localeCompare(b[prop]); + }; +} + +var result = arraySort(arr, function (a, b) { + return a.two.localeCompare(b.two); +}); + +console.log(result); +// [ { one: 'z', two: 'a' }, +// { one: 'w', two: 'b' }, +// { one: 'x', two: 'c' }, +// { one: 'y', two: 'd' } ] +``` + +**[Multiple custom functions](examples/custom-functions.js)** + +```js +var arr = [ + {foo: 'w', bar: 'y', baz: 'w'}, + {foo: 'x', bar: 'y', baz: 'w'}, + {foo: 'x', bar: 'y', baz: 'z'}, + {foo: 'x', bar: 'x', baz: 'w'}, +]; + +// reusable compare function +function compare(prop) { + return function (a, b) { + return a[prop].localeCompare(b[prop]); + }; +} + +// the `compare` functions can be a list or array +var result = arraySort(arr, compare('foo'), compare('bar'), compare('baz')); + +console.log(result); +// [ { foo: 'w', bar: 'y', baz: 'w' }, +// { foo: 'x', bar: 'x', baz: 'w' }, +// { foo: 'x', bar: 'y', baz: 'w' }, +// { foo: 'x', bar: 'y', baz: 'z' } ] +``` + +## About + +### Related projects + +* [get-value](https://www.npmjs.com/package/get-value): Use property paths (`a.b.c`) to get a nested value from an object. | [homepage](https://github.com/jonschlinkert/get-value "Use property paths (`a.b.c`) to get a nested value from an object.") +* [set-value](https://www.npmjs.com/package/set-value): Create nested values and any intermediaries using dot notation (`'a.b.c'`) paths. | [homepage](https://github.com/jonschlinkert/set-value "Create nested values and any intermediaries using dot notation (`'a.b.c'`) paths.") +* [sort-asc](https://www.npmjs.com/package/sort-asc): Sort array elements in ascending order. | [homepage](https://github.com/jonschlinkert/sort-asc "Sort array elements in ascending order.") +* [sort-desc](https://www.npmjs.com/package/sort-desc): Sort array elements in descending order. | [homepage](https://github.com/jonschlinkert/sort-desc "Sort array elements in descending order.") +* [sort-object](https://www.npmjs.com/package/sort-object): Sort the keys in an object. | [homepage](https://github.com/doowb/sort-object "Sort the keys in an object.") + +### Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new). + +### Contributors + +| **Commits** | **Contributor** | +| --- | --- | +| 10 | [jonschlinkert](https://github.com/jonschlinkert) | +| 4 | [doowb](https://github.com/doowb) | +| 1 | [iamstolis](https://github.com/iamstolis) | +| 1 | [wkevina](https://github.com/wkevina) | + +### Building docs + +_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_ + +To generate the readme, run the following command: + +```sh +$ npm install -g verbose/verb#dev verb-generate-readme && verb +``` + +### Running tests + +Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command: + +```sh +$ npm install && npm test +``` + +### Author + +**Jon Schlinkert** + +* [github/jonschlinkert](https://github.com/jonschlinkert) +* [twitter/jonschlinkert](https://twitter.com/jonschlinkert) + +### License + +Copyright © 2017, [Jon Schlinkert](https://github.com/jonschlinkert). +Released under the [MIT License](LICENSE). + +*** + +_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.6.0, on September 11, 2017._ \ No newline at end of file diff --git a/node_modules/array-sort/index.js b/node_modules/array-sort/index.js new file mode 100644 index 0000000000..01880e1a21 --- /dev/null +++ b/node_modules/array-sort/index.js @@ -0,0 +1,105 @@ +/*! + * array-sort + * + * Copyright (c) 2015-2017, Jon Schlinkert. + * Released under the MIT License. + */ + +'use strict'; + +var defaultCompare = require('default-compare'); +var typeOf = require('kind-of'); +var get = require('get-value'); + +/** + * Sort an array of objects by one or more properties. + * + * @param {Array} `arr` The Array to sort. + * @param {String|Array|Function} `props` One or more object paths or comparison functions. + * @param {Object} `opts` Pass `{ reverse: true }` to reverse the sort order. + * @return {Array} Returns a sorted array. + * @api public + */ + +function arraySort(arr, props, opts) { + if (arr == null) { + return []; + } + + if (!Array.isArray(arr)) { + throw new TypeError('array-sort expects an array.'); + } + + if (arguments.length === 1) { + return arr.sort(); + } + + var args = flatten([].slice.call(arguments, 1)); + + // if the last argument appears to be a plain object, + // it's not a valid `compare` arg, so it must be options. + if (typeOf(args[args.length - 1]) === 'object') { + opts = args.pop(); + } + return arr.sort(sortBy(args, opts)); +} + +/** + * Iterate over each comparison property or function until `1` or `-1` + * is returned. + * + * @param {String|Array|Function} `props` One or more object paths or comparison functions. + * @param {Object} `opts` Pass `{ reverse: true }` to reverse the sort order. + * @return {Array} + */ + +function sortBy(props, opts) { + opts = opts || {}; + + return function compareFn(a, b) { + var len = props.length, i = -1; + var result; + + while (++i < len) { + result = compare(props[i], a, b); + if (result !== 0) { + break; + } + } + if (opts.reverse === true) { + return result * -1; + } + return result; + }; +} + +/** + * Compare `a` to `b`. If an object `prop` is passed, then + * `a[prop]` is compared to `b[prop]` + */ + +function compare(prop, a, b) { + if (typeof prop === 'function') { + // expose `compare` to custom function + return prop(a, b, compare.bind(null, null)); + } + // compare object values + if (prop && typeof a === 'object' && typeof b === 'object') { + return compare(null, get(a, prop), get(b, prop)); + } + return defaultCompare(a, b); +} + +/** + * Flatten the given array. + */ + +function flatten(arr) { + return [].concat.apply([], arr); +} + +/** + * Expose `arraySort` + */ + +module.exports = arraySort; diff --git a/node_modules/array-sort/node_modules/kind-of/LICENSE b/node_modules/array-sort/node_modules/kind-of/LICENSE new file mode 100644 index 0000000000..3f2eca18f1 --- /dev/null +++ b/node_modules/array-sort/node_modules/kind-of/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2014-2017, Jon Schlinkert. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/array-sort/node_modules/kind-of/README.md b/node_modules/array-sort/node_modules/kind-of/README.md new file mode 100644 index 0000000000..170bf30498 --- /dev/null +++ b/node_modules/array-sort/node_modules/kind-of/README.md @@ -0,0 +1,342 @@ +# kind-of [![NPM version](https://img.shields.io/npm/v/kind-of.svg?style=flat)](https://www.npmjs.com/package/kind-of) [![NPM monthly downloads](https://img.shields.io/npm/dm/kind-of.svg?style=flat)](https://npmjs.org/package/kind-of) [![NPM total downloads](https://img.shields.io/npm/dt/kind-of.svg?style=flat)](https://npmjs.org/package/kind-of) [![Linux Build Status](https://img.shields.io/travis/jonschlinkert/kind-of.svg?style=flat&label=Travis)](https://travis-ci.org/jonschlinkert/kind-of) + +> Get the native type of a value. + +Please consider following this project's author, [Jon Schlinkert](https://github.com/jonschlinkert), and consider starring the project to show your :heart: and support. + +## Install + +Install with [npm](https://www.npmjs.com/): + +```sh +$ npm install --save kind-of +``` + +Install with [bower](https://bower.io/) + +```sh +$ bower install kind-of --save +``` + +## Why use this? + +1. [it's fast](#benchmarks) | [optimizations](#optimizations) +2. [better type checking](#better-type-checking) + +## Usage + +> es5, browser and es6 ready + +```js +var kindOf = require('kind-of'); + +kindOf(undefined); +//=> 'undefined' + +kindOf(null); +//=> 'null' + +kindOf(true); +//=> 'boolean' + +kindOf(false); +//=> 'boolean' + +kindOf(new Boolean(true)); +//=> 'boolean' + +kindOf(new Buffer('')); +//=> 'buffer' + +kindOf(42); +//=> 'number' + +kindOf(new Number(42)); +//=> 'number' + +kindOf('str'); +//=> 'string' + +kindOf(new String('str')); +//=> 'string' + +kindOf(arguments); +//=> 'arguments' + +kindOf({}); +//=> 'object' + +kindOf(Object.create(null)); +//=> 'object' + +kindOf(new Test()); +//=> 'object' + +kindOf(new Date()); +//=> 'date' + +kindOf([]); +//=> 'array' + +kindOf([1, 2, 3]); +//=> 'array' + +kindOf(new Array()); +//=> 'array' + +kindOf(/foo/); +//=> 'regexp' + +kindOf(new RegExp('foo')); +//=> 'regexp' + +kindOf(function () {}); +//=> 'function' + +kindOf(function * () {}); +//=> 'function' + +kindOf(new Function()); +//=> 'function' + +kindOf(new Map()); +//=> 'map' + +kindOf(new WeakMap()); +//=> 'weakmap' + +kindOf(new Set()); +//=> 'set' + +kindOf(new WeakSet()); +//=> 'weakset' + +kindOf(Symbol('str')); +//=> 'symbol' + +kindOf(new Int8Array()); +//=> 'int8array' + +kindOf(new Uint8Array()); +//=> 'uint8array' + +kindOf(new Uint8ClampedArray()); +//=> 'uint8clampedarray' + +kindOf(new Int16Array()); +//=> 'int16array' + +kindOf(new Uint16Array()); +//=> 'uint16array' + +kindOf(new Int32Array()); +//=> 'int32array' + +kindOf(new Uint32Array()); +//=> 'uint32array' + +kindOf(new Float32Array()); +//=> 'float32array' + +kindOf(new Float64Array()); +//=> 'float64array' +``` + +## Release history + +### v4.0.0 + +**Added** + +* `promise` support + +### v5.0.0 + +**Added** + +* `Set Iterator` and `Map Iterator` support + +**Fixed** + +* Now returns `generatorfunction` for generator functions + +## Benchmarks + +Benchmarked against [typeof](http://github.com/CodingFu/typeof) and [type-of](https://github.com/ForbesLindesay/type-of). +Note that performaces is slower for es6 features `Map`, `WeakMap`, `Set` and `WeakSet`. + +```bash +#1: array + current x 23,329,397 ops/sec ±0.82% (94 runs sampled) + lib-type-of x 4,170,273 ops/sec ±0.55% (94 runs sampled) + lib-typeof x 9,686,935 ops/sec ±0.59% (98 runs sampled) + +#2: boolean + current x 27,197,115 ops/sec ±0.85% (94 runs sampled) + lib-type-of x 3,145,791 ops/sec ±0.73% (97 runs sampled) + lib-typeof x 9,199,562 ops/sec ±0.44% (99 runs sampled) + +#3: date + current x 20,190,117 ops/sec ±0.86% (92 runs sampled) + lib-type-of x 5,166,970 ops/sec ±0.74% (94 runs sampled) + lib-typeof x 9,610,821 ops/sec ±0.50% (96 runs sampled) + +#4: function + current x 23,855,460 ops/sec ±0.60% (97 runs sampled) + lib-type-of x 5,667,740 ops/sec ±0.54% (100 runs sampled) + lib-typeof x 10,010,644 ops/sec ±0.44% (100 runs sampled) + +#5: null + current x 27,061,047 ops/sec ±0.97% (96 runs sampled) + lib-type-of x 13,965,573 ops/sec ±0.62% (97 runs sampled) + lib-typeof x 8,460,194 ops/sec ±0.61% (97 runs sampled) + +#6: number + current x 25,075,682 ops/sec ±0.53% (99 runs sampled) + lib-type-of x 2,266,405 ops/sec ±0.41% (98 runs sampled) + lib-typeof x 9,821,481 ops/sec ±0.45% (99 runs sampled) + +#7: object + current x 3,348,980 ops/sec ±0.49% (99 runs sampled) + lib-type-of x 3,245,138 ops/sec ±0.60% (94 runs sampled) + lib-typeof x 9,262,952 ops/sec ±0.59% (99 runs sampled) + +#8: regex + current x 21,284,827 ops/sec ±0.72% (96 runs sampled) + lib-type-of x 4,689,241 ops/sec ±0.43% (100 runs sampled) + lib-typeof x 8,957,593 ops/sec ±0.62% (98 runs sampled) + +#9: string + current x 25,379,234 ops/sec ±0.58% (96 runs sampled) + lib-type-of x 3,635,148 ops/sec ±0.76% (93 runs sampled) + lib-typeof x 9,494,134 ops/sec ±0.49% (98 runs sampled) + +#10: undef + current x 27,459,221 ops/sec ±1.01% (93 runs sampled) + lib-type-of x 14,360,433 ops/sec ±0.52% (99 runs sampled) + lib-typeof x 23,202,868 ops/sec ±0.59% (94 runs sampled) + +``` + +## Optimizations + +In 7 out of 8 cases, this library is 2x-10x faster than other top libraries included in the benchmarks. There are a few things that lead to this performance advantage, none of them hard and fast rules, but all of them simple and repeatable in almost any code library: + +1. Optimize around the fastest and most common use cases first. Of course, this will change from project-to-project, but I took some time to understand how and why `typeof` checks were being used in my own libraries and other libraries I use a lot. +2. Optimize around bottlenecks - In other words, the order in which conditionals are implemented is significant, because each check is only as fast as the failing checks that came before it. Here, the biggest bottleneck by far is checking for plain objects (an object that was created by the `Object` constructor). I opted to make this check happen by process of elimination rather than brute force up front (e.g. by using something like `val.constructor.name`), so that every other type check would not be penalized it. +3. Don't do uneccessary processing - why do `.slice(8, -1).toLowerCase();` just to get the word `regex`? It's much faster to do `if (type === '[object RegExp]') return 'regex'` +4. There is no reason to make the code in a microlib as terse as possible, just to win points for making it shorter. It's always better to favor performant code over terse code. You will always only be using a single `require()` statement to use the library anyway, regardless of how the code is written. + +## Better type checking + +kind-of is more correct than other type checking libs I've looked at. For example, here are some differing results from other popular libs: + +### [typeof](https://github.com/CodingFu/typeof) lib + +Incorrectly tests instances of custom constructors (pretty common): + +```js +var typeOf = require('typeof'); +function Test() {} +console.log(typeOf(new Test())); +//=> 'test' +``` + +Returns `object` instead of `arguments`: + +```js +function foo() { + console.log(typeOf(arguments)) //=> 'object' +} +foo(); +``` + +### [type-of](https://github.com/ForbesLindesay/type-of) lib + +Incorrectly returns `object` for generator functions, buffers, `Map`, `Set`, `WeakMap` and `WeakSet`: + +```js +function * foo() {} +console.log(typeOf(foo)); +//=> 'object' +console.log(typeOf(new Buffer(''))); +//=> 'object' +console.log(typeOf(new Map())); +//=> 'object' +console.log(typeOf(new Set())); +//=> 'object' +console.log(typeOf(new WeakMap())); +//=> 'object' +console.log(typeOf(new WeakSet())); +//=> 'object' +``` + +## About + +
+Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new). + +
+ +
+Running Tests + +Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command: + +```sh +$ npm install && npm test +``` + +
+ +
+Building docs + +_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_ + +To generate the readme, run the following command: + +```sh +$ npm install -g verbose/verb#dev verb-generate-readme && verb +``` + +
+ +### Related projects + +You might also be interested in these projects: + +* [is-glob](https://www.npmjs.com/package/is-glob): Returns `true` if the given string looks like a glob pattern or an extglob pattern… [more](https://github.com/jonschlinkert/is-glob) | [homepage](https://github.com/jonschlinkert/is-glob "Returns `true` if the given string looks like a glob pattern or an extglob pattern. This makes it easy to create code that only uses external modules like node-glob when necessary, resulting in much faster code execution and initialization time, and a bet") +* [is-number](https://www.npmjs.com/package/is-number): Returns true if the value is a number. comprehensive tests. | [homepage](https://github.com/jonschlinkert/is-number "Returns true if the value is a number. comprehensive tests.") +* [is-primitive](https://www.npmjs.com/package/is-primitive): Returns `true` if the value is a primitive. | [homepage](https://github.com/jonschlinkert/is-primitive "Returns `true` if the value is a primitive. ") + +### Contributors + +| **Commits** | **Contributor** | +| --- | --- | +| 82 | [jonschlinkert](https://github.com/jonschlinkert) | +| 3 | [aretecode](https://github.com/aretecode) | +| 2 | [miguelmota](https://github.com/miguelmota) | +| 1 | [dtothefp](https://github.com/dtothefp) | +| 1 | [ksheedlo](https://github.com/ksheedlo) | +| 1 | [pdehaan](https://github.com/pdehaan) | +| 1 | [laggingreflex](https://github.com/laggingreflex) | +| 1 | [charlike](https://github.com/charlike) | + +### Author + +**Jon Schlinkert** + +* [github/jonschlinkert](https://github.com/jonschlinkert) +* [twitter/jonschlinkert](https://twitter.com/jonschlinkert) + +### License + +Copyright © 2017, [Jon Schlinkert](https://github.com/jonschlinkert). +Released under the [MIT License](LICENSE). + +*** + +_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.6.0, on October 13, 2017._ \ No newline at end of file diff --git a/node_modules/array-sort/node_modules/kind-of/index.js b/node_modules/array-sort/node_modules/kind-of/index.js new file mode 100644 index 0000000000..fc5cde96ec --- /dev/null +++ b/node_modules/array-sort/node_modules/kind-of/index.js @@ -0,0 +1,147 @@ +var toString = Object.prototype.toString; + +/** + * Get the native `typeof` a value. + * + * @param {*} `val` + * @return {*} Native javascript type + */ + +module.exports = function kindOf(val) { + var type = typeof val; + + // primitivies + if (type === 'undefined') { + return 'undefined'; + } + if (val === null) { + return 'null'; + } + if (val === true || val === false || val instanceof Boolean) { + return 'boolean'; + } + if (type === 'string' || val instanceof String) { + return 'string'; + } + if (type === 'number' || val instanceof Number) { + return 'number'; + } + + // functions + if (type === 'function' || val instanceof Function) { + if (typeof val.constructor.name !== 'undefined' && val.constructor.name.slice(0, 9) === 'Generator') { + return 'generatorfunction'; + } + return 'function'; + } + + // array + if (typeof Array.isArray !== 'undefined' && Array.isArray(val)) { + return 'array'; + } + + // check for instances of RegExp and Date before calling `toString` + if (val instanceof RegExp) { + return 'regexp'; + } + if (val instanceof Date) { + return 'date'; + } + + // other objects + type = toString.call(val); + + if (type === '[object RegExp]') { + return 'regexp'; + } + if (type === '[object Date]') { + return 'date'; + } + if (type === '[object Arguments]') { + return 'arguments'; + } + if (type === '[object Error]') { + return 'error'; + } + if (type === '[object Promise]') { + return 'promise'; + } + + // buffer + if (isBuffer(val)) { + return 'buffer'; + } + + // es6: Map, WeakMap, Set, WeakSet + if (type === '[object Set]') { + return 'set'; + } + if (type === '[object WeakSet]') { + return 'weakset'; + } + if (type === '[object Map]') { + return 'map'; + } + if (type === '[object WeakMap]') { + return 'weakmap'; + } + if (type === '[object Symbol]') { + return 'symbol'; + } + + if (type === '[object Map Iterator]') { + return 'mapiterator'; + } + if (type === '[object Set Iterator]') { + return 'setiterator'; + } + if (type === '[object String Iterator]') { + return 'stringiterator'; + } + if (type === '[object Array Iterator]') { + return 'arrayiterator'; + } + + // typed arrays + if (type === '[object Int8Array]') { + return 'int8array'; + } + if (type === '[object Uint8Array]') { + return 'uint8array'; + } + if (type === '[object Uint8ClampedArray]') { + return 'uint8clampedarray'; + } + if (type === '[object Int16Array]') { + return 'int16array'; + } + if (type === '[object Uint16Array]') { + return 'uint16array'; + } + if (type === '[object Int32Array]') { + return 'int32array'; + } + if (type === '[object Uint32Array]') { + return 'uint32array'; + } + if (type === '[object Float32Array]') { + return 'float32array'; + } + if (type === '[object Float64Array]') { + return 'float64array'; + } + + // must be a plain object + return 'object'; +}; + +/** + * If you need to support Safari 5-7 (8-10 yr-old browser), + * take a look at https://github.com/feross/is-buffer + */ + +function isBuffer(val) { + return val.constructor + && typeof val.constructor.isBuffer === 'function' + && val.constructor.isBuffer(val); +} diff --git a/node_modules/array-sort/node_modules/kind-of/package.json b/node_modules/array-sort/node_modules/kind-of/package.json new file mode 100644 index 0000000000..cd38808b6a --- /dev/null +++ b/node_modules/array-sort/node_modules/kind-of/package.json @@ -0,0 +1,146 @@ +{ + "_from": "kind-of@^5.0.2", + "_id": "kind-of@5.1.0", + "_inBundle": false, + "_integrity": "sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw==", + "_location": "/array-sort/kind-of", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "kind-of@^5.0.2", + "name": "kind-of", + "escapedName": "kind-of", + "rawSpec": "^5.0.2", + "saveSpec": null, + "fetchSpec": "^5.0.2" + }, + "_requiredBy": [ + "/array-sort" + ], + "_resolved": "https://registry.npmjs.org/kind-of/-/kind-of-5.1.0.tgz", + "_shasum": "729c91e2d857b7a419a1f9aa65685c4c33f5845d", + "_spec": "kind-of@^5.0.2", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/array-sort", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/jonschlinkert/kind-of/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "David Fox-Powell", + "url": "https://dtothefp.github.io/me" + }, + { + "name": "James", + "url": "https://twitter.com/aretecode" + }, + { + "name": "Jon Schlinkert", + "url": "http://twitter.com/jonschlinkert" + }, + { + "name": "Ken Sheedlo", + "url": "kensheedlo.com" + }, + { + "name": "laggingreflex", + "url": "https://github.com/laggingreflex" + }, + { + "name": "Miguel Mota", + "url": "https://miguelmota.com" + }, + { + "name": "Peter deHaan", + "url": "http://about.me/peterdehaan" + }, + { + "name": "tunnckoCore", + "url": "https://i.am.charlike.online" + } + ], + "deprecated": false, + "description": "Get the native type of a value.", + "devDependencies": { + "ansi-bold": "^0.1.1", + "benchmarked": "^1.1.1", + "browserify": "^14.4.0", + "gulp-format-md": "^0.1.12", + "matched": "^0.4.4", + "mocha": "^3.4.2", + "type-of": "^2.0.1", + "typeof": "^1.0.0" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/jonschlinkert/kind-of", + "keywords": [ + "arguments", + "array", + "boolean", + "check", + "date", + "function", + "is", + "is-type", + "is-type-of", + "kind", + "kind-of", + "number", + "object", + "of", + "regexp", + "string", + "test", + "type", + "type-of", + "typeof", + "types" + ], + "license": "MIT", + "main": "index.js", + "name": "kind-of", + "repository": { + "type": "git", + "url": "git+https://github.com/jonschlinkert/kind-of.git" + }, + "scripts": { + "prepublish": "browserify -o browser.js -e index.js -s index --bare", + "test": "mocha" + }, + "verb": { + "related": { + "list": [ + "is-glob", + "is-number", + "is-primitive" + ] + }, + "toc": false, + "layout": "default", + "tasks": [ + "readme" + ], + "plugins": [ + "gulp-format-md" + ], + "lint": { + "reflinks": true + }, + "reflinks": [ + "type-of", + "typeof", + "verb" + ] + }, + "version": "5.1.0" +} diff --git a/node_modules/array-sort/package.json b/node_modules/array-sort/package.json new file mode 100644 index 0000000000..39fcdb677f --- /dev/null +++ b/node_modules/array-sort/package.json @@ -0,0 +1,137 @@ +{ + "_from": "array-sort@^1.0.0", + "_id": "array-sort@1.0.0", + "_inBundle": false, + "_integrity": "sha512-ihLeJkonmdiAsD7vpgN3CRcx2J2S0TiYW+IS/5zHBI7mKUq3ySvBdzzBfD236ubDBQFiiyG3SWCPc+msQ9KoYg==", + "_location": "/array-sort", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "array-sort@^1.0.0", + "name": "array-sort", + "escapedName": "array-sort", + "rawSpec": "^1.0.0", + "saveSpec": null, + "fetchSpec": "^1.0.0" + }, + "_requiredBy": [ + "/gulp/gulp-cli" + ], + "_resolved": "https://registry.npmjs.org/array-sort/-/array-sort-1.0.0.tgz", + "_shasum": "e4c05356453f56f53512a7d1d6123f2c54c0a88a", + "_spec": "array-sort@^1.0.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/gulp/node_modules/gulp-cli", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/jonschlinkert/array-sort/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "Brian Woodward", + "url": "https://twitter.com/doowb" + }, + { + "name": "Jan Stola", + "url": "https://github.com/iamstolis" + }, + { + "name": "Jon Schlinkert", + "url": "http://twitter.com/jonschlinkert" + }, + { + "name": "Kevin Ward", + "url": "https://github.com/wkevina" + } + ], + "dependencies": { + "default-compare": "^1.0.0", + "get-value": "^2.0.6", + "kind-of": "^5.0.2" + }, + "deprecated": false, + "description": "Fast and powerful array sorting. Sort an array of objects by one or more properties. Any number of nested properties or custom comparison functions may be used.", + "devDependencies": { + "ansi-bold": "^0.1.1", + "benchmarked": "^0.1.5", + "glob": "^7.0.3", + "gulp-format-md": "^0.1.8", + "lodash.sortbyorder": "^3.4.4", + "mocha": "^2.4.5", + "should": "^8.3.1" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/jonschlinkert/array-sort", + "keywords": [ + "arr", + "array", + "asc", + "ascend", + "ascending", + "desc", + "descend", + "descending", + "dot", + "element", + "elements", + "get", + "multiple", + "nested", + "obj", + "object", + "order", + "ordered", + "path", + "prop", + "properties", + "property", + "sort", + "sorted", + "sorting" + ], + "license": "MIT", + "main": "index.js", + "name": "array-sort", + "repository": { + "type": "git", + "url": "git+https://github.com/jonschlinkert/array-sort.git" + }, + "scripts": { + "test": "mocha" + }, + "verb": { + "reflinks": [ + "verb" + ], + "related": { + "list": [ + "get-value", + "set-value", + "sort-asc", + "sort-desc", + "sort-object" + ] + }, + "toc": false, + "layout": "default", + "tasks": [ + "readme" + ], + "plugins": [ + "gulp-format-md" + ], + "lint": { + "reflinks": true + } + }, + "version": "1.0.0" +} diff --git a/node_modules/array-unique/LICENSE b/node_modules/array-unique/LICENSE new file mode 100755 index 0000000000..842218cf09 --- /dev/null +++ b/node_modules/array-unique/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2014-2016, Jon Schlinkert + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/array-unique/README.md b/node_modules/array-unique/README.md new file mode 100755 index 0000000000..41c8c904ef --- /dev/null +++ b/node_modules/array-unique/README.md @@ -0,0 +1,77 @@ +# array-unique [![NPM version](https://img.shields.io/npm/v/array-unique.svg?style=flat)](https://www.npmjs.com/package/array-unique) [![NPM downloads](https://img.shields.io/npm/dm/array-unique.svg?style=flat)](https://npmjs.org/package/array-unique) [![Build Status](https://img.shields.io/travis/jonschlinkert/array-unique.svg?style=flat)](https://travis-ci.org/jonschlinkert/array-unique) + +Remove duplicate values from an array. Fastest ES5 implementation. + +## Install + +Install with [npm](https://www.npmjs.com/): + +```sh +$ npm install --save array-unique +``` + +## Usage + +```js +var unique = require('array-unique'); + +var arr = ['a', 'b', 'c', 'c']; +console.log(unique(arr)) //=> ['a', 'b', 'c'] +console.log(arr) //=> ['a', 'b', 'c'] + +/* The above modifies the input array. To prevent that at a slight performance cost: */ +var unique = require("array-unique").immutable; + +var arr = ['a', 'b', 'c', 'c']; +console.log(unique(arr)) //=> ['a', 'b', 'c'] +console.log(arr) //=> ['a', 'b', 'c', 'c'] +``` + +## About + +### Related projects + +* [arr-diff](https://www.npmjs.com/package/arr-diff): Returns an array with only the unique values from the first array, by excluding all… [more](https://github.com/jonschlinkert/arr-diff) | [homepage](https://github.com/jonschlinkert/arr-diff "Returns an array with only the unique values from the first array, by excluding all values from additional arrays using strict equality for comparisons.") +* [arr-flatten](https://www.npmjs.com/package/arr-flatten): Recursively flatten an array or arrays. This is the fastest implementation of array flatten. | [homepage](https://github.com/jonschlinkert/arr-flatten "Recursively flatten an array or arrays. This is the fastest implementation of array flatten.") +* [arr-map](https://www.npmjs.com/package/arr-map): Faster, node.js focused alternative to JavaScript's native array map. | [homepage](https://github.com/jonschlinkert/arr-map "Faster, node.js focused alternative to JavaScript's native array map.") +* [arr-pluck](https://www.npmjs.com/package/arr-pluck): Retrieves the value of a specified property from all elements in the collection. | [homepage](https://github.com/jonschlinkert/arr-pluck "Retrieves the value of a specified property from all elements in the collection.") +* [arr-reduce](https://www.npmjs.com/package/arr-reduce): Fast array reduce that also loops over sparse elements. | [homepage](https://github.com/jonschlinkert/arr-reduce "Fast array reduce that also loops over sparse elements.") +* [arr-union](https://www.npmjs.com/package/arr-union): Combines a list of arrays, returning a single array with unique values, using strict equality… [more](https://github.com/jonschlinkert/arr-union) | [homepage](https://github.com/jonschlinkert/arr-union "Combines a list of arrays, returning a single array with unique values, using strict equality for comparisons.") + +### Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new). + +### Building docs + +_(This document was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme) (a [verb](https://github.com/verbose/verb) generator), please don't edit the readme directly. Any changes to the readme must be made in [.verb.md](.verb.md).)_ + +To generate the readme and API documentation with [verb](https://github.com/verbose/verb): + +```sh +$ npm install -g verb verb-generate-readme && verb +``` + +### Running tests + +Install dev dependencies: + +```sh +$ npm install -d && npm test +``` + +### Author + +**Jon Schlinkert** + +* [github/jonschlinkert](https://github.com/jonschlinkert) +* [twitter/jonschlinkert](http://twitter.com/jonschlinkert) + +### License + +Copyright © 2016, [Jon Schlinkert](https://github.com/jonschlinkert). +Released under the [MIT license](https://github.com/jonschlinkert/array-unique/blob/master/LICENSE). + +*** + +_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.1.28, on July 31, 2016._ \ No newline at end of file diff --git a/node_modules/array-unique/index.js b/node_modules/array-unique/index.js new file mode 100644 index 0000000000..7e481e0724 --- /dev/null +++ b/node_modules/array-unique/index.js @@ -0,0 +1,43 @@ +/*! + * array-unique + * + * Copyright (c) 2014-2015, Jon Schlinkert. + * Licensed under the MIT License. + */ + +'use strict'; + +module.exports = function unique(arr) { + if (!Array.isArray(arr)) { + throw new TypeError('array-unique expects an array.'); + } + + var len = arr.length; + var i = -1; + + while (i++ < len) { + var j = i + 1; + + for (; j < arr.length; ++j) { + if (arr[i] === arr[j]) { + arr.splice(j--, 1); + } + } + } + return arr; +}; + +module.exports.immutable = function uniqueImmutable(arr) { + if (!Array.isArray(arr)) { + throw new TypeError('array-unique expects an array.'); + } + + var arrLen = arr.length; + var newArr = new Array(arrLen); + + for (var i = 0; i < arrLen; i++) { + newArr[i] = arr[i]; + } + + return module.exports(newArr); +}; diff --git a/node_modules/array-unique/package.json b/node_modules/array-unique/package.json new file mode 100644 index 0000000000..a827e5c262 --- /dev/null +++ b/node_modules/array-unique/package.json @@ -0,0 +1,102 @@ +{ + "_from": "array-unique@^0.3.2", + "_id": "array-unique@0.3.2", + "_inBundle": false, + "_integrity": "sha1-qJS3XUvE9s1nnvMkSp/Y9Gri1Cg=", + "_location": "/array-unique", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "array-unique@^0.3.2", + "name": "array-unique", + "escapedName": "array-unique", + "rawSpec": "^0.3.2", + "saveSpec": null, + "fetchSpec": "^0.3.2" + }, + "_requiredBy": [ + "/anymatch/extglob", + "/anymatch/micromatch", + "/braces", + "/chokidar/extglob", + "/chokidar/micromatch", + "/findup-sync/extglob", + "/findup-sync/micromatch", + "/matchdep/extglob", + "/matchdep/micromatch", + "/nanomatch" + ], + "_resolved": "https://registry.npmjs.org/array-unique/-/array-unique-0.3.2.tgz", + "_shasum": "a894b75d4bc4f6cd679ef3244a9fd8f46ae2d428", + "_spec": "array-unique@^0.3.2", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/anymatch/node_modules/micromatch", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/jonschlinkert/array-unique/issues" + }, + "bundleDependencies": false, + "deprecated": false, + "description": "Remove duplicate values from an array. Fastest ES5 implementation.", + "devDependencies": { + "array-uniq": "^1.0.2", + "benchmarked": "^0.1.3", + "gulp-format-md": "^0.1.9", + "mocha": "^2.5.3", + "should": "^10.0.0" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js", + "LICENSE", + "README.md" + ], + "homepage": "https://github.com/jonschlinkert/array-unique", + "keywords": [ + "array", + "unique" + ], + "license": "MIT", + "main": "index.js", + "name": "array-unique", + "repository": { + "type": "git", + "url": "git+https://github.com/jonschlinkert/array-unique.git" + }, + "scripts": { + "test": "mocha" + }, + "verb": { + "toc": false, + "layout": "default", + "tasks": [ + "readme" + ], + "plugins": [ + "gulp-format-md" + ], + "related": { + "list": [ + "arr-diff", + "arr-union", + "arr-flatten", + "arr-reduce", + "arr-map", + "arr-pluck" + ] + }, + "reflinks": [ + "verb", + "verb-generate-readme" + ], + "lint": { + "reflinks": true + } + }, + "version": "0.3.2" +} diff --git a/node_modules/arraybuffer.slice/.npmignore b/node_modules/arraybuffer.slice/.npmignore new file mode 100644 index 0000000000..cfbee8d8bd --- /dev/null +++ b/node_modules/arraybuffer.slice/.npmignore @@ -0,0 +1,17 @@ +lib-cov +lcov.info +*.seed +*.log +*.csv +*.dat +*.out +*.pid +*.gz + +pids +logs +results +build +.grunt + +node_modules diff --git a/node_modules/arraybuffer.slice/LICENCE b/node_modules/arraybuffer.slice/LICENCE new file mode 100644 index 0000000000..35fa37590d --- /dev/null +++ b/node_modules/arraybuffer.slice/LICENCE @@ -0,0 +1,18 @@ +Copyright (C) 2013 Rase- + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/node_modules/arraybuffer.slice/Makefile b/node_modules/arraybuffer.slice/Makefile new file mode 100644 index 0000000000..849887f7fa --- /dev/null +++ b/node_modules/arraybuffer.slice/Makefile @@ -0,0 +1,8 @@ + +REPORTER = dot + +test: + @./node_modules/.bin/mocha \ + --reporter $(REPORTER) + +.PHONY: test diff --git a/node_modules/arraybuffer.slice/README.md b/node_modules/arraybuffer.slice/README.md new file mode 100644 index 0000000000..15e465efca --- /dev/null +++ b/node_modules/arraybuffer.slice/README.md @@ -0,0 +1,17 @@ +# How to +```javascript +var sliceBuffer = require('arraybuffer.slice'); +var ab = (new Int8Array(5)).buffer; +var sliced = sliceBuffer(ab, 1, 3); +sliced = sliceBuffer(ab, 1); +``` + +# Licence (MIT) +Copyright (C) 2013 Rase- + + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/node_modules/arraybuffer.slice/index.js b/node_modules/arraybuffer.slice/index.js new file mode 100644 index 0000000000..11ac556e9a --- /dev/null +++ b/node_modules/arraybuffer.slice/index.js @@ -0,0 +1,29 @@ +/** + * An abstraction for slicing an arraybuffer even when + * ArrayBuffer.prototype.slice is not supported + * + * @api public + */ + +module.exports = function(arraybuffer, start, end) { + var bytes = arraybuffer.byteLength; + start = start || 0; + end = end || bytes; + + if (arraybuffer.slice) { return arraybuffer.slice(start, end); } + + if (start < 0) { start += bytes; } + if (end < 0) { end += bytes; } + if (end > bytes) { end = bytes; } + + if (start >= bytes || start >= end || bytes === 0) { + return new ArrayBuffer(0); + } + + var abv = new Uint8Array(arraybuffer); + var result = new Uint8Array(end - start); + for (var i = start, ii = 0; i < end; i++, ii++) { + result[ii] = abv[i]; + } + return result.buffer; +}; diff --git a/node_modules/arraybuffer.slice/package.json b/node_modules/arraybuffer.slice/package.json new file mode 100644 index 0000000000..0f66dcad57 --- /dev/null +++ b/node_modules/arraybuffer.slice/package.json @@ -0,0 +1,44 @@ +{ + "_from": "arraybuffer.slice@~0.0.7", + "_id": "arraybuffer.slice@0.0.7", + "_inBundle": false, + "_integrity": "sha512-wGUIVQXuehL5TCqQun8OW81jGzAWycqzFF8lFp+GOM5BXLYj3bKNsYC4daB7n6XjCqxQA/qgTJ+8ANR3acjrog==", + "_location": "/arraybuffer.slice", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "arraybuffer.slice@~0.0.7", + "name": "arraybuffer.slice", + "escapedName": "arraybuffer.slice", + "rawSpec": "~0.0.7", + "saveSpec": null, + "fetchSpec": "~0.0.7" + }, + "_requiredBy": [ + "/engine.io-parser" + ], + "_resolved": "https://registry.npmjs.org/arraybuffer.slice/-/arraybuffer.slice-0.0.7.tgz", + "_shasum": "3bbc4275dd584cc1b10809b89d4e8b63a69e7675", + "_spec": "arraybuffer.slice@~0.0.7", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/engine.io-parser", + "bugs": { + "url": "https://github.com/rase-/arraybuffer.slice/issues" + }, + "bundleDependencies": false, + "dependencies": {}, + "deprecated": false, + "description": "Exports a function for slicing ArrayBuffers (no polyfilling)", + "devDependencies": { + "expect.js": "0.2.0", + "mocha": "1.17.1" + }, + "homepage": "https://github.com/rase-/arraybuffer.slice", + "license": "MIT", + "name": "arraybuffer.slice", + "repository": { + "type": "git", + "url": "git+ssh://git@github.com/rase-/arraybuffer.slice.git" + }, + "version": "0.0.7" +} diff --git a/node_modules/arraybuffer.slice/test/slice-buffer.js b/node_modules/arraybuffer.slice/test/slice-buffer.js new file mode 100644 index 0000000000..4778da67da --- /dev/null +++ b/node_modules/arraybuffer.slice/test/slice-buffer.js @@ -0,0 +1,227 @@ +/* + * Test dependencies + */ + +var sliceBuffer = require('../index.js'); +var expect = require('expect.js'); + +/** + * Tests + */ + +describe('sliceBuffer', function() { + describe('using standard slice', function() { + it('should slice correctly with only start provided', function() { + var abv = new Uint8Array(10); + for (var i = 0; i < abv.length; i++) { + abv[i] = i; + } + + var sliced = sliceBuffer(abv.buffer, 3); + var sabv = new Uint8Array(sliced); + for (var i = 3, ii = 0; i < abv.length; i++, ii++) { + expect(abv[i]).to.equal(sabv[ii]); + } + }); + + it('should slice correctly with start and end provided', function() { + var abv = new Uint8Array(10); + for (var i = 0; i < abv.length; i++) { + abv[i] = i; + } + + var sliced = sliceBuffer(abv.buffer, 3, 8); + var sabv = new Uint8Array(sliced); + for (var i = 3, ii = 0; i < 8; i++, ii++) { + expect(abv[i]).to.equal(sabv[ii]); + } + }); + + it('should slice correctly with negative start', function() { + var abv = new Uint8Array(10); + for (var i = 0; i < abv.length; i++) { + abv[i] = i; + } + + var sliced = sliceBuffer(abv.buffer, -3); + var sabv = new Uint8Array(sliced); + for (var i = abv.length - 3, ii = 0; i < abv.length; i++, ii++) { + expect(abv[i]).to.equal(sabv[ii]); + } + }); + + it('should slice correctly with negative end', function() { + var abv = new Uint8Array(10); + for (var i = 0; i < abv.length; i++) { + abv[i] = i; + } + + var sliced = sliceBuffer(abv.buffer, 0, -3); + var sabv = new Uint8Array(sliced); + for (var i = 0, ii = 0; i < abv.length - 3; i++, ii++) { + expect(abv[i]).to.equal(sabv[ii]); + } + }); + + it('should slice correctly with negative start and end', function() { + var abv = new Uint8Array(10); + for (var i = 0; i < abv.length; i++) { + abv[i] = i; + } + + var sliced = sliceBuffer(abv.buffer, -6, -3); + var sabv = new Uint8Array(sliced); + for (var i = abv.length - 6, ii = 0; i < abv.length - 3; i++, ii++) { + expect(abv[i]).to.equal(sabv[ii]); + } + }); + + it('should slice correctly with equal start and end', function() { + var abv = new Uint8Array(10); + for (var i = 0; i < abv.length; i++) { + abv[i] = i; + } + + var sliced = sliceBuffer(abv.buffer, 1, 1); + expect(sliced.byteLength).to.equal(0); + }); + + it('should slice correctly when end larger than buffer', function() { + var abv = new Uint8Array(10); + for (var i = 0; i < abv.length; i++) { + abv[i] = i; + } + + var sliced = sliceBuffer(abv.buffer, 0, 100); + expect(new Uint8Array(sliced)).to.eql(abv); + }); + + it('shoud slice correctly when start larger than end', function() { + var abv = new Uint8Array(10); + for (var i = 0; i < abv.length; i++) { + abv[i] = i; + } + + var sliced = sliceBuffer(abv.buffer, 6, 5); + expect(sliced.byteLength).to.equal(0); + }); + }); + + describe('using fallback', function() { + it('should slice correctly with only start provided', function() { + var abv = new Uint8Array(10); + for (var i = 0; i < abv.length; i++) { + abv[i] = i; + } + var ab = abv.buffer; + ab.slice = undefined; + + var sliced = sliceBuffer(ab, 3); + var sabv = new Uint8Array(sliced); + for (var i = 3, ii = 0; i < abv.length; i++, ii++) { + expect(abv[i]).to.equal(sabv[ii]); + } + }); + + it('should slice correctly with start and end provided', function() { + var abv = new Uint8Array(10); + for (var i = 0; i < abv.length; i++) { + abv[i] = i; + } + var ab = abv.buffer; + ab.slice = undefined; + + + var sliced = sliceBuffer(ab, 3, 8); + var sabv = new Uint8Array(sliced); + for (var i = 3, ii = 0; i < 8; i++, ii++) { + expect(abv[i]).to.equal(sabv[ii]); + } + }); + + it('should slice correctly with negative start', function() { + var abv = new Uint8Array(10); + for (var i = 0; i < abv.length; i++) { + abv[i] = i; + } + var ab = abv.buffer; + ab.slice = undefined; + + + var sliced = sliceBuffer(ab, -3); + var sabv = new Uint8Array(sliced); + for (var i = abv.length - 3, ii = 0; i < abv.length; i++, ii++) { + expect(abv[i]).to.equal(sabv[ii]); + } + }); + + it('should slice correctly with negative end', function() { + var abv = new Uint8Array(10); + for (var i = 0; i < abv.length; i++) { + abv[i] = i; + } + var ab = abv.buffer; + ab.slice = undefined; + + var sliced = sliceBuffer(ab, 0, -3); + var sabv = new Uint8Array(sliced); + for (var i = 0, ii = 0; i < abv.length - 3; i++, ii++) { + expect(abv[i]).to.equal(sabv[ii]); + } + }); + + it('should slice correctly with negative start and end', function() { + var abv = new Uint8Array(10); + for (var i = 0; i < abv.length; i++) { + abv[i] = i; + } + var ab = abv.buffer; + ab.slice = undefined; + + var sliced = sliceBuffer(ab, -6, -3); + var sabv = new Uint8Array(sliced); + for (var i = abv.length - 6, ii = 0; i < abv.length - 3; i++, ii++) { + expect(abv[i]).to.equal(sabv[ii]); + } + }); + + it('should slice correctly with equal start and end', function() { + var abv = new Uint8Array(10); + for (var i = 0; i < abv.length; i++) { + abv[i] = i; + } + var ab = abv.buffer; + ab.slice = undefined; + + var sliced = sliceBuffer(ab, 1, 1); + expect(sliced.byteLength).to.equal(0); + }); + + it('should slice correctly when end larger than buffer', function() { + var abv = new Uint8Array(10); + for (var i = 0; i < abv.length; i++) { + abv[i] = i; + } + var ab = abv.buffer; + ab.slice = undefined; + + var sliced = sliceBuffer(ab, 0, 100); + var sabv = new Uint8Array(sliced); + for (var i = 0; i < abv.length; i++) { + expect(abv[i]).to.equal(sabv[i]); + } + }); + + it('shoud slice correctly when start larger than end', function() { + var abv = new Uint8Array(10); + for (var i = 0; i < abv.length; i++) { + abv[i] = i; + } + var ab = abv.buffer; + ab.slice = undefined; + + var sliced = sliceBuffer(ab, 6, 5); + expect(sliced.byteLength).to.equal(0); + }); + }); +}); diff --git a/node_modules/assign-symbols/LICENSE b/node_modules/assign-symbols/LICENSE new file mode 100644 index 0000000000..65f90aca8c --- /dev/null +++ b/node_modules/assign-symbols/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2015, Jon Schlinkert. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/assign-symbols/README.md b/node_modules/assign-symbols/README.md new file mode 100644 index 0000000000..422729d45e --- /dev/null +++ b/node_modules/assign-symbols/README.md @@ -0,0 +1,73 @@ +# assign-symbols [![NPM version](https://badge.fury.io/js/assign-symbols.svg)](http://badge.fury.io/js/assign-symbols) + +> Assign the enumerable es6 Symbol properties from an object (or objects) to the first object passed on the arguments. Can be used as a supplement to other extend, assign or merge methods as a polyfill for the Symbols part of the es6 Object.assign method. + +From the [Mozilla Developer docs for Symbol](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Symbol): + +> A symbol is a unique and immutable data type and may be used as an identifier for object properties. The symbol object is an implicit object wrapper for the symbol primitive data type. + +## Install + +Install with [npm](https://www.npmjs.com/) + +```sh +$ npm i assign-symbols --save +``` + +## Usage + +```js +var assignSymbols = require('assign-symbols'); +var obj = {}; + +var one = {}; +var symbolOne = Symbol('aaa'); +one[symbolOne] = 'bbb'; + +var two = {}; +var symbolTwo = Symbol('ccc'); +two[symbolTwo] = 'ddd'; + +assignSymbols(obj, one, two); + +console.log(obj[symbolOne]); +//=> 'bbb' +console.log(obj[symbolTwo]); +//=> 'ddd' +``` + +## Similar projects + +* [assign-deep](https://www.npmjs.com/package/assign-deep): Deeply assign the enumerable properties of source objects to a destination object. | [homepage](https://github.com/jonschlinkert/assign-deep) +* [clone-deep](https://www.npmjs.com/package/clone-deep): Recursively (deep) clone JavaScript native types, like Object, Array, RegExp, Date as well as primitives. | [homepage](https://github.com/jonschlinkert/clone-deep) +* [extend-shallow](https://www.npmjs.com/package/extend-shallow): Extend an object with the properties of additional objects. node.js/javascript util. | [homepage](https://github.com/jonschlinkert/extend-shallow) +* [merge-deep](https://www.npmjs.com/package/merge-deep): Recursively merge values in a javascript object. | [homepage](https://github.com/jonschlinkert/merge-deep) +* [mixin-deep](https://www.npmjs.com/package/mixin-deep): Deeply mix the properties of objects into the first object. Like merge-deep, but doesn't clone. | [homepage](https://github.com/jonschlinkert/mixin-deep) + +## Running tests + +Install dev dependencies: + +```sh +$ npm i -d && npm test +``` + +## Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](https://github.com/jonschlinkert/assign-symbols/issues/new). + +## Author + +**Jon Schlinkert** + ++ [github/jonschlinkert](https://github.com/jonschlinkert) ++ [twitter/jonschlinkert](http://twitter.com/jonschlinkert) + +## License + +Copyright © 2015 Jon Schlinkert +Released under the MIT license. + +*** + +_This file was generated by [verb-cli](https://github.com/assemble/verb-cli) on November 06, 2015._ \ No newline at end of file diff --git a/node_modules/assign-symbols/index.js b/node_modules/assign-symbols/index.js new file mode 100644 index 0000000000..c08a232b7f --- /dev/null +++ b/node_modules/assign-symbols/index.js @@ -0,0 +1,40 @@ +/*! + * assign-symbols + * + * Copyright (c) 2015, Jon Schlinkert. + * Licensed under the MIT License. + */ + +'use strict'; + +module.exports = function(receiver, objects) { + if (receiver === null || typeof receiver === 'undefined') { + throw new TypeError('expected first argument to be an object.'); + } + + if (typeof objects === 'undefined' || typeof Symbol === 'undefined') { + return receiver; + } + + if (typeof Object.getOwnPropertySymbols !== 'function') { + return receiver; + } + + var isEnumerable = Object.prototype.propertyIsEnumerable; + var target = Object(receiver); + var len = arguments.length, i = 0; + + while (++i < len) { + var provider = Object(arguments[i]); + var names = Object.getOwnPropertySymbols(provider); + + for (var j = 0; j < names.length; j++) { + var key = names[j]; + + if (isEnumerable.call(provider, key)) { + target[key] = provider[key]; + } + } + } + return target; +}; diff --git a/node_modules/assign-symbols/package.json b/node_modules/assign-symbols/package.json new file mode 100644 index 0000000000..3dfeb5d441 --- /dev/null +++ b/node_modules/assign-symbols/package.json @@ -0,0 +1,71 @@ +{ + "_from": "assign-symbols@^1.0.0", + "_id": "assign-symbols@1.0.0", + "_inBundle": false, + "_integrity": "sha1-WWZ/QfrdTyDMvCu5a41Pf3jsA2c=", + "_location": "/assign-symbols", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "assign-symbols@^1.0.0", + "name": "assign-symbols", + "escapedName": "assign-symbols", + "rawSpec": "^1.0.0", + "saveSpec": null, + "fetchSpec": "^1.0.0" + }, + "_requiredBy": [ + "/extend-shallow" + ], + "_resolved": "https://registry.npmjs.org/assign-symbols/-/assign-symbols-1.0.0.tgz", + "_shasum": "59667f41fadd4f20ccbc2bb96b8d4f7f78ec0367", + "_spec": "assign-symbols@^1.0.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/extend-shallow", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/jonschlinkert/assign-symbols/issues" + }, + "bundleDependencies": false, + "deprecated": false, + "description": "Assign the enumerable es6 Symbol properties from an object (or objects) to the first object passed on the arguments. Can be used as a supplement to other extend, assign or merge methods as a polyfill for the Symbols part of the es6 Object.assign method.", + "devDependencies": { + "mocha": "^3.0.0" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/jonschlinkert/assign-symbols", + "keywords": [ + "assign", + "symbols" + ], + "license": "MIT", + "main": "index.js", + "name": "assign-symbols", + "repository": { + "type": "git", + "url": "git+https://github.com/jonschlinkert/assign-symbols.git" + }, + "scripts": { + "test": "mocha" + }, + "verb": { + "related": { + "list": [ + "assign-deep", + "mixin-deep", + "merge-deep", + "extend-shallow", + "clone-deep" + ] + } + }, + "version": "1.0.0" +} diff --git a/node_modules/async-done/LICENSE b/node_modules/async-done/LICENSE new file mode 100644 index 0000000000..9aedc0d725 --- /dev/null +++ b/node_modules/async-done/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2015 Blaine Bublitz, Eric Schoffstall and other contributors + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/node_modules/async-done/README.md b/node_modules/async-done/README.md new file mode 100644 index 0000000000..93545c27ae --- /dev/null +++ b/node_modules/async-done/README.md @@ -0,0 +1,121 @@ +

+ + + +

+ +# async-done + +[![NPM version][npm-image]][npm-url] [![Downloads][downloads-image]][npm-url] [![Azure Pipelines Build Status][azure-pipelines-image]][azure-pipelines-url] [![Travis Build Status][travis-image]][travis-url] [![AppVeyor Build Status][appveyor-image]][appveyor-url] [![Coveralls Status][coveralls-image]][coveralls-url] [![Gitter chat][gitter-image]][gitter-url] + +Allows libraries to handle various caller provided asynchronous functions uniformly. Maps promises, observables, child processes and streams, and callbacks to callback style. + +As async conventions evolve, it is useful to be able to deal with several different *styles* of async completion uniformly. With this module you can handle completion using a node-style callback, regardless of a return value that's a promise, observable, child process or stream. + +## Usage + +### Successful completion + +```js +var asyncDone = require('async-done'); + +asyncDone(function(done){ + // do async things + done(null, 2); +}, function(error, result){ + // `error` will be null on successful execution of the first function. + // `result` will be the result from the first function. +}); +``` + +### Failed completion + +```js +var asyncDone = require('async-done'); + +asyncDone(function(done){ + // do async things + done(new Error('Some Error Occurred')); +}, function(error, result){ + // `error` will be an error from the first function. + // `result` will be undefined on failed execution of the first function. +}); +``` + +## API + +### `asyncDone(fn, callback)` + +Takes a function to execute (`fn`) and a function to call on completion (`callback`). + +#### `fn([done])` + +Optionally takes a callback to call when async tasks are complete. + +#### Completion and Error Resolution + +* `Callback` (`done`) called + - Completion: called with null error + - Error: called with non-null error +* `Stream` or `EventEmitter` returned + - Completion: [end-of-stream][end-of-stream] module + - Error: [domains][domains] + - __Note:__ Only actual streams are supported, not faux-streams; Therefore, modules like [`event-stream`][event-stream] are not supported. +* `Child Process` returned + - Completion [end-of-stream][end-of-stream] module + - Error: [domains][domains] +* `Promise` returned + - Completion: [onFulfilled][promise-onfulfilled] method called + - Error: [onRejected][promise-onrejected] method called +* `Observable` (e.g. from [RxJS v5][rxjs5-observable] or [RxJS v4][rxjs5-observable]) returned + - Completion: [complete][rxjs5-observer-complete] method called + - Error: [error][rxjs5-observer-error] method called + +__Warning:__ Sync tasks are __not supported__ and your function will never complete if the one of the above strategies is not used to signal completion. However, thrown errors will be caught by the domain. + +#### `callback(error, result)` + +If an error doesn't occur in the execution of the `fn` function, the `callback` method will receive the results as its second argument. Note: Some streams don't received any results. + +If an error occurred in the execution of the `fn` function, The `callback` method will receive an error as its first argument. + +Errors can be caused by: + +* A thrown error +* An error passed to a `done` callback +* An `error` event emitted on a returned `Stream`, `EventEmitter` or `Child Process` +* A rejection of a returned `Promise` - If the `Promise` is not rejected with a value, we generate a new `Error` +* The `onError` handler being called on an `Observable` + +## License + +MIT + +[downloads-image]: https://img.shields.io/npm/dm/async-done.svg +[npm-url]: https://www.npmjs.com/package/async-done +[npm-image]: https://img.shields.io/npm/v/async-done.svg + +[azure-pipelines-url]: https://dev.azure.com/gulpjs/gulp/_build/latest?definitionId=6&branchName=master +[azure-pipelines-image]: https://dev.azure.com/gulpjs/gulp/_apis/build/status/async-done?branchName=master + +[travis-url]: https://travis-ci.org/gulpjs/async-done +[travis-image]: https://img.shields.io/travis/gulpjs/async-done.svg?label=travis-ci + +[appveyor-url]: https://ci.appveyor.com/project/gulpjs/async-done +[appveyor-image]: https://img.shields.io/appveyor/ci/gulpjs/async-done.svg?label=appveyor + +[coveralls-url]: https://coveralls.io/r/gulpjs/async-done +[coveralls-image]: https://img.shields.io/coveralls/gulpjs/async-done/master.svg + +[gitter-url]: https://gitter.im/gulpjs/gulp +[gitter-image]: https://badges.gitter.im/gulpjs/gulp.svg + +[end-of-stream]: https://www.npmjs.com/package/end-of-stream +[domains]: http://nodejs.org/api/domain.html +[event-stream]: https://github.com/dominictarr/event-stream +[promise-onfulfilled]: http://promisesaplus.com/#point-26 +[promise-onrejected]: http://promisesaplus.com/#point-30 +[rx4-observable]: https://github.com/Reactive-Extensions/RxJS/blob/master/doc/api/core/observable.md +[rxjs5-observable]: http://reactivex.io/rxjs/class/es6/Observable.js~Observable.html +[rxjs5-observer-complete]: http://reactivex.io/rxjs/class/es6/MiscJSDoc.js~ObserverDoc.html#instance-method-complete +[rxjs5-observer-error]: http://reactivex.io/rxjs/class/es6/MiscJSDoc.js~ObserverDoc.html#instance-method-error diff --git a/node_modules/async-done/index.d.ts b/node_modules/async-done/index.d.ts new file mode 100644 index 0000000000..2c4ab9360e --- /dev/null +++ b/node_modules/async-done/index.d.ts @@ -0,0 +1,101 @@ +/** + * Notes about these type definitions: + * + * - Callbacks returning multiple completion values using multiple arguments are not supported by these types. + * Prefer to use Node's style by grouping your values in a single object or array. + * Support for this kind of callback is blocked by Microsoft/TypeScript#5453 + * + * - For ease of use, `asyncDone` lets you pass callback functions with a result type `T` instead of `T | undefined`. + * This matches Node's types but can lead to unsound code being typechecked. + * + * The following code typechecks but fails at runtime: + * ```typescript + * async function getString(): Promise { + * return "Hello, World!"; + * } + * + * async function evilGetString(): Promise { + * throw new Error("Hello, World!"); + * } + * + * function cb(err: Error | null, result: string): void { + * // This is unsound because `result` is `undefined` when `err` is not `null`. + * console.log(result.toLowerCase()); + * } + * + * asyncDone(getString, cb); // Prints `hello, world!` + * asyncDone(evilGetString, cb); // Runtime error: `TypeError: Cannot read property 'toLowerCase' of undefined` + * ``` + * + * Enforcing stricter callbacks would require developers to use `result?: string` and assert the existence + * of the result either by checking it directly or using the `!` assertion operator after testing for errors. + * ```typescript + * function stricterCb1(err: Error | null, result?: string): void { + * if (err !== null) { + * console.error(err); + * return; + * } + * console.log(result!.toLowerCase()); + * } + * + * function stricterCb2(err: Error | null, result?: string): void { + * if (result === undefined) { + * console.error("Undefined result. Error:); + * console.error(err); + * return; + * } + * console.log(result.toLowerCase()); + * } + * ``` + */ +import { ChildProcess } from "child_process"; +import { EventEmitter } from "events"; +import { Stream } from "stream"; + +declare namespace asyncDone { + + /** + * Represents a callback function used to signal the completion of a + * task without any result value. + */ + type VoidCallback = (err: Error | null) => void; + + /** + * Represents a callback function used to signal the completion of a + * task with a single result value. + */ + interface Callback { + (err: null, result: T): void; + + // Use `result?: T` or `result: undefined` to require the consumer to assert the existence of the result + // (even in case of success). See comment at the top of the file. + (err: Error, result?: any): void; + } + + /** + * Minimal `Observable` interface compatible with `async-done`. + * + * @see https://github.com/ReactiveX/rxjs/blob/c3c56867eaf93f302ac7cd588034c7d8712f2834/src/internal/Observable.ts#L77 + */ + interface Observable { + subscribe(next?: (value: T) => void, error?: (error: any) => void, complete?: () => void): any; + } + + /** + * Represents an async operation. + */ + export type AsyncTask = + ((done: VoidCallback) => void) + | ((done: Callback) => void) + | (() => ChildProcess | EventEmitter | Observable | PromiseLike | Stream); +} + +/** + * Takes a function to execute (`fn`) and a function to call on completion (`callback`). + * + * @param fn Function to execute. + * @param callback Function to call on completion. + */ +declare function asyncDone(fn: asyncDone.AsyncTask, callback: asyncDone.Callback): void; + +export = asyncDone; diff --git a/node_modules/async-done/index.js b/node_modules/async-done/index.js new file mode 100644 index 0000000000..e5be989387 --- /dev/null +++ b/node_modules/async-done/index.js @@ -0,0 +1,88 @@ +'use strict'; + +var domain = require('domain'); + +var eos = require('end-of-stream'); +var p = require('process-nextick-args'); +var once = require('once'); +var exhaust = require('stream-exhaust'); + +var eosConfig = { + error: false, +}; + +function rethrowAsync(err) { + process.nextTick(rethrow); + + function rethrow() { + throw err; + } +} + +function tryCatch(fn, args) { + try { + return fn.apply(null, args); + } catch (err) { + rethrowAsync(err); + } +} + +function asyncDone(fn, cb) { + cb = once(cb); + + var d = domain.create(); + d.once('error', onError); + var domainBoundFn = d.bind(fn); + + function done() { + d.removeListener('error', onError); + d.exit(); + return tryCatch(cb, arguments); + } + + function onSuccess(result) { + done(null, result); + } + + function onError(error) { + if (!error) { + error = new Error('Promise rejected without Error'); + } + done(error); + } + + function asyncRunner() { + var result = domainBoundFn(done); + + function onNext(state) { + onNext.state = state; + } + + function onCompleted() { + onSuccess(onNext.state); + } + + if (result && typeof result.on === 'function') { + // Assume node stream + d.add(result); + eos(exhaust(result), eosConfig, done); + return; + } + + if (result && typeof result.subscribe === 'function') { + // Assume RxJS observable + result.subscribe(onNext, onError, onCompleted); + return; + } + + if (result && typeof result.then === 'function') { + // Assume promise + result.then(onSuccess, onError); + return; + } + } + + p.nextTick(asyncRunner); +} + +module.exports = asyncDone; diff --git a/node_modules/async-done/package.json b/node_modules/async-done/package.json new file mode 100644 index 0000000000..369d002a04 --- /dev/null +++ b/node_modules/async-done/package.json @@ -0,0 +1,115 @@ +{ + "_from": "async-done@^1.2.0", + "_id": "async-done@1.3.2", + "_inBundle": false, + "_integrity": "sha512-uYkTP8dw2og1tu1nmza1n1CMW0qb8gWWlwqMmLb7MhBVs4BXrFziT6HXUd+/RlRA/i4H9AkofYloUbs1fwMqlw==", + "_location": "/async-done", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "async-done@^1.2.0", + "name": "async-done", + "escapedName": "async-done", + "rawSpec": "^1.2.0", + "saveSpec": null, + "fetchSpec": "^1.2.0" + }, + "_requiredBy": [ + "/async-settle", + "/bach", + "/glob-watcher" + ], + "_resolved": "https://registry.npmjs.org/async-done/-/async-done-1.3.2.tgz", + "_shasum": "5e15aa729962a4b07414f528a88cdf18e0b290a2", + "_spec": "async-done@^1.2.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/glob-watcher", + "author": { + "name": "Gulp Team", + "email": "team@gulpjs.com", + "url": "https://gulpjs.com/" + }, + "bugs": { + "url": "https://github.com/gulpjs/async-done/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "Blaine Bublitz", + "email": "blaine.bublitz@gmail.com" + }, + { + "name": "Pawel Kozlowski", + "email": "pkozlowski.opensource@gmail.com" + }, + { + "name": "Matthew Podwysocki", + "email": "matthew.podwysocki@gmail.com" + }, + { + "name": "Charles Samborski", + "email": "demurgos@demurgos.net" + } + ], + "dependencies": { + "end-of-stream": "^1.1.0", + "once": "^1.3.2", + "process-nextick-args": "^2.0.0", + "stream-exhaust": "^1.0.1" + }, + "deprecated": false, + "description": "Allows libraries to handle various caller provided asynchronous functions uniformly. Maps promises, observables, child processes and streams, and callbacks to callback style.", + "devDependencies": { + "@types/node": "^9.3.0", + "coveralls": "github:phated/node-coveralls#2.x", + "eslint": "^2.13.1", + "eslint-config-gulp": "^3.0.1", + "expect": "^1.20.2", + "mocha": "^3.0.0", + "nyc": "^10.3.2", + "pumpify": "^1.3.6", + "rxjs": "^5.5.6", + "through2": "^2.0.0", + "typescript": "^2.6.2", + "when": "^3.7.3" + }, + "engines": { + "node": ">= 0.10" + }, + "files": [ + "index.js", + "index.d.ts", + "LICENSE" + ], + "homepage": "https://github.com/gulpjs/async-done#readme", + "keywords": [ + "promises", + "callbacks", + "observables", + "streams", + "end", + "completion", + "complete", + "finish", + "done", + "async", + "error handling" + ], + "license": "MIT", + "main": "index.js", + "name": "async-done", + "repository": { + "type": "git", + "url": "git+https://github.com/gulpjs/async-done.git" + }, + "scripts": { + "azure-pipelines": "nyc mocha --async-only --reporter xunit -O output=test.xunit", + "coveralls": "nyc report --reporter=text-lcov | coveralls", + "lint": "eslint .", + "pretest": "npm run lint", + "test": "nyc mocha --async-only", + "test-types": "tsc -p test/types" + }, + "types": "index.d.ts", + "version": "1.3.2" +} diff --git a/node_modules/async-each-series/Readme.md b/node_modules/async-each-series/Readme.md new file mode 100644 index 0000000000..d49279cdc0 --- /dev/null +++ b/node_modules/async-each-series/Readme.md @@ -0,0 +1,65 @@ +# async-each-series + + Apply an async function to each Array element in series + + [![Build Status](https://travis-ci.org/jb55/async-each-series.svg)](https://travis-ci.org/jb55/async-each-series) + + [![browser support](https://ci.testling.com/jb55/async-each-series.png)](https://ci.testling.com/jb55/async-each-series) + +## Installation + + Install with [npm](https://www.npmjs.org): + + $ npm install async-each-series + + Install with [component(1)](http://component.io): + + $ component install jb55/async-each-series + +## Examples + +### Node.js + +```javascript +var each = require('async-each-series'); +each(['foo','bar','baz'], function(el, next) { + setTimeout(function () { + console.log(el); + next(); + }, Math.random() * 5000); +}, function (err) { + console.log('finished'); +}); +//=> foo +//=> bar +//=> baz +//=> finished +``` + +## API + +### eachSeries(array, iterator(elem, cb(err, elem)), finishedCb(err)) + +## License + + The MIT License (MIT) + + Copyright (c) 2014 William Casarin + + Permission is hereby granted, free of charge, to any person obtaining a copy + of this software and associated documentation files (the "Software"), to deal + in the Software without restriction, including without limitation the rights + to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included in + all copies or substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + THE SOFTWARE. diff --git a/node_modules/async-each-series/index.js b/node_modules/async-each-series/index.js new file mode 100644 index 0000000000..4d796c8457 --- /dev/null +++ b/node_modules/async-each-series/index.js @@ -0,0 +1,21 @@ +module.exports = function (arr, iterator, callback) { + callback = callback || function () {}; + if (!Array.isArray(arr) || !arr.length) { + return callback(); + } + var completed = 0; + var iterate = function () { + iterator(arr[completed], function (err) { + if (err) { + callback(err); + callback = function () {}; + } + else { + ++completed; + if (completed >= arr.length) { callback(); } + else { iterate(); } + } + }); + }; + iterate(); +}; diff --git a/node_modules/async-each-series/package.json b/node_modules/async-each-series/package.json new file mode 100644 index 0000000000..d648f36987 --- /dev/null +++ b/node_modules/async-each-series/package.json @@ -0,0 +1,76 @@ +{ + "_from": "async-each-series@0.1.1", + "_id": "async-each-series@0.1.1", + "_inBundle": false, + "_integrity": "sha1-dhfBkXQB/Yykooqtzj266Yr+tDI=", + "_location": "/async-each-series", + "_phantomChildren": {}, + "_requested": { + "type": "version", + "registry": true, + "raw": "async-each-series@0.1.1", + "name": "async-each-series", + "escapedName": "async-each-series", + "rawSpec": "0.1.1", + "saveSpec": null, + "fetchSpec": "0.1.1" + }, + "_requiredBy": [ + "/browser-sync-ui" + ], + "_resolved": "https://registry.npmjs.org/async-each-series/-/async-each-series-0.1.1.tgz", + "_shasum": "7617c1917401fd8ca4a28aadce3dbae98afeb432", + "_spec": "async-each-series@0.1.1", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/browser-sync-ui", + "author": { + "name": "jb55" + }, + "bugs": { + "url": "https://github.com/jb55/async-each-series/issues" + }, + "bundleDependencies": false, + "deprecated": false, + "description": "Apply an async function to each Array element in series.", + "devDependencies": { + "expect.js": "^0.3.1", + "mocha": "^2.0.1" + }, + "engines": { + "node": ">=0.8.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/jb55/async-each-series#readme", + "keywords": [ + "async", + "asyncEachSeries", + "eachSeries", + "each", + "asyncEach" + ], + "license": "MIT", + "main": "index.js", + "name": "async-each-series", + "repository": { + "url": "git+ssh://git@github.com/jb55/async-each-series.git" + }, + "scripts": { + "test": "mocha -R spec" + }, + "testling": { + "harness": "mocha-bdd", + "files": "test.js", + "browsers": [ + "ie/8..latest", + "chrome/28..latest", + "firefox/latest", + "safari/latest", + "opera/latest", + "iphone/6", + "ipad/6", + "android-browser/latest" + ] + }, + "version": "0.1.1" +} diff --git a/node_modules/async-each/README.md b/node_modules/async-each/README.md new file mode 100644 index 0000000000..6444d95429 --- /dev/null +++ b/node_modules/async-each/README.md @@ -0,0 +1,52 @@ +# async-each + +No-bullshit, ultra-simple, 35-lines-of-code async parallel forEach function for JavaScript. + +We don't need junky 30K async libs. Really. + +For browsers and node.js. + +## Installation +* Just include async-each before your scripts. +* `npm install async-each` if you’re using node.js. + +## Usage + +* `each(array, iterator, callback);` — `Array`, `Function`, `(optional) Function` +* `iterator(item, next)` receives current item and a callback that will mark the item as done. `next` callback receives optional `error, transformedItem` arguments. +* `callback(error, transformedArray)` optionally receives first error and transformed result `Array`. + +```javascript +var each = require('async-each'); +each(['a.js', 'b.js', 'c.js'], fs.readFile, function(error, contents) { + if (error) console.error(error); + console.log('Contents for a, b and c:', contents); +}); + +// Alternatively in browser: +asyncEach(list, fn, callback); +``` + +## License + +The MIT License (MIT) + +Copyright (c) 2016 Paul Miller [(paulmillr.com)](http://paulmillr.com) + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the “Software”), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/async-each/index.js b/node_modules/async-each/index.js new file mode 100644 index 0000000000..277217df3a --- /dev/null +++ b/node_modules/async-each/index.js @@ -0,0 +1,38 @@ +// async-each MIT license (by Paul Miller from https://paulmillr.com). +(function(globals) { + 'use strict'; + var each = function(items, next, callback) { + if (!Array.isArray(items)) throw new TypeError('each() expects array as first argument'); + if (typeof next !== 'function') throw new TypeError('each() expects function as second argument'); + if (typeof callback !== 'function') callback = Function.prototype; // no-op + + if (items.length === 0) return callback(undefined, items); + + var transformed = new Array(items.length); + var count = 0; + var returned = false; + + items.forEach(function(item, index) { + next(item, function(error, transformedItem) { + if (returned) return; + if (error) { + returned = true; + return callback(error); + } + transformed[index] = transformedItem; + count += 1; + if (count === items.length) return callback(undefined, transformed); + }); + }); + }; + + if (typeof define !== 'undefined' && define.amd) { + define([], function() { + return each; + }); // RequireJS + } else if (typeof module !== 'undefined' && module.exports) { + module.exports = each; // CommonJS + } else { + globals.asyncEach = each; // + + + + diff --git a/node_modules/async-limiter/coverage/lcov-report/async-throttle/index.js.html b/node_modules/async-limiter/coverage/lcov-report/async-throttle/index.js.html new file mode 100644 index 0000000000..adc030fda9 --- /dev/null +++ b/node_modules/async-limiter/coverage/lcov-report/async-throttle/index.js.html @@ -0,0 +1,246 @@ + + + + Code coverage report for async-throttle/index.js + + + + + + +
+

Code coverage report for async-throttle/index.js

+

+ Statements: 100% (37 / 37)      + Branches: 92.86% (13 / 14)      + Functions: 100% (7 / 7)      + Lines: 100% (37 / 37)      + Ignored: none      +

+
All files » async-throttle/ » index.js
+
+
+

+
+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68  +  +1 +7 +1 +  +  +6 +6 +6 +6 +6 +6 +  +  +1 +  +  +  +  +  +1 +3 +13 +13 +13 +  +  +  +1 +  +19 +  +  +  +1 +45 +6 +  +39 +13 +13 +13 +13 +  +  +39 +18 +6 +6 +  +  +  +  +1 +6 +6 +6 +  +  +  +1 +13 +13 +  +  +1 + 
'use strict';
+ 
+function Queue(options) {
+  if (!(this instanceof Queue)) {
+    return new Queue(options);
+  }
+ 
+  options = options || {};
+  this.concurrency = options.concurrency || Infinity;
+  this.pending = 0;
+  this.jobs = [];
+  this.cbs = [];
+  this._done = done.bind(this);
+}
+ 
+var arrayAddMethods = [
+  'push',
+  'unshift',
+  'splice'
+];
+ 
+arrayAddMethods.forEach(function(method) {
+  Queue.prototype[method] = function() {
+    var methodResult = Array.prototype[method].apply(this.jobs, arguments);
+    this._run();
+    return methodResult;
+  };
+});
+ 
+Object.defineProperty(Queue.prototype, 'length', {
+  get: function() {
+    return this.pending + this.jobs.length;
+  }
+});
+ 
+Queue.prototype._run = function() {
+  if (this.pending === this.concurrency) {
+    return;
+  }
+  if (this.jobs.length) {
+    var job = this.jobs.shift();
+    this.pending++;
+    job(this._done);
+    this._run();
+  }
+ 
+  if (this.pending === 0) {
+    while (this.cbs.length !== 0) {
+      var cb = this.cbs.pop();
+      process.nextTick(cb);
+    }
+  }
+};
+ 
+Queue.prototype.onDone = function(cb) {
+  Eif (typeof cb === 'function') {
+    this.cbs.push(cb);
+    this._run();
+  }
+};
+ 
+function done() {
+  this.pending--;
+  this._run();
+}
+ 
+module.exports = Queue;
+ 
+ +
+ + + + + + diff --git a/node_modules/async-limiter/coverage/lcov-report/base.css b/node_modules/async-limiter/coverage/lcov-report/base.css new file mode 100644 index 0000000000..a6a2f3284d --- /dev/null +++ b/node_modules/async-limiter/coverage/lcov-report/base.css @@ -0,0 +1,182 @@ +body, html { + margin:0; padding: 0; +} +body { + font-family: Helvetica Neue, Helvetica,Arial; + font-size: 10pt; +} +div.header, div.footer { + background: #eee; + padding: 1em; +} +div.header { + z-index: 100; + position: fixed; + top: 0; + border-bottom: 1px solid #666; + width: 100%; +} +div.footer { + border-top: 1px solid #666; +} +div.body { + margin-top: 10em; +} +div.meta { + font-size: 90%; + text-align: center; +} +h1, h2, h3 { + font-weight: normal; +} +h1 { + font-size: 12pt; +} +h2 { + font-size: 10pt; +} +pre { + font-family: Consolas, Menlo, Monaco, monospace; + margin: 0; + padding: 0; + line-height: 1.3; + font-size: 14px; + -moz-tab-size: 2; + -o-tab-size: 2; + tab-size: 2; +} + +div.path { font-size: 110%; } +div.path a:link, div.path a:visited { color: #000; } +table.coverage { border-collapse: collapse; margin:0; padding: 0 } + +table.coverage td { + margin: 0; + padding: 0; + color: #111; + vertical-align: top; +} +table.coverage td.line-count { + width: 50px; + text-align: right; + padding-right: 5px; +} +table.coverage td.line-coverage { + color: #777 !important; + text-align: right; + border-left: 1px solid #666; + border-right: 1px solid #666; +} + +table.coverage td.text { +} + +table.coverage td span.cline-any { + display: inline-block; + padding: 0 5px; + width: 40px; +} +table.coverage td span.cline-neutral { + background: #eee; +} +table.coverage td span.cline-yes { + background: #b5d592; + color: #999; +} +table.coverage td span.cline-no { + background: #fc8c84; +} + +.cstat-yes { color: #111; } +.cstat-no { background: #fc8c84; color: #111; } +.fstat-no { background: #ffc520; color: #111 !important; } +.cbranch-no { background: yellow !important; color: #111; } + +.cstat-skip { background: #ddd; color: #111; } +.fstat-skip { background: #ddd; color: #111 !important; } +.cbranch-skip { background: #ddd !important; color: #111; } + +.missing-if-branch { + display: inline-block; + margin-right: 10px; + position: relative; + padding: 0 4px; + background: black; + color: yellow; +} + +.skip-if-branch { + display: none; + margin-right: 10px; + position: relative; + padding: 0 4px; + background: #ccc; + color: white; +} + +.missing-if-branch .typ, .skip-if-branch .typ { + color: inherit !important; +} + +.entity, .metric { font-weight: bold; } +.metric { display: inline-block; border: 1px solid #333; padding: 0.3em; background: white; } +.metric small { font-size: 80%; font-weight: normal; color: #666; } + +div.coverage-summary table { border-collapse: collapse; margin: 3em; font-size: 110%; } +div.coverage-summary td, div.coverage-summary table th { margin: 0; padding: 0.25em 1em; border-top: 1px solid #666; border-bottom: 1px solid #666; } +div.coverage-summary th { text-align: left; border: 1px solid #666; background: #eee; font-weight: normal; } +div.coverage-summary th.file { border-right: none !important; } +div.coverage-summary th.pic { border-left: none !important; text-align: right; } +div.coverage-summary th.pct { border-right: none !important; } +div.coverage-summary th.abs { border-left: none !important; text-align: right; } +div.coverage-summary td.pct { text-align: right; border-left: 1px solid #666; } +div.coverage-summary td.abs { text-align: right; font-size: 90%; color: #444; border-right: 1px solid #666; } +div.coverage-summary td.file { border-left: 1px solid #666; white-space: nowrap; } +div.coverage-summary td.pic { min-width: 120px !important; } +div.coverage-summary a:link { text-decoration: none; color: #000; } +div.coverage-summary a:visited { text-decoration: none; color: #777; } +div.coverage-summary a:hover { text-decoration: underline; } +div.coverage-summary tfoot td { border-top: 1px solid #666; } + +div.coverage-summary .sorter { + height: 10px; + width: 7px; + display: inline-block; + margin-left: 0.5em; + background: url(sort-arrow-sprite.png) no-repeat scroll 0 0 transparent; +} +div.coverage-summary .sorted .sorter { + background-position: 0 -20px; +} +div.coverage-summary .sorted-desc .sorter { + background-position: 0 -10px; +} + +.high { background: #b5d592 !important; } +.medium { background: #ffe87c !important; } +.low { background: #fc8c84 !important; } + +span.cover-fill, span.cover-empty { + display:inline-block; + border:1px solid #444; + background: white; + height: 12px; +} +span.cover-fill { + background: #ccc; + border-right: 1px solid #444; +} +span.cover-empty { + background: white; + border-left: none; +} +span.cover-full { + border-right: none !important; +} +pre.prettyprint { + border: none !important; + padding: 0 !important; + margin: 0 !important; +} +.com { color: #999 !important; } +.ignore-none { color: #999; font-weight: normal; } diff --git a/node_modules/async-limiter/coverage/lcov-report/index.html b/node_modules/async-limiter/coverage/lcov-report/index.html new file mode 100644 index 0000000000..782a1cff11 --- /dev/null +++ b/node_modules/async-limiter/coverage/lcov-report/index.html @@ -0,0 +1,73 @@ + + + + Code coverage report for All files + + + + + + +
+

Code coverage report for All files

+

+ Statements: 100% (37 / 37)      + Branches: 92.86% (13 / 14)      + Functions: 100% (7 / 7)      + Lines: 100% (37 / 37)      + Ignored: none      +

+
+
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
async-throttle/100%(37 / 37)92.86%(13 / 14)100%(7 / 7)100%(37 / 37)
+
+
+ + + + + + diff --git a/node_modules/async-limiter/coverage/lcov-report/prettify.css b/node_modules/async-limiter/coverage/lcov-report/prettify.css new file mode 100644 index 0000000000..b317a7cda3 --- /dev/null +++ b/node_modules/async-limiter/coverage/lcov-report/prettify.css @@ -0,0 +1 @@ +.pln{color:#000}@media screen{.str{color:#080}.kwd{color:#008}.com{color:#800}.typ{color:#606}.lit{color:#066}.pun,.opn,.clo{color:#660}.tag{color:#008}.atn{color:#606}.atv{color:#080}.dec,.var{color:#606}.fun{color:red}}@media print,projection{.str{color:#060}.kwd{color:#006;font-weight:bold}.com{color:#600;font-style:italic}.typ{color:#404;font-weight:bold}.lit{color:#044}.pun,.opn,.clo{color:#440}.tag{color:#006;font-weight:bold}.atn{color:#404}.atv{color:#060}}pre.prettyprint{padding:2px;border:1px solid #888}ol.linenums{margin-top:0;margin-bottom:0}li.L0,li.L1,li.L2,li.L3,li.L5,li.L6,li.L7,li.L8{list-style-type:none}li.L1,li.L3,li.L5,li.L7,li.L9{background:#eee} diff --git a/node_modules/async-limiter/coverage/lcov-report/prettify.js b/node_modules/async-limiter/coverage/lcov-report/prettify.js new file mode 100644 index 0000000000..ef51e03866 --- /dev/null +++ b/node_modules/async-limiter/coverage/lcov-report/prettify.js @@ -0,0 +1 @@ +window.PR_SHOULD_USE_CONTINUATION=true;(function(){var h=["break,continue,do,else,for,if,return,while"];var u=[h,"auto,case,char,const,default,double,enum,extern,float,goto,int,long,register,short,signed,sizeof,static,struct,switch,typedef,union,unsigned,void,volatile"];var p=[u,"catch,class,delete,false,import,new,operator,private,protected,public,this,throw,true,try,typeof"];var l=[p,"alignof,align_union,asm,axiom,bool,concept,concept_map,const_cast,constexpr,decltype,dynamic_cast,explicit,export,friend,inline,late_check,mutable,namespace,nullptr,reinterpret_cast,static_assert,static_cast,template,typeid,typename,using,virtual,where"];var x=[p,"abstract,boolean,byte,extends,final,finally,implements,import,instanceof,null,native,package,strictfp,super,synchronized,throws,transient"];var R=[x,"as,base,by,checked,decimal,delegate,descending,dynamic,event,fixed,foreach,from,group,implicit,in,interface,internal,into,is,lock,object,out,override,orderby,params,partial,readonly,ref,sbyte,sealed,stackalloc,string,select,uint,ulong,unchecked,unsafe,ushort,var"];var r="all,and,by,catch,class,else,extends,false,finally,for,if,in,is,isnt,loop,new,no,not,null,of,off,on,or,return,super,then,true,try,unless,until,when,while,yes";var w=[p,"debugger,eval,export,function,get,null,set,undefined,var,with,Infinity,NaN"];var s="caller,delete,die,do,dump,elsif,eval,exit,foreach,for,goto,if,import,last,local,my,next,no,our,print,package,redo,require,sub,undef,unless,until,use,wantarray,while,BEGIN,END";var I=[h,"and,as,assert,class,def,del,elif,except,exec,finally,from,global,import,in,is,lambda,nonlocal,not,or,pass,print,raise,try,with,yield,False,True,None"];var f=[h,"alias,and,begin,case,class,def,defined,elsif,end,ensure,false,in,module,next,nil,not,or,redo,rescue,retry,self,super,then,true,undef,unless,until,when,yield,BEGIN,END"];var H=[h,"case,done,elif,esac,eval,fi,function,in,local,set,then,until"];var A=[l,R,w,s+I,f,H];var e=/^(DIR|FILE|vector|(de|priority_)?queue|list|stack|(const_)?iterator|(multi)?(set|map)|bitset|u?(int|float)\d*)/;var C="str";var z="kwd";var j="com";var O="typ";var G="lit";var L="pun";var F="pln";var m="tag";var E="dec";var J="src";var P="atn";var n="atv";var N="nocode";var M="(?:^^\\.?|[+-]|\\!|\\!=|\\!==|\\#|\\%|\\%=|&|&&|&&=|&=|\\(|\\*|\\*=|\\+=|\\,|\\-=|\\->|\\/|\\/=|:|::|\\;|<|<<|<<=|<=|=|==|===|>|>=|>>|>>=|>>>|>>>=|\\?|\\@|\\[|\\^|\\^=|\\^\\^|\\^\\^=|\\{|\\||\\|=|\\|\\||\\|\\|=|\\~|break|case|continue|delete|do|else|finally|instanceof|return|throw|try|typeof)\\s*";function k(Z){var ad=0;var S=false;var ac=false;for(var V=0,U=Z.length;V122)){if(!(al<65||ag>90)){af.push([Math.max(65,ag)|32,Math.min(al,90)|32])}if(!(al<97||ag>122)){af.push([Math.max(97,ag)&~32,Math.min(al,122)&~32])}}}}af.sort(function(av,au){return(av[0]-au[0])||(au[1]-av[1])});var ai=[];var ap=[NaN,NaN];for(var ar=0;arat[0]){if(at[1]+1>at[0]){an.push("-")}an.push(T(at[1]))}}an.push("]");return an.join("")}function W(al){var aj=al.source.match(new RegExp("(?:\\[(?:[^\\x5C\\x5D]|\\\\[\\s\\S])*\\]|\\\\u[A-Fa-f0-9]{4}|\\\\x[A-Fa-f0-9]{2}|\\\\[0-9]+|\\\\[^ux0-9]|\\(\\?[:!=]|[\\(\\)\\^]|[^\\x5B\\x5C\\(\\)\\^]+)","g"));var ah=aj.length;var an=[];for(var ak=0,am=0;ak=2&&ai==="["){aj[ak]=X(ag)}else{if(ai!=="\\"){aj[ak]=ag.replace(/[a-zA-Z]/g,function(ao){var ap=ao.charCodeAt(0);return"["+String.fromCharCode(ap&~32,ap|32)+"]"})}}}}return aj.join("")}var aa=[];for(var V=0,U=Z.length;V=0;){S[ac.charAt(ae)]=Y}}var af=Y[1];var aa=""+af;if(!ag.hasOwnProperty(aa)){ah.push(af);ag[aa]=null}}ah.push(/[\0-\uffff]/);V=k(ah)})();var X=T.length;var W=function(ah){var Z=ah.sourceCode,Y=ah.basePos;var ad=[Y,F];var af=0;var an=Z.match(V)||[];var aj={};for(var ae=0,aq=an.length;ae=5&&"lang-"===ap.substring(0,5);if(am&&!(ai&&typeof ai[1]==="string")){am=false;ap=J}if(!am){aj[ag]=ap}}var ab=af;af+=ag.length;if(!am){ad.push(Y+ab,ap)}else{var al=ai[1];var ak=ag.indexOf(al);var ac=ak+al.length;if(ai[2]){ac=ag.length-ai[2].length;ak=ac-al.length}var ar=ap.substring(5);B(Y+ab,ag.substring(0,ak),W,ad);B(Y+ab+ak,al,q(ar,al),ad);B(Y+ab+ac,ag.substring(ac),W,ad)}}ah.decorations=ad};return W}function i(T){var W=[],S=[];if(T.tripleQuotedStrings){W.push([C,/^(?:\'\'\'(?:[^\'\\]|\\[\s\S]|\'{1,2}(?=[^\']))*(?:\'\'\'|$)|\"\"\"(?:[^\"\\]|\\[\s\S]|\"{1,2}(?=[^\"]))*(?:\"\"\"|$)|\'(?:[^\\\']|\\[\s\S])*(?:\'|$)|\"(?:[^\\\"]|\\[\s\S])*(?:\"|$))/,null,"'\""])}else{if(T.multiLineStrings){W.push([C,/^(?:\'(?:[^\\\']|\\[\s\S])*(?:\'|$)|\"(?:[^\\\"]|\\[\s\S])*(?:\"|$)|\`(?:[^\\\`]|\\[\s\S])*(?:\`|$))/,null,"'\"`"])}else{W.push([C,/^(?:\'(?:[^\\\'\r\n]|\\.)*(?:\'|$)|\"(?:[^\\\"\r\n]|\\.)*(?:\"|$))/,null,"\"'"])}}if(T.verbatimStrings){S.push([C,/^@\"(?:[^\"]|\"\")*(?:\"|$)/,null])}var Y=T.hashComments;if(Y){if(T.cStyleComments){if(Y>1){W.push([j,/^#(?:##(?:[^#]|#(?!##))*(?:###|$)|.*)/,null,"#"])}else{W.push([j,/^#(?:(?:define|elif|else|endif|error|ifdef|include|ifndef|line|pragma|undef|warning)\b|[^\r\n]*)/,null,"#"])}S.push([C,/^<(?:(?:(?:\.\.\/)*|\/?)(?:[\w-]+(?:\/[\w-]+)+)?[\w-]+\.h|[a-z]\w*)>/,null])}else{W.push([j,/^#[^\r\n]*/,null,"#"])}}if(T.cStyleComments){S.push([j,/^\/\/[^\r\n]*/,null]);S.push([j,/^\/\*[\s\S]*?(?:\*\/|$)/,null])}if(T.regexLiterals){var X=("/(?=[^/*])(?:[^/\\x5B\\x5C]|\\x5C[\\s\\S]|\\x5B(?:[^\\x5C\\x5D]|\\x5C[\\s\\S])*(?:\\x5D|$))+/");S.push(["lang-regex",new RegExp("^"+M+"("+X+")")])}var V=T.types;if(V){S.push([O,V])}var U=(""+T.keywords).replace(/^ | $/g,"");if(U.length){S.push([z,new RegExp("^(?:"+U.replace(/[\s,]+/g,"|")+")\\b"),null])}W.push([F,/^\s+/,null," \r\n\t\xA0"]);S.push([G,/^@[a-z_$][a-z_$@0-9]*/i,null],[O,/^(?:[@_]?[A-Z]+[a-z][A-Za-z_$@0-9]*|\w+_t\b)/,null],[F,/^[a-z_$][a-z_$@0-9]*/i,null],[G,new RegExp("^(?:0x[a-f0-9]+|(?:\\d(?:_\\d+)*\\d*(?:\\.\\d*)?|\\.\\d\\+)(?:e[+\\-]?\\d+)?)[a-z]*","i"),null,"0123456789"],[F,/^\\[\s\S]?/,null],[L,/^.[^\s\w\.$@\'\"\`\/\#\\]*/,null]);return g(W,S)}var K=i({keywords:A,hashComments:true,cStyleComments:true,multiLineStrings:true,regexLiterals:true});function Q(V,ag){var U=/(?:^|\s)nocode(?:\s|$)/;var ab=/\r\n?|\n/;var ac=V.ownerDocument;var S;if(V.currentStyle){S=V.currentStyle.whiteSpace}else{if(window.getComputedStyle){S=ac.defaultView.getComputedStyle(V,null).getPropertyValue("white-space")}}var Z=S&&"pre"===S.substring(0,3);var af=ac.createElement("LI");while(V.firstChild){af.appendChild(V.firstChild)}var W=[af];function ae(al){switch(al.nodeType){case 1:if(U.test(al.className)){break}if("BR"===al.nodeName){ad(al);if(al.parentNode){al.parentNode.removeChild(al)}}else{for(var an=al.firstChild;an;an=an.nextSibling){ae(an)}}break;case 3:case 4:if(Z){var am=al.nodeValue;var aj=am.match(ab);if(aj){var ai=am.substring(0,aj.index);al.nodeValue=ai;var ah=am.substring(aj.index+aj[0].length);if(ah){var ak=al.parentNode;ak.insertBefore(ac.createTextNode(ah),al.nextSibling)}ad(al);if(!ai){al.parentNode.removeChild(al)}}}break}}function ad(ak){while(!ak.nextSibling){ak=ak.parentNode;if(!ak){return}}function ai(al,ar){var aq=ar?al.cloneNode(false):al;var ao=al.parentNode;if(ao){var ap=ai(ao,1);var an=al.nextSibling;ap.appendChild(aq);for(var am=an;am;am=an){an=am.nextSibling;ap.appendChild(am)}}return aq}var ah=ai(ak.nextSibling,0);for(var aj;(aj=ah.parentNode)&&aj.nodeType===1;){ah=aj}W.push(ah)}for(var Y=0;Y=S){ah+=2}if(V>=ap){Z+=2}}}var t={};function c(U,V){for(var S=V.length;--S>=0;){var T=V[S];if(!t.hasOwnProperty(T)){t[T]=U}else{if(window.console){console.warn("cannot override language handler %s",T)}}}}function q(T,S){if(!(T&&t.hasOwnProperty(T))){T=/^\s*]*(?:>|$)/],[j,/^<\!--[\s\S]*?(?:-\->|$)/],["lang-",/^<\?([\s\S]+?)(?:\?>|$)/],["lang-",/^<%([\s\S]+?)(?:%>|$)/],[L,/^(?:<[%?]|[%?]>)/],["lang-",/^]*>([\s\S]+?)<\/xmp\b[^>]*>/i],["lang-js",/^]*>([\s\S]*?)(<\/script\b[^>]*>)/i],["lang-css",/^]*>([\s\S]*?)(<\/style\b[^>]*>)/i],["lang-in.tag",/^(<\/?[a-z][^<>]*>)/i]]),["default-markup","htm","html","mxml","xhtml","xml","xsl"]);c(g([[F,/^[\s]+/,null," \t\r\n"],[n,/^(?:\"[^\"]*\"?|\'[^\']*\'?)/,null,"\"'"]],[[m,/^^<\/?[a-z](?:[\w.:-]*\w)?|\/?>$/i],[P,/^(?!style[\s=]|on)[a-z](?:[\w:-]*\w)?/i],["lang-uq.val",/^=\s*([^>\'\"\s]*(?:[^>\'\"\s\/]|\/(?=\s)))/],[L,/^[=<>\/]+/],["lang-js",/^on\w+\s*=\s*\"([^\"]+)\"/i],["lang-js",/^on\w+\s*=\s*\'([^\']+)\'/i],["lang-js",/^on\w+\s*=\s*([^\"\'>\s]+)/i],["lang-css",/^style\s*=\s*\"([^\"]+)\"/i],["lang-css",/^style\s*=\s*\'([^\']+)\'/i],["lang-css",/^style\s*=\s*([^\"\'>\s]+)/i]]),["in.tag"]);c(g([],[[n,/^[\s\S]+/]]),["uq.val"]);c(i({keywords:l,hashComments:true,cStyleComments:true,types:e}),["c","cc","cpp","cxx","cyc","m"]);c(i({keywords:"null,true,false"}),["json"]);c(i({keywords:R,hashComments:true,cStyleComments:true,verbatimStrings:true,types:e}),["cs"]);c(i({keywords:x,cStyleComments:true}),["java"]);c(i({keywords:H,hashComments:true,multiLineStrings:true}),["bsh","csh","sh"]);c(i({keywords:I,hashComments:true,multiLineStrings:true,tripleQuotedStrings:true}),["cv","py"]);c(i({keywords:s,hashComments:true,multiLineStrings:true,regexLiterals:true}),["perl","pl","pm"]);c(i({keywords:f,hashComments:true,multiLineStrings:true,regexLiterals:true}),["rb"]);c(i({keywords:w,cStyleComments:true,regexLiterals:true}),["js"]);c(i({keywords:r,hashComments:3,cStyleComments:true,multilineStrings:true,tripleQuotedStrings:true,regexLiterals:true}),["coffee"]);c(g([],[[C,/^[\s\S]+/]]),["regex"]);function d(V){var U=V.langExtension;try{var S=a(V.sourceNode);var T=S.sourceCode;V.sourceCode=T;V.spans=S.spans;V.basePos=0;q(U,T)(V);D(V)}catch(W){if("console" in window){console.log(W&&W.stack?W.stack:W)}}}function y(W,V,U){var S=document.createElement("PRE");S.innerHTML=W;if(U){Q(S,U)}var T={langExtension:V,numberLines:U,sourceNode:S};d(T);return S.innerHTML}function b(ad){function Y(af){return document.getElementsByTagName(af)}var ac=[Y("pre"),Y("code"),Y("xmp")];var T=[];for(var aa=0;aa=0){var ah=ai.match(ab);var am;if(!ah&&(am=o(aj))&&"CODE"===am.tagName){ah=am.className.match(ab)}if(ah){ah=ah[1]}var al=false;for(var ak=aj.parentNode;ak;ak=ak.parentNode){if((ak.tagName==="pre"||ak.tagName==="code"||ak.tagName==="xmp")&&ak.className&&ak.className.indexOf("prettyprint")>=0){al=true;break}}if(!al){var af=aj.className.match(/\blinenums\b(?::(\d+))?/);af=af?af[1]&&af[1].length?+af[1]:true:false;if(af){Q(aj,af)}S={langExtension:ah,sourceNode:aj,numberLines:af};d(S)}}}if(X]*(?:>|$)/],[PR.PR_COMMENT,/^<\!--[\s\S]*?(?:-\->|$)/],[PR.PR_PUNCTUATION,/^(?:<[%?]|[%?]>)/],["lang-",/^<\?([\s\S]+?)(?:\?>|$)/],["lang-",/^<%([\s\S]+?)(?:%>|$)/],["lang-",/^]*>([\s\S]+?)<\/xmp\b[^>]*>/i],["lang-handlebars",/^]*type\s*=\s*['"]?text\/x-handlebars-template['"]?\b[^>]*>([\s\S]*?)(<\/script\b[^>]*>)/i],["lang-js",/^]*>([\s\S]*?)(<\/script\b[^>]*>)/i],["lang-css",/^]*>([\s\S]*?)(<\/style\b[^>]*>)/i],["lang-in.tag",/^(<\/?[a-z][^<>]*>)/i],[PR.PR_DECLARATION,/^{{[#^>/]?\s*[\w.][^}]*}}/],[PR.PR_DECLARATION,/^{{&?\s*[\w.][^}]*}}/],[PR.PR_DECLARATION,/^{{{>?\s*[\w.][^}]*}}}/],[PR.PR_COMMENT,/^{{![^}]*}}/]]),["handlebars","hbs"]);PR.registerLangHandler(PR.createSimpleLexer([[PR.PR_PLAIN,/^[ \t\r\n\f]+/,null," \t\r\n\f"]],[[PR.PR_STRING,/^\"(?:[^\n\r\f\\\"]|\\(?:\r\n?|\n|\f)|\\[\s\S])*\"/,null],[PR.PR_STRING,/^\'(?:[^\n\r\f\\\']|\\(?:\r\n?|\n|\f)|\\[\s\S])*\'/,null],["lang-css-str",/^url\(([^\)\"\']*)\)/i],[PR.PR_KEYWORD,/^(?:url|rgb|\!important|@import|@page|@media|@charset|inherit)(?=[^\-\w]|$)/i,null],["lang-css-kw",/^(-?(?:[_a-z]|(?:\\[0-9a-f]+ ?))(?:[_a-z0-9\-]|\\(?:\\[0-9a-f]+ ?))*)\s*:/i],[PR.PR_COMMENT,/^\/\*[^*]*\*+(?:[^\/*][^*]*\*+)*\//],[PR.PR_COMMENT,/^(?:)/],[PR.PR_LITERAL,/^(?:\d+|\d*\.\d+)(?:%|[a-z]+)?/i],[PR.PR_LITERAL,/^#(?:[0-9a-f]{3}){1,2}/i],[PR.PR_PLAIN,/^-?(?:[_a-z]|(?:\\[\da-f]+ ?))(?:[_a-z\d\-]|\\(?:\\[\da-f]+ ?))*/i],[PR.PR_PUNCTUATION,/^[^\s\w\'\"]+/]]),["css"]);PR.registerLangHandler(PR.createSimpleLexer([],[[PR.PR_KEYWORD,/^-?(?:[_a-z]|(?:\\[\da-f]+ ?))(?:[_a-z\d\-]|\\(?:\\[\da-f]+ ?))*/i]]),["css-kw"]);PR.registerLangHandler(PR.createSimpleLexer([],[[PR.PR_STRING,/^[^\)\"\']+/]]),["css-str"]); diff --git a/node_modules/async-limiter/coverage/lcov-report/sort-arrow-sprite.png b/node_modules/async-limiter/coverage/lcov-report/sort-arrow-sprite.png new file mode 100644 index 0000000000..03f704a609 Binary files /dev/null and b/node_modules/async-limiter/coverage/lcov-report/sort-arrow-sprite.png differ diff --git a/node_modules/async-limiter/coverage/lcov-report/sorter.js b/node_modules/async-limiter/coverage/lcov-report/sorter.js new file mode 100644 index 0000000000..6afb736c39 --- /dev/null +++ b/node_modules/async-limiter/coverage/lcov-report/sorter.js @@ -0,0 +1,156 @@ +var addSorting = (function () { + "use strict"; + var cols, + currentSort = { + index: 0, + desc: false + }; + + // returns the summary table element + function getTable() { return document.querySelector('.coverage-summary table'); } + // returns the thead element of the summary table + function getTableHeader() { return getTable().querySelector('thead tr'); } + // returns the tbody element of the summary table + function getTableBody() { return getTable().querySelector('tbody'); } + // returns the th element for nth column + function getNthColumn(n) { return getTableHeader().querySelectorAll('th')[n]; } + + // loads all columns + function loadColumns() { + var colNodes = getTableHeader().querySelectorAll('th'), + colNode, + cols = [], + col, + i; + + for (i = 0; i < colNodes.length; i += 1) { + colNode = colNodes[i]; + col = { + key: colNode.getAttribute('data-col'), + sortable: !colNode.getAttribute('data-nosort'), + type: colNode.getAttribute('data-type') || 'string' + }; + cols.push(col); + if (col.sortable) { + col.defaultDescSort = col.type === 'number'; + colNode.innerHTML = colNode.innerHTML + ''; + } + } + return cols; + } + // attaches a data attribute to every tr element with an object + // of data values keyed by column name + function loadRowData(tableRow) { + var tableCols = tableRow.querySelectorAll('td'), + colNode, + col, + data = {}, + i, + val; + for (i = 0; i < tableCols.length; i += 1) { + colNode = tableCols[i]; + col = cols[i]; + val = colNode.getAttribute('data-value'); + if (col.type === 'number') { + val = Number(val); + } + data[col.key] = val; + } + return data; + } + // loads all row data + function loadData() { + var rows = getTableBody().querySelectorAll('tr'), + i; + + for (i = 0; i < rows.length; i += 1) { + rows[i].data = loadRowData(rows[i]); + } + } + // sorts the table using the data for the ith column + function sortByIndex(index, desc) { + var key = cols[index].key, + sorter = function (a, b) { + a = a.data[key]; + b = b.data[key]; + return a < b ? -1 : a > b ? 1 : 0; + }, + finalSorter = sorter, + tableBody = document.querySelector('.coverage-summary tbody'), + rowNodes = tableBody.querySelectorAll('tr'), + rows = [], + i; + + if (desc) { + finalSorter = function (a, b) { + return -1 * sorter(a, b); + }; + } + + for (i = 0; i < rowNodes.length; i += 1) { + rows.push(rowNodes[i]); + tableBody.removeChild(rowNodes[i]); + } + + rows.sort(finalSorter); + + for (i = 0; i < rows.length; i += 1) { + tableBody.appendChild(rows[i]); + } + } + // removes sort indicators for current column being sorted + function removeSortIndicators() { + var col = getNthColumn(currentSort.index), + cls = col.className; + + cls = cls.replace(/ sorted$/, '').replace(/ sorted-desc$/, ''); + col.className = cls; + } + // adds sort indicators for current column being sorted + function addSortIndicators() { + getNthColumn(currentSort.index).className += currentSort.desc ? ' sorted-desc' : ' sorted'; + } + // adds event listeners for all sorter widgets + function enableUI() { + var i, + el, + ithSorter = function ithSorter(i) { + var col = cols[i]; + + return function () { + var desc = col.defaultDescSort; + + if (currentSort.index === i) { + desc = !currentSort.desc; + } + sortByIndex(i, desc); + removeSortIndicators(); + currentSort.index = i; + currentSort.desc = desc; + addSortIndicators(); + }; + }; + for (i =0 ; i < cols.length; i += 1) { + if (cols[i].sortable) { + el = getNthColumn(i).querySelector('.sorter'); + if (el.addEventListener) { + el.addEventListener('click', ithSorter(i)); + } else { + el.attachEvent('onclick', ithSorter(i)); + } + } + } + } + // adds sorting functionality to the UI + return function () { + if (!getTable()) { + return; + } + cols = loadColumns(); + loadData(cols); + addSortIndicators(); + enableUI(); + }; +})(); + +window.addEventListener('load', addSorting); diff --git a/node_modules/async-limiter/coverage/lcov.info b/node_modules/async-limiter/coverage/lcov.info new file mode 100644 index 0000000000..fbf36aab03 --- /dev/null +++ b/node_modules/async-limiter/coverage/lcov.info @@ -0,0 +1,74 @@ +TN: +SF:/Users/samuelreed/git/forks/async-throttle/index.js +FN:3,Queue +FN:22,(anonymous_2) +FN:23,(anonymous_3) +FN:31,(anonymous_4) +FN:36,(anonymous_5) +FN:55,(anonymous_6) +FN:62,done +FNF:7 +FNH:7 +FNDA:7,Queue +FNDA:3,(anonymous_2) +FNDA:13,(anonymous_3) +FNDA:19,(anonymous_4) +FNDA:45,(anonymous_5) +FNDA:6,(anonymous_6) +FNDA:13,done +DA:3,1 +DA:4,7 +DA:5,1 +DA:8,6 +DA:9,6 +DA:10,6 +DA:11,6 +DA:12,6 +DA:13,6 +DA:16,1 +DA:22,1 +DA:23,3 +DA:24,13 +DA:25,13 +DA:26,13 +DA:30,1 +DA:32,19 +DA:36,1 +DA:37,45 +DA:38,6 +DA:40,39 +DA:41,13 +DA:42,13 +DA:43,13 +DA:44,13 +DA:47,39 +DA:48,18 +DA:49,6 +DA:50,6 +DA:55,1 +DA:56,6 +DA:57,6 +DA:58,6 +DA:62,1 +DA:63,13 +DA:64,13 +DA:67,1 +LF:37 +LH:37 +BRDA:4,1,0,1 +BRDA:4,1,1,6 +BRDA:8,2,0,6 +BRDA:8,2,1,5 +BRDA:9,3,0,6 +BRDA:9,3,1,5 +BRDA:37,4,0,6 +BRDA:37,4,1,39 +BRDA:40,5,0,13 +BRDA:40,5,1,26 +BRDA:47,6,0,18 +BRDA:47,6,1,21 +BRDA:56,7,0,6 +BRDA:56,7,1,0 +BRF:14 +BRH:13 +end_of_record diff --git a/node_modules/async-limiter/index.js b/node_modules/async-limiter/index.js new file mode 100644 index 0000000000..c9bd2f9778 --- /dev/null +++ b/node_modules/async-limiter/index.js @@ -0,0 +1,67 @@ +'use strict'; + +function Queue(options) { + if (!(this instanceof Queue)) { + return new Queue(options); + } + + options = options || {}; + this.concurrency = options.concurrency || Infinity; + this.pending = 0; + this.jobs = []; + this.cbs = []; + this._done = done.bind(this); +} + +var arrayAddMethods = [ + 'push', + 'unshift', + 'splice' +]; + +arrayAddMethods.forEach(function(method) { + Queue.prototype[method] = function() { + var methodResult = Array.prototype[method].apply(this.jobs, arguments); + this._run(); + return methodResult; + }; +}); + +Object.defineProperty(Queue.prototype, 'length', { + get: function() { + return this.pending + this.jobs.length; + } +}); + +Queue.prototype._run = function() { + if (this.pending === this.concurrency) { + return; + } + if (this.jobs.length) { + var job = this.jobs.shift(); + this.pending++; + job(this._done); + this._run(); + } + + if (this.pending === 0) { + while (this.cbs.length !== 0) { + var cb = this.cbs.pop(); + process.nextTick(cb); + } + } +}; + +Queue.prototype.onDone = function(cb) { + if (typeof cb === 'function') { + this.cbs.push(cb); + this._run(); + } +}; + +function done() { + this.pending--; + this._run(); +} + +module.exports = Queue; diff --git a/node_modules/async-limiter/package.json b/node_modules/async-limiter/package.json new file mode 100644 index 0000000000..aed7d6012f --- /dev/null +++ b/node_modules/async-limiter/package.json @@ -0,0 +1,71 @@ +{ + "_from": "async-limiter@~1.0.0", + "_id": "async-limiter@1.0.0", + "_inBundle": false, + "_integrity": "sha512-jp/uFnooOiO+L211eZOoSyzpOITMXx1rBITauYykG3BRYPu8h0UcxsPNB04RR5vo4Tyz3+ay17tR6JVf9qzYWg==", + "_location": "/async-limiter", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "async-limiter@~1.0.0", + "name": "async-limiter", + "escapedName": "async-limiter", + "rawSpec": "~1.0.0", + "saveSpec": null, + "fetchSpec": "~1.0.0" + }, + "_requiredBy": [ + "/engine.io/ws", + "/socket.io/ws", + "/ws" + ], + "_resolved": "https://registry.npmjs.org/async-limiter/-/async-limiter-1.0.0.tgz", + "_shasum": "78faed8c3d074ab81f22b4e985d79e8738f720f8", + "_spec": "async-limiter@~1.0.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/ws", + "author": { + "name": "Samuel Reed" + }, + "bugs": { + "url": "https://github.com/strml/async-limiter/issues" + }, + "bundleDependencies": false, + "dependencies": {}, + "deprecated": false, + "description": "asynchronous function queue with adjustable concurrency", + "devDependencies": { + "coveralls": "^2.11.2", + "eslint": "^4.6.1", + "eslint-plugin-mocha": "^4.11.0", + "intelli-espower-loader": "^1.0.1", + "istanbul": "^0.3.2", + "mocha": "^3.5.2", + "power-assert": "^1.4.4" + }, + "homepage": "https://github.com/strml/async-limiter#readme", + "keywords": [ + "throttle", + "async", + "limiter", + "asynchronous", + "job", + "task", + "concurrency", + "concurrent" + ], + "license": "MIT", + "name": "async-limiter", + "repository": { + "type": "git", + "url": "git+https://github.com/strml/async-limiter.git" + }, + "scripts": { + "coverage": "istanbul cover ./node_modules/mocha/bin/_mocha --report lcovonly -- -R spec && cat ./coverage/lcov.info | coveralls", + "example": "node example", + "lint": "eslint .", + "test": "mocha --R intelli-espower-loader test/", + "travis": "npm run lint && npm run coverage" + }, + "version": "1.0.0" +} diff --git a/node_modules/async-limiter/readme.md b/node_modules/async-limiter/readme.md new file mode 100644 index 0000000000..dcf4932f9a --- /dev/null +++ b/node_modules/async-limiter/readme.md @@ -0,0 +1,132 @@ +# Async-Limiter + +A module for limiting concurrent asynchronous actions in flight. Forked from [queue](https://github.com/jessetane/queue). + +[![npm](http://img.shields.io/npm/v/async-limiter.svg?style=flat-square)](http://www.npmjs.org/async-limiter) +[![tests](https://img.shields.io/travis/STRML/async-limiter.svg?style=flat-square&branch=master)](https://travis-ci.org/STRML/async-limiter) +[![coverage](https://img.shields.io/coveralls/STRML/async-limiter.svg?style=flat-square&branch=master)](https://coveralls.io/r/STRML/async-limiter) + +This module exports a class `Limiter` that implements some of the `Array` API. +Pass async functions (ones that accept a callback or return a promise) to an instance's additive array methods. + +## Motivation + +Certain functions, like `zlib`, have [undesirable behavior](https://github.com/nodejs/node/issues/8871#issuecomment-250915913) when +run at infinite concurrency. + +In this case, it is actually faster, and takes far less memory, to limit concurrency. + +This module should do the absolute minimum work necessary to queue up functions. PRs are welcome that would +make this module faster or lighter, but new functionality is not desired. + +Style should confirm to nodejs/node style. + +## Example + +``` javascript +var Limiter = require('async-limiter') + +var t = new Limiter({concurrency: 2}); +var results = [] + +// add jobs using the familiar Array API +t.push(function (cb) { + results.push('two') + cb() +}) + +t.push( + function (cb) { + results.push('four') + cb() + }, + function (cb) { + results.push('five') + cb() + } +) + +t.unshift(function (cb) { + results.push('one') + cb() +}) + +t.splice(2, 0, function (cb) { + results.push('three') + cb() +}) + +// Jobs run automatically. If you want a callback when all are done, +// call 'onDone()'. +t.onDone(function () { + console.log('all done:', results) +}) +``` + +## Zlib Example + +```js +const zlib = require('zlib'); +const Limiter = require('async-limiter'); + +const message = {some: "data"}; +const payload = new Buffer(JSON.stringify(message)); + +// Try with different concurrency values to see how this actually +// slows significantly with higher concurrency! +// +// 5: 1398.607ms +// 10: 1375.668ms +// Infinity: 4423.300ms +// +const t = new Limiter({concurrency: 5}); +function deflate(payload, cb) { + t.push(function(done) { + zlib.deflate(payload, function(err, buffer) { + done(); + cb(err, buffer); + }); + }); +} + +console.time('deflate'); +for(let i = 0; i < 30000; ++i) { + deflate(payload, function (err, buffer) {}); +} +q.onDone(function() { + console.timeEnd('deflate'); +}); +``` + +## Install + +`npm install async-limiter` + +## Test + +`npm test` + +## API + +### `var t = new Limiter([opts])` +Constructor. `opts` may contain inital values for: +* `q.concurrency` + +## Instance methods + +### `q.onDone(fn)` +`fn` will be called once and only once, when the queue is empty. + +## Instance methods mixed in from `Array` +Mozilla has docs on how these methods work [here](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array). +### `q.push(element1, ..., elementN)` +### `q.unshift(element1, ..., elementN)` +### `q.splice(index , howMany[, element1[, ...[, elementN]]])` + +## Properties +### `q.concurrency` +Max number of jobs the queue should process concurrently, defaults to `Infinity`. + +### `q.length` +Jobs pending + jobs to process (readonly). + diff --git a/node_modules/async-settle/LICENSE b/node_modules/async-settle/LICENSE new file mode 100644 index 0000000000..0b2955ae3c --- /dev/null +++ b/node_modules/async-settle/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2014 Blaine Bublitz, Eric Schoffstall and other contributors + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/node_modules/async-settle/README.md b/node_modules/async-settle/README.md new file mode 100644 index 0000000000..c08c42e8b6 --- /dev/null +++ b/node_modules/async-settle/README.md @@ -0,0 +1,96 @@ +

+ + + +

+ +# async-settle + +[![NPM version][npm-image]][npm-url] [![Downloads][downloads-image]][npm-url] [![Build Status][travis-image]][travis-url] [![AppVeyor Build Status][appveyor-image]][appveyor-url] [![Coveralls Status][coveralls-image]][coveralls-url] [![Gitter chat][gitter-image]][gitter-url] + +Settle an async function. It will always complete successfully with an object of the resulting state. + +Handles completion and errors for callbacks, promises, observables and streams. + +Will run call the function on `nextTick`. This will cause all functions to be async. + +## Usage + +### Successful completion + +```js +var asyncSettle = require('async-settle'); + +asyncSettle(function(done){ + // do async things + done(null, 2); +}, function(error, result){ + // `error` will ALWAYS be null on execution of the first function. + // `result` will ALWAYS be a settled object with the result or error of the first function. +}); +``` + +### Failed completion + +```js +var asyncSettle = require('async-settle'); + +asyncSettle(function(done){ + // do async things + done(new Error('Some Error Occurred')); +}, function(error, result){ + // `error` will ALWAYS be null on execution of the first function. + // `result` will ALWAYS be a settled object with the result or error of the first function. +}); +``` + +## API + +### `asyncSettle(fn, callback)` + +Takes a function to execute (`fn`) and a function to call on completion (`callback`). + +#### `fn([done])` + +Optionally takes a callback (`done`) to call when async tasks are complete. + +Executed in the context of [`async-done`][async-done], with all errors and results being settled. + +Completion is handled by [`async-done` completion and error resolution][completions]. + +#### `callback(error, result)` + +Called on completion of `fn` and recieves a settled object as the `result` argument. + +The `error` argument will always be `null`. + +#### Settled Object + +Settled values have two properties, `state` and `value`. + +`state` has two possible options `'error'` and `'success'`. + +`value` will be the value passed to original callback. + +## License + +MIT + +[async-done]: https://github.com/gulpjs/async-done +[completions]: https://github.com/gulpjs/async-done#completion-and-error-resolution + +[downloads-image]: http://img.shields.io/npm/dm/async-settle.svg +[npm-url]: https://www.npmjs.com/package/async-settle +[npm-image]: http://img.shields.io/npm/v/async-settle.svg + +[travis-url]: https://travis-ci.org/gulpjs/async-settle +[travis-image]: http://img.shields.io/travis/gulpjs/async-settle.svg?label=travis-ci + +[appveyor-url]: https://ci.appveyor.com/project/gulpjs/async-settle +[appveyor-image]: https://img.shields.io/appveyor/ci/gulpjs/async-settle.svg?label=appveyor + +[coveralls-url]: https://coveralls.io/r/gulpjs/async-settle +[coveralls-image]: http://img.shields.io/coveralls/gulpjs/async-settle/master.svg + +[gitter-url]: https://gitter.im/gulpjs/gulp +[gitter-image]: https://badges.gitter.im/gulpjs/gulp.svg diff --git a/node_modules/async-settle/index.js b/node_modules/async-settle/index.js new file mode 100644 index 0000000000..0fd28d6c2c --- /dev/null +++ b/node_modules/async-settle/index.js @@ -0,0 +1,21 @@ +'use strict'; + +var asyncDone = require('async-done'); + +function settle(fn, done) { + asyncDone(fn, function(error, result) { + var settled = {}; + + if (error != null) { + settled.state = 'error'; + settled.value = error; + } else { + settled.state = 'success'; + settled.value = result; + } + + done(null, settled); + }); +} + +module.exports = settle; diff --git a/node_modules/async-settle/package.json b/node_modules/async-settle/package.json new file mode 100644 index 0000000000..03814a37ee --- /dev/null +++ b/node_modules/async-settle/package.json @@ -0,0 +1,86 @@ +{ + "_from": "async-settle@^1.0.0", + "_id": "async-settle@1.0.0", + "_inBundle": false, + "_integrity": "sha1-HQqRS7Aldb7IqPOnTlCA9yssDGs=", + "_location": "/async-settle", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "async-settle@^1.0.0", + "name": "async-settle", + "escapedName": "async-settle", + "rawSpec": "^1.0.0", + "saveSpec": null, + "fetchSpec": "^1.0.0" + }, + "_requiredBy": [ + "/bach" + ], + "_resolved": "https://registry.npmjs.org/async-settle/-/async-settle-1.0.0.tgz", + "_shasum": "1d0a914bb02575bec8a8f3a74e5080f72b2c0c6b", + "_spec": "async-settle@^1.0.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/bach", + "author": { + "name": "Gulp Team", + "email": "team@gulpjs.com", + "url": "http://gulpjs.com/" + }, + "bugs": { + "url": "https://github.com/gulpjs/async-settle/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "Blaine Bublitz", + "email": "blaine.bublitz@gmail.com" + } + ], + "dependencies": { + "async-done": "^1.2.2" + }, + "deprecated": false, + "description": "Settle an async function.", + "devDependencies": { + "eslint": "^1.7.3", + "eslint-config-gulp": "^2.0.0", + "expect": "^1.19.0", + "istanbul": "^0.4.3", + "istanbul-coveralls": "^1.0.3", + "jscs": "^2.3.5", + "jscs-preset-gulp": "^1.0.0", + "mocha": "^2.4.5" + }, + "engines": { + "node": ">= 0.10" + }, + "files": [ + "index.js", + "LICENSE" + ], + "homepage": "https://github.com/gulpjs/async-settle#readme", + "keywords": [ + "settle", + "async", + "async-done", + "complete", + "error", + "parallel" + ], + "license": "MIT", + "main": "index.js", + "name": "async-settle", + "repository": { + "type": "git", + "url": "git+https://github.com/gulpjs/async-settle.git" + }, + "scripts": { + "cover": "istanbul cover _mocha --report lcovonly", + "coveralls": "npm run cover && istanbul-coveralls", + "lint": "eslint . && jscs index.js test/", + "pretest": "npm run lint", + "test": "mocha --async-only" + }, + "version": "1.0.0" +} diff --git a/node_modules/async/CHANGELOG.md b/node_modules/async/CHANGELOG.md new file mode 100644 index 0000000000..f15e08121b --- /dev/null +++ b/node_modules/async/CHANGELOG.md @@ -0,0 +1,125 @@ +# v1.5.2 +- Allow using `"consructor"` as an argument in `memoize` (#998) +- Give a better error messsage when `auto` dependency checking fails (#994) +- Various doc updates (#936, #956, #979, #1002) + +# v1.5.1 +- Fix issue with `pause` in `queue` with concurrency enabled (#946) +- `while` and `until` now pass the final result to callback (#963) +- `auto` will properly handle concurrency when there is no callback (#966) +- `auto` will now properly stop execution when an error occurs (#988, #993) +- Various doc fixes (#971, #980) + +# v1.5.0 + +- Added `transform`, analogous to [`_.transform`](http://lodash.com/docs#transform) (#892) +- `map` now returns an object when an object is passed in, rather than array with non-numeric keys. `map` will begin always returning an array with numeric indexes in the next major release. (#873) +- `auto` now accepts an optional `concurrency` argument to limit the number of running tasks (#637) +- Added `queue#workersList()`, to retrieve the list of currently running tasks. (#891) +- Various code simplifications (#896, #904) +- Various doc fixes :scroll: (#890, #894, #903, #905, #912) + +# v1.4.2 + +- Ensure coverage files don't get published on npm (#879) + +# v1.4.1 + +- Add in overlooked `detectLimit` method (#866) +- Removed unnecessary files from npm releases (#861) +- Removed usage of a reserved word to prevent :boom: in older environments (#870) + +# v1.4.0 + +- `asyncify` now supports promises (#840) +- Added `Limit` versions of `filter` and `reject` (#836) +- Add `Limit` versions of `detect`, `some` and `every` (#828, #829) +- `some`, `every` and `detect` now short circuit early (#828, #829) +- Improve detection of the global object (#804), enabling use in WebWorkers +- `whilst` now called with arguments from iterator (#823) +- `during` now gets called with arguments from iterator (#824) +- Code simplifications and optimizations aplenty ([diff](https://github.com/caolan/async/compare/v1.3.0...v1.4.0)) + + +# v1.3.0 + +New Features: +- Added `constant` +- Added `asyncify`/`wrapSync` for making sync functions work with callbacks. (#671, #806) +- Added `during` and `doDuring`, which are like `whilst` with an async truth test. (#800) +- `retry` now accepts an `interval` parameter to specify a delay between retries. (#793) +- `async` should work better in Web Workers due to better `root` detection (#804) +- Callbacks are now optional in `whilst`, `doWhilst`, `until`, and `doUntil` (#642) +- Various internal updates (#786, #801, #802, #803) +- Various doc fixes (#790, #794) + +Bug Fixes: +- `cargo` now exposes the `payload` size, and `cargo.payload` can be changed on the fly after the `cargo` is created. (#740, #744, #783) + + +# v1.2.1 + +Bug Fix: + +- Small regression with synchronous iterator behavior in `eachSeries` with a 1-element array. Before 1.1.0, `eachSeries`'s callback was called on the same tick, which this patch restores. In 2.0.0, it will be called on the next tick. (#782) + + +# v1.2.0 + +New Features: + +- Added `timesLimit` (#743) +- `concurrency` can be changed after initialization in `queue` by setting `q.concurrency`. The new concurrency will be reflected the next time a task is processed. (#747, #772) + +Bug Fixes: + +- Fixed a regression in `each` and family with empty arrays that have additional properties. (#775, #777) + + +# v1.1.1 + +Bug Fix: + +- Small regression with synchronous iterator behavior in `eachSeries` with a 1-element array. Before 1.1.0, `eachSeries`'s callback was called on the same tick, which this patch restores. In 2.0.0, it will be called on the next tick. (#782) + + +# v1.1.0 + +New Features: + +- `cargo` now supports all of the same methods and event callbacks as `queue`. +- Added `ensureAsync` - A wrapper that ensures an async function calls its callback on a later tick. (#769) +- Optimized `map`, `eachOf`, and `waterfall` families of functions +- Passing a `null` or `undefined` array to `map`, `each`, `parallel` and families will be treated as an empty array (#667). +- The callback is now optional for the composed results of `compose` and `seq`. (#618) +- Reduced file size by 4kb, (minified version by 1kb) +- Added code coverage through `nyc` and `coveralls` (#768) + +Bug Fixes: + +- `forever` will no longer stack overflow with a synchronous iterator (#622) +- `eachLimit` and other limit functions will stop iterating once an error occurs (#754) +- Always pass `null` in callbacks when there is no error (#439) +- Ensure proper conditions when calling `drain()` after pushing an empty data set to a queue (#668) +- `each` and family will properly handle an empty array (#578) +- `eachSeries` and family will finish if the underlying array is modified during execution (#557) +- `queue` will throw if a non-function is passed to `q.push()` (#593) +- Doc fixes (#629, #766) + + +# v1.0.0 + +No known breaking changes, we are simply complying with semver from here on out. + +Changes: + +- Start using a changelog! +- Add `forEachOf` for iterating over Objects (or to iterate Arrays with indexes available) (#168 #704 #321) +- Detect deadlocks in `auto` (#663) +- Better support for require.js (#527) +- Throw if queue created with concurrency `0` (#714) +- Fix unneeded iteration in `queue.resume()` (#758) +- Guard against timer mocking overriding `setImmediate` (#609 #611) +- Miscellaneous doc fixes (#542 #596 #615 #628 #631 #690 #729) +- Use single noop function internally (#546) +- Optimize internal `_each`, `_map` and `_keys` functions. diff --git a/node_modules/async/LICENSE b/node_modules/async/LICENSE new file mode 100644 index 0000000000..8f29698588 --- /dev/null +++ b/node_modules/async/LICENSE @@ -0,0 +1,19 @@ +Copyright (c) 2010-2014 Caolan McMahon + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/async/README.md b/node_modules/async/README.md new file mode 100644 index 0000000000..316c40505c --- /dev/null +++ b/node_modules/async/README.md @@ -0,0 +1,1877 @@ +# Async.js + +[![Build Status via Travis CI](https://travis-ci.org/caolan/async.svg?branch=master)](https://travis-ci.org/caolan/async) +[![NPM version](http://img.shields.io/npm/v/async.svg)](https://www.npmjs.org/package/async) +[![Coverage Status](https://coveralls.io/repos/caolan/async/badge.svg?branch=master)](https://coveralls.io/r/caolan/async?branch=master) +[![Join the chat at https://gitter.im/caolan/async](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/caolan/async?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) + + +Async is a utility module which provides straight-forward, powerful functions +for working with asynchronous JavaScript. Although originally designed for +use with [Node.js](http://nodejs.org) and installable via `npm install async`, +it can also be used directly in the browser. + +Async is also installable via: + +- [bower](http://bower.io/): `bower install async` +- [component](https://github.com/component/component): `component install + caolan/async` +- [jam](http://jamjs.org/): `jam install async` +- [spm](http://spmjs.io/): `spm install async` + +Async provides around 20 functions that include the usual 'functional' +suspects (`map`, `reduce`, `filter`, `each`…) as well as some common patterns +for asynchronous control flow (`parallel`, `series`, `waterfall`…). All these +functions assume you follow the Node.js convention of providing a single +callback as the last argument of your `async` function. + + +## Quick Examples + +```javascript +async.map(['file1','file2','file3'], fs.stat, function(err, results){ + // results is now an array of stats for each file +}); + +async.filter(['file1','file2','file3'], fs.exists, function(results){ + // results now equals an array of the existing files +}); + +async.parallel([ + function(){ ... }, + function(){ ... } +], callback); + +async.series([ + function(){ ... }, + function(){ ... } +]); +``` + +There are many more functions available so take a look at the docs below for a +full list. This module aims to be comprehensive, so if you feel anything is +missing please create a GitHub issue for it. + +## Common Pitfalls [(StackOverflow)](http://stackoverflow.com/questions/tagged/async.js) +### Synchronous iteration functions + +If you get an error like `RangeError: Maximum call stack size exceeded.` or other stack overflow issues when using async, you are likely using a synchronous iterator. By *synchronous* we mean a function that calls its callback on the same tick in the javascript event loop, without doing any I/O or using any timers. Calling many callbacks iteratively will quickly overflow the stack. If you run into this issue, just defer your callback with `async.setImmediate` to start a new call stack on the next tick of the event loop. + +This can also arise by accident if you callback early in certain cases: + +```js +async.eachSeries(hugeArray, function iterator(item, callback) { + if (inCache(item)) { + callback(null, cache[item]); // if many items are cached, you'll overflow + } else { + doSomeIO(item, callback); + } +}, function done() { + //... +}); +``` + +Just change it to: + +```js +async.eachSeries(hugeArray, function iterator(item, callback) { + if (inCache(item)) { + async.setImmediate(function () { + callback(null, cache[item]); + }); + } else { + doSomeIO(item, callback); + //... +``` + +Async guards against synchronous functions in some, but not all, cases. If you are still running into stack overflows, you can defer as suggested above, or wrap functions with [`async.ensureAsync`](#ensureAsync) Functions that are asynchronous by their nature do not have this problem and don't need the extra callback deferral. + +If JavaScript's event loop is still a bit nebulous, check out [this article](http://blog.carbonfive.com/2013/10/27/the-javascript-event-loop-explained/) or [this talk](http://2014.jsconf.eu/speakers/philip-roberts-what-the-heck-is-the-event-loop-anyway.html) for more detailed information about how it works. + + +### Multiple callbacks + +Make sure to always `return` when calling a callback early, otherwise you will cause multiple callbacks and unpredictable behavior in many cases. + +```js +async.waterfall([ + function (callback) { + getSomething(options, function (err, result) { + if (err) { + callback(new Error("failed getting something:" + err.message)); + // we should return here + } + // since we did not return, this callback still will be called and + // `processData` will be called twice + callback(null, result); + }); + }, + processData +], done) +``` + +It is always good practice to `return callback(err, result)` whenever a callback call is not the last statement of a function. + + +### Binding a context to an iterator + +This section is really about `bind`, not about `async`. If you are wondering how to +make `async` execute your iterators in a given context, or are confused as to why +a method of another library isn't working as an iterator, study this example: + +```js +// Here is a simple object with an (unnecessarily roundabout) squaring method +var AsyncSquaringLibrary = { + squareExponent: 2, + square: function(number, callback){ + var result = Math.pow(number, this.squareExponent); + setTimeout(function(){ + callback(null, result); + }, 200); + } +}; + +async.map([1, 2, 3], AsyncSquaringLibrary.square, function(err, result){ + // result is [NaN, NaN, NaN] + // This fails because the `this.squareExponent` expression in the square + // function is not evaluated in the context of AsyncSquaringLibrary, and is + // therefore undefined. +}); + +async.map([1, 2, 3], AsyncSquaringLibrary.square.bind(AsyncSquaringLibrary), function(err, result){ + // result is [1, 4, 9] + // With the help of bind we can attach a context to the iterator before + // passing it to async. Now the square function will be executed in its + // 'home' AsyncSquaringLibrary context and the value of `this.squareExponent` + // will be as expected. +}); +``` + +## Download + +The source is available for download from +[GitHub](https://github.com/caolan/async/blob/master/lib/async.js). +Alternatively, you can install using Node Package Manager (`npm`): + + npm install async + +As well as using Bower: + + bower install async + +__Development:__ [async.js](https://github.com/caolan/async/raw/master/lib/async.js) - 29.6kb Uncompressed + +## In the Browser + +So far it's been tested in IE6, IE7, IE8, FF3.6 and Chrome 5. + +Usage: + +```html + + +``` + +## Documentation + +Some functions are also available in the following forms: +* `Series` - the same as `` but runs only a single async operation at a time +* `Limit` - the same as `` but runs a maximum of `limit` async operations at a time + +### Collections + +* [`each`](#each), `eachSeries`, `eachLimit` +* [`forEachOf`](#forEachOf), `forEachOfSeries`, `forEachOfLimit` +* [`map`](#map), `mapSeries`, `mapLimit` +* [`filter`](#filter), `filterSeries`, `filterLimit` +* [`reject`](#reject), `rejectSeries`, `rejectLimit` +* [`reduce`](#reduce), [`reduceRight`](#reduceRight) +* [`detect`](#detect), `detectSeries`, `detectLimit` +* [`sortBy`](#sortBy) +* [`some`](#some), `someLimit` +* [`every`](#every), `everyLimit` +* [`concat`](#concat), `concatSeries` + +### Control Flow + +* [`series`](#seriestasks-callback) +* [`parallel`](#parallel), `parallelLimit` +* [`whilst`](#whilst), [`doWhilst`](#doWhilst) +* [`until`](#until), [`doUntil`](#doUntil) +* [`during`](#during), [`doDuring`](#doDuring) +* [`forever`](#forever) +* [`waterfall`](#waterfall) +* [`compose`](#compose) +* [`seq`](#seq) +* [`applyEach`](#applyEach), `applyEachSeries` +* [`queue`](#queue), [`priorityQueue`](#priorityQueue) +* [`cargo`](#cargo) +* [`auto`](#auto) +* [`retry`](#retry) +* [`iterator`](#iterator) +* [`times`](#times), `timesSeries`, `timesLimit` + +### Utils + +* [`apply`](#apply) +* [`nextTick`](#nextTick) +* [`memoize`](#memoize) +* [`unmemoize`](#unmemoize) +* [`ensureAsync`](#ensureAsync) +* [`constant`](#constant) +* [`asyncify`](#asyncify) +* [`wrapSync`](#wrapSync) +* [`log`](#log) +* [`dir`](#dir) +* [`noConflict`](#noConflict) + +## Collections + + + +### each(arr, iterator, [callback]) + +Applies the function `iterator` to each item in `arr`, in parallel. +The `iterator` is called with an item from the list, and a callback for when it +has finished. If the `iterator` passes an error to its `callback`, the main +`callback` (for the `each` function) is immediately called with the error. + +Note, that since this function applies `iterator` to each item in parallel, +there is no guarantee that the iterator functions will complete in order. + +__Arguments__ + +* `arr` - An array to iterate over. +* `iterator(item, callback)` - A function to apply to each item in `arr`. + The iterator is passed a `callback(err)` which must be called once it has + completed. If no error has occurred, the `callback` should be run without + arguments or with an explicit `null` argument. The array index is not passed + to the iterator. If you need the index, use [`forEachOf`](#forEachOf). +* `callback(err)` - *Optional* A callback which is called when all `iterator` functions + have finished, or an error occurs. + +__Examples__ + + +```js +// assuming openFiles is an array of file names and saveFile is a function +// to save the modified contents of that file: + +async.each(openFiles, saveFile, function(err){ + // if any of the saves produced an error, err would equal that error +}); +``` + +```js +// assuming openFiles is an array of file names + +async.each(openFiles, function(file, callback) { + + // Perform operation on file here. + console.log('Processing file ' + file); + + if( file.length > 32 ) { + console.log('This file name is too long'); + callback('File name too long'); + } else { + // Do work to process file here + console.log('File processed'); + callback(); + } +}, function(err){ + // if any of the file processing produced an error, err would equal that error + if( err ) { + // One of the iterations produced an error. + // All processing will now stop. + console.log('A file failed to process'); + } else { + console.log('All files have been processed successfully'); + } +}); +``` + +__Related__ + +* eachSeries(arr, iterator, [callback]) +* eachLimit(arr, limit, iterator, [callback]) + +--------------------------------------- + + + + +### forEachOf(obj, iterator, [callback]) + +Like `each`, except that it iterates over objects, and passes the key as the second argument to the iterator. + +__Arguments__ + +* `obj` - An object or array to iterate over. +* `iterator(item, key, callback)` - A function to apply to each item in `obj`. +The `key` is the item's key, or index in the case of an array. The iterator is +passed a `callback(err)` which must be called once it has completed. If no +error has occurred, the callback should be run without arguments or with an +explicit `null` argument. +* `callback(err)` - *Optional* A callback which is called when all `iterator` functions have finished, or an error occurs. + +__Example__ + +```js +var obj = {dev: "/dev.json", test: "/test.json", prod: "/prod.json"}; +var configs = {}; + +async.forEachOf(obj, function (value, key, callback) { + fs.readFile(__dirname + value, "utf8", function (err, data) { + if (err) return callback(err); + try { + configs[key] = JSON.parse(data); + } catch (e) { + return callback(e); + } + callback(); + }) +}, function (err) { + if (err) console.error(err.message); + // configs is now a map of JSON data + doSomethingWith(configs); +}) +``` + +__Related__ + +* forEachOfSeries(obj, iterator, [callback]) +* forEachOfLimit(obj, limit, iterator, [callback]) + +--------------------------------------- + + +### map(arr, iterator, [callback]) + +Produces a new array of values by mapping each value in `arr` through +the `iterator` function. The `iterator` is called with an item from `arr` and a +callback for when it has finished processing. Each of these callback takes 2 arguments: +an `error`, and the transformed item from `arr`. If `iterator` passes an error to its +callback, the main `callback` (for the `map` function) is immediately called with the error. + +Note, that since this function applies the `iterator` to each item in parallel, +there is no guarantee that the `iterator` functions will complete in order. +However, the results array will be in the same order as the original `arr`. + +__Arguments__ + +* `arr` - An array to iterate over. +* `iterator(item, callback)` - A function to apply to each item in `arr`. + The iterator is passed a `callback(err, transformed)` which must be called once + it has completed with an error (which can be `null`) and a transformed item. +* `callback(err, results)` - *Optional* A callback which is called when all `iterator` + functions have finished, or an error occurs. Results is an array of the + transformed items from the `arr`. + +__Example__ + +```js +async.map(['file1','file2','file3'], fs.stat, function(err, results){ + // results is now an array of stats for each file +}); +``` + +__Related__ +* mapSeries(arr, iterator, [callback]) +* mapLimit(arr, limit, iterator, [callback]) + +--------------------------------------- + + + +### filter(arr, iterator, [callback]) + +__Alias:__ `select` + +Returns a new array of all the values in `arr` which pass an async truth test. +_The callback for each `iterator` call only accepts a single argument of `true` or +`false`; it does not accept an error argument first!_ This is in-line with the +way node libraries work with truth tests like `fs.exists`. This operation is +performed in parallel, but the results array will be in the same order as the +original. + +__Arguments__ + +* `arr` - An array to iterate over. +* `iterator(item, callback)` - A truth test to apply to each item in `arr`. + The `iterator` is passed a `callback(truthValue)`, which must be called with a + boolean argument once it has completed. +* `callback(results)` - *Optional* A callback which is called after all the `iterator` + functions have finished. + +__Example__ + +```js +async.filter(['file1','file2','file3'], fs.exists, function(results){ + // results now equals an array of the existing files +}); +``` + +__Related__ + +* filterSeries(arr, iterator, [callback]) +* filterLimit(arr, limit, iterator, [callback]) + +--------------------------------------- + + +### reject(arr, iterator, [callback]) + +The opposite of [`filter`](#filter). Removes values that pass an `async` truth test. + +__Related__ + +* rejectSeries(arr, iterator, [callback]) +* rejectLimit(arr, limit, iterator, [callback]) + +--------------------------------------- + + +### reduce(arr, memo, iterator, [callback]) + +__Aliases:__ `inject`, `foldl` + +Reduces `arr` into a single value using an async `iterator` to return +each successive step. `memo` is the initial state of the reduction. +This function only operates in series. + +For performance reasons, it may make sense to split a call to this function into +a parallel map, and then use the normal `Array.prototype.reduce` on the results. +This function is for situations where each step in the reduction needs to be async; +if you can get the data before reducing it, then it's probably a good idea to do so. + +__Arguments__ + +* `arr` - An array to iterate over. +* `memo` - The initial state of the reduction. +* `iterator(memo, item, callback)` - A function applied to each item in the + array to produce the next step in the reduction. The `iterator` is passed a + `callback(err, reduction)` which accepts an optional error as its first + argument, and the state of the reduction as the second. If an error is + passed to the callback, the reduction is stopped and the main `callback` is + immediately called with the error. +* `callback(err, result)` - *Optional* A callback which is called after all the `iterator` + functions have finished. Result is the reduced value. + +__Example__ + +```js +async.reduce([1,2,3], 0, function(memo, item, callback){ + // pointless async: + process.nextTick(function(){ + callback(null, memo + item) + }); +}, function(err, result){ + // result is now equal to the last value of memo, which is 6 +}); +``` + +--------------------------------------- + + +### reduceRight(arr, memo, iterator, [callback]) + +__Alias:__ `foldr` + +Same as [`reduce`](#reduce), only operates on `arr` in reverse order. + + +--------------------------------------- + + +### detect(arr, iterator, [callback]) + +Returns the first value in `arr` that passes an async truth test. The +`iterator` is applied in parallel, meaning the first iterator to return `true` will +fire the detect `callback` with that result. That means the result might not be +the first item in the original `arr` (in terms of order) that passes the test. + +If order within the original `arr` is important, then look at [`detectSeries`](#detectSeries). + +__Arguments__ + +* `arr` - An array to iterate over. +* `iterator(item, callback)` - A truth test to apply to each item in `arr`. + The iterator is passed a `callback(truthValue)` which must be called with a + boolean argument once it has completed. **Note: this callback does not take an error as its first argument.** +* `callback(result)` - *Optional* A callback which is called as soon as any iterator returns + `true`, or after all the `iterator` functions have finished. Result will be + the first item in the array that passes the truth test (iterator) or the + value `undefined` if none passed. **Note: this callback does not take an error as its first argument.** + +__Example__ + +```js +async.detect(['file1','file2','file3'], fs.exists, function(result){ + // result now equals the first file in the list that exists +}); +``` + +__Related__ + +* detectSeries(arr, iterator, [callback]) +* detectLimit(arr, limit, iterator, [callback]) + +--------------------------------------- + + +### sortBy(arr, iterator, [callback]) + +Sorts a list by the results of running each `arr` value through an async `iterator`. + +__Arguments__ + +* `arr` - An array to iterate over. +* `iterator(item, callback)` - A function to apply to each item in `arr`. + The iterator is passed a `callback(err, sortValue)` which must be called once it + has completed with an error (which can be `null`) and a value to use as the sort + criteria. +* `callback(err, results)` - *Optional* A callback which is called after all the `iterator` + functions have finished, or an error occurs. Results is the items from + the original `arr` sorted by the values returned by the `iterator` calls. + +__Example__ + +```js +async.sortBy(['file1','file2','file3'], function(file, callback){ + fs.stat(file, function(err, stats){ + callback(err, stats.mtime); + }); +}, function(err, results){ + // results is now the original array of files sorted by + // modified date +}); +``` + +__Sort Order__ + +By modifying the callback parameter the sorting order can be influenced: + +```js +//ascending order +async.sortBy([1,9,3,5], function(x, callback){ + callback(null, x); +}, function(err,result){ + //result callback +} ); + +//descending order +async.sortBy([1,9,3,5], function(x, callback){ + callback(null, x*-1); //<- x*-1 instead of x, turns the order around +}, function(err,result){ + //result callback +} ); +``` + +--------------------------------------- + + +### some(arr, iterator, [callback]) + +__Alias:__ `any` + +Returns `true` if at least one element in the `arr` satisfies an async test. +_The callback for each iterator call only accepts a single argument of `true` or +`false`; it does not accept an error argument first!_ This is in-line with the +way node libraries work with truth tests like `fs.exists`. Once any iterator +call returns `true`, the main `callback` is immediately called. + +__Arguments__ + +* `arr` - An array to iterate over. +* `iterator(item, callback)` - A truth test to apply to each item in the array + in parallel. The iterator is passed a `callback(truthValue)`` which must be + called with a boolean argument once it has completed. +* `callback(result)` - *Optional* A callback which is called as soon as any iterator returns + `true`, or after all the iterator functions have finished. Result will be + either `true` or `false` depending on the values of the async tests. + + **Note: the callbacks do not take an error as their first argument.** +__Example__ + +```js +async.some(['file1','file2','file3'], fs.exists, function(result){ + // if result is true then at least one of the files exists +}); +``` + +__Related__ + +* someLimit(arr, limit, iterator, callback) + +--------------------------------------- + + +### every(arr, iterator, [callback]) + +__Alias:__ `all` + +Returns `true` if every element in `arr` satisfies an async test. +_The callback for each `iterator` call only accepts a single argument of `true` or +`false`; it does not accept an error argument first!_ This is in-line with the +way node libraries work with truth tests like `fs.exists`. + +__Arguments__ + +* `arr` - An array to iterate over. +* `iterator(item, callback)` - A truth test to apply to each item in the array + in parallel. The iterator is passed a `callback(truthValue)` which must be + called with a boolean argument once it has completed. +* `callback(result)` - *Optional* A callback which is called as soon as any iterator returns + `false`, or after all the iterator functions have finished. Result will be + either `true` or `false` depending on the values of the async tests. + + **Note: the callbacks do not take an error as their first argument.** + +__Example__ + +```js +async.every(['file1','file2','file3'], fs.exists, function(result){ + // if result is true then every file exists +}); +``` + +__Related__ + +* everyLimit(arr, limit, iterator, callback) + +--------------------------------------- + + +### concat(arr, iterator, [callback]) + +Applies `iterator` to each item in `arr`, concatenating the results. Returns the +concatenated list. The `iterator`s are called in parallel, and the results are +concatenated as they return. There is no guarantee that the results array will +be returned in the original order of `arr` passed to the `iterator` function. + +__Arguments__ + +* `arr` - An array to iterate over. +* `iterator(item, callback)` - A function to apply to each item in `arr`. + The iterator is passed a `callback(err, results)` which must be called once it + has completed with an error (which can be `null`) and an array of results. +* `callback(err, results)` - *Optional* A callback which is called after all the `iterator` + functions have finished, or an error occurs. Results is an array containing + the concatenated results of the `iterator` function. + +__Example__ + +```js +async.concat(['dir1','dir2','dir3'], fs.readdir, function(err, files){ + // files is now a list of filenames that exist in the 3 directories +}); +``` + +__Related__ + +* concatSeries(arr, iterator, [callback]) + + +## Control Flow + + +### series(tasks, [callback]) + +Run the functions in the `tasks` array in series, each one running once the previous +function has completed. If any functions in the series pass an error to its +callback, no more functions are run, and `callback` is immediately called with the value of the error. +Otherwise, `callback` receives an array of results when `tasks` have completed. + +It is also possible to use an object instead of an array. Each property will be +run as a function, and the results will be passed to the final `callback` as an object +instead of an array. This can be a more readable way of handling results from +[`series`](#series). + +**Note** that while many implementations preserve the order of object properties, the +[ECMAScript Language Specification](http://www.ecma-international.org/ecma-262/5.1/#sec-8.6) +explicitly states that + +> The mechanics and order of enumerating the properties is not specified. + +So if you rely on the order in which your series of functions are executed, and want +this to work on all platforms, consider using an array. + +__Arguments__ + +* `tasks` - An array or object containing functions to run, each function is passed + a `callback(err, result)` it must call on completion with an error `err` (which can + be `null`) and an optional `result` value. +* `callback(err, results)` - An optional callback to run once all the functions + have completed. This function gets a results array (or object) containing all + the result arguments passed to the `task` callbacks. + +__Example__ + +```js +async.series([ + function(callback){ + // do some stuff ... + callback(null, 'one'); + }, + function(callback){ + // do some more stuff ... + callback(null, 'two'); + } +], +// optional callback +function(err, results){ + // results is now equal to ['one', 'two'] +}); + + +// an example using an object instead of an array +async.series({ + one: function(callback){ + setTimeout(function(){ + callback(null, 1); + }, 200); + }, + two: function(callback){ + setTimeout(function(){ + callback(null, 2); + }, 100); + } +}, +function(err, results) { + // results is now equal to: {one: 1, two: 2} +}); +``` + +--------------------------------------- + + +### parallel(tasks, [callback]) + +Run the `tasks` array of functions in parallel, without waiting until the previous +function has completed. If any of the functions pass an error to its +callback, the main `callback` is immediately called with the value of the error. +Once the `tasks` have completed, the results are passed to the final `callback` as an +array. + +**Note:** `parallel` is about kicking-off I/O tasks in parallel, not about parallel execution of code. If your tasks do not use any timers or perform any I/O, they will actually be executed in series. Any synchronous setup sections for each task will happen one after the other. JavaScript remains single-threaded. + +It is also possible to use an object instead of an array. Each property will be +run as a function and the results will be passed to the final `callback` as an object +instead of an array. This can be a more readable way of handling results from +[`parallel`](#parallel). + + +__Arguments__ + +* `tasks` - An array or object containing functions to run. Each function is passed + a `callback(err, result)` which it must call on completion with an error `err` + (which can be `null`) and an optional `result` value. +* `callback(err, results)` - An optional callback to run once all the functions + have completed successfully. This function gets a results array (or object) containing all + the result arguments passed to the task callbacks. + +__Example__ + +```js +async.parallel([ + function(callback){ + setTimeout(function(){ + callback(null, 'one'); + }, 200); + }, + function(callback){ + setTimeout(function(){ + callback(null, 'two'); + }, 100); + } +], +// optional callback +function(err, results){ + // the results array will equal ['one','two'] even though + // the second function had a shorter timeout. +}); + + +// an example using an object instead of an array +async.parallel({ + one: function(callback){ + setTimeout(function(){ + callback(null, 1); + }, 200); + }, + two: function(callback){ + setTimeout(function(){ + callback(null, 2); + }, 100); + } +}, +function(err, results) { + // results is now equals to: {one: 1, two: 2} +}); +``` + +__Related__ + +* parallelLimit(tasks, limit, [callback]) + +--------------------------------------- + + +### whilst(test, fn, callback) + +Repeatedly call `fn`, while `test` returns `true`. Calls `callback` when stopped, +or an error occurs. + +__Arguments__ + +* `test()` - synchronous truth test to perform before each execution of `fn`. +* `fn(callback)` - A function which is called each time `test` passes. The function is + passed a `callback(err)`, which must be called once it has completed with an + optional `err` argument. +* `callback(err, [results])` - A callback which is called after the test + function has failed and repeated execution of `fn` has stopped. `callback` + will be passed an error and any arguments passed to the final `fn`'s callback. + +__Example__ + +```js +var count = 0; + +async.whilst( + function () { return count < 5; }, + function (callback) { + count++; + setTimeout(function () { + callback(null, count); + }, 1000); + }, + function (err, n) { + // 5 seconds have passed, n = 5 + } +); +``` + +--------------------------------------- + + +### doWhilst(fn, test, callback) + +The post-check version of [`whilst`](#whilst). To reflect the difference in +the order of operations, the arguments `test` and `fn` are switched. + +`doWhilst` is to `whilst` as `do while` is to `while` in plain JavaScript. + +--------------------------------------- + + +### until(test, fn, callback) + +Repeatedly call `fn` until `test` returns `true`. Calls `callback` when stopped, +or an error occurs. `callback` will be passed an error and any arguments passed +to the final `fn`'s callback. + +The inverse of [`whilst`](#whilst). + +--------------------------------------- + + +### doUntil(fn, test, callback) + +Like [`doWhilst`](#doWhilst), except the `test` is inverted. Note the argument ordering differs from `until`. + +--------------------------------------- + + +### during(test, fn, callback) + +Like [`whilst`](#whilst), except the `test` is an asynchronous function that is passed a callback in the form of `function (err, truth)`. If error is passed to `test` or `fn`, the main callback is immediately called with the value of the error. + +__Example__ + +```js +var count = 0; + +async.during( + function (callback) { + return callback(null, count < 5); + }, + function (callback) { + count++; + setTimeout(callback, 1000); + }, + function (err) { + // 5 seconds have passed + } +); +``` + +--------------------------------------- + + +### doDuring(fn, test, callback) + +The post-check version of [`during`](#during). To reflect the difference in +the order of operations, the arguments `test` and `fn` are switched. + +Also a version of [`doWhilst`](#doWhilst) with asynchronous `test` function. + +--------------------------------------- + + +### forever(fn, [errback]) + +Calls the asynchronous function `fn` with a callback parameter that allows it to +call itself again, in series, indefinitely. + +If an error is passed to the callback then `errback` is called with the +error, and execution stops, otherwise it will never be called. + +```js +async.forever( + function(next) { + // next is suitable for passing to things that need a callback(err [, whatever]); + // it will result in this function being called again. + }, + function(err) { + // if next is called with a value in its first parameter, it will appear + // in here as 'err', and execution will stop. + } +); +``` + +--------------------------------------- + + +### waterfall(tasks, [callback]) + +Runs the `tasks` array of functions in series, each passing their results to the next in +the array. However, if any of the `tasks` pass an error to their own callback, the +next function is not executed, and the main `callback` is immediately called with +the error. + +__Arguments__ + +* `tasks` - An array of functions to run, each function is passed a + `callback(err, result1, result2, ...)` it must call on completion. The first + argument is an error (which can be `null`) and any further arguments will be + passed as arguments in order to the next task. +* `callback(err, [results])` - An optional callback to run once all the functions + have completed. This will be passed the results of the last task's callback. + + + +__Example__ + +```js +async.waterfall([ + function(callback) { + callback(null, 'one', 'two'); + }, + function(arg1, arg2, callback) { + // arg1 now equals 'one' and arg2 now equals 'two' + callback(null, 'three'); + }, + function(arg1, callback) { + // arg1 now equals 'three' + callback(null, 'done'); + } +], function (err, result) { + // result now equals 'done' +}); +``` +Or, with named functions: + +```js +async.waterfall([ + myFirstFunction, + mySecondFunction, + myLastFunction, +], function (err, result) { + // result now equals 'done' +}); +function myFirstFunction(callback) { + callback(null, 'one', 'two'); +} +function mySecondFunction(arg1, arg2, callback) { + // arg1 now equals 'one' and arg2 now equals 'two' + callback(null, 'three'); +} +function myLastFunction(arg1, callback) { + // arg1 now equals 'three' + callback(null, 'done'); +} +``` + +Or, if you need to pass any argument to the first function: + +```js +async.waterfall([ + async.apply(myFirstFunction, 'zero'), + mySecondFunction, + myLastFunction, +], function (err, result) { + // result now equals 'done' +}); +function myFirstFunction(arg1, callback) { + // arg1 now equals 'zero' + callback(null, 'one', 'two'); +} +function mySecondFunction(arg1, arg2, callback) { + // arg1 now equals 'one' and arg2 now equals 'two' + callback(null, 'three'); +} +function myLastFunction(arg1, callback) { + // arg1 now equals 'three' + callback(null, 'done'); +} +``` + +--------------------------------------- + +### compose(fn1, fn2...) + +Creates a function which is a composition of the passed asynchronous +functions. Each function consumes the return value of the function that +follows. Composing functions `f()`, `g()`, and `h()` would produce the result of +`f(g(h()))`, only this version uses callbacks to obtain the return values. + +Each function is executed with the `this` binding of the composed function. + +__Arguments__ + +* `functions...` - the asynchronous functions to compose + + +__Example__ + +```js +function add1(n, callback) { + setTimeout(function () { + callback(null, n + 1); + }, 10); +} + +function mul3(n, callback) { + setTimeout(function () { + callback(null, n * 3); + }, 10); +} + +var add1mul3 = async.compose(mul3, add1); + +add1mul3(4, function (err, result) { + // result now equals 15 +}); +``` + +--------------------------------------- + +### seq(fn1, fn2...) + +Version of the compose function that is more natural to read. +Each function consumes the return value of the previous function. +It is the equivalent of [`compose`](#compose) with the arguments reversed. + +Each function is executed with the `this` binding of the composed function. + +__Arguments__ + +* `functions...` - the asynchronous functions to compose + + +__Example__ + +```js +// Requires lodash (or underscore), express3 and dresende's orm2. +// Part of an app, that fetches cats of the logged user. +// This example uses `seq` function to avoid overnesting and error +// handling clutter. +app.get('/cats', function(request, response) { + var User = request.models.User; + async.seq( + _.bind(User.get, User), // 'User.get' has signature (id, callback(err, data)) + function(user, fn) { + user.getCats(fn); // 'getCats' has signature (callback(err, data)) + } + )(req.session.user_id, function (err, cats) { + if (err) { + console.error(err); + response.json({ status: 'error', message: err.message }); + } else { + response.json({ status: 'ok', message: 'Cats found', data: cats }); + } + }); +}); +``` + +--------------------------------------- + +### applyEach(fns, args..., callback) + +Applies the provided arguments to each function in the array, calling +`callback` after all functions have completed. If you only provide the first +argument, then it will return a function which lets you pass in the +arguments as if it were a single function call. + +__Arguments__ + +* `fns` - the asynchronous functions to all call with the same arguments +* `args...` - any number of separate arguments to pass to the function +* `callback` - the final argument should be the callback, called when all + functions have completed processing + + +__Example__ + +```js +async.applyEach([enableSearch, updateSchema], 'bucket', callback); + +// partial application example: +async.each( + buckets, + async.applyEach([enableSearch, updateSchema]), + callback +); +``` + +__Related__ + +* applyEachSeries(tasks, args..., [callback]) + +--------------------------------------- + + +### queue(worker, [concurrency]) + +Creates a `queue` object with the specified `concurrency`. Tasks added to the +`queue` are processed in parallel (up to the `concurrency` limit). If all +`worker`s are in progress, the task is queued until one becomes available. +Once a `worker` completes a `task`, that `task`'s callback is called. + +__Arguments__ + +* `worker(task, callback)` - An asynchronous function for processing a queued + task, which must call its `callback(err)` argument when finished, with an + optional `error` as an argument. If you want to handle errors from an individual task, pass a callback to `q.push()`. +* `concurrency` - An `integer` for determining how many `worker` functions should be + run in parallel. If omitted, the concurrency defaults to `1`. If the concurrency is `0`, an error is thrown. + +__Queue objects__ + +The `queue` object returned by this function has the following properties and +methods: + +* `length()` - a function returning the number of items waiting to be processed. +* `started` - a function returning whether or not any items have been pushed and processed by the queue +* `running()` - a function returning the number of items currently being processed. +* `workersList()` - a function returning the array of items currently being processed. +* `idle()` - a function returning false if there are items waiting or being processed, or true if not. +* `concurrency` - an integer for determining how many `worker` functions should be + run in parallel. This property can be changed after a `queue` is created to + alter the concurrency on-the-fly. +* `push(task, [callback])` - add a new task to the `queue`. Calls `callback` once + the `worker` has finished processing the task. Instead of a single task, a `tasks` array + can be submitted. The respective callback is used for every task in the list. +* `unshift(task, [callback])` - add a new task to the front of the `queue`. +* `saturated` - a callback that is called when the `queue` length hits the `concurrency` limit, + and further tasks will be queued. +* `empty` - a callback that is called when the last item from the `queue` is given to a `worker`. +* `drain` - a callback that is called when the last item from the `queue` has returned from the `worker`. +* `paused` - a boolean for determining whether the queue is in a paused state +* `pause()` - a function that pauses the processing of tasks until `resume()` is called. +* `resume()` - a function that resumes the processing of queued tasks when the queue is paused. +* `kill()` - a function that removes the `drain` callback and empties remaining tasks from the queue forcing it to go idle. + +__Example__ + +```js +// create a queue object with concurrency 2 + +var q = async.queue(function (task, callback) { + console.log('hello ' + task.name); + callback(); +}, 2); + + +// assign a callback +q.drain = function() { + console.log('all items have been processed'); +} + +// add some items to the queue + +q.push({name: 'foo'}, function (err) { + console.log('finished processing foo'); +}); +q.push({name: 'bar'}, function (err) { + console.log('finished processing bar'); +}); + +// add some items to the queue (batch-wise) + +q.push([{name: 'baz'},{name: 'bay'},{name: 'bax'}], function (err) { + console.log('finished processing item'); +}); + +// add some items to the front of the queue + +q.unshift({name: 'bar'}, function (err) { + console.log('finished processing bar'); +}); +``` + + +--------------------------------------- + + +### priorityQueue(worker, concurrency) + +The same as [`queue`](#queue) only tasks are assigned a priority and completed in ascending priority order. There are two differences between `queue` and `priorityQueue` objects: + +* `push(task, priority, [callback])` - `priority` should be a number. If an array of + `tasks` is given, all tasks will be assigned the same priority. +* The `unshift` method was removed. + +--------------------------------------- + + +### cargo(worker, [payload]) + +Creates a `cargo` object with the specified payload. Tasks added to the +cargo will be processed altogether (up to the `payload` limit). If the +`worker` is in progress, the task is queued until it becomes available. Once +the `worker` has completed some tasks, each callback of those tasks is called. +Check out [these](https://camo.githubusercontent.com/6bbd36f4cf5b35a0f11a96dcd2e97711ffc2fb37/68747470733a2f2f662e636c6f75642e6769746875622e636f6d2f6173736574732f313637363837312f36383130382f62626330636662302d356632392d313165322d393734662d3333393763363464633835382e676966) [animations](https://camo.githubusercontent.com/f4810e00e1c5f5f8addbe3e9f49064fd5d102699/68747470733a2f2f662e636c6f75642e6769746875622e636f6d2f6173736574732f313637363837312f36383130312f38346339323036362d356632392d313165322d383134662d3964336430323431336266642e676966) for how `cargo` and `queue` work. + +While [queue](#queue) passes only one task to one of a group of workers +at a time, cargo passes an array of tasks to a single worker, repeating +when the worker is finished. + +__Arguments__ + +* `worker(tasks, callback)` - An asynchronous function for processing an array of + queued tasks, which must call its `callback(err)` argument when finished, with + an optional `err` argument. +* `payload` - An optional `integer` for determining how many tasks should be + processed per round; if omitted, the default is unlimited. + +__Cargo objects__ + +The `cargo` object returned by this function has the following properties and +methods: + +* `length()` - A function returning the number of items waiting to be processed. +* `payload` - An `integer` for determining how many tasks should be + process per round. This property can be changed after a `cargo` is created to + alter the payload on-the-fly. +* `push(task, [callback])` - Adds `task` to the `queue`. The callback is called + once the `worker` has finished processing the task. Instead of a single task, an array of `tasks` + can be submitted. The respective callback is used for every task in the list. +* `saturated` - A callback that is called when the `queue.length()` hits the concurrency and further tasks will be queued. +* `empty` - A callback that is called when the last item from the `queue` is given to a `worker`. +* `drain` - A callback that is called when the last item from the `queue` has returned from the `worker`. +* `idle()`, `pause()`, `resume()`, `kill()` - cargo inherits all of the same methods and event calbacks as [`queue`](#queue) + +__Example__ + +```js +// create a cargo object with payload 2 + +var cargo = async.cargo(function (tasks, callback) { + for(var i=0; i +### auto(tasks, [concurrency], [callback]) + +Determines the best order for running the functions in `tasks`, based on their requirements. Each function can optionally depend on other functions being completed first, and each function is run as soon as its requirements are satisfied. + +If any of the functions pass an error to their callback, the `auto` sequence will stop. Further tasks will not execute (so any other functions depending on it will not run), and the main `callback` is immediately called with the error. Functions also receive an object containing the results of functions which have completed so far. + +Note, all functions are called with a `results` object as a second argument, +so it is unsafe to pass functions in the `tasks` object which cannot handle the +extra argument. + +For example, this snippet of code: + +```js +async.auto({ + readData: async.apply(fs.readFile, 'data.txt', 'utf-8') +}, callback); +``` + +will have the effect of calling `readFile` with the results object as the last +argument, which will fail: + +```js +fs.readFile('data.txt', 'utf-8', cb, {}); +``` + +Instead, wrap the call to `readFile` in a function which does not forward the +`results` object: + +```js +async.auto({ + readData: function(cb, results){ + fs.readFile('data.txt', 'utf-8', cb); + } +}, callback); +``` + +__Arguments__ + +* `tasks` - An object. Each of its properties is either a function or an array of + requirements, with the function itself the last item in the array. The object's key + of a property serves as the name of the task defined by that property, + i.e. can be used when specifying requirements for other tasks. + The function receives two arguments: (1) a `callback(err, result)` which must be + called when finished, passing an `error` (which can be `null`) and the result of + the function's execution, and (2) a `results` object, containing the results of + the previously executed functions. +* `concurrency` - An optional `integer` for determining the maximum number of tasks that can be run in parallel. By default, as many as possible. +* `callback(err, results)` - An optional callback which is called when all the + tasks have been completed. It receives the `err` argument if any `tasks` + pass an error to their callback. Results are always returned; however, if + an error occurs, no further `tasks` will be performed, and the results + object will only contain partial results. + + +__Example__ + +```js +async.auto({ + get_data: function(callback){ + console.log('in get_data'); + // async code to get some data + callback(null, 'data', 'converted to array'); + }, + make_folder: function(callback){ + console.log('in make_folder'); + // async code to create a directory to store a file in + // this is run at the same time as getting the data + callback(null, 'folder'); + }, + write_file: ['get_data', 'make_folder', function(callback, results){ + console.log('in write_file', JSON.stringify(results)); + // once there is some data and the directory exists, + // write the data to a file in the directory + callback(null, 'filename'); + }], + email_link: ['write_file', function(callback, results){ + console.log('in email_link', JSON.stringify(results)); + // once the file is written let's email a link to it... + // results.write_file contains the filename returned by write_file. + callback(null, {'file':results.write_file, 'email':'user@example.com'}); + }] +}, function(err, results) { + console.log('err = ', err); + console.log('results = ', results); +}); +``` + +This is a fairly trivial example, but to do this using the basic parallel and +series functions would look like this: + +```js +async.parallel([ + function(callback){ + console.log('in get_data'); + // async code to get some data + callback(null, 'data', 'converted to array'); + }, + function(callback){ + console.log('in make_folder'); + // async code to create a directory to store a file in + // this is run at the same time as getting the data + callback(null, 'folder'); + } +], +function(err, results){ + async.series([ + function(callback){ + console.log('in write_file', JSON.stringify(results)); + // once there is some data and the directory exists, + // write the data to a file in the directory + results.push('filename'); + callback(null); + }, + function(callback){ + console.log('in email_link', JSON.stringify(results)); + // once the file is written let's email a link to it... + callback(null, {'file':results.pop(), 'email':'user@example.com'}); + } + ]); +}); +``` + +For a complicated series of `async` tasks, using the [`auto`](#auto) function makes adding +new tasks much easier (and the code more readable). + + +--------------------------------------- + + +### retry([opts = {times: 5, interval: 0}| 5], task, [callback]) + +Attempts to get a successful response from `task` no more than `times` times before +returning an error. If the task is successful, the `callback` will be passed the result +of the successful task. If all attempts fail, the callback will be passed the error and +result (if any) of the final attempt. + +__Arguments__ + +* `opts` - Can be either an object with `times` and `interval` or a number. + * `times` - The number of attempts to make before giving up. The default is `5`. + * `interval` - The time to wait between retries, in milliseconds. The default is `0`. + * If `opts` is a number, the number specifies the number of times to retry, with the default interval of `0`. +* `task(callback, results)` - A function which receives two arguments: (1) a `callback(err, result)` + which must be called when finished, passing `err` (which can be `null`) and the `result` of + the function's execution, and (2) a `results` object, containing the results of + the previously executed functions (if nested inside another control flow). +* `callback(err, results)` - An optional callback which is called when the + task has succeeded, or after the final failed attempt. It receives the `err` and `result` arguments of the last attempt at completing the `task`. + +The [`retry`](#retry) function can be used as a stand-alone control flow by passing a callback, as shown below: + +```js +// try calling apiMethod 3 times +async.retry(3, apiMethod, function(err, result) { + // do something with the result +}); +``` + +```js +// try calling apiMethod 3 times, waiting 200 ms between each retry +async.retry({times: 3, interval: 200}, apiMethod, function(err, result) { + // do something with the result +}); +``` + +```js +// try calling apiMethod the default 5 times no delay between each retry +async.retry(apiMethod, function(err, result) { + // do something with the result +}); +``` + +It can also be embedded within other control flow functions to retry individual methods +that are not as reliable, like this: + +```js +async.auto({ + users: api.getUsers.bind(api), + payments: async.retry(3, api.getPayments.bind(api)) +}, function(err, results) { + // do something with the results +}); +``` + + +--------------------------------------- + + +### iterator(tasks) + +Creates an iterator function which calls the next function in the `tasks` array, +returning a continuation to call the next one after that. It's also possible to +“peek” at the next iterator with `iterator.next()`. + +This function is used internally by the `async` module, but can be useful when +you want to manually control the flow of functions in series. + +__Arguments__ + +* `tasks` - An array of functions to run. + +__Example__ + +```js +var iterator = async.iterator([ + function(){ sys.p('one'); }, + function(){ sys.p('two'); }, + function(){ sys.p('three'); } +]); + +node> var iterator2 = iterator(); +'one' +node> var iterator3 = iterator2(); +'two' +node> iterator3(); +'three' +node> var nextfn = iterator2.next(); +node> nextfn(); +'three' +``` + +--------------------------------------- + + +### apply(function, arguments..) + +Creates a continuation function with some arguments already applied. + +Useful as a shorthand when combined with other control flow functions. Any arguments +passed to the returned function are added to the arguments originally passed +to apply. + +__Arguments__ + +* `function` - The function you want to eventually apply all arguments to. +* `arguments...` - Any number of arguments to automatically apply when the + continuation is called. + +__Example__ + +```js +// using apply + +async.parallel([ + async.apply(fs.writeFile, 'testfile1', 'test1'), + async.apply(fs.writeFile, 'testfile2', 'test2'), +]); + + +// the same process without using apply + +async.parallel([ + function(callback){ + fs.writeFile('testfile1', 'test1', callback); + }, + function(callback){ + fs.writeFile('testfile2', 'test2', callback); + } +]); +``` + +It's possible to pass any number of additional arguments when calling the +continuation: + +```js +node> var fn = async.apply(sys.puts, 'one'); +node> fn('two', 'three'); +one +two +three +``` + +--------------------------------------- + + +### nextTick(callback), setImmediate(callback) + +Calls `callback` on a later loop around the event loop. In Node.js this just +calls `process.nextTick`; in the browser it falls back to `setImmediate(callback)` +if available, otherwise `setTimeout(callback, 0)`, which means other higher priority +events may precede the execution of `callback`. + +This is used internally for browser-compatibility purposes. + +__Arguments__ + +* `callback` - The function to call on a later loop around the event loop. + +__Example__ + +```js +var call_order = []; +async.nextTick(function(){ + call_order.push('two'); + // call_order now equals ['one','two'] +}); +call_order.push('one') +``` + + +### times(n, iterator, [callback]) + +Calls the `iterator` function `n` times, and accumulates results in the same manner +you would use with [`map`](#map). + +__Arguments__ + +* `n` - The number of times to run the function. +* `iterator` - The function to call `n` times. +* `callback` - see [`map`](#map) + +__Example__ + +```js +// Pretend this is some complicated async factory +var createUser = function(id, callback) { + callback(null, { + id: 'user' + id + }) +} +// generate 5 users +async.times(5, function(n, next){ + createUser(n, function(err, user) { + next(err, user) + }) +}, function(err, users) { + // we should now have 5 users +}); +``` + +__Related__ + +* timesSeries(n, iterator, [callback]) +* timesLimit(n, limit, iterator, [callback]) + + +## Utils + + +### memoize(fn, [hasher]) + +Caches the results of an `async` function. When creating a hash to store function +results against, the callback is omitted from the hash and an optional hash +function can be used. + +If no hash function is specified, the first argument is used as a hash key, which may work reasonably if it is a string or a data type that converts to a distinct string. Note that objects and arrays will not behave reasonably. Neither will cases where the other arguments are significant. In such cases, specify your own hash function. + +The cache of results is exposed as the `memo` property of the function returned +by `memoize`. + +__Arguments__ + +* `fn` - The function to proxy and cache results from. +* `hasher` - An optional function for generating a custom hash for storing + results. It has all the arguments applied to it apart from the callback, and + must be synchronous. + +__Example__ + +```js +var slow_fn = function (name, callback) { + // do something + callback(null, result); +}; +var fn = async.memoize(slow_fn); + +// fn can now be used as if it were slow_fn +fn('some name', function () { + // callback +}); +``` + + +### unmemoize(fn) + +Undoes a [`memoize`](#memoize)d function, reverting it to the original, unmemoized +form. Handy for testing. + +__Arguments__ + +* `fn` - the memoized function + +--------------------------------------- + + +### ensureAsync(fn) + +Wrap an async function and ensure it calls its callback on a later tick of the event loop. If the function already calls its callback on a next tick, no extra deferral is added. This is useful for preventing stack overflows (`RangeError: Maximum call stack size exceeded`) and generally keeping [Zalgo](http://blog.izs.me/post/59142742143/designing-apis-for-asynchrony) contained. + +__Arguments__ + +* `fn` - an async function, one that expects a node-style callback as its last argument + +Returns a wrapped function with the exact same call signature as the function passed in. + +__Example__ + +```js +function sometimesAsync(arg, callback) { + if (cache[arg]) { + return callback(null, cache[arg]); // this would be synchronous!! + } else { + doSomeIO(arg, callback); // this IO would be asynchronous + } +} + +// this has a risk of stack overflows if many results are cached in a row +async.mapSeries(args, sometimesAsync, done); + +// this will defer sometimesAsync's callback if necessary, +// preventing stack overflows +async.mapSeries(args, async.ensureAsync(sometimesAsync), done); + +``` + +--------------------------------------- + + +### constant(values...) + +Returns a function that when called, calls-back with the values provided. Useful as the first function in a `waterfall`, or for plugging values in to `auto`. + +__Example__ + +```js +async.waterfall([ + async.constant(42), + function (value, next) { + // value === 42 + }, + //... +], callback); + +async.waterfall([ + async.constant(filename, "utf8"), + fs.readFile, + function (fileData, next) { + //... + } + //... +], callback); + +async.auto({ + hostname: async.constant("https://server.net/"), + port: findFreePort, + launchServer: ["hostname", "port", function (cb, options) { + startServer(options, cb); + }], + //... +}, callback); + +``` + +--------------------------------------- + + + +### asyncify(func) + +__Alias:__ `wrapSync` + +Take a sync function and make it async, passing its return value to a callback. This is useful for plugging sync functions into a waterfall, series, or other async functions. Any arguments passed to the generated function will be passed to the wrapped function (except for the final callback argument). Errors thrown will be passed to the callback. + +__Example__ + +```js +async.waterfall([ + async.apply(fs.readFile, filename, "utf8"), + async.asyncify(JSON.parse), + function (data, next) { + // data is the result of parsing the text. + // If there was a parsing error, it would have been caught. + } +], callback) +``` + +If the function passed to `asyncify` returns a Promise, that promises's resolved/rejected state will be used to call the callback, rather than simply the synchronous return value. Example: + +```js +async.waterfall([ + async.apply(fs.readFile, filename, "utf8"), + async.asyncify(function (contents) { + return db.model.create(contents); + }), + function (model, next) { + // `model` is the instantiated model object. + // If there was an error, this function would be skipped. + } +], callback) +``` + +This also means you can asyncify ES2016 `async` functions. + +```js +var q = async.queue(async.asyncify(async function (file) { + var intermediateStep = await processFile(file); + return await somePromise(intermediateStep) +})); + +q.push(files); +``` + +--------------------------------------- + + +### log(function, arguments) + +Logs the result of an `async` function to the `console`. Only works in Node.js or +in browsers that support `console.log` and `console.error` (such as FF and Chrome). +If multiple arguments are returned from the async function, `console.log` is +called on each argument in order. + +__Arguments__ + +* `function` - The function you want to eventually apply all arguments to. +* `arguments...` - Any number of arguments to apply to the function. + +__Example__ + +```js +var hello = function(name, callback){ + setTimeout(function(){ + callback(null, 'hello ' + name); + }, 1000); +}; +``` +```js +node> async.log(hello, 'world'); +'hello world' +``` + +--------------------------------------- + + +### dir(function, arguments) + +Logs the result of an `async` function to the `console` using `console.dir` to +display the properties of the resulting object. Only works in Node.js or +in browsers that support `console.dir` and `console.error` (such as FF and Chrome). +If multiple arguments are returned from the async function, `console.dir` is +called on each argument in order. + +__Arguments__ + +* `function` - The function you want to eventually apply all arguments to. +* `arguments...` - Any number of arguments to apply to the function. + +__Example__ + +```js +var hello = function(name, callback){ + setTimeout(function(){ + callback(null, {hello: name}); + }, 1000); +}; +``` +```js +node> async.dir(hello, 'world'); +{hello: 'world'} +``` + +--------------------------------------- + + +### noConflict() + +Changes the value of `async` back to its original value, returning a reference to the +`async` object. diff --git a/node_modules/async/dist/async.js b/node_modules/async/dist/async.js new file mode 100644 index 0000000000..31e7620fb6 --- /dev/null +++ b/node_modules/async/dist/async.js @@ -0,0 +1,1265 @@ +/*! + * async + * https://github.com/caolan/async + * + * Copyright 2010-2014 Caolan McMahon + * Released under the MIT license + */ +(function () { + + var async = {}; + function noop() {} + function identity(v) { + return v; + } + function toBool(v) { + return !!v; + } + function notId(v) { + return !v; + } + + // global on the server, window in the browser + var previous_async; + + // Establish the root object, `window` (`self`) in the browser, `global` + // on the server, or `this` in some virtual machines. We use `self` + // instead of `window` for `WebWorker` support. + var root = typeof self === 'object' && self.self === self && self || + typeof global === 'object' && global.global === global && global || + this; + + if (root != null) { + previous_async = root.async; + } + + async.noConflict = function () { + root.async = previous_async; + return async; + }; + + function only_once(fn) { + return function() { + if (fn === null) throw new Error("Callback was already called."); + fn.apply(this, arguments); + fn = null; + }; + } + + function _once(fn) { + return function() { + if (fn === null) return; + fn.apply(this, arguments); + fn = null; + }; + } + + //// cross-browser compatiblity functions //// + + var _toString = Object.prototype.toString; + + var _isArray = Array.isArray || function (obj) { + return _toString.call(obj) === '[object Array]'; + }; + + // Ported from underscore.js isObject + var _isObject = function(obj) { + var type = typeof obj; + return type === 'function' || type === 'object' && !!obj; + }; + + function _isArrayLike(arr) { + return _isArray(arr) || ( + // has a positive integer length property + typeof arr.length === "number" && + arr.length >= 0 && + arr.length % 1 === 0 + ); + } + + function _arrayEach(arr, iterator) { + var index = -1, + length = arr.length; + + while (++index < length) { + iterator(arr[index], index, arr); + } + } + + function _map(arr, iterator) { + var index = -1, + length = arr.length, + result = Array(length); + + while (++index < length) { + result[index] = iterator(arr[index], index, arr); + } + return result; + } + + function _range(count) { + return _map(Array(count), function (v, i) { return i; }); + } + + function _reduce(arr, iterator, memo) { + _arrayEach(arr, function (x, i, a) { + memo = iterator(memo, x, i, a); + }); + return memo; + } + + function _forEachOf(object, iterator) { + _arrayEach(_keys(object), function (key) { + iterator(object[key], key); + }); + } + + function _indexOf(arr, item) { + for (var i = 0; i < arr.length; i++) { + if (arr[i] === item) return i; + } + return -1; + } + + var _keys = Object.keys || function (obj) { + var keys = []; + for (var k in obj) { + if (obj.hasOwnProperty(k)) { + keys.push(k); + } + } + return keys; + }; + + function _keyIterator(coll) { + var i = -1; + var len; + var keys; + if (_isArrayLike(coll)) { + len = coll.length; + return function next() { + i++; + return i < len ? i : null; + }; + } else { + keys = _keys(coll); + len = keys.length; + return function next() { + i++; + return i < len ? keys[i] : null; + }; + } + } + + // Similar to ES6's rest param (http://ariya.ofilabs.com/2013/03/es6-and-rest-parameter.html) + // This accumulates the arguments passed into an array, after a given index. + // From underscore.js (https://github.com/jashkenas/underscore/pull/2140). + function _restParam(func, startIndex) { + startIndex = startIndex == null ? func.length - 1 : +startIndex; + return function() { + var length = Math.max(arguments.length - startIndex, 0); + var rest = Array(length); + for (var index = 0; index < length; index++) { + rest[index] = arguments[index + startIndex]; + } + switch (startIndex) { + case 0: return func.call(this, rest); + case 1: return func.call(this, arguments[0], rest); + } + // Currently unused but handle cases outside of the switch statement: + // var args = Array(startIndex + 1); + // for (index = 0; index < startIndex; index++) { + // args[index] = arguments[index]; + // } + // args[startIndex] = rest; + // return func.apply(this, args); + }; + } + + function _withoutIndex(iterator) { + return function (value, index, callback) { + return iterator(value, callback); + }; + } + + //// exported async module functions //// + + //// nextTick implementation with browser-compatible fallback //// + + // capture the global reference to guard against fakeTimer mocks + var _setImmediate = typeof setImmediate === 'function' && setImmediate; + + var _delay = _setImmediate ? function(fn) { + // not a direct alias for IE10 compatibility + _setImmediate(fn); + } : function(fn) { + setTimeout(fn, 0); + }; + + if (typeof process === 'object' && typeof process.nextTick === 'function') { + async.nextTick = process.nextTick; + } else { + async.nextTick = _delay; + } + async.setImmediate = _setImmediate ? _delay : async.nextTick; + + + async.forEach = + async.each = function (arr, iterator, callback) { + return async.eachOf(arr, _withoutIndex(iterator), callback); + }; + + async.forEachSeries = + async.eachSeries = function (arr, iterator, callback) { + return async.eachOfSeries(arr, _withoutIndex(iterator), callback); + }; + + + async.forEachLimit = + async.eachLimit = function (arr, limit, iterator, callback) { + return _eachOfLimit(limit)(arr, _withoutIndex(iterator), callback); + }; + + async.forEachOf = + async.eachOf = function (object, iterator, callback) { + callback = _once(callback || noop); + object = object || []; + + var iter = _keyIterator(object); + var key, completed = 0; + + while ((key = iter()) != null) { + completed += 1; + iterator(object[key], key, only_once(done)); + } + + if (completed === 0) callback(null); + + function done(err) { + completed--; + if (err) { + callback(err); + } + // Check key is null in case iterator isn't exhausted + // and done resolved synchronously. + else if (key === null && completed <= 0) { + callback(null); + } + } + }; + + async.forEachOfSeries = + async.eachOfSeries = function (obj, iterator, callback) { + callback = _once(callback || noop); + obj = obj || []; + var nextKey = _keyIterator(obj); + var key = nextKey(); + function iterate() { + var sync = true; + if (key === null) { + return callback(null); + } + iterator(obj[key], key, only_once(function (err) { + if (err) { + callback(err); + } + else { + key = nextKey(); + if (key === null) { + return callback(null); + } else { + if (sync) { + async.setImmediate(iterate); + } else { + iterate(); + } + } + } + })); + sync = false; + } + iterate(); + }; + + + + async.forEachOfLimit = + async.eachOfLimit = function (obj, limit, iterator, callback) { + _eachOfLimit(limit)(obj, iterator, callback); + }; + + function _eachOfLimit(limit) { + + return function (obj, iterator, callback) { + callback = _once(callback || noop); + obj = obj || []; + var nextKey = _keyIterator(obj); + if (limit <= 0) { + return callback(null); + } + var done = false; + var running = 0; + var errored = false; + + (function replenish () { + if (done && running <= 0) { + return callback(null); + } + + while (running < limit && !errored) { + var key = nextKey(); + if (key === null) { + done = true; + if (running <= 0) { + callback(null); + } + return; + } + running += 1; + iterator(obj[key], key, only_once(function (err) { + running -= 1; + if (err) { + callback(err); + errored = true; + } + else { + replenish(); + } + })); + } + })(); + }; + } + + + function doParallel(fn) { + return function (obj, iterator, callback) { + return fn(async.eachOf, obj, iterator, callback); + }; + } + function doParallelLimit(fn) { + return function (obj, limit, iterator, callback) { + return fn(_eachOfLimit(limit), obj, iterator, callback); + }; + } + function doSeries(fn) { + return function (obj, iterator, callback) { + return fn(async.eachOfSeries, obj, iterator, callback); + }; + } + + function _asyncMap(eachfn, arr, iterator, callback) { + callback = _once(callback || noop); + arr = arr || []; + var results = _isArrayLike(arr) ? [] : {}; + eachfn(arr, function (value, index, callback) { + iterator(value, function (err, v) { + results[index] = v; + callback(err); + }); + }, function (err) { + callback(err, results); + }); + } + + async.map = doParallel(_asyncMap); + async.mapSeries = doSeries(_asyncMap); + async.mapLimit = doParallelLimit(_asyncMap); + + // reduce only has a series version, as doing reduce in parallel won't + // work in many situations. + async.inject = + async.foldl = + async.reduce = function (arr, memo, iterator, callback) { + async.eachOfSeries(arr, function (x, i, callback) { + iterator(memo, x, function (err, v) { + memo = v; + callback(err); + }); + }, function (err) { + callback(err, memo); + }); + }; + + async.foldr = + async.reduceRight = function (arr, memo, iterator, callback) { + var reversed = _map(arr, identity).reverse(); + async.reduce(reversed, memo, iterator, callback); + }; + + async.transform = function (arr, memo, iterator, callback) { + if (arguments.length === 3) { + callback = iterator; + iterator = memo; + memo = _isArray(arr) ? [] : {}; + } + + async.eachOf(arr, function(v, k, cb) { + iterator(memo, v, k, cb); + }, function(err) { + callback(err, memo); + }); + }; + + function _filter(eachfn, arr, iterator, callback) { + var results = []; + eachfn(arr, function (x, index, callback) { + iterator(x, function (v) { + if (v) { + results.push({index: index, value: x}); + } + callback(); + }); + }, function () { + callback(_map(results.sort(function (a, b) { + return a.index - b.index; + }), function (x) { + return x.value; + })); + }); + } + + async.select = + async.filter = doParallel(_filter); + + async.selectLimit = + async.filterLimit = doParallelLimit(_filter); + + async.selectSeries = + async.filterSeries = doSeries(_filter); + + function _reject(eachfn, arr, iterator, callback) { + _filter(eachfn, arr, function(value, cb) { + iterator(value, function(v) { + cb(!v); + }); + }, callback); + } + async.reject = doParallel(_reject); + async.rejectLimit = doParallelLimit(_reject); + async.rejectSeries = doSeries(_reject); + + function _createTester(eachfn, check, getResult) { + return function(arr, limit, iterator, cb) { + function done() { + if (cb) cb(getResult(false, void 0)); + } + function iteratee(x, _, callback) { + if (!cb) return callback(); + iterator(x, function (v) { + if (cb && check(v)) { + cb(getResult(true, x)); + cb = iterator = false; + } + callback(); + }); + } + if (arguments.length > 3) { + eachfn(arr, limit, iteratee, done); + } else { + cb = iterator; + iterator = limit; + eachfn(arr, iteratee, done); + } + }; + } + + async.any = + async.some = _createTester(async.eachOf, toBool, identity); + + async.someLimit = _createTester(async.eachOfLimit, toBool, identity); + + async.all = + async.every = _createTester(async.eachOf, notId, notId); + + async.everyLimit = _createTester(async.eachOfLimit, notId, notId); + + function _findGetResult(v, x) { + return x; + } + async.detect = _createTester(async.eachOf, identity, _findGetResult); + async.detectSeries = _createTester(async.eachOfSeries, identity, _findGetResult); + async.detectLimit = _createTester(async.eachOfLimit, identity, _findGetResult); + + async.sortBy = function (arr, iterator, callback) { + async.map(arr, function (x, callback) { + iterator(x, function (err, criteria) { + if (err) { + callback(err); + } + else { + callback(null, {value: x, criteria: criteria}); + } + }); + }, function (err, results) { + if (err) { + return callback(err); + } + else { + callback(null, _map(results.sort(comparator), function (x) { + return x.value; + })); + } + + }); + + function comparator(left, right) { + var a = left.criteria, b = right.criteria; + return a < b ? -1 : a > b ? 1 : 0; + } + }; + + async.auto = function (tasks, concurrency, callback) { + if (typeof arguments[1] === 'function') { + // concurrency is optional, shift the args. + callback = concurrency; + concurrency = null; + } + callback = _once(callback || noop); + var keys = _keys(tasks); + var remainingTasks = keys.length; + if (!remainingTasks) { + return callback(null); + } + if (!concurrency) { + concurrency = remainingTasks; + } + + var results = {}; + var runningTasks = 0; + + var hasError = false; + + var listeners = []; + function addListener(fn) { + listeners.unshift(fn); + } + function removeListener(fn) { + var idx = _indexOf(listeners, fn); + if (idx >= 0) listeners.splice(idx, 1); + } + function taskComplete() { + remainingTasks--; + _arrayEach(listeners.slice(0), function (fn) { + fn(); + }); + } + + addListener(function () { + if (!remainingTasks) { + callback(null, results); + } + }); + + _arrayEach(keys, function (k) { + if (hasError) return; + var task = _isArray(tasks[k]) ? tasks[k]: [tasks[k]]; + var taskCallback = _restParam(function(err, args) { + runningTasks--; + if (args.length <= 1) { + args = args[0]; + } + if (err) { + var safeResults = {}; + _forEachOf(results, function(val, rkey) { + safeResults[rkey] = val; + }); + safeResults[k] = args; + hasError = true; + + callback(err, safeResults); + } + else { + results[k] = args; + async.setImmediate(taskComplete); + } + }); + var requires = task.slice(0, task.length - 1); + // prevent dead-locks + var len = requires.length; + var dep; + while (len--) { + if (!(dep = tasks[requires[len]])) { + throw new Error('Has nonexistent dependency in ' + requires.join(', ')); + } + if (_isArray(dep) && _indexOf(dep, k) >= 0) { + throw new Error('Has cyclic dependencies'); + } + } + function ready() { + return runningTasks < concurrency && _reduce(requires, function (a, x) { + return (a && results.hasOwnProperty(x)); + }, true) && !results.hasOwnProperty(k); + } + if (ready()) { + runningTasks++; + task[task.length - 1](taskCallback, results); + } + else { + addListener(listener); + } + function listener() { + if (ready()) { + runningTasks++; + removeListener(listener); + task[task.length - 1](taskCallback, results); + } + } + }); + }; + + + + async.retry = function(times, task, callback) { + var DEFAULT_TIMES = 5; + var DEFAULT_INTERVAL = 0; + + var attempts = []; + + var opts = { + times: DEFAULT_TIMES, + interval: DEFAULT_INTERVAL + }; + + function parseTimes(acc, t){ + if(typeof t === 'number'){ + acc.times = parseInt(t, 10) || DEFAULT_TIMES; + } else if(typeof t === 'object'){ + acc.times = parseInt(t.times, 10) || DEFAULT_TIMES; + acc.interval = parseInt(t.interval, 10) || DEFAULT_INTERVAL; + } else { + throw new Error('Unsupported argument type for \'times\': ' + typeof t); + } + } + + var length = arguments.length; + if (length < 1 || length > 3) { + throw new Error('Invalid arguments - must be either (task), (task, callback), (times, task) or (times, task, callback)'); + } else if (length <= 2 && typeof times === 'function') { + callback = task; + task = times; + } + if (typeof times !== 'function') { + parseTimes(opts, times); + } + opts.callback = callback; + opts.task = task; + + function wrappedTask(wrappedCallback, wrappedResults) { + function retryAttempt(task, finalAttempt) { + return function(seriesCallback) { + task(function(err, result){ + seriesCallback(!err || finalAttempt, {err: err, result: result}); + }, wrappedResults); + }; + } + + function retryInterval(interval){ + return function(seriesCallback){ + setTimeout(function(){ + seriesCallback(null); + }, interval); + }; + } + + while (opts.times) { + + var finalAttempt = !(opts.times-=1); + attempts.push(retryAttempt(opts.task, finalAttempt)); + if(!finalAttempt && opts.interval > 0){ + attempts.push(retryInterval(opts.interval)); + } + } + + async.series(attempts, function(done, data){ + data = data[data.length - 1]; + (wrappedCallback || opts.callback)(data.err, data.result); + }); + } + + // If a callback is passed, run this as a controll flow + return opts.callback ? wrappedTask() : wrappedTask; + }; + + async.waterfall = function (tasks, callback) { + callback = _once(callback || noop); + if (!_isArray(tasks)) { + var err = new Error('First argument to waterfall must be an array of functions'); + return callback(err); + } + if (!tasks.length) { + return callback(); + } + function wrapIterator(iterator) { + return _restParam(function (err, args) { + if (err) { + callback.apply(null, [err].concat(args)); + } + else { + var next = iterator.next(); + if (next) { + args.push(wrapIterator(next)); + } + else { + args.push(callback); + } + ensureAsync(iterator).apply(null, args); + } + }); + } + wrapIterator(async.iterator(tasks))(); + }; + + function _parallel(eachfn, tasks, callback) { + callback = callback || noop; + var results = _isArrayLike(tasks) ? [] : {}; + + eachfn(tasks, function (task, key, callback) { + task(_restParam(function (err, args) { + if (args.length <= 1) { + args = args[0]; + } + results[key] = args; + callback(err); + })); + }, function (err) { + callback(err, results); + }); + } + + async.parallel = function (tasks, callback) { + _parallel(async.eachOf, tasks, callback); + }; + + async.parallelLimit = function(tasks, limit, callback) { + _parallel(_eachOfLimit(limit), tasks, callback); + }; + + async.series = function(tasks, callback) { + _parallel(async.eachOfSeries, tasks, callback); + }; + + async.iterator = function (tasks) { + function makeCallback(index) { + function fn() { + if (tasks.length) { + tasks[index].apply(null, arguments); + } + return fn.next(); + } + fn.next = function () { + return (index < tasks.length - 1) ? makeCallback(index + 1): null; + }; + return fn; + } + return makeCallback(0); + }; + + async.apply = _restParam(function (fn, args) { + return _restParam(function (callArgs) { + return fn.apply( + null, args.concat(callArgs) + ); + }); + }); + + function _concat(eachfn, arr, fn, callback) { + var result = []; + eachfn(arr, function (x, index, cb) { + fn(x, function (err, y) { + result = result.concat(y || []); + cb(err); + }); + }, function (err) { + callback(err, result); + }); + } + async.concat = doParallel(_concat); + async.concatSeries = doSeries(_concat); + + async.whilst = function (test, iterator, callback) { + callback = callback || noop; + if (test()) { + var next = _restParam(function(err, args) { + if (err) { + callback(err); + } else if (test.apply(this, args)) { + iterator(next); + } else { + callback.apply(null, [null].concat(args)); + } + }); + iterator(next); + } else { + callback(null); + } + }; + + async.doWhilst = function (iterator, test, callback) { + var calls = 0; + return async.whilst(function() { + return ++calls <= 1 || test.apply(this, arguments); + }, iterator, callback); + }; + + async.until = function (test, iterator, callback) { + return async.whilst(function() { + return !test.apply(this, arguments); + }, iterator, callback); + }; + + async.doUntil = function (iterator, test, callback) { + return async.doWhilst(iterator, function() { + return !test.apply(this, arguments); + }, callback); + }; + + async.during = function (test, iterator, callback) { + callback = callback || noop; + + var next = _restParam(function(err, args) { + if (err) { + callback(err); + } else { + args.push(check); + test.apply(this, args); + } + }); + + var check = function(err, truth) { + if (err) { + callback(err); + } else if (truth) { + iterator(next); + } else { + callback(null); + } + }; + + test(check); + }; + + async.doDuring = function (iterator, test, callback) { + var calls = 0; + async.during(function(next) { + if (calls++ < 1) { + next(null, true); + } else { + test.apply(this, arguments); + } + }, iterator, callback); + }; + + function _queue(worker, concurrency, payload) { + if (concurrency == null) { + concurrency = 1; + } + else if(concurrency === 0) { + throw new Error('Concurrency must not be zero'); + } + function _insert(q, data, pos, callback) { + if (callback != null && typeof callback !== "function") { + throw new Error("task callback must be a function"); + } + q.started = true; + if (!_isArray(data)) { + data = [data]; + } + if(data.length === 0 && q.idle()) { + // call drain immediately if there are no tasks + return async.setImmediate(function() { + q.drain(); + }); + } + _arrayEach(data, function(task) { + var item = { + data: task, + callback: callback || noop + }; + + if (pos) { + q.tasks.unshift(item); + } else { + q.tasks.push(item); + } + + if (q.tasks.length === q.concurrency) { + q.saturated(); + } + }); + async.setImmediate(q.process); + } + function _next(q, tasks) { + return function(){ + workers -= 1; + + var removed = false; + var args = arguments; + _arrayEach(tasks, function (task) { + _arrayEach(workersList, function (worker, index) { + if (worker === task && !removed) { + workersList.splice(index, 1); + removed = true; + } + }); + + task.callback.apply(task, args); + }); + if (q.tasks.length + workers === 0) { + q.drain(); + } + q.process(); + }; + } + + var workers = 0; + var workersList = []; + var q = { + tasks: [], + concurrency: concurrency, + payload: payload, + saturated: noop, + empty: noop, + drain: noop, + started: false, + paused: false, + push: function (data, callback) { + _insert(q, data, false, callback); + }, + kill: function () { + q.drain = noop; + q.tasks = []; + }, + unshift: function (data, callback) { + _insert(q, data, true, callback); + }, + process: function () { + while(!q.paused && workers < q.concurrency && q.tasks.length){ + + var tasks = q.payload ? + q.tasks.splice(0, q.payload) : + q.tasks.splice(0, q.tasks.length); + + var data = _map(tasks, function (task) { + return task.data; + }); + + if (q.tasks.length === 0) { + q.empty(); + } + workers += 1; + workersList.push(tasks[0]); + var cb = only_once(_next(q, tasks)); + worker(data, cb); + } + }, + length: function () { + return q.tasks.length; + }, + running: function () { + return workers; + }, + workersList: function () { + return workersList; + }, + idle: function() { + return q.tasks.length + workers === 0; + }, + pause: function () { + q.paused = true; + }, + resume: function () { + if (q.paused === false) { return; } + q.paused = false; + var resumeCount = Math.min(q.concurrency, q.tasks.length); + // Need to call q.process once per concurrent + // worker to preserve full concurrency after pause + for (var w = 1; w <= resumeCount; w++) { + async.setImmediate(q.process); + } + } + }; + return q; + } + + async.queue = function (worker, concurrency) { + var q = _queue(function (items, cb) { + worker(items[0], cb); + }, concurrency, 1); + + return q; + }; + + async.priorityQueue = function (worker, concurrency) { + + function _compareTasks(a, b){ + return a.priority - b.priority; + } + + function _binarySearch(sequence, item, compare) { + var beg = -1, + end = sequence.length - 1; + while (beg < end) { + var mid = beg + ((end - beg + 1) >>> 1); + if (compare(item, sequence[mid]) >= 0) { + beg = mid; + } else { + end = mid - 1; + } + } + return beg; + } + + function _insert(q, data, priority, callback) { + if (callback != null && typeof callback !== "function") { + throw new Error("task callback must be a function"); + } + q.started = true; + if (!_isArray(data)) { + data = [data]; + } + if(data.length === 0) { + // call drain immediately if there are no tasks + return async.setImmediate(function() { + q.drain(); + }); + } + _arrayEach(data, function(task) { + var item = { + data: task, + priority: priority, + callback: typeof callback === 'function' ? callback : noop + }; + + q.tasks.splice(_binarySearch(q.tasks, item, _compareTasks) + 1, 0, item); + + if (q.tasks.length === q.concurrency) { + q.saturated(); + } + async.setImmediate(q.process); + }); + } + + // Start with a normal queue + var q = async.queue(worker, concurrency); + + // Override push to accept second parameter representing priority + q.push = function (data, priority, callback) { + _insert(q, data, priority, callback); + }; + + // Remove unshift function + delete q.unshift; + + return q; + }; + + async.cargo = function (worker, payload) { + return _queue(worker, 1, payload); + }; + + function _console_fn(name) { + return _restParam(function (fn, args) { + fn.apply(null, args.concat([_restParam(function (err, args) { + if (typeof console === 'object') { + if (err) { + if (console.error) { + console.error(err); + } + } + else if (console[name]) { + _arrayEach(args, function (x) { + console[name](x); + }); + } + } + })])); + }); + } + async.log = _console_fn('log'); + async.dir = _console_fn('dir'); + /*async.info = _console_fn('info'); + async.warn = _console_fn('warn'); + async.error = _console_fn('error');*/ + + async.memoize = function (fn, hasher) { + var memo = {}; + var queues = {}; + var has = Object.prototype.hasOwnProperty; + hasher = hasher || identity; + var memoized = _restParam(function memoized(args) { + var callback = args.pop(); + var key = hasher.apply(null, args); + if (has.call(memo, key)) { + async.setImmediate(function () { + callback.apply(null, memo[key]); + }); + } + else if (has.call(queues, key)) { + queues[key].push(callback); + } + else { + queues[key] = [callback]; + fn.apply(null, args.concat([_restParam(function (args) { + memo[key] = args; + var q = queues[key]; + delete queues[key]; + for (var i = 0, l = q.length; i < l; i++) { + q[i].apply(null, args); + } + })])); + } + }); + memoized.memo = memo; + memoized.unmemoized = fn; + return memoized; + }; + + async.unmemoize = function (fn) { + return function () { + return (fn.unmemoized || fn).apply(null, arguments); + }; + }; + + function _times(mapper) { + return function (count, iterator, callback) { + mapper(_range(count), iterator, callback); + }; + } + + async.times = _times(async.map); + async.timesSeries = _times(async.mapSeries); + async.timesLimit = function (count, limit, iterator, callback) { + return async.mapLimit(_range(count), limit, iterator, callback); + }; + + async.seq = function (/* functions... */) { + var fns = arguments; + return _restParam(function (args) { + var that = this; + + var callback = args[args.length - 1]; + if (typeof callback == 'function') { + args.pop(); + } else { + callback = noop; + } + + async.reduce(fns, args, function (newargs, fn, cb) { + fn.apply(that, newargs.concat([_restParam(function (err, nextargs) { + cb(err, nextargs); + })])); + }, + function (err, results) { + callback.apply(that, [err].concat(results)); + }); + }); + }; + + async.compose = function (/* functions... */) { + return async.seq.apply(null, Array.prototype.reverse.call(arguments)); + }; + + + function _applyEach(eachfn) { + return _restParam(function(fns, args) { + var go = _restParam(function(args) { + var that = this; + var callback = args.pop(); + return eachfn(fns, function (fn, _, cb) { + fn.apply(that, args.concat([cb])); + }, + callback); + }); + if (args.length) { + return go.apply(this, args); + } + else { + return go; + } + }); + } + + async.applyEach = _applyEach(async.eachOf); + async.applyEachSeries = _applyEach(async.eachOfSeries); + + + async.forever = function (fn, callback) { + var done = only_once(callback || noop); + var task = ensureAsync(fn); + function next(err) { + if (err) { + return done(err); + } + task(next); + } + next(); + }; + + function ensureAsync(fn) { + return _restParam(function (args) { + var callback = args.pop(); + args.push(function () { + var innerArgs = arguments; + if (sync) { + async.setImmediate(function () { + callback.apply(null, innerArgs); + }); + } else { + callback.apply(null, innerArgs); + } + }); + var sync = true; + fn.apply(this, args); + sync = false; + }); + } + + async.ensureAsync = ensureAsync; + + async.constant = _restParam(function(values) { + var args = [null].concat(values); + return function (callback) { + return callback.apply(this, args); + }; + }); + + async.wrapSync = + async.asyncify = function asyncify(func) { + return _restParam(function (args) { + var callback = args.pop(); + var result; + try { + result = func.apply(this, args); + } catch (e) { + return callback(e); + } + // if result is Promise object + if (_isObject(result) && typeof result.then === "function") { + result.then(function(value) { + callback(null, value); + })["catch"](function(err) { + callback(err.message ? err : new Error(err)); + }); + } else { + callback(null, result); + } + }); + }; + + // Node.js + if (typeof module === 'object' && module.exports) { + module.exports = async; + } + // AMD / RequireJS + else if (typeof define === 'function' && define.amd) { + define([], function () { + return async; + }); + } + // included directly via +``` + +## Example + +Performing a `GET` request + +```js +const axios = require('axios'); + +// Make a request for a user with a given ID +axios.get('/user?ID=12345') + .then(function (response) { + // handle success + console.log(response); + }) + .catch(function (error) { + // handle error + console.log(error); + }) + .finally(function () { + // always executed + }); + +// Optionally the request above could also be done as +axios.get('/user', { + params: { + ID: 12345 + } + }) + .then(function (response) { + console.log(response); + }) + .catch(function (error) { + console.log(error); + }) + .then(function () { + // always executed + }); + +// Want to use async/await? Add the `async` keyword to your outer function/method. +async function getUser() { + try { + const response = await axios.get('/user?ID=12345'); + console.log(response); + } catch (error) { + console.error(error); + } +} +``` + +> **NOTE:** `async/await` is part of ECMAScript 2017 and is not supported in Internet +> Explorer and older browsers, so use with caution. + +Performing a `POST` request + +```js +axios.post('/user', { + firstName: 'Fred', + lastName: 'Flintstone' + }) + .then(function (response) { + console.log(response); + }) + .catch(function (error) { + console.log(error); + }); +``` + +Performing multiple concurrent requests + +```js +function getUserAccount() { + return axios.get('/user/12345'); +} + +function getUserPermissions() { + return axios.get('/user/12345/permissions'); +} + +axios.all([getUserAccount(), getUserPermissions()]) + .then(axios.spread(function (acct, perms) { + // Both requests are now complete + })); +``` + +## axios API + +Requests can be made by passing the relevant config to `axios`. + +##### axios(config) + +```js +// Send a POST request +axios({ + method: 'post', + url: '/user/12345', + data: { + firstName: 'Fred', + lastName: 'Flintstone' + } +}); +``` + +```js +// GET request for remote image +axios({ + method: 'get', + url: 'http://bit.ly/2mTM3nY', + responseType: 'stream' +}) + .then(function (response) { + response.data.pipe(fs.createWriteStream('ada_lovelace.jpg')) + }); +``` + +##### axios(url[, config]) + +```js +// Send a GET request (default method) +axios('/user/12345'); +``` + +### Request method aliases + +For convenience aliases have been provided for all supported request methods. + +##### axios.request(config) +##### axios.get(url[, config]) +##### axios.delete(url[, config]) +##### axios.head(url[, config]) +##### axios.options(url[, config]) +##### axios.post(url[, data[, config]]) +##### axios.put(url[, data[, config]]) +##### axios.patch(url[, data[, config]]) + +###### NOTE +When using the alias methods `url`, `method`, and `data` properties don't need to be specified in config. + +### Concurrency + +Helper functions for dealing with concurrent requests. + +##### axios.all(iterable) +##### axios.spread(callback) + +### Creating an instance + +You can create a new instance of axios with a custom config. + +##### axios.create([config]) + +```js +const instance = axios.create({ + baseURL: 'https://some-domain.com/api/', + timeout: 1000, + headers: {'X-Custom-Header': 'foobar'} +}); +``` + +### Instance methods + +The available instance methods are listed below. The specified config will be merged with the instance config. + +##### axios#request(config) +##### axios#get(url[, config]) +##### axios#delete(url[, config]) +##### axios#head(url[, config]) +##### axios#options(url[, config]) +##### axios#post(url[, data[, config]]) +##### axios#put(url[, data[, config]]) +##### axios#patch(url[, data[, config]]) +##### axios#getUri([config]) + +## Request Config + +These are the available config options for making requests. Only the `url` is required. Requests will default to `GET` if `method` is not specified. + +```js +{ + // `url` is the server URL that will be used for the request + url: '/user', + + // `method` is the request method to be used when making the request + method: 'get', // default + + // `baseURL` will be prepended to `url` unless `url` is absolute. + // It can be convenient to set `baseURL` for an instance of axios to pass relative URLs + // to methods of that instance. + baseURL: 'https://some-domain.com/api/', + + // `transformRequest` allows changes to the request data before it is sent to the server + // This is only applicable for request methods 'PUT', 'POST', 'PATCH' and 'DELETE' + // The last function in the array must return a string or an instance of Buffer, ArrayBuffer, + // FormData or Stream + // You may modify the headers object. + transformRequest: [function (data, headers) { + // Do whatever you want to transform the data + + return data; + }], + + // `transformResponse` allows changes to the response data to be made before + // it is passed to then/catch + transformResponse: [function (data) { + // Do whatever you want to transform the data + + return data; + }], + + // `headers` are custom headers to be sent + headers: {'X-Requested-With': 'XMLHttpRequest'}, + + // `params` are the URL parameters to be sent with the request + // Must be a plain object or a URLSearchParams object + params: { + ID: 12345 + }, + + // `paramsSerializer` is an optional function in charge of serializing `params` + // (e.g. https://www.npmjs.com/package/qs, http://api.jquery.com/jquery.param/) + paramsSerializer: function (params) { + return Qs.stringify(params, {arrayFormat: 'brackets'}) + }, + + // `data` is the data to be sent as the request body + // Only applicable for request methods 'PUT', 'POST', and 'PATCH' + // When no `transformRequest` is set, must be of one of the following types: + // - string, plain object, ArrayBuffer, ArrayBufferView, URLSearchParams + // - Browser only: FormData, File, Blob + // - Node only: Stream, Buffer + data: { + firstName: 'Fred' + }, + + // `timeout` specifies the number of milliseconds before the request times out. + // If the request takes longer than `timeout`, the request will be aborted. + timeout: 1000, // default is `0` (no timeout) + + // `withCredentials` indicates whether or not cross-site Access-Control requests + // should be made using credentials + withCredentials: false, // default + + // `adapter` allows custom handling of requests which makes testing easier. + // Return a promise and supply a valid response (see lib/adapters/README.md). + adapter: function (config) { + /* ... */ + }, + + // `auth` indicates that HTTP Basic auth should be used, and supplies credentials. + // This will set an `Authorization` header, overwriting any existing + // `Authorization` custom headers you have set using `headers`. + // Please note that only HTTP Basic auth is configurable through this parameter. + // For Bearer tokens and such, use `Authorization` custom headers instead. + auth: { + username: 'janedoe', + password: 's00pers3cret' + }, + + // `responseType` indicates the type of data that the server will respond with + // options are: 'arraybuffer', 'document', 'json', 'text', 'stream' + // browser only: 'blob' + responseType: 'json', // default + + // `responseEncoding` indicates encoding to use for decoding responses + // Note: Ignored for `responseType` of 'stream' or client-side requests + responseEncoding: 'utf8', // default + + // `xsrfCookieName` is the name of the cookie to use as a value for xsrf token + xsrfCookieName: 'XSRF-TOKEN', // default + + // `xsrfHeaderName` is the name of the http header that carries the xsrf token value + xsrfHeaderName: 'X-XSRF-TOKEN', // default + + // `onUploadProgress` allows handling of progress events for uploads + onUploadProgress: function (progressEvent) { + // Do whatever you want with the native progress event + }, + + // `onDownloadProgress` allows handling of progress events for downloads + onDownloadProgress: function (progressEvent) { + // Do whatever you want with the native progress event + }, + + // `maxContentLength` defines the max size of the http response content in bytes allowed + maxContentLength: 2000, + + // `validateStatus` defines whether to resolve or reject the promise for a given + // HTTP response status code. If `validateStatus` returns `true` (or is set to `null` + // or `undefined`), the promise will be resolved; otherwise, the promise will be + // rejected. + validateStatus: function (status) { + return status >= 200 && status < 300; // default + }, + + // `maxRedirects` defines the maximum number of redirects to follow in node.js. + // If set to 0, no redirects will be followed. + maxRedirects: 5, // default + + // `socketPath` defines a UNIX Socket to be used in node.js. + // e.g. '/var/run/docker.sock' to send requests to the docker daemon. + // Only either `socketPath` or `proxy` can be specified. + // If both are specified, `socketPath` is used. + socketPath: null, // default + + // `httpAgent` and `httpsAgent` define a custom agent to be used when performing http + // and https requests, respectively, in node.js. This allows options to be added like + // `keepAlive` that are not enabled by default. + httpAgent: new http.Agent({ keepAlive: true }), + httpsAgent: new https.Agent({ keepAlive: true }), + + // 'proxy' defines the hostname and port of the proxy server. + // You can also define your proxy using the conventional `http_proxy` and + // `https_proxy` environment variables. If you are using environment variables + // for your proxy configuration, you can also define a `no_proxy` environment + // variable as a comma-separated list of domains that should not be proxied. + // Use `false` to disable proxies, ignoring environment variables. + // `auth` indicates that HTTP Basic auth should be used to connect to the proxy, and + // supplies credentials. + // This will set an `Proxy-Authorization` header, overwriting any existing + // `Proxy-Authorization` custom headers you have set using `headers`. + proxy: { + host: '127.0.0.1', + port: 9000, + auth: { + username: 'mikeymike', + password: 'rapunz3l' + } + }, + + // `cancelToken` specifies a cancel token that can be used to cancel the request + // (see Cancellation section below for details) + cancelToken: new CancelToken(function (cancel) { + }) +} +``` + +## Response Schema + +The response for a request contains the following information. + +```js +{ + // `data` is the response that was provided by the server + data: {}, + + // `status` is the HTTP status code from the server response + status: 200, + + // `statusText` is the HTTP status message from the server response + statusText: 'OK', + + // `headers` the headers that the server responded with + // All header names are lower cased + headers: {}, + + // `config` is the config that was provided to `axios` for the request + config: {}, + + // `request` is the request that generated this response + // It is the last ClientRequest instance in node.js (in redirects) + // and an XMLHttpRequest instance the browser + request: {} +} +``` + +When using `then`, you will receive the response as follows: + +```js +axios.get('/user/12345') + .then(function (response) { + console.log(response.data); + console.log(response.status); + console.log(response.statusText); + console.log(response.headers); + console.log(response.config); + }); +``` + +When using `catch`, or passing a [rejection callback](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise/then) as second parameter of `then`, the response will be available through the `error` object as explained in the [Handling Errors](#handling-errors) section. + +## Config Defaults + +You can specify config defaults that will be applied to every request. + +### Global axios defaults + +```js +axios.defaults.baseURL = 'https://api.example.com'; +axios.defaults.headers.common['Authorization'] = AUTH_TOKEN; +axios.defaults.headers.post['Content-Type'] = 'application/x-www-form-urlencoded'; +``` + +### Custom instance defaults + +```js +// Set config defaults when creating the instance +const instance = axios.create({ + baseURL: 'https://api.example.com' +}); + +// Alter defaults after instance has been created +instance.defaults.headers.common['Authorization'] = AUTH_TOKEN; +``` + +### Config order of precedence + +Config will be merged with an order of precedence. The order is library defaults found in [lib/defaults.js](https://github.com/axios/axios/blob/master/lib/defaults.js#L28), then `defaults` property of the instance, and finally `config` argument for the request. The latter will take precedence over the former. Here's an example. + +```js +// Create an instance using the config defaults provided by the library +// At this point the timeout config value is `0` as is the default for the library +const instance = axios.create(); + +// Override timeout default for the library +// Now all requests using this instance will wait 2.5 seconds before timing out +instance.defaults.timeout = 2500; + +// Override timeout for this request as it's known to take a long time +instance.get('/longRequest', { + timeout: 5000 +}); +``` + +## Interceptors + +You can intercept requests or responses before they are handled by `then` or `catch`. + +```js +// Add a request interceptor +axios.interceptors.request.use(function (config) { + // Do something before request is sent + return config; + }, function (error) { + // Do something with request error + return Promise.reject(error); + }); + +// Add a response interceptor +axios.interceptors.response.use(function (response) { + // Do something with response data + return response; + }, function (error) { + // Do something with response error + return Promise.reject(error); + }); +``` + +If you may need to remove an interceptor later you can. + +```js +const myInterceptor = axios.interceptors.request.use(function () {/*...*/}); +axios.interceptors.request.eject(myInterceptor); +``` + +You can add interceptors to a custom instance of axios. + +```js +const instance = axios.create(); +instance.interceptors.request.use(function () {/*...*/}); +``` + +## Handling Errors + +```js +axios.get('/user/12345') + .catch(function (error) { + if (error.response) { + // The request was made and the server responded with a status code + // that falls out of the range of 2xx + console.log(error.response.data); + console.log(error.response.status); + console.log(error.response.headers); + } else if (error.request) { + // The request was made but no response was received + // `error.request` is an instance of XMLHttpRequest in the browser and an instance of + // http.ClientRequest in node.js + console.log(error.request); + } else { + // Something happened in setting up the request that triggered an Error + console.log('Error', error.message); + } + console.log(error.config); + }); +``` + +You can define a custom HTTP status code error range using the `validateStatus` config option. + +```js +axios.get('/user/12345', { + validateStatus: function (status) { + return status < 500; // Reject only if the status code is greater than or equal to 500 + } +}) +``` + +## Cancellation + +You can cancel a request using a *cancel token*. + +> The axios cancel token API is based on the withdrawn [cancelable promises proposal](https://github.com/tc39/proposal-cancelable-promises). + +You can create a cancel token using the `CancelToken.source` factory as shown below: + +```js +const CancelToken = axios.CancelToken; +const source = CancelToken.source(); + +axios.get('/user/12345', { + cancelToken: source.token +}).catch(function (thrown) { + if (axios.isCancel(thrown)) { + console.log('Request canceled', thrown.message); + } else { + // handle error + } +}); + +axios.post('/user/12345', { + name: 'new name' +}, { + cancelToken: source.token +}) + +// cancel the request (the message parameter is optional) +source.cancel('Operation canceled by the user.'); +``` + +You can also create a cancel token by passing an executor function to the `CancelToken` constructor: + +```js +const CancelToken = axios.CancelToken; +let cancel; + +axios.get('/user/12345', { + cancelToken: new CancelToken(function executor(c) { + // An executor function receives a cancel function as a parameter + cancel = c; + }) +}); + +// cancel the request +cancel(); +``` + +> Note: you can cancel several requests with the same cancel token. + +## Using application/x-www-form-urlencoded format + +By default, axios serializes JavaScript objects to `JSON`. To send data in the `application/x-www-form-urlencoded` format instead, you can use one of the following options. + +### Browser + +In a browser, you can use the [`URLSearchParams`](https://developer.mozilla.org/en-US/docs/Web/API/URLSearchParams) API as follows: + +```js +const params = new URLSearchParams(); +params.append('param1', 'value1'); +params.append('param2', 'value2'); +axios.post('/foo', params); +``` + +> Note that `URLSearchParams` is not supported by all browsers (see [caniuse.com](http://www.caniuse.com/#feat=urlsearchparams)), but there is a [polyfill](https://github.com/WebReflection/url-search-params) available (make sure to polyfill the global environment). + +Alternatively, you can encode data using the [`qs`](https://github.com/ljharb/qs) library: + +```js +const qs = require('qs'); +axios.post('/foo', qs.stringify({ 'bar': 123 })); +``` + +Or in another way (ES6), + +```js +import qs from 'qs'; +const data = { 'bar': 123 }; +const options = { + method: 'POST', + headers: { 'content-type': 'application/x-www-form-urlencoded' }, + data: qs.stringify(data), + url, +}; +axios(options); +``` + +### Node.js + +In node.js, you can use the [`querystring`](https://nodejs.org/api/querystring.html) module as follows: + +```js +const querystring = require('querystring'); +axios.post('http://something.com/', querystring.stringify({ foo: 'bar' })); +``` + +You can also use the [`qs`](https://github.com/ljharb/qs) library. + +###### NOTE +The `qs` library is preferable if you need to stringify nested objects, as the `querystring` method has known issues with that use case (https://github.com/nodejs/node-v0.x-archive/issues/1665). + +## Semver + +Until axios reaches a `1.0` release, breaking changes will be released with a new minor version. For example `0.5.1`, and `0.5.4` will have the same API, but `0.6.0` will have breaking changes. + +## Promises + +axios depends on a native ES6 Promise implementation to be [supported](http://caniuse.com/promises). +If your environment doesn't support ES6 Promises, you can [polyfill](https://github.com/jakearchibald/es6-promise). + +## TypeScript +axios includes [TypeScript](http://typescriptlang.org) definitions. +```typescript +import axios from 'axios'; +axios.get('/user?ID=12345'); +``` + +## Resources + +* [Changelog](https://github.com/axios/axios/blob/master/CHANGELOG.md) +* [Upgrade Guide](https://github.com/axios/axios/blob/master/UPGRADE_GUIDE.md) +* [Ecosystem](https://github.com/axios/axios/blob/master/ECOSYSTEM.md) +* [Contributing Guide](https://github.com/axios/axios/blob/master/CONTRIBUTING.md) +* [Code of Conduct](https://github.com/axios/axios/blob/master/CODE_OF_CONDUCT.md) + +## Credits + +axios is heavily inspired by the [$http service](https://docs.angularjs.org/api/ng/service/$http) provided in [Angular](https://angularjs.org/). Ultimately axios is an effort to provide a standalone `$http`-like service for use outside of Angular. + +## License + +MIT diff --git a/node_modules/axios/UPGRADE_GUIDE.md b/node_modules/axios/UPGRADE_GUIDE.md new file mode 100644 index 0000000000..eedb049255 --- /dev/null +++ b/node_modules/axios/UPGRADE_GUIDE.md @@ -0,0 +1,162 @@ +# Upgrade Guide + +### 0.15.x -> 0.16.0 + +#### `Promise` Type Declarations + +The `Promise` type declarations have been removed from the axios typings in favor of the built-in type declarations. If you use axios in a TypeScript project that targets `ES5`, please make sure to include the `es2015.promise` lib. Please see [this post](https://blog.mariusschulz.com/2016/11/25/typescript-2-0-built-in-type-declarations) for details. + +### 0.13.x -> 0.14.0 + +#### TypeScript Definitions + +The axios TypeScript definitions have been updated to match the axios API and use the ES2015 module syntax. + +Please use the following `import` statement to import axios in TypeScript: + +```typescript +import axios from 'axios'; + +axios.get('/foo') + .then(response => console.log(response)) + .catch(error => console.log(error)); +``` + +#### `agent` Config Option + +The `agent` config option has been replaced with two new options: `httpAgent` and `httpsAgent`. Please use them instead. + +```js +{ + // Define a custom agent for HTTP + httpAgent: new http.Agent({ keepAlive: true }), + // Define a custom agent for HTTPS + httpsAgent: new https.Agent({ keepAlive: true }) +} +``` + +#### `progress` Config Option + +The `progress` config option has been replaced with the `onUploadProgress` and `onDownloadProgress` options. + +```js +{ + // Define a handler for upload progress events + onUploadProgress: function (progressEvent) { + // ... + }, + + // Define a handler for download progress events + onDownloadProgress: function (progressEvent) { + // ... + } +} +``` + +### 0.12.x -> 0.13.0 + +The `0.13.0` release contains several changes to custom adapters and error handling. + +#### Error Handling + +Previous to this release an error could either be a server response with bad status code or an actual `Error`. With this release Promise will always reject with an `Error`. In the case that a response was received, the `Error` will also include the response. + +```js +axios.get('/user/12345') + .catch((error) => { + console.log(error.message); + console.log(error.code); // Not always specified + console.log(error.config); // The config that was used to make the request + console.log(error.response); // Only available if response was received from the server + }); +``` + +#### Request Adapters + +This release changes a few things about how request adapters work. Please take note if you are using your own custom adapter. + +1. Response transformer is now called outside of adapter. +2. Request adapter returns a `Promise`. + +This means that you no longer need to invoke `transformData` on response data. You will also no longer receive `resolve` and `reject` as arguments in your adapter. + +Previous code: + +```js +function myAdapter(resolve, reject, config) { + var response = { + data: transformData( + responseData, + responseHeaders, + config.transformResponse + ), + status: request.status, + statusText: request.statusText, + headers: responseHeaders + }; + settle(resolve, reject, response); +} +``` + +New code: + +```js +function myAdapter(config) { + return new Promise(function (resolve, reject) { + var response = { + data: responseData, + status: request.status, + statusText: request.statusText, + headers: responseHeaders + }; + settle(resolve, reject, response); + }); +} +``` + +See the related commits for more details: +- [Response transformers](https://github.com/axios/axios/commit/10eb23865101f9347570552c04e9d6211376e25e) +- [Request adapter Promise](https://github.com/axios/axios/commit/157efd5615890301824e3121cc6c9d2f9b21f94a) + +### 0.5.x -> 0.6.0 + +The `0.6.0` release contains mostly bug fixes, but there are a couple things to be aware of when upgrading. + +#### ES6 Promise Polyfill + +Up until the `0.6.0` release ES6 `Promise` was being polyfilled using [es6-promise](https://github.com/jakearchibald/es6-promise). With this release, the polyfill has been removed, and you will need to supply it yourself if your environment needs it. + +```js +require('es6-promise').polyfill(); +var axios = require('axios'); +``` + +This will polyfill the global environment, and only needs to be done once. + +#### `axios.success`/`axios.error` + +The `success`, and `error` aliases were deprectated in [0.4.0](https://github.com/axios/axios/blob/master/CHANGELOG.md#040-oct-03-2014). As of this release they have been removed entirely. Instead please use `axios.then`, and `axios.catch` respectively. + +```js +axios.get('some/url') + .then(function (res) { + /* ... */ + }) + .catch(function (err) { + /* ... */ + }); +``` + +#### UMD + +Previous versions of axios shipped with an AMD, CommonJS, and Global build. This has all been rolled into a single UMD build. + +```js +// AMD +require(['bower_components/axios/dist/axios'], function (axios) { + /* ... */ +}); + +// CommonJS +var axios = require('axios/dist/axios'); +``` diff --git a/node_modules/axios/dist/axios.js b/node_modules/axios/dist/axios.js new file mode 100644 index 0000000000..5cef419c2c --- /dev/null +++ b/node_modules/axios/dist/axios.js @@ -0,0 +1,1668 @@ +/* axios v0.19.0 | (c) 2019 by Matt Zabriskie */ +(function webpackUniversalModuleDefinition(root, factory) { + if(typeof exports === 'object' && typeof module === 'object') + module.exports = factory(); + else if(typeof define === 'function' && define.amd) + define([], factory); + else if(typeof exports === 'object') + exports["axios"] = factory(); + else + root["axios"] = factory(); +})(this, function() { +return /******/ (function(modules) { // webpackBootstrap +/******/ // The module cache +/******/ var installedModules = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ +/******/ // Check if module is in cache +/******/ if(installedModules[moduleId]) +/******/ return installedModules[moduleId].exports; +/******/ +/******/ // Create a new module (and put it into the cache) +/******/ var module = installedModules[moduleId] = { +/******/ exports: {}, +/******/ id: moduleId, +/******/ loaded: false +/******/ }; +/******/ +/******/ // Execute the module function +/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); +/******/ +/******/ // Flag the module as loaded +/******/ module.loaded = true; +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = modules; +/******/ +/******/ // expose the module cache +/******/ __webpack_require__.c = installedModules; +/******/ +/******/ // __webpack_public_path__ +/******/ __webpack_require__.p = ""; +/******/ +/******/ // Load entry module and return exports +/******/ return __webpack_require__(0); +/******/ }) +/************************************************************************/ +/******/ ([ +/* 0 */ +/***/ (function(module, exports, __webpack_require__) { + + module.exports = __webpack_require__(1); + +/***/ }), +/* 1 */ +/***/ (function(module, exports, __webpack_require__) { + + 'use strict'; + + var utils = __webpack_require__(2); + var bind = __webpack_require__(3); + var Axios = __webpack_require__(5); + var mergeConfig = __webpack_require__(22); + var defaults = __webpack_require__(11); + + /** + * Create an instance of Axios + * + * @param {Object} defaultConfig The default config for the instance + * @return {Axios} A new instance of Axios + */ + function createInstance(defaultConfig) { + var context = new Axios(defaultConfig); + var instance = bind(Axios.prototype.request, context); + + // Copy axios.prototype to instance + utils.extend(instance, Axios.prototype, context); + + // Copy context to instance + utils.extend(instance, context); + + return instance; + } + + // Create the default instance to be exported + var axios = createInstance(defaults); + + // Expose Axios class to allow class inheritance + axios.Axios = Axios; + + // Factory for creating new instances + axios.create = function create(instanceConfig) { + return createInstance(mergeConfig(axios.defaults, instanceConfig)); + }; + + // Expose Cancel & CancelToken + axios.Cancel = __webpack_require__(23); + axios.CancelToken = __webpack_require__(24); + axios.isCancel = __webpack_require__(10); + + // Expose all/spread + axios.all = function all(promises) { + return Promise.all(promises); + }; + axios.spread = __webpack_require__(25); + + module.exports = axios; + + // Allow use of default import syntax in TypeScript + module.exports.default = axios; + + +/***/ }), +/* 2 */ +/***/ (function(module, exports, __webpack_require__) { + + 'use strict'; + + var bind = __webpack_require__(3); + var isBuffer = __webpack_require__(4); + + /*global toString:true*/ + + // utils is a library of generic helper functions non-specific to axios + + var toString = Object.prototype.toString; + + /** + * Determine if a value is an Array + * + * @param {Object} val The value to test + * @returns {boolean} True if value is an Array, otherwise false + */ + function isArray(val) { + return toString.call(val) === '[object Array]'; + } + + /** + * Determine if a value is an ArrayBuffer + * + * @param {Object} val The value to test + * @returns {boolean} True if value is an ArrayBuffer, otherwise false + */ + function isArrayBuffer(val) { + return toString.call(val) === '[object ArrayBuffer]'; + } + + /** + * Determine if a value is a FormData + * + * @param {Object} val The value to test + * @returns {boolean} True if value is an FormData, otherwise false + */ + function isFormData(val) { + return (typeof FormData !== 'undefined') && (val instanceof FormData); + } + + /** + * Determine if a value is a view on an ArrayBuffer + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a view on an ArrayBuffer, otherwise false + */ + function isArrayBufferView(val) { + var result; + if ((typeof ArrayBuffer !== 'undefined') && (ArrayBuffer.isView)) { + result = ArrayBuffer.isView(val); + } else { + result = (val) && (val.buffer) && (val.buffer instanceof ArrayBuffer); + } + return result; + } + + /** + * Determine if a value is a String + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a String, otherwise false + */ + function isString(val) { + return typeof val === 'string'; + } + + /** + * Determine if a value is a Number + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a Number, otherwise false + */ + function isNumber(val) { + return typeof val === 'number'; + } + + /** + * Determine if a value is undefined + * + * @param {Object} val The value to test + * @returns {boolean} True if the value is undefined, otherwise false + */ + function isUndefined(val) { + return typeof val === 'undefined'; + } + + /** + * Determine if a value is an Object + * + * @param {Object} val The value to test + * @returns {boolean} True if value is an Object, otherwise false + */ + function isObject(val) { + return val !== null && typeof val === 'object'; + } + + /** + * Determine if a value is a Date + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a Date, otherwise false + */ + function isDate(val) { + return toString.call(val) === '[object Date]'; + } + + /** + * Determine if a value is a File + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a File, otherwise false + */ + function isFile(val) { + return toString.call(val) === '[object File]'; + } + + /** + * Determine if a value is a Blob + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a Blob, otherwise false + */ + function isBlob(val) { + return toString.call(val) === '[object Blob]'; + } + + /** + * Determine if a value is a Function + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a Function, otherwise false + */ + function isFunction(val) { + return toString.call(val) === '[object Function]'; + } + + /** + * Determine if a value is a Stream + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a Stream, otherwise false + */ + function isStream(val) { + return isObject(val) && isFunction(val.pipe); + } + + /** + * Determine if a value is a URLSearchParams object + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a URLSearchParams object, otherwise false + */ + function isURLSearchParams(val) { + return typeof URLSearchParams !== 'undefined' && val instanceof URLSearchParams; + } + + /** + * Trim excess whitespace off the beginning and end of a string + * + * @param {String} str The String to trim + * @returns {String} The String freed of excess whitespace + */ + function trim(str) { + return str.replace(/^\s*/, '').replace(/\s*$/, ''); + } + + /** + * Determine if we're running in a standard browser environment + * + * This allows axios to run in a web worker, and react-native. + * Both environments support XMLHttpRequest, but not fully standard globals. + * + * web workers: + * typeof window -> undefined + * typeof document -> undefined + * + * react-native: + * navigator.product -> 'ReactNative' + * nativescript + * navigator.product -> 'NativeScript' or 'NS' + */ + function isStandardBrowserEnv() { + if (typeof navigator !== 'undefined' && (navigator.product === 'ReactNative' || + navigator.product === 'NativeScript' || + navigator.product === 'NS')) { + return false; + } + return ( + typeof window !== 'undefined' && + typeof document !== 'undefined' + ); + } + + /** + * Iterate over an Array or an Object invoking a function for each item. + * + * If `obj` is an Array callback will be called passing + * the value, index, and complete array for each item. + * + * If 'obj' is an Object callback will be called passing + * the value, key, and complete object for each property. + * + * @param {Object|Array} obj The object to iterate + * @param {Function} fn The callback to invoke for each item + */ + function forEach(obj, fn) { + // Don't bother if no value provided + if (obj === null || typeof obj === 'undefined') { + return; + } + + // Force an array if not already something iterable + if (typeof obj !== 'object') { + /*eslint no-param-reassign:0*/ + obj = [obj]; + } + + if (isArray(obj)) { + // Iterate over array values + for (var i = 0, l = obj.length; i < l; i++) { + fn.call(null, obj[i], i, obj); + } + } else { + // Iterate over object keys + for (var key in obj) { + if (Object.prototype.hasOwnProperty.call(obj, key)) { + fn.call(null, obj[key], key, obj); + } + } + } + } + + /** + * Accepts varargs expecting each argument to be an object, then + * immutably merges the properties of each object and returns result. + * + * When multiple objects contain the same key the later object in + * the arguments list will take precedence. + * + * Example: + * + * ```js + * var result = merge({foo: 123}, {foo: 456}); + * console.log(result.foo); // outputs 456 + * ``` + * + * @param {Object} obj1 Object to merge + * @returns {Object} Result of all merge properties + */ + function merge(/* obj1, obj2, obj3, ... */) { + var result = {}; + function assignValue(val, key) { + if (typeof result[key] === 'object' && typeof val === 'object') { + result[key] = merge(result[key], val); + } else { + result[key] = val; + } + } + + for (var i = 0, l = arguments.length; i < l; i++) { + forEach(arguments[i], assignValue); + } + return result; + } + + /** + * Function equal to merge with the difference being that no reference + * to original objects is kept. + * + * @see merge + * @param {Object} obj1 Object to merge + * @returns {Object} Result of all merge properties + */ + function deepMerge(/* obj1, obj2, obj3, ... */) { + var result = {}; + function assignValue(val, key) { + if (typeof result[key] === 'object' && typeof val === 'object') { + result[key] = deepMerge(result[key], val); + } else if (typeof val === 'object') { + result[key] = deepMerge({}, val); + } else { + result[key] = val; + } + } + + for (var i = 0, l = arguments.length; i < l; i++) { + forEach(arguments[i], assignValue); + } + return result; + } + + /** + * Extends object a by mutably adding to it the properties of object b. + * + * @param {Object} a The object to be extended + * @param {Object} b The object to copy properties from + * @param {Object} thisArg The object to bind function to + * @return {Object} The resulting value of object a + */ + function extend(a, b, thisArg) { + forEach(b, function assignValue(val, key) { + if (thisArg && typeof val === 'function') { + a[key] = bind(val, thisArg); + } else { + a[key] = val; + } + }); + return a; + } + + module.exports = { + isArray: isArray, + isArrayBuffer: isArrayBuffer, + isBuffer: isBuffer, + isFormData: isFormData, + isArrayBufferView: isArrayBufferView, + isString: isString, + isNumber: isNumber, + isObject: isObject, + isUndefined: isUndefined, + isDate: isDate, + isFile: isFile, + isBlob: isBlob, + isFunction: isFunction, + isStream: isStream, + isURLSearchParams: isURLSearchParams, + isStandardBrowserEnv: isStandardBrowserEnv, + forEach: forEach, + merge: merge, + deepMerge: deepMerge, + extend: extend, + trim: trim + }; + + +/***/ }), +/* 3 */ +/***/ (function(module, exports) { + + 'use strict'; + + module.exports = function bind(fn, thisArg) { + return function wrap() { + var args = new Array(arguments.length); + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i]; + } + return fn.apply(thisArg, args); + }; + }; + + +/***/ }), +/* 4 */ +/***/ (function(module, exports) { + + /*! + * Determine if an object is a Buffer + * + * @author Feross Aboukhadijeh + * @license MIT + */ + + module.exports = function isBuffer (obj) { + return obj != null && obj.constructor != null && + typeof obj.constructor.isBuffer === 'function' && obj.constructor.isBuffer(obj) + } + + +/***/ }), +/* 5 */ +/***/ (function(module, exports, __webpack_require__) { + + 'use strict'; + + var utils = __webpack_require__(2); + var buildURL = __webpack_require__(6); + var InterceptorManager = __webpack_require__(7); + var dispatchRequest = __webpack_require__(8); + var mergeConfig = __webpack_require__(22); + + /** + * Create a new instance of Axios + * + * @param {Object} instanceConfig The default config for the instance + */ + function Axios(instanceConfig) { + this.defaults = instanceConfig; + this.interceptors = { + request: new InterceptorManager(), + response: new InterceptorManager() + }; + } + + /** + * Dispatch a request + * + * @param {Object} config The config specific for this request (merged with this.defaults) + */ + Axios.prototype.request = function request(config) { + /*eslint no-param-reassign:0*/ + // Allow for axios('example/url'[, config]) a la fetch API + if (typeof config === 'string') { + config = arguments[1] || {}; + config.url = arguments[0]; + } else { + config = config || {}; + } + + config = mergeConfig(this.defaults, config); + config.method = config.method ? config.method.toLowerCase() : 'get'; + + // Hook up interceptors middleware + var chain = [dispatchRequest, undefined]; + var promise = Promise.resolve(config); + + this.interceptors.request.forEach(function unshiftRequestInterceptors(interceptor) { + chain.unshift(interceptor.fulfilled, interceptor.rejected); + }); + + this.interceptors.response.forEach(function pushResponseInterceptors(interceptor) { + chain.push(interceptor.fulfilled, interceptor.rejected); + }); + + while (chain.length) { + promise = promise.then(chain.shift(), chain.shift()); + } + + return promise; + }; + + Axios.prototype.getUri = function getUri(config) { + config = mergeConfig(this.defaults, config); + return buildURL(config.url, config.params, config.paramsSerializer).replace(/^\?/, ''); + }; + + // Provide aliases for supported request methods + utils.forEach(['delete', 'get', 'head', 'options'], function forEachMethodNoData(method) { + /*eslint func-names:0*/ + Axios.prototype[method] = function(url, config) { + return this.request(utils.merge(config || {}, { + method: method, + url: url + })); + }; + }); + + utils.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method) { + /*eslint func-names:0*/ + Axios.prototype[method] = function(url, data, config) { + return this.request(utils.merge(config || {}, { + method: method, + url: url, + data: data + })); + }; + }); + + module.exports = Axios; + + +/***/ }), +/* 6 */ +/***/ (function(module, exports, __webpack_require__) { + + 'use strict'; + + var utils = __webpack_require__(2); + + function encode(val) { + return encodeURIComponent(val). + replace(/%40/gi, '@'). + replace(/%3A/gi, ':'). + replace(/%24/g, '$'). + replace(/%2C/gi, ','). + replace(/%20/g, '+'). + replace(/%5B/gi, '['). + replace(/%5D/gi, ']'); + } + + /** + * Build a URL by appending params to the end + * + * @param {string} url The base of the url (e.g., http://www.google.com) + * @param {object} [params] The params to be appended + * @returns {string} The formatted url + */ + module.exports = function buildURL(url, params, paramsSerializer) { + /*eslint no-param-reassign:0*/ + if (!params) { + return url; + } + + var serializedParams; + if (paramsSerializer) { + serializedParams = paramsSerializer(params); + } else if (utils.isURLSearchParams(params)) { + serializedParams = params.toString(); + } else { + var parts = []; + + utils.forEach(params, function serialize(val, key) { + if (val === null || typeof val === 'undefined') { + return; + } + + if (utils.isArray(val)) { + key = key + '[]'; + } else { + val = [val]; + } + + utils.forEach(val, function parseValue(v) { + if (utils.isDate(v)) { + v = v.toISOString(); + } else if (utils.isObject(v)) { + v = JSON.stringify(v); + } + parts.push(encode(key) + '=' + encode(v)); + }); + }); + + serializedParams = parts.join('&'); + } + + if (serializedParams) { + var hashmarkIndex = url.indexOf('#'); + if (hashmarkIndex !== -1) { + url = url.slice(0, hashmarkIndex); + } + + url += (url.indexOf('?') === -1 ? '?' : '&') + serializedParams; + } + + return url; + }; + + +/***/ }), +/* 7 */ +/***/ (function(module, exports, __webpack_require__) { + + 'use strict'; + + var utils = __webpack_require__(2); + + function InterceptorManager() { + this.handlers = []; + } + + /** + * Add a new interceptor to the stack + * + * @param {Function} fulfilled The function to handle `then` for a `Promise` + * @param {Function} rejected The function to handle `reject` for a `Promise` + * + * @return {Number} An ID used to remove interceptor later + */ + InterceptorManager.prototype.use = function use(fulfilled, rejected) { + this.handlers.push({ + fulfilled: fulfilled, + rejected: rejected + }); + return this.handlers.length - 1; + }; + + /** + * Remove an interceptor from the stack + * + * @param {Number} id The ID that was returned by `use` + */ + InterceptorManager.prototype.eject = function eject(id) { + if (this.handlers[id]) { + this.handlers[id] = null; + } + }; + + /** + * Iterate over all the registered interceptors + * + * This method is particularly useful for skipping over any + * interceptors that may have become `null` calling `eject`. + * + * @param {Function} fn The function to call for each interceptor + */ + InterceptorManager.prototype.forEach = function forEach(fn) { + utils.forEach(this.handlers, function forEachHandler(h) { + if (h !== null) { + fn(h); + } + }); + }; + + module.exports = InterceptorManager; + + +/***/ }), +/* 8 */ +/***/ (function(module, exports, __webpack_require__) { + + 'use strict'; + + var utils = __webpack_require__(2); + var transformData = __webpack_require__(9); + var isCancel = __webpack_require__(10); + var defaults = __webpack_require__(11); + var isAbsoluteURL = __webpack_require__(20); + var combineURLs = __webpack_require__(21); + + /** + * Throws a `Cancel` if cancellation has been requested. + */ + function throwIfCancellationRequested(config) { + if (config.cancelToken) { + config.cancelToken.throwIfRequested(); + } + } + + /** + * Dispatch a request to the server using the configured adapter. + * + * @param {object} config The config that is to be used for the request + * @returns {Promise} The Promise to be fulfilled + */ + module.exports = function dispatchRequest(config) { + throwIfCancellationRequested(config); + + // Support baseURL config + if (config.baseURL && !isAbsoluteURL(config.url)) { + config.url = combineURLs(config.baseURL, config.url); + } + + // Ensure headers exist + config.headers = config.headers || {}; + + // Transform request data + config.data = transformData( + config.data, + config.headers, + config.transformRequest + ); + + // Flatten headers + config.headers = utils.merge( + config.headers.common || {}, + config.headers[config.method] || {}, + config.headers || {} + ); + + utils.forEach( + ['delete', 'get', 'head', 'post', 'put', 'patch', 'common'], + function cleanHeaderConfig(method) { + delete config.headers[method]; + } + ); + + var adapter = config.adapter || defaults.adapter; + + return adapter(config).then(function onAdapterResolution(response) { + throwIfCancellationRequested(config); + + // Transform response data + response.data = transformData( + response.data, + response.headers, + config.transformResponse + ); + + return response; + }, function onAdapterRejection(reason) { + if (!isCancel(reason)) { + throwIfCancellationRequested(config); + + // Transform response data + if (reason && reason.response) { + reason.response.data = transformData( + reason.response.data, + reason.response.headers, + config.transformResponse + ); + } + } + + return Promise.reject(reason); + }); + }; + + +/***/ }), +/* 9 */ +/***/ (function(module, exports, __webpack_require__) { + + 'use strict'; + + var utils = __webpack_require__(2); + + /** + * Transform the data for a request or a response + * + * @param {Object|String} data The data to be transformed + * @param {Array} headers The headers for the request or response + * @param {Array|Function} fns A single function or Array of functions + * @returns {*} The resulting transformed data + */ + module.exports = function transformData(data, headers, fns) { + /*eslint no-param-reassign:0*/ + utils.forEach(fns, function transform(fn) { + data = fn(data, headers); + }); + + return data; + }; + + +/***/ }), +/* 10 */ +/***/ (function(module, exports) { + + 'use strict'; + + module.exports = function isCancel(value) { + return !!(value && value.__CANCEL__); + }; + + +/***/ }), +/* 11 */ +/***/ (function(module, exports, __webpack_require__) { + + 'use strict'; + + var utils = __webpack_require__(2); + var normalizeHeaderName = __webpack_require__(12); + + var DEFAULT_CONTENT_TYPE = { + 'Content-Type': 'application/x-www-form-urlencoded' + }; + + function setContentTypeIfUnset(headers, value) { + if (!utils.isUndefined(headers) && utils.isUndefined(headers['Content-Type'])) { + headers['Content-Type'] = value; + } + } + + function getDefaultAdapter() { + var adapter; + // Only Node.JS has a process variable that is of [[Class]] process + if (typeof process !== 'undefined' && Object.prototype.toString.call(process) === '[object process]') { + // For node use HTTP adapter + adapter = __webpack_require__(13); + } else if (typeof XMLHttpRequest !== 'undefined') { + // For browsers use XHR adapter + adapter = __webpack_require__(13); + } + return adapter; + } + + var defaults = { + adapter: getDefaultAdapter(), + + transformRequest: [function transformRequest(data, headers) { + normalizeHeaderName(headers, 'Accept'); + normalizeHeaderName(headers, 'Content-Type'); + if (utils.isFormData(data) || + utils.isArrayBuffer(data) || + utils.isBuffer(data) || + utils.isStream(data) || + utils.isFile(data) || + utils.isBlob(data) + ) { + return data; + } + if (utils.isArrayBufferView(data)) { + return data.buffer; + } + if (utils.isURLSearchParams(data)) { + setContentTypeIfUnset(headers, 'application/x-www-form-urlencoded;charset=utf-8'); + return data.toString(); + } + if (utils.isObject(data)) { + setContentTypeIfUnset(headers, 'application/json;charset=utf-8'); + return JSON.stringify(data); + } + return data; + }], + + transformResponse: [function transformResponse(data) { + /*eslint no-param-reassign:0*/ + if (typeof data === 'string') { + try { + data = JSON.parse(data); + } catch (e) { /* Ignore */ } + } + return data; + }], + + /** + * A timeout in milliseconds to abort a request. If set to 0 (default) a + * timeout is not created. + */ + timeout: 0, + + xsrfCookieName: 'XSRF-TOKEN', + xsrfHeaderName: 'X-XSRF-TOKEN', + + maxContentLength: -1, + + validateStatus: function validateStatus(status) { + return status >= 200 && status < 300; + } + }; + + defaults.headers = { + common: { + 'Accept': 'application/json, text/plain, */*' + } + }; + + utils.forEach(['delete', 'get', 'head'], function forEachMethodNoData(method) { + defaults.headers[method] = {}; + }); + + utils.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method) { + defaults.headers[method] = utils.merge(DEFAULT_CONTENT_TYPE); + }); + + module.exports = defaults; + + +/***/ }), +/* 12 */ +/***/ (function(module, exports, __webpack_require__) { + + 'use strict'; + + var utils = __webpack_require__(2); + + module.exports = function normalizeHeaderName(headers, normalizedName) { + utils.forEach(headers, function processHeader(value, name) { + if (name !== normalizedName && name.toUpperCase() === normalizedName.toUpperCase()) { + headers[normalizedName] = value; + delete headers[name]; + } + }); + }; + + +/***/ }), +/* 13 */ +/***/ (function(module, exports, __webpack_require__) { + + 'use strict'; + + var utils = __webpack_require__(2); + var settle = __webpack_require__(14); + var buildURL = __webpack_require__(6); + var parseHeaders = __webpack_require__(17); + var isURLSameOrigin = __webpack_require__(18); + var createError = __webpack_require__(15); + + module.exports = function xhrAdapter(config) { + return new Promise(function dispatchXhrRequest(resolve, reject) { + var requestData = config.data; + var requestHeaders = config.headers; + + if (utils.isFormData(requestData)) { + delete requestHeaders['Content-Type']; // Let the browser set it + } + + var request = new XMLHttpRequest(); + + // HTTP basic authentication + if (config.auth) { + var username = config.auth.username || ''; + var password = config.auth.password || ''; + requestHeaders.Authorization = 'Basic ' + btoa(username + ':' + password); + } + + request.open(config.method.toUpperCase(), buildURL(config.url, config.params, config.paramsSerializer), true); + + // Set the request timeout in MS + request.timeout = config.timeout; + + // Listen for ready state + request.onreadystatechange = function handleLoad() { + if (!request || request.readyState !== 4) { + return; + } + + // The request errored out and we didn't get a response, this will be + // handled by onerror instead + // With one exception: request that using file: protocol, most browsers + // will return status as 0 even though it's a successful request + if (request.status === 0 && !(request.responseURL && request.responseURL.indexOf('file:') === 0)) { + return; + } + + // Prepare the response + var responseHeaders = 'getAllResponseHeaders' in request ? parseHeaders(request.getAllResponseHeaders()) : null; + var responseData = !config.responseType || config.responseType === 'text' ? request.responseText : request.response; + var response = { + data: responseData, + status: request.status, + statusText: request.statusText, + headers: responseHeaders, + config: config, + request: request + }; + + settle(resolve, reject, response); + + // Clean up request + request = null; + }; + + // Handle browser request cancellation (as opposed to a manual cancellation) + request.onabort = function handleAbort() { + if (!request) { + return; + } + + reject(createError('Request aborted', config, 'ECONNABORTED', request)); + + // Clean up request + request = null; + }; + + // Handle low level network errors + request.onerror = function handleError() { + // Real errors are hidden from us by the browser + // onerror should only fire if it's a network error + reject(createError('Network Error', config, null, request)); + + // Clean up request + request = null; + }; + + // Handle timeout + request.ontimeout = function handleTimeout() { + reject(createError('timeout of ' + config.timeout + 'ms exceeded', config, 'ECONNABORTED', + request)); + + // Clean up request + request = null; + }; + + // Add xsrf header + // This is only done if running in a standard browser environment. + // Specifically not if we're in a web worker, or react-native. + if (utils.isStandardBrowserEnv()) { + var cookies = __webpack_require__(19); + + // Add xsrf header + var xsrfValue = (config.withCredentials || isURLSameOrigin(config.url)) && config.xsrfCookieName ? + cookies.read(config.xsrfCookieName) : + undefined; + + if (xsrfValue) { + requestHeaders[config.xsrfHeaderName] = xsrfValue; + } + } + + // Add headers to the request + if ('setRequestHeader' in request) { + utils.forEach(requestHeaders, function setRequestHeader(val, key) { + if (typeof requestData === 'undefined' && key.toLowerCase() === 'content-type') { + // Remove Content-Type if data is undefined + delete requestHeaders[key]; + } else { + // Otherwise add header to the request + request.setRequestHeader(key, val); + } + }); + } + + // Add withCredentials to request if needed + if (config.withCredentials) { + request.withCredentials = true; + } + + // Add responseType to request if needed + if (config.responseType) { + try { + request.responseType = config.responseType; + } catch (e) { + // Expected DOMException thrown by browsers not compatible XMLHttpRequest Level 2. + // But, this can be suppressed for 'json' type as it can be parsed by default 'transformResponse' function. + if (config.responseType !== 'json') { + throw e; + } + } + } + + // Handle progress if needed + if (typeof config.onDownloadProgress === 'function') { + request.addEventListener('progress', config.onDownloadProgress); + } + + // Not all browsers support upload events + if (typeof config.onUploadProgress === 'function' && request.upload) { + request.upload.addEventListener('progress', config.onUploadProgress); + } + + if (config.cancelToken) { + // Handle cancellation + config.cancelToken.promise.then(function onCanceled(cancel) { + if (!request) { + return; + } + + request.abort(); + reject(cancel); + // Clean up request + request = null; + }); + } + + if (requestData === undefined) { + requestData = null; + } + + // Send the request + request.send(requestData); + }); + }; + + +/***/ }), +/* 14 */ +/***/ (function(module, exports, __webpack_require__) { + + 'use strict'; + + var createError = __webpack_require__(15); + + /** + * Resolve or reject a Promise based on response status. + * + * @param {Function} resolve A function that resolves the promise. + * @param {Function} reject A function that rejects the promise. + * @param {object} response The response. + */ + module.exports = function settle(resolve, reject, response) { + var validateStatus = response.config.validateStatus; + if (!validateStatus || validateStatus(response.status)) { + resolve(response); + } else { + reject(createError( + 'Request failed with status code ' + response.status, + response.config, + null, + response.request, + response + )); + } + }; + + +/***/ }), +/* 15 */ +/***/ (function(module, exports, __webpack_require__) { + + 'use strict'; + + var enhanceError = __webpack_require__(16); + + /** + * Create an Error with the specified message, config, error code, request and response. + * + * @param {string} message The error message. + * @param {Object} config The config. + * @param {string} [code] The error code (for example, 'ECONNABORTED'). + * @param {Object} [request] The request. + * @param {Object} [response] The response. + * @returns {Error} The created error. + */ + module.exports = function createError(message, config, code, request, response) { + var error = new Error(message); + return enhanceError(error, config, code, request, response); + }; + + +/***/ }), +/* 16 */ +/***/ (function(module, exports) { + + 'use strict'; + + /** + * Update an Error with the specified config, error code, and response. + * + * @param {Error} error The error to update. + * @param {Object} config The config. + * @param {string} [code] The error code (for example, 'ECONNABORTED'). + * @param {Object} [request] The request. + * @param {Object} [response] The response. + * @returns {Error} The error. + */ + module.exports = function enhanceError(error, config, code, request, response) { + error.config = config; + if (code) { + error.code = code; + } + + error.request = request; + error.response = response; + error.isAxiosError = true; + + error.toJSON = function() { + return { + // Standard + message: this.message, + name: this.name, + // Microsoft + description: this.description, + number: this.number, + // Mozilla + fileName: this.fileName, + lineNumber: this.lineNumber, + columnNumber: this.columnNumber, + stack: this.stack, + // Axios + config: this.config, + code: this.code + }; + }; + return error; + }; + + +/***/ }), +/* 17 */ +/***/ (function(module, exports, __webpack_require__) { + + 'use strict'; + + var utils = __webpack_require__(2); + + // Headers whose duplicates are ignored by node + // c.f. https://nodejs.org/api/http.html#http_message_headers + var ignoreDuplicateOf = [ + 'age', 'authorization', 'content-length', 'content-type', 'etag', + 'expires', 'from', 'host', 'if-modified-since', 'if-unmodified-since', + 'last-modified', 'location', 'max-forwards', 'proxy-authorization', + 'referer', 'retry-after', 'user-agent' + ]; + + /** + * Parse headers into an object + * + * ``` + * Date: Wed, 27 Aug 2014 08:58:49 GMT + * Content-Type: application/json + * Connection: keep-alive + * Transfer-Encoding: chunked + * ``` + * + * @param {String} headers Headers needing to be parsed + * @returns {Object} Headers parsed into an object + */ + module.exports = function parseHeaders(headers) { + var parsed = {}; + var key; + var val; + var i; + + if (!headers) { return parsed; } + + utils.forEach(headers.split('\n'), function parser(line) { + i = line.indexOf(':'); + key = utils.trim(line.substr(0, i)).toLowerCase(); + val = utils.trim(line.substr(i + 1)); + + if (key) { + if (parsed[key] && ignoreDuplicateOf.indexOf(key) >= 0) { + return; + } + if (key === 'set-cookie') { + parsed[key] = (parsed[key] ? parsed[key] : []).concat([val]); + } else { + parsed[key] = parsed[key] ? parsed[key] + ', ' + val : val; + } + } + }); + + return parsed; + }; + + +/***/ }), +/* 18 */ +/***/ (function(module, exports, __webpack_require__) { + + 'use strict'; + + var utils = __webpack_require__(2); + + module.exports = ( + utils.isStandardBrowserEnv() ? + + // Standard browser envs have full support of the APIs needed to test + // whether the request URL is of the same origin as current location. + (function standardBrowserEnv() { + var msie = /(msie|trident)/i.test(navigator.userAgent); + var urlParsingNode = document.createElement('a'); + var originURL; + + /** + * Parse a URL to discover it's components + * + * @param {String} url The URL to be parsed + * @returns {Object} + */ + function resolveURL(url) { + var href = url; + + if (msie) { + // IE needs attribute set twice to normalize properties + urlParsingNode.setAttribute('href', href); + href = urlParsingNode.href; + } + + urlParsingNode.setAttribute('href', href); + + // urlParsingNode provides the UrlUtils interface - http://url.spec.whatwg.org/#urlutils + return { + href: urlParsingNode.href, + protocol: urlParsingNode.protocol ? urlParsingNode.protocol.replace(/:$/, '') : '', + host: urlParsingNode.host, + search: urlParsingNode.search ? urlParsingNode.search.replace(/^\?/, '') : '', + hash: urlParsingNode.hash ? urlParsingNode.hash.replace(/^#/, '') : '', + hostname: urlParsingNode.hostname, + port: urlParsingNode.port, + pathname: (urlParsingNode.pathname.charAt(0) === '/') ? + urlParsingNode.pathname : + '/' + urlParsingNode.pathname + }; + } + + originURL = resolveURL(window.location.href); + + /** + * Determine if a URL shares the same origin as the current location + * + * @param {String} requestURL The URL to test + * @returns {boolean} True if URL shares the same origin, otherwise false + */ + return function isURLSameOrigin(requestURL) { + var parsed = (utils.isString(requestURL)) ? resolveURL(requestURL) : requestURL; + return (parsed.protocol === originURL.protocol && + parsed.host === originURL.host); + }; + })() : + + // Non standard browser envs (web workers, react-native) lack needed support. + (function nonStandardBrowserEnv() { + return function isURLSameOrigin() { + return true; + }; + })() + ); + + +/***/ }), +/* 19 */ +/***/ (function(module, exports, __webpack_require__) { + + 'use strict'; + + var utils = __webpack_require__(2); + + module.exports = ( + utils.isStandardBrowserEnv() ? + + // Standard browser envs support document.cookie + (function standardBrowserEnv() { + return { + write: function write(name, value, expires, path, domain, secure) { + var cookie = []; + cookie.push(name + '=' + encodeURIComponent(value)); + + if (utils.isNumber(expires)) { + cookie.push('expires=' + new Date(expires).toGMTString()); + } + + if (utils.isString(path)) { + cookie.push('path=' + path); + } + + if (utils.isString(domain)) { + cookie.push('domain=' + domain); + } + + if (secure === true) { + cookie.push('secure'); + } + + document.cookie = cookie.join('; '); + }, + + read: function read(name) { + var match = document.cookie.match(new RegExp('(^|;\\s*)(' + name + ')=([^;]*)')); + return (match ? decodeURIComponent(match[3]) : null); + }, + + remove: function remove(name) { + this.write(name, '', Date.now() - 86400000); + } + }; + })() : + + // Non standard browser env (web workers, react-native) lack needed support. + (function nonStandardBrowserEnv() { + return { + write: function write() {}, + read: function read() { return null; }, + remove: function remove() {} + }; + })() + ); + + +/***/ }), +/* 20 */ +/***/ (function(module, exports) { + + 'use strict'; + + /** + * Determines whether the specified URL is absolute + * + * @param {string} url The URL to test + * @returns {boolean} True if the specified URL is absolute, otherwise false + */ + module.exports = function isAbsoluteURL(url) { + // A URL is considered absolute if it begins with "://" or "//" (protocol-relative URL). + // RFC 3986 defines scheme name as a sequence of characters beginning with a letter and followed + // by any combination of letters, digits, plus, period, or hyphen. + return /^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(url); + }; + + +/***/ }), +/* 21 */ +/***/ (function(module, exports) { + + 'use strict'; + + /** + * Creates a new URL by combining the specified URLs + * + * @param {string} baseURL The base URL + * @param {string} relativeURL The relative URL + * @returns {string} The combined URL + */ + module.exports = function combineURLs(baseURL, relativeURL) { + return relativeURL + ? baseURL.replace(/\/+$/, '') + '/' + relativeURL.replace(/^\/+/, '') + : baseURL; + }; + + +/***/ }), +/* 22 */ +/***/ (function(module, exports, __webpack_require__) { + + 'use strict'; + + var utils = __webpack_require__(2); + + /** + * Config-specific merge-function which creates a new config-object + * by merging two configuration objects together. + * + * @param {Object} config1 + * @param {Object} config2 + * @returns {Object} New object resulting from merging config2 to config1 + */ + module.exports = function mergeConfig(config1, config2) { + // eslint-disable-next-line no-param-reassign + config2 = config2 || {}; + var config = {}; + + utils.forEach(['url', 'method', 'params', 'data'], function valueFromConfig2(prop) { + if (typeof config2[prop] !== 'undefined') { + config[prop] = config2[prop]; + } + }); + + utils.forEach(['headers', 'auth', 'proxy'], function mergeDeepProperties(prop) { + if (utils.isObject(config2[prop])) { + config[prop] = utils.deepMerge(config1[prop], config2[prop]); + } else if (typeof config2[prop] !== 'undefined') { + config[prop] = config2[prop]; + } else if (utils.isObject(config1[prop])) { + config[prop] = utils.deepMerge(config1[prop]); + } else if (typeof config1[prop] !== 'undefined') { + config[prop] = config1[prop]; + } + }); + + utils.forEach([ + 'baseURL', 'transformRequest', 'transformResponse', 'paramsSerializer', + 'timeout', 'withCredentials', 'adapter', 'responseType', 'xsrfCookieName', + 'xsrfHeaderName', 'onUploadProgress', 'onDownloadProgress', 'maxContentLength', + 'validateStatus', 'maxRedirects', 'httpAgent', 'httpsAgent', 'cancelToken', + 'socketPath' + ], function defaultToConfig2(prop) { + if (typeof config2[prop] !== 'undefined') { + config[prop] = config2[prop]; + } else if (typeof config1[prop] !== 'undefined') { + config[prop] = config1[prop]; + } + }); + + return config; + }; + + +/***/ }), +/* 23 */ +/***/ (function(module, exports) { + + 'use strict'; + + /** + * A `Cancel` is an object that is thrown when an operation is canceled. + * + * @class + * @param {string=} message The message. + */ + function Cancel(message) { + this.message = message; + } + + Cancel.prototype.toString = function toString() { + return 'Cancel' + (this.message ? ': ' + this.message : ''); + }; + + Cancel.prototype.__CANCEL__ = true; + + module.exports = Cancel; + + +/***/ }), +/* 24 */ +/***/ (function(module, exports, __webpack_require__) { + + 'use strict'; + + var Cancel = __webpack_require__(23); + + /** + * A `CancelToken` is an object that can be used to request cancellation of an operation. + * + * @class + * @param {Function} executor The executor function. + */ + function CancelToken(executor) { + if (typeof executor !== 'function') { + throw new TypeError('executor must be a function.'); + } + + var resolvePromise; + this.promise = new Promise(function promiseExecutor(resolve) { + resolvePromise = resolve; + }); + + var token = this; + executor(function cancel(message) { + if (token.reason) { + // Cancellation has already been requested + return; + } + + token.reason = new Cancel(message); + resolvePromise(token.reason); + }); + } + + /** + * Throws a `Cancel` if cancellation has been requested. + */ + CancelToken.prototype.throwIfRequested = function throwIfRequested() { + if (this.reason) { + throw this.reason; + } + }; + + /** + * Returns an object that contains a new `CancelToken` and a function that, when called, + * cancels the `CancelToken`. + */ + CancelToken.source = function source() { + var cancel; + var token = new CancelToken(function executor(c) { + cancel = c; + }); + return { + token: token, + cancel: cancel + }; + }; + + module.exports = CancelToken; + + +/***/ }), +/* 25 */ +/***/ (function(module, exports) { + + 'use strict'; + + /** + * Syntactic sugar for invoking a function and expanding an array for arguments. + * + * Common use case would be to use `Function.prototype.apply`. + * + * ```js + * function f(x, y, z) {} + * var args = [1, 2, 3]; + * f.apply(null, args); + * ``` + * + * With `spread` this example can be re-written. + * + * ```js + * spread(function(x, y, z) {})([1, 2, 3]); + * ``` + * + * @param {Function} callback + * @returns {Function} + */ + module.exports = function spread(callback) { + return function wrap(arr) { + return callback.apply(null, arr); + }; + }; + + +/***/ }) +/******/ ]) +}); +; +//# sourceMappingURL=axios.map \ No newline at end of file diff --git a/node_modules/axios/dist/axios.map b/node_modules/axios/dist/axios.map new file mode 100644 index 0000000000..6fff93e67a --- /dev/null +++ b/node_modules/axios/dist/axios.map @@ -0,0 +1 @@ +{"version":3,"sources":["webpack:///webpack/universalModuleDefinition","webpack:///webpack/bootstrap ddfe8a04d3b6bbcd8d1c","webpack:///./index.js","webpack:///./lib/axios.js","webpack:///./lib/utils.js","webpack:///./lib/helpers/bind.js","webpack:///./~/is-buffer/index.js","webpack:///./lib/core/Axios.js","webpack:///./lib/helpers/buildURL.js","webpack:///./lib/core/InterceptorManager.js","webpack:///./lib/core/dispatchRequest.js","webpack:///./lib/core/transformData.js","webpack:///./lib/cancel/isCancel.js","webpack:///./lib/defaults.js","webpack:///./lib/helpers/normalizeHeaderName.js","webpack:///./lib/adapters/xhr.js","webpack:///./lib/core/settle.js","webpack:///./lib/core/createError.js","webpack:///./lib/core/enhanceError.js","webpack:///./lib/helpers/parseHeaders.js","webpack:///./lib/helpers/isURLSameOrigin.js","webpack:///./lib/helpers/cookies.js","webpack:///./lib/helpers/isAbsoluteURL.js","webpack:///./lib/helpers/combineURLs.js","webpack:///./lib/core/mergeConfig.js","webpack:///./lib/cancel/Cancel.js","webpack:///./lib/cancel/CancelToken.js","webpack:///./lib/helpers/spread.js"],"names":[],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC;AACD,O;ACVA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA,uBAAe;AACf;AACA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;;;AAGA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;;;;;;;ACtCA,yC;;;;;;ACAA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,YAAW,OAAO;AAClB,aAAY,MAAM;AAClB;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;;;;;;;ACpDA;;AAEA;AACA;;AAEA;;AAEA;;AAEA;;AAEA;AACA;AACA;AACA,YAAW,OAAO;AAClB,cAAa,QAAQ;AACrB;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,YAAW,OAAO;AAClB,cAAa,QAAQ;AACrB;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,YAAW,OAAO;AAClB,cAAa,QAAQ;AACrB;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,YAAW,OAAO;AAClB,cAAa,QAAQ;AACrB;AACA;AACA;AACA;AACA;AACA,IAAG;AACH;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,YAAW,OAAO;AAClB,cAAa,QAAQ;AACrB;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,YAAW,OAAO;AAClB,cAAa,QAAQ;AACrB;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,YAAW,OAAO;AAClB,cAAa,QAAQ;AACrB;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,YAAW,OAAO;AAClB,cAAa,QAAQ;AACrB;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,YAAW,OAAO;AAClB,cAAa,QAAQ;AACrB;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,YAAW,OAAO;AAClB,cAAa,QAAQ;AACrB;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,YAAW,OAAO;AAClB,cAAa,QAAQ;AACrB;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,YAAW,OAAO;AAClB,cAAa,QAAQ;AACrB;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,YAAW,OAAO;AAClB,cAAa,QAAQ;AACrB;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,YAAW,OAAO;AAClB,cAAa,QAAQ;AACrB;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,YAAW,OAAO;AAClB,cAAa,OAAO;AACpB;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,YAAW,aAAa;AACxB,YAAW,SAAS;AACpB;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA,oCAAmC,OAAO;AAC1C;AACA;AACA,IAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,wBAAuB,SAAS,GAAG,SAAS;AAC5C,4BAA2B;AAC3B;AACA;AACA,YAAW,OAAO;AAClB,cAAa,OAAO;AACpB;AACA;AACA;AACA;AACA;AACA;AACA,MAAK;AACL;AACA;AACA;;AAEA,wCAAuC,OAAO;AAC9C;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA,YAAW,OAAO;AAClB,cAAa,OAAO;AACpB;AACA;AACA;AACA;AACA;AACA;AACA,MAAK;AACL,iCAAgC;AAChC,MAAK;AACL;AACA;AACA;;AAEA,wCAAuC,OAAO;AAC9C;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,YAAW,OAAO;AAClB,YAAW,OAAO;AAClB,YAAW,OAAO;AAClB,aAAY,OAAO;AACnB;AACA;AACA;AACA;AACA;AACA,MAAK;AACL;AACA;AACA,IAAG;AACH;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;AC7UA;;AAEA;AACA;AACA;AACA,oBAAmB,iBAAiB;AACpC;AACA;AACA;AACA;AACA;;;;;;;ACVA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;;;;;;ACVA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,YAAW,OAAO;AAClB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,YAAW,OAAO;AAClB;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAG;AACH;AACA;;AAEA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA,IAAG;;AAEH;AACA;AACA,IAAG;;AAEH;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA,iDAAgD;AAChD;AACA;AACA,MAAK;AACL;AACA,EAAC;;AAED;AACA;AACA;AACA,iDAAgD;AAChD;AACA;AACA;AACA,MAAK;AACL;AACA,EAAC;;AAED;;;;;;;ACrFA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,YAAW,OAAO;AAClB,YAAW,OAAO;AAClB,cAAa,OAAO;AACpB;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,IAAG;AACH;AACA,IAAG;AACH;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA,QAAO;AACP;AACA;;AAEA;AACA;AACA;AACA,UAAS;AACT;AACA;AACA;AACA,QAAO;AACP,MAAK;;AAEL;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;;;;;;;ACtEA;;AAEA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA,YAAW,SAAS;AACpB,YAAW,SAAS;AACpB;AACA,aAAY,OAAO;AACnB;AACA;AACA;AACA;AACA;AACA,IAAG;AACH;AACA;;AAEA;AACA;AACA;AACA,YAAW,OAAO;AAClB;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,YAAW,SAAS;AACpB;AACA;AACA;AACA;AACA;AACA;AACA,IAAG;AACH;;AAEA;;;;;;;ACnDA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,YAAW,OAAO;AAClB,cAAa,QAAQ;AACrB;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA,gCAA+B;AAC/B,wCAAuC;AACvC;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA,IAAG;AACH;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA,IAAG;AACH;;;;;;;ACrFA;;AAEA;;AAEA;AACA;AACA;AACA,YAAW,cAAc;AACzB,YAAW,MAAM;AACjB,YAAW,eAAe;AAC1B,cAAa,EAAE;AACf;AACA;AACA;AACA;AACA;AACA,IAAG;;AAEH;AACA;;;;;;;ACnBA;;AAEA;AACA;AACA;;;;;;;ACJA;;AAEA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,IAAG;AACH;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,yEAAwE;AACxE;AACA;AACA;AACA,wDAAuD;AACvD;AACA;AACA;AACA,IAAG;;AAEH;AACA;AACA;AACA;AACA;AACA,QAAO,YAAY;AACnB;AACA;AACA,IAAG;;AAEH;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA,EAAC;;AAED;AACA;AACA,EAAC;;AAED;;;;;;;ACjGA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,IAAG;AACH;;;;;;;ACXA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA,6CAA4C;AAC5C;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,UAAS;AACT;AACA;AACA;AACA,QAAO;AACP;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA,QAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA,QAAO;AACP;;AAEA;AACA;AACA;;AAEA;AACA;AACA,IAAG;AACH;;;;;;;AC7KA;;AAEA;;AAEA;AACA;AACA;AACA,YAAW,SAAS;AACpB,YAAW,SAAS;AACpB,YAAW,OAAO;AAClB;AACA;AACA;AACA;AACA;AACA,IAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;ACxBA;;AAEA;;AAEA;AACA;AACA;AACA,YAAW,OAAO;AAClB,YAAW,OAAO;AAClB,YAAW,OAAO;AAClB,YAAW,OAAO;AAClB,YAAW,OAAO;AAClB,cAAa,MAAM;AACnB;AACA;AACA;AACA;AACA;;;;;;;ACjBA;;AAEA;AACA;AACA;AACA,YAAW,MAAM;AACjB,YAAW,OAAO;AAClB,YAAW,OAAO;AAClB,YAAW,OAAO;AAClB,YAAW,OAAO;AAClB,cAAa,MAAM;AACnB;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;ACzCA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,YAAW,OAAO;AAClB,cAAa,OAAO;AACpB;AACA;AACA;AACA;AACA;AACA;;AAEA,kBAAiB,eAAe;;AAEhC;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,QAAO;AACP;AACA;AACA;AACA,IAAG;;AAEH;AACA;;;;;;;ACpDA;;AAEA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,eAAc,OAAO;AACrB,iBAAgB;AAChB;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA,eAAc,OAAO;AACrB,iBAAgB,QAAQ;AACxB;AACA;AACA;AACA;AACA;AACA;AACA,MAAK;;AAEL;AACA;AACA;AACA;AACA;AACA,MAAK;AACL;;;;;;;ACnEA;;AAEA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA,2CAA0C;AAC1C,UAAS;;AAET;AACA,6DAA4D,wBAAwB;AACpF;AACA,UAAS;;AAET;AACA;AACA;AACA;AACA,MAAK;;AAEL;AACA;AACA;AACA,mCAAkC;AAClC,gCAA+B,aAAa,EAAE;AAC9C;AACA;AACA,MAAK;AACL;;;;;;;ACpDA;;AAEA;AACA;AACA;AACA,YAAW,OAAO;AAClB,cAAa,QAAQ;AACrB;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;ACbA;;AAEA;AACA;AACA;AACA,YAAW,OAAO;AAClB,YAAW,OAAO;AAClB,cAAa,OAAO;AACpB;AACA;AACA;AACA;AACA;AACA;;;;;;;ACbA;;AAEA;;AAEA;AACA;AACA;AACA;AACA,YAAW,OAAO;AAClB,YAAW,OAAO;AAClB,cAAa,OAAO;AACpB;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA,IAAG;;AAEH;AACA;AACA;AACA,MAAK;AACL;AACA,MAAK;AACL;AACA,MAAK;AACL;AACA;AACA,IAAG;;AAEH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAK;AACL;AACA;AACA,IAAG;;AAEH;AACA;;;;;;;AClDA;;AAEA;AACA;AACA;AACA;AACA,YAAW,QAAQ;AACnB;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;;AAEA;;;;;;;AClBA;;AAEA;;AAEA;AACA;AACA;AACA;AACA,YAAW,SAAS;AACpB;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,IAAG;;AAEH;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA,IAAG;AACH;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAG;AACH;AACA;AACA;AACA;AACA;;AAEA;;;;;;;ACxDA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,gCAA+B;AAC/B;AACA;AACA,YAAW,SAAS;AACpB,cAAa;AACb;AACA;AACA;AACA;AACA;AACA","file":"axios.js","sourcesContent":["(function webpackUniversalModuleDefinition(root, factory) {\n\tif(typeof exports === 'object' && typeof module === 'object')\n\t\tmodule.exports = factory();\n\telse if(typeof define === 'function' && define.amd)\n\t\tdefine([], factory);\n\telse if(typeof exports === 'object')\n\t\texports[\"axios\"] = factory();\n\telse\n\t\troot[\"axios\"] = factory();\n})(this, function() {\nreturn \n\n\n// WEBPACK FOOTER //\n// webpack/universalModuleDefinition"," \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId])\n \t\t\treturn installedModules[moduleId].exports;\n\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\texports: {},\n \t\t\tid: moduleId,\n \t\t\tloaded: false\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.loaded = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(0);\n\n\n\n// WEBPACK FOOTER //\n// webpack/bootstrap ddfe8a04d3b6bbcd8d1c","module.exports = require('./lib/axios');\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./index.js\n// module id = 0\n// module chunks = 0","'use strict';\n\nvar utils = require('./utils');\nvar bind = require('./helpers/bind');\nvar Axios = require('./core/Axios');\nvar mergeConfig = require('./core/mergeConfig');\nvar defaults = require('./defaults');\n\n/**\n * Create an instance of Axios\n *\n * @param {Object} defaultConfig The default config for the instance\n * @return {Axios} A new instance of Axios\n */\nfunction createInstance(defaultConfig) {\n var context = new Axios(defaultConfig);\n var instance = bind(Axios.prototype.request, context);\n\n // Copy axios.prototype to instance\n utils.extend(instance, Axios.prototype, context);\n\n // Copy context to instance\n utils.extend(instance, context);\n\n return instance;\n}\n\n// Create the default instance to be exported\nvar axios = createInstance(defaults);\n\n// Expose Axios class to allow class inheritance\naxios.Axios = Axios;\n\n// Factory for creating new instances\naxios.create = function create(instanceConfig) {\n return createInstance(mergeConfig(axios.defaults, instanceConfig));\n};\n\n// Expose Cancel & CancelToken\naxios.Cancel = require('./cancel/Cancel');\naxios.CancelToken = require('./cancel/CancelToken');\naxios.isCancel = require('./cancel/isCancel');\n\n// Expose all/spread\naxios.all = function all(promises) {\n return Promise.all(promises);\n};\naxios.spread = require('./helpers/spread');\n\nmodule.exports = axios;\n\n// Allow use of default import syntax in TypeScript\nmodule.exports.default = axios;\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/axios.js\n// module id = 1\n// module chunks = 0","'use strict';\n\nvar bind = require('./helpers/bind');\nvar isBuffer = require('is-buffer');\n\n/*global toString:true*/\n\n// utils is a library of generic helper functions non-specific to axios\n\nvar toString = Object.prototype.toString;\n\n/**\n * Determine if a value is an Array\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is an Array, otherwise false\n */\nfunction isArray(val) {\n return toString.call(val) === '[object Array]';\n}\n\n/**\n * Determine if a value is an ArrayBuffer\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is an ArrayBuffer, otherwise false\n */\nfunction isArrayBuffer(val) {\n return toString.call(val) === '[object ArrayBuffer]';\n}\n\n/**\n * Determine if a value is a FormData\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is an FormData, otherwise false\n */\nfunction isFormData(val) {\n return (typeof FormData !== 'undefined') && (val instanceof FormData);\n}\n\n/**\n * Determine if a value is a view on an ArrayBuffer\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is a view on an ArrayBuffer, otherwise false\n */\nfunction isArrayBufferView(val) {\n var result;\n if ((typeof ArrayBuffer !== 'undefined') && (ArrayBuffer.isView)) {\n result = ArrayBuffer.isView(val);\n } else {\n result = (val) && (val.buffer) && (val.buffer instanceof ArrayBuffer);\n }\n return result;\n}\n\n/**\n * Determine if a value is a String\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is a String, otherwise false\n */\nfunction isString(val) {\n return typeof val === 'string';\n}\n\n/**\n * Determine if a value is a Number\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is a Number, otherwise false\n */\nfunction isNumber(val) {\n return typeof val === 'number';\n}\n\n/**\n * Determine if a value is undefined\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if the value is undefined, otherwise false\n */\nfunction isUndefined(val) {\n return typeof val === 'undefined';\n}\n\n/**\n * Determine if a value is an Object\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is an Object, otherwise false\n */\nfunction isObject(val) {\n return val !== null && typeof val === 'object';\n}\n\n/**\n * Determine if a value is a Date\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is a Date, otherwise false\n */\nfunction isDate(val) {\n return toString.call(val) === '[object Date]';\n}\n\n/**\n * Determine if a value is a File\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is a File, otherwise false\n */\nfunction isFile(val) {\n return toString.call(val) === '[object File]';\n}\n\n/**\n * Determine if a value is a Blob\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is a Blob, otherwise false\n */\nfunction isBlob(val) {\n return toString.call(val) === '[object Blob]';\n}\n\n/**\n * Determine if a value is a Function\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is a Function, otherwise false\n */\nfunction isFunction(val) {\n return toString.call(val) === '[object Function]';\n}\n\n/**\n * Determine if a value is a Stream\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is a Stream, otherwise false\n */\nfunction isStream(val) {\n return isObject(val) && isFunction(val.pipe);\n}\n\n/**\n * Determine if a value is a URLSearchParams object\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is a URLSearchParams object, otherwise false\n */\nfunction isURLSearchParams(val) {\n return typeof URLSearchParams !== 'undefined' && val instanceof URLSearchParams;\n}\n\n/**\n * Trim excess whitespace off the beginning and end of a string\n *\n * @param {String} str The String to trim\n * @returns {String} The String freed of excess whitespace\n */\nfunction trim(str) {\n return str.replace(/^\\s*/, '').replace(/\\s*$/, '');\n}\n\n/**\n * Determine if we're running in a standard browser environment\n *\n * This allows axios to run in a web worker, and react-native.\n * Both environments support XMLHttpRequest, but not fully standard globals.\n *\n * web workers:\n * typeof window -> undefined\n * typeof document -> undefined\n *\n * react-native:\n * navigator.product -> 'ReactNative'\n * nativescript\n * navigator.product -> 'NativeScript' or 'NS'\n */\nfunction isStandardBrowserEnv() {\n if (typeof navigator !== 'undefined' && (navigator.product === 'ReactNative' ||\n navigator.product === 'NativeScript' ||\n navigator.product === 'NS')) {\n return false;\n }\n return (\n typeof window !== 'undefined' &&\n typeof document !== 'undefined'\n );\n}\n\n/**\n * Iterate over an Array or an Object invoking a function for each item.\n *\n * If `obj` is an Array callback will be called passing\n * the value, index, and complete array for each item.\n *\n * If 'obj' is an Object callback will be called passing\n * the value, key, and complete object for each property.\n *\n * @param {Object|Array} obj The object to iterate\n * @param {Function} fn The callback to invoke for each item\n */\nfunction forEach(obj, fn) {\n // Don't bother if no value provided\n if (obj === null || typeof obj === 'undefined') {\n return;\n }\n\n // Force an array if not already something iterable\n if (typeof obj !== 'object') {\n /*eslint no-param-reassign:0*/\n obj = [obj];\n }\n\n if (isArray(obj)) {\n // Iterate over array values\n for (var i = 0, l = obj.length; i < l; i++) {\n fn.call(null, obj[i], i, obj);\n }\n } else {\n // Iterate over object keys\n for (var key in obj) {\n if (Object.prototype.hasOwnProperty.call(obj, key)) {\n fn.call(null, obj[key], key, obj);\n }\n }\n }\n}\n\n/**\n * Accepts varargs expecting each argument to be an object, then\n * immutably merges the properties of each object and returns result.\n *\n * When multiple objects contain the same key the later object in\n * the arguments list will take precedence.\n *\n * Example:\n *\n * ```js\n * var result = merge({foo: 123}, {foo: 456});\n * console.log(result.foo); // outputs 456\n * ```\n *\n * @param {Object} obj1 Object to merge\n * @returns {Object} Result of all merge properties\n */\nfunction merge(/* obj1, obj2, obj3, ... */) {\n var result = {};\n function assignValue(val, key) {\n if (typeof result[key] === 'object' && typeof val === 'object') {\n result[key] = merge(result[key], val);\n } else {\n result[key] = val;\n }\n }\n\n for (var i = 0, l = arguments.length; i < l; i++) {\n forEach(arguments[i], assignValue);\n }\n return result;\n}\n\n/**\n * Function equal to merge with the difference being that no reference\n * to original objects is kept.\n *\n * @see merge\n * @param {Object} obj1 Object to merge\n * @returns {Object} Result of all merge properties\n */\nfunction deepMerge(/* obj1, obj2, obj3, ... */) {\n var result = {};\n function assignValue(val, key) {\n if (typeof result[key] === 'object' && typeof val === 'object') {\n result[key] = deepMerge(result[key], val);\n } else if (typeof val === 'object') {\n result[key] = deepMerge({}, val);\n } else {\n result[key] = val;\n }\n }\n\n for (var i = 0, l = arguments.length; i < l; i++) {\n forEach(arguments[i], assignValue);\n }\n return result;\n}\n\n/**\n * Extends object a by mutably adding to it the properties of object b.\n *\n * @param {Object} a The object to be extended\n * @param {Object} b The object to copy properties from\n * @param {Object} thisArg The object to bind function to\n * @return {Object} The resulting value of object a\n */\nfunction extend(a, b, thisArg) {\n forEach(b, function assignValue(val, key) {\n if (thisArg && typeof val === 'function') {\n a[key] = bind(val, thisArg);\n } else {\n a[key] = val;\n }\n });\n return a;\n}\n\nmodule.exports = {\n isArray: isArray,\n isArrayBuffer: isArrayBuffer,\n isBuffer: isBuffer,\n isFormData: isFormData,\n isArrayBufferView: isArrayBufferView,\n isString: isString,\n isNumber: isNumber,\n isObject: isObject,\n isUndefined: isUndefined,\n isDate: isDate,\n isFile: isFile,\n isBlob: isBlob,\n isFunction: isFunction,\n isStream: isStream,\n isURLSearchParams: isURLSearchParams,\n isStandardBrowserEnv: isStandardBrowserEnv,\n forEach: forEach,\n merge: merge,\n deepMerge: deepMerge,\n extend: extend,\n trim: trim\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/utils.js\n// module id = 2\n// module chunks = 0","'use strict';\n\nmodule.exports = function bind(fn, thisArg) {\n return function wrap() {\n var args = new Array(arguments.length);\n for (var i = 0; i < args.length; i++) {\n args[i] = arguments[i];\n }\n return fn.apply(thisArg, args);\n };\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/helpers/bind.js\n// module id = 3\n// module chunks = 0","/*!\n * Determine if an object is a Buffer\n *\n * @author Feross Aboukhadijeh \n * @license MIT\n */\n\nmodule.exports = function isBuffer (obj) {\n return obj != null && obj.constructor != null &&\n typeof obj.constructor.isBuffer === 'function' && obj.constructor.isBuffer(obj)\n}\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/is-buffer/index.js\n// module id = 4\n// module chunks = 0","'use strict';\n\nvar utils = require('./../utils');\nvar buildURL = require('../helpers/buildURL');\nvar InterceptorManager = require('./InterceptorManager');\nvar dispatchRequest = require('./dispatchRequest');\nvar mergeConfig = require('./mergeConfig');\n\n/**\n * Create a new instance of Axios\n *\n * @param {Object} instanceConfig The default config for the instance\n */\nfunction Axios(instanceConfig) {\n this.defaults = instanceConfig;\n this.interceptors = {\n request: new InterceptorManager(),\n response: new InterceptorManager()\n };\n}\n\n/**\n * Dispatch a request\n *\n * @param {Object} config The config specific for this request (merged with this.defaults)\n */\nAxios.prototype.request = function request(config) {\n /*eslint no-param-reassign:0*/\n // Allow for axios('example/url'[, config]) a la fetch API\n if (typeof config === 'string') {\n config = arguments[1] || {};\n config.url = arguments[0];\n } else {\n config = config || {};\n }\n\n config = mergeConfig(this.defaults, config);\n config.method = config.method ? config.method.toLowerCase() : 'get';\n\n // Hook up interceptors middleware\n var chain = [dispatchRequest, undefined];\n var promise = Promise.resolve(config);\n\n this.interceptors.request.forEach(function unshiftRequestInterceptors(interceptor) {\n chain.unshift(interceptor.fulfilled, interceptor.rejected);\n });\n\n this.interceptors.response.forEach(function pushResponseInterceptors(interceptor) {\n chain.push(interceptor.fulfilled, interceptor.rejected);\n });\n\n while (chain.length) {\n promise = promise.then(chain.shift(), chain.shift());\n }\n\n return promise;\n};\n\nAxios.prototype.getUri = function getUri(config) {\n config = mergeConfig(this.defaults, config);\n return buildURL(config.url, config.params, config.paramsSerializer).replace(/^\\?/, '');\n};\n\n// Provide aliases for supported request methods\nutils.forEach(['delete', 'get', 'head', 'options'], function forEachMethodNoData(method) {\n /*eslint func-names:0*/\n Axios.prototype[method] = function(url, config) {\n return this.request(utils.merge(config || {}, {\n method: method,\n url: url\n }));\n };\n});\n\nutils.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method) {\n /*eslint func-names:0*/\n Axios.prototype[method] = function(url, data, config) {\n return this.request(utils.merge(config || {}, {\n method: method,\n url: url,\n data: data\n }));\n };\n});\n\nmodule.exports = Axios;\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/core/Axios.js\n// module id = 5\n// module chunks = 0","'use strict';\n\nvar utils = require('./../utils');\n\nfunction encode(val) {\n return encodeURIComponent(val).\n replace(/%40/gi, '@').\n replace(/%3A/gi, ':').\n replace(/%24/g, '$').\n replace(/%2C/gi, ',').\n replace(/%20/g, '+').\n replace(/%5B/gi, '[').\n replace(/%5D/gi, ']');\n}\n\n/**\n * Build a URL by appending params to the end\n *\n * @param {string} url The base of the url (e.g., http://www.google.com)\n * @param {object} [params] The params to be appended\n * @returns {string} The formatted url\n */\nmodule.exports = function buildURL(url, params, paramsSerializer) {\n /*eslint no-param-reassign:0*/\n if (!params) {\n return url;\n }\n\n var serializedParams;\n if (paramsSerializer) {\n serializedParams = paramsSerializer(params);\n } else if (utils.isURLSearchParams(params)) {\n serializedParams = params.toString();\n } else {\n var parts = [];\n\n utils.forEach(params, function serialize(val, key) {\n if (val === null || typeof val === 'undefined') {\n return;\n }\n\n if (utils.isArray(val)) {\n key = key + '[]';\n } else {\n val = [val];\n }\n\n utils.forEach(val, function parseValue(v) {\n if (utils.isDate(v)) {\n v = v.toISOString();\n } else if (utils.isObject(v)) {\n v = JSON.stringify(v);\n }\n parts.push(encode(key) + '=' + encode(v));\n });\n });\n\n serializedParams = parts.join('&');\n }\n\n if (serializedParams) {\n var hashmarkIndex = url.indexOf('#');\n if (hashmarkIndex !== -1) {\n url = url.slice(0, hashmarkIndex);\n }\n\n url += (url.indexOf('?') === -1 ? '?' : '&') + serializedParams;\n }\n\n return url;\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/helpers/buildURL.js\n// module id = 6\n// module chunks = 0","'use strict';\n\nvar utils = require('./../utils');\n\nfunction InterceptorManager() {\n this.handlers = [];\n}\n\n/**\n * Add a new interceptor to the stack\n *\n * @param {Function} fulfilled The function to handle `then` for a `Promise`\n * @param {Function} rejected The function to handle `reject` for a `Promise`\n *\n * @return {Number} An ID used to remove interceptor later\n */\nInterceptorManager.prototype.use = function use(fulfilled, rejected) {\n this.handlers.push({\n fulfilled: fulfilled,\n rejected: rejected\n });\n return this.handlers.length - 1;\n};\n\n/**\n * Remove an interceptor from the stack\n *\n * @param {Number} id The ID that was returned by `use`\n */\nInterceptorManager.prototype.eject = function eject(id) {\n if (this.handlers[id]) {\n this.handlers[id] = null;\n }\n};\n\n/**\n * Iterate over all the registered interceptors\n *\n * This method is particularly useful for skipping over any\n * interceptors that may have become `null` calling `eject`.\n *\n * @param {Function} fn The function to call for each interceptor\n */\nInterceptorManager.prototype.forEach = function forEach(fn) {\n utils.forEach(this.handlers, function forEachHandler(h) {\n if (h !== null) {\n fn(h);\n }\n });\n};\n\nmodule.exports = InterceptorManager;\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/core/InterceptorManager.js\n// module id = 7\n// module chunks = 0","'use strict';\n\nvar utils = require('./../utils');\nvar transformData = require('./transformData');\nvar isCancel = require('../cancel/isCancel');\nvar defaults = require('../defaults');\nvar isAbsoluteURL = require('./../helpers/isAbsoluteURL');\nvar combineURLs = require('./../helpers/combineURLs');\n\n/**\n * Throws a `Cancel` if cancellation has been requested.\n */\nfunction throwIfCancellationRequested(config) {\n if (config.cancelToken) {\n config.cancelToken.throwIfRequested();\n }\n}\n\n/**\n * Dispatch a request to the server using the configured adapter.\n *\n * @param {object} config The config that is to be used for the request\n * @returns {Promise} The Promise to be fulfilled\n */\nmodule.exports = function dispatchRequest(config) {\n throwIfCancellationRequested(config);\n\n // Support baseURL config\n if (config.baseURL && !isAbsoluteURL(config.url)) {\n config.url = combineURLs(config.baseURL, config.url);\n }\n\n // Ensure headers exist\n config.headers = config.headers || {};\n\n // Transform request data\n config.data = transformData(\n config.data,\n config.headers,\n config.transformRequest\n );\n\n // Flatten headers\n config.headers = utils.merge(\n config.headers.common || {},\n config.headers[config.method] || {},\n config.headers || {}\n );\n\n utils.forEach(\n ['delete', 'get', 'head', 'post', 'put', 'patch', 'common'],\n function cleanHeaderConfig(method) {\n delete config.headers[method];\n }\n );\n\n var adapter = config.adapter || defaults.adapter;\n\n return adapter(config).then(function onAdapterResolution(response) {\n throwIfCancellationRequested(config);\n\n // Transform response data\n response.data = transformData(\n response.data,\n response.headers,\n config.transformResponse\n );\n\n return response;\n }, function onAdapterRejection(reason) {\n if (!isCancel(reason)) {\n throwIfCancellationRequested(config);\n\n // Transform response data\n if (reason && reason.response) {\n reason.response.data = transformData(\n reason.response.data,\n reason.response.headers,\n config.transformResponse\n );\n }\n }\n\n return Promise.reject(reason);\n });\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/core/dispatchRequest.js\n// module id = 8\n// module chunks = 0","'use strict';\n\nvar utils = require('./../utils');\n\n/**\n * Transform the data for a request or a response\n *\n * @param {Object|String} data The data to be transformed\n * @param {Array} headers The headers for the request or response\n * @param {Array|Function} fns A single function or Array of functions\n * @returns {*} The resulting transformed data\n */\nmodule.exports = function transformData(data, headers, fns) {\n /*eslint no-param-reassign:0*/\n utils.forEach(fns, function transform(fn) {\n data = fn(data, headers);\n });\n\n return data;\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/core/transformData.js\n// module id = 9\n// module chunks = 0","'use strict';\n\nmodule.exports = function isCancel(value) {\n return !!(value && value.__CANCEL__);\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/cancel/isCancel.js\n// module id = 10\n// module chunks = 0","'use strict';\n\nvar utils = require('./utils');\nvar normalizeHeaderName = require('./helpers/normalizeHeaderName');\n\nvar DEFAULT_CONTENT_TYPE = {\n 'Content-Type': 'application/x-www-form-urlencoded'\n};\n\nfunction setContentTypeIfUnset(headers, value) {\n if (!utils.isUndefined(headers) && utils.isUndefined(headers['Content-Type'])) {\n headers['Content-Type'] = value;\n }\n}\n\nfunction getDefaultAdapter() {\n var adapter;\n // Only Node.JS has a process variable that is of [[Class]] process\n if (typeof process !== 'undefined' && Object.prototype.toString.call(process) === '[object process]') {\n // For node use HTTP adapter\n adapter = require('./adapters/http');\n } else if (typeof XMLHttpRequest !== 'undefined') {\n // For browsers use XHR adapter\n adapter = require('./adapters/xhr');\n }\n return adapter;\n}\n\nvar defaults = {\n adapter: getDefaultAdapter(),\n\n transformRequest: [function transformRequest(data, headers) {\n normalizeHeaderName(headers, 'Accept');\n normalizeHeaderName(headers, 'Content-Type');\n if (utils.isFormData(data) ||\n utils.isArrayBuffer(data) ||\n utils.isBuffer(data) ||\n utils.isStream(data) ||\n utils.isFile(data) ||\n utils.isBlob(data)\n ) {\n return data;\n }\n if (utils.isArrayBufferView(data)) {\n return data.buffer;\n }\n if (utils.isURLSearchParams(data)) {\n setContentTypeIfUnset(headers, 'application/x-www-form-urlencoded;charset=utf-8');\n return data.toString();\n }\n if (utils.isObject(data)) {\n setContentTypeIfUnset(headers, 'application/json;charset=utf-8');\n return JSON.stringify(data);\n }\n return data;\n }],\n\n transformResponse: [function transformResponse(data) {\n /*eslint no-param-reassign:0*/\n if (typeof data === 'string') {\n try {\n data = JSON.parse(data);\n } catch (e) { /* Ignore */ }\n }\n return data;\n }],\n\n /**\n * A timeout in milliseconds to abort a request. If set to 0 (default) a\n * timeout is not created.\n */\n timeout: 0,\n\n xsrfCookieName: 'XSRF-TOKEN',\n xsrfHeaderName: 'X-XSRF-TOKEN',\n\n maxContentLength: -1,\n\n validateStatus: function validateStatus(status) {\n return status >= 200 && status < 300;\n }\n};\n\ndefaults.headers = {\n common: {\n 'Accept': 'application/json, text/plain, */*'\n }\n};\n\nutils.forEach(['delete', 'get', 'head'], function forEachMethodNoData(method) {\n defaults.headers[method] = {};\n});\n\nutils.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method) {\n defaults.headers[method] = utils.merge(DEFAULT_CONTENT_TYPE);\n});\n\nmodule.exports = defaults;\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/defaults.js\n// module id = 11\n// module chunks = 0","'use strict';\n\nvar utils = require('../utils');\n\nmodule.exports = function normalizeHeaderName(headers, normalizedName) {\n utils.forEach(headers, function processHeader(value, name) {\n if (name !== normalizedName && name.toUpperCase() === normalizedName.toUpperCase()) {\n headers[normalizedName] = value;\n delete headers[name];\n }\n });\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/helpers/normalizeHeaderName.js\n// module id = 12\n// module chunks = 0","'use strict';\n\nvar utils = require('./../utils');\nvar settle = require('./../core/settle');\nvar buildURL = require('./../helpers/buildURL');\nvar parseHeaders = require('./../helpers/parseHeaders');\nvar isURLSameOrigin = require('./../helpers/isURLSameOrigin');\nvar createError = require('../core/createError');\n\nmodule.exports = function xhrAdapter(config) {\n return new Promise(function dispatchXhrRequest(resolve, reject) {\n var requestData = config.data;\n var requestHeaders = config.headers;\n\n if (utils.isFormData(requestData)) {\n delete requestHeaders['Content-Type']; // Let the browser set it\n }\n\n var request = new XMLHttpRequest();\n\n // HTTP basic authentication\n if (config.auth) {\n var username = config.auth.username || '';\n var password = config.auth.password || '';\n requestHeaders.Authorization = 'Basic ' + btoa(username + ':' + password);\n }\n\n request.open(config.method.toUpperCase(), buildURL(config.url, config.params, config.paramsSerializer), true);\n\n // Set the request timeout in MS\n request.timeout = config.timeout;\n\n // Listen for ready state\n request.onreadystatechange = function handleLoad() {\n if (!request || request.readyState !== 4) {\n return;\n }\n\n // The request errored out and we didn't get a response, this will be\n // handled by onerror instead\n // With one exception: request that using file: protocol, most browsers\n // will return status as 0 even though it's a successful request\n if (request.status === 0 && !(request.responseURL && request.responseURL.indexOf('file:') === 0)) {\n return;\n }\n\n // Prepare the response\n var responseHeaders = 'getAllResponseHeaders' in request ? parseHeaders(request.getAllResponseHeaders()) : null;\n var responseData = !config.responseType || config.responseType === 'text' ? request.responseText : request.response;\n var response = {\n data: responseData,\n status: request.status,\n statusText: request.statusText,\n headers: responseHeaders,\n config: config,\n request: request\n };\n\n settle(resolve, reject, response);\n\n // Clean up request\n request = null;\n };\n\n // Handle browser request cancellation (as opposed to a manual cancellation)\n request.onabort = function handleAbort() {\n if (!request) {\n return;\n }\n\n reject(createError('Request aborted', config, 'ECONNABORTED', request));\n\n // Clean up request\n request = null;\n };\n\n // Handle low level network errors\n request.onerror = function handleError() {\n // Real errors are hidden from us by the browser\n // onerror should only fire if it's a network error\n reject(createError('Network Error', config, null, request));\n\n // Clean up request\n request = null;\n };\n\n // Handle timeout\n request.ontimeout = function handleTimeout() {\n reject(createError('timeout of ' + config.timeout + 'ms exceeded', config, 'ECONNABORTED',\n request));\n\n // Clean up request\n request = null;\n };\n\n // Add xsrf header\n // This is only done if running in a standard browser environment.\n // Specifically not if we're in a web worker, or react-native.\n if (utils.isStandardBrowserEnv()) {\n var cookies = require('./../helpers/cookies');\n\n // Add xsrf header\n var xsrfValue = (config.withCredentials || isURLSameOrigin(config.url)) && config.xsrfCookieName ?\n cookies.read(config.xsrfCookieName) :\n undefined;\n\n if (xsrfValue) {\n requestHeaders[config.xsrfHeaderName] = xsrfValue;\n }\n }\n\n // Add headers to the request\n if ('setRequestHeader' in request) {\n utils.forEach(requestHeaders, function setRequestHeader(val, key) {\n if (typeof requestData === 'undefined' && key.toLowerCase() === 'content-type') {\n // Remove Content-Type if data is undefined\n delete requestHeaders[key];\n } else {\n // Otherwise add header to the request\n request.setRequestHeader(key, val);\n }\n });\n }\n\n // Add withCredentials to request if needed\n if (config.withCredentials) {\n request.withCredentials = true;\n }\n\n // Add responseType to request if needed\n if (config.responseType) {\n try {\n request.responseType = config.responseType;\n } catch (e) {\n // Expected DOMException thrown by browsers not compatible XMLHttpRequest Level 2.\n // But, this can be suppressed for 'json' type as it can be parsed by default 'transformResponse' function.\n if (config.responseType !== 'json') {\n throw e;\n }\n }\n }\n\n // Handle progress if needed\n if (typeof config.onDownloadProgress === 'function') {\n request.addEventListener('progress', config.onDownloadProgress);\n }\n\n // Not all browsers support upload events\n if (typeof config.onUploadProgress === 'function' && request.upload) {\n request.upload.addEventListener('progress', config.onUploadProgress);\n }\n\n if (config.cancelToken) {\n // Handle cancellation\n config.cancelToken.promise.then(function onCanceled(cancel) {\n if (!request) {\n return;\n }\n\n request.abort();\n reject(cancel);\n // Clean up request\n request = null;\n });\n }\n\n if (requestData === undefined) {\n requestData = null;\n }\n\n // Send the request\n request.send(requestData);\n });\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/adapters/xhr.js\n// module id = 13\n// module chunks = 0","'use strict';\n\nvar createError = require('./createError');\n\n/**\n * Resolve or reject a Promise based on response status.\n *\n * @param {Function} resolve A function that resolves the promise.\n * @param {Function} reject A function that rejects the promise.\n * @param {object} response The response.\n */\nmodule.exports = function settle(resolve, reject, response) {\n var validateStatus = response.config.validateStatus;\n if (!validateStatus || validateStatus(response.status)) {\n resolve(response);\n } else {\n reject(createError(\n 'Request failed with status code ' + response.status,\n response.config,\n null,\n response.request,\n response\n ));\n }\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/core/settle.js\n// module id = 14\n// module chunks = 0","'use strict';\n\nvar enhanceError = require('./enhanceError');\n\n/**\n * Create an Error with the specified message, config, error code, request and response.\n *\n * @param {string} message The error message.\n * @param {Object} config The config.\n * @param {string} [code] The error code (for example, 'ECONNABORTED').\n * @param {Object} [request] The request.\n * @param {Object} [response] The response.\n * @returns {Error} The created error.\n */\nmodule.exports = function createError(message, config, code, request, response) {\n var error = new Error(message);\n return enhanceError(error, config, code, request, response);\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/core/createError.js\n// module id = 15\n// module chunks = 0","'use strict';\n\n/**\n * Update an Error with the specified config, error code, and response.\n *\n * @param {Error} error The error to update.\n * @param {Object} config The config.\n * @param {string} [code] The error code (for example, 'ECONNABORTED').\n * @param {Object} [request] The request.\n * @param {Object} [response] The response.\n * @returns {Error} The error.\n */\nmodule.exports = function enhanceError(error, config, code, request, response) {\n error.config = config;\n if (code) {\n error.code = code;\n }\n\n error.request = request;\n error.response = response;\n error.isAxiosError = true;\n\n error.toJSON = function() {\n return {\n // Standard\n message: this.message,\n name: this.name,\n // Microsoft\n description: this.description,\n number: this.number,\n // Mozilla\n fileName: this.fileName,\n lineNumber: this.lineNumber,\n columnNumber: this.columnNumber,\n stack: this.stack,\n // Axios\n config: this.config,\n code: this.code\n };\n };\n return error;\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/core/enhanceError.js\n// module id = 16\n// module chunks = 0","'use strict';\n\nvar utils = require('./../utils');\n\n// Headers whose duplicates are ignored by node\n// c.f. https://nodejs.org/api/http.html#http_message_headers\nvar ignoreDuplicateOf = [\n 'age', 'authorization', 'content-length', 'content-type', 'etag',\n 'expires', 'from', 'host', 'if-modified-since', 'if-unmodified-since',\n 'last-modified', 'location', 'max-forwards', 'proxy-authorization',\n 'referer', 'retry-after', 'user-agent'\n];\n\n/**\n * Parse headers into an object\n *\n * ```\n * Date: Wed, 27 Aug 2014 08:58:49 GMT\n * Content-Type: application/json\n * Connection: keep-alive\n * Transfer-Encoding: chunked\n * ```\n *\n * @param {String} headers Headers needing to be parsed\n * @returns {Object} Headers parsed into an object\n */\nmodule.exports = function parseHeaders(headers) {\n var parsed = {};\n var key;\n var val;\n var i;\n\n if (!headers) { return parsed; }\n\n utils.forEach(headers.split('\\n'), function parser(line) {\n i = line.indexOf(':');\n key = utils.trim(line.substr(0, i)).toLowerCase();\n val = utils.trim(line.substr(i + 1));\n\n if (key) {\n if (parsed[key] && ignoreDuplicateOf.indexOf(key) >= 0) {\n return;\n }\n if (key === 'set-cookie') {\n parsed[key] = (parsed[key] ? parsed[key] : []).concat([val]);\n } else {\n parsed[key] = parsed[key] ? parsed[key] + ', ' + val : val;\n }\n }\n });\n\n return parsed;\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/helpers/parseHeaders.js\n// module id = 17\n// module chunks = 0","'use strict';\n\nvar utils = require('./../utils');\n\nmodule.exports = (\n utils.isStandardBrowserEnv() ?\n\n // Standard browser envs have full support of the APIs needed to test\n // whether the request URL is of the same origin as current location.\n (function standardBrowserEnv() {\n var msie = /(msie|trident)/i.test(navigator.userAgent);\n var urlParsingNode = document.createElement('a');\n var originURL;\n\n /**\n * Parse a URL to discover it's components\n *\n * @param {String} url The URL to be parsed\n * @returns {Object}\n */\n function resolveURL(url) {\n var href = url;\n\n if (msie) {\n // IE needs attribute set twice to normalize properties\n urlParsingNode.setAttribute('href', href);\n href = urlParsingNode.href;\n }\n\n urlParsingNode.setAttribute('href', href);\n\n // urlParsingNode provides the UrlUtils interface - http://url.spec.whatwg.org/#urlutils\n return {\n href: urlParsingNode.href,\n protocol: urlParsingNode.protocol ? urlParsingNode.protocol.replace(/:$/, '') : '',\n host: urlParsingNode.host,\n search: urlParsingNode.search ? urlParsingNode.search.replace(/^\\?/, '') : '',\n hash: urlParsingNode.hash ? urlParsingNode.hash.replace(/^#/, '') : '',\n hostname: urlParsingNode.hostname,\n port: urlParsingNode.port,\n pathname: (urlParsingNode.pathname.charAt(0) === '/') ?\n urlParsingNode.pathname :\n '/' + urlParsingNode.pathname\n };\n }\n\n originURL = resolveURL(window.location.href);\n\n /**\n * Determine if a URL shares the same origin as the current location\n *\n * @param {String} requestURL The URL to test\n * @returns {boolean} True if URL shares the same origin, otherwise false\n */\n return function isURLSameOrigin(requestURL) {\n var parsed = (utils.isString(requestURL)) ? resolveURL(requestURL) : requestURL;\n return (parsed.protocol === originURL.protocol &&\n parsed.host === originURL.host);\n };\n })() :\n\n // Non standard browser envs (web workers, react-native) lack needed support.\n (function nonStandardBrowserEnv() {\n return function isURLSameOrigin() {\n return true;\n };\n })()\n);\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/helpers/isURLSameOrigin.js\n// module id = 18\n// module chunks = 0","'use strict';\n\nvar utils = require('./../utils');\n\nmodule.exports = (\n utils.isStandardBrowserEnv() ?\n\n // Standard browser envs support document.cookie\n (function standardBrowserEnv() {\n return {\n write: function write(name, value, expires, path, domain, secure) {\n var cookie = [];\n cookie.push(name + '=' + encodeURIComponent(value));\n\n if (utils.isNumber(expires)) {\n cookie.push('expires=' + new Date(expires).toGMTString());\n }\n\n if (utils.isString(path)) {\n cookie.push('path=' + path);\n }\n\n if (utils.isString(domain)) {\n cookie.push('domain=' + domain);\n }\n\n if (secure === true) {\n cookie.push('secure');\n }\n\n document.cookie = cookie.join('; ');\n },\n\n read: function read(name) {\n var match = document.cookie.match(new RegExp('(^|;\\\\s*)(' + name + ')=([^;]*)'));\n return (match ? decodeURIComponent(match[3]) : null);\n },\n\n remove: function remove(name) {\n this.write(name, '', Date.now() - 86400000);\n }\n };\n })() :\n\n // Non standard browser env (web workers, react-native) lack needed support.\n (function nonStandardBrowserEnv() {\n return {\n write: function write() {},\n read: function read() { return null; },\n remove: function remove() {}\n };\n })()\n);\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/helpers/cookies.js\n// module id = 19\n// module chunks = 0","'use strict';\n\n/**\n * Determines whether the specified URL is absolute\n *\n * @param {string} url The URL to test\n * @returns {boolean} True if the specified URL is absolute, otherwise false\n */\nmodule.exports = function isAbsoluteURL(url) {\n // A URL is considered absolute if it begins with \"://\" or \"//\" (protocol-relative URL).\n // RFC 3986 defines scheme name as a sequence of characters beginning with a letter and followed\n // by any combination of letters, digits, plus, period, or hyphen.\n return /^([a-z][a-z\\d\\+\\-\\.]*:)?\\/\\//i.test(url);\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/helpers/isAbsoluteURL.js\n// module id = 20\n// module chunks = 0","'use strict';\n\n/**\n * Creates a new URL by combining the specified URLs\n *\n * @param {string} baseURL The base URL\n * @param {string} relativeURL The relative URL\n * @returns {string} The combined URL\n */\nmodule.exports = function combineURLs(baseURL, relativeURL) {\n return relativeURL\n ? baseURL.replace(/\\/+$/, '') + '/' + relativeURL.replace(/^\\/+/, '')\n : baseURL;\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/helpers/combineURLs.js\n// module id = 21\n// module chunks = 0","'use strict';\n\nvar utils = require('../utils');\n\n/**\n * Config-specific merge-function which creates a new config-object\n * by merging two configuration objects together.\n *\n * @param {Object} config1\n * @param {Object} config2\n * @returns {Object} New object resulting from merging config2 to config1\n */\nmodule.exports = function mergeConfig(config1, config2) {\n // eslint-disable-next-line no-param-reassign\n config2 = config2 || {};\n var config = {};\n\n utils.forEach(['url', 'method', 'params', 'data'], function valueFromConfig2(prop) {\n if (typeof config2[prop] !== 'undefined') {\n config[prop] = config2[prop];\n }\n });\n\n utils.forEach(['headers', 'auth', 'proxy'], function mergeDeepProperties(prop) {\n if (utils.isObject(config2[prop])) {\n config[prop] = utils.deepMerge(config1[prop], config2[prop]);\n } else if (typeof config2[prop] !== 'undefined') {\n config[prop] = config2[prop];\n } else if (utils.isObject(config1[prop])) {\n config[prop] = utils.deepMerge(config1[prop]);\n } else if (typeof config1[prop] !== 'undefined') {\n config[prop] = config1[prop];\n }\n });\n\n utils.forEach([\n 'baseURL', 'transformRequest', 'transformResponse', 'paramsSerializer',\n 'timeout', 'withCredentials', 'adapter', 'responseType', 'xsrfCookieName',\n 'xsrfHeaderName', 'onUploadProgress', 'onDownloadProgress', 'maxContentLength',\n 'validateStatus', 'maxRedirects', 'httpAgent', 'httpsAgent', 'cancelToken',\n 'socketPath'\n ], function defaultToConfig2(prop) {\n if (typeof config2[prop] !== 'undefined') {\n config[prop] = config2[prop];\n } else if (typeof config1[prop] !== 'undefined') {\n config[prop] = config1[prop];\n }\n });\n\n return config;\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/core/mergeConfig.js\n// module id = 22\n// module chunks = 0","'use strict';\n\n/**\n * A `Cancel` is an object that is thrown when an operation is canceled.\n *\n * @class\n * @param {string=} message The message.\n */\nfunction Cancel(message) {\n this.message = message;\n}\n\nCancel.prototype.toString = function toString() {\n return 'Cancel' + (this.message ? ': ' + this.message : '');\n};\n\nCancel.prototype.__CANCEL__ = true;\n\nmodule.exports = Cancel;\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/cancel/Cancel.js\n// module id = 23\n// module chunks = 0","'use strict';\n\nvar Cancel = require('./Cancel');\n\n/**\n * A `CancelToken` is an object that can be used to request cancellation of an operation.\n *\n * @class\n * @param {Function} executor The executor function.\n */\nfunction CancelToken(executor) {\n if (typeof executor !== 'function') {\n throw new TypeError('executor must be a function.');\n }\n\n var resolvePromise;\n this.promise = new Promise(function promiseExecutor(resolve) {\n resolvePromise = resolve;\n });\n\n var token = this;\n executor(function cancel(message) {\n if (token.reason) {\n // Cancellation has already been requested\n return;\n }\n\n token.reason = new Cancel(message);\n resolvePromise(token.reason);\n });\n}\n\n/**\n * Throws a `Cancel` if cancellation has been requested.\n */\nCancelToken.prototype.throwIfRequested = function throwIfRequested() {\n if (this.reason) {\n throw this.reason;\n }\n};\n\n/**\n * Returns an object that contains a new `CancelToken` and a function that, when called,\n * cancels the `CancelToken`.\n */\nCancelToken.source = function source() {\n var cancel;\n var token = new CancelToken(function executor(c) {\n cancel = c;\n });\n return {\n token: token,\n cancel: cancel\n };\n};\n\nmodule.exports = CancelToken;\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/cancel/CancelToken.js\n// module id = 24\n// module chunks = 0","'use strict';\n\n/**\n * Syntactic sugar for invoking a function and expanding an array for arguments.\n *\n * Common use case would be to use `Function.prototype.apply`.\n *\n * ```js\n * function f(x, y, z) {}\n * var args = [1, 2, 3];\n * f.apply(null, args);\n * ```\n *\n * With `spread` this example can be re-written.\n *\n * ```js\n * spread(function(x, y, z) {})([1, 2, 3]);\n * ```\n *\n * @param {Function} callback\n * @returns {Function}\n */\nmodule.exports = function spread(callback) {\n return function wrap(arr) {\n return callback.apply(null, arr);\n };\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/helpers/spread.js\n// module id = 25\n// module chunks = 0"],"sourceRoot":""} \ No newline at end of file diff --git a/node_modules/axios/dist/axios.min.js b/node_modules/axios/dist/axios.min.js new file mode 100644 index 0000000000..0f36816306 --- /dev/null +++ b/node_modules/axios/dist/axios.min.js @@ -0,0 +1,9 @@ +/* axios v0.19.0 | (c) 2019 by Matt Zabriskie */ +!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.axios=t():e.axios=t()}(this,function(){return function(e){function t(r){if(n[r])return n[r].exports;var o=n[r]={exports:{},id:r,loaded:!1};return e[r].call(o.exports,o,o.exports,t),o.loaded=!0,o.exports}var n={};return t.m=e,t.c=n,t.p="",t(0)}([function(e,t,n){e.exports=n(1)},function(e,t,n){"use strict";function r(e){var t=new i(e),n=s(i.prototype.request,t);return o.extend(n,i.prototype,t),o.extend(n,t),n}var o=n(2),s=n(3),i=n(5),a=n(22),u=n(11),c=r(u);c.Axios=i,c.create=function(e){return r(a(c.defaults,e))},c.Cancel=n(23),c.CancelToken=n(24),c.isCancel=n(10),c.all=function(e){return Promise.all(e)},c.spread=n(25),e.exports=c,e.exports.default=c},function(e,t,n){"use strict";function r(e){return"[object Array]"===j.call(e)}function o(e){return"[object ArrayBuffer]"===j.call(e)}function s(e){return"undefined"!=typeof FormData&&e instanceof FormData}function i(e){var t;return t="undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&e.buffer instanceof ArrayBuffer}function a(e){return"string"==typeof e}function u(e){return"number"==typeof e}function c(e){return"undefined"==typeof e}function f(e){return null!==e&&"object"==typeof e}function p(e){return"[object Date]"===j.call(e)}function d(e){return"[object File]"===j.call(e)}function l(e){return"[object Blob]"===j.call(e)}function h(e){return"[object Function]"===j.call(e)}function m(e){return f(e)&&h(e.pipe)}function y(e){return"undefined"!=typeof URLSearchParams&&e instanceof URLSearchParams}function g(e){return e.replace(/^\s*/,"").replace(/\s*$/,"")}function x(){return("undefined"==typeof navigator||"ReactNative"!==navigator.product&&"NativeScript"!==navigator.product&&"NS"!==navigator.product)&&("undefined"!=typeof window&&"undefined"!=typeof document)}function v(e,t){if(null!==e&&"undefined"!=typeof e)if("object"!=typeof e&&(e=[e]),r(e))for(var n=0,o=e.length;n + * @license MIT + */ +e.exports=function(e){return null!=e&&null!=e.constructor&&"function"==typeof e.constructor.isBuffer&&e.constructor.isBuffer(e)}},function(e,t,n){"use strict";function r(e){this.defaults=e,this.interceptors={request:new i,response:new i}}var o=n(2),s=n(6),i=n(7),a=n(8),u=n(22);r.prototype.request=function(e){"string"==typeof e?(e=arguments[1]||{},e.url=arguments[0]):e=e||{},e=u(this.defaults,e),e.method=e.method?e.method.toLowerCase():"get";var t=[a,void 0],n=Promise.resolve(e);for(this.interceptors.request.forEach(function(e){t.unshift(e.fulfilled,e.rejected)}),this.interceptors.response.forEach(function(e){t.push(e.fulfilled,e.rejected)});t.length;)n=n.then(t.shift(),t.shift());return n},r.prototype.getUri=function(e){return e=u(this.defaults,e),s(e.url,e.params,e.paramsSerializer).replace(/^\?/,"")},o.forEach(["delete","get","head","options"],function(e){r.prototype[e]=function(t,n){return this.request(o.merge(n||{},{method:e,url:t}))}}),o.forEach(["post","put","patch"],function(e){r.prototype[e]=function(t,n,r){return this.request(o.merge(r||{},{method:e,url:t,data:n}))}}),e.exports=r},function(e,t,n){"use strict";function r(e){return encodeURIComponent(e).replace(/%40/gi,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}var o=n(2);e.exports=function(e,t,n){if(!t)return e;var s;if(n)s=n(t);else if(o.isURLSearchParams(t))s=t.toString();else{var i=[];o.forEach(t,function(e,t){null!==e&&"undefined"!=typeof e&&(o.isArray(e)?t+="[]":e=[e],o.forEach(e,function(e){o.isDate(e)?e=e.toISOString():o.isObject(e)&&(e=JSON.stringify(e)),i.push(r(t)+"="+r(e))}))}),s=i.join("&")}if(s){var a=e.indexOf("#");a!==-1&&(e=e.slice(0,a)),e+=(e.indexOf("?")===-1?"?":"&")+s}return e}},function(e,t,n){"use strict";function r(){this.handlers=[]}var o=n(2);r.prototype.use=function(e,t){return this.handlers.push({fulfilled:e,rejected:t}),this.handlers.length-1},r.prototype.eject=function(e){this.handlers[e]&&(this.handlers[e]=null)},r.prototype.forEach=function(e){o.forEach(this.handlers,function(t){null!==t&&e(t)})},e.exports=r},function(e,t,n){"use strict";function r(e){e.cancelToken&&e.cancelToken.throwIfRequested()}var o=n(2),s=n(9),i=n(10),a=n(11),u=n(20),c=n(21);e.exports=function(e){r(e),e.baseURL&&!u(e.url)&&(e.url=c(e.baseURL,e.url)),e.headers=e.headers||{},e.data=s(e.data,e.headers,e.transformRequest),e.headers=o.merge(e.headers.common||{},e.headers[e.method]||{},e.headers||{}),o.forEach(["delete","get","head","post","put","patch","common"],function(t){delete e.headers[t]});var t=e.adapter||a.adapter;return t(e).then(function(t){return r(e),t.data=s(t.data,t.headers,e.transformResponse),t},function(t){return i(t)||(r(e),t&&t.response&&(t.response.data=s(t.response.data,t.response.headers,e.transformResponse))),Promise.reject(t)})}},function(e,t,n){"use strict";var r=n(2);e.exports=function(e,t,n){return r.forEach(n,function(n){e=n(e,t)}),e}},function(e,t){"use strict";e.exports=function(e){return!(!e||!e.__CANCEL__)}},function(e,t,n){"use strict";function r(e,t){!s.isUndefined(e)&&s.isUndefined(e["Content-Type"])&&(e["Content-Type"]=t)}function o(){var e;return"undefined"!=typeof process&&"[object process]"===Object.prototype.toString.call(process)?e=n(13):"undefined"!=typeof XMLHttpRequest&&(e=n(13)),e}var s=n(2),i=n(12),a={"Content-Type":"application/x-www-form-urlencoded"},u={adapter:o(),transformRequest:[function(e,t){return i(t,"Accept"),i(t,"Content-Type"),s.isFormData(e)||s.isArrayBuffer(e)||s.isBuffer(e)||s.isStream(e)||s.isFile(e)||s.isBlob(e)?e:s.isArrayBufferView(e)?e.buffer:s.isURLSearchParams(e)?(r(t,"application/x-www-form-urlencoded;charset=utf-8"),e.toString()):s.isObject(e)?(r(t,"application/json;charset=utf-8"),JSON.stringify(e)):e}],transformResponse:[function(e){if("string"==typeof e)try{e=JSON.parse(e)}catch(e){}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,validateStatus:function(e){return e>=200&&e<300}};u.headers={common:{Accept:"application/json, text/plain, */*"}},s.forEach(["delete","get","head"],function(e){u.headers[e]={}}),s.forEach(["post","put","patch"],function(e){u.headers[e]=s.merge(a)}),e.exports=u},function(e,t,n){"use strict";var r=n(2);e.exports=function(e,t){r.forEach(e,function(n,r){r!==t&&r.toUpperCase()===t.toUpperCase()&&(e[t]=n,delete e[r])})}},function(e,t,n){"use strict";var r=n(2),o=n(14),s=n(6),i=n(17),a=n(18),u=n(15);e.exports=function(e){return new Promise(function(t,c){var f=e.data,p=e.headers;r.isFormData(f)&&delete p["Content-Type"];var d=new XMLHttpRequest;if(e.auth){var l=e.auth.username||"",h=e.auth.password||"";p.Authorization="Basic "+btoa(l+":"+h)}if(d.open(e.method.toUpperCase(),s(e.url,e.params,e.paramsSerializer),!0),d.timeout=e.timeout,d.onreadystatechange=function(){if(d&&4===d.readyState&&(0!==d.status||d.responseURL&&0===d.responseURL.indexOf("file:"))){var n="getAllResponseHeaders"in d?i(d.getAllResponseHeaders()):null,r=e.responseType&&"text"!==e.responseType?d.response:d.responseText,s={data:r,status:d.status,statusText:d.statusText,headers:n,config:e,request:d};o(t,c,s),d=null}},d.onabort=function(){d&&(c(u("Request aborted",e,"ECONNABORTED",d)),d=null)},d.onerror=function(){c(u("Network Error",e,null,d)),d=null},d.ontimeout=function(){c(u("timeout of "+e.timeout+"ms exceeded",e,"ECONNABORTED",d)),d=null},r.isStandardBrowserEnv()){var m=n(19),y=(e.withCredentials||a(e.url))&&e.xsrfCookieName?m.read(e.xsrfCookieName):void 0;y&&(p[e.xsrfHeaderName]=y)}if("setRequestHeader"in d&&r.forEach(p,function(e,t){"undefined"==typeof f&&"content-type"===t.toLowerCase()?delete p[t]:d.setRequestHeader(t,e)}),e.withCredentials&&(d.withCredentials=!0),e.responseType)try{d.responseType=e.responseType}catch(t){if("json"!==e.responseType)throw t}"function"==typeof e.onDownloadProgress&&d.addEventListener("progress",e.onDownloadProgress),"function"==typeof e.onUploadProgress&&d.upload&&d.upload.addEventListener("progress",e.onUploadProgress),e.cancelToken&&e.cancelToken.promise.then(function(e){d&&(d.abort(),c(e),d=null)}),void 0===f&&(f=null),d.send(f)})}},function(e,t,n){"use strict";var r=n(15);e.exports=function(e,t,n){var o=n.config.validateStatus;!o||o(n.status)?e(n):t(r("Request failed with status code "+n.status,n.config,null,n.request,n))}},function(e,t,n){"use strict";var r=n(16);e.exports=function(e,t,n,o,s){var i=new Error(e);return r(i,t,n,o,s)}},function(e,t){"use strict";e.exports=function(e,t,n,r,o){return e.config=t,n&&(e.code=n),e.request=r,e.response=o,e.isAxiosError=!0,e.toJSON=function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:this.config,code:this.code}},e}},function(e,t,n){"use strict";var r=n(2),o=["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"];e.exports=function(e){var t,n,s,i={};return e?(r.forEach(e.split("\n"),function(e){if(s=e.indexOf(":"),t=r.trim(e.substr(0,s)).toLowerCase(),n=r.trim(e.substr(s+1)),t){if(i[t]&&o.indexOf(t)>=0)return;"set-cookie"===t?i[t]=(i[t]?i[t]:[]).concat([n]):i[t]=i[t]?i[t]+", "+n:n}}),i):i}},function(e,t,n){"use strict";var r=n(2);e.exports=r.isStandardBrowserEnv()?function(){function e(e){var t=e;return n&&(o.setAttribute("href",t),t=o.href),o.setAttribute("href",t),{href:o.href,protocol:o.protocol?o.protocol.replace(/:$/,""):"",host:o.host,search:o.search?o.search.replace(/^\?/,""):"",hash:o.hash?o.hash.replace(/^#/,""):"",hostname:o.hostname,port:o.port,pathname:"/"===o.pathname.charAt(0)?o.pathname:"/"+o.pathname}}var t,n=/(msie|trident)/i.test(navigator.userAgent),o=document.createElement("a");return t=e(window.location.href),function(n){var o=r.isString(n)?e(n):n;return o.protocol===t.protocol&&o.host===t.host}}():function(){return function(){return!0}}()},function(e,t,n){"use strict";var r=n(2);e.exports=r.isStandardBrowserEnv()?function(){return{write:function(e,t,n,o,s,i){var a=[];a.push(e+"="+encodeURIComponent(t)),r.isNumber(n)&&a.push("expires="+new Date(n).toGMTString()),r.isString(o)&&a.push("path="+o),r.isString(s)&&a.push("domain="+s),i===!0&&a.push("secure"),document.cookie=a.join("; ")},read:function(e){var t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove:function(e){this.write(e,"",Date.now()-864e5)}}}():function(){return{write:function(){},read:function(){return null},remove:function(){}}}()},function(e,t){"use strict";e.exports=function(e){return/^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(e)}},function(e,t){"use strict";e.exports=function(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}},function(e,t,n){"use strict";var r=n(2);e.exports=function(e,t){t=t||{};var n={};return r.forEach(["url","method","params","data"],function(e){"undefined"!=typeof t[e]&&(n[e]=t[e])}),r.forEach(["headers","auth","proxy"],function(o){r.isObject(t[o])?n[o]=r.deepMerge(e[o],t[o]):"undefined"!=typeof t[o]?n[o]=t[o]:r.isObject(e[o])?n[o]=r.deepMerge(e[o]):"undefined"!=typeof e[o]&&(n[o]=e[o])}),r.forEach(["baseURL","transformRequest","transformResponse","paramsSerializer","timeout","withCredentials","adapter","responseType","xsrfCookieName","xsrfHeaderName","onUploadProgress","onDownloadProgress","maxContentLength","validateStatus","maxRedirects","httpAgent","httpsAgent","cancelToken","socketPath"],function(r){"undefined"!=typeof t[r]?n[r]=t[r]:"undefined"!=typeof e[r]&&(n[r]=e[r])}),n}},function(e,t){"use strict";function n(e){this.message=e}n.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")},n.prototype.__CANCEL__=!0,e.exports=n},function(e,t,n){"use strict";function r(e){if("function"!=typeof e)throw new TypeError("executor must be a function.");var t;this.promise=new Promise(function(e){t=e});var n=this;e(function(e){n.reason||(n.reason=new o(e),t(n.reason))})}var o=n(23);r.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},r.source=function(){var e,t=new r(function(t){e=t});return{token:t,cancel:e}},e.exports=r},function(e,t){"use strict";e.exports=function(e){return function(t){return e.apply(null,t)}}}])}); +//# sourceMappingURL=axios.min.map \ No newline at end of file diff --git a/node_modules/axios/dist/axios.min.map b/node_modules/axios/dist/axios.min.map new file mode 100644 index 0000000000..8dcff1cd5b --- /dev/null +++ b/node_modules/axios/dist/axios.min.map @@ -0,0 +1 @@ +{"version":3,"sources":["webpack:///webpack/universalModuleDefinition","webpack:///axios.min.js","webpack:///webpack/bootstrap 3e317bb69558239a2225","webpack:///./index.js","webpack:///./lib/axios.js","webpack:///./lib/utils.js","webpack:///./lib/helpers/bind.js","webpack:///./~/is-buffer/index.js","webpack:///./lib/core/Axios.js","webpack:///./lib/helpers/buildURL.js","webpack:///./lib/core/InterceptorManager.js","webpack:///./lib/core/dispatchRequest.js","webpack:///./lib/core/transformData.js","webpack:///./lib/cancel/isCancel.js","webpack:///./lib/defaults.js","webpack:///./lib/helpers/normalizeHeaderName.js","webpack:///./lib/adapters/xhr.js","webpack:///./lib/core/settle.js","webpack:///./lib/core/createError.js","webpack:///./lib/core/enhanceError.js","webpack:///./lib/helpers/parseHeaders.js","webpack:///./lib/helpers/isURLSameOrigin.js","webpack:///./lib/helpers/cookies.js","webpack:///./lib/helpers/isAbsoluteURL.js","webpack:///./lib/helpers/combineURLs.js","webpack:///./lib/core/mergeConfig.js","webpack:///./lib/cancel/Cancel.js","webpack:///./lib/cancel/CancelToken.js","webpack:///./lib/helpers/spread.js"],"names":["root","factory","exports","module","define","amd","this","modules","__webpack_require__","moduleId","installedModules","id","loaded","call","m","c","p","createInstance","defaultConfig","context","Axios","instance","bind","prototype","request","utils","extend","mergeConfig","defaults","axios","create","instanceConfig","Cancel","CancelToken","isCancel","all","promises","Promise","spread","default","isArray","val","toString","isArrayBuffer","isFormData","FormData","isArrayBufferView","result","ArrayBuffer","isView","buffer","isString","isNumber","isUndefined","isObject","isDate","isFile","isBlob","isFunction","isStream","pipe","isURLSearchParams","URLSearchParams","trim","str","replace","isStandardBrowserEnv","navigator","product","window","document","forEach","obj","fn","i","l","length","key","Object","hasOwnProperty","merge","assignValue","arguments","deepMerge","a","b","thisArg","isBuffer","args","Array","apply","constructor","interceptors","InterceptorManager","response","buildURL","dispatchRequest","config","url","method","toLowerCase","chain","undefined","promise","resolve","interceptor","unshift","fulfilled","rejected","push","then","shift","getUri","params","paramsSerializer","data","encode","encodeURIComponent","serializedParams","parts","v","toISOString","JSON","stringify","join","hashmarkIndex","indexOf","slice","handlers","use","eject","h","throwIfCancellationRequested","cancelToken","throwIfRequested","transformData","isAbsoluteURL","combineURLs","baseURL","headers","transformRequest","common","adapter","transformResponse","reason","reject","fns","value","__CANCEL__","setContentTypeIfUnset","getDefaultAdapter","process","XMLHttpRequest","normalizeHeaderName","DEFAULT_CONTENT_TYPE","Content-Type","parse","e","timeout","xsrfCookieName","xsrfHeaderName","maxContentLength","validateStatus","status","Accept","normalizedName","name","toUpperCase","settle","parseHeaders","isURLSameOrigin","createError","requestData","requestHeaders","auth","username","password","Authorization","btoa","open","onreadystatechange","readyState","responseURL","responseHeaders","getAllResponseHeaders","responseData","responseType","responseText","statusText","onabort","onerror","ontimeout","cookies","xsrfValue","withCredentials","read","setRequestHeader","onDownloadProgress","addEventListener","onUploadProgress","upload","cancel","abort","send","enhanceError","message","code","error","Error","isAxiosError","toJSON","description","number","fileName","lineNumber","columnNumber","stack","ignoreDuplicateOf","parsed","split","line","substr","concat","resolveURL","href","msie","urlParsingNode","setAttribute","protocol","host","search","hash","hostname","port","pathname","charAt","originURL","test","userAgent","createElement","location","requestURL","write","expires","path","domain","secure","cookie","Date","toGMTString","match","RegExp","decodeURIComponent","remove","now","relativeURL","config1","config2","prop","executor","TypeError","resolvePromise","token","source","callback","arr"],"mappings":"CAAA,SAAAA,EAAAC,GACA,gBAAAC,UAAA,gBAAAC,QACAA,OAAAD,QAAAD,IACA,kBAAAG,gBAAAC,IACAD,UAAAH,GACA,gBAAAC,SACAA,QAAA,MAAAD,IAEAD,EAAA,MAAAC,KACCK,KAAA,WACD,MCAgB,UAAUC,GCN1B,QAAAC,GAAAC,GAGA,GAAAC,EAAAD,GACA,MAAAC,GAAAD,GAAAP,OAGA,IAAAC,GAAAO,EAAAD,IACAP,WACAS,GAAAF,EACAG,QAAA,EAUA,OANAL,GAAAE,GAAAI,KAAAV,EAAAD,QAAAC,IAAAD,QAAAM,GAGAL,EAAAS,QAAA,EAGAT,EAAAD,QAvBA,GAAAQ,KAqCA,OATAF,GAAAM,EAAAP,EAGAC,EAAAO,EAAAL,EAGAF,EAAAQ,EAAA,GAGAR,EAAA,KDgBM,SAAUL,EAAQD,EAASM,GEtDjCL,EAAAD,QAAAM,EAAA,IF4DM,SAAUL,EAAQD,EAASM,GG5DjC,YAcA,SAAAS,GAAAC,GACA,GAAAC,GAAA,GAAAC,GAAAF,GACAG,EAAAC,EAAAF,EAAAG,UAAAC,QAAAL,EAQA,OALAM,GAAAC,OAAAL,EAAAD,EAAAG,UAAAJ,GAGAM,EAAAC,OAAAL,EAAAF,GA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AA,KAGA7K,EAAAT,UAAA6H,YAAA,EAEAjJ,EAAAD,QAAA8B,GzB8gDM,SAAU7B,EAAQD,EAASM,G0BhiDjC,YAUA,SAAAyB,GAAAkO,GACA,qBAAAA,GACA,SAAAC,WAAA,+BAGA,IAAAC,EACA/P,MAAAiG,QAAA,GAAAlE,SAAA,SAAAmE,GACA6J,EAAA7J,GAGA,IAAA8J,GAAAhQ,IACA6P,GAAA,SAAAtD,GACAyD,EAAAtH,SAKAsH,EAAAtH,OAAA,GAAAhH,GAAA6K,GACAwD,EAAAC,EAAAtH,WA1BA,GAAAhH,GAAAxB,EAAA,GAiCAyB,GAAAV,UAAA+G,iBAAA,WACA,GAAAhI,KAAA0I,OACA,KAAA1I,MAAA0I,QAQA/G,EAAAsO,OAAA,WACA,GAAA9D,GACA6D,EAAA,GAAArO,GAAA,SAAAlB,GACA0L,EAAA1L,GAEA,QACAuP,QACA7D,WAIAtM,EAAAD,QAAA+B,G1BuiDM,SAAU9B,EAAQD,G2B/lDxB,YAsBAC,GAAAD,QAAA,SAAAsQ,GACA,gBAAAC,GACA,MAAAD,GAAA9K,MAAA,KAAA+K","file":"axios.min.js","sourcesContent":["(function webpackUniversalModuleDefinition(root, factory) {\n\tif(typeof exports === 'object' && typeof module === 'object')\n\t\tmodule.exports = factory();\n\telse if(typeof define === 'function' && define.amd)\n\t\tdefine([], factory);\n\telse if(typeof exports === 'object')\n\t\texports[\"axios\"] = factory();\n\telse\n\t\troot[\"axios\"] = factory();\n})(this, function() {\nreturn \n\n\n// WEBPACK FOOTER //\n// webpack/universalModuleDefinition","(function webpackUniversalModuleDefinition(root, factory) {\n\tif(typeof exports === 'object' && typeof module === 'object')\n\t\tmodule.exports = factory();\n\telse if(typeof define === 'function' && define.amd)\n\t\tdefine([], factory);\n\telse if(typeof exports === 'object')\n\t\texports[\"axios\"] = factory();\n\telse\n\t\troot[\"axios\"] = factory();\n})(this, function() {\nreturn /******/ (function(modules) { // webpackBootstrap\n/******/ \t// The module cache\n/******/ \tvar installedModules = {};\n/******/\n/******/ \t// The require function\n/******/ \tfunction __webpack_require__(moduleId) {\n/******/\n/******/ \t\t// Check if module is in cache\n/******/ \t\tif(installedModules[moduleId])\n/******/ \t\t\treturn installedModules[moduleId].exports;\n/******/\n/******/ \t\t// Create a new module (and put it into the cache)\n/******/ \t\tvar module = installedModules[moduleId] = {\n/******/ \t\t\texports: {},\n/******/ \t\t\tid: moduleId,\n/******/ \t\t\tloaded: false\n/******/ \t\t};\n/******/\n/******/ \t\t// Execute the module function\n/******/ \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n/******/\n/******/ \t\t// Flag the module as loaded\n/******/ \t\tmodule.loaded = true;\n/******/\n/******/ \t\t// Return the exports of the module\n/******/ \t\treturn module.exports;\n/******/ \t}\n/******/\n/******/\n/******/ \t// expose the modules object (__webpack_modules__)\n/******/ \t__webpack_require__.m = modules;\n/******/\n/******/ \t// expose the module cache\n/******/ \t__webpack_require__.c = installedModules;\n/******/\n/******/ \t// __webpack_public_path__\n/******/ \t__webpack_require__.p = \"\";\n/******/\n/******/ \t// Load entry module and return exports\n/******/ \treturn __webpack_require__(0);\n/******/ })\n/************************************************************************/\n/******/ ([\n/* 0 */\n/***/ (function(module, exports, __webpack_require__) {\n\n\tmodule.exports = __webpack_require__(1);\n\n/***/ }),\n/* 1 */\n/***/ (function(module, exports, __webpack_require__) {\n\n\t'use strict';\n\t\n\tvar utils = __webpack_require__(2);\n\tvar bind = __webpack_require__(3);\n\tvar Axios = __webpack_require__(5);\n\tvar mergeConfig = __webpack_require__(22);\n\tvar defaults = __webpack_require__(11);\n\t\n\t/**\n\t * Create an instance of Axios\n\t *\n\t * @param {Object} defaultConfig The default config for the instance\n\t * @return {Axios} A new instance of Axios\n\t */\n\tfunction createInstance(defaultConfig) {\n\t var context = new Axios(defaultConfig);\n\t var instance = bind(Axios.prototype.request, context);\n\t\n\t // Copy axios.prototype to instance\n\t utils.extend(instance, Axios.prototype, context);\n\t\n\t // Copy context to instance\n\t utils.extend(instance, context);\n\t\n\t return instance;\n\t}\n\t\n\t// Create the default instance to be exported\n\tvar axios = createInstance(defaults);\n\t\n\t// Expose Axios class to allow class inheritance\n\taxios.Axios = Axios;\n\t\n\t// Factory for creating new instances\n\taxios.create = function create(instanceConfig) {\n\t return createInstance(mergeConfig(axios.defaults, instanceConfig));\n\t};\n\t\n\t// Expose Cancel & CancelToken\n\taxios.Cancel = __webpack_require__(23);\n\taxios.CancelToken = __webpack_require__(24);\n\taxios.isCancel = __webpack_require__(10);\n\t\n\t// Expose all/spread\n\taxios.all = function all(promises) {\n\t return Promise.all(promises);\n\t};\n\taxios.spread = __webpack_require__(25);\n\t\n\tmodule.exports = axios;\n\t\n\t// Allow use of default import syntax in TypeScript\n\tmodule.exports.default = axios;\n\n\n/***/ }),\n/* 2 */\n/***/ (function(module, exports, __webpack_require__) {\n\n\t'use strict';\n\t\n\tvar bind = __webpack_require__(3);\n\tvar isBuffer = __webpack_require__(4);\n\t\n\t/*global toString:true*/\n\t\n\t// utils is a library of generic helper functions non-specific to axios\n\t\n\tvar toString = Object.prototype.toString;\n\t\n\t/**\n\t * Determine if a value is an Array\n\t *\n\t * @param {Object} val The value to test\n\t * @returns {boolean} True if value is an Array, otherwise false\n\t */\n\tfunction isArray(val) {\n\t return toString.call(val) === '[object Array]';\n\t}\n\t\n\t/**\n\t * Determine if a value is an ArrayBuffer\n\t *\n\t * @param {Object} val The value to test\n\t * @returns {boolean} True if value is an ArrayBuffer, otherwise false\n\t */\n\tfunction isArrayBuffer(val) {\n\t return toString.call(val) === '[object ArrayBuffer]';\n\t}\n\t\n\t/**\n\t * Determine if a value is a FormData\n\t *\n\t * @param {Object} val The value to test\n\t * @returns {boolean} True if value is an FormData, otherwise false\n\t */\n\tfunction isFormData(val) {\n\t return (typeof FormData !== 'undefined') && (val instanceof FormData);\n\t}\n\t\n\t/**\n\t * Determine if a value is a view on an ArrayBuffer\n\t *\n\t * @param {Object} val The value to test\n\t * @returns {boolean} True if value is a view on an ArrayBuffer, otherwise false\n\t */\n\tfunction isArrayBufferView(val) {\n\t var result;\n\t if ((typeof ArrayBuffer !== 'undefined') && (ArrayBuffer.isView)) {\n\t result = ArrayBuffer.isView(val);\n\t } else {\n\t result = (val) && (val.buffer) && (val.buffer instanceof ArrayBuffer);\n\t }\n\t return result;\n\t}\n\t\n\t/**\n\t * Determine if a value is a String\n\t *\n\t * @param {Object} val The value to test\n\t * @returns {boolean} True if value is a String, otherwise false\n\t */\n\tfunction isString(val) {\n\t return typeof val === 'string';\n\t}\n\t\n\t/**\n\t * Determine if a value is a Number\n\t *\n\t * @param {Object} val The value to test\n\t * @returns {boolean} True if value is a Number, otherwise false\n\t */\n\tfunction isNumber(val) {\n\t return typeof val === 'number';\n\t}\n\t\n\t/**\n\t * Determine if a value is undefined\n\t *\n\t * @param {Object} val The value to test\n\t * @returns {boolean} True if the value is undefined, otherwise false\n\t */\n\tfunction isUndefined(val) {\n\t return typeof val === 'undefined';\n\t}\n\t\n\t/**\n\t * Determine if a value is an Object\n\t *\n\t * @param {Object} val The value to test\n\t * @returns {boolean} True if value is an Object, otherwise false\n\t */\n\tfunction isObject(val) {\n\t return val !== null && typeof val === 'object';\n\t}\n\t\n\t/**\n\t * Determine if a value is a Date\n\t *\n\t * @param {Object} val The value to test\n\t * @returns {boolean} True if value is a Date, otherwise false\n\t */\n\tfunction isDate(val) {\n\t return toString.call(val) === '[object Date]';\n\t}\n\t\n\t/**\n\t * Determine if a value is a File\n\t *\n\t * @param {Object} val The value to test\n\t * @returns {boolean} True if value is a File, otherwise false\n\t */\n\tfunction isFile(val) {\n\t return toString.call(val) === '[object File]';\n\t}\n\t\n\t/**\n\t * Determine if a value is a Blob\n\t *\n\t * @param {Object} val The value to test\n\t * @returns {boolean} True if value is a Blob, otherwise false\n\t */\n\tfunction isBlob(val) {\n\t return toString.call(val) === '[object Blob]';\n\t}\n\t\n\t/**\n\t * Determine if a value is a Function\n\t *\n\t * @param {Object} val The value to test\n\t * @returns {boolean} True if value is a Function, otherwise false\n\t */\n\tfunction isFunction(val) {\n\t return toString.call(val) === '[object Function]';\n\t}\n\t\n\t/**\n\t * Determine if a value is a Stream\n\t *\n\t * @param {Object} val The value to test\n\t * @returns {boolean} True if value is a Stream, otherwise false\n\t */\n\tfunction isStream(val) {\n\t return isObject(val) && isFunction(val.pipe);\n\t}\n\t\n\t/**\n\t * Determine if a value is a URLSearchParams object\n\t *\n\t * @param {Object} val The value to test\n\t * @returns {boolean} True if value is a URLSearchParams object, otherwise false\n\t */\n\tfunction isURLSearchParams(val) {\n\t return typeof URLSearchParams !== 'undefined' && val instanceof URLSearchParams;\n\t}\n\t\n\t/**\n\t * Trim excess whitespace off the beginning and end of a string\n\t *\n\t * @param {String} str The String to trim\n\t * @returns {String} The String freed of excess whitespace\n\t */\n\tfunction trim(str) {\n\t return str.replace(/^\\s*/, '').replace(/\\s*$/, '');\n\t}\n\t\n\t/**\n\t * Determine if we're running in a standard browser environment\n\t *\n\t * This allows axios to run in a web worker, and react-native.\n\t * Both environments support XMLHttpRequest, but not fully standard globals.\n\t *\n\t * web workers:\n\t * typeof window -> undefined\n\t * typeof document -> undefined\n\t *\n\t * react-native:\n\t * navigator.product -> 'ReactNative'\n\t * nativescript\n\t * navigator.product -> 'NativeScript' or 'NS'\n\t */\n\tfunction isStandardBrowserEnv() {\n\t if (typeof navigator !== 'undefined' && (navigator.product === 'ReactNative' ||\n\t navigator.product === 'NativeScript' ||\n\t navigator.product === 'NS')) {\n\t return false;\n\t }\n\t return (\n\t typeof window !== 'undefined' &&\n\t typeof document !== 'undefined'\n\t );\n\t}\n\t\n\t/**\n\t * Iterate over an Array or an Object invoking a function for each item.\n\t *\n\t * If `obj` is an Array callback will be called passing\n\t * the value, index, and complete array for each item.\n\t *\n\t * If 'obj' is an Object callback will be called passing\n\t * the value, key, and complete object for each property.\n\t *\n\t * @param {Object|Array} obj The object to iterate\n\t * @param {Function} fn The callback to invoke for each item\n\t */\n\tfunction forEach(obj, fn) {\n\t // Don't bother if no value provided\n\t if (obj === null || typeof obj === 'undefined') {\n\t return;\n\t }\n\t\n\t // Force an array if not already something iterable\n\t if (typeof obj !== 'object') {\n\t /*eslint no-param-reassign:0*/\n\t obj = [obj];\n\t }\n\t\n\t if (isArray(obj)) {\n\t // Iterate over array values\n\t for (var i = 0, l = obj.length; i < l; i++) {\n\t fn.call(null, obj[i], i, obj);\n\t }\n\t } else {\n\t // Iterate over object keys\n\t for (var key in obj) {\n\t if (Object.prototype.hasOwnProperty.call(obj, key)) {\n\t fn.call(null, obj[key], key, obj);\n\t }\n\t }\n\t }\n\t}\n\t\n\t/**\n\t * Accepts varargs expecting each argument to be an object, then\n\t * immutably merges the properties of each object and returns result.\n\t *\n\t * When multiple objects contain the same key the later object in\n\t * the arguments list will take precedence.\n\t *\n\t * Example:\n\t *\n\t * ```js\n\t * var result = merge({foo: 123}, {foo: 456});\n\t * console.log(result.foo); // outputs 456\n\t * ```\n\t *\n\t * @param {Object} obj1 Object to merge\n\t * @returns {Object} Result of all merge properties\n\t */\n\tfunction merge(/* obj1, obj2, obj3, ... */) {\n\t var result = {};\n\t function assignValue(val, key) {\n\t if (typeof result[key] === 'object' && typeof val === 'object') {\n\t result[key] = merge(result[key], val);\n\t } else {\n\t result[key] = val;\n\t }\n\t }\n\t\n\t for (var i = 0, l = arguments.length; i < l; i++) {\n\t forEach(arguments[i], assignValue);\n\t }\n\t return result;\n\t}\n\t\n\t/**\n\t * Function equal to merge with the difference being that no reference\n\t * to original objects is kept.\n\t *\n\t * @see merge\n\t * @param {Object} obj1 Object to merge\n\t * @returns {Object} Result of all merge properties\n\t */\n\tfunction deepMerge(/* obj1, obj2, obj3, ... */) {\n\t var result = {};\n\t function assignValue(val, key) {\n\t if (typeof result[key] === 'object' && typeof val === 'object') {\n\t result[key] = deepMerge(result[key], val);\n\t } else if (typeof val === 'object') {\n\t result[key] = deepMerge({}, val);\n\t } else {\n\t result[key] = val;\n\t }\n\t }\n\t\n\t for (var i = 0, l = arguments.length; i < l; i++) {\n\t forEach(arguments[i], assignValue);\n\t }\n\t return result;\n\t}\n\t\n\t/**\n\t * Extends object a by mutably adding to it the properties of object b.\n\t *\n\t * @param {Object} a The object to be extended\n\t * @param {Object} b The object to copy properties from\n\t * @param {Object} thisArg The object to bind function to\n\t * @return {Object} The resulting value of object a\n\t */\n\tfunction extend(a, b, thisArg) {\n\t forEach(b, function assignValue(val, key) {\n\t if (thisArg && typeof val === 'function') {\n\t a[key] = bind(val, thisArg);\n\t } else {\n\t a[key] = val;\n\t }\n\t });\n\t return a;\n\t}\n\t\n\tmodule.exports = {\n\t isArray: isArray,\n\t isArrayBuffer: isArrayBuffer,\n\t isBuffer: isBuffer,\n\t isFormData: isFormData,\n\t isArrayBufferView: isArrayBufferView,\n\t isString: isString,\n\t isNumber: isNumber,\n\t isObject: isObject,\n\t isUndefined: isUndefined,\n\t isDate: isDate,\n\t isFile: isFile,\n\t isBlob: isBlob,\n\t isFunction: isFunction,\n\t isStream: isStream,\n\t isURLSearchParams: isURLSearchParams,\n\t isStandardBrowserEnv: isStandardBrowserEnv,\n\t forEach: forEach,\n\t merge: merge,\n\t deepMerge: deepMerge,\n\t extend: extend,\n\t trim: trim\n\t};\n\n\n/***/ }),\n/* 3 */\n/***/ (function(module, exports) {\n\n\t'use strict';\n\t\n\tmodule.exports = function bind(fn, thisArg) {\n\t return function wrap() {\n\t var args = new Array(arguments.length);\n\t for (var i = 0; i < args.length; i++) {\n\t args[i] = arguments[i];\n\t }\n\t return fn.apply(thisArg, args);\n\t };\n\t};\n\n\n/***/ }),\n/* 4 */\n/***/ (function(module, exports) {\n\n\t/*!\n\t * Determine if an object is a Buffer\n\t *\n\t * @author Feross Aboukhadijeh \n\t * @license MIT\n\t */\n\t\n\tmodule.exports = function isBuffer (obj) {\n\t return obj != null && obj.constructor != null &&\n\t typeof obj.constructor.isBuffer === 'function' && obj.constructor.isBuffer(obj)\n\t}\n\n\n/***/ }),\n/* 5 */\n/***/ (function(module, exports, __webpack_require__) {\n\n\t'use strict';\n\t\n\tvar utils = __webpack_require__(2);\n\tvar buildURL = __webpack_require__(6);\n\tvar InterceptorManager = __webpack_require__(7);\n\tvar dispatchRequest = __webpack_require__(8);\n\tvar mergeConfig = __webpack_require__(22);\n\t\n\t/**\n\t * Create a new instance of Axios\n\t *\n\t * @param {Object} instanceConfig The default config for the instance\n\t */\n\tfunction Axios(instanceConfig) {\n\t this.defaults = instanceConfig;\n\t this.interceptors = {\n\t request: new InterceptorManager(),\n\t response: new InterceptorManager()\n\t };\n\t}\n\t\n\t/**\n\t * Dispatch a request\n\t *\n\t * @param {Object} config The config specific for this request (merged with this.defaults)\n\t */\n\tAxios.prototype.request = function request(config) {\n\t /*eslint no-param-reassign:0*/\n\t // Allow for axios('example/url'[, config]) a la fetch API\n\t if (typeof config === 'string') {\n\t config = arguments[1] || {};\n\t config.url = arguments[0];\n\t } else {\n\t config = config || {};\n\t }\n\t\n\t config = mergeConfig(this.defaults, config);\n\t config.method = config.method ? config.method.toLowerCase() : 'get';\n\t\n\t // Hook up interceptors middleware\n\t var chain = [dispatchRequest, undefined];\n\t var promise = Promise.resolve(config);\n\t\n\t this.interceptors.request.forEach(function unshiftRequestInterceptors(interceptor) {\n\t chain.unshift(interceptor.fulfilled, interceptor.rejected);\n\t });\n\t\n\t this.interceptors.response.forEach(function pushResponseInterceptors(interceptor) {\n\t chain.push(interceptor.fulfilled, interceptor.rejected);\n\t });\n\t\n\t while (chain.length) {\n\t promise = promise.then(chain.shift(), chain.shift());\n\t }\n\t\n\t return promise;\n\t};\n\t\n\tAxios.prototype.getUri = function getUri(config) {\n\t config = mergeConfig(this.defaults, config);\n\t return buildURL(config.url, config.params, config.paramsSerializer).replace(/^\\?/, '');\n\t};\n\t\n\t// Provide aliases for supported request methods\n\tutils.forEach(['delete', 'get', 'head', 'options'], function forEachMethodNoData(method) {\n\t /*eslint func-names:0*/\n\t Axios.prototype[method] = function(url, config) {\n\t return this.request(utils.merge(config || {}, {\n\t method: method,\n\t url: url\n\t }));\n\t };\n\t});\n\t\n\tutils.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method) {\n\t /*eslint func-names:0*/\n\t Axios.prototype[method] = function(url, data, config) {\n\t return this.request(utils.merge(config || {}, {\n\t method: method,\n\t url: url,\n\t data: data\n\t }));\n\t };\n\t});\n\t\n\tmodule.exports = Axios;\n\n\n/***/ }),\n/* 6 */\n/***/ (function(module, exports, __webpack_require__) {\n\n\t'use strict';\n\t\n\tvar utils = __webpack_require__(2);\n\t\n\tfunction encode(val) {\n\t return encodeURIComponent(val).\n\t replace(/%40/gi, '@').\n\t replace(/%3A/gi, ':').\n\t replace(/%24/g, '$').\n\t replace(/%2C/gi, ',').\n\t replace(/%20/g, '+').\n\t replace(/%5B/gi, '[').\n\t replace(/%5D/gi, ']');\n\t}\n\t\n\t/**\n\t * Build a URL by appending params to the end\n\t *\n\t * @param {string} url The base of the url (e.g., http://www.google.com)\n\t * @param {object} [params] The params to be appended\n\t * @returns {string} The formatted url\n\t */\n\tmodule.exports = function buildURL(url, params, paramsSerializer) {\n\t /*eslint no-param-reassign:0*/\n\t if (!params) {\n\t return url;\n\t }\n\t\n\t var serializedParams;\n\t if (paramsSerializer) {\n\t serializedParams = paramsSerializer(params);\n\t } else if (utils.isURLSearchParams(params)) {\n\t serializedParams = params.toString();\n\t } else {\n\t var parts = [];\n\t\n\t utils.forEach(params, function serialize(val, key) {\n\t if (val === null || typeof val === 'undefined') {\n\t return;\n\t }\n\t\n\t if (utils.isArray(val)) {\n\t key = key + '[]';\n\t } else {\n\t val = [val];\n\t }\n\t\n\t utils.forEach(val, function parseValue(v) {\n\t if (utils.isDate(v)) {\n\t v = v.toISOString();\n\t } else if (utils.isObject(v)) {\n\t v = JSON.stringify(v);\n\t }\n\t parts.push(encode(key) + '=' + encode(v));\n\t });\n\t });\n\t\n\t serializedParams = parts.join('&');\n\t }\n\t\n\t if (serializedParams) {\n\t var hashmarkIndex = url.indexOf('#');\n\t if (hashmarkIndex !== -1) {\n\t url = url.slice(0, hashmarkIndex);\n\t }\n\t\n\t url += (url.indexOf('?') === -1 ? '?' : '&') + serializedParams;\n\t }\n\t\n\t return url;\n\t};\n\n\n/***/ }),\n/* 7 */\n/***/ (function(module, exports, __webpack_require__) {\n\n\t'use strict';\n\t\n\tvar utils = __webpack_require__(2);\n\t\n\tfunction InterceptorManager() {\n\t this.handlers = [];\n\t}\n\t\n\t/**\n\t * Add a new interceptor to the stack\n\t *\n\t * @param {Function} fulfilled The function to handle `then` for a `Promise`\n\t * @param {Function} rejected The function to handle `reject` for a `Promise`\n\t *\n\t * @return {Number} An ID used to remove interceptor later\n\t */\n\tInterceptorManager.prototype.use = function use(fulfilled, rejected) {\n\t this.handlers.push({\n\t fulfilled: fulfilled,\n\t rejected: rejected\n\t });\n\t return this.handlers.length - 1;\n\t};\n\t\n\t/**\n\t * Remove an interceptor from the stack\n\t *\n\t * @param {Number} id The ID that was returned by `use`\n\t */\n\tInterceptorManager.prototype.eject = function eject(id) {\n\t if (this.handlers[id]) {\n\t this.handlers[id] = null;\n\t }\n\t};\n\t\n\t/**\n\t * Iterate over all the registered interceptors\n\t *\n\t * This method is particularly useful for skipping over any\n\t * interceptors that may have become `null` calling `eject`.\n\t *\n\t * @param {Function} fn The function to call for each interceptor\n\t */\n\tInterceptorManager.prototype.forEach = function forEach(fn) {\n\t utils.forEach(this.handlers, function forEachHandler(h) {\n\t if (h !== null) {\n\t fn(h);\n\t }\n\t });\n\t};\n\t\n\tmodule.exports = InterceptorManager;\n\n\n/***/ }),\n/* 8 */\n/***/ (function(module, exports, __webpack_require__) {\n\n\t'use strict';\n\t\n\tvar utils = __webpack_require__(2);\n\tvar transformData = __webpack_require__(9);\n\tvar isCancel = __webpack_require__(10);\n\tvar defaults = __webpack_require__(11);\n\tvar isAbsoluteURL = __webpack_require__(20);\n\tvar combineURLs = __webpack_require__(21);\n\t\n\t/**\n\t * Throws a `Cancel` if cancellation has been requested.\n\t */\n\tfunction throwIfCancellationRequested(config) {\n\t if (config.cancelToken) {\n\t config.cancelToken.throwIfRequested();\n\t }\n\t}\n\t\n\t/**\n\t * Dispatch a request to the server using the configured adapter.\n\t *\n\t * @param {object} config The config that is to be used for the request\n\t * @returns {Promise} The Promise to be fulfilled\n\t */\n\tmodule.exports = function dispatchRequest(config) {\n\t throwIfCancellationRequested(config);\n\t\n\t // Support baseURL config\n\t if (config.baseURL && !isAbsoluteURL(config.url)) {\n\t config.url = combineURLs(config.baseURL, config.url);\n\t }\n\t\n\t // Ensure headers exist\n\t config.headers = config.headers || {};\n\t\n\t // Transform request data\n\t config.data = transformData(\n\t config.data,\n\t config.headers,\n\t config.transformRequest\n\t );\n\t\n\t // Flatten headers\n\t config.headers = utils.merge(\n\t config.headers.common || {},\n\t config.headers[config.method] || {},\n\t config.headers || {}\n\t );\n\t\n\t utils.forEach(\n\t ['delete', 'get', 'head', 'post', 'put', 'patch', 'common'],\n\t function cleanHeaderConfig(method) {\n\t delete config.headers[method];\n\t }\n\t );\n\t\n\t var adapter = config.adapter || defaults.adapter;\n\t\n\t return adapter(config).then(function onAdapterResolution(response) {\n\t throwIfCancellationRequested(config);\n\t\n\t // Transform response data\n\t response.data = transformData(\n\t response.data,\n\t response.headers,\n\t config.transformResponse\n\t );\n\t\n\t return response;\n\t }, function onAdapterRejection(reason) {\n\t if (!isCancel(reason)) {\n\t throwIfCancellationRequested(config);\n\t\n\t // Transform response data\n\t if (reason && reason.response) {\n\t reason.response.data = transformData(\n\t reason.response.data,\n\t reason.response.headers,\n\t config.transformResponse\n\t );\n\t }\n\t }\n\t\n\t return Promise.reject(reason);\n\t });\n\t};\n\n\n/***/ }),\n/* 9 */\n/***/ (function(module, exports, __webpack_require__) {\n\n\t'use strict';\n\t\n\tvar utils = __webpack_require__(2);\n\t\n\t/**\n\t * Transform the data for a request or a response\n\t *\n\t * @param {Object|String} data The data to be transformed\n\t * @param {Array} headers The headers for the request or response\n\t * @param {Array|Function} fns A single function or Array of functions\n\t * @returns {*} The resulting transformed data\n\t */\n\tmodule.exports = function transformData(data, headers, fns) {\n\t /*eslint no-param-reassign:0*/\n\t utils.forEach(fns, function transform(fn) {\n\t data = fn(data, headers);\n\t });\n\t\n\t return data;\n\t};\n\n\n/***/ }),\n/* 10 */\n/***/ (function(module, exports) {\n\n\t'use strict';\n\t\n\tmodule.exports = function isCancel(value) {\n\t return !!(value && value.__CANCEL__);\n\t};\n\n\n/***/ }),\n/* 11 */\n/***/ (function(module, exports, __webpack_require__) {\n\n\t'use strict';\n\t\n\tvar utils = __webpack_require__(2);\n\tvar normalizeHeaderName = __webpack_require__(12);\n\t\n\tvar DEFAULT_CONTENT_TYPE = {\n\t 'Content-Type': 'application/x-www-form-urlencoded'\n\t};\n\t\n\tfunction setContentTypeIfUnset(headers, value) {\n\t if (!utils.isUndefined(headers) && utils.isUndefined(headers['Content-Type'])) {\n\t headers['Content-Type'] = value;\n\t }\n\t}\n\t\n\tfunction getDefaultAdapter() {\n\t var adapter;\n\t // Only Node.JS has a process variable that is of [[Class]] process\n\t if (typeof process !== 'undefined' && Object.prototype.toString.call(process) === '[object process]') {\n\t // For node use HTTP adapter\n\t adapter = __webpack_require__(13);\n\t } else if (typeof XMLHttpRequest !== 'undefined') {\n\t // For browsers use XHR adapter\n\t adapter = __webpack_require__(13);\n\t }\n\t return adapter;\n\t}\n\t\n\tvar defaults = {\n\t adapter: getDefaultAdapter(),\n\t\n\t transformRequest: [function transformRequest(data, headers) {\n\t normalizeHeaderName(headers, 'Accept');\n\t normalizeHeaderName(headers, 'Content-Type');\n\t if (utils.isFormData(data) ||\n\t utils.isArrayBuffer(data) ||\n\t utils.isBuffer(data) ||\n\t utils.isStream(data) ||\n\t utils.isFile(data) ||\n\t utils.isBlob(data)\n\t ) {\n\t return data;\n\t }\n\t if (utils.isArrayBufferView(data)) {\n\t return data.buffer;\n\t }\n\t if (utils.isURLSearchParams(data)) {\n\t setContentTypeIfUnset(headers, 'application/x-www-form-urlencoded;charset=utf-8');\n\t return data.toString();\n\t }\n\t if (utils.isObject(data)) {\n\t setContentTypeIfUnset(headers, 'application/json;charset=utf-8');\n\t return JSON.stringify(data);\n\t }\n\t return data;\n\t }],\n\t\n\t transformResponse: [function transformResponse(data) {\n\t /*eslint no-param-reassign:0*/\n\t if (typeof data === 'string') {\n\t try {\n\t data = JSON.parse(data);\n\t } catch (e) { /* Ignore */ }\n\t }\n\t return data;\n\t }],\n\t\n\t /**\n\t * A timeout in milliseconds to abort a request. If set to 0 (default) a\n\t * timeout is not created.\n\t */\n\t timeout: 0,\n\t\n\t xsrfCookieName: 'XSRF-TOKEN',\n\t xsrfHeaderName: 'X-XSRF-TOKEN',\n\t\n\t maxContentLength: -1,\n\t\n\t validateStatus: function validateStatus(status) {\n\t return status >= 200 && status < 300;\n\t }\n\t};\n\t\n\tdefaults.headers = {\n\t common: {\n\t 'Accept': 'application/json, text/plain, */*'\n\t }\n\t};\n\t\n\tutils.forEach(['delete', 'get', 'head'], function forEachMethodNoData(method) {\n\t defaults.headers[method] = {};\n\t});\n\t\n\tutils.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method) {\n\t defaults.headers[method] = utils.merge(DEFAULT_CONTENT_TYPE);\n\t});\n\t\n\tmodule.exports = defaults;\n\n\n/***/ }),\n/* 12 */\n/***/ (function(module, exports, __webpack_require__) {\n\n\t'use strict';\n\t\n\tvar utils = __webpack_require__(2);\n\t\n\tmodule.exports = function normalizeHeaderName(headers, normalizedName) {\n\t utils.forEach(headers, function processHeader(value, name) {\n\t if (name !== normalizedName && name.toUpperCase() === normalizedName.toUpperCase()) {\n\t headers[normalizedName] = value;\n\t delete headers[name];\n\t }\n\t });\n\t};\n\n\n/***/ }),\n/* 13 */\n/***/ (function(module, exports, __webpack_require__) {\n\n\t'use strict';\n\t\n\tvar utils = __webpack_require__(2);\n\tvar settle = __webpack_require__(14);\n\tvar buildURL = __webpack_require__(6);\n\tvar parseHeaders = __webpack_require__(17);\n\tvar isURLSameOrigin = __webpack_require__(18);\n\tvar createError = __webpack_require__(15);\n\t\n\tmodule.exports = function xhrAdapter(config) {\n\t return new Promise(function dispatchXhrRequest(resolve, reject) {\n\t var requestData = config.data;\n\t var requestHeaders = config.headers;\n\t\n\t if (utils.isFormData(requestData)) {\n\t delete requestHeaders['Content-Type']; // Let the browser set it\n\t }\n\t\n\t var request = new XMLHttpRequest();\n\t\n\t // HTTP basic authentication\n\t if (config.auth) {\n\t var username = config.auth.username || '';\n\t var password = config.auth.password || '';\n\t requestHeaders.Authorization = 'Basic ' + btoa(username + ':' + password);\n\t }\n\t\n\t request.open(config.method.toUpperCase(), buildURL(config.url, config.params, config.paramsSerializer), true);\n\t\n\t // Set the request timeout in MS\n\t request.timeout = config.timeout;\n\t\n\t // Listen for ready state\n\t request.onreadystatechange = function handleLoad() {\n\t if (!request || request.readyState !== 4) {\n\t return;\n\t }\n\t\n\t // The request errored out and we didn't get a response, this will be\n\t // handled by onerror instead\n\t // With one exception: request that using file: protocol, most browsers\n\t // will return status as 0 even though it's a successful request\n\t if (request.status === 0 && !(request.responseURL && request.responseURL.indexOf('file:') === 0)) {\n\t return;\n\t }\n\t\n\t // Prepare the response\n\t var responseHeaders = 'getAllResponseHeaders' in request ? parseHeaders(request.getAllResponseHeaders()) : null;\n\t var responseData = !config.responseType || config.responseType === 'text' ? request.responseText : request.response;\n\t var response = {\n\t data: responseData,\n\t status: request.status,\n\t statusText: request.statusText,\n\t headers: responseHeaders,\n\t config: config,\n\t request: request\n\t };\n\t\n\t settle(resolve, reject, response);\n\t\n\t // Clean up request\n\t request = null;\n\t };\n\t\n\t // Handle browser request cancellation (as opposed to a manual cancellation)\n\t request.onabort = function handleAbort() {\n\t if (!request) {\n\t return;\n\t }\n\t\n\t reject(createError('Request aborted', config, 'ECONNABORTED', request));\n\t\n\t // Clean up request\n\t request = null;\n\t };\n\t\n\t // Handle low level network errors\n\t request.onerror = function handleError() {\n\t // Real errors are hidden from us by the browser\n\t // onerror should only fire if it's a network error\n\t reject(createError('Network Error', config, null, request));\n\t\n\t // Clean up request\n\t request = null;\n\t };\n\t\n\t // Handle timeout\n\t request.ontimeout = function handleTimeout() {\n\t reject(createError('timeout of ' + config.timeout + 'ms exceeded', config, 'ECONNABORTED',\n\t request));\n\t\n\t // Clean up request\n\t request = null;\n\t };\n\t\n\t // Add xsrf header\n\t // This is only done if running in a standard browser environment.\n\t // Specifically not if we're in a web worker, or react-native.\n\t if (utils.isStandardBrowserEnv()) {\n\t var cookies = __webpack_require__(19);\n\t\n\t // Add xsrf header\n\t var xsrfValue = (config.withCredentials || isURLSameOrigin(config.url)) && config.xsrfCookieName ?\n\t cookies.read(config.xsrfCookieName) :\n\t undefined;\n\t\n\t if (xsrfValue) {\n\t requestHeaders[config.xsrfHeaderName] = xsrfValue;\n\t }\n\t }\n\t\n\t // Add headers to the request\n\t if ('setRequestHeader' in request) {\n\t utils.forEach(requestHeaders, function setRequestHeader(val, key) {\n\t if (typeof requestData === 'undefined' && key.toLowerCase() === 'content-type') {\n\t // Remove Content-Type if data is undefined\n\t delete requestHeaders[key];\n\t } else {\n\t // Otherwise add header to the request\n\t request.setRequestHeader(key, val);\n\t }\n\t });\n\t }\n\t\n\t // Add withCredentials to request if needed\n\t if (config.withCredentials) {\n\t request.withCredentials = true;\n\t }\n\t\n\t // Add responseType to request if needed\n\t if (config.responseType) {\n\t try {\n\t request.responseType = config.responseType;\n\t } catch (e) {\n\t // Expected DOMException thrown by browsers not compatible XMLHttpRequest Level 2.\n\t // But, this can be suppressed for 'json' type as it can be parsed by default 'transformResponse' function.\n\t if (config.responseType !== 'json') {\n\t throw e;\n\t }\n\t }\n\t }\n\t\n\t // Handle progress if needed\n\t if (typeof config.onDownloadProgress === 'function') {\n\t request.addEventListener('progress', config.onDownloadProgress);\n\t }\n\t\n\t // Not all browsers support upload events\n\t if (typeof config.onUploadProgress === 'function' && request.upload) {\n\t request.upload.addEventListener('progress', config.onUploadProgress);\n\t }\n\t\n\t if (config.cancelToken) {\n\t // Handle cancellation\n\t config.cancelToken.promise.then(function onCanceled(cancel) {\n\t if (!request) {\n\t return;\n\t }\n\t\n\t request.abort();\n\t reject(cancel);\n\t // Clean up request\n\t request = null;\n\t });\n\t }\n\t\n\t if (requestData === undefined) {\n\t requestData = null;\n\t }\n\t\n\t // Send the request\n\t request.send(requestData);\n\t });\n\t};\n\n\n/***/ }),\n/* 14 */\n/***/ (function(module, exports, __webpack_require__) {\n\n\t'use strict';\n\t\n\tvar createError = __webpack_require__(15);\n\t\n\t/**\n\t * Resolve or reject a Promise based on response status.\n\t *\n\t * @param {Function} resolve A function that resolves the promise.\n\t * @param {Function} reject A function that rejects the promise.\n\t * @param {object} response The response.\n\t */\n\tmodule.exports = function settle(resolve, reject, response) {\n\t var validateStatus = response.config.validateStatus;\n\t if (!validateStatus || validateStatus(response.status)) {\n\t resolve(response);\n\t } else {\n\t reject(createError(\n\t 'Request failed with status code ' + response.status,\n\t response.config,\n\t null,\n\t response.request,\n\t response\n\t ));\n\t }\n\t};\n\n\n/***/ }),\n/* 15 */\n/***/ (function(module, exports, __webpack_require__) {\n\n\t'use strict';\n\t\n\tvar enhanceError = __webpack_require__(16);\n\t\n\t/**\n\t * Create an Error with the specified message, config, error code, request and response.\n\t *\n\t * @param {string} message The error message.\n\t * @param {Object} config The config.\n\t * @param {string} [code] The error code (for example, 'ECONNABORTED').\n\t * @param {Object} [request] The request.\n\t * @param {Object} [response] The response.\n\t * @returns {Error} The created error.\n\t */\n\tmodule.exports = function createError(message, config, code, request, response) {\n\t var error = new Error(message);\n\t return enhanceError(error, config, code, request, response);\n\t};\n\n\n/***/ }),\n/* 16 */\n/***/ (function(module, exports) {\n\n\t'use strict';\n\t\n\t/**\n\t * Update an Error with the specified config, error code, and response.\n\t *\n\t * @param {Error} error The error to update.\n\t * @param {Object} config The config.\n\t * @param {string} [code] The error code (for example, 'ECONNABORTED').\n\t * @param {Object} [request] The request.\n\t * @param {Object} [response] The response.\n\t * @returns {Error} The error.\n\t */\n\tmodule.exports = function enhanceError(error, config, code, request, response) {\n\t error.config = config;\n\t if (code) {\n\t error.code = code;\n\t }\n\t\n\t error.request = request;\n\t error.response = response;\n\t error.isAxiosError = true;\n\t\n\t error.toJSON = function() {\n\t return {\n\t // Standard\n\t message: this.message,\n\t name: this.name,\n\t // Microsoft\n\t description: this.description,\n\t number: this.number,\n\t // Mozilla\n\t fileName: this.fileName,\n\t lineNumber: this.lineNumber,\n\t columnNumber: this.columnNumber,\n\t stack: this.stack,\n\t // Axios\n\t config: this.config,\n\t code: this.code\n\t };\n\t };\n\t return error;\n\t};\n\n\n/***/ }),\n/* 17 */\n/***/ (function(module, exports, __webpack_require__) {\n\n\t'use strict';\n\t\n\tvar utils = __webpack_require__(2);\n\t\n\t// Headers whose duplicates are ignored by node\n\t// c.f. https://nodejs.org/api/http.html#http_message_headers\n\tvar ignoreDuplicateOf = [\n\t 'age', 'authorization', 'content-length', 'content-type', 'etag',\n\t 'expires', 'from', 'host', 'if-modified-since', 'if-unmodified-since',\n\t 'last-modified', 'location', 'max-forwards', 'proxy-authorization',\n\t 'referer', 'retry-after', 'user-agent'\n\t];\n\t\n\t/**\n\t * Parse headers into an object\n\t *\n\t * ```\n\t * Date: Wed, 27 Aug 2014 08:58:49 GMT\n\t * Content-Type: application/json\n\t * Connection: keep-alive\n\t * Transfer-Encoding: chunked\n\t * ```\n\t *\n\t * @param {String} headers Headers needing to be parsed\n\t * @returns {Object} Headers parsed into an object\n\t */\n\tmodule.exports = function parseHeaders(headers) {\n\t var parsed = {};\n\t var key;\n\t var val;\n\t var i;\n\t\n\t if (!headers) { return parsed; }\n\t\n\t utils.forEach(headers.split('\\n'), function parser(line) {\n\t i = line.indexOf(':');\n\t key = utils.trim(line.substr(0, i)).toLowerCase();\n\t val = utils.trim(line.substr(i + 1));\n\t\n\t if (key) {\n\t if (parsed[key] && ignoreDuplicateOf.indexOf(key) >= 0) {\n\t return;\n\t }\n\t if (key === 'set-cookie') {\n\t parsed[key] = (parsed[key] ? parsed[key] : []).concat([val]);\n\t } else {\n\t parsed[key] = parsed[key] ? parsed[key] + ', ' + val : val;\n\t }\n\t }\n\t });\n\t\n\t return parsed;\n\t};\n\n\n/***/ }),\n/* 18 */\n/***/ (function(module, exports, __webpack_require__) {\n\n\t'use strict';\n\t\n\tvar utils = __webpack_require__(2);\n\t\n\tmodule.exports = (\n\t utils.isStandardBrowserEnv() ?\n\t\n\t // Standard browser envs have full support of the APIs needed to test\n\t // whether the request URL is of the same origin as current location.\n\t (function standardBrowserEnv() {\n\t var msie = /(msie|trident)/i.test(navigator.userAgent);\n\t var urlParsingNode = document.createElement('a');\n\t var originURL;\n\t\n\t /**\n\t * Parse a URL to discover it's components\n\t *\n\t * @param {String} url The URL to be parsed\n\t * @returns {Object}\n\t */\n\t function resolveURL(url) {\n\t var href = url;\n\t\n\t if (msie) {\n\t // IE needs attribute set twice to normalize properties\n\t urlParsingNode.setAttribute('href', href);\n\t href = urlParsingNode.href;\n\t }\n\t\n\t urlParsingNode.setAttribute('href', href);\n\t\n\t // urlParsingNode provides the UrlUtils interface - http://url.spec.whatwg.org/#urlutils\n\t return {\n\t href: urlParsingNode.href,\n\t protocol: urlParsingNode.protocol ? urlParsingNode.protocol.replace(/:$/, '') : '',\n\t host: urlParsingNode.host,\n\t search: urlParsingNode.search ? urlParsingNode.search.replace(/^\\?/, '') : '',\n\t hash: urlParsingNode.hash ? urlParsingNode.hash.replace(/^#/, '') : '',\n\t hostname: urlParsingNode.hostname,\n\t port: urlParsingNode.port,\n\t pathname: (urlParsingNode.pathname.charAt(0) === '/') ?\n\t urlParsingNode.pathname :\n\t '/' + urlParsingNode.pathname\n\t };\n\t }\n\t\n\t originURL = resolveURL(window.location.href);\n\t\n\t /**\n\t * Determine if a URL shares the same origin as the current location\n\t *\n\t * @param {String} requestURL The URL to test\n\t * @returns {boolean} True if URL shares the same origin, otherwise false\n\t */\n\t return function isURLSameOrigin(requestURL) {\n\t var parsed = (utils.isString(requestURL)) ? resolveURL(requestURL) : requestURL;\n\t return (parsed.protocol === originURL.protocol &&\n\t parsed.host === originURL.host);\n\t };\n\t })() :\n\t\n\t // Non standard browser envs (web workers, react-native) lack needed support.\n\t (function nonStandardBrowserEnv() {\n\t return function isURLSameOrigin() {\n\t return true;\n\t };\n\t })()\n\t);\n\n\n/***/ }),\n/* 19 */\n/***/ (function(module, exports, __webpack_require__) {\n\n\t'use strict';\n\t\n\tvar utils = __webpack_require__(2);\n\t\n\tmodule.exports = (\n\t utils.isStandardBrowserEnv() ?\n\t\n\t // Standard browser envs support document.cookie\n\t (function standardBrowserEnv() {\n\t return {\n\t write: function write(name, value, expires, path, domain, secure) {\n\t var cookie = [];\n\t cookie.push(name + '=' + encodeURIComponent(value));\n\t\n\t if (utils.isNumber(expires)) {\n\t cookie.push('expires=' + new Date(expires).toGMTString());\n\t }\n\t\n\t if (utils.isString(path)) {\n\t cookie.push('path=' + path);\n\t }\n\t\n\t if (utils.isString(domain)) {\n\t cookie.push('domain=' + domain);\n\t }\n\t\n\t if (secure === true) {\n\t cookie.push('secure');\n\t }\n\t\n\t document.cookie = cookie.join('; ');\n\t },\n\t\n\t read: function read(name) {\n\t var match = document.cookie.match(new RegExp('(^|;\\\\s*)(' + name + ')=([^;]*)'));\n\t return (match ? decodeURIComponent(match[3]) : null);\n\t },\n\t\n\t remove: function remove(name) {\n\t this.write(name, '', Date.now() - 86400000);\n\t }\n\t };\n\t })() :\n\t\n\t // Non standard browser env (web workers, react-native) lack needed support.\n\t (function nonStandardBrowserEnv() {\n\t return {\n\t write: function write() {},\n\t read: function read() { return null; },\n\t remove: function remove() {}\n\t };\n\t })()\n\t);\n\n\n/***/ }),\n/* 20 */\n/***/ (function(module, exports) {\n\n\t'use strict';\n\t\n\t/**\n\t * Determines whether the specified URL is absolute\n\t *\n\t * @param {string} url The URL to test\n\t * @returns {boolean} True if the specified URL is absolute, otherwise false\n\t */\n\tmodule.exports = function isAbsoluteURL(url) {\n\t // A URL is considered absolute if it begins with \"://\" or \"//\" (protocol-relative URL).\n\t // RFC 3986 defines scheme name as a sequence of characters beginning with a letter and followed\n\t // by any combination of letters, digits, plus, period, or hyphen.\n\t return /^([a-z][a-z\\d\\+\\-\\.]*:)?\\/\\//i.test(url);\n\t};\n\n\n/***/ }),\n/* 21 */\n/***/ (function(module, exports) {\n\n\t'use strict';\n\t\n\t/**\n\t * Creates a new URL by combining the specified URLs\n\t *\n\t * @param {string} baseURL The base URL\n\t * @param {string} relativeURL The relative URL\n\t * @returns {string} The combined URL\n\t */\n\tmodule.exports = function combineURLs(baseURL, relativeURL) {\n\t return relativeURL\n\t ? baseURL.replace(/\\/+$/, '') + '/' + relativeURL.replace(/^\\/+/, '')\n\t : baseURL;\n\t};\n\n\n/***/ }),\n/* 22 */\n/***/ (function(module, exports, __webpack_require__) {\n\n\t'use strict';\n\t\n\tvar utils = __webpack_require__(2);\n\t\n\t/**\n\t * Config-specific merge-function which creates a new config-object\n\t * by merging two configuration objects together.\n\t *\n\t * @param {Object} config1\n\t * @param {Object} config2\n\t * @returns {Object} New object resulting from merging config2 to config1\n\t */\n\tmodule.exports = function mergeConfig(config1, config2) {\n\t // eslint-disable-next-line no-param-reassign\n\t config2 = config2 || {};\n\t var config = {};\n\t\n\t utils.forEach(['url', 'method', 'params', 'data'], function valueFromConfig2(prop) {\n\t if (typeof config2[prop] !== 'undefined') {\n\t config[prop] = config2[prop];\n\t }\n\t });\n\t\n\t utils.forEach(['headers', 'auth', 'proxy'], function mergeDeepProperties(prop) {\n\t if (utils.isObject(config2[prop])) {\n\t config[prop] = utils.deepMerge(config1[prop], config2[prop]);\n\t } else if (typeof config2[prop] !== 'undefined') {\n\t config[prop] = config2[prop];\n\t } else if (utils.isObject(config1[prop])) {\n\t config[prop] = utils.deepMerge(config1[prop]);\n\t } else if (typeof config1[prop] !== 'undefined') {\n\t config[prop] = config1[prop];\n\t }\n\t });\n\t\n\t utils.forEach([\n\t 'baseURL', 'transformRequest', 'transformResponse', 'paramsSerializer',\n\t 'timeout', 'withCredentials', 'adapter', 'responseType', 'xsrfCookieName',\n\t 'xsrfHeaderName', 'onUploadProgress', 'onDownloadProgress', 'maxContentLength',\n\t 'validateStatus', 'maxRedirects', 'httpAgent', 'httpsAgent', 'cancelToken',\n\t 'socketPath'\n\t ], function defaultToConfig2(prop) {\n\t if (typeof config2[prop] !== 'undefined') {\n\t config[prop] = config2[prop];\n\t } else if (typeof config1[prop] !== 'undefined') {\n\t config[prop] = config1[prop];\n\t }\n\t });\n\t\n\t return config;\n\t};\n\n\n/***/ }),\n/* 23 */\n/***/ (function(module, exports) {\n\n\t'use strict';\n\t\n\t/**\n\t * A `Cancel` is an object that is thrown when an operation is canceled.\n\t *\n\t * @class\n\t * @param {string=} message The message.\n\t */\n\tfunction Cancel(message) {\n\t this.message = message;\n\t}\n\t\n\tCancel.prototype.toString = function toString() {\n\t return 'Cancel' + (this.message ? ': ' + this.message : '');\n\t};\n\t\n\tCancel.prototype.__CANCEL__ = true;\n\t\n\tmodule.exports = Cancel;\n\n\n/***/ }),\n/* 24 */\n/***/ (function(module, exports, __webpack_require__) {\n\n\t'use strict';\n\t\n\tvar Cancel = __webpack_require__(23);\n\t\n\t/**\n\t * A `CancelToken` is an object that can be used to request cancellation of an operation.\n\t *\n\t * @class\n\t * @param {Function} executor The executor function.\n\t */\n\tfunction CancelToken(executor) {\n\t if (typeof executor !== 'function') {\n\t throw new TypeError('executor must be a function.');\n\t }\n\t\n\t var resolvePromise;\n\t this.promise = new Promise(function promiseExecutor(resolve) {\n\t resolvePromise = resolve;\n\t });\n\t\n\t var token = this;\n\t executor(function cancel(message) {\n\t if (token.reason) {\n\t // Cancellation has already been requested\n\t return;\n\t }\n\t\n\t token.reason = new Cancel(message);\n\t resolvePromise(token.reason);\n\t });\n\t}\n\t\n\t/**\n\t * Throws a `Cancel` if cancellation has been requested.\n\t */\n\tCancelToken.prototype.throwIfRequested = function throwIfRequested() {\n\t if (this.reason) {\n\t throw this.reason;\n\t }\n\t};\n\t\n\t/**\n\t * Returns an object that contains a new `CancelToken` and a function that, when called,\n\t * cancels the `CancelToken`.\n\t */\n\tCancelToken.source = function source() {\n\t var cancel;\n\t var token = new CancelToken(function executor(c) {\n\t cancel = c;\n\t });\n\t return {\n\t token: token,\n\t cancel: cancel\n\t };\n\t};\n\t\n\tmodule.exports = CancelToken;\n\n\n/***/ }),\n/* 25 */\n/***/ (function(module, exports) {\n\n\t'use strict';\n\t\n\t/**\n\t * Syntactic sugar for invoking a function and expanding an array for arguments.\n\t *\n\t * Common use case would be to use `Function.prototype.apply`.\n\t *\n\t * ```js\n\t * function f(x, y, z) {}\n\t * var args = [1, 2, 3];\n\t * f.apply(null, args);\n\t * ```\n\t *\n\t * With `spread` this example can be re-written.\n\t *\n\t * ```js\n\t * spread(function(x, y, z) {})([1, 2, 3]);\n\t * ```\n\t *\n\t * @param {Function} callback\n\t * @returns {Function}\n\t */\n\tmodule.exports = function spread(callback) {\n\t return function wrap(arr) {\n\t return callback.apply(null, arr);\n\t };\n\t};\n\n\n/***/ })\n/******/ ])\n});\n;\n\n\n// WEBPACK FOOTER //\n// axios.min.js"," \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId])\n \t\t\treturn installedModules[moduleId].exports;\n\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\texports: {},\n \t\t\tid: moduleId,\n \t\t\tloaded: false\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.loaded = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(0);\n\n\n\n// WEBPACK FOOTER //\n// webpack/bootstrap 3e317bb69558239a2225","module.exports = require('./lib/axios');\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./index.js\n// module id = 0\n// module chunks = 0","'use strict';\n\nvar utils = require('./utils');\nvar bind = require('./helpers/bind');\nvar Axios = require('./core/Axios');\nvar mergeConfig = require('./core/mergeConfig');\nvar defaults = require('./defaults');\n\n/**\n * Create an instance of Axios\n *\n * @param {Object} defaultConfig The default config for the instance\n * @return {Axios} A new instance of Axios\n */\nfunction createInstance(defaultConfig) {\n var context = new Axios(defaultConfig);\n var instance = bind(Axios.prototype.request, context);\n\n // Copy axios.prototype to instance\n utils.extend(instance, Axios.prototype, context);\n\n // Copy context to instance\n utils.extend(instance, context);\n\n return instance;\n}\n\n// Create the default instance to be exported\nvar axios = createInstance(defaults);\n\n// Expose Axios class to allow class inheritance\naxios.Axios = Axios;\n\n// Factory for creating new instances\naxios.create = function create(instanceConfig) {\n return createInstance(mergeConfig(axios.defaults, instanceConfig));\n};\n\n// Expose Cancel & CancelToken\naxios.Cancel = require('./cancel/Cancel');\naxios.CancelToken = require('./cancel/CancelToken');\naxios.isCancel = require('./cancel/isCancel');\n\n// Expose all/spread\naxios.all = function all(promises) {\n return Promise.all(promises);\n};\naxios.spread = require('./helpers/spread');\n\nmodule.exports = axios;\n\n// Allow use of default import syntax in TypeScript\nmodule.exports.default = axios;\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/axios.js\n// module id = 1\n// module chunks = 0","'use strict';\n\nvar bind = require('./helpers/bind');\nvar isBuffer = require('is-buffer');\n\n/*global toString:true*/\n\n// utils is a library of generic helper functions non-specific to axios\n\nvar toString = Object.prototype.toString;\n\n/**\n * Determine if a value is an Array\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is an Array, otherwise false\n */\nfunction isArray(val) {\n return toString.call(val) === '[object Array]';\n}\n\n/**\n * Determine if a value is an ArrayBuffer\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is an ArrayBuffer, otherwise false\n */\nfunction isArrayBuffer(val) {\n return toString.call(val) === '[object ArrayBuffer]';\n}\n\n/**\n * Determine if a value is a FormData\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is an FormData, otherwise false\n */\nfunction isFormData(val) {\n return (typeof FormData !== 'undefined') && (val instanceof FormData);\n}\n\n/**\n * Determine if a value is a view on an ArrayBuffer\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is a view on an ArrayBuffer, otherwise false\n */\nfunction isArrayBufferView(val) {\n var result;\n if ((typeof ArrayBuffer !== 'undefined') && (ArrayBuffer.isView)) {\n result = ArrayBuffer.isView(val);\n } else {\n result = (val) && (val.buffer) && (val.buffer instanceof ArrayBuffer);\n }\n return result;\n}\n\n/**\n * Determine if a value is a String\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is a String, otherwise false\n */\nfunction isString(val) {\n return typeof val === 'string';\n}\n\n/**\n * Determine if a value is a Number\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is a Number, otherwise false\n */\nfunction isNumber(val) {\n return typeof val === 'number';\n}\n\n/**\n * Determine if a value is undefined\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if the value is undefined, otherwise false\n */\nfunction isUndefined(val) {\n return typeof val === 'undefined';\n}\n\n/**\n * Determine if a value is an Object\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is an Object, otherwise false\n */\nfunction isObject(val) {\n return val !== null && typeof val === 'object';\n}\n\n/**\n * Determine if a value is a Date\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is a Date, otherwise false\n */\nfunction isDate(val) {\n return toString.call(val) === '[object Date]';\n}\n\n/**\n * Determine if a value is a File\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is a File, otherwise false\n */\nfunction isFile(val) {\n return toString.call(val) === '[object File]';\n}\n\n/**\n * Determine if a value is a Blob\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is a Blob, otherwise false\n */\nfunction isBlob(val) {\n return toString.call(val) === '[object Blob]';\n}\n\n/**\n * Determine if a value is a Function\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is a Function, otherwise false\n */\nfunction isFunction(val) {\n return toString.call(val) === '[object Function]';\n}\n\n/**\n * Determine if a value is a Stream\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is a Stream, otherwise false\n */\nfunction isStream(val) {\n return isObject(val) && isFunction(val.pipe);\n}\n\n/**\n * Determine if a value is a URLSearchParams object\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is a URLSearchParams object, otherwise false\n */\nfunction isURLSearchParams(val) {\n return typeof URLSearchParams !== 'undefined' && val instanceof URLSearchParams;\n}\n\n/**\n * Trim excess whitespace off the beginning and end of a string\n *\n * @param {String} str The String to trim\n * @returns {String} The String freed of excess whitespace\n */\nfunction trim(str) {\n return str.replace(/^\\s*/, '').replace(/\\s*$/, '');\n}\n\n/**\n * Determine if we're running in a standard browser environment\n *\n * This allows axios to run in a web worker, and react-native.\n * Both environments support XMLHttpRequest, but not fully standard globals.\n *\n * web workers:\n * typeof window -> undefined\n * typeof document -> undefined\n *\n * react-native:\n * navigator.product -> 'ReactNative'\n * nativescript\n * navigator.product -> 'NativeScript' or 'NS'\n */\nfunction isStandardBrowserEnv() {\n if (typeof navigator !== 'undefined' && (navigator.product === 'ReactNative' ||\n navigator.product === 'NativeScript' ||\n navigator.product === 'NS')) {\n return false;\n }\n return (\n typeof window !== 'undefined' &&\n typeof document !== 'undefined'\n );\n}\n\n/**\n * Iterate over an Array or an Object invoking a function for each item.\n *\n * If `obj` is an Array callback will be called passing\n * the value, index, and complete array for each item.\n *\n * If 'obj' is an Object callback will be called passing\n * the value, key, and complete object for each property.\n *\n * @param {Object|Array} obj The object to iterate\n * @param {Function} fn The callback to invoke for each item\n */\nfunction forEach(obj, fn) {\n // Don't bother if no value provided\n if (obj === null || typeof obj === 'undefined') {\n return;\n }\n\n // Force an array if not already something iterable\n if (typeof obj !== 'object') {\n /*eslint no-param-reassign:0*/\n obj = [obj];\n }\n\n if (isArray(obj)) {\n // Iterate over array values\n for (var i = 0, l = obj.length; i < l; i++) {\n fn.call(null, obj[i], i, obj);\n }\n } else {\n // Iterate over object keys\n for (var key in obj) {\n if (Object.prototype.hasOwnProperty.call(obj, key)) {\n fn.call(null, obj[key], key, obj);\n }\n }\n }\n}\n\n/**\n * Accepts varargs expecting each argument to be an object, then\n * immutably merges the properties of each object and returns result.\n *\n * When multiple objects contain the same key the later object in\n * the arguments list will take precedence.\n *\n * Example:\n *\n * ```js\n * var result = merge({foo: 123}, {foo: 456});\n * console.log(result.foo); // outputs 456\n * ```\n *\n * @param {Object} obj1 Object to merge\n * @returns {Object} Result of all merge properties\n */\nfunction merge(/* obj1, obj2, obj3, ... */) {\n var result = {};\n function assignValue(val, key) {\n if (typeof result[key] === 'object' && typeof val === 'object') {\n result[key] = merge(result[key], val);\n } else {\n result[key] = val;\n }\n }\n\n for (var i = 0, l = arguments.length; i < l; i++) {\n forEach(arguments[i], assignValue);\n }\n return result;\n}\n\n/**\n * Function equal to merge with the difference being that no reference\n * to original objects is kept.\n *\n * @see merge\n * @param {Object} obj1 Object to merge\n * @returns {Object} Result of all merge properties\n */\nfunction deepMerge(/* obj1, obj2, obj3, ... */) {\n var result = {};\n function assignValue(val, key) {\n if (typeof result[key] === 'object' && typeof val === 'object') {\n result[key] = deepMerge(result[key], val);\n } else if (typeof val === 'object') {\n result[key] = deepMerge({}, val);\n } else {\n result[key] = val;\n }\n }\n\n for (var i = 0, l = arguments.length; i < l; i++) {\n forEach(arguments[i], assignValue);\n }\n return result;\n}\n\n/**\n * Extends object a by mutably adding to it the properties of object b.\n *\n * @param {Object} a The object to be extended\n * @param {Object} b The object to copy properties from\n * @param {Object} thisArg The object to bind function to\n * @return {Object} The resulting value of object a\n */\nfunction extend(a, b, thisArg) {\n forEach(b, function assignValue(val, key) {\n if (thisArg && typeof val === 'function') {\n a[key] = bind(val, thisArg);\n } else {\n a[key] = val;\n }\n });\n return a;\n}\n\nmodule.exports = {\n isArray: isArray,\n isArrayBuffer: isArrayBuffer,\n isBuffer: isBuffer,\n isFormData: isFormData,\n isArrayBufferView: isArrayBufferView,\n isString: isString,\n isNumber: isNumber,\n isObject: isObject,\n isUndefined: isUndefined,\n isDate: isDate,\n isFile: isFile,\n isBlob: isBlob,\n isFunction: isFunction,\n isStream: isStream,\n isURLSearchParams: isURLSearchParams,\n isStandardBrowserEnv: isStandardBrowserEnv,\n forEach: forEach,\n merge: merge,\n deepMerge: deepMerge,\n extend: extend,\n trim: trim\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/utils.js\n// module id = 2\n// module chunks = 0","'use strict';\n\nmodule.exports = function bind(fn, thisArg) {\n return function wrap() {\n var args = new Array(arguments.length);\n for (var i = 0; i < args.length; i++) {\n args[i] = arguments[i];\n }\n return fn.apply(thisArg, args);\n };\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/helpers/bind.js\n// module id = 3\n// module chunks = 0","/*!\n * Determine if an object is a Buffer\n *\n * @author Feross Aboukhadijeh \n * @license MIT\n */\n\nmodule.exports = function isBuffer (obj) {\n return obj != null && obj.constructor != null &&\n typeof obj.constructor.isBuffer === 'function' && obj.constructor.isBuffer(obj)\n}\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./~/is-buffer/index.js\n// module id = 4\n// module chunks = 0","'use strict';\n\nvar utils = require('./../utils');\nvar buildURL = require('../helpers/buildURL');\nvar InterceptorManager = require('./InterceptorManager');\nvar dispatchRequest = require('./dispatchRequest');\nvar mergeConfig = require('./mergeConfig');\n\n/**\n * Create a new instance of Axios\n *\n * @param {Object} instanceConfig The default config for the instance\n */\nfunction Axios(instanceConfig) {\n this.defaults = instanceConfig;\n this.interceptors = {\n request: new InterceptorManager(),\n response: new InterceptorManager()\n };\n}\n\n/**\n * Dispatch a request\n *\n * @param {Object} config The config specific for this request (merged with this.defaults)\n */\nAxios.prototype.request = function request(config) {\n /*eslint no-param-reassign:0*/\n // Allow for axios('example/url'[, config]) a la fetch API\n if (typeof config === 'string') {\n config = arguments[1] || {};\n config.url = arguments[0];\n } else {\n config = config || {};\n }\n\n config = mergeConfig(this.defaults, config);\n config.method = config.method ? config.method.toLowerCase() : 'get';\n\n // Hook up interceptors middleware\n var chain = [dispatchRequest, undefined];\n var promise = Promise.resolve(config);\n\n this.interceptors.request.forEach(function unshiftRequestInterceptors(interceptor) {\n chain.unshift(interceptor.fulfilled, interceptor.rejected);\n });\n\n this.interceptors.response.forEach(function pushResponseInterceptors(interceptor) {\n chain.push(interceptor.fulfilled, interceptor.rejected);\n });\n\n while (chain.length) {\n promise = promise.then(chain.shift(), chain.shift());\n }\n\n return promise;\n};\n\nAxios.prototype.getUri = function getUri(config) {\n config = mergeConfig(this.defaults, config);\n return buildURL(config.url, config.params, config.paramsSerializer).replace(/^\\?/, '');\n};\n\n// Provide aliases for supported request methods\nutils.forEach(['delete', 'get', 'head', 'options'], function forEachMethodNoData(method) {\n /*eslint func-names:0*/\n Axios.prototype[method] = function(url, config) {\n return this.request(utils.merge(config || {}, {\n method: method,\n url: url\n }));\n };\n});\n\nutils.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method) {\n /*eslint func-names:0*/\n Axios.prototype[method] = function(url, data, config) {\n return this.request(utils.merge(config || {}, {\n method: method,\n url: url,\n data: data\n }));\n };\n});\n\nmodule.exports = Axios;\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/core/Axios.js\n// module id = 5\n// module chunks = 0","'use strict';\n\nvar utils = require('./../utils');\n\nfunction encode(val) {\n return encodeURIComponent(val).\n replace(/%40/gi, '@').\n replace(/%3A/gi, ':').\n replace(/%24/g, '$').\n replace(/%2C/gi, ',').\n replace(/%20/g, '+').\n replace(/%5B/gi, '[').\n replace(/%5D/gi, ']');\n}\n\n/**\n * Build a URL by appending params to the end\n *\n * @param {string} url The base of the url (e.g., http://www.google.com)\n * @param {object} [params] The params to be appended\n * @returns {string} The formatted url\n */\nmodule.exports = function buildURL(url, params, paramsSerializer) {\n /*eslint no-param-reassign:0*/\n if (!params) {\n return url;\n }\n\n var serializedParams;\n if (paramsSerializer) {\n serializedParams = paramsSerializer(params);\n } else if (utils.isURLSearchParams(params)) {\n serializedParams = params.toString();\n } else {\n var parts = [];\n\n utils.forEach(params, function serialize(val, key) {\n if (val === null || typeof val === 'undefined') {\n return;\n }\n\n if (utils.isArray(val)) {\n key = key + '[]';\n } else {\n val = [val];\n }\n\n utils.forEach(val, function parseValue(v) {\n if (utils.isDate(v)) {\n v = v.toISOString();\n } else if (utils.isObject(v)) {\n v = JSON.stringify(v);\n }\n parts.push(encode(key) + '=' + encode(v));\n });\n });\n\n serializedParams = parts.join('&');\n }\n\n if (serializedParams) {\n var hashmarkIndex = url.indexOf('#');\n if (hashmarkIndex !== -1) {\n url = url.slice(0, hashmarkIndex);\n }\n\n url += (url.indexOf('?') === -1 ? '?' : '&') + serializedParams;\n }\n\n return url;\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/helpers/buildURL.js\n// module id = 6\n// module chunks = 0","'use strict';\n\nvar utils = require('./../utils');\n\nfunction InterceptorManager() {\n this.handlers = [];\n}\n\n/**\n * Add a new interceptor to the stack\n *\n * @param {Function} fulfilled The function to handle `then` for a `Promise`\n * @param {Function} rejected The function to handle `reject` for a `Promise`\n *\n * @return {Number} An ID used to remove interceptor later\n */\nInterceptorManager.prototype.use = function use(fulfilled, rejected) {\n this.handlers.push({\n fulfilled: fulfilled,\n rejected: rejected\n });\n return this.handlers.length - 1;\n};\n\n/**\n * Remove an interceptor from the stack\n *\n * @param {Number} id The ID that was returned by `use`\n */\nInterceptorManager.prototype.eject = function eject(id) {\n if (this.handlers[id]) {\n this.handlers[id] = null;\n }\n};\n\n/**\n * Iterate over all the registered interceptors\n *\n * This method is particularly useful for skipping over any\n * interceptors that may have become `null` calling `eject`.\n *\n * @param {Function} fn The function to call for each interceptor\n */\nInterceptorManager.prototype.forEach = function forEach(fn) {\n utils.forEach(this.handlers, function forEachHandler(h) {\n if (h !== null) {\n fn(h);\n }\n });\n};\n\nmodule.exports = InterceptorManager;\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/core/InterceptorManager.js\n// module id = 7\n// module chunks = 0","'use strict';\n\nvar utils = require('./../utils');\nvar transformData = require('./transformData');\nvar isCancel = require('../cancel/isCancel');\nvar defaults = require('../defaults');\nvar isAbsoluteURL = require('./../helpers/isAbsoluteURL');\nvar combineURLs = require('./../helpers/combineURLs');\n\n/**\n * Throws a `Cancel` if cancellation has been requested.\n */\nfunction throwIfCancellationRequested(config) {\n if (config.cancelToken) {\n config.cancelToken.throwIfRequested();\n }\n}\n\n/**\n * Dispatch a request to the server using the configured adapter.\n *\n * @param {object} config The config that is to be used for the request\n * @returns {Promise} The Promise to be fulfilled\n */\nmodule.exports = function dispatchRequest(config) {\n throwIfCancellationRequested(config);\n\n // Support baseURL config\n if (config.baseURL && !isAbsoluteURL(config.url)) {\n config.url = combineURLs(config.baseURL, config.url);\n }\n\n // Ensure headers exist\n config.headers = config.headers || {};\n\n // Transform request data\n config.data = transformData(\n config.data,\n config.headers,\n config.transformRequest\n );\n\n // Flatten headers\n config.headers = utils.merge(\n config.headers.common || {},\n config.headers[config.method] || {},\n config.headers || {}\n );\n\n utils.forEach(\n ['delete', 'get', 'head', 'post', 'put', 'patch', 'common'],\n function cleanHeaderConfig(method) {\n delete config.headers[method];\n }\n );\n\n var adapter = config.adapter || defaults.adapter;\n\n return adapter(config).then(function onAdapterResolution(response) {\n throwIfCancellationRequested(config);\n\n // Transform response data\n response.data = transformData(\n response.data,\n response.headers,\n config.transformResponse\n );\n\n return response;\n }, function onAdapterRejection(reason) {\n if (!isCancel(reason)) {\n throwIfCancellationRequested(config);\n\n // Transform response data\n if (reason && reason.response) {\n reason.response.data = transformData(\n reason.response.data,\n reason.response.headers,\n config.transformResponse\n );\n }\n }\n\n return Promise.reject(reason);\n });\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/core/dispatchRequest.js\n// module id = 8\n// module chunks = 0","'use strict';\n\nvar utils = require('./../utils');\n\n/**\n * Transform the data for a request or a response\n *\n * @param {Object|String} data The data to be transformed\n * @param {Array} headers The headers for the request or response\n * @param {Array|Function} fns A single function or Array of functions\n * @returns {*} The resulting transformed data\n */\nmodule.exports = function transformData(data, headers, fns) {\n /*eslint no-param-reassign:0*/\n utils.forEach(fns, function transform(fn) {\n data = fn(data, headers);\n });\n\n return data;\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/core/transformData.js\n// module id = 9\n// module chunks = 0","'use strict';\n\nmodule.exports = function isCancel(value) {\n return !!(value && value.__CANCEL__);\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/cancel/isCancel.js\n// module id = 10\n// module chunks = 0","'use strict';\n\nvar utils = require('./utils');\nvar normalizeHeaderName = require('./helpers/normalizeHeaderName');\n\nvar DEFAULT_CONTENT_TYPE = {\n 'Content-Type': 'application/x-www-form-urlencoded'\n};\n\nfunction setContentTypeIfUnset(headers, value) {\n if (!utils.isUndefined(headers) && utils.isUndefined(headers['Content-Type'])) {\n headers['Content-Type'] = value;\n }\n}\n\nfunction getDefaultAdapter() {\n var adapter;\n // Only Node.JS has a process variable that is of [[Class]] process\n if (typeof process !== 'undefined' && Object.prototype.toString.call(process) === '[object process]') {\n // For node use HTTP adapter\n adapter = require('./adapters/http');\n } else if (typeof XMLHttpRequest !== 'undefined') {\n // For browsers use XHR adapter\n adapter = require('./adapters/xhr');\n }\n return adapter;\n}\n\nvar defaults = {\n adapter: getDefaultAdapter(),\n\n transformRequest: [function transformRequest(data, headers) {\n normalizeHeaderName(headers, 'Accept');\n normalizeHeaderName(headers, 'Content-Type');\n if (utils.isFormData(data) ||\n utils.isArrayBuffer(data) ||\n utils.isBuffer(data) ||\n utils.isStream(data) ||\n utils.isFile(data) ||\n utils.isBlob(data)\n ) {\n return data;\n }\n if (utils.isArrayBufferView(data)) {\n return data.buffer;\n }\n if (utils.isURLSearchParams(data)) {\n setContentTypeIfUnset(headers, 'application/x-www-form-urlencoded;charset=utf-8');\n return data.toString();\n }\n if (utils.isObject(data)) {\n setContentTypeIfUnset(headers, 'application/json;charset=utf-8');\n return JSON.stringify(data);\n }\n return data;\n }],\n\n transformResponse: [function transformResponse(data) {\n /*eslint no-param-reassign:0*/\n if (typeof data === 'string') {\n try {\n data = JSON.parse(data);\n } catch (e) { /* Ignore */ }\n }\n return data;\n }],\n\n /**\n * A timeout in milliseconds to abort a request. If set to 0 (default) a\n * timeout is not created.\n */\n timeout: 0,\n\n xsrfCookieName: 'XSRF-TOKEN',\n xsrfHeaderName: 'X-XSRF-TOKEN',\n\n maxContentLength: -1,\n\n validateStatus: function validateStatus(status) {\n return status >= 200 && status < 300;\n }\n};\n\ndefaults.headers = {\n common: {\n 'Accept': 'application/json, text/plain, */*'\n }\n};\n\nutils.forEach(['delete', 'get', 'head'], function forEachMethodNoData(method) {\n defaults.headers[method] = {};\n});\n\nutils.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method) {\n defaults.headers[method] = utils.merge(DEFAULT_CONTENT_TYPE);\n});\n\nmodule.exports = defaults;\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/defaults.js\n// module id = 11\n// module chunks = 0","'use strict';\n\nvar utils = require('../utils');\n\nmodule.exports = function normalizeHeaderName(headers, normalizedName) {\n utils.forEach(headers, function processHeader(value, name) {\n if (name !== normalizedName && name.toUpperCase() === normalizedName.toUpperCase()) {\n headers[normalizedName] = value;\n delete headers[name];\n }\n });\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/helpers/normalizeHeaderName.js\n// module id = 12\n// module chunks = 0","'use strict';\n\nvar utils = require('./../utils');\nvar settle = require('./../core/settle');\nvar buildURL = require('./../helpers/buildURL');\nvar parseHeaders = require('./../helpers/parseHeaders');\nvar isURLSameOrigin = require('./../helpers/isURLSameOrigin');\nvar createError = require('../core/createError');\n\nmodule.exports = function xhrAdapter(config) {\n return new Promise(function dispatchXhrRequest(resolve, reject) {\n var requestData = config.data;\n var requestHeaders = config.headers;\n\n if (utils.isFormData(requestData)) {\n delete requestHeaders['Content-Type']; // Let the browser set it\n }\n\n var request = new XMLHttpRequest();\n\n // HTTP basic authentication\n if (config.auth) {\n var username = config.auth.username || '';\n var password = config.auth.password || '';\n requestHeaders.Authorization = 'Basic ' + btoa(username + ':' + password);\n }\n\n request.open(config.method.toUpperCase(), buildURL(config.url, config.params, config.paramsSerializer), true);\n\n // Set the request timeout in MS\n request.timeout = config.timeout;\n\n // Listen for ready state\n request.onreadystatechange = function handleLoad() {\n if (!request || request.readyState !== 4) {\n return;\n }\n\n // The request errored out and we didn't get a response, this will be\n // handled by onerror instead\n // With one exception: request that using file: protocol, most browsers\n // will return status as 0 even though it's a successful request\n if (request.status === 0 && !(request.responseURL && request.responseURL.indexOf('file:') === 0)) {\n return;\n }\n\n // Prepare the response\n var responseHeaders = 'getAllResponseHeaders' in request ? parseHeaders(request.getAllResponseHeaders()) : null;\n var responseData = !config.responseType || config.responseType === 'text' ? request.responseText : request.response;\n var response = {\n data: responseData,\n status: request.status,\n statusText: request.statusText,\n headers: responseHeaders,\n config: config,\n request: request\n };\n\n settle(resolve, reject, response);\n\n // Clean up request\n request = null;\n };\n\n // Handle browser request cancellation (as opposed to a manual cancellation)\n request.onabort = function handleAbort() {\n if (!request) {\n return;\n }\n\n reject(createError('Request aborted', config, 'ECONNABORTED', request));\n\n // Clean up request\n request = null;\n };\n\n // Handle low level network errors\n request.onerror = function handleError() {\n // Real errors are hidden from us by the browser\n // onerror should only fire if it's a network error\n reject(createError('Network Error', config, null, request));\n\n // Clean up request\n request = null;\n };\n\n // Handle timeout\n request.ontimeout = function handleTimeout() {\n reject(createError('timeout of ' + config.timeout + 'ms exceeded', config, 'ECONNABORTED',\n request));\n\n // Clean up request\n request = null;\n };\n\n // Add xsrf header\n // This is only done if running in a standard browser environment.\n // Specifically not if we're in a web worker, or react-native.\n if (utils.isStandardBrowserEnv()) {\n var cookies = require('./../helpers/cookies');\n\n // Add xsrf header\n var xsrfValue = (config.withCredentials || isURLSameOrigin(config.url)) && config.xsrfCookieName ?\n cookies.read(config.xsrfCookieName) :\n undefined;\n\n if (xsrfValue) {\n requestHeaders[config.xsrfHeaderName] = xsrfValue;\n }\n }\n\n // Add headers to the request\n if ('setRequestHeader' in request) {\n utils.forEach(requestHeaders, function setRequestHeader(val, key) {\n if (typeof requestData === 'undefined' && key.toLowerCase() === 'content-type') {\n // Remove Content-Type if data is undefined\n delete requestHeaders[key];\n } else {\n // Otherwise add header to the request\n request.setRequestHeader(key, val);\n }\n });\n }\n\n // Add withCredentials to request if needed\n if (config.withCredentials) {\n request.withCredentials = true;\n }\n\n // Add responseType to request if needed\n if (config.responseType) {\n try {\n request.responseType = config.responseType;\n } catch (e) {\n // Expected DOMException thrown by browsers not compatible XMLHttpRequest Level 2.\n // But, this can be suppressed for 'json' type as it can be parsed by default 'transformResponse' function.\n if (config.responseType !== 'json') {\n throw e;\n }\n }\n }\n\n // Handle progress if needed\n if (typeof config.onDownloadProgress === 'function') {\n request.addEventListener('progress', config.onDownloadProgress);\n }\n\n // Not all browsers support upload events\n if (typeof config.onUploadProgress === 'function' && request.upload) {\n request.upload.addEventListener('progress', config.onUploadProgress);\n }\n\n if (config.cancelToken) {\n // Handle cancellation\n config.cancelToken.promise.then(function onCanceled(cancel) {\n if (!request) {\n return;\n }\n\n request.abort();\n reject(cancel);\n // Clean up request\n request = null;\n });\n }\n\n if (requestData === undefined) {\n requestData = null;\n }\n\n // Send the request\n request.send(requestData);\n });\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/adapters/xhr.js\n// module id = 13\n// module chunks = 0","'use strict';\n\nvar createError = require('./createError');\n\n/**\n * Resolve or reject a Promise based on response status.\n *\n * @param {Function} resolve A function that resolves the promise.\n * @param {Function} reject A function that rejects the promise.\n * @param {object} response The response.\n */\nmodule.exports = function settle(resolve, reject, response) {\n var validateStatus = response.config.validateStatus;\n if (!validateStatus || validateStatus(response.status)) {\n resolve(response);\n } else {\n reject(createError(\n 'Request failed with status code ' + response.status,\n response.config,\n null,\n response.request,\n response\n ));\n }\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/core/settle.js\n// module id = 14\n// module chunks = 0","'use strict';\n\nvar enhanceError = require('./enhanceError');\n\n/**\n * Create an Error with the specified message, config, error code, request and response.\n *\n * @param {string} message The error message.\n * @param {Object} config The config.\n * @param {string} [code] The error code (for example, 'ECONNABORTED').\n * @param {Object} [request] The request.\n * @param {Object} [response] The response.\n * @returns {Error} The created error.\n */\nmodule.exports = function createError(message, config, code, request, response) {\n var error = new Error(message);\n return enhanceError(error, config, code, request, response);\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/core/createError.js\n// module id = 15\n// module chunks = 0","'use strict';\n\n/**\n * Update an Error with the specified config, error code, and response.\n *\n * @param {Error} error The error to update.\n * @param {Object} config The config.\n * @param {string} [code] The error code (for example, 'ECONNABORTED').\n * @param {Object} [request] The request.\n * @param {Object} [response] The response.\n * @returns {Error} The error.\n */\nmodule.exports = function enhanceError(error, config, code, request, response) {\n error.config = config;\n if (code) {\n error.code = code;\n }\n\n error.request = request;\n error.response = response;\n error.isAxiosError = true;\n\n error.toJSON = function() {\n return {\n // Standard\n message: this.message,\n name: this.name,\n // Microsoft\n description: this.description,\n number: this.number,\n // Mozilla\n fileName: this.fileName,\n lineNumber: this.lineNumber,\n columnNumber: this.columnNumber,\n stack: this.stack,\n // Axios\n config: this.config,\n code: this.code\n };\n };\n return error;\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/core/enhanceError.js\n// module id = 16\n// module chunks = 0","'use strict';\n\nvar utils = require('./../utils');\n\n// Headers whose duplicates are ignored by node\n// c.f. https://nodejs.org/api/http.html#http_message_headers\nvar ignoreDuplicateOf = [\n 'age', 'authorization', 'content-length', 'content-type', 'etag',\n 'expires', 'from', 'host', 'if-modified-since', 'if-unmodified-since',\n 'last-modified', 'location', 'max-forwards', 'proxy-authorization',\n 'referer', 'retry-after', 'user-agent'\n];\n\n/**\n * Parse headers into an object\n *\n * ```\n * Date: Wed, 27 Aug 2014 08:58:49 GMT\n * Content-Type: application/json\n * Connection: keep-alive\n * Transfer-Encoding: chunked\n * ```\n *\n * @param {String} headers Headers needing to be parsed\n * @returns {Object} Headers parsed into an object\n */\nmodule.exports = function parseHeaders(headers) {\n var parsed = {};\n var key;\n var val;\n var i;\n\n if (!headers) { return parsed; }\n\n utils.forEach(headers.split('\\n'), function parser(line) {\n i = line.indexOf(':');\n key = utils.trim(line.substr(0, i)).toLowerCase();\n val = utils.trim(line.substr(i + 1));\n\n if (key) {\n if (parsed[key] && ignoreDuplicateOf.indexOf(key) >= 0) {\n return;\n }\n if (key === 'set-cookie') {\n parsed[key] = (parsed[key] ? parsed[key] : []).concat([val]);\n } else {\n parsed[key] = parsed[key] ? parsed[key] + ', ' + val : val;\n }\n }\n });\n\n return parsed;\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/helpers/parseHeaders.js\n// module id = 17\n// module chunks = 0","'use strict';\n\nvar utils = require('./../utils');\n\nmodule.exports = (\n utils.isStandardBrowserEnv() ?\n\n // Standard browser envs have full support of the APIs needed to test\n // whether the request URL is of the same origin as current location.\n (function standardBrowserEnv() {\n var msie = /(msie|trident)/i.test(navigator.userAgent);\n var urlParsingNode = document.createElement('a');\n var originURL;\n\n /**\n * Parse a URL to discover it's components\n *\n * @param {String} url The URL to be parsed\n * @returns {Object}\n */\n function resolveURL(url) {\n var href = url;\n\n if (msie) {\n // IE needs attribute set twice to normalize properties\n urlParsingNode.setAttribute('href', href);\n href = urlParsingNode.href;\n }\n\n urlParsingNode.setAttribute('href', href);\n\n // urlParsingNode provides the UrlUtils interface - http://url.spec.whatwg.org/#urlutils\n return {\n href: urlParsingNode.href,\n protocol: urlParsingNode.protocol ? urlParsingNode.protocol.replace(/:$/, '') : '',\n host: urlParsingNode.host,\n search: urlParsingNode.search ? urlParsingNode.search.replace(/^\\?/, '') : '',\n hash: urlParsingNode.hash ? urlParsingNode.hash.replace(/^#/, '') : '',\n hostname: urlParsingNode.hostname,\n port: urlParsingNode.port,\n pathname: (urlParsingNode.pathname.charAt(0) === '/') ?\n urlParsingNode.pathname :\n '/' + urlParsingNode.pathname\n };\n }\n\n originURL = resolveURL(window.location.href);\n\n /**\n * Determine if a URL shares the same origin as the current location\n *\n * @param {String} requestURL The URL to test\n * @returns {boolean} True if URL shares the same origin, otherwise false\n */\n return function isURLSameOrigin(requestURL) {\n var parsed = (utils.isString(requestURL)) ? resolveURL(requestURL) : requestURL;\n return (parsed.protocol === originURL.protocol &&\n parsed.host === originURL.host);\n };\n })() :\n\n // Non standard browser envs (web workers, react-native) lack needed support.\n (function nonStandardBrowserEnv() {\n return function isURLSameOrigin() {\n return true;\n };\n })()\n);\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/helpers/isURLSameOrigin.js\n// module id = 18\n// module chunks = 0","'use strict';\n\nvar utils = require('./../utils');\n\nmodule.exports = (\n utils.isStandardBrowserEnv() ?\n\n // Standard browser envs support document.cookie\n (function standardBrowserEnv() {\n return {\n write: function write(name, value, expires, path, domain, secure) {\n var cookie = [];\n cookie.push(name + '=' + encodeURIComponent(value));\n\n if (utils.isNumber(expires)) {\n cookie.push('expires=' + new Date(expires).toGMTString());\n }\n\n if (utils.isString(path)) {\n cookie.push('path=' + path);\n }\n\n if (utils.isString(domain)) {\n cookie.push('domain=' + domain);\n }\n\n if (secure === true) {\n cookie.push('secure');\n }\n\n document.cookie = cookie.join('; ');\n },\n\n read: function read(name) {\n var match = document.cookie.match(new RegExp('(^|;\\\\s*)(' + name + ')=([^;]*)'));\n return (match ? decodeURIComponent(match[3]) : null);\n },\n\n remove: function remove(name) {\n this.write(name, '', Date.now() - 86400000);\n }\n };\n })() :\n\n // Non standard browser env (web workers, react-native) lack needed support.\n (function nonStandardBrowserEnv() {\n return {\n write: function write() {},\n read: function read() { return null; },\n remove: function remove() {}\n };\n })()\n);\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/helpers/cookies.js\n// module id = 19\n// module chunks = 0","'use strict';\n\n/**\n * Determines whether the specified URL is absolute\n *\n * @param {string} url The URL to test\n * @returns {boolean} True if the specified URL is absolute, otherwise false\n */\nmodule.exports = function isAbsoluteURL(url) {\n // A URL is considered absolute if it begins with \"://\" or \"//\" (protocol-relative URL).\n // RFC 3986 defines scheme name as a sequence of characters beginning with a letter and followed\n // by any combination of letters, digits, plus, period, or hyphen.\n return /^([a-z][a-z\\d\\+\\-\\.]*:)?\\/\\//i.test(url);\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/helpers/isAbsoluteURL.js\n// module id = 20\n// module chunks = 0","'use strict';\n\n/**\n * Creates a new URL by combining the specified URLs\n *\n * @param {string} baseURL The base URL\n * @param {string} relativeURL The relative URL\n * @returns {string} The combined URL\n */\nmodule.exports = function combineURLs(baseURL, relativeURL) {\n return relativeURL\n ? baseURL.replace(/\\/+$/, '') + '/' + relativeURL.replace(/^\\/+/, '')\n : baseURL;\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/helpers/combineURLs.js\n// module id = 21\n// module chunks = 0","'use strict';\n\nvar utils = require('../utils');\n\n/**\n * Config-specific merge-function which creates a new config-object\n * by merging two configuration objects together.\n *\n * @param {Object} config1\n * @param {Object} config2\n * @returns {Object} New object resulting from merging config2 to config1\n */\nmodule.exports = function mergeConfig(config1, config2) {\n // eslint-disable-next-line no-param-reassign\n config2 = config2 || {};\n var config = {};\n\n utils.forEach(['url', 'method', 'params', 'data'], function valueFromConfig2(prop) {\n if (typeof config2[prop] !== 'undefined') {\n config[prop] = config2[prop];\n }\n });\n\n utils.forEach(['headers', 'auth', 'proxy'], function mergeDeepProperties(prop) {\n if (utils.isObject(config2[prop])) {\n config[prop] = utils.deepMerge(config1[prop], config2[prop]);\n } else if (typeof config2[prop] !== 'undefined') {\n config[prop] = config2[prop];\n } else if (utils.isObject(config1[prop])) {\n config[prop] = utils.deepMerge(config1[prop]);\n } else if (typeof config1[prop] !== 'undefined') {\n config[prop] = config1[prop];\n }\n });\n\n utils.forEach([\n 'baseURL', 'transformRequest', 'transformResponse', 'paramsSerializer',\n 'timeout', 'withCredentials', 'adapter', 'responseType', 'xsrfCookieName',\n 'xsrfHeaderName', 'onUploadProgress', 'onDownloadProgress', 'maxContentLength',\n 'validateStatus', 'maxRedirects', 'httpAgent', 'httpsAgent', 'cancelToken',\n 'socketPath'\n ], function defaultToConfig2(prop) {\n if (typeof config2[prop] !== 'undefined') {\n config[prop] = config2[prop];\n } else if (typeof config1[prop] !== 'undefined') {\n config[prop] = config1[prop];\n }\n });\n\n return config;\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/core/mergeConfig.js\n// module id = 22\n// module chunks = 0","'use strict';\n\n/**\n * A `Cancel` is an object that is thrown when an operation is canceled.\n *\n * @class\n * @param {string=} message The message.\n */\nfunction Cancel(message) {\n this.message = message;\n}\n\nCancel.prototype.toString = function toString() {\n return 'Cancel' + (this.message ? ': ' + this.message : '');\n};\n\nCancel.prototype.__CANCEL__ = true;\n\nmodule.exports = Cancel;\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/cancel/Cancel.js\n// module id = 23\n// module chunks = 0","'use strict';\n\nvar Cancel = require('./Cancel');\n\n/**\n * A `CancelToken` is an object that can be used to request cancellation of an operation.\n *\n * @class\n * @param {Function} executor The executor function.\n */\nfunction CancelToken(executor) {\n if (typeof executor !== 'function') {\n throw new TypeError('executor must be a function.');\n }\n\n var resolvePromise;\n this.promise = new Promise(function promiseExecutor(resolve) {\n resolvePromise = resolve;\n });\n\n var token = this;\n executor(function cancel(message) {\n if (token.reason) {\n // Cancellation has already been requested\n return;\n }\n\n token.reason = new Cancel(message);\n resolvePromise(token.reason);\n });\n}\n\n/**\n * Throws a `Cancel` if cancellation has been requested.\n */\nCancelToken.prototype.throwIfRequested = function throwIfRequested() {\n if (this.reason) {\n throw this.reason;\n }\n};\n\n/**\n * Returns an object that contains a new `CancelToken` and a function that, when called,\n * cancels the `CancelToken`.\n */\nCancelToken.source = function source() {\n var cancel;\n var token = new CancelToken(function executor(c) {\n cancel = c;\n });\n return {\n token: token,\n cancel: cancel\n };\n};\n\nmodule.exports = CancelToken;\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/cancel/CancelToken.js\n// module id = 24\n// module chunks = 0","'use strict';\n\n/**\n * Syntactic sugar for invoking a function and expanding an array for arguments.\n *\n * Common use case would be to use `Function.prototype.apply`.\n *\n * ```js\n * function f(x, y, z) {}\n * var args = [1, 2, 3];\n * f.apply(null, args);\n * ```\n *\n * With `spread` this example can be re-written.\n *\n * ```js\n * spread(function(x, y, z) {})([1, 2, 3]);\n * ```\n *\n * @param {Function} callback\n * @returns {Function}\n */\nmodule.exports = function spread(callback) {\n return function wrap(arr) {\n return callback.apply(null, arr);\n };\n};\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./lib/helpers/spread.js\n// module id = 25\n// module chunks = 0"],"sourceRoot":""} \ No newline at end of file diff --git a/node_modules/axios/index.d.ts b/node_modules/axios/index.d.ts new file mode 100644 index 0000000000..f934886659 --- /dev/null +++ b/node_modules/axios/index.d.ts @@ -0,0 +1,152 @@ +export interface AxiosTransformer { + (data: any, headers?: any): any; +} + +export interface AxiosAdapter { + (config: AxiosRequestConfig): AxiosPromise; +} + +export interface AxiosBasicCredentials { + username: string; + password: string; +} + +export interface AxiosProxyConfig { + host: string; + port: number; + auth?: { + username: string; + password:string; + }; + protocol?: string; +} + +export type Method = + | 'get' | 'GET' + | 'delete' | 'DELETE' + | 'head' | 'HEAD' + | 'options' | 'OPTIONS' + | 'post' | 'POST' + | 'put' | 'PUT' + | 'patch' | 'PATCH' + +export type ResponseType = + | 'arraybuffer' + | 'blob' + | 'document' + | 'json' + | 'text' + | 'stream' + +export interface AxiosRequestConfig { + url?: string; + method?: Method; + baseURL?: string; + transformRequest?: AxiosTransformer | AxiosTransformer[]; + transformResponse?: AxiosTransformer | AxiosTransformer[]; + headers?: any; + params?: any; + paramsSerializer?: (params: any) => string; + data?: any; + timeout?: number; + withCredentials?: boolean; + adapter?: AxiosAdapter; + auth?: AxiosBasicCredentials; + responseType?: ResponseType; + xsrfCookieName?: string; + xsrfHeaderName?: string; + onUploadProgress?: (progressEvent: any) => void; + onDownloadProgress?: (progressEvent: any) => void; + maxContentLength?: number; + validateStatus?: (status: number) => boolean; + maxRedirects?: number; + socketPath?: string | null; + httpAgent?: any; + httpsAgent?: any; + proxy?: AxiosProxyConfig | false; + cancelToken?: CancelToken; +} + +export interface AxiosResponse { + data: T; + status: number; + statusText: string; + headers: any; + config: AxiosRequestConfig; + request?: any; +} + +export interface AxiosError extends Error { + config: AxiosRequestConfig; + code?: string; + request?: any; + response?: AxiosResponse; + isAxiosError: boolean; +} + +export interface AxiosPromise extends Promise> { +} + +export interface CancelStatic { + new (message?: string): Cancel; +} + +export interface Cancel { + message: string; +} + +export interface Canceler { + (message?: string): void; +} + +export interface CancelTokenStatic { + new (executor: (cancel: Canceler) => void): CancelToken; + source(): CancelTokenSource; +} + +export interface CancelToken { + promise: Promise; + reason?: Cancel; + throwIfRequested(): void; +} + +export interface CancelTokenSource { + token: CancelToken; + cancel: Canceler; +} + +export interface AxiosInterceptorManager { + use(onFulfilled?: (value: V) => V | Promise, onRejected?: (error: any) => any): number; + eject(id: number): void; +} + +export interface AxiosInstance { + (config: AxiosRequestConfig): AxiosPromise; + (url: string, config?: AxiosRequestConfig): AxiosPromise; + defaults: AxiosRequestConfig; + interceptors: { + request: AxiosInterceptorManager; + response: AxiosInterceptorManager; + }; + getUri(config?: AxiosRequestConfig): string; + request> (config: AxiosRequestConfig): Promise; + get>(url: string, config?: AxiosRequestConfig): Promise; + delete>(url: string, config?: AxiosRequestConfig): Promise; + head>(url: string, config?: AxiosRequestConfig): Promise; + post>(url: string, data?: any, config?: AxiosRequestConfig): Promise; + put>(url: string, data?: any, config?: AxiosRequestConfig): Promise; + patch>(url: string, data?: any, config?: AxiosRequestConfig): Promise; +} + +export interface AxiosStatic extends AxiosInstance { + create(config?: AxiosRequestConfig): AxiosInstance; + Cancel: CancelStatic; + CancelToken: CancelTokenStatic; + isCancel(value: any): boolean; + all(values: (T | Promise)[]): Promise; + spread(callback: (...args: T[]) => R): (array: T[]) => R; +} + +declare const Axios: AxiosStatic; + +export default Axios; diff --git a/node_modules/axios/index.js b/node_modules/axios/index.js new file mode 100644 index 0000000000..79dfd09dd5 --- /dev/null +++ b/node_modules/axios/index.js @@ -0,0 +1 @@ +module.exports = require('./lib/axios'); \ No newline at end of file diff --git a/node_modules/axios/lib/adapters/README.md b/node_modules/axios/lib/adapters/README.md new file mode 100644 index 0000000000..68f1118959 --- /dev/null +++ b/node_modules/axios/lib/adapters/README.md @@ -0,0 +1,37 @@ +# axios // adapters + +The modules under `adapters/` are modules that handle dispatching a request and settling a returned `Promise` once a response is received. + +## Example + +```js +var settle = require('./../core/settle'); + +module.exports = function myAdapter(config) { + // At this point: + // - config has been merged with defaults + // - request transformers have already run + // - request interceptors have already run + + // Make the request using config provided + // Upon response settle the Promise + + return new Promise(function(resolve, reject) { + + var response = { + data: responseData, + status: request.status, + statusText: request.statusText, + headers: responseHeaders, + config: config, + request: request + }; + + settle(resolve, reject, response); + + // From here: + // - response transformers will run + // - response interceptors will run + }); +} +``` diff --git a/node_modules/axios/lib/adapters/http.js b/node_modules/axios/lib/adapters/http.js new file mode 100755 index 0000000000..06169ff2cb --- /dev/null +++ b/node_modules/axios/lib/adapters/http.js @@ -0,0 +1,275 @@ +'use strict'; + +var utils = require('./../utils'); +var settle = require('./../core/settle'); +var buildURL = require('./../helpers/buildURL'); +var http = require('http'); +var https = require('https'); +var httpFollow = require('follow-redirects').http; +var httpsFollow = require('follow-redirects').https; +var url = require('url'); +var zlib = require('zlib'); +var pkg = require('./../../package.json'); +var createError = require('../core/createError'); +var enhanceError = require('../core/enhanceError'); + +var isHttps = /https:?/; + +/*eslint consistent-return:0*/ +module.exports = function httpAdapter(config) { + return new Promise(function dispatchHttpRequest(resolvePromise, rejectPromise) { + var timer; + var resolve = function resolve(value) { + clearTimeout(timer); + resolvePromise(value); + }; + var reject = function reject(value) { + clearTimeout(timer); + rejectPromise(value); + }; + var data = config.data; + var headers = config.headers; + + // Set User-Agent (required by some servers) + // Only set header if it hasn't been set in config + // See https://github.com/axios/axios/issues/69 + if (!headers['User-Agent'] && !headers['user-agent']) { + headers['User-Agent'] = 'axios/' + pkg.version; + } + + if (data && !utils.isStream(data)) { + if (Buffer.isBuffer(data)) { + // Nothing to do... + } else if (utils.isArrayBuffer(data)) { + data = Buffer.from(new Uint8Array(data)); + } else if (utils.isString(data)) { + data = Buffer.from(data, 'utf-8'); + } else { + return reject(createError( + 'Data after transformation must be a string, an ArrayBuffer, a Buffer, or a Stream', + config + )); + } + + // Add Content-Length header if data exists + headers['Content-Length'] = data.length; + } + + // HTTP basic authentication + var auth = undefined; + if (config.auth) { + var username = config.auth.username || ''; + var password = config.auth.password || ''; + auth = username + ':' + password; + } + + // Parse url + var parsed = url.parse(config.url); + var protocol = parsed.protocol || 'http:'; + + if (!auth && parsed.auth) { + var urlAuth = parsed.auth.split(':'); + var urlUsername = urlAuth[0] || ''; + var urlPassword = urlAuth[1] || ''; + auth = urlUsername + ':' + urlPassword; + } + + if (auth) { + delete headers.Authorization; + } + + var isHttpsRequest = isHttps.test(protocol); + var agent = isHttpsRequest ? config.httpsAgent : config.httpAgent; + + var options = { + path: buildURL(parsed.path, config.params, config.paramsSerializer).replace(/^\?/, ''), + method: config.method.toUpperCase(), + headers: headers, + agent: agent, + auth: auth + }; + + if (config.socketPath) { + options.socketPath = config.socketPath; + } else { + options.hostname = parsed.hostname; + options.port = parsed.port; + } + + var proxy = config.proxy; + if (!proxy && proxy !== false) { + var proxyEnv = protocol.slice(0, -1) + '_proxy'; + var proxyUrl = process.env[proxyEnv] || process.env[proxyEnv.toUpperCase()]; + if (proxyUrl) { + var parsedProxyUrl = url.parse(proxyUrl); + var noProxyEnv = process.env.no_proxy || process.env.NO_PROXY; + var shouldProxy = true; + + if (noProxyEnv) { + var noProxy = noProxyEnv.split(',').map(function trim(s) { + return s.trim(); + }); + + shouldProxy = !noProxy.some(function proxyMatch(proxyElement) { + if (!proxyElement) { + return false; + } + if (proxyElement === '*') { + return true; + } + if (proxyElement[0] === '.' && + parsed.hostname.substr(parsed.hostname.length - proxyElement.length) === proxyElement && + proxyElement.match(/\./g).length === parsed.hostname.match(/\./g).length) { + return true; + } + + return parsed.hostname === proxyElement; + }); + } + + + if (shouldProxy) { + proxy = { + host: parsedProxyUrl.hostname, + port: parsedProxyUrl.port + }; + + if (parsedProxyUrl.auth) { + var proxyUrlAuth = parsedProxyUrl.auth.split(':'); + proxy.auth = { + username: proxyUrlAuth[0], + password: proxyUrlAuth[1] + }; + } + } + } + } + + if (proxy) { + options.hostname = proxy.host; + options.host = proxy.host; + options.headers.host = parsed.hostname + (parsed.port ? ':' + parsed.port : ''); + options.port = proxy.port; + options.path = protocol + '//' + parsed.hostname + (parsed.port ? ':' + parsed.port : '') + options.path; + + // Basic proxy authorization + if (proxy.auth) { + var base64 = Buffer.from(proxy.auth.username + ':' + proxy.auth.password, 'utf8').toString('base64'); + options.headers['Proxy-Authorization'] = 'Basic ' + base64; + } + } + + var transport; + var isHttpsProxy = isHttpsRequest && (proxy ? isHttps.test(proxy.protocol) : true); + if (config.transport) { + transport = config.transport; + } else if (config.maxRedirects === 0) { + transport = isHttpsProxy ? https : http; + } else { + if (config.maxRedirects) { + options.maxRedirects = config.maxRedirects; + } + transport = isHttpsProxy ? httpsFollow : httpFollow; + } + + if (config.maxContentLength && config.maxContentLength > -1) { + options.maxBodyLength = config.maxContentLength; + } + + // Create the request + var req = transport.request(options, function handleResponse(res) { + if (req.aborted) return; + + // uncompress the response body transparently if required + var stream = res; + switch (res.headers['content-encoding']) { + /*eslint default-case:0*/ + case 'gzip': + case 'compress': + case 'deflate': + // add the unzipper to the body stream processing pipeline + stream = (res.statusCode === 204) ? stream : stream.pipe(zlib.createUnzip()); + + // remove the content-encoding in order to not confuse downstream operations + delete res.headers['content-encoding']; + break; + } + + // return the last request in case of redirects + var lastRequest = res.req || req; + + var response = { + status: res.statusCode, + statusText: res.statusMessage, + headers: res.headers, + config: config, + request: lastRequest + }; + + if (config.responseType === 'stream') { + response.data = stream; + settle(resolve, reject, response); + } else { + var responseBuffer = []; + stream.on('data', function handleStreamData(chunk) { + responseBuffer.push(chunk); + + // make sure the content length is not over the maxContentLength if specified + if (config.maxContentLength > -1 && Buffer.concat(responseBuffer).length > config.maxContentLength) { + stream.destroy(); + reject(createError('maxContentLength size of ' + config.maxContentLength + ' exceeded', + config, null, lastRequest)); + } + }); + + stream.on('error', function handleStreamError(err) { + if (req.aborted) return; + reject(enhanceError(err, config, null, lastRequest)); + }); + + stream.on('end', function handleStreamEnd() { + var responseData = Buffer.concat(responseBuffer); + if (config.responseType !== 'arraybuffer') { + responseData = responseData.toString(config.responseEncoding); + } + + response.data = responseData; + settle(resolve, reject, response); + }); + } + }); + + // Handle errors + req.on('error', function handleRequestError(err) { + if (req.aborted) return; + reject(enhanceError(err, config, null, req)); + }); + + // Handle request timeout + if (config.timeout) { + timer = setTimeout(function handleRequestTimeout() { + req.abort(); + reject(createError('timeout of ' + config.timeout + 'ms exceeded', config, 'ECONNABORTED', req)); + }, config.timeout); + } + + if (config.cancelToken) { + // Handle cancellation + config.cancelToken.promise.then(function onCanceled(cancel) { + if (req.aborted) return; + + req.abort(); + reject(cancel); + }); + } + + // Send the request + if (utils.isStream(data)) { + data.on('error', function handleStreamError(err) { + reject(enhanceError(err, config, null, req)); + }).pipe(req); + } else { + req.end(data); + } + }); +}; diff --git a/node_modules/axios/lib/adapters/xhr.js b/node_modules/axios/lib/adapters/xhr.js new file mode 100644 index 0000000000..8c98d114b6 --- /dev/null +++ b/node_modules/axios/lib/adapters/xhr.js @@ -0,0 +1,174 @@ +'use strict'; + +var utils = require('./../utils'); +var settle = require('./../core/settle'); +var buildURL = require('./../helpers/buildURL'); +var parseHeaders = require('./../helpers/parseHeaders'); +var isURLSameOrigin = require('./../helpers/isURLSameOrigin'); +var createError = require('../core/createError'); + +module.exports = function xhrAdapter(config) { + return new Promise(function dispatchXhrRequest(resolve, reject) { + var requestData = config.data; + var requestHeaders = config.headers; + + if (utils.isFormData(requestData)) { + delete requestHeaders['Content-Type']; // Let the browser set it + } + + var request = new XMLHttpRequest(); + + // HTTP basic authentication + if (config.auth) { + var username = config.auth.username || ''; + var password = config.auth.password || ''; + requestHeaders.Authorization = 'Basic ' + btoa(username + ':' + password); + } + + request.open(config.method.toUpperCase(), buildURL(config.url, config.params, config.paramsSerializer), true); + + // Set the request timeout in MS + request.timeout = config.timeout; + + // Listen for ready state + request.onreadystatechange = function handleLoad() { + if (!request || request.readyState !== 4) { + return; + } + + // The request errored out and we didn't get a response, this will be + // handled by onerror instead + // With one exception: request that using file: protocol, most browsers + // will return status as 0 even though it's a successful request + if (request.status === 0 && !(request.responseURL && request.responseURL.indexOf('file:') === 0)) { + return; + } + + // Prepare the response + var responseHeaders = 'getAllResponseHeaders' in request ? parseHeaders(request.getAllResponseHeaders()) : null; + var responseData = !config.responseType || config.responseType === 'text' ? request.responseText : request.response; + var response = { + data: responseData, + status: request.status, + statusText: request.statusText, + headers: responseHeaders, + config: config, + request: request + }; + + settle(resolve, reject, response); + + // Clean up request + request = null; + }; + + // Handle browser request cancellation (as opposed to a manual cancellation) + request.onabort = function handleAbort() { + if (!request) { + return; + } + + reject(createError('Request aborted', config, 'ECONNABORTED', request)); + + // Clean up request + request = null; + }; + + // Handle low level network errors + request.onerror = function handleError() { + // Real errors are hidden from us by the browser + // onerror should only fire if it's a network error + reject(createError('Network Error', config, null, request)); + + // Clean up request + request = null; + }; + + // Handle timeout + request.ontimeout = function handleTimeout() { + reject(createError('timeout of ' + config.timeout + 'ms exceeded', config, 'ECONNABORTED', + request)); + + // Clean up request + request = null; + }; + + // Add xsrf header + // This is only done if running in a standard browser environment. + // Specifically not if we're in a web worker, or react-native. + if (utils.isStandardBrowserEnv()) { + var cookies = require('./../helpers/cookies'); + + // Add xsrf header + var xsrfValue = (config.withCredentials || isURLSameOrigin(config.url)) && config.xsrfCookieName ? + cookies.read(config.xsrfCookieName) : + undefined; + + if (xsrfValue) { + requestHeaders[config.xsrfHeaderName] = xsrfValue; + } + } + + // Add headers to the request + if ('setRequestHeader' in request) { + utils.forEach(requestHeaders, function setRequestHeader(val, key) { + if (typeof requestData === 'undefined' && key.toLowerCase() === 'content-type') { + // Remove Content-Type if data is undefined + delete requestHeaders[key]; + } else { + // Otherwise add header to the request + request.setRequestHeader(key, val); + } + }); + } + + // Add withCredentials to request if needed + if (config.withCredentials) { + request.withCredentials = true; + } + + // Add responseType to request if needed + if (config.responseType) { + try { + request.responseType = config.responseType; + } catch (e) { + // Expected DOMException thrown by browsers not compatible XMLHttpRequest Level 2. + // But, this can be suppressed for 'json' type as it can be parsed by default 'transformResponse' function. + if (config.responseType !== 'json') { + throw e; + } + } + } + + // Handle progress if needed + if (typeof config.onDownloadProgress === 'function') { + request.addEventListener('progress', config.onDownloadProgress); + } + + // Not all browsers support upload events + if (typeof config.onUploadProgress === 'function' && request.upload) { + request.upload.addEventListener('progress', config.onUploadProgress); + } + + if (config.cancelToken) { + // Handle cancellation + config.cancelToken.promise.then(function onCanceled(cancel) { + if (!request) { + return; + } + + request.abort(); + reject(cancel); + // Clean up request + request = null; + }); + } + + if (requestData === undefined) { + requestData = null; + } + + // Send the request + request.send(requestData); + }); +}; diff --git a/node_modules/axios/lib/axios.js b/node_modules/axios/lib/axios.js new file mode 100644 index 0000000000..8142437983 --- /dev/null +++ b/node_modules/axios/lib/axios.js @@ -0,0 +1,53 @@ +'use strict'; + +var utils = require('./utils'); +var bind = require('./helpers/bind'); +var Axios = require('./core/Axios'); +var mergeConfig = require('./core/mergeConfig'); +var defaults = require('./defaults'); + +/** + * Create an instance of Axios + * + * @param {Object} defaultConfig The default config for the instance + * @return {Axios} A new instance of Axios + */ +function createInstance(defaultConfig) { + var context = new Axios(defaultConfig); + var instance = bind(Axios.prototype.request, context); + + // Copy axios.prototype to instance + utils.extend(instance, Axios.prototype, context); + + // Copy context to instance + utils.extend(instance, context); + + return instance; +} + +// Create the default instance to be exported +var axios = createInstance(defaults); + +// Expose Axios class to allow class inheritance +axios.Axios = Axios; + +// Factory for creating new instances +axios.create = function create(instanceConfig) { + return createInstance(mergeConfig(axios.defaults, instanceConfig)); +}; + +// Expose Cancel & CancelToken +axios.Cancel = require('./cancel/Cancel'); +axios.CancelToken = require('./cancel/CancelToken'); +axios.isCancel = require('./cancel/isCancel'); + +// Expose all/spread +axios.all = function all(promises) { + return Promise.all(promises); +}; +axios.spread = require('./helpers/spread'); + +module.exports = axios; + +// Allow use of default import syntax in TypeScript +module.exports.default = axios; diff --git a/node_modules/axios/lib/cancel/Cancel.js b/node_modules/axios/lib/cancel/Cancel.js new file mode 100644 index 0000000000..e0de4003f9 --- /dev/null +++ b/node_modules/axios/lib/cancel/Cancel.js @@ -0,0 +1,19 @@ +'use strict'; + +/** + * A `Cancel` is an object that is thrown when an operation is canceled. + * + * @class + * @param {string=} message The message. + */ +function Cancel(message) { + this.message = message; +} + +Cancel.prototype.toString = function toString() { + return 'Cancel' + (this.message ? ': ' + this.message : ''); +}; + +Cancel.prototype.__CANCEL__ = true; + +module.exports = Cancel; diff --git a/node_modules/axios/lib/cancel/CancelToken.js b/node_modules/axios/lib/cancel/CancelToken.js new file mode 100644 index 0000000000..6b46e66625 --- /dev/null +++ b/node_modules/axios/lib/cancel/CancelToken.js @@ -0,0 +1,57 @@ +'use strict'; + +var Cancel = require('./Cancel'); + +/** + * A `CancelToken` is an object that can be used to request cancellation of an operation. + * + * @class + * @param {Function} executor The executor function. + */ +function CancelToken(executor) { + if (typeof executor !== 'function') { + throw new TypeError('executor must be a function.'); + } + + var resolvePromise; + this.promise = new Promise(function promiseExecutor(resolve) { + resolvePromise = resolve; + }); + + var token = this; + executor(function cancel(message) { + if (token.reason) { + // Cancellation has already been requested + return; + } + + token.reason = new Cancel(message); + resolvePromise(token.reason); + }); +} + +/** + * Throws a `Cancel` if cancellation has been requested. + */ +CancelToken.prototype.throwIfRequested = function throwIfRequested() { + if (this.reason) { + throw this.reason; + } +}; + +/** + * Returns an object that contains a new `CancelToken` and a function that, when called, + * cancels the `CancelToken`. + */ +CancelToken.source = function source() { + var cancel; + var token = new CancelToken(function executor(c) { + cancel = c; + }); + return { + token: token, + cancel: cancel + }; +}; + +module.exports = CancelToken; diff --git a/node_modules/axios/lib/cancel/isCancel.js b/node_modules/axios/lib/cancel/isCancel.js new file mode 100644 index 0000000000..051f3ae4c5 --- /dev/null +++ b/node_modules/axios/lib/cancel/isCancel.js @@ -0,0 +1,5 @@ +'use strict'; + +module.exports = function isCancel(value) { + return !!(value && value.__CANCEL__); +}; diff --git a/node_modules/axios/lib/core/Axios.js b/node_modules/axios/lib/core/Axios.js new file mode 100644 index 0000000000..811cb36498 --- /dev/null +++ b/node_modules/axios/lib/core/Axios.js @@ -0,0 +1,86 @@ +'use strict'; + +var utils = require('./../utils'); +var buildURL = require('../helpers/buildURL'); +var InterceptorManager = require('./InterceptorManager'); +var dispatchRequest = require('./dispatchRequest'); +var mergeConfig = require('./mergeConfig'); + +/** + * Create a new instance of Axios + * + * @param {Object} instanceConfig The default config for the instance + */ +function Axios(instanceConfig) { + this.defaults = instanceConfig; + this.interceptors = { + request: new InterceptorManager(), + response: new InterceptorManager() + }; +} + +/** + * Dispatch a request + * + * @param {Object} config The config specific for this request (merged with this.defaults) + */ +Axios.prototype.request = function request(config) { + /*eslint no-param-reassign:0*/ + // Allow for axios('example/url'[, config]) a la fetch API + if (typeof config === 'string') { + config = arguments[1] || {}; + config.url = arguments[0]; + } else { + config = config || {}; + } + + config = mergeConfig(this.defaults, config); + config.method = config.method ? config.method.toLowerCase() : 'get'; + + // Hook up interceptors middleware + var chain = [dispatchRequest, undefined]; + var promise = Promise.resolve(config); + + this.interceptors.request.forEach(function unshiftRequestInterceptors(interceptor) { + chain.unshift(interceptor.fulfilled, interceptor.rejected); + }); + + this.interceptors.response.forEach(function pushResponseInterceptors(interceptor) { + chain.push(interceptor.fulfilled, interceptor.rejected); + }); + + while (chain.length) { + promise = promise.then(chain.shift(), chain.shift()); + } + + return promise; +}; + +Axios.prototype.getUri = function getUri(config) { + config = mergeConfig(this.defaults, config); + return buildURL(config.url, config.params, config.paramsSerializer).replace(/^\?/, ''); +}; + +// Provide aliases for supported request methods +utils.forEach(['delete', 'get', 'head', 'options'], function forEachMethodNoData(method) { + /*eslint func-names:0*/ + Axios.prototype[method] = function(url, config) { + return this.request(utils.merge(config || {}, { + method: method, + url: url + })); + }; +}); + +utils.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method) { + /*eslint func-names:0*/ + Axios.prototype[method] = function(url, data, config) { + return this.request(utils.merge(config || {}, { + method: method, + url: url, + data: data + })); + }; +}); + +module.exports = Axios; diff --git a/node_modules/axios/lib/core/InterceptorManager.js b/node_modules/axios/lib/core/InterceptorManager.js new file mode 100644 index 0000000000..50d667bb44 --- /dev/null +++ b/node_modules/axios/lib/core/InterceptorManager.js @@ -0,0 +1,52 @@ +'use strict'; + +var utils = require('./../utils'); + +function InterceptorManager() { + this.handlers = []; +} + +/** + * Add a new interceptor to the stack + * + * @param {Function} fulfilled The function to handle `then` for a `Promise` + * @param {Function} rejected The function to handle `reject` for a `Promise` + * + * @return {Number} An ID used to remove interceptor later + */ +InterceptorManager.prototype.use = function use(fulfilled, rejected) { + this.handlers.push({ + fulfilled: fulfilled, + rejected: rejected + }); + return this.handlers.length - 1; +}; + +/** + * Remove an interceptor from the stack + * + * @param {Number} id The ID that was returned by `use` + */ +InterceptorManager.prototype.eject = function eject(id) { + if (this.handlers[id]) { + this.handlers[id] = null; + } +}; + +/** + * Iterate over all the registered interceptors + * + * This method is particularly useful for skipping over any + * interceptors that may have become `null` calling `eject`. + * + * @param {Function} fn The function to call for each interceptor + */ +InterceptorManager.prototype.forEach = function forEach(fn) { + utils.forEach(this.handlers, function forEachHandler(h) { + if (h !== null) { + fn(h); + } + }); +}; + +module.exports = InterceptorManager; diff --git a/node_modules/axios/lib/core/README.md b/node_modules/axios/lib/core/README.md new file mode 100644 index 0000000000..253bc48611 --- /dev/null +++ b/node_modules/axios/lib/core/README.md @@ -0,0 +1,7 @@ +# axios // core + +The modules found in `core/` should be modules that are specific to the domain logic of axios. These modules would most likely not make sense to be consumed outside of the axios module, as their logic is too specific. Some examples of core modules are: + +- Dispatching requests +- Managing interceptors +- Handling config diff --git a/node_modules/axios/lib/core/createError.js b/node_modules/axios/lib/core/createError.js new file mode 100644 index 0000000000..933680f694 --- /dev/null +++ b/node_modules/axios/lib/core/createError.js @@ -0,0 +1,18 @@ +'use strict'; + +var enhanceError = require('./enhanceError'); + +/** + * Create an Error with the specified message, config, error code, request and response. + * + * @param {string} message The error message. + * @param {Object} config The config. + * @param {string} [code] The error code (for example, 'ECONNABORTED'). + * @param {Object} [request] The request. + * @param {Object} [response] The response. + * @returns {Error} The created error. + */ +module.exports = function createError(message, config, code, request, response) { + var error = new Error(message); + return enhanceError(error, config, code, request, response); +}; diff --git a/node_modules/axios/lib/core/dispatchRequest.js b/node_modules/axios/lib/core/dispatchRequest.js new file mode 100644 index 0000000000..9ea70f2287 --- /dev/null +++ b/node_modules/axios/lib/core/dispatchRequest.js @@ -0,0 +1,86 @@ +'use strict'; + +var utils = require('./../utils'); +var transformData = require('./transformData'); +var isCancel = require('../cancel/isCancel'); +var defaults = require('../defaults'); +var isAbsoluteURL = require('./../helpers/isAbsoluteURL'); +var combineURLs = require('./../helpers/combineURLs'); + +/** + * Throws a `Cancel` if cancellation has been requested. + */ +function throwIfCancellationRequested(config) { + if (config.cancelToken) { + config.cancelToken.throwIfRequested(); + } +} + +/** + * Dispatch a request to the server using the configured adapter. + * + * @param {object} config The config that is to be used for the request + * @returns {Promise} The Promise to be fulfilled + */ +module.exports = function dispatchRequest(config) { + throwIfCancellationRequested(config); + + // Support baseURL config + if (config.baseURL && !isAbsoluteURL(config.url)) { + config.url = combineURLs(config.baseURL, config.url); + } + + // Ensure headers exist + config.headers = config.headers || {}; + + // Transform request data + config.data = transformData( + config.data, + config.headers, + config.transformRequest + ); + + // Flatten headers + config.headers = utils.merge( + config.headers.common || {}, + config.headers[config.method] || {}, + config.headers || {} + ); + + utils.forEach( + ['delete', 'get', 'head', 'post', 'put', 'patch', 'common'], + function cleanHeaderConfig(method) { + delete config.headers[method]; + } + ); + + var adapter = config.adapter || defaults.adapter; + + return adapter(config).then(function onAdapterResolution(response) { + throwIfCancellationRequested(config); + + // Transform response data + response.data = transformData( + response.data, + response.headers, + config.transformResponse + ); + + return response; + }, function onAdapterRejection(reason) { + if (!isCancel(reason)) { + throwIfCancellationRequested(config); + + // Transform response data + if (reason && reason.response) { + reason.response.data = transformData( + reason.response.data, + reason.response.headers, + config.transformResponse + ); + } + } + + return Promise.reject(reason); + }); +}; diff --git a/node_modules/axios/lib/core/enhanceError.js b/node_modules/axios/lib/core/enhanceError.js new file mode 100644 index 0000000000..02fbbd6a99 --- /dev/null +++ b/node_modules/axios/lib/core/enhanceError.js @@ -0,0 +1,42 @@ +'use strict'; + +/** + * Update an Error with the specified config, error code, and response. + * + * @param {Error} error The error to update. + * @param {Object} config The config. + * @param {string} [code] The error code (for example, 'ECONNABORTED'). + * @param {Object} [request] The request. + * @param {Object} [response] The response. + * @returns {Error} The error. + */ +module.exports = function enhanceError(error, config, code, request, response) { + error.config = config; + if (code) { + error.code = code; + } + + error.request = request; + error.response = response; + error.isAxiosError = true; + + error.toJSON = function() { + return { + // Standard + message: this.message, + name: this.name, + // Microsoft + description: this.description, + number: this.number, + // Mozilla + fileName: this.fileName, + lineNumber: this.lineNumber, + columnNumber: this.columnNumber, + stack: this.stack, + // Axios + config: this.config, + code: this.code + }; + }; + return error; +}; diff --git a/node_modules/axios/lib/core/mergeConfig.js b/node_modules/axios/lib/core/mergeConfig.js new file mode 100644 index 0000000000..6097a3e587 --- /dev/null +++ b/node_modules/axios/lib/core/mergeConfig.js @@ -0,0 +1,51 @@ +'use strict'; + +var utils = require('../utils'); + +/** + * Config-specific merge-function which creates a new config-object + * by merging two configuration objects together. + * + * @param {Object} config1 + * @param {Object} config2 + * @returns {Object} New object resulting from merging config2 to config1 + */ +module.exports = function mergeConfig(config1, config2) { + // eslint-disable-next-line no-param-reassign + config2 = config2 || {}; + var config = {}; + + utils.forEach(['url', 'method', 'params', 'data'], function valueFromConfig2(prop) { + if (typeof config2[prop] !== 'undefined') { + config[prop] = config2[prop]; + } + }); + + utils.forEach(['headers', 'auth', 'proxy'], function mergeDeepProperties(prop) { + if (utils.isObject(config2[prop])) { + config[prop] = utils.deepMerge(config1[prop], config2[prop]); + } else if (typeof config2[prop] !== 'undefined') { + config[prop] = config2[prop]; + } else if (utils.isObject(config1[prop])) { + config[prop] = utils.deepMerge(config1[prop]); + } else if (typeof config1[prop] !== 'undefined') { + config[prop] = config1[prop]; + } + }); + + utils.forEach([ + 'baseURL', 'transformRequest', 'transformResponse', 'paramsSerializer', + 'timeout', 'withCredentials', 'adapter', 'responseType', 'xsrfCookieName', + 'xsrfHeaderName', 'onUploadProgress', 'onDownloadProgress', 'maxContentLength', + 'validateStatus', 'maxRedirects', 'httpAgent', 'httpsAgent', 'cancelToken', + 'socketPath' + ], function defaultToConfig2(prop) { + if (typeof config2[prop] !== 'undefined') { + config[prop] = config2[prop]; + } else if (typeof config1[prop] !== 'undefined') { + config[prop] = config1[prop]; + } + }); + + return config; +}; diff --git a/node_modules/axios/lib/core/settle.js b/node_modules/axios/lib/core/settle.js new file mode 100644 index 0000000000..071d9e3e8f --- /dev/null +++ b/node_modules/axios/lib/core/settle.js @@ -0,0 +1,25 @@ +'use strict'; + +var createError = require('./createError'); + +/** + * Resolve or reject a Promise based on response status. + * + * @param {Function} resolve A function that resolves the promise. + * @param {Function} reject A function that rejects the promise. + * @param {object} response The response. + */ +module.exports = function settle(resolve, reject, response) { + var validateStatus = response.config.validateStatus; + if (!validateStatus || validateStatus(response.status)) { + resolve(response); + } else { + reject(createError( + 'Request failed with status code ' + response.status, + response.config, + null, + response.request, + response + )); + } +}; diff --git a/node_modules/axios/lib/core/transformData.js b/node_modules/axios/lib/core/transformData.js new file mode 100644 index 0000000000..e0653620e6 --- /dev/null +++ b/node_modules/axios/lib/core/transformData.js @@ -0,0 +1,20 @@ +'use strict'; + +var utils = require('./../utils'); + +/** + * Transform the data for a request or a response + * + * @param {Object|String} data The data to be transformed + * @param {Array} headers The headers for the request or response + * @param {Array|Function} fns A single function or Array of functions + * @returns {*} The resulting transformed data + */ +module.exports = function transformData(data, headers, fns) { + /*eslint no-param-reassign:0*/ + utils.forEach(fns, function transform(fn) { + data = fn(data, headers); + }); + + return data; +}; diff --git a/node_modules/axios/lib/defaults.js b/node_modules/axios/lib/defaults.js new file mode 100644 index 0000000000..7cb8a2504a --- /dev/null +++ b/node_modules/axios/lib/defaults.js @@ -0,0 +1,98 @@ +'use strict'; + +var utils = require('./utils'); +var normalizeHeaderName = require('./helpers/normalizeHeaderName'); + +var DEFAULT_CONTENT_TYPE = { + 'Content-Type': 'application/x-www-form-urlencoded' +}; + +function setContentTypeIfUnset(headers, value) { + if (!utils.isUndefined(headers) && utils.isUndefined(headers['Content-Type'])) { + headers['Content-Type'] = value; + } +} + +function getDefaultAdapter() { + var adapter; + // Only Node.JS has a process variable that is of [[Class]] process + if (typeof process !== 'undefined' && Object.prototype.toString.call(process) === '[object process]') { + // For node use HTTP adapter + adapter = require('./adapters/http'); + } else if (typeof XMLHttpRequest !== 'undefined') { + // For browsers use XHR adapter + adapter = require('./adapters/xhr'); + } + return adapter; +} + +var defaults = { + adapter: getDefaultAdapter(), + + transformRequest: [function transformRequest(data, headers) { + normalizeHeaderName(headers, 'Accept'); + normalizeHeaderName(headers, 'Content-Type'); + if (utils.isFormData(data) || + utils.isArrayBuffer(data) || + utils.isBuffer(data) || + utils.isStream(data) || + utils.isFile(data) || + utils.isBlob(data) + ) { + return data; + } + if (utils.isArrayBufferView(data)) { + return data.buffer; + } + if (utils.isURLSearchParams(data)) { + setContentTypeIfUnset(headers, 'application/x-www-form-urlencoded;charset=utf-8'); + return data.toString(); + } + if (utils.isObject(data)) { + setContentTypeIfUnset(headers, 'application/json;charset=utf-8'); + return JSON.stringify(data); + } + return data; + }], + + transformResponse: [function transformResponse(data) { + /*eslint no-param-reassign:0*/ + if (typeof data === 'string') { + try { + data = JSON.parse(data); + } catch (e) { /* Ignore */ } + } + return data; + }], + + /** + * A timeout in milliseconds to abort a request. If set to 0 (default) a + * timeout is not created. + */ + timeout: 0, + + xsrfCookieName: 'XSRF-TOKEN', + xsrfHeaderName: 'X-XSRF-TOKEN', + + maxContentLength: -1, + + validateStatus: function validateStatus(status) { + return status >= 200 && status < 300; + } +}; + +defaults.headers = { + common: { + 'Accept': 'application/json, text/plain, */*' + } +}; + +utils.forEach(['delete', 'get', 'head'], function forEachMethodNoData(method) { + defaults.headers[method] = {}; +}); + +utils.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method) { + defaults.headers[method] = utils.merge(DEFAULT_CONTENT_TYPE); +}); + +module.exports = defaults; diff --git a/node_modules/axios/lib/helpers/README.md b/node_modules/axios/lib/helpers/README.md new file mode 100644 index 0000000000..4ae34193a1 --- /dev/null +++ b/node_modules/axios/lib/helpers/README.md @@ -0,0 +1,7 @@ +# axios // helpers + +The modules found in `helpers/` should be generic modules that are _not_ specific to the domain logic of axios. These modules could theoretically be published to npm on their own and consumed by other modules or apps. Some examples of generic modules are things like: + +- Browser polyfills +- Managing cookies +- Parsing HTTP headers diff --git a/node_modules/axios/lib/helpers/bind.js b/node_modules/axios/lib/helpers/bind.js new file mode 100644 index 0000000000..6147c608e1 --- /dev/null +++ b/node_modules/axios/lib/helpers/bind.js @@ -0,0 +1,11 @@ +'use strict'; + +module.exports = function bind(fn, thisArg) { + return function wrap() { + var args = new Array(arguments.length); + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i]; + } + return fn.apply(thisArg, args); + }; +}; diff --git a/node_modules/axios/lib/helpers/buildURL.js b/node_modules/axios/lib/helpers/buildURL.js new file mode 100644 index 0000000000..8c40e4096a --- /dev/null +++ b/node_modules/axios/lib/helpers/buildURL.js @@ -0,0 +1,71 @@ +'use strict'; + +var utils = require('./../utils'); + +function encode(val) { + return encodeURIComponent(val). + replace(/%40/gi, '@'). + replace(/%3A/gi, ':'). + replace(/%24/g, '$'). + replace(/%2C/gi, ','). + replace(/%20/g, '+'). + replace(/%5B/gi, '['). + replace(/%5D/gi, ']'); +} + +/** + * Build a URL by appending params to the end + * + * @param {string} url The base of the url (e.g., http://www.google.com) + * @param {object} [params] The params to be appended + * @returns {string} The formatted url + */ +module.exports = function buildURL(url, params, paramsSerializer) { + /*eslint no-param-reassign:0*/ + if (!params) { + return url; + } + + var serializedParams; + if (paramsSerializer) { + serializedParams = paramsSerializer(params); + } else if (utils.isURLSearchParams(params)) { + serializedParams = params.toString(); + } else { + var parts = []; + + utils.forEach(params, function serialize(val, key) { + if (val === null || typeof val === 'undefined') { + return; + } + + if (utils.isArray(val)) { + key = key + '[]'; + } else { + val = [val]; + } + + utils.forEach(val, function parseValue(v) { + if (utils.isDate(v)) { + v = v.toISOString(); + } else if (utils.isObject(v)) { + v = JSON.stringify(v); + } + parts.push(encode(key) + '=' + encode(v)); + }); + }); + + serializedParams = parts.join('&'); + } + + if (serializedParams) { + var hashmarkIndex = url.indexOf('#'); + if (hashmarkIndex !== -1) { + url = url.slice(0, hashmarkIndex); + } + + url += (url.indexOf('?') === -1 ? '?' : '&') + serializedParams; + } + + return url; +}; diff --git a/node_modules/axios/lib/helpers/combineURLs.js b/node_modules/axios/lib/helpers/combineURLs.js new file mode 100644 index 0000000000..f1b58a5864 --- /dev/null +++ b/node_modules/axios/lib/helpers/combineURLs.js @@ -0,0 +1,14 @@ +'use strict'; + +/** + * Creates a new URL by combining the specified URLs + * + * @param {string} baseURL The base URL + * @param {string} relativeURL The relative URL + * @returns {string} The combined URL + */ +module.exports = function combineURLs(baseURL, relativeURL) { + return relativeURL + ? baseURL.replace(/\/+$/, '') + '/' + relativeURL.replace(/^\/+/, '') + : baseURL; +}; diff --git a/node_modules/axios/lib/helpers/cookies.js b/node_modules/axios/lib/helpers/cookies.js new file mode 100644 index 0000000000..5a8a66661c --- /dev/null +++ b/node_modules/axios/lib/helpers/cookies.js @@ -0,0 +1,53 @@ +'use strict'; + +var utils = require('./../utils'); + +module.exports = ( + utils.isStandardBrowserEnv() ? + + // Standard browser envs support document.cookie + (function standardBrowserEnv() { + return { + write: function write(name, value, expires, path, domain, secure) { + var cookie = []; + cookie.push(name + '=' + encodeURIComponent(value)); + + if (utils.isNumber(expires)) { + cookie.push('expires=' + new Date(expires).toGMTString()); + } + + if (utils.isString(path)) { + cookie.push('path=' + path); + } + + if (utils.isString(domain)) { + cookie.push('domain=' + domain); + } + + if (secure === true) { + cookie.push('secure'); + } + + document.cookie = cookie.join('; '); + }, + + read: function read(name) { + var match = document.cookie.match(new RegExp('(^|;\\s*)(' + name + ')=([^;]*)')); + return (match ? decodeURIComponent(match[3]) : null); + }, + + remove: function remove(name) { + this.write(name, '', Date.now() - 86400000); + } + }; + })() : + + // Non standard browser env (web workers, react-native) lack needed support. + (function nonStandardBrowserEnv() { + return { + write: function write() {}, + read: function read() { return null; }, + remove: function remove() {} + }; + })() +); diff --git a/node_modules/axios/lib/helpers/deprecatedMethod.js b/node_modules/axios/lib/helpers/deprecatedMethod.js new file mode 100644 index 0000000000..ed40965bab --- /dev/null +++ b/node_modules/axios/lib/helpers/deprecatedMethod.js @@ -0,0 +1,24 @@ +'use strict'; + +/*eslint no-console:0*/ + +/** + * Supply a warning to the developer that a method they are using + * has been deprecated. + * + * @param {string} method The name of the deprecated method + * @param {string} [instead] The alternate method to use if applicable + * @param {string} [docs] The documentation URL to get further details + */ +module.exports = function deprecatedMethod(method, instead, docs) { + try { + console.warn( + 'DEPRECATED method `' + method + '`.' + + (instead ? ' Use `' + instead + '` instead.' : '') + + ' This method will be removed in a future release.'); + + if (docs) { + console.warn('For more information about usage see ' + docs); + } + } catch (e) { /* Ignore */ } +}; diff --git a/node_modules/axios/lib/helpers/isAbsoluteURL.js b/node_modules/axios/lib/helpers/isAbsoluteURL.js new file mode 100644 index 0000000000..d33e99275c --- /dev/null +++ b/node_modules/axios/lib/helpers/isAbsoluteURL.js @@ -0,0 +1,14 @@ +'use strict'; + +/** + * Determines whether the specified URL is absolute + * + * @param {string} url The URL to test + * @returns {boolean} True if the specified URL is absolute, otherwise false + */ +module.exports = function isAbsoluteURL(url) { + // A URL is considered absolute if it begins with "://" or "//" (protocol-relative URL). + // RFC 3986 defines scheme name as a sequence of characters beginning with a letter and followed + // by any combination of letters, digits, plus, period, or hyphen. + return /^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(url); +}; diff --git a/node_modules/axios/lib/helpers/isURLSameOrigin.js b/node_modules/axios/lib/helpers/isURLSameOrigin.js new file mode 100644 index 0000000000..f1d89ad19d --- /dev/null +++ b/node_modules/axios/lib/helpers/isURLSameOrigin.js @@ -0,0 +1,68 @@ +'use strict'; + +var utils = require('./../utils'); + +module.exports = ( + utils.isStandardBrowserEnv() ? + + // Standard browser envs have full support of the APIs needed to test + // whether the request URL is of the same origin as current location. + (function standardBrowserEnv() { + var msie = /(msie|trident)/i.test(navigator.userAgent); + var urlParsingNode = document.createElement('a'); + var originURL; + + /** + * Parse a URL to discover it's components + * + * @param {String} url The URL to be parsed + * @returns {Object} + */ + function resolveURL(url) { + var href = url; + + if (msie) { + // IE needs attribute set twice to normalize properties + urlParsingNode.setAttribute('href', href); + href = urlParsingNode.href; + } + + urlParsingNode.setAttribute('href', href); + + // urlParsingNode provides the UrlUtils interface - http://url.spec.whatwg.org/#urlutils + return { + href: urlParsingNode.href, + protocol: urlParsingNode.protocol ? urlParsingNode.protocol.replace(/:$/, '') : '', + host: urlParsingNode.host, + search: urlParsingNode.search ? urlParsingNode.search.replace(/^\?/, '') : '', + hash: urlParsingNode.hash ? urlParsingNode.hash.replace(/^#/, '') : '', + hostname: urlParsingNode.hostname, + port: urlParsingNode.port, + pathname: (urlParsingNode.pathname.charAt(0) === '/') ? + urlParsingNode.pathname : + '/' + urlParsingNode.pathname + }; + } + + originURL = resolveURL(window.location.href); + + /** + * Determine if a URL shares the same origin as the current location + * + * @param {String} requestURL The URL to test + * @returns {boolean} True if URL shares the same origin, otherwise false + */ + return function isURLSameOrigin(requestURL) { + var parsed = (utils.isString(requestURL)) ? resolveURL(requestURL) : requestURL; + return (parsed.protocol === originURL.protocol && + parsed.host === originURL.host); + }; + })() : + + // Non standard browser envs (web workers, react-native) lack needed support. + (function nonStandardBrowserEnv() { + return function isURLSameOrigin() { + return true; + }; + })() +); diff --git a/node_modules/axios/lib/helpers/normalizeHeaderName.js b/node_modules/axios/lib/helpers/normalizeHeaderName.js new file mode 100644 index 0000000000..738c9fe40a --- /dev/null +++ b/node_modules/axios/lib/helpers/normalizeHeaderName.js @@ -0,0 +1,12 @@ +'use strict'; + +var utils = require('../utils'); + +module.exports = function normalizeHeaderName(headers, normalizedName) { + utils.forEach(headers, function processHeader(value, name) { + if (name !== normalizedName && name.toUpperCase() === normalizedName.toUpperCase()) { + headers[normalizedName] = value; + delete headers[name]; + } + }); +}; diff --git a/node_modules/axios/lib/helpers/parseHeaders.js b/node_modules/axios/lib/helpers/parseHeaders.js new file mode 100644 index 0000000000..8af2cc7f1b --- /dev/null +++ b/node_modules/axios/lib/helpers/parseHeaders.js @@ -0,0 +1,53 @@ +'use strict'; + +var utils = require('./../utils'); + +// Headers whose duplicates are ignored by node +// c.f. https://nodejs.org/api/http.html#http_message_headers +var ignoreDuplicateOf = [ + 'age', 'authorization', 'content-length', 'content-type', 'etag', + 'expires', 'from', 'host', 'if-modified-since', 'if-unmodified-since', + 'last-modified', 'location', 'max-forwards', 'proxy-authorization', + 'referer', 'retry-after', 'user-agent' +]; + +/** + * Parse headers into an object + * + * ``` + * Date: Wed, 27 Aug 2014 08:58:49 GMT + * Content-Type: application/json + * Connection: keep-alive + * Transfer-Encoding: chunked + * ``` + * + * @param {String} headers Headers needing to be parsed + * @returns {Object} Headers parsed into an object + */ +module.exports = function parseHeaders(headers) { + var parsed = {}; + var key; + var val; + var i; + + if (!headers) { return parsed; } + + utils.forEach(headers.split('\n'), function parser(line) { + i = line.indexOf(':'); + key = utils.trim(line.substr(0, i)).toLowerCase(); + val = utils.trim(line.substr(i + 1)); + + if (key) { + if (parsed[key] && ignoreDuplicateOf.indexOf(key) >= 0) { + return; + } + if (key === 'set-cookie') { + parsed[key] = (parsed[key] ? parsed[key] : []).concat([val]); + } else { + parsed[key] = parsed[key] ? parsed[key] + ', ' + val : val; + } + } + }); + + return parsed; +}; diff --git a/node_modules/axios/lib/helpers/spread.js b/node_modules/axios/lib/helpers/spread.js new file mode 100644 index 0000000000..25e3cdd394 --- /dev/null +++ b/node_modules/axios/lib/helpers/spread.js @@ -0,0 +1,27 @@ +'use strict'; + +/** + * Syntactic sugar for invoking a function and expanding an array for arguments. + * + * Common use case would be to use `Function.prototype.apply`. + * + * ```js + * function f(x, y, z) {} + * var args = [1, 2, 3]; + * f.apply(null, args); + * ``` + * + * With `spread` this example can be re-written. + * + * ```js + * spread(function(x, y, z) {})([1, 2, 3]); + * ``` + * + * @param {Function} callback + * @returns {Function} + */ +module.exports = function spread(callback) { + return function wrap(arr) { + return callback.apply(null, arr); + }; +}; diff --git a/node_modules/axios/lib/utils.js b/node_modules/axios/lib/utils.js new file mode 100644 index 0000000000..8946055dac --- /dev/null +++ b/node_modules/axios/lib/utils.js @@ -0,0 +1,334 @@ +'use strict'; + +var bind = require('./helpers/bind'); +var isBuffer = require('is-buffer'); + +/*global toString:true*/ + +// utils is a library of generic helper functions non-specific to axios + +var toString = Object.prototype.toString; + +/** + * Determine if a value is an Array + * + * @param {Object} val The value to test + * @returns {boolean} True if value is an Array, otherwise false + */ +function isArray(val) { + return toString.call(val) === '[object Array]'; +} + +/** + * Determine if a value is an ArrayBuffer + * + * @param {Object} val The value to test + * @returns {boolean} True if value is an ArrayBuffer, otherwise false + */ +function isArrayBuffer(val) { + return toString.call(val) === '[object ArrayBuffer]'; +} + +/** + * Determine if a value is a FormData + * + * @param {Object} val The value to test + * @returns {boolean} True if value is an FormData, otherwise false + */ +function isFormData(val) { + return (typeof FormData !== 'undefined') && (val instanceof FormData); +} + +/** + * Determine if a value is a view on an ArrayBuffer + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a view on an ArrayBuffer, otherwise false + */ +function isArrayBufferView(val) { + var result; + if ((typeof ArrayBuffer !== 'undefined') && (ArrayBuffer.isView)) { + result = ArrayBuffer.isView(val); + } else { + result = (val) && (val.buffer) && (val.buffer instanceof ArrayBuffer); + } + return result; +} + +/** + * Determine if a value is a String + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a String, otherwise false + */ +function isString(val) { + return typeof val === 'string'; +} + +/** + * Determine if a value is a Number + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a Number, otherwise false + */ +function isNumber(val) { + return typeof val === 'number'; +} + +/** + * Determine if a value is undefined + * + * @param {Object} val The value to test + * @returns {boolean} True if the value is undefined, otherwise false + */ +function isUndefined(val) { + return typeof val === 'undefined'; +} + +/** + * Determine if a value is an Object + * + * @param {Object} val The value to test + * @returns {boolean} True if value is an Object, otherwise false + */ +function isObject(val) { + return val !== null && typeof val === 'object'; +} + +/** + * Determine if a value is a Date + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a Date, otherwise false + */ +function isDate(val) { + return toString.call(val) === '[object Date]'; +} + +/** + * Determine if a value is a File + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a File, otherwise false + */ +function isFile(val) { + return toString.call(val) === '[object File]'; +} + +/** + * Determine if a value is a Blob + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a Blob, otherwise false + */ +function isBlob(val) { + return toString.call(val) === '[object Blob]'; +} + +/** + * Determine if a value is a Function + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a Function, otherwise false + */ +function isFunction(val) { + return toString.call(val) === '[object Function]'; +} + +/** + * Determine if a value is a Stream + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a Stream, otherwise false + */ +function isStream(val) { + return isObject(val) && isFunction(val.pipe); +} + +/** + * Determine if a value is a URLSearchParams object + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a URLSearchParams object, otherwise false + */ +function isURLSearchParams(val) { + return typeof URLSearchParams !== 'undefined' && val instanceof URLSearchParams; +} + +/** + * Trim excess whitespace off the beginning and end of a string + * + * @param {String} str The String to trim + * @returns {String} The String freed of excess whitespace + */ +function trim(str) { + return str.replace(/^\s*/, '').replace(/\s*$/, ''); +} + +/** + * Determine if we're running in a standard browser environment + * + * This allows axios to run in a web worker, and react-native. + * Both environments support XMLHttpRequest, but not fully standard globals. + * + * web workers: + * typeof window -> undefined + * typeof document -> undefined + * + * react-native: + * navigator.product -> 'ReactNative' + * nativescript + * navigator.product -> 'NativeScript' or 'NS' + */ +function isStandardBrowserEnv() { + if (typeof navigator !== 'undefined' && (navigator.product === 'ReactNative' || + navigator.product === 'NativeScript' || + navigator.product === 'NS')) { + return false; + } + return ( + typeof window !== 'undefined' && + typeof document !== 'undefined' + ); +} + +/** + * Iterate over an Array or an Object invoking a function for each item. + * + * If `obj` is an Array callback will be called passing + * the value, index, and complete array for each item. + * + * If 'obj' is an Object callback will be called passing + * the value, key, and complete object for each property. + * + * @param {Object|Array} obj The object to iterate + * @param {Function} fn The callback to invoke for each item + */ +function forEach(obj, fn) { + // Don't bother if no value provided + if (obj === null || typeof obj === 'undefined') { + return; + } + + // Force an array if not already something iterable + if (typeof obj !== 'object') { + /*eslint no-param-reassign:0*/ + obj = [obj]; + } + + if (isArray(obj)) { + // Iterate over array values + for (var i = 0, l = obj.length; i < l; i++) { + fn.call(null, obj[i], i, obj); + } + } else { + // Iterate over object keys + for (var key in obj) { + if (Object.prototype.hasOwnProperty.call(obj, key)) { + fn.call(null, obj[key], key, obj); + } + } + } +} + +/** + * Accepts varargs expecting each argument to be an object, then + * immutably merges the properties of each object and returns result. + * + * When multiple objects contain the same key the later object in + * the arguments list will take precedence. + * + * Example: + * + * ```js + * var result = merge({foo: 123}, {foo: 456}); + * console.log(result.foo); // outputs 456 + * ``` + * + * @param {Object} obj1 Object to merge + * @returns {Object} Result of all merge properties + */ +function merge(/* obj1, obj2, obj3, ... */) { + var result = {}; + function assignValue(val, key) { + if (typeof result[key] === 'object' && typeof val === 'object') { + result[key] = merge(result[key], val); + } else { + result[key] = val; + } + } + + for (var i = 0, l = arguments.length; i < l; i++) { + forEach(arguments[i], assignValue); + } + return result; +} + +/** + * Function equal to merge with the difference being that no reference + * to original objects is kept. + * + * @see merge + * @param {Object} obj1 Object to merge + * @returns {Object} Result of all merge properties + */ +function deepMerge(/* obj1, obj2, obj3, ... */) { + var result = {}; + function assignValue(val, key) { + if (typeof result[key] === 'object' && typeof val === 'object') { + result[key] = deepMerge(result[key], val); + } else if (typeof val === 'object') { + result[key] = deepMerge({}, val); + } else { + result[key] = val; + } + } + + for (var i = 0, l = arguments.length; i < l; i++) { + forEach(arguments[i], assignValue); + } + return result; +} + +/** + * Extends object a by mutably adding to it the properties of object b. + * + * @param {Object} a The object to be extended + * @param {Object} b The object to copy properties from + * @param {Object} thisArg The object to bind function to + * @return {Object} The resulting value of object a + */ +function extend(a, b, thisArg) { + forEach(b, function assignValue(val, key) { + if (thisArg && typeof val === 'function') { + a[key] = bind(val, thisArg); + } else { + a[key] = val; + } + }); + return a; +} + +module.exports = { + isArray: isArray, + isArrayBuffer: isArrayBuffer, + isBuffer: isBuffer, + isFormData: isFormData, + isArrayBufferView: isArrayBufferView, + isString: isString, + isNumber: isNumber, + isObject: isObject, + isUndefined: isUndefined, + isDate: isDate, + isFile: isFile, + isBlob: isBlob, + isFunction: isFunction, + isStream: isStream, + isURLSearchParams: isURLSearchParams, + isStandardBrowserEnv: isStandardBrowserEnv, + forEach: forEach, + merge: merge, + deepMerge: deepMerge, + extend: extend, + trim: trim +}; diff --git a/node_modules/axios/node_modules/is-buffer/LICENSE b/node_modules/axios/node_modules/is-buffer/LICENSE new file mode 100644 index 0000000000..0c068ceecb --- /dev/null +++ b/node_modules/axios/node_modules/is-buffer/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) Feross Aboukhadijeh + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/axios/node_modules/is-buffer/README.md b/node_modules/axios/node_modules/is-buffer/README.md new file mode 100644 index 0000000000..cce0a8cf92 --- /dev/null +++ b/node_modules/axios/node_modules/is-buffer/README.md @@ -0,0 +1,53 @@ +# is-buffer [![travis][travis-image]][travis-url] [![npm][npm-image]][npm-url] [![downloads][downloads-image]][downloads-url] [![javascript style guide][standard-image]][standard-url] + +[travis-image]: https://img.shields.io/travis/feross/is-buffer/master.svg +[travis-url]: https://travis-ci.org/feross/is-buffer +[npm-image]: https://img.shields.io/npm/v/is-buffer.svg +[npm-url]: https://npmjs.org/package/is-buffer +[downloads-image]: https://img.shields.io/npm/dm/is-buffer.svg +[downloads-url]: https://npmjs.org/package/is-buffer +[standard-image]: https://img.shields.io/badge/code_style-standard-brightgreen.svg +[standard-url]: https://standardjs.com + +#### Determine if an object is a [`Buffer`](http://nodejs.org/api/buffer.html) (including the [browserify Buffer](https://github.com/feross/buffer)) + +[![saucelabs][saucelabs-image]][saucelabs-url] + +[saucelabs-image]: https://saucelabs.com/browser-matrix/is-buffer.svg +[saucelabs-url]: https://saucelabs.com/u/is-buffer + +## Why not use `Buffer.isBuffer`? + +This module lets you check if an object is a `Buffer` without using `Buffer.isBuffer` (which includes the whole [buffer](https://github.com/feross/buffer) module in [browserify](http://browserify.org/)). + +It's future-proof and works in node too! + +## install + +```bash +npm install is-buffer +``` + +## usage + +```js +var isBuffer = require('is-buffer') + +isBuffer(new Buffer(4)) // true + +isBuffer(undefined) // false +isBuffer(null) // false +isBuffer('') // false +isBuffer(true) // false +isBuffer(false) // false +isBuffer(0) // false +isBuffer(1) // false +isBuffer(1.0) // false +isBuffer('string') // false +isBuffer({}) // false +isBuffer(function foo () {}) // false +``` + +## license + +MIT. Copyright (C) [Feross Aboukhadijeh](http://feross.org). diff --git a/node_modules/axios/node_modules/is-buffer/index.js b/node_modules/axios/node_modules/is-buffer/index.js new file mode 100644 index 0000000000..da9bfdd7dc --- /dev/null +++ b/node_modules/axios/node_modules/is-buffer/index.js @@ -0,0 +1,11 @@ +/*! + * Determine if an object is a Buffer + * + * @author Feross Aboukhadijeh + * @license MIT + */ + +module.exports = function isBuffer (obj) { + return obj != null && obj.constructor != null && + typeof obj.constructor.isBuffer === 'function' && obj.constructor.isBuffer(obj) +} diff --git a/node_modules/axios/node_modules/is-buffer/package.json b/node_modules/axios/node_modules/is-buffer/package.json new file mode 100644 index 0000000000..f4a13c56f9 --- /dev/null +++ b/node_modules/axios/node_modules/is-buffer/package.json @@ -0,0 +1,80 @@ +{ + "_from": "is-buffer@^2.0.2", + "_id": "is-buffer@2.0.3", + "_inBundle": false, + "_integrity": "sha512-U15Q7MXTuZlrbymiz95PJpZxu8IlipAp4dtS3wOdgPXx3mqBnslrWU14kxfHB+Py/+2PVKSr37dMAgM2A4uArw==", + "_location": "/axios/is-buffer", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "is-buffer@^2.0.2", + "name": "is-buffer", + "escapedName": "is-buffer", + "rawSpec": "^2.0.2", + "saveSpec": null, + "fetchSpec": "^2.0.2" + }, + "_requiredBy": [ + "/axios" + ], + "_resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-2.0.3.tgz", + "_shasum": "4ecf3fcf749cbd1e472689e109ac66261a25e725", + "_spec": "is-buffer@^2.0.2", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/axios", + "author": { + "name": "Feross Aboukhadijeh", + "email": "feross@feross.org", + "url": "https://feross.org" + }, + "bugs": { + "url": "https://github.com/feross/is-buffer/issues" + }, + "bundleDependencies": false, + "dependencies": {}, + "deprecated": false, + "description": "Determine if an object is a Buffer", + "devDependencies": { + "airtap": "0.0.7", + "standard": "*", + "tape": "^4.0.0" + }, + "engines": { + "node": ">=4" + }, + "homepage": "https://github.com/feross/is-buffer#readme", + "keywords": [ + "arraybuffer", + "browser", + "browser buffer", + "browserify", + "buffer", + "buffers", + "core buffer", + "dataview", + "float32array", + "float64array", + "int16array", + "int32array", + "type", + "typed array", + "uint32array" + ], + "license": "MIT", + "main": "index.js", + "name": "is-buffer", + "repository": { + "type": "git", + "url": "git://github.com/feross/is-buffer.git" + }, + "scripts": { + "test": "standard && npm run test-node && npm run test-browser", + "test-browser": "airtap -- test/*.js", + "test-browser-local": "airtap --local -- test/*.js", + "test-node": "tape test/*.js" + }, + "testling": { + "files": "test/*.js" + }, + "version": "2.0.3" +} diff --git a/node_modules/axios/package.json b/node_modules/axios/package.json new file mode 100644 index 0000000000..893e54f089 --- /dev/null +++ b/node_modules/axios/package.json @@ -0,0 +1,112 @@ +{ + "_from": "axios@0.19.0", + "_id": "axios@0.19.0", + "_inBundle": false, + "_integrity": "sha512-1uvKqKQta3KBxIz14F2v06AEHZ/dIoeKfbTRkK1E5oqjDnuEerLmYTgJB5AiQZHJcljpg1TuRzdjDR06qNk0DQ==", + "_location": "/axios", + "_phantomChildren": {}, + "_requested": { + "type": "version", + "registry": true, + "raw": "axios@0.19.0", + "name": "axios", + "escapedName": "axios", + "rawSpec": "0.19.0", + "saveSpec": null, + "fetchSpec": "0.19.0" + }, + "_requiredBy": [ + "/localtunnel" + ], + "_resolved": "https://registry.npmjs.org/axios/-/axios-0.19.0.tgz", + "_shasum": "8e09bff3d9122e133f7b8101c8fbdd00ed3d2ab8", + "_spec": "axios@0.19.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/localtunnel", + "author": { + "name": "Matt Zabriskie" + }, + "browser": { + "./lib/adapters/http.js": "./lib/adapters/xhr.js" + }, + "bugs": { + "url": "https://github.com/axios/axios/issues" + }, + "bundleDependencies": false, + "bundlesize": [ + { + "path": "./dist/axios.min.js", + "threshold": "5kB" + } + ], + "dependencies": { + "follow-redirects": "1.5.10", + "is-buffer": "^2.0.2" + }, + "deprecated": false, + "description": "Promise based HTTP client for the browser and node.js", + "devDependencies": { + "bundlesize": "^0.17.0", + "coveralls": "^3.0.0", + "es6-promise": "^4.2.4", + "grunt": "^1.0.2", + "grunt-banner": "^0.6.0", + "grunt-cli": "^1.2.0", + "grunt-contrib-clean": "^1.1.0", + "grunt-contrib-watch": "^1.0.0", + "grunt-eslint": "^20.1.0", + "grunt-karma": "^2.0.0", + "grunt-mocha-test": "^0.13.3", + "grunt-ts": "^6.0.0-beta.19", + "grunt-webpack": "^1.0.18", + "istanbul-instrumenter-loader": "^1.0.0", + "jasmine-core": "^2.4.1", + "karma": "^1.3.0", + "karma-chrome-launcher": "^2.2.0", + "karma-coverage": "^1.1.1", + "karma-firefox-launcher": "^1.1.0", + "karma-jasmine": "^1.1.1", + "karma-jasmine-ajax": "^0.1.13", + "karma-opera-launcher": "^1.0.0", + "karma-safari-launcher": "^1.0.0", + "karma-sauce-launcher": "^1.2.0", + "karma-sinon": "^1.0.5", + "karma-sourcemap-loader": "^0.3.7", + "karma-webpack": "^1.7.0", + "load-grunt-tasks": "^3.5.2", + "minimist": "^1.2.0", + "mocha": "^5.2.0", + "sinon": "^4.5.0", + "typescript": "^2.8.1", + "url-search-params": "^0.10.0", + "webpack": "^1.13.1", + "webpack-dev-server": "^1.14.1" + }, + "homepage": "https://github.com/axios/axios", + "keywords": [ + "xhr", + "http", + "ajax", + "promise", + "node" + ], + "license": "MIT", + "main": "index.js", + "name": "axios", + "repository": { + "type": "git", + "url": "git+https://github.com/axios/axios.git" + }, + "scripts": { + "build": "NODE_ENV=production grunt build", + "coveralls": "cat coverage/lcov.info | ./node_modules/coveralls/bin/coveralls.js", + "examples": "node ./examples/server.js", + "fix": "eslint --fix lib/**/*.js", + "postversion": "git push && git push --tags", + "preversion": "npm test", + "start": "node ./sandbox/server.js", + "test": "grunt test && bundlesize", + "version": "npm run build && grunt version && git add -A dist && git add CHANGELOG.md bower.json package.json" + }, + "typings": "./index.d.ts", + "version": "0.19.0" +} diff --git a/node_modules/bach/LICENSE b/node_modules/bach/LICENSE new file mode 100644 index 0000000000..0b2955ae3c --- /dev/null +++ b/node_modules/bach/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2014 Blaine Bublitz, Eric Schoffstall and other contributors + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/node_modules/bach/README.md b/node_modules/bach/README.md new file mode 100644 index 0000000000..4a9a8ebd1c --- /dev/null +++ b/node_modules/bach/README.md @@ -0,0 +1,252 @@ +

+ + + +

+ +# bach + +[![NPM version][npm-image]][npm-url] [![Downloads][downloads-image]][npm-url] [![Build Status][travis-image]][travis-url] [![AppVeyor Build Status][appveyor-image]][appveyor-url] [![Coveralls Status][coveralls-image]][coveralls-url] [![Gitter chat][gitter-image]][gitter-url] + +Compose your async functions with elegance. + +## Usage + +With `bach`, it is very easy to compose async functions to run in series or parallel. + +```js +var bach = require('bach'); + +function fn1(cb) { + cb(null, 1); +} + +function fn2(cb) { + cb(null, 2); +} + +function fn3(cb) { + cb(null, 3); +} + +var seriesFn = bach.series(fn1, fn2, fn3); +// fn1, fn2, and fn3 will be run in series +seriesFn(function(err, res) { + if (err) { // in this example, err is undefined + // handle error + } + // handle results + // in this example, res is [1, 2, 3] +}); + +var parallelFn = bach.parallel(fn1, fn2, fn3); +// fn1, fn2, and fn3 will be run in parallel +parallelFn(function(err, res) { + if (err) { // in this example, err is undefined + // handle error + } + // handle results + // in this example, res is [1, 2, 3] +}); +``` + +Since the composer functions return a function, you can combine them. + +```js +var combinedFn = bach.series(fn1, bach.parallel(fn2, fn3)); +// fn1 will be executed before fn2 and fn3 are run in parallel +combinedFn(function(err, res) { + if (err) { // in this example, err is undefined + // handle error + } + // handle results + // in this example, res is [1, [2, 3]] +}); +``` + +Functions are called with [async-done], so you can return a stream, promise, observable or child process. See [`async-done` completion and error resolution][completions] for more detail. + +```js +// streams +var fs = require('fs'); + +function streamFn1() { + return fs.createReadStream('./example') + .pipe(fs.createWriteStream('./example')); +} + +function streamFn2() { + return fs.createReadStream('./example') + .pipe(fs.createWriteStream('./example')); +} + +var parallelStreams = bach.parallel(streamFn1, streamFn2); +parallelStreams(function(err) { + if (err) { // in this example, err is undefined + // handle error + } + // all streams have emitted an 'end' or 'close' event +}); +``` + +```js +// promises +var when = require('when'); + +function promiseFn1() { + return when.resolve(1); +} + +function promiseFn2() { + return when.resolve(2); +} + +var parallelPromises = bach.parallel(promiseFn1, promiseFn2); +parallelPromises(function(err, res) { + if (err) { // in this example, err is undefined + // handle error + } + // handle results + // in this example, res is [1, 2] +}); +``` + +All errors are caught in a [domain] and passed to the final callback as the first argument. + +```js +function success(cb) { + setTimeout(function() { + cb(null, 1); + }, 500); +} + +function error() { + throw new Error('Thrown Error'); +} + +var errorThrownFn = bach.parallel(error, success); +errorThrownFn(function(err, res) { + if (err) { + // handle error + // in this example, err is an error caught by the domain + } + // handle results + // in this example, res is [undefined] +}); +``` + +When an error happens in a parallel composition, the callback will be called as soon as the error happens. +If you want to continue on error and wait until all functions have finished before calling the callback, use `settleSeries` or `settleParallel`. + +```js +function success(cb) { + setTimeout(function() { + cb(null, 1); + }, 500); +} + +function error(cb) { + cb(new Error('Async Error')); +} + +var parallelSettlingFn = bach.settleParallel(success, error); +parallelSettlingFn(function(err, res) { + // all functions have finished executing + if (err) { + // handle error + // in this example, err is an error passed to the callback + } + // handle results + // in this example, res is [1] +}); +``` + +## API + +### `series(fns..., [extensions])` + +Takes a variable amount of functions (`fns`) to be called in series when the returned function is +called. Optionally, takes an [extensions](#extensions) object as the last argument. + +Returns an `invoker(cb)` function to be called to start the serial execution. The invoker function takes a callback (`cb`) with the `function(error, results)` signature. + +If all functions complete successfully, the callback function will be called with all `results` as the second argument. + +If an error occurs, execution will stop and the error will be passed to the callback function as the first parameter. The error parameter will always be a single error. + +### `parallel(fns..., [extensions])` + +Takes a variable amount of functions (`fns`) to be called in parallel when the returned function is +called. Optionally, takes an [extensions](#extensions) object as the last argument. + +Returns an `invoker(cb)` function to be called to start the parallel execution. The invoker function takes a callback (`cb`) with the `function(error, results)` signature. + +If all functions complete successfully, the callback function will be called with all `results` as the second argument. + +If an error occurs, the callback function will be called with the error as the first parameter. Any async functions that have not completed, will still complete, but their results will __not__ be available. The error parameter will always be a single error. + +### `settleSeries(fns..., [extensions])` + +Takes a variable amount of functions (`fns`) to be called in series when the returned function is +called. Optionally, takes an [extensions](#extensions) object as the last argument. + +Returns an `invoker(cb)` function to be called to start the serial execution. The invoker function takes a callback (`cb`) with the `function(error, results)` signature. + +All functions will always be called and the callback will receive all settled errors and results. If any errors occur, the error parameter will be an array of errors. + +### `settleParallel(fns..., [extensions])` + +Takes a variable amount of functions (`fns`) to be called in parallel when the returned function is +called. Optionally, takes an [extensions](#extensions) object as the last argument. + +Returns an `invoker(cb)` function to be called to start the parallel execution. The invoker function takes a callback (`cb`) with the `function(error, results)` signature. + +All functions will always be called and the callback will receive all settled errors and results. If any errors occur, the error parameter will be an array of errors. + +### `extensions` + +The `extensions` object is used for specifying functions that give insight into the lifecycle of each function call. The possible extension points are `create`, `before`, `after` and `error`. If an extension point is not specified, it defaults to a no-op function. + +##### `extensions.create(fn, index)` + +Called at the very beginning of each function call with the function (`fn`) being executed and the `index` from the array/arguments. If `create` returns a value (`storage`), it is passed to the `before`, `after` and `error` extension points. + +If a value is not returned, an empty object is used as `storage` for each other extension point. + +This is useful for tracking information across an iteration. + +##### `extensions.before(storage)` + +Called immediately before each function call with the `storage` value returned from the `create` extension point. + +##### `extensions.after(result, storage)` + +Called immediately after each function call with the `result` of the function and the `storage` value returned from the `create` extension point. + +##### `extensions.error(error, storage)` + +Called immediately after a failed function call with the `error` of the function and the `storage` value returned from the `create` extension point. + +## License + +MIT + +[domain]: http://nodejs.org/api/domain.html +[async-done]: https://github.com/gulpjs/async-done +[completions]: https://github.com/gulpjs/async-done#completion-and-error-resolution + +[downloads-image]: http://img.shields.io/npm/dm/bach.svg +[npm-url]: https://www.npmjs.com/package/bach +[npm-image]: http://img.shields.io/npm/v/bach.svg + +[travis-url]: https://travis-ci.org/gulpjs/bach +[travis-image]: http://img.shields.io/travis/gulpjs/bach.svg?label=travis-ci + +[appveyor-url]: https://ci.appveyor.com/project/gulpjs/bach +[appveyor-image]: https://img.shields.io/appveyor/ci/gulpjs/bach.svg?label=appveyor + +[coveralls-url]: https://coveralls.io/r/gulpjs/bach +[coveralls-image]: http://img.shields.io/coveralls/gulpjs/bach.svg + +[gitter-url]: https://gitter.im/gulpjs/gulp +[gitter-image]: https://badges.gitter.im/gulpjs/gulp.svg diff --git a/node_modules/bach/index.js b/node_modules/bach/index.js new file mode 100644 index 0000000000..1a4848e008 --- /dev/null +++ b/node_modules/bach/index.js @@ -0,0 +1,8 @@ +'use strict'; + +module.exports = { + series: require('./lib/series'), + parallel: require('./lib/parallel'), + settleSeries: require('./lib/settleSeries'), + settleParallel: require('./lib/settleParallel'), +}; diff --git a/node_modules/bach/lib/helpers.js b/node_modules/bach/lib/helpers.js new file mode 100644 index 0000000000..aca276b493 --- /dev/null +++ b/node_modules/bach/lib/helpers.js @@ -0,0 +1,84 @@ +'use strict'; + +var assert = require('assert'); + +var filter = require('arr-filter'); +var map = require('arr-map'); +var flatten = require('arr-flatten'); +var forEach = require('array-each'); + +function noop() {} + +function getExtensions(lastArg) { + if (typeof lastArg !== 'function') { + return lastArg; + } +} + +function filterSuccess(elem) { + return elem.state === 'success'; +} + +function filterError(elem) { + return elem.state === 'error'; +} + +function buildOnSettled(done) { + if (typeof done !== 'function') { + done = noop; + } + + function onSettled(error, result) { + if (error) { + return done(error, null); + } + + var settledErrors = filter(result, filterError); + var settledResults = filter(result, filterSuccess); + + var errors = null; + if (settledErrors.length) { + errors = map(settledErrors, 'value'); + } + + var results = null; + if (settledResults.length) { + results = map(settledResults, 'value'); + } + + done(errors, results); + } + + return onSettled; +} + +function verifyArguments(args) { + args = flatten(args); + var lastIdx = args.length - 1; + + assert.ok(args.length, 'A set of functions to combine is required'); + + forEach(args, function(arg, argIdx) { + var isFunction = typeof arg === 'function'; + if (isFunction) { + return; + } + + if (argIdx === lastIdx) { + // Last arg can be an object of extension points + return; + } + + var msg = 'Only functions can be combined, got ' + typeof arg + + ' for argument ' + argIdx; + assert.ok(isFunction, msg); + }); + + return args; +} + +module.exports = { + getExtensions: getExtensions, + onSettled: buildOnSettled, + verifyArguments: verifyArguments, +}; diff --git a/node_modules/bach/lib/parallel.js b/node_modules/bach/lib/parallel.js new file mode 100644 index 0000000000..133a5c1765 --- /dev/null +++ b/node_modules/bach/lib/parallel.js @@ -0,0 +1,30 @@ +'use strict'; + +var initial = require('array-initial'); +var last = require('array-last'); +var asyncDone = require('async-done'); +var nowAndLater = require('now-and-later'); + +var helpers = require('./helpers'); + +function iterator(fn, key, cb) { + return asyncDone(fn, cb); +} + +function buildParallel() { + var args = helpers.verifyArguments(arguments); + + var extensions = helpers.getExtensions(last(args)); + + if (extensions) { + args = initial(args); + } + + function parallel(done) { + nowAndLater.map(args, iterator, extensions, done); + } + + return parallel; +} + +module.exports = buildParallel; diff --git a/node_modules/bach/lib/series.js b/node_modules/bach/lib/series.js new file mode 100644 index 0000000000..8b9f2844a9 --- /dev/null +++ b/node_modules/bach/lib/series.js @@ -0,0 +1,30 @@ +'use strict'; + +var initial = require('array-initial'); +var last = require('array-last'); +var asyncDone = require('async-done'); +var nowAndLater = require('now-and-later'); + +var helpers = require('./helpers'); + +function iterator(fn, key, cb) { + return asyncDone(fn, cb); +} + +function buildSeries() { + var args = helpers.verifyArguments(arguments); + + var extensions = helpers.getExtensions(last(args)); + + if (extensions) { + args = initial(args); + } + + function series(done) { + nowAndLater.mapSeries(args, iterator, extensions, done); + } + + return series; +} + +module.exports = buildSeries; diff --git a/node_modules/bach/lib/settleParallel.js b/node_modules/bach/lib/settleParallel.js new file mode 100644 index 0000000000..a022e166fa --- /dev/null +++ b/node_modules/bach/lib/settleParallel.js @@ -0,0 +1,31 @@ +'use strict'; + +var initial = require('array-initial'); +var last = require('array-last'); +var asyncSettle = require('async-settle'); +var nowAndLater = require('now-and-later'); + +var helpers = require('./helpers'); + +function iterator(fn, key, cb) { + return asyncSettle(fn, cb); +} + +function buildSettleParallel() { + var args = helpers.verifyArguments(arguments); + + var extensions = helpers.getExtensions(last(args)); + + if (extensions) { + args = initial(args); + } + + function settleParallel(done) { + var onSettled = helpers.onSettled(done); + nowAndLater.map(args, iterator, extensions, onSettled); + } + + return settleParallel; +} + +module.exports = buildSettleParallel; diff --git a/node_modules/bach/lib/settleSeries.js b/node_modules/bach/lib/settleSeries.js new file mode 100644 index 0000000000..727ada6809 --- /dev/null +++ b/node_modules/bach/lib/settleSeries.js @@ -0,0 +1,31 @@ +'use strict'; + +var initial = require('array-initial'); +var last = require('array-last'); +var asyncSettle = require('async-settle'); +var nowAndLater = require('now-and-later'); + +var helpers = require('./helpers'); + +function iterator(fn, key, cb) { + return asyncSettle(fn, cb); +} + +function buildSettleSeries() { + var args = helpers.verifyArguments(arguments); + + var extensions = helpers.getExtensions(last(args)); + + if (extensions) { + args = initial(args); + } + + function settleSeries(done) { + var onSettled = helpers.onSettled(done); + nowAndLater.mapSeries(args, iterator, extensions, onSettled); + } + + return settleSeries; +} + +module.exports = buildSettleSeries; diff --git a/node_modules/bach/package.json b/node_modules/bach/package.json new file mode 100644 index 0000000000..f1605cbc8a --- /dev/null +++ b/node_modules/bach/package.json @@ -0,0 +1,123 @@ +{ + "_from": "bach@^1.0.0", + "_id": "bach@1.2.0", + "_inBundle": false, + "_integrity": "sha1-Szzpa/JxNPeaG0FKUcFONMO9mIA=", + "_location": "/bach", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "bach@^1.0.0", + "name": "bach", + "escapedName": "bach", + "rawSpec": "^1.0.0", + "saveSpec": null, + "fetchSpec": "^1.0.0" + }, + "_requiredBy": [ + "/undertaker" + ], + "_resolved": "https://registry.npmjs.org/bach/-/bach-1.2.0.tgz", + "_shasum": "4b3ce96bf27134f79a1b414a51c14e34c3bd9880", + "_spec": "bach@^1.0.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/undertaker", + "author": { + "name": "Gulp Team", + "email": "team@gulpjs.com", + "url": "http://gulpjs.com/" + }, + "bugs": { + "url": "https://github.com/gulpjs/bach/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "Blaine Bublitz", + "email": "blaine.bublitz@gmail.com" + }, + { + "name": "Pawel Kozlowski", + "email": "pkozlowski.opensource@gmail.com" + }, + { + "name": "Benjamin Tan", + "email": "demoneaux@gmail.com" + } + ], + "dependencies": { + "arr-filter": "^1.1.1", + "arr-flatten": "^1.0.1", + "arr-map": "^2.0.0", + "array-each": "^1.0.0", + "array-initial": "^1.0.0", + "array-last": "^1.1.1", + "async-done": "^1.2.2", + "async-settle": "^1.0.0", + "now-and-later": "^2.0.0" + }, + "deprecated": false, + "description": "Compose your async functions with elegance.", + "devDependencies": { + "eslint": "^1.7.3", + "eslint-config-gulp": "^2.0.0", + "expect": "^1.19.0", + "istanbul": "^0.4.3", + "istanbul-coveralls": "^1.0.3", + "jscs": "^2.3.5", + "jscs-preset-gulp": "^1.0.0", + "mocha": "^2.4.5" + }, + "engines": { + "node": ">= 0.10" + }, + "files": [ + "index.js", + "lib", + "LICENSE" + ], + "homepage": "https://github.com/gulpjs/bach#readme", + "keywords": [ + "compose", + "fluent", + "composing", + "continuation", + "function composition", + "functional", + "async", + "map", + "series", + "parallel", + "extension", + "tracing", + "debug", + "timing", + "aop", + "settle", + "promises", + "callbacks", + "observables", + "streams", + "end", + "completion", + "complete", + "finish", + "done", + "error handling" + ], + "license": "MIT", + "main": "index.js", + "name": "bach", + "repository": { + "type": "git", + "url": "git+https://github.com/gulpjs/bach.git" + }, + "scripts": { + "cover": "istanbul cover _mocha --report lcovonly", + "coveralls": "npm run cover && istanbul-coveralls", + "lint": "eslint . && jscs index.js lib/ test/", + "pretest": "npm run lint", + "test": "mocha --async-only" + }, + "version": "1.2.0" +} diff --git a/node_modules/backo2/.npmignore b/node_modules/backo2/.npmignore new file mode 100644 index 0000000000..c2658d7d1b --- /dev/null +++ b/node_modules/backo2/.npmignore @@ -0,0 +1 @@ +node_modules/ diff --git a/node_modules/backo2/History.md b/node_modules/backo2/History.md new file mode 100644 index 0000000000..8eb28b8e71 --- /dev/null +++ b/node_modules/backo2/History.md @@ -0,0 +1,12 @@ + +1.0.1 / 2014-02-17 +================== + + * go away decimal point + * history + +1.0.0 / 2014-02-17 +================== + + * add jitter option + * Initial commit diff --git a/node_modules/backo2/Makefile b/node_modules/backo2/Makefile new file mode 100644 index 0000000000..9987df81aa --- /dev/null +++ b/node_modules/backo2/Makefile @@ -0,0 +1,8 @@ + +test: + @./node_modules/.bin/mocha \ + --require should \ + --reporter dot \ + --bail + +.PHONY: test \ No newline at end of file diff --git a/node_modules/backo2/Readme.md b/node_modules/backo2/Readme.md new file mode 100644 index 0000000000..0df2a399b1 --- /dev/null +++ b/node_modules/backo2/Readme.md @@ -0,0 +1,34 @@ +# backo + + Simple exponential backoff because the others seem to have weird abstractions. + +## Installation + +``` +$ npm install backo +``` + +## Options + + - `min` initial timeout in milliseconds [100] + - `max` max timeout [10000] + - `jitter` [0] + - `factor` [2] + +## Example + +```js +var Backoff = require('backo'); +var backoff = new Backoff({ min: 100, max: 20000 }); + +setTimeout(function(){ + something.reconnect(); +}, backoff.duration()); + +// later when something works +backoff.reset() +``` + +# License + + MIT diff --git a/node_modules/backo2/component.json b/node_modules/backo2/component.json new file mode 100644 index 0000000000..994845ac9b --- /dev/null +++ b/node_modules/backo2/component.json @@ -0,0 +1,11 @@ +{ + "name": "backo", + "repo": "segmentio/backo", + "dependencies": {}, + "version": "1.0.1", + "description": "simple backoff without the weird abstractions", + "keywords": ["backoff"], + "license": "MIT", + "scripts": ["index.js"], + "main": "index.js" +} diff --git a/node_modules/backo2/index.js b/node_modules/backo2/index.js new file mode 100644 index 0000000000..fac4429bf7 --- /dev/null +++ b/node_modules/backo2/index.js @@ -0,0 +1,85 @@ + +/** + * Expose `Backoff`. + */ + +module.exports = Backoff; + +/** + * Initialize backoff timer with `opts`. + * + * - `min` initial timeout in milliseconds [100] + * - `max` max timeout [10000] + * - `jitter` [0] + * - `factor` [2] + * + * @param {Object} opts + * @api public + */ + +function Backoff(opts) { + opts = opts || {}; + this.ms = opts.min || 100; + this.max = opts.max || 10000; + this.factor = opts.factor || 2; + this.jitter = opts.jitter > 0 && opts.jitter <= 1 ? opts.jitter : 0; + this.attempts = 0; +} + +/** + * Return the backoff duration. + * + * @return {Number} + * @api public + */ + +Backoff.prototype.duration = function(){ + var ms = this.ms * Math.pow(this.factor, this.attempts++); + if (this.jitter) { + var rand = Math.random(); + var deviation = Math.floor(rand * this.jitter * ms); + ms = (Math.floor(rand * 10) & 1) == 0 ? ms - deviation : ms + deviation; + } + return Math.min(ms, this.max) | 0; +}; + +/** + * Reset the number of attempts. + * + * @api public + */ + +Backoff.prototype.reset = function(){ + this.attempts = 0; +}; + +/** + * Set the minimum duration + * + * @api public + */ + +Backoff.prototype.setMin = function(min){ + this.ms = min; +}; + +/** + * Set the maximum duration + * + * @api public + */ + +Backoff.prototype.setMax = function(max){ + this.max = max; +}; + +/** + * Set the jitter + * + * @api public + */ + +Backoff.prototype.setJitter = function(jitter){ + this.jitter = jitter; +}; + diff --git a/node_modules/backo2/package.json b/node_modules/backo2/package.json new file mode 100644 index 0000000000..6e645ade5f --- /dev/null +++ b/node_modules/backo2/package.json @@ -0,0 +1,48 @@ +{ + "_from": "backo2@1.0.2", + "_id": "backo2@1.0.2", + "_inBundle": false, + "_integrity": "sha1-MasayLEpNjRj41s+u2n038+6eUc=", + "_location": "/backo2", + "_phantomChildren": {}, + "_requested": { + "type": "version", + "registry": true, + "raw": "backo2@1.0.2", + "name": "backo2", + "escapedName": "backo2", + "rawSpec": "1.0.2", + "saveSpec": null, + "fetchSpec": "1.0.2" + }, + "_requiredBy": [ + "/socket.io-client", + "/socket.io/socket.io-client" + ], + "_resolved": "https://registry.npmjs.org/backo2/-/backo2-1.0.2.tgz", + "_shasum": "31ab1ac8b129363463e35b3ebb69f4dfcfba7947", + "_spec": "backo2@1.0.2", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/socket.io-client", + "bugs": { + "url": "https://github.com/mokesmokes/backo/issues" + }, + "bundleDependencies": false, + "dependencies": {}, + "deprecated": false, + "description": "simple backoff based on segmentio/backo", + "devDependencies": { + "mocha": "*", + "should": "*" + }, + "homepage": "https://github.com/mokesmokes/backo#readme", + "keywords": [ + "backoff" + ], + "license": "MIT", + "name": "backo2", + "repository": { + "type": "git", + "url": "git+https://github.com/mokesmokes/backo.git" + }, + "version": "1.0.2" +} diff --git a/node_modules/backo2/test/index.js b/node_modules/backo2/test/index.js new file mode 100644 index 0000000000..ea1f6de132 --- /dev/null +++ b/node_modules/backo2/test/index.js @@ -0,0 +1,18 @@ + +var Backoff = require('..'); +var assert = require('assert'); + +describe('.duration()', function(){ + it('should increase the backoff', function(){ + var b = new Backoff; + + assert(100 == b.duration()); + assert(200 == b.duration()); + assert(400 == b.duration()); + assert(800 == b.duration()); + + b.reset(); + assert(100 == b.duration()); + assert(200 == b.duration()); + }) +}) \ No newline at end of file diff --git a/node_modules/base/LICENSE b/node_modules/base/LICENSE new file mode 100644 index 0000000000..e33d14b754 --- /dev/null +++ b/node_modules/base/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2015-2017, Jon Schlinkert. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/base/README.md b/node_modules/base/README.md new file mode 100644 index 0000000000..c77cdaf9d2 --- /dev/null +++ b/node_modules/base/README.md @@ -0,0 +1,491 @@ +

+ + + +

+ +# base [![NPM version](https://img.shields.io/npm/v/base.svg?style=flat)](https://www.npmjs.com/package/base) [![NPM monthly downloads](https://img.shields.io/npm/dm/base.svg?style=flat)](https://npmjs.org/package/base) [![NPM total downloads](https://img.shields.io/npm/dt/base.svg?style=flat)](https://npmjs.org/package/base) [![Linux Build Status](https://img.shields.io/travis/node-base/base.svg?style=flat&label=Travis)](https://travis-ci.org/node-base/base) + +> base is the foundation for creating modular, unit testable and highly pluggable node.js applications, starting with a handful of common methods, like `set`, `get`, `del` and `use`. + +## Install + +Install with [npm](https://www.npmjs.com/): + +```sh +$ npm install --save base +``` + +## What is Base? + +Base is a framework for rapidly creating high quality node.js applications, using plugins like building blocks. + +### Guiding principles + +The core team follows these principles to help guide API decisions: + +* **Compact API surface**: The smaller the API surface, the easier the library will be to learn and use. +* **Easy to extend**: Implementors can use any npm package, and write plugins in pure JavaScript. If you're building complex apps, Base simplifies inheritance. +* **Easy to test**: No special setup should be required to unit test `Base` or base plugins + +### Minimal API surface + +[The API](#api) was designed to provide only the minimum necessary functionality for creating a useful application, with or without [plugins](#plugins). + +**Base core** + +Base itself ships with only a handful of [useful methods](#api), such as: + +* `.set`: for setting values on the instance +* `.get`: for getting values from the instance +* `.has`: to check if a property exists on the instance +* `.define`: for setting non-enumerable values on the instance +* `.use`: for adding plugins + +**Be generic** + +When deciding on method to add or remove, we try to answer these questions: + +1. Will all or most Base applications need this method? +2. Will this method encourage practices or enforce conventions that are beneficial to implementors? +3. Can or should this be done in a plugin instead? + +### Composability + +**Plugin system** + +It couldn't be easier to extend Base with any features or custom functionality you can think of. + +Base plugins are just functions that take an instance of `Base`: + +```js +var base = new Base(); + +function plugin(base) { + // do plugin stuff, in pure JavaScript +} +// use the plugin +base.use(plugin); +``` + +**Inheritance** + +Easily inherit Base using `.extend`: + +```js +var Base = require('base'); + +function MyApp() { + Base.call(this); +} +Base.extend(MyApp); + +var app = new MyApp(); +app.set('a', 'b'); +app.get('a'); +//=> 'b'; +``` + +**Inherit or instantiate with a namespace** + +By default, the `.get`, `.set` and `.has` methods set and get values from the root of the `base` instance. You can customize this using the `.namespace` method exposed on the exported function. For example: + +```js +var Base = require('base'); +// get and set values on the `base.cache` object +var base = Base.namespace('cache'); + +var app = base(); +app.set('foo', 'bar'); +console.log(app.cache.foo); +//=> 'bar' +``` + +## API + +**Usage** + +```js +var Base = require('base'); +var app = new Base(); +app.set('foo', 'bar'); +console.log(app.foo); +//=> 'bar' +``` + +### [Base](index.js#L44) + +Create an instance of `Base` with the given `config` and `options`. + +**Params** + +* `config` **{Object}**: If supplied, this object is passed to [cache-base](https://github.com/jonschlinkert/cache-base) to merge onto the the instance upon instantiation. +* `options` **{Object}**: If supplied, this object is used to initialize the `base.options` object. + +**Example** + +```js +// initialize with `config` and `options` +var app = new Base({isApp: true}, {abc: true}); +app.set('foo', 'bar'); + +// values defined with the given `config` object will be on the root of the instance +console.log(app.baz); //=> undefined +console.log(app.foo); //=> 'bar' +// or use `.get` +console.log(app.get('isApp')); //=> true +console.log(app.get('foo')); //=> 'bar' + +// values defined with the given `options` object will be on `app.options +console.log(app.options.abc); //=> true +``` + +### [.is](index.js#L107) + +Set the given `name` on `app._name` and `app.is*` properties. Used for doing lookups in plugins. + +**Params** + +* `name` **{String}** +* `returns` **{Boolean}** + +**Example** + +```js +app.is('foo'); +console.log(app._name); +//=> 'foo' +console.log(app.isFoo); +//=> true +app.is('bar'); +console.log(app.isFoo); +//=> true +console.log(app.isBar); +//=> true +console.log(app._name); +//=> 'bar' +``` + +### [.isRegistered](index.js#L145) + +Returns true if a plugin has already been registered on an instance. + +Plugin implementors are encouraged to use this first thing in a plugin +to prevent the plugin from being called more than once on the same +instance. + +**Params** + +* `name` **{String}**: The plugin name. +* `register` **{Boolean}**: If the plugin if not already registered, to record it as being registered pass `true` as the second argument. +* `returns` **{Boolean}**: Returns true if a plugin is already registered. + +**Events** + +* `emits`: `plugin` Emits the name of the plugin being registered. Useful for unit tests, to ensure plugins are only registered once. + +**Example** + +```js +var base = new Base(); +base.use(function(app) { + if (app.isRegistered('myPlugin')) return; + // do stuff to `app` +}); + +// to also record the plugin as being registered +base.use(function(app) { + if (app.isRegistered('myPlugin', true)) return; + // do stuff to `app` +}); +``` + +### [.use](index.js#L175) + +Define a plugin function to be called immediately upon init. Plugins are chainable and expose the following arguments to the plugin function: + +* `app`: the current instance of `Base` +* `base`: the [first ancestor instance](#base) of `Base` + +**Params** + +* `fn` **{Function}**: plugin function to call +* `returns` **{Object}**: Returns the item instance for chaining. + +**Example** + +```js +var app = new Base() + .use(foo) + .use(bar) + .use(baz) +``` + +### [.define](index.js#L197) + +The `.define` method is used for adding non-enumerable property on the instance. Dot-notation is **not supported** with `define`. + +**Params** + +* `key` **{String}**: The name of the property to define. +* `value` **{any}** +* `returns` **{Object}**: Returns the instance for chaining. + +**Example** + +```js +// arbitrary `render` function using lodash `template` +app.define('render', function(str, locals) { + return _.template(str)(locals); +}); +``` + +### [.mixin](index.js#L222) + +Mix property `key` onto the Base prototype. If base is inherited using `Base.extend` this method will be overridden by a new `mixin` method that will only add properties to the prototype of the inheriting application. + +**Params** + +* `key` **{String}** +* `val` **{Object|Array}** +* `returns` **{Object}**: Returns the `base` instance for chaining. + +**Example** + +```js +app.mixin('foo', function() { + // do stuff +}); +``` + +### [.base](index.js#L268) + +Getter/setter used when creating nested instances of `Base`, for storing a reference to the first ancestor instance. This works by setting an instance of `Base` on the `parent` property of a "child" instance. The `base` property defaults to the current instance if no `parent` property is defined. + +**Example** + +```js +// create an instance of `Base`, this is our first ("base") instance +var first = new Base(); +first.foo = 'bar'; // arbitrary property, to make it easier to see what's happening later + +// create another instance +var second = new Base(); +// create a reference to the first instance (`first`) +second.parent = first; + +// create another instance +var third = new Base(); +// create a reference to the previous instance (`second`) +// repeat this pattern every time a "child" instance is created +third.parent = second; + +// we can always access the first instance using the `base` property +console.log(first.base.foo); +//=> 'bar' +console.log(second.base.foo); +//=> 'bar' +console.log(third.base.foo); +//=> 'bar' +// and now you know how to get to third base ;) +``` + +### [#use](index.js#L293) + +Static method for adding global plugin functions that will be added to an instance when created. + +**Params** + +* `fn` **{Function}**: Plugin function to use on each instance. +* `returns` **{Object}**: Returns the `Base` constructor for chaining + +**Example** + +```js +Base.use(function(app) { + app.foo = 'bar'; +}); +var app = new Base(); +console.log(app.foo); +//=> 'bar' +``` + +### [#extend](index.js#L337) + +Static method for inheriting the prototype and static methods of the `Base` class. This method greatly simplifies the process of creating inheritance-based applications. See [static-extend](https://github.com/jonschlinkert/static-extend) for more details. + +**Params** + +* `Ctor` **{Function}**: constructor to extend +* `methods` **{Object}**: Optional prototype properties to mix in. +* `returns` **{Object}**: Returns the `Base` constructor for chaining + +**Example** + +```js +var extend = cu.extend(Parent); +Parent.extend(Child); + +// optional methods +Parent.extend(Child, { + foo: function() {}, + bar: function() {} +}); +``` + +### [#mixin](index.js#L379) + +Used for adding methods to the `Base` prototype, and/or to the prototype of child instances. When a mixin function returns a function, the returned function is pushed onto the `.mixins` array, making it available to be used on inheriting classes whenever `Base.mixins()` is called (e.g. `Base.mixins(Child)`). + +**Params** + +* `fn` **{Function}**: Function to call +* `returns` **{Object}**: Returns the `Base` constructor for chaining + +**Example** + +```js +Base.mixin(function(proto) { + proto.foo = function(msg) { + return 'foo ' + msg; + }; +}); +``` + +### [#mixins](index.js#L401) + +Static method for running global mixin functions against a child constructor. Mixins must be registered before calling this method. + +**Params** + +* `Child` **{Function}**: Constructor function of a child class +* `returns` **{Object}**: Returns the `Base` constructor for chaining + +**Example** + +```js +Base.extend(Child); +Base.mixins(Child); +``` + +### [#inherit](index.js#L420) + +Similar to `util.inherit`, but copies all static properties, prototype properties, and getters/setters from `Provider` to `Receiver`. See [class-utils](https://github.com/jonschlinkert/class-utils#inherit) for more details. + +**Params** + +* `Receiver` **{Function}**: Receiving (child) constructor +* `Provider` **{Function}**: Providing (parent) constructor +* `returns` **{Object}**: Returns the `Base` constructor for chaining + +**Example** + +```js +Base.inherit(Foo, Bar); +``` + +## In the wild + +The following node.js applications were built with `Base`: + +* [assemble](https://github.com/assemble/assemble) +* [verb](https://github.com/verbose/verb) +* [generate](https://github.com/generate/generate) +* [scaffold](https://github.com/jonschlinkert/scaffold) +* [boilerplate](https://github.com/jonschlinkert/boilerplate) + +## Test coverage + +``` +Statements : 98.91% ( 91/92 ) +Branches : 92.86% ( 26/28 ) +Functions : 100% ( 17/17 ) +Lines : 98.9% ( 90/91 ) +``` + +## History + +### v0.11.2 + +* fixes https://github.com/micromatch/micromatch/issues/99 + +### v0.11.0 + +**Breaking changes** + +* Static `.use` and `.run` methods are now non-enumerable + +### v0.9.0 + +**Breaking changes** + +* `.is` no longer takes a function, a string must be passed +* all remaining `.debug` code has been removed +* `app._namespace` was removed (related to `debug`) +* `.plugin`, `.use`, and `.define` no longer emit events +* `.assertPlugin` was removed +* `.lazy` was removed + +## About + +### Related projects + +* [base-cwd](https://www.npmjs.com/package/base-cwd): Base plugin that adds a getter/setter for the current working directory. | [homepage](https://github.com/node-base/base-cwd "Base plugin that adds a getter/setter for the current working directory.") +* [base-data](https://www.npmjs.com/package/base-data): adds a `data` method to base-methods. | [homepage](https://github.com/node-base/base-data "adds a `data` method to base-methods.") +* [base-fs](https://www.npmjs.com/package/base-fs): base-methods plugin that adds vinyl-fs methods to your 'base' application for working with the file… [more](https://github.com/node-base/base-fs) | [homepage](https://github.com/node-base/base-fs "base-methods plugin that adds vinyl-fs methods to your 'base' application for working with the file system, like src, dest, copy and symlink.") +* [base-generators](https://www.npmjs.com/package/base-generators): Adds project-generator support to your `base` application. | [homepage](https://github.com/node-base/base-generators "Adds project-generator support to your `base` application.") +* [base-option](https://www.npmjs.com/package/base-option): Adds a few options methods to base, like `option`, `enable` and `disable`. See the readme… [more](https://github.com/node-base/base-option) | [homepage](https://github.com/node-base/base-option "Adds a few options methods to base, like `option`, `enable` and `disable`. See the readme for the full API.") +* [base-pipeline](https://www.npmjs.com/package/base-pipeline): base-methods plugin that adds pipeline and plugin methods for dynamically composing streaming plugin pipelines. | [homepage](https://github.com/node-base/base-pipeline "base-methods plugin that adds pipeline and plugin methods for dynamically composing streaming plugin pipelines.") +* [base-pkg](https://www.npmjs.com/package/base-pkg): Plugin for adding a `pkg` method that exposes pkg-store to your base application. | [homepage](https://github.com/node-base/base-pkg "Plugin for adding a `pkg` method that exposes pkg-store to your base application.") +* [base-plugins](https://www.npmjs.com/package/base-plugins): Adds 'smart plugin' support to your base application. | [homepage](https://github.com/node-base/base-plugins "Adds 'smart plugin' support to your base application.") +* [base-questions](https://www.npmjs.com/package/base-questions): Plugin for base-methods that adds methods for prompting the user and storing the answers on… [more](https://github.com/node-base/base-questions) | [homepage](https://github.com/node-base/base-questions "Plugin for base-methods that adds methods for prompting the user and storing the answers on a project-by-project basis.") +* [base-store](https://www.npmjs.com/package/base-store): Plugin for getting and persisting config values with your base-methods application. Adds a 'store' object… [more](https://github.com/node-base/base-store) | [homepage](https://github.com/node-base/base-store "Plugin for getting and persisting config values with your base-methods application. Adds a 'store' object that exposes all of the methods from the data-store library. Also now supports sub-stores!") +* [base-task](https://www.npmjs.com/package/base-task): base plugin that provides a very thin wrapper around [https://github.com/doowb/composer](https://github.com/doowb/composer) for adding task methods to… [more](https://github.com/node-base/base-task) | [homepage](https://github.com/node-base/base-task "base plugin that provides a very thin wrapper around for adding task methods to your application.") + +### Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new). + +### Contributors + +| **Commits** | **Contributor** | +| --- | --- | +| 141 | [jonschlinkert](https://github.com/jonschlinkert) | +| 30 | [doowb](https://github.com/doowb) | +| 3 | [charlike](https://github.com/charlike) | +| 1 | [criticalmash](https://github.com/criticalmash) | +| 1 | [wtgtybhertgeghgtwtg](https://github.com/wtgtybhertgeghgtwtg) | + +### Building docs + +_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_ + +To generate the readme, run the following command: + +```sh +$ npm install -g verbose/verb#dev verb-generate-readme && verb +``` + +### Running tests + +Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command: + +```sh +$ npm install && npm test +``` + +### Author + +**Jon Schlinkert** + +* [github/jonschlinkert](https://github.com/jonschlinkert) +* [twitter/jonschlinkert](https://twitter.com/jonschlinkert) + +### License + +Copyright © 2017, [Jon Schlinkert](https://github.com/jonschlinkert). +Released under the [MIT License](LICENSE). + +*** + +_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.6.0, on September 07, 2017._ \ No newline at end of file diff --git a/node_modules/base/index.js b/node_modules/base/index.js new file mode 100644 index 0000000000..fb680481e4 --- /dev/null +++ b/node_modules/base/index.js @@ -0,0 +1,435 @@ +'use strict'; + +var util = require('util'); +var define = require('define-property'); +var CacheBase = require('cache-base'); +var Emitter = require('component-emitter'); +var isObject = require('isobject'); +var merge = require('mixin-deep'); +var pascal = require('pascalcase'); +var cu = require('class-utils'); + +/** + * Optionally define a custom `cache` namespace to use. + */ + +function namespace(name) { + var Cache = name ? CacheBase.namespace(name) : CacheBase; + var fns = []; + + /** + * Create an instance of `Base` with the given `config` and `options`. + * + * ```js + * // initialize with `config` and `options` + * var app = new Base({isApp: true}, {abc: true}); + * app.set('foo', 'bar'); + * + * // values defined with the given `config` object will be on the root of the instance + * console.log(app.baz); //=> undefined + * console.log(app.foo); //=> 'bar' + * // or use `.get` + * console.log(app.get('isApp')); //=> true + * console.log(app.get('foo')); //=> 'bar' + * + * // values defined with the given `options` object will be on `app.options + * console.log(app.options.abc); //=> true + * ``` + * + * @param {Object} `config` If supplied, this object is passed to [cache-base][] to merge onto the the instance upon instantiation. + * @param {Object} `options` If supplied, this object is used to initialize the `base.options` object. + * @api public + */ + + function Base(config, options) { + if (!(this instanceof Base)) { + return new Base(config, options); + } + Cache.call(this, config); + this.is('base'); + this.initBase(config, options); + } + + /** + * Inherit cache-base + */ + + util.inherits(Base, Cache); + + /** + * Add static emitter methods + */ + + Emitter(Base); + + /** + * Initialize `Base` defaults with the given `config` object + */ + + Base.prototype.initBase = function(config, options) { + this.options = merge({}, this.options, options); + this.cache = this.cache || {}; + this.define('registered', {}); + if (name) this[name] = {}; + + // make `app._callbacks` non-enumerable + this.define('_callbacks', this._callbacks); + if (isObject(config)) { + this.visit('set', config); + } + Base.run(this, 'use', fns); + }; + + /** + * Set the given `name` on `app._name` and `app.is*` properties. Used for doing + * lookups in plugins. + * + * ```js + * app.is('foo'); + * console.log(app._name); + * //=> 'foo' + * console.log(app.isFoo); + * //=> true + * app.is('bar'); + * console.log(app.isFoo); + * //=> true + * console.log(app.isBar); + * //=> true + * console.log(app._name); + * //=> 'bar' + * ``` + * @name .is + * @param {String} `name` + * @return {Boolean} + * @api public + */ + + Base.prototype.is = function(name) { + if (typeof name !== 'string') { + throw new TypeError('expected name to be a string'); + } + this.define('is' + pascal(name), true); + this.define('_name', name); + this.define('_appname', name); + return this; + }; + + /** + * Returns true if a plugin has already been registered on an instance. + * + * Plugin implementors are encouraged to use this first thing in a plugin + * to prevent the plugin from being called more than once on the same + * instance. + * + * ```js + * var base = new Base(); + * base.use(function(app) { + * if (app.isRegistered('myPlugin')) return; + * // do stuff to `app` + * }); + * + * // to also record the plugin as being registered + * base.use(function(app) { + * if (app.isRegistered('myPlugin', true)) return; + * // do stuff to `app` + * }); + * ``` + * @name .isRegistered + * @emits `plugin` Emits the name of the plugin being registered. Useful for unit tests, to ensure plugins are only registered once. + * @param {String} `name` The plugin name. + * @param {Boolean} `register` If the plugin if not already registered, to record it as being registered pass `true` as the second argument. + * @return {Boolean} Returns true if a plugin is already registered. + * @api public + */ + + Base.prototype.isRegistered = function(name, register) { + if (this.registered.hasOwnProperty(name)) { + return true; + } + if (register !== false) { + this.registered[name] = true; + this.emit('plugin', name); + } + return false; + }; + + /** + * Define a plugin function to be called immediately upon init. Plugins are chainable + * and expose the following arguments to the plugin function: + * + * - `app`: the current instance of `Base` + * - `base`: the [first ancestor instance](#base) of `Base` + * + * ```js + * var app = new Base() + * .use(foo) + * .use(bar) + * .use(baz) + * ``` + * @name .use + * @param {Function} `fn` plugin function to call + * @return {Object} Returns the item instance for chaining. + * @api public + */ + + Base.prototype.use = function(fn) { + fn.call(this, this); + return this; + }; + + /** + * The `.define` method is used for adding non-enumerable property on the instance. + * Dot-notation is **not supported** with `define`. + * + * ```js + * // arbitrary `render` function using lodash `template` + * app.define('render', function(str, locals) { + * return _.template(str)(locals); + * }); + * ``` + * @name .define + * @param {String} `key` The name of the property to define. + * @param {any} `value` + * @return {Object} Returns the instance for chaining. + * @api public + */ + + Base.prototype.define = function(key, val) { + if (isObject(key)) { + return this.visit('define', key); + } + define(this, key, val); + return this; + }; + + /** + * Mix property `key` onto the Base prototype. If base is inherited using + * `Base.extend` this method will be overridden by a new `mixin` method that will + * only add properties to the prototype of the inheriting application. + * + * ```js + * app.mixin('foo', function() { + * // do stuff + * }); + * ``` + * @name .mixin + * @param {String} `key` + * @param {Object|Array} `val` + * @return {Object} Returns the `base` instance for chaining. + * @api public + */ + + Base.prototype.mixin = function(key, val) { + Base.prototype[key] = val; + return this; + }; + + /** + * Non-enumberable mixin array, used by the static [Base.mixin]() method. + */ + + Base.prototype.mixins = Base.prototype.mixins || []; + + /** + * Getter/setter used when creating nested instances of `Base`, for storing a reference + * to the first ancestor instance. This works by setting an instance of `Base` on the `parent` + * property of a "child" instance. The `base` property defaults to the current instance if + * no `parent` property is defined. + * + * ```js + * // create an instance of `Base`, this is our first ("base") instance + * var first = new Base(); + * first.foo = 'bar'; // arbitrary property, to make it easier to see what's happening later + * + * // create another instance + * var second = new Base(); + * // create a reference to the first instance (`first`) + * second.parent = first; + * + * // create another instance + * var third = new Base(); + * // create a reference to the previous instance (`second`) + * // repeat this pattern every time a "child" instance is created + * third.parent = second; + * + * // we can always access the first instance using the `base` property + * console.log(first.base.foo); + * //=> 'bar' + * console.log(second.base.foo); + * //=> 'bar' + * console.log(third.base.foo); + * //=> 'bar' + * // and now you know how to get to third base ;) + * ``` + * @name .base + * @api public + */ + + Object.defineProperty(Base.prototype, 'base', { + configurable: true, + get: function() { + return this.parent ? this.parent.base : this; + } + }); + + /** + * Static method for adding global plugin functions that will + * be added to an instance when created. + * + * ```js + * Base.use(function(app) { + * app.foo = 'bar'; + * }); + * var app = new Base(); + * console.log(app.foo); + * //=> 'bar' + * ``` + * @name #use + * @param {Function} `fn` Plugin function to use on each instance. + * @return {Object} Returns the `Base` constructor for chaining + * @api public + */ + + define(Base, 'use', function(fn) { + fns.push(fn); + return Base; + }); + + /** + * Run an array of functions by passing each function + * to a method on the given object specified by the given property. + * + * @param {Object} `obj` Object containing method to use. + * @param {String} `prop` Name of the method on the object to use. + * @param {Array} `arr` Array of functions to pass to the method. + */ + + define(Base, 'run', function(obj, prop, arr) { + var len = arr.length, i = 0; + while (len--) { + obj[prop](arr[i++]); + } + return Base; + }); + + /** + * Static method for inheriting the prototype and static methods of the `Base` class. + * This method greatly simplifies the process of creating inheritance-based applications. + * See [static-extend][] for more details. + * + * ```js + * var extend = cu.extend(Parent); + * Parent.extend(Child); + * + * // optional methods + * Parent.extend(Child, { + * foo: function() {}, + * bar: function() {} + * }); + * ``` + * @name #extend + * @param {Function} `Ctor` constructor to extend + * @param {Object} `methods` Optional prototype properties to mix in. + * @return {Object} Returns the `Base` constructor for chaining + * @api public + */ + + define(Base, 'extend', cu.extend(Base, function(Ctor, Parent) { + Ctor.prototype.mixins = Ctor.prototype.mixins || []; + + define(Ctor, 'mixin', function(fn) { + var mixin = fn(Ctor.prototype, Ctor); + if (typeof mixin === 'function') { + Ctor.prototype.mixins.push(mixin); + } + return Ctor; + }); + + define(Ctor, 'mixins', function(Child) { + Base.run(Child, 'mixin', Ctor.prototype.mixins); + return Ctor; + }); + + Ctor.prototype.mixin = function(key, value) { + Ctor.prototype[key] = value; + return this; + }; + return Base; + })); + + /** + * Used for adding methods to the `Base` prototype, and/or to the prototype of child instances. + * When a mixin function returns a function, the returned function is pushed onto the `.mixins` + * array, making it available to be used on inheriting classes whenever `Base.mixins()` is + * called (e.g. `Base.mixins(Child)`). + * + * ```js + * Base.mixin(function(proto) { + * proto.foo = function(msg) { + * return 'foo ' + msg; + * }; + * }); + * ``` + * @name #mixin + * @param {Function} `fn` Function to call + * @return {Object} Returns the `Base` constructor for chaining + * @api public + */ + + define(Base, 'mixin', function(fn) { + var mixin = fn(Base.prototype, Base); + if (typeof mixin === 'function') { + Base.prototype.mixins.push(mixin); + } + return Base; + }); + + /** + * Static method for running global mixin functions against a child constructor. + * Mixins must be registered before calling this method. + * + * ```js + * Base.extend(Child); + * Base.mixins(Child); + * ``` + * @name #mixins + * @param {Function} `Child` Constructor function of a child class + * @return {Object} Returns the `Base` constructor for chaining + * @api public + */ + + define(Base, 'mixins', function(Child) { + Base.run(Child, 'mixin', Base.prototype.mixins); + return Base; + }); + + /** + * Similar to `util.inherit`, but copies all static properties, prototype properties, and + * getters/setters from `Provider` to `Receiver`. See [class-utils][]{#inherit} for more details. + * + * ```js + * Base.inherit(Foo, Bar); + * ``` + * @name #inherit + * @param {Function} `Receiver` Receiving (child) constructor + * @param {Function} `Provider` Providing (parent) constructor + * @return {Object} Returns the `Base` constructor for chaining + * @api public + */ + + define(Base, 'inherit', cu.inherit); + define(Base, 'bubble', cu.bubble); + return Base; +} + +/** + * Expose `Base` with default settings + */ + +module.exports = namespace(); + +/** + * Allow users to define a namespace + */ + +module.exports.namespace = namespace; diff --git a/node_modules/base/node_modules/define-property/LICENSE b/node_modules/base/node_modules/define-property/LICENSE new file mode 100644 index 0000000000..ec85897eb1 --- /dev/null +++ b/node_modules/base/node_modules/define-property/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2015, 2017, Jon Schlinkert + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/base/node_modules/define-property/README.md b/node_modules/base/node_modules/define-property/README.md new file mode 100644 index 0000000000..2f1af05f3c --- /dev/null +++ b/node_modules/base/node_modules/define-property/README.md @@ -0,0 +1,95 @@ +# define-property [![NPM version](https://img.shields.io/npm/v/define-property.svg?style=flat)](https://www.npmjs.com/package/define-property) [![NPM monthly downloads](https://img.shields.io/npm/dm/define-property.svg?style=flat)](https://npmjs.org/package/define-property) [![NPM total downloads](https://img.shields.io/npm/dt/define-property.svg?style=flat)](https://npmjs.org/package/define-property) [![Linux Build Status](https://img.shields.io/travis/jonschlinkert/define-property.svg?style=flat&label=Travis)](https://travis-ci.org/jonschlinkert/define-property) + +> Define a non-enumerable property on an object. + +## Install + +Install with [npm](https://www.npmjs.com/): + +```sh +$ npm install --save define-property +``` + +Install with [yarn](https://yarnpkg.com): + +```sh +$ yarn add define-property +``` + +## Usage + +**Params** + +* `obj`: The object on which to define the property. +* `prop`: The name of the property to be defined or modified. +* `descriptor`: The descriptor for the property being defined or modified. + +```js +var define = require('define-property'); +var obj = {}; +define(obj, 'foo', function(val) { + return val.toUpperCase(); +}); + +console.log(obj); +//=> {} + +console.log(obj.foo('bar')); +//=> 'BAR' +``` + +**get/set** + +```js +define(obj, 'foo', { + get: function() {}, + set: function() {} +}); +``` + +## About + +### Related projects + +* [assign-deep](https://www.npmjs.com/package/assign-deep): Deeply assign the enumerable properties and/or es6 Symbol properies of source objects to the target… [more](https://github.com/jonschlinkert/assign-deep) | [homepage](https://github.com/jonschlinkert/assign-deep "Deeply assign the enumerable properties and/or es6 Symbol properies of source objects to the target (first) object.") +* [extend-shallow](https://www.npmjs.com/package/extend-shallow): Extend an object with the properties of additional objects. node.js/javascript util. | [homepage](https://github.com/jonschlinkert/extend-shallow "Extend an object with the properties of additional objects. node.js/javascript util.") +* [merge-deep](https://www.npmjs.com/package/merge-deep): Recursively merge values in a javascript object. | [homepage](https://github.com/jonschlinkert/merge-deep "Recursively merge values in a javascript object.") +* [mixin-deep](https://www.npmjs.com/package/mixin-deep): Deeply mix the properties of objects into the first object. Like merge-deep, but doesn't clone. | [homepage](https://github.com/jonschlinkert/mixin-deep "Deeply mix the properties of objects into the first object. Like merge-deep, but doesn't clone.") + +### Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new). + +### Building docs + +_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_ + +To generate the readme, run the following command: + +```sh +$ npm install -g verbose/verb#dev verb-generate-readme && verb +``` + +### Running tests + +Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command: + +```sh +$ npm install && npm test +``` + +### Author + +**Jon Schlinkert** + +* [github/jonschlinkert](https://github.com/jonschlinkert) +* [twitter/jonschlinkert](https://twitter.com/jonschlinkert) + +### License + +Copyright © 2017, [Jon Schlinkert](https://github.com/jonschlinkert). +Released under the [MIT License](LICENSE). + +*** + +_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.5.0, on April 20, 2017._ \ No newline at end of file diff --git a/node_modules/base/node_modules/define-property/index.js b/node_modules/base/node_modules/define-property/index.js new file mode 100644 index 0000000000..27c19ebf6d --- /dev/null +++ b/node_modules/base/node_modules/define-property/index.js @@ -0,0 +1,31 @@ +/*! + * define-property + * + * Copyright (c) 2015, 2017, Jon Schlinkert. + * Released under the MIT License. + */ + +'use strict'; + +var isDescriptor = require('is-descriptor'); + +module.exports = function defineProperty(obj, prop, val) { + if (typeof obj !== 'object' && typeof obj !== 'function') { + throw new TypeError('expected an object or function.'); + } + + if (typeof prop !== 'string') { + throw new TypeError('expected `prop` to be a string.'); + } + + if (isDescriptor(val) && ('set' in val || 'get' in val)) { + return Object.defineProperty(obj, prop, val); + } + + return Object.defineProperty(obj, prop, { + configurable: true, + enumerable: false, + writable: true, + value: val + }); +}; diff --git a/node_modules/base/node_modules/define-property/package.json b/node_modules/base/node_modules/define-property/package.json new file mode 100644 index 0000000000..52af4305b0 --- /dev/null +++ b/node_modules/base/node_modules/define-property/package.json @@ -0,0 +1,93 @@ +{ + "_from": "define-property@^1.0.0", + "_id": "define-property@1.0.0", + "_inBundle": false, + "_integrity": "sha1-dp66rz9KY6rTr56NMEybvnm/sOY=", + "_location": "/base/define-property", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "define-property@^1.0.0", + "name": "define-property", + "escapedName": "define-property", + "rawSpec": "^1.0.0", + "saveSpec": null, + "fetchSpec": "^1.0.0" + }, + "_requiredBy": [ + "/base" + ], + "_resolved": "https://registry.npmjs.org/define-property/-/define-property-1.0.0.tgz", + "_shasum": "769ebaaf3f4a63aad3af9e8d304c9bbe79bfb0e6", + "_spec": "define-property@^1.0.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/base", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/jonschlinkert/define-property/issues" + }, + "bundleDependencies": false, + "dependencies": { + "is-descriptor": "^1.0.0" + }, + "deprecated": false, + "description": "Define a non-enumerable property on an object.", + "devDependencies": { + "gulp-format-md": "^0.1.12", + "mocha": "^3.2.0" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/jonschlinkert/define-property", + "keywords": [ + "define", + "define-property", + "enumerable", + "key", + "non", + "non-enumerable", + "object", + "prop", + "property", + "value" + ], + "license": "MIT", + "main": "index.js", + "name": "define-property", + "repository": { + "type": "git", + "url": "git+https://github.com/jonschlinkert/define-property.git" + }, + "scripts": { + "test": "mocha" + }, + "verb": { + "related": { + "list": [ + "extend-shallow", + "merge-deep", + "assign-deep", + "mixin-deep" + ] + }, + "toc": false, + "layout": "default", + "tasks": [ + "readme" + ], + "plugins": [ + "gulp-format-md" + ], + "lint": { + "reflinks": true + } + }, + "version": "1.0.0" +} diff --git a/node_modules/base/node_modules/is-accessor-descriptor/LICENSE b/node_modules/base/node_modules/is-accessor-descriptor/LICENSE new file mode 100644 index 0000000000..e33d14b754 --- /dev/null +++ b/node_modules/base/node_modules/is-accessor-descriptor/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2015-2017, Jon Schlinkert. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/base/node_modules/is-accessor-descriptor/README.md b/node_modules/base/node_modules/is-accessor-descriptor/README.md new file mode 100644 index 0000000000..d198e1f05e --- /dev/null +++ b/node_modules/base/node_modules/is-accessor-descriptor/README.md @@ -0,0 +1,144 @@ +# is-accessor-descriptor [![NPM version](https://img.shields.io/npm/v/is-accessor-descriptor.svg?style=flat)](https://www.npmjs.com/package/is-accessor-descriptor) [![NPM monthly downloads](https://img.shields.io/npm/dm/is-accessor-descriptor.svg?style=flat)](https://npmjs.org/package/is-accessor-descriptor) [![NPM total downloads](https://img.shields.io/npm/dt/is-accessor-descriptor.svg?style=flat)](https://npmjs.org/package/is-accessor-descriptor) [![Linux Build Status](https://img.shields.io/travis/jonschlinkert/is-accessor-descriptor.svg?style=flat&label=Travis)](https://travis-ci.org/jonschlinkert/is-accessor-descriptor) + +> Returns true if a value has the characteristics of a valid JavaScript accessor descriptor. + +Please consider following this project's author, [Jon Schlinkert](https://github.com/jonschlinkert), and consider starring the project to show your :heart: and support. + +## Install + +Install with [npm](https://www.npmjs.com/): + +```sh +$ npm install --save is-accessor-descriptor +``` + +## Usage + +```js +var isAccessor = require('is-accessor-descriptor'); + +isAccessor({get: function() {}}); +//=> true +``` + +You may also pass an object and property name to check if the property is an accessor: + +```js +isAccessor(foo, 'bar'); +``` + +## Examples + +`false` when not an object + +```js +isAccessor('a') +isAccessor(null) +isAccessor([]) +//=> false +``` + +`true` when the object has valid properties + +and the properties all have the correct JavaScript types: + +```js +isAccessor({get: noop, set: noop}) +isAccessor({get: noop}) +isAccessor({set: noop}) +//=> true +``` + +`false` when the object has invalid properties + +```js +isAccessor({get: noop, set: noop, bar: 'baz'}) +isAccessor({get: noop, writable: true}) +isAccessor({get: noop, value: true}) +//=> false +``` + +`false` when an accessor is not a function + +```js +isAccessor({get: noop, set: 'baz'}) +isAccessor({get: 'foo', set: noop}) +isAccessor({get: 'foo', bar: 'baz'}) +isAccessor({get: 'foo', set: 'baz'}) +//=> false +``` + +`false` when a value is not the correct type + +```js +isAccessor({get: noop, set: noop, enumerable: 'foo'}) +isAccessor({set: noop, configurable: 'foo'}) +isAccessor({get: noop, configurable: 'foo'}) +//=> false +``` + +## About + +
+Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new). + +
+ +
+Running Tests + +Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command: + +```sh +$ npm install && npm test +``` + +
+ +
+Building docs + +_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_ + +To generate the readme, run the following command: + +```sh +$ npm install -g verbose/verb#dev verb-generate-readme && verb +``` + +
+ +### Related projects + +You might also be interested in these projects: + +* [is-accessor-descriptor](https://www.npmjs.com/package/is-accessor-descriptor): Returns true if a value has the characteristics of a valid JavaScript accessor descriptor. | [homepage](https://github.com/jonschlinkert/is-accessor-descriptor "Returns true if a value has the characteristics of a valid JavaScript accessor descriptor.") +* [is-data-descriptor](https://www.npmjs.com/package/is-data-descriptor): Returns true if a value has the characteristics of a valid JavaScript data descriptor. | [homepage](https://github.com/jonschlinkert/is-data-descriptor "Returns true if a value has the characteristics of a valid JavaScript data descriptor.") +* [is-descriptor](https://www.npmjs.com/package/is-descriptor): Returns true if a value has the characteristics of a valid JavaScript descriptor. Works for… [more](https://github.com/jonschlinkert/is-descriptor) | [homepage](https://github.com/jonschlinkert/is-descriptor "Returns true if a value has the characteristics of a valid JavaScript descriptor. Works for data descriptors and accessor descriptors.") +* [is-plain-object](https://www.npmjs.com/package/is-plain-object): Returns true if an object was created by the `Object` constructor. | [homepage](https://github.com/jonschlinkert/is-plain-object "Returns true if an object was created by the `Object` constructor.") +* [isobject](https://www.npmjs.com/package/isobject): Returns true if the value is an object and not an array or null. | [homepage](https://github.com/jonschlinkert/isobject "Returns true if the value is an object and not an array or null.") + +### Contributors + +| **Commits** | **Contributor** | +| --- | --- | +| 22 | [jonschlinkert](https://github.com/jonschlinkert) | +| 2 | [realityking](https://github.com/realityking) | + +### Author + +**Jon Schlinkert** + +* [github/jonschlinkert](https://github.com/jonschlinkert) +* [twitter/jonschlinkert](https://twitter.com/jonschlinkert) + +### License + +Copyright © 2017, [Jon Schlinkert](https://github.com/jonschlinkert). +Released under the [MIT License](LICENSE). + +*** + +_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.6.0, on November 01, 2017._ \ No newline at end of file diff --git a/node_modules/base/node_modules/is-accessor-descriptor/index.js b/node_modules/base/node_modules/is-accessor-descriptor/index.js new file mode 100644 index 0000000000..d2e6fe8b9e --- /dev/null +++ b/node_modules/base/node_modules/is-accessor-descriptor/index.js @@ -0,0 +1,69 @@ +/*! + * is-accessor-descriptor + * + * Copyright (c) 2015-2017, Jon Schlinkert. + * Released under the MIT License. + */ + +'use strict'; + +var typeOf = require('kind-of'); + +// accessor descriptor properties +var accessor = { + get: 'function', + set: 'function', + configurable: 'boolean', + enumerable: 'boolean' +}; + +function isAccessorDescriptor(obj, prop) { + if (typeof prop === 'string') { + var val = Object.getOwnPropertyDescriptor(obj, prop); + return typeof val !== 'undefined'; + } + + if (typeOf(obj) !== 'object') { + return false; + } + + if (has(obj, 'value') || has(obj, 'writable')) { + return false; + } + + if (!has(obj, 'get') || typeof obj.get !== 'function') { + return false; + } + + // tldr: it's valid to have "set" be undefined + // "set" might be undefined if `Object.getOwnPropertyDescriptor` + // was used to get the value, and only `get` was defined by the user + if (has(obj, 'set') && typeof obj[key] !== 'function' && typeof obj[key] !== 'undefined') { + return false; + } + + for (var key in obj) { + if (!accessor.hasOwnProperty(key)) { + continue; + } + + if (typeOf(obj[key]) === accessor[key]) { + continue; + } + + if (typeof obj[key] !== 'undefined') { + return false; + } + } + return true; +} + +function has(obj, key) { + return {}.hasOwnProperty.call(obj, key); +} + +/** + * Expose `isAccessorDescriptor` + */ + +module.exports = isAccessorDescriptor; diff --git a/node_modules/base/node_modules/is-accessor-descriptor/package.json b/node_modules/base/node_modules/is-accessor-descriptor/package.json new file mode 100644 index 0000000000..065071a662 --- /dev/null +++ b/node_modules/base/node_modules/is-accessor-descriptor/package.json @@ -0,0 +1,110 @@ +{ + "_from": "is-accessor-descriptor@^1.0.0", + "_id": "is-accessor-descriptor@1.0.0", + "_inBundle": false, + "_integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", + "_location": "/base/is-accessor-descriptor", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "is-accessor-descriptor@^1.0.0", + "name": "is-accessor-descriptor", + "escapedName": "is-accessor-descriptor", + "rawSpec": "^1.0.0", + "saveSpec": null, + "fetchSpec": "^1.0.0" + }, + "_requiredBy": [ + "/base/is-descriptor" + ], + "_resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz", + "_shasum": "169c2f6d3df1f992618072365c9b0ea1f6878656", + "_spec": "is-accessor-descriptor@^1.0.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/base/node_modules/is-descriptor", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/jonschlinkert/is-accessor-descriptor/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "Jon Schlinkert", + "url": "http://twitter.com/jonschlinkert" + }, + { + "name": "Rouven Weßling", + "url": "www.rouvenwessling.de" + } + ], + "dependencies": { + "kind-of": "^6.0.0" + }, + "deprecated": false, + "description": "Returns true if a value has the characteristics of a valid JavaScript accessor descriptor.", + "devDependencies": { + "gulp-format-md": "^1.0.0", + "mocha": "^3.5.3" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/jonschlinkert/is-accessor-descriptor", + "keywords": [ + "accessor", + "check", + "data", + "descriptor", + "get", + "getter", + "is", + "keys", + "object", + "properties", + "property", + "set", + "setter", + "type", + "valid", + "value" + ], + "license": "MIT", + "main": "index.js", + "name": "is-accessor-descriptor", + "repository": { + "type": "git", + "url": "git+https://github.com/jonschlinkert/is-accessor-descriptor.git" + }, + "scripts": { + "test": "mocha" + }, + "verb": { + "toc": false, + "layout": "default", + "tasks": [ + "readme" + ], + "plugins": [ + "gulp-format-md" + ], + "related": { + "list": [ + "is-accessor-descriptor", + "is-data-descriptor", + "is-descriptor", + "is-plain-object", + "isobject" + ] + }, + "lint": { + "reflinks": true + } + }, + "version": "1.0.0" +} diff --git a/node_modules/base/node_modules/is-data-descriptor/LICENSE b/node_modules/base/node_modules/is-data-descriptor/LICENSE new file mode 100644 index 0000000000..e33d14b754 --- /dev/null +++ b/node_modules/base/node_modules/is-data-descriptor/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2015-2017, Jon Schlinkert. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/base/node_modules/is-data-descriptor/README.md b/node_modules/base/node_modules/is-data-descriptor/README.md new file mode 100644 index 0000000000..42b0714465 --- /dev/null +++ b/node_modules/base/node_modules/is-data-descriptor/README.md @@ -0,0 +1,161 @@ +# is-data-descriptor [![NPM version](https://img.shields.io/npm/v/is-data-descriptor.svg?style=flat)](https://www.npmjs.com/package/is-data-descriptor) [![NPM monthly downloads](https://img.shields.io/npm/dm/is-data-descriptor.svg?style=flat)](https://npmjs.org/package/is-data-descriptor) [![NPM total downloads](https://img.shields.io/npm/dt/is-data-descriptor.svg?style=flat)](https://npmjs.org/package/is-data-descriptor) [![Linux Build Status](https://img.shields.io/travis/jonschlinkert/is-data-descriptor.svg?style=flat&label=Travis)](https://travis-ci.org/jonschlinkert/is-data-descriptor) + +> Returns true if a value has the characteristics of a valid JavaScript data descriptor. + +Please consider following this project's author, [Jon Schlinkert](https://github.com/jonschlinkert), and consider starring the project to show your :heart: and support. + +## Install + +Install with [npm](https://www.npmjs.com/): + +```sh +$ npm install --save is-data-descriptor +``` + +## Usage + +```js +var isDataDesc = require('is-data-descriptor'); +``` + +## Examples + +`true` when the descriptor has valid properties with valid values. + +```js +// `value` can be anything +isDataDesc({value: 'foo'}) +isDataDesc({value: function() {}}) +isDataDesc({value: true}) +//=> true +``` + +`false` when not an object + +```js +isDataDesc('a') +//=> false +isDataDesc(null) +//=> false +isDataDesc([]) +//=> false +``` + +`false` when the object has invalid properties + +```js +isDataDesc({value: 'foo', bar: 'baz'}) +//=> false +isDataDesc({value: 'foo', bar: 'baz'}) +//=> false +isDataDesc({value: 'foo', get: function(){}}) +//=> false +isDataDesc({get: function(){}, value: 'foo'}) +//=> false +``` + +`false` when a value is not the correct type + +```js +isDataDesc({value: 'foo', enumerable: 'foo'}) +//=> false +isDataDesc({value: 'foo', configurable: 'foo'}) +//=> false +isDataDesc({value: 'foo', writable: 'foo'}) +//=> false +``` + +## Valid properties + +The only valid data descriptor properties are the following: + +* `configurable` (required) +* `enumerable` (required) +* `value` (optional) +* `writable` (optional) + +To be a valid data descriptor, either `value` or `writable` must be defined. + +**Invalid properties** + +A descriptor may have additional _invalid_ properties (an error will **not** be thrown). + +```js +var foo = {}; + +Object.defineProperty(foo, 'bar', { + enumerable: true, + whatever: 'blah', // invalid, but doesn't cause an error + get: function() { + return 'baz'; + } +}); + +console.log(foo.bar); +//=> 'baz' +``` + +## About + +
+Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new). + +
+ +
+Running Tests + +Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command: + +```sh +$ npm install && npm test +``` + +
+ +
+Building docs + +_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_ + +To generate the readme, run the following command: + +```sh +$ npm install -g verbose/verb#dev verb-generate-readme && verb +``` + +
+ +### Related projects + +You might also be interested in these projects: + +* [is-accessor-descriptor](https://www.npmjs.com/package/is-accessor-descriptor): Returns true if a value has the characteristics of a valid JavaScript accessor descriptor. | [homepage](https://github.com/jonschlinkert/is-accessor-descriptor "Returns true if a value has the characteristics of a valid JavaScript accessor descriptor.") +* [is-data-descriptor](https://www.npmjs.com/package/is-data-descriptor): Returns true if a value has the characteristics of a valid JavaScript data descriptor. | [homepage](https://github.com/jonschlinkert/is-data-descriptor "Returns true if a value has the characteristics of a valid JavaScript data descriptor.") +* [is-descriptor](https://www.npmjs.com/package/is-descriptor): Returns true if a value has the characteristics of a valid JavaScript descriptor. Works for… [more](https://github.com/jonschlinkert/is-descriptor) | [homepage](https://github.com/jonschlinkert/is-descriptor "Returns true if a value has the characteristics of a valid JavaScript descriptor. Works for data descriptors and accessor descriptors.") +* [isobject](https://www.npmjs.com/package/isobject): Returns true if the value is an object and not an array or null. | [homepage](https://github.com/jonschlinkert/isobject "Returns true if the value is an object and not an array or null.") + +### Contributors + +| **Commits** | **Contributor** | +| --- | --- | +| 21 | [jonschlinkert](https://github.com/jonschlinkert) | +| 2 | [realityking](https://github.com/realityking) | + +### Author + +**Jon Schlinkert** + +* [github/jonschlinkert](https://github.com/jonschlinkert) +* [twitter/jonschlinkert](https://twitter.com/jonschlinkert) + +### License + +Copyright © 2017, [Jon Schlinkert](https://github.com/jonschlinkert). +Released under the [MIT License](LICENSE). + +*** + +_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.6.0, on November 01, 2017._ \ No newline at end of file diff --git a/node_modules/base/node_modules/is-data-descriptor/index.js b/node_modules/base/node_modules/is-data-descriptor/index.js new file mode 100644 index 0000000000..cfeae36190 --- /dev/null +++ b/node_modules/base/node_modules/is-data-descriptor/index.js @@ -0,0 +1,49 @@ +/*! + * is-data-descriptor + * + * Copyright (c) 2015-2017, Jon Schlinkert. + * Released under the MIT License. + */ + +'use strict'; + +var typeOf = require('kind-of'); + +module.exports = function isDataDescriptor(obj, prop) { + // data descriptor properties + var data = { + configurable: 'boolean', + enumerable: 'boolean', + writable: 'boolean' + }; + + if (typeOf(obj) !== 'object') { + return false; + } + + if (typeof prop === 'string') { + var val = Object.getOwnPropertyDescriptor(obj, prop); + return typeof val !== 'undefined'; + } + + if (!('value' in obj) && !('writable' in obj)) { + return false; + } + + for (var key in obj) { + if (key === 'value') continue; + + if (!data.hasOwnProperty(key)) { + continue; + } + + if (typeOf(obj[key]) === data[key]) { + continue; + } + + if (typeof obj[key] !== 'undefined') { + return false; + } + } + return true; +}; diff --git a/node_modules/base/node_modules/is-data-descriptor/package.json b/node_modules/base/node_modules/is-data-descriptor/package.json new file mode 100644 index 0000000000..2a1f962c28 --- /dev/null +++ b/node_modules/base/node_modules/is-data-descriptor/package.json @@ -0,0 +1,109 @@ +{ + "_from": "is-data-descriptor@^1.0.0", + "_id": "is-data-descriptor@1.0.0", + "_inBundle": false, + "_integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", + "_location": "/base/is-data-descriptor", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "is-data-descriptor@^1.0.0", + "name": "is-data-descriptor", + "escapedName": "is-data-descriptor", + "rawSpec": "^1.0.0", + "saveSpec": null, + "fetchSpec": "^1.0.0" + }, + "_requiredBy": [ + "/base/is-descriptor" + ], + "_resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", + "_shasum": "d84876321d0e7add03990406abbbbd36ba9268c7", + "_spec": "is-data-descriptor@^1.0.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/base/node_modules/is-descriptor", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/jonschlinkert/is-data-descriptor/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "Jon Schlinkert", + "url": "http://twitter.com/jonschlinkert" + }, + { + "name": "Rouven Weßling", + "url": "www.rouvenwessling.de" + } + ], + "dependencies": { + "kind-of": "^6.0.0" + }, + "deprecated": false, + "description": "Returns true if a value has the characteristics of a valid JavaScript data descriptor.", + "devDependencies": { + "gulp-format-md": "^1.0.0", + "mocha": "^3.5.3" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/jonschlinkert/is-data-descriptor", + "keywords": [ + "accessor", + "check", + "data", + "descriptor", + "get", + "getter", + "is", + "keys", + "object", + "properties", + "property", + "set", + "setter", + "type", + "valid", + "value" + ], + "license": "MIT", + "main": "index.js", + "name": "is-data-descriptor", + "repository": { + "type": "git", + "url": "git+https://github.com/jonschlinkert/is-data-descriptor.git" + }, + "scripts": { + "test": "mocha" + }, + "verb": { + "toc": false, + "layout": "default", + "tasks": [ + "readme" + ], + "plugins": [ + "gulp-format-md" + ], + "related": { + "list": [ + "is-accessor-descriptor", + "is-data-descriptor", + "is-descriptor", + "isobject" + ] + }, + "lint": { + "reflinks": true + } + }, + "version": "1.0.0" +} diff --git a/node_modules/base/node_modules/is-descriptor/LICENSE b/node_modules/base/node_modules/is-descriptor/LICENSE new file mode 100644 index 0000000000..c0d7f13627 --- /dev/null +++ b/node_modules/base/node_modules/is-descriptor/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2015-2017, Jon Schlinkert. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. \ No newline at end of file diff --git a/node_modules/base/node_modules/is-descriptor/README.md b/node_modules/base/node_modules/is-descriptor/README.md new file mode 100644 index 0000000000..658e53301b --- /dev/null +++ b/node_modules/base/node_modules/is-descriptor/README.md @@ -0,0 +1,193 @@ +# is-descriptor [![NPM version](https://img.shields.io/npm/v/is-descriptor.svg?style=flat)](https://www.npmjs.com/package/is-descriptor) [![NPM monthly downloads](https://img.shields.io/npm/dm/is-descriptor.svg?style=flat)](https://npmjs.org/package/is-descriptor) [![NPM total downloads](https://img.shields.io/npm/dt/is-descriptor.svg?style=flat)](https://npmjs.org/package/is-descriptor) [![Linux Build Status](https://img.shields.io/travis/jonschlinkert/is-descriptor.svg?style=flat&label=Travis)](https://travis-ci.org/jonschlinkert/is-descriptor) + +> Returns true if a value has the characteristics of a valid JavaScript descriptor. Works for data descriptors and accessor descriptors. + +## Install + +Install with [npm](https://www.npmjs.com/): + +```sh +$ npm install --save is-descriptor +``` + +## Usage + +```js +var isDescriptor = require('is-descriptor'); + +isDescriptor({value: 'foo'}) +//=> true +isDescriptor({get: function(){}, set: function(){}}) +//=> true +isDescriptor({get: 'foo', set: function(){}}) +//=> false +``` + +You may also check for a descriptor by passing an object as the first argument and property name (`string`) as the second argument. + +```js +var obj = {}; +obj.foo = 'abc'; + +Object.defineProperty(obj, 'bar', { + value: 'xyz' +}); + +isDescriptor(obj, 'foo'); +//=> true +isDescriptor(obj, 'bar'); +//=> true +``` + +## Examples + +### value type + +`false` when not an object + +```js +isDescriptor('a'); +//=> false +isDescriptor(null); +//=> false +isDescriptor([]); +//=> false +``` + +### data descriptor + +`true` when the object has valid properties with valid values. + +```js +isDescriptor({value: 'foo'}); +//=> true +isDescriptor({value: noop}); +//=> true +``` + +`false` when the object has invalid properties + +```js +isDescriptor({value: 'foo', bar: 'baz'}); +//=> false +isDescriptor({value: 'foo', bar: 'baz'}); +//=> false +isDescriptor({value: 'foo', get: noop}); +//=> false +isDescriptor({get: noop, value: noop}); +//=> false +``` + +`false` when a value is not the correct type + +```js +isDescriptor({value: 'foo', enumerable: 'foo'}); +//=> false +isDescriptor({value: 'foo', configurable: 'foo'}); +//=> false +isDescriptor({value: 'foo', writable: 'foo'}); +//=> false +``` + +### accessor descriptor + +`true` when the object has valid properties with valid values. + +```js +isDescriptor({get: noop, set: noop}); +//=> true +isDescriptor({get: noop}); +//=> true +isDescriptor({set: noop}); +//=> true +``` + +`false` when the object has invalid properties + +```js +isDescriptor({get: noop, set: noop, bar: 'baz'}); +//=> false +isDescriptor({get: noop, writable: true}); +//=> false +isDescriptor({get: noop, value: true}); +//=> false +``` + +`false` when an accessor is not a function + +```js +isDescriptor({get: noop, set: 'baz'}); +//=> false +isDescriptor({get: 'foo', set: noop}); +//=> false +isDescriptor({get: 'foo', bar: 'baz'}); +//=> false +isDescriptor({get: 'foo', set: 'baz'}); +//=> false +``` + +`false` when a value is not the correct type + +```js +isDescriptor({get: noop, set: noop, enumerable: 'foo'}); +//=> false +isDescriptor({set: noop, configurable: 'foo'}); +//=> false +isDescriptor({get: noop, configurable: 'foo'}); +//=> false +``` + +## About + +### Related projects + +* [is-accessor-descriptor](https://www.npmjs.com/package/is-accessor-descriptor): Returns true if a value has the characteristics of a valid JavaScript accessor descriptor. | [homepage](https://github.com/jonschlinkert/is-accessor-descriptor "Returns true if a value has the characteristics of a valid JavaScript accessor descriptor.") +* [is-data-descriptor](https://www.npmjs.com/package/is-data-descriptor): Returns true if a value has the characteristics of a valid JavaScript data descriptor. | [homepage](https://github.com/jonschlinkert/is-data-descriptor "Returns true if a value has the characteristics of a valid JavaScript data descriptor.") +* [is-descriptor](https://www.npmjs.com/package/is-descriptor): Returns true if a value has the characteristics of a valid JavaScript descriptor. Works for… [more](https://github.com/jonschlinkert/is-descriptor) | [homepage](https://github.com/jonschlinkert/is-descriptor "Returns true if a value has the characteristics of a valid JavaScript descriptor. Works for data descriptors and accessor descriptors.") +* [isobject](https://www.npmjs.com/package/isobject): Returns true if the value is an object and not an array or null. | [homepage](https://github.com/jonschlinkert/isobject "Returns true if the value is an object and not an array or null.") + +### Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new). + +### Contributors + +| **Commits** | **Contributor** | +| --- | --- | +| 24 | [jonschlinkert](https://github.com/jonschlinkert) | +| 1 | [doowb](https://github.com/doowb) | +| 1 | [wtgtybhertgeghgtwtg](https://github.com/wtgtybhertgeghgtwtg) | + +### Building docs + +_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_ + +To generate the readme, run the following command: + +```sh +$ npm install -g verbose/verb#dev verb-generate-readme && verb +``` + +### Running tests + +Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command: + +```sh +$ npm install && npm test +``` + +### Author + +**Jon Schlinkert** + +* [github/jonschlinkert](https://github.com/jonschlinkert) +* [twitter/jonschlinkert](https://twitter.com/jonschlinkert) + +### License + +Copyright © 2017, [Jon Schlinkert](https://github.com/jonschlinkert). +Released under the [MIT License](LICENSE). + +*** + +_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.6.0, on July 22, 2017._ \ No newline at end of file diff --git a/node_modules/base/node_modules/is-descriptor/index.js b/node_modules/base/node_modules/is-descriptor/index.js new file mode 100644 index 0000000000..c9b91d7622 --- /dev/null +++ b/node_modules/base/node_modules/is-descriptor/index.js @@ -0,0 +1,22 @@ +/*! + * is-descriptor + * + * Copyright (c) 2015-2017, Jon Schlinkert. + * Released under the MIT License. + */ + +'use strict'; + +var typeOf = require('kind-of'); +var isAccessor = require('is-accessor-descriptor'); +var isData = require('is-data-descriptor'); + +module.exports = function isDescriptor(obj, key) { + if (typeOf(obj) !== 'object') { + return false; + } + if ('get' in obj) { + return isAccessor(obj, key); + } + return isData(obj, key); +}; diff --git a/node_modules/base/node_modules/is-descriptor/package.json b/node_modules/base/node_modules/is-descriptor/package.json new file mode 100644 index 0000000000..aada16d9da --- /dev/null +++ b/node_modules/base/node_modules/is-descriptor/package.json @@ -0,0 +1,114 @@ +{ + "_from": "is-descriptor@^1.0.0", + "_id": "is-descriptor@1.0.2", + "_inBundle": false, + "_integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", + "_location": "/base/is-descriptor", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "is-descriptor@^1.0.0", + "name": "is-descriptor", + "escapedName": "is-descriptor", + "rawSpec": "^1.0.0", + "saveSpec": null, + "fetchSpec": "^1.0.0" + }, + "_requiredBy": [ + "/base/define-property" + ], + "_resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-1.0.2.tgz", + "_shasum": "3b159746a66604b04f8c81524ba365c5f14d86ec", + "_spec": "is-descriptor@^1.0.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/base/node_modules/define-property", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/jonschlinkert/is-descriptor/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "Brian Woodward", + "url": "https://twitter.com/doowb" + }, + { + "name": "Jon Schlinkert", + "url": "http://twitter.com/jonschlinkert" + }, + { + "url": "https://github.com/wtgtybhertgeghgtwtg" + } + ], + "dependencies": { + "is-accessor-descriptor": "^1.0.0", + "is-data-descriptor": "^1.0.0", + "kind-of": "^6.0.2" + }, + "deprecated": false, + "description": "Returns true if a value has the characteristics of a valid JavaScript descriptor. Works for data descriptors and accessor descriptors.", + "devDependencies": { + "gulp-format-md": "^1.0.0", + "mocha": "^3.5.3" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/jonschlinkert/is-descriptor", + "keywords": [ + "accessor", + "check", + "data", + "descriptor", + "get", + "getter", + "is", + "keys", + "object", + "properties", + "property", + "set", + "setter", + "type", + "valid", + "value" + ], + "license": "MIT", + "main": "index.js", + "name": "is-descriptor", + "repository": { + "type": "git", + "url": "git+https://github.com/jonschlinkert/is-descriptor.git" + }, + "scripts": { + "test": "mocha" + }, + "verb": { + "related": { + "list": [ + "is-accessor-descriptor", + "is-data-descriptor", + "is-descriptor", + "isobject" + ] + }, + "plugins": [ + "gulp-format-md" + ], + "toc": false, + "layout": "default", + "tasks": [ + "readme" + ], + "lint": { + "reflinks": true + } + }, + "version": "1.0.2" +} diff --git a/node_modules/base/package.json b/node_modules/base/package.json new file mode 100644 index 0000000000..9c929afcaa --- /dev/null +++ b/node_modules/base/package.json @@ -0,0 +1,164 @@ +{ + "_from": "base@^0.11.1", + "_id": "base@0.11.2", + "_inBundle": false, + "_integrity": "sha512-5T6P4xPgpp0YDFvSWwEZ4NoE3aM4QBQXDzmVbraCkFj8zHM+mba8SyqB5DbZWyR7mYHo6Y7BdQo3MoA4m0TeQg==", + "_location": "/base", + "_phantomChildren": { + "kind-of": "6.0.2" + }, + "_requested": { + "type": "range", + "registry": true, + "raw": "base@^0.11.1", + "name": "base", + "escapedName": "base", + "rawSpec": "^0.11.1", + "saveSpec": null, + "fetchSpec": "^0.11.1" + }, + "_requiredBy": [ + "/snapdragon" + ], + "_resolved": "https://registry.npmjs.org/base/-/base-0.11.2.tgz", + "_shasum": "7bde5ced145b6d551a90db87f83c558b4eb48a8f", + "_spec": "base@^0.11.1", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/snapdragon", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/node-base/base/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "Brian Woodward", + "url": "https://twitter.com/doowb" + }, + { + "name": "John O'Donnell", + "url": "https://github.com/criticalmash" + }, + { + "name": "Jon Schlinkert", + "url": "http://twitter.com/jonschlinkert" + }, + { + "name": "tunnckoCore", + "url": "https://i.am.charlike.online" + }, + { + "url": "https://github.com/wtgtybhertgeghgtwtg" + } + ], + "dependencies": { + "cache-base": "^1.0.1", + "class-utils": "^0.3.5", + "component-emitter": "^1.2.1", + "define-property": "^1.0.0", + "isobject": "^3.0.1", + "mixin-deep": "^1.2.0", + "pascalcase": "^0.1.1" + }, + "deprecated": false, + "description": "base is the foundation for creating modular, unit testable and highly pluggable node.js applications, starting with a handful of common methods, like `set`, `get`, `del` and `use`.", + "devDependencies": { + "gulp": "^3.9.1", + "gulp-eslint": "^4.0.0", + "gulp-format-md": "^1.0.0", + "gulp-istanbul": "^1.1.2", + "gulp-mocha": "^3.0.1", + "helper-coverage": "^0.1.3", + "mocha": "^3.5.0", + "should": "^13.0.1", + "through2": "^2.0.3", + "verb-generate-readme": "^0.6.0" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/node-base/base", + "keywords": [ + "base", + "boilerplate", + "cache", + "del", + "get", + "inherit", + "methods", + "set", + "starter", + "unset", + "visit" + ], + "license": "MIT", + "main": "index.js", + "maintainers": [ + { + "name": "Brian Woodward", + "url": "https://github.com/doowb" + }, + { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + } + ], + "name": "base", + "repository": { + "type": "git", + "url": "git+https://github.com/node-base/base.git" + }, + "scripts": { + "test": "mocha" + }, + "verb": { + "run": true, + "toc": false, + "layout": "default", + "tasks": [ + "readme" + ], + "plugins": [ + "gulp-format-md" + ], + "helpers": [ + "helper-coverage" + ], + "related": { + "description": "There are a number of different plugins available for extending base. Let us know if you create your own!", + "hightlight": "generate", + "list": [ + "base-cwd", + "base-data", + "base-fs", + "base-generators", + "base-option", + "base-pipeline", + "base-pkg", + "base-plugins", + "base-questions", + "base-store", + "base-task" + ] + }, + "reflinks": [ + "assemble", + "boilerplate", + "cache-base", + "class-utils", + "generate", + "scaffold", + "static-extend", + "verb" + ], + "lint": { + "reflinks": true + } + }, + "version": "0.11.2" +} diff --git a/node_modules/base64-arraybuffer/.npmignore b/node_modules/base64-arraybuffer/.npmignore new file mode 100644 index 0000000000..332ee5ada3 --- /dev/null +++ b/node_modules/base64-arraybuffer/.npmignore @@ -0,0 +1,3 @@ +/node_modules/ +Gruntfile.js +/test/ diff --git a/node_modules/base64-arraybuffer/.travis.yml b/node_modules/base64-arraybuffer/.travis.yml new file mode 100644 index 0000000000..19259a549f --- /dev/null +++ b/node_modules/base64-arraybuffer/.travis.yml @@ -0,0 +1,19 @@ +language: node_js +node_js: +- '0.12' +- iojs-1 +- iojs-2 +- iojs-3 +- '4.1' +before_script: +- npm install +before_install: npm install -g npm@'>=2.13.5' +deploy: + provider: npm + email: niklasvh@gmail.com + api_key: + secure: oHV9ArprTj5WOk7MP1UF7QMJ70huXw+y7xXb5wF4+V2H8Hyfa5TfE0DiOmqrube1WXTeH1FLgq54shp/sJWi47Hkg/GyeoB5NnsPhYEaJkaON9UG5blML+ODiNVsEnq/1kNBQ8e0+0JItMPLGySKyFmuZ3yflulXKS8O88mfINo= + on: + tags: true + branch: master + repo: niklasvh/base64-arraybuffer diff --git a/node_modules/base64-arraybuffer/LICENSE-MIT b/node_modules/base64-arraybuffer/LICENSE-MIT new file mode 100644 index 0000000000..ed27b41b25 --- /dev/null +++ b/node_modules/base64-arraybuffer/LICENSE-MIT @@ -0,0 +1,22 @@ +Copyright (c) 2012 Niklas von Hertzen + +Permission is hereby granted, free of charge, to any person +obtaining a copy of this software and associated documentation +files (the "Software"), to deal in the Software without +restriction, including without limitation the rights to use, +copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the +Software is furnished to do so, subject to the following +conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES +OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT +HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +OTHER DEALINGS IN THE SOFTWARE. diff --git a/node_modules/base64-arraybuffer/README.md b/node_modules/base64-arraybuffer/README.md new file mode 100644 index 0000000000..50009e44f6 --- /dev/null +++ b/node_modules/base64-arraybuffer/README.md @@ -0,0 +1,20 @@ +# base64-arraybuffer + +[![Build Status](https://travis-ci.org/niklasvh/base64-arraybuffer.png)](https://travis-ci.org/niklasvh/base64-arraybuffer) +[![NPM Downloads](https://img.shields.io/npm/dm/base64-arraybuffer.svg)](https://www.npmjs.org/package/base64-arraybuffer) +[![NPM Version](https://img.shields.io/npm/v/base64-arraybuffer.svg)](https://www.npmjs.org/package/base64-arraybuffer) + +Encode/decode base64 data into ArrayBuffers + +## Getting Started +Install the module with: `npm install base64-arraybuffer` + +## API +The library encodes and decodes base64 to and from ArrayBuffers + + - __encode(buffer)__ - Encodes `ArrayBuffer` into base64 string + - __decode(str)__ - Decodes base64 string to `ArrayBuffer` + +## License +Copyright (c) 2012 Niklas von Hertzen +Licensed under the MIT license. diff --git a/node_modules/base64-arraybuffer/lib/base64-arraybuffer.js b/node_modules/base64-arraybuffer/lib/base64-arraybuffer.js new file mode 100644 index 0000000000..e6b630637b --- /dev/null +++ b/node_modules/base64-arraybuffer/lib/base64-arraybuffer.js @@ -0,0 +1,67 @@ +/* + * base64-arraybuffer + * https://github.com/niklasvh/base64-arraybuffer + * + * Copyright (c) 2012 Niklas von Hertzen + * Licensed under the MIT license. + */ +(function(){ + "use strict"; + + var chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"; + + // Use a lookup table to find the index. + var lookup = new Uint8Array(256); + for (var i = 0; i < chars.length; i++) { + lookup[chars.charCodeAt(i)] = i; + } + + exports.encode = function(arraybuffer) { + var bytes = new Uint8Array(arraybuffer), + i, len = bytes.length, base64 = ""; + + for (i = 0; i < len; i+=3) { + base64 += chars[bytes[i] >> 2]; + base64 += chars[((bytes[i] & 3) << 4) | (bytes[i + 1] >> 4)]; + base64 += chars[((bytes[i + 1] & 15) << 2) | (bytes[i + 2] >> 6)]; + base64 += chars[bytes[i + 2] & 63]; + } + + if ((len % 3) === 2) { + base64 = base64.substring(0, base64.length - 1) + "="; + } else if (len % 3 === 1) { + base64 = base64.substring(0, base64.length - 2) + "=="; + } + + return base64; + }; + + exports.decode = function(base64) { + var bufferLength = base64.length * 0.75, + len = base64.length, i, p = 0, + encoded1, encoded2, encoded3, encoded4; + + if (base64[base64.length - 1] === "=") { + bufferLength--; + if (base64[base64.length - 2] === "=") { + bufferLength--; + } + } + + var arraybuffer = new ArrayBuffer(bufferLength), + bytes = new Uint8Array(arraybuffer); + + for (i = 0; i < len; i+=4) { + encoded1 = lookup[base64.charCodeAt(i)]; + encoded2 = lookup[base64.charCodeAt(i+1)]; + encoded3 = lookup[base64.charCodeAt(i+2)]; + encoded4 = lookup[base64.charCodeAt(i+3)]; + + bytes[p++] = (encoded1 << 2) | (encoded2 >> 4); + bytes[p++] = ((encoded2 & 15) << 4) | (encoded3 >> 2); + bytes[p++] = ((encoded3 & 3) << 6) | (encoded4 & 63); + } + + return arraybuffer; + }; +})(); diff --git a/node_modules/base64-arraybuffer/package.json b/node_modules/base64-arraybuffer/package.json new file mode 100644 index 0000000000..cb362ef4d8 --- /dev/null +++ b/node_modules/base64-arraybuffer/package.json @@ -0,0 +1,66 @@ +{ + "_from": "base64-arraybuffer@0.1.5", + "_id": "base64-arraybuffer@0.1.5", + "_inBundle": false, + "_integrity": "sha1-c5JncZI7Whl0etZmqlzUv5xunOg=", + "_location": "/base64-arraybuffer", + "_phantomChildren": {}, + "_requested": { + "type": "version", + "registry": true, + "raw": "base64-arraybuffer@0.1.5", + "name": "base64-arraybuffer", + "escapedName": "base64-arraybuffer", + "rawSpec": "0.1.5", + "saveSpec": null, + "fetchSpec": "0.1.5" + }, + "_requiredBy": [ + "/engine.io-parser", + "/socket.io-client", + "/socket.io/socket.io-client" + ], + "_resolved": "https://registry.npmjs.org/base64-arraybuffer/-/base64-arraybuffer-0.1.5.tgz", + "_shasum": "73926771923b5a19747ad666aa5cd4bf9c6e9ce8", + "_spec": "base64-arraybuffer@0.1.5", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/socket.io-client", + "author": { + "name": "Niklas von Hertzen", + "email": "niklasvh@gmail.com", + "url": "http://hertzen.com" + }, + "bugs": { + "url": "https://github.com/niklasvh/base64-arraybuffer/issues" + }, + "bundleDependencies": false, + "deprecated": false, + "description": "Encode/decode base64 data into ArrayBuffers", + "devDependencies": { + "grunt": "^0.4.5", + "grunt-cli": "^0.1.13", + "grunt-contrib-jshint": "^0.11.2", + "grunt-contrib-nodeunit": "^0.4.1", + "grunt-contrib-watch": "^0.6.1" + }, + "engines": { + "node": ">= 0.6.0" + }, + "homepage": "https://github.com/niklasvh/base64-arraybuffer", + "keywords": [], + "licenses": [ + { + "type": "MIT", + "url": "https://github.com/niklasvh/base64-arraybuffer/blob/master/LICENSE-MIT" + } + ], + "main": "lib/base64-arraybuffer", + "name": "base64-arraybuffer", + "repository": { + "type": "git", + "url": "git+https://github.com/niklasvh/base64-arraybuffer.git" + }, + "scripts": { + "test": "grunt nodeunit" + }, + "version": "0.1.5" +} diff --git a/node_modules/base64id/.npmignore b/node_modules/base64id/.npmignore new file mode 100644 index 0000000000..39e9864f5a --- /dev/null +++ b/node_modules/base64id/.npmignore @@ -0,0 +1,3 @@ +support +test +examples diff --git a/node_modules/base64id/LICENSE b/node_modules/base64id/LICENSE new file mode 100644 index 0000000000..0d03c830fd --- /dev/null +++ b/node_modules/base64id/LICENSE @@ -0,0 +1,22 @@ +(The MIT License) + +Copyright (c) 2012-2016 Kristian Faeldt + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +'Software'), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY +CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, +TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE +SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/node_modules/base64id/README.md b/node_modules/base64id/README.md new file mode 100644 index 0000000000..17689e6f8c --- /dev/null +++ b/node_modules/base64id/README.md @@ -0,0 +1,18 @@ +base64id +======== + +Node.js module that generates a base64 id. + +Uses crypto.randomBytes when available, falls back to unsafe methods for node.js <= 0.4. + +To increase performance, random bytes are buffered to minimize the number of synchronous calls to crypto.randomBytes. + +## Installation + + $ npm install base64id + +## Usage + + var base64id = require('base64id'); + + var id = base64id.generateId(); diff --git a/node_modules/base64id/lib/base64id.js b/node_modules/base64id/lib/base64id.js new file mode 100644 index 0000000000..f68815979f --- /dev/null +++ b/node_modules/base64id/lib/base64id.js @@ -0,0 +1,103 @@ +/*! + * base64id v0.1.0 + */ + +/** + * Module dependencies + */ + +var crypto = require('crypto'); + +/** + * Constructor + */ + +var Base64Id = function() { }; + +/** + * Get random bytes + * + * Uses a buffer if available, falls back to crypto.randomBytes + */ + +Base64Id.prototype.getRandomBytes = function(bytes) { + + var BUFFER_SIZE = 4096 + var self = this; + + bytes = bytes || 12; + + if (bytes > BUFFER_SIZE) { + return crypto.randomBytes(bytes); + } + + var bytesInBuffer = parseInt(BUFFER_SIZE/bytes); + var threshold = parseInt(bytesInBuffer*0.85); + + if (!threshold) { + return crypto.randomBytes(bytes); + } + + if (this.bytesBufferIndex == null) { + this.bytesBufferIndex = -1; + } + + if (this.bytesBufferIndex == bytesInBuffer) { + this.bytesBuffer = null; + this.bytesBufferIndex = -1; + } + + // No buffered bytes available or index above threshold + if (this.bytesBufferIndex == -1 || this.bytesBufferIndex > threshold) { + + if (!this.isGeneratingBytes) { + this.isGeneratingBytes = true; + crypto.randomBytes(BUFFER_SIZE, function(err, bytes) { + self.bytesBuffer = bytes; + self.bytesBufferIndex = 0; + self.isGeneratingBytes = false; + }); + } + + // Fall back to sync call when no buffered bytes are available + if (this.bytesBufferIndex == -1) { + return crypto.randomBytes(bytes); + } + } + + var result = this.bytesBuffer.slice(bytes*this.bytesBufferIndex, bytes*(this.bytesBufferIndex+1)); + this.bytesBufferIndex++; + + return result; +} + +/** + * Generates a base64 id + * + * (Original version from socket.io ) + */ + +Base64Id.prototype.generateId = function () { + var rand = new Buffer(15); // multiple of 3 for base64 + if (!rand.writeInt32BE) { + return Math.abs(Math.random() * Math.random() * Date.now() | 0).toString() + + Math.abs(Math.random() * Math.random() * Date.now() | 0).toString(); + } + this.sequenceNumber = (this.sequenceNumber + 1) | 0; + rand.writeInt32BE(this.sequenceNumber, 11); + if (crypto.randomBytes) { + this.getRandomBytes(12).copy(rand); + } else { + // not secure for node 0.4 + [0, 4, 8].forEach(function(i) { + rand.writeInt32BE(Math.random() * Math.pow(2, 32) | 0, i); + }); + } + return rand.toString('base64').replace(/\//g, '_').replace(/\+/g, '-'); +}; + +/** + * Export + */ + +exports = module.exports = new Base64Id(); diff --git a/node_modules/base64id/package.json b/node_modules/base64id/package.json new file mode 100644 index 0000000000..7e204652a4 --- /dev/null +++ b/node_modules/base64id/package.json @@ -0,0 +1,47 @@ +{ + "_from": "base64id@1.0.0", + "_id": "base64id@1.0.0", + "_inBundle": false, + "_integrity": "sha1-R2iMuZu2gE8OBtPnY7HDLlfY5rY=", + "_location": "/base64id", + "_phantomChildren": {}, + "_requested": { + "type": "version", + "registry": true, + "raw": "base64id@1.0.0", + "name": "base64id", + "escapedName": "base64id", + "rawSpec": "1.0.0", + "saveSpec": null, + "fetchSpec": "1.0.0" + }, + "_requiredBy": [ + "/engine.io" + ], + "_resolved": "https://registry.npmjs.org/base64id/-/base64id-1.0.0.tgz", + "_shasum": "47688cb99bb6804f0e06d3e763b1c32e57d8e6b6", + "_spec": "base64id@1.0.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/engine.io", + "author": { + "name": "Kristian Faeldt", + "email": "faeldt_kristian@cyberagent.co.jp" + }, + "bugs": { + "url": "https://github.com/faeldt/base64id/issues" + }, + "bundleDependencies": false, + "deprecated": false, + "description": "Generates a base64 id", + "engines": { + "node": ">= 0.4.0" + }, + "homepage": "https://github.com/faeldt/base64id#readme", + "license": "MIT", + "main": "./lib/base64id.js", + "name": "base64id", + "repository": { + "type": "git", + "url": "git+https://github.com/faeldt/base64id.git" + }, + "version": "1.0.0" +} diff --git a/node_modules/batch/.npmignore b/node_modules/batch/.npmignore new file mode 100644 index 0000000000..f1250e584c --- /dev/null +++ b/node_modules/batch/.npmignore @@ -0,0 +1,4 @@ +support +test +examples +*.sock diff --git a/node_modules/batch/History.md b/node_modules/batch/History.md new file mode 100644 index 0000000000..f7e9b76f8b --- /dev/null +++ b/node_modules/batch/History.md @@ -0,0 +1,93 @@ +0.6.1 / 2017-05-16 +================== + + * fix `process.nextTick` detection in Node.js + +0.6.0 / 2017-03-25 +================== + + * always invoke end callback asynchronously + * fix compatibility with component v1 + * fix license field + +0.5.3 / 2015-10-01 +================== + + * fix for browserify + +0.5.2 / 2014-12-22 +================== + + * add brower field + * add license to package.json + +0.5.1 / 2014-06-19 +================== + + * add repository field to readme (exciting) + +0.5.0 / 2013-07-29 +================== + + * add `.throws(true)` to opt-in to responding with an array of error objects + * make `new` optional + +0.4.0 / 2013-06-05 +================== + + * add catching of immediate callback errors + +0.3.2 / 2013-03-15 +================== + + * remove Emitter call in constructor + +0.3.1 / 2013-03-13 +================== + + * add Emitter() mixin for client. Closes #8 + +0.3.0 / 2013-03-13 +================== + + * add component.json + * add result example + * add .concurrency support + * add concurrency example + * add parallel example + +0.2.1 / 2012-11-08 +================== + + * add .start, .end, and .duration properties + * change dependencies to devDependencies + +0.2.0 / 2012-10-04 +================== + + * add progress events. Closes #5 (__BREAKING CHANGE__) + +0.1.1 / 2012-07-03 +================== + + * change "complete" event to "progress" + +0.1.0 / 2012-07-03 +================== + + * add Emitter inheritance and emit "complete" [burcu] + +0.0.3 / 2012-06-02 +================== + + * Callback results should be in the order of the queued functions. + +0.0.2 / 2012-02-12 +================== + + * any node + +0.0.1 / 2010-01-03 +================== + + * Initial release diff --git a/node_modules/batch/LICENSE b/node_modules/batch/LICENSE new file mode 100644 index 0000000000..b7409302c4 --- /dev/null +++ b/node_modules/batch/LICENSE @@ -0,0 +1,22 @@ +(The MIT License) + +Copyright (c) 2013 TJ Holowaychuk + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +'Software'), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY +CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, +TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE +SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/node_modules/batch/Makefile b/node_modules/batch/Makefile new file mode 100644 index 0000000000..634e372192 --- /dev/null +++ b/node_modules/batch/Makefile @@ -0,0 +1,6 @@ + +test: + @./node_modules/.bin/mocha \ + --require should + +.PHONY: test \ No newline at end of file diff --git a/node_modules/batch/Readme.md b/node_modules/batch/Readme.md new file mode 100644 index 0000000000..c2b4d3d0c4 --- /dev/null +++ b/node_modules/batch/Readme.md @@ -0,0 +1,53 @@ + +# batch + + Simple async batch with concurrency control and progress reporting. + +## Installation + +``` +$ npm install batch +``` + +## API + +```js +var Batch = require('batch') + , batch = new Batch; + +batch.concurrency(4); + +ids.forEach(function(id){ + batch.push(function(done){ + User.get(id, done); + }); +}); + +batch.on('progress', function(e){ + +}); + +batch.end(function(err, users){ + +}); +``` + +### Progress events + + Contain the "job" index, response value, duration information, and completion data. + +``` +{ index: 1, + value: 'bar', + pending: 2, + total: 3, + complete: 2, + percent: 66, + start: Thu Oct 04 2012 12:25:53 GMT-0700 (PDT), + end: Thu Oct 04 2012 12:25:53 GMT-0700 (PDT), + duration: 0 } +``` + +## License + +[MIT](LICENSE) diff --git a/node_modules/batch/component.json b/node_modules/batch/component.json new file mode 100644 index 0000000000..2715596c84 --- /dev/null +++ b/node_modules/batch/component.json @@ -0,0 +1,14 @@ +{ + "name": "batch", + "repo": "visionmedia/batch", + "description": "Async task batching", + "version": "0.6.1", + "keywords": ["batch", "async", "utility", "concurrency", "concurrent"], + "dependencies": { + "component/emitter": "*" + }, + "development": {}, + "scripts": [ + "index.js" + ] +} diff --git a/node_modules/batch/index.js b/node_modules/batch/index.js new file mode 100644 index 0000000000..5b402550d1 --- /dev/null +++ b/node_modules/batch/index.js @@ -0,0 +1,173 @@ +/** + * Module dependencies. + */ + +try { + var EventEmitter = require('events').EventEmitter; + if (!EventEmitter) throw new Error(); +} catch (err) { + var Emitter = require('emitter'); +} + +/** + * Defer. + */ + +var defer = typeof process !== 'undefined' && process && typeof process.nextTick === 'function' + ? process.nextTick + : function(fn){ setTimeout(fn); }; + +/** + * Noop. + */ + +function noop(){} + +/** + * Expose `Batch`. + */ + +module.exports = Batch; + +/** + * Create a new Batch. + */ + +function Batch() { + if (!(this instanceof Batch)) return new Batch; + this.fns = []; + this.concurrency(Infinity); + this.throws(true); + for (var i = 0, len = arguments.length; i < len; ++i) { + this.push(arguments[i]); + } +} + +/** + * Inherit from `EventEmitter.prototype`. + */ + +if (EventEmitter) { + Batch.prototype.__proto__ = EventEmitter.prototype; +} else { + Emitter(Batch.prototype); +} + +/** + * Set concurrency to `n`. + * + * @param {Number} n + * @return {Batch} + * @api public + */ + +Batch.prototype.concurrency = function(n){ + this.n = n; + return this; +}; + +/** + * Queue a function. + * + * @param {Function} fn + * @return {Batch} + * @api public + */ + +Batch.prototype.push = function(fn){ + this.fns.push(fn); + return this; +}; + +/** + * Set wether Batch will or will not throw up. + * + * @param {Boolean} throws + * @return {Batch} + * @api public + */ +Batch.prototype.throws = function(throws) { + this.e = !!throws; + return this; +}; + +/** + * Execute all queued functions in parallel, + * executing `cb(err, results)`. + * + * @param {Function} cb + * @return {Batch} + * @api public + */ + +Batch.prototype.end = function(cb){ + var self = this + , total = this.fns.length + , pending = total + , results = [] + , errors = [] + , cb = cb || noop + , fns = this.fns + , max = this.n + , throws = this.e + , index = 0 + , done; + + // empty + if (!fns.length) return defer(function(){ + cb(null, results); + }); + + // process + function next() { + var i = index++; + var fn = fns[i]; + if (!fn) return; + var start = new Date; + + try { + fn(callback); + } catch (err) { + callback(err); + } + + function callback(err, res){ + if (done) return; + if (err && throws) return done = true, defer(function(){ + cb(err); + }); + var complete = total - pending + 1; + var end = new Date; + + results[i] = res; + errors[i] = err; + + self.emit('progress', { + index: i, + value: res, + error: err, + pending: pending, + total: total, + complete: complete, + percent: complete / total * 100 | 0, + start: start, + end: end, + duration: end - start + }); + + if (--pending) next(); + else defer(function(){ + if(!throws) cb(errors, results); + else cb(null, results); + }); + } + } + + // concurrency + for (var i = 0; i < fns.length; i++) { + if (i == max) break; + next(); + } + + return this; +}; diff --git a/node_modules/batch/package.json b/node_modules/batch/package.json new file mode 100644 index 0000000000..f731f20330 --- /dev/null +++ b/node_modules/batch/package.json @@ -0,0 +1,51 @@ +{ + "_from": "batch@0.6.1", + "_id": "batch@0.6.1", + "_inBundle": false, + "_integrity": "sha1-3DQxT05nkxgJP8dgJyUl+UvyXBY=", + "_location": "/batch", + "_phantomChildren": {}, + "_requested": { + "type": "version", + "registry": true, + "raw": "batch@0.6.1", + "name": "batch", + "escapedName": "batch", + "rawSpec": "0.6.1", + "saveSpec": null, + "fetchSpec": "0.6.1" + }, + "_requiredBy": [ + "/serve-index" + ], + "_resolved": "https://registry.npmjs.org/batch/-/batch-0.6.1.tgz", + "_shasum": "dc34314f4e679318093fc760272525f94bf25c16", + "_spec": "batch@0.6.1", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/serve-index", + "author": { + "name": "TJ Holowaychuk", + "email": "tj@vision-media.ca" + }, + "browser": { + "emitter": "events" + }, + "bugs": { + "url": "https://github.com/visionmedia/batch/issues" + }, + "bundleDependencies": false, + "deprecated": false, + "description": "Simple async batch with concurrency control and progress reporting.", + "devDependencies": { + "mocha": "*", + "should": "*" + }, + "homepage": "https://github.com/visionmedia/batch#readme", + "license": "MIT", + "main": "index", + "name": "batch", + "repository": { + "type": "git", + "url": "git+https://github.com/visionmedia/batch.git" + }, + "version": "0.6.1" +} diff --git a/node_modules/better-assert/.npmignore b/node_modules/better-assert/.npmignore new file mode 100644 index 0000000000..f1250e584c --- /dev/null +++ b/node_modules/better-assert/.npmignore @@ -0,0 +1,4 @@ +support +test +examples +*.sock diff --git a/node_modules/better-assert/History.md b/node_modules/better-assert/History.md new file mode 100644 index 0000000000..cbb579bead --- /dev/null +++ b/node_modules/better-assert/History.md @@ -0,0 +1,15 @@ + +1.0.0 / 2013-02-03 +================== + + * Stop using the removed magic __stack global getter + +0.1.0 / 2012-10-04 +================== + + * add throwing of AssertionError for test frameworks etc + +0.0.1 / 2010-01-03 +================== + + * Initial release diff --git a/node_modules/better-assert/Makefile b/node_modules/better-assert/Makefile new file mode 100644 index 0000000000..36a3ed7d0a --- /dev/null +++ b/node_modules/better-assert/Makefile @@ -0,0 +1,5 @@ + +test: + @echo "populate me" + +.PHONY: test \ No newline at end of file diff --git a/node_modules/better-assert/Readme.md b/node_modules/better-assert/Readme.md new file mode 100644 index 0000000000..d8d3a63b6c --- /dev/null +++ b/node_modules/better-assert/Readme.md @@ -0,0 +1,61 @@ + +# better-assert + + Better c-style assertions using [callsite](https://github.com/visionmedia/callsite) for + self-documenting failure messages. + +## Installation + + $ npm install better-assert + +## Example + + By default assertions are enabled, however the __NO_ASSERT__ environment variable + will deactivate them when truthy. + +```js +var assert = require('better-assert'); + +test(); + +function test() { + var user = { name: 'tobi' }; + assert('tobi' == user.name); + assert('number' == typeof user.age); +} + +AssertionError: 'number' == typeof user.age + at test (/Users/tj/projects/better-assert/example.js:9:3) + at Object. (/Users/tj/projects/better-assert/example.js:4:1) + at Module._compile (module.js:449:26) + at Object.Module._extensions..js (module.js:467:10) + at Module.load (module.js:356:32) + at Function.Module._load (module.js:312:12) + at Module.runMain (module.js:492:10) + at process.startup.processNextTick.process._tickCallback (node.js:244:9) +``` + +## License + +(The MIT License) + +Copyright (c) 2012 TJ Holowaychuk <tj@vision-media.ca> + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +'Software'), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY +CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, +TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE +SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. \ No newline at end of file diff --git a/node_modules/better-assert/example.js b/node_modules/better-assert/example.js new file mode 100644 index 0000000000..688c29e8ac --- /dev/null +++ b/node_modules/better-assert/example.js @@ -0,0 +1,10 @@ + +var assert = require('./'); + +test(); + +function test() { + var user = { name: 'tobi' }; + assert('tobi' == user.name); + assert('number' == typeof user.age); +} \ No newline at end of file diff --git a/node_modules/better-assert/index.js b/node_modules/better-assert/index.js new file mode 100644 index 0000000000..fd1c9b7d17 --- /dev/null +++ b/node_modules/better-assert/index.js @@ -0,0 +1,38 @@ +/** + * Module dependencies. + */ + +var AssertionError = require('assert').AssertionError + , callsite = require('callsite') + , fs = require('fs') + +/** + * Expose `assert`. + */ + +module.exports = process.env.NO_ASSERT + ? function(){} + : assert; + +/** + * Assert the given `expr`. + */ + +function assert(expr) { + if (expr) return; + + var stack = callsite(); + var call = stack[1]; + var file = call.getFileName(); + var lineno = call.getLineNumber(); + var src = fs.readFileSync(file, 'utf8'); + var line = src.split('\n')[lineno-1]; + var src = line.match(/assert\((.*)\)/)[1]; + + var err = new AssertionError({ + message: src, + stackStartFunction: stack[0].getFunction() + }); + + throw err; +} diff --git a/node_modules/better-assert/package.json b/node_modules/better-assert/package.json new file mode 100644 index 0000000000..7f697b2199 --- /dev/null +++ b/node_modules/better-assert/package.json @@ -0,0 +1,65 @@ +{ + "_from": "better-assert@~1.0.0", + "_id": "better-assert@1.0.2", + "_inBundle": false, + "_integrity": "sha1-QIZrnhueC1W0gYlDEeaPr/rrxSI=", + "_location": "/better-assert", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "better-assert@~1.0.0", + "name": "better-assert", + "escapedName": "better-assert", + "rawSpec": "~1.0.0", + "saveSpec": null, + "fetchSpec": "~1.0.0" + }, + "_requiredBy": [ + "/parseqs", + "/parseuri" + ], + "_resolved": "https://registry.npmjs.org/better-assert/-/better-assert-1.0.2.tgz", + "_shasum": "40866b9e1b9e0b55b481894311e68faffaebc522", + "_spec": "better-assert@~1.0.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/parseqs", + "author": { + "name": "TJ Holowaychuk", + "email": "tj@vision-media.ca" + }, + "bugs": { + "url": "https://github.com/visionmedia/better-assert/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "TonyHe", + "email": "coolhzb@163.com" + }, + { + "name": "ForbesLindesay" + } + ], + "dependencies": { + "callsite": "1.0.0" + }, + "deprecated": false, + "description": "Better assertions for node, reporting the expr, filename, lineno etc", + "engines": { + "node": "*" + }, + "homepage": "https://github.com/visionmedia/better-assert#readme", + "keywords": [ + "assert", + "stack", + "trace", + "debug" + ], + "main": "index", + "name": "better-assert", + "repository": { + "type": "git", + "url": "git+https://github.com/visionmedia/better-assert.git" + }, + "version": "1.0.2" +} diff --git a/node_modules/binary-extensions/binary-extensions.json b/node_modules/binary-extensions/binary-extensions.json new file mode 100644 index 0000000000..725e53207c --- /dev/null +++ b/node_modules/binary-extensions/binary-extensions.json @@ -0,0 +1,252 @@ +[ + "3dm", + "3ds", + "3g2", + "3gp", + "7z", + "a", + "aac", + "adp", + "ai", + "aif", + "aiff", + "alz", + "ape", + "apk", + "ar", + "arj", + "asf", + "au", + "avi", + "bak", + "baml", + "bh", + "bin", + "bk", + "bmp", + "btif", + "bz2", + "bzip2", + "cab", + "caf", + "cgm", + "class", + "cmx", + "cpio", + "cr2", + "cur", + "dat", + "dcm", + "deb", + "dex", + "djvu", + "dll", + "dmg", + "dng", + "doc", + "docm", + "docx", + "dot", + "dotm", + "dra", + "DS_Store", + "dsk", + "dts", + "dtshd", + "dvb", + "dwg", + "dxf", + "ecelp4800", + "ecelp7470", + "ecelp9600", + "egg", + "eol", + "eot", + "epub", + "exe", + "f4v", + "fbs", + "fh", + "fla", + "flac", + "fli", + "flv", + "fpx", + "fst", + "fvt", + "g3", + "gh", + "gif", + "graffle", + "gz", + "gzip", + "h261", + "h263", + "h264", + "icns", + "ico", + "ief", + "img", + "ipa", + "iso", + "jar", + "jpeg", + "jpg", + "jpgv", + "jpm", + "jxr", + "key", + "ktx", + "lha", + "lib", + "lvp", + "lz", + "lzh", + "lzma", + "lzo", + "m3u", + "m4a", + "m4v", + "mar", + "mdi", + "mht", + "mid", + "midi", + "mj2", + "mka", + "mkv", + "mmr", + "mng", + "mobi", + "mov", + "movie", + "mp3", + "mp4", + "mp4a", + "mpeg", + "mpg", + "mpga", + "mxu", + "nef", + "npx", + "numbers", + "nupkg", + "o", + "oga", + "ogg", + "ogv", + "otf", + "pages", + "pbm", + "pcx", + "pdb", + "pdf", + "pea", + "pgm", + "pic", + "png", + "pnm", + "pot", + "potm", + "potx", + "ppa", + "ppam", + "ppm", + "pps", + "ppsm", + "ppsx", + "ppt", + "pptm", + "pptx", + "psd", + "pya", + "pyc", + "pyo", + "pyv", + "qt", + "rar", + "ras", + "raw", + "resources", + "rgb", + "rip", + "rlc", + "rmf", + "rmvb", + "rtf", + "rz", + "s3m", + "s7z", + "scpt", + "sgi", + "shar", + "sil", + "sketch", + "slk", + "smv", + "snk", + "so", + "stl", + "suo", + "sub", + "swf", + "tar", + "tbz", + "tbz2", + "tga", + "tgz", + "thmx", + "tif", + "tiff", + "tlz", + "ttc", + "ttf", + "txz", + "udf", + "uvh", + "uvi", + "uvm", + "uvp", + "uvs", + "uvu", + "viv", + "vob", + "war", + "wav", + "wax", + "wbmp", + "wdp", + "weba", + "webm", + "webp", + "whl", + "wim", + "wm", + "wma", + "wmv", + "wmx", + "woff", + "woff2", + "wrm", + "wvx", + "xbm", + "xif", + "xla", + "xlam", + "xls", + "xlsb", + "xlsm", + "xlsx", + "xlt", + "xltm", + "xltx", + "xm", + "xmind", + "xpi", + "xpm", + "xwd", + "xz", + "z", + "zip", + "zipx" +] diff --git a/node_modules/binary-extensions/license b/node_modules/binary-extensions/license new file mode 100644 index 0000000000..e7af2f7710 --- /dev/null +++ b/node_modules/binary-extensions/license @@ -0,0 +1,9 @@ +MIT License + +Copyright (c) Sindre Sorhus (sindresorhus.com) + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/node_modules/binary-extensions/package.json b/node_modules/binary-extensions/package.json new file mode 100644 index 0000000000..c77f940384 --- /dev/null +++ b/node_modules/binary-extensions/package.json @@ -0,0 +1,68 @@ +{ + "_from": "binary-extensions@^1.0.0", + "_id": "binary-extensions@1.13.1", + "_inBundle": false, + "_integrity": "sha512-Un7MIEDdUC5gNpcGDV97op1Ywk748MpHcFTHoYs6qnj1Z3j7I53VG3nwZhKzoBZmbdRNnb6WRdFlwl7tSDuZGw==", + "_location": "/binary-extensions", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "binary-extensions@^1.0.0", + "name": "binary-extensions", + "escapedName": "binary-extensions", + "rawSpec": "^1.0.0", + "saveSpec": null, + "fetchSpec": "^1.0.0" + }, + "_requiredBy": [ + "/is-binary-path" + ], + "_resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-1.13.1.tgz", + "_shasum": "598afe54755b2868a5330d2aff9d4ebb53209b65", + "_spec": "binary-extensions@^1.0.0", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/is-binary-path", + "author": { + "name": "Sindre Sorhus", + "email": "sindresorhus@gmail.com", + "url": "sindresorhus.com" + }, + "bugs": { + "url": "https://github.com/sindresorhus/binary-extensions/issues" + }, + "bundleDependencies": false, + "deprecated": false, + "description": "List of binary file extensions", + "devDependencies": { + "ava": "0.16.0" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "binary-extensions.json" + ], + "homepage": "https://github.com/sindresorhus/binary-extensions#readme", + "keywords": [ + "bin", + "binary", + "ext", + "extensions", + "extension", + "file", + "json", + "list", + "array" + ], + "license": "MIT", + "main": "binary-extensions.json", + "name": "binary-extensions", + "repository": { + "type": "git", + "url": "git+https://github.com/sindresorhus/binary-extensions.git" + }, + "scripts": { + "test": "ava" + }, + "version": "1.13.1" +} diff --git a/node_modules/binary-extensions/readme.md b/node_modules/binary-extensions/readme.md new file mode 100644 index 0000000000..4c9eca2476 --- /dev/null +++ b/node_modules/binary-extensions/readme.md @@ -0,0 +1,33 @@ +# binary-extensions [![Build Status](https://travis-ci.org/sindresorhus/binary-extensions.svg?branch=master)](https://travis-ci.org/sindresorhus/binary-extensions) + +> List of binary file extensions + +The list is just a [JSON file](binary-extensions.json) and can be used anywhere. + + +## Install + +``` +$ npm install binary-extensions +``` + + +## Usage + +```js +const binaryExtensions = require('binary-extensions'); + +console.log(binaryExtensions); +//=> ['3ds', '3g2', …] +``` + + +## Related + +- [is-binary-path](https://github.com/sindresorhus/is-binary-path) - Check if a filepath is a binary file +- [text-extensions](https://github.com/sindresorhus/text-extensions) - List of text file extensions + + +## License + +MIT © [Sindre Sorhus](https://sindresorhus.com), Paul Miller (https://paulmillr.com) diff --git a/node_modules/blob/.zuul.yml b/node_modules/blob/.zuul.yml new file mode 100644 index 0000000000..d95890bad3 --- /dev/null +++ b/node_modules/blob/.zuul.yml @@ -0,0 +1,14 @@ +ui: mocha-bdd +browsers: + - name: chrome + version: 8..latest + - name: firefox + version: 7..latest + - name: safari + version: 6..latest + - name: opera + version: 12.1..latest + - name: ie + version: 10..latest + - name: android + version: latest diff --git a/node_modules/blob/LICENSE b/node_modules/blob/LICENSE new file mode 100644 index 0000000000..aa31544b8a --- /dev/null +++ b/node_modules/blob/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (C) 2014 Rase- + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/node_modules/blob/Makefile b/node_modules/blob/Makefile new file mode 100644 index 0000000000..e886c41419 --- /dev/null +++ b/node_modules/blob/Makefile @@ -0,0 +1,14 @@ +REPORTER = dot + +build: blob.js + +blob.js: + @./node_modules/.bin/browserify --standalone blob index.js > blob.js + +test: + @./node_modules/.bin/zuul -- test/index.js + +clean: + rm blob.js + +.PHONY: test blob.js diff --git a/node_modules/blob/README.md b/node_modules/blob/README.md new file mode 100644 index 0000000000..4073ce9525 --- /dev/null +++ b/node_modules/blob/README.md @@ -0,0 +1,21 @@ +# Blob + +A cross-browser `Blob` that falls back to `BlobBuilder` when appropriate. +If neither is available, it exports `undefined`. + +## Installation + +``` bash +$ npm install blob +``` + +## Example + +``` js +var Blob = require('blob'); +var b = new Blob(['hi', 'constructing', 'a', 'blob']); +``` + +## License + +MIT diff --git a/node_modules/blob/component.json b/node_modules/blob/component.json new file mode 100644 index 0000000000..0f3a48126f --- /dev/null +++ b/node_modules/blob/component.json @@ -0,0 +1,11 @@ +{ + "name": "blob", + "repo": "webmodules/blob", + "description": "Abstracts out Blob and uses BlobBulder in cases where it is supported with any vendor prefix.", + "version": "0.0.4", + "license": "MIT", + "dependencies": {}, + "scripts": [ + "index.js" + ] +} diff --git a/node_modules/blob/index.js b/node_modules/blob/index.js new file mode 100644 index 0000000000..ee179d7223 --- /dev/null +++ b/node_modules/blob/index.js @@ -0,0 +1,100 @@ +/** + * Create a blob builder even when vendor prefixes exist + */ + +var BlobBuilder = typeof BlobBuilder !== 'undefined' ? BlobBuilder : + typeof WebKitBlobBuilder !== 'undefined' ? WebKitBlobBuilder : + typeof MSBlobBuilder !== 'undefined' ? MSBlobBuilder : + typeof MozBlobBuilder !== 'undefined' ? MozBlobBuilder : + false; + +/** + * Check if Blob constructor is supported + */ + +var blobSupported = (function() { + try { + var a = new Blob(['hi']); + return a.size === 2; + } catch(e) { + return false; + } +})(); + +/** + * Check if Blob constructor supports ArrayBufferViews + * Fails in Safari 6, so we need to map to ArrayBuffers there. + */ + +var blobSupportsArrayBufferView = blobSupported && (function() { + try { + var b = new Blob([new Uint8Array([1,2])]); + return b.size === 2; + } catch(e) { + return false; + } +})(); + +/** + * Check if BlobBuilder is supported + */ + +var blobBuilderSupported = BlobBuilder + && BlobBuilder.prototype.append + && BlobBuilder.prototype.getBlob; + +/** + * Helper function that maps ArrayBufferViews to ArrayBuffers + * Used by BlobBuilder constructor and old browsers that didn't + * support it in the Blob constructor. + */ + +function mapArrayBufferViews(ary) { + return ary.map(function(chunk) { + if (chunk.buffer instanceof ArrayBuffer) { + var buf = chunk.buffer; + + // if this is a subarray, make a copy so we only + // include the subarray region from the underlying buffer + if (chunk.byteLength !== buf.byteLength) { + var copy = new Uint8Array(chunk.byteLength); + copy.set(new Uint8Array(buf, chunk.byteOffset, chunk.byteLength)); + buf = copy.buffer; + } + + return buf; + } + + return chunk; + }); +} + +function BlobBuilderConstructor(ary, options) { + options = options || {}; + + var bb = new BlobBuilder(); + mapArrayBufferViews(ary).forEach(function(part) { + bb.append(part); + }); + + return (options.type) ? bb.getBlob(options.type) : bb.getBlob(); +}; + +function BlobConstructor(ary, options) { + return new Blob(mapArrayBufferViews(ary), options || {}); +}; + +if (typeof Blob !== 'undefined') { + BlobBuilderConstructor.prototype = Blob.prototype; + BlobConstructor.prototype = Blob.prototype; +} + +module.exports = (function() { + if (blobSupported) { + return blobSupportsArrayBufferView ? Blob : BlobConstructor; + } else if (blobBuilderSupported) { + return BlobBuilderConstructor; + } else { + return undefined; + } +})(); diff --git a/node_modules/blob/package.json b/node_modules/blob/package.json new file mode 100644 index 0000000000..5e63a57805 --- /dev/null +++ b/node_modules/blob/package.json @@ -0,0 +1,49 @@ +{ + "_from": "blob@0.0.5", + "_id": "blob@0.0.5", + "_inBundle": false, + "_integrity": "sha512-gaqbzQPqOoamawKg0LGVd7SzLgXS+JH61oWprSLH+P+abTczqJbhTR8CmJ2u9/bUYNmHTGJx/UEmn6doAvvuig==", + "_location": "/blob", + "_phantomChildren": {}, + "_requested": { + "type": "version", + "registry": true, + "raw": "blob@0.0.5", + "name": "blob", + "escapedName": "blob", + "rawSpec": "0.0.5", + "saveSpec": null, + "fetchSpec": "0.0.5" + }, + "_requiredBy": [ + "/engine.io-parser" + ], + "_resolved": "https://registry.npmjs.org/blob/-/blob-0.0.5.tgz", + "_shasum": "d680eeef25f8cd91ad533f5b01eed48e64caf683", + "_spec": "blob@0.0.5", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/engine.io-parser", + "bugs": { + "url": "https://github.com/webmodules/blob/issues" + }, + "bundleDependencies": false, + "dependencies": {}, + "deprecated": false, + "description": "Abstracts out Blob and uses BlobBulder in cases where it is supported with any vendor prefix.", + "devDependencies": { + "browserify": "4.2.3", + "expect.js": "0.2.0", + "mocha": "1.17.1", + "zuul": "1.10.2" + }, + "homepage": "https://github.com/webmodules/blob", + "license": "MIT", + "name": "blob", + "repository": { + "type": "git", + "url": "git://github.com/webmodules/blob.git" + }, + "scripts": { + "test": "make test" + }, + "version": "0.0.5" +} diff --git a/node_modules/blob/test/index.js b/node_modules/blob/test/index.js new file mode 100644 index 0000000000..fe9105e90c --- /dev/null +++ b/node_modules/blob/test/index.js @@ -0,0 +1,100 @@ +var Blob = require('../'); +var expect = require('expect.js'); + +describe('blob', function() { + if (!Blob) { + it('should not have a blob or a blob builder in the global namespace, or blob should not be a constructor function if the module exports false', function() { + try { + var ab = (new Uint8Array(5)).buffer; + global.Blob([ab]); + expect().fail('Blob shouldn\'t be constructable'); + } catch (e) {} + + var BlobBuilder = global.BlobBuilder + || global.WebKitBlobBuilder + || global.MSBlobBuilder + || global.MozBlobBuilder; + expect(BlobBuilder).to.be(undefined); + }); + } else { + it('should encode a proper sized blob when given a string argument', function() { + var b = new Blob(['hi']); + expect(b.size).to.be(2); + }); + + it('should encode a blob with proper size when given two strings as arguments', function() { + var b = new Blob(['hi', 'hello']); + expect(b.size).to.be(7); + }); + + it('should encode arraybuffers with right content', function(done) { + var ary = new Uint8Array(5); + for (var i = 0; i < 5; i++) ary[i] = i; + var b = new Blob([ary.buffer]); + var fr = new FileReader(); + fr.onload = function() { + var newAry = new Uint8Array(this.result); + for (var i = 0; i < 5; i++) expect(newAry[i]).to.be(i); + done(); + }; + fr.readAsArrayBuffer(b); + }); + + it('should encode typed arrays with right content', function(done) { + var ary = new Uint8Array(5); + for (var i = 0; i < 5; i++) ary[i] = i; + var b = new Blob([ary]); + var fr = new FileReader(); + fr.onload = function() { + var newAry = new Uint8Array(this.result); + for (var i = 0; i < 5; i++) expect(newAry[i]).to.be(i); + done(); + }; + fr.readAsArrayBuffer(b); + }); + + it('should encode sliced typed arrays with right content', function(done) { + var ary = new Uint8Array(5); + for (var i = 0; i < 5; i++) ary[i] = i; + var b = new Blob([ary.subarray(2)]); + var fr = new FileReader(); + fr.onload = function() { + var newAry = new Uint8Array(this.result); + for (var i = 0; i < 3; i++) expect(newAry[i]).to.be(i + 2); + done(); + }; + fr.readAsArrayBuffer(b); + }); + + it('should encode with blobs', function(done) { + var ary = new Uint8Array(5); + for (var i = 0; i < 5; i++) ary[i] = i; + var b = new Blob([new Blob([ary.buffer])]); + var fr = new FileReader(); + fr.onload = function() { + var newAry = new Uint8Array(this.result); + for (var i = 0; i < 5; i++) expect(newAry[i]).to.be(i); + done(); + }; + fr.readAsArrayBuffer(b); + }); + + it('should enode mixed contents to right size', function() { + var ary = new Uint8Array(5); + for (var i = 0; i < 5; i++) ary[i] = i; + var b = new Blob([ary.buffer, 'hello']); + expect(b.size).to.be(10); + }); + + it('should accept mime type', function() { + var b = new Blob(['hi', 'hello'], { type: 'text/html' }); + expect(b.type).to.be('text/html'); + }); + + it('should be an instance of constructor', function() { + var b = new Blob(['hi']); + expect(b).to.be.a(Blob); + expect(b).to.be.a(global.Blob); + }); + } +}); diff --git a/node_modules/braces/LICENSE b/node_modules/braces/LICENSE new file mode 100644 index 0000000000..d32ab4426a --- /dev/null +++ b/node_modules/braces/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2014-2018, Jon Schlinkert. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/braces/README.md b/node_modules/braces/README.md new file mode 100644 index 0000000000..f909bfba1a --- /dev/null +++ b/node_modules/braces/README.md @@ -0,0 +1,640 @@ +# braces [![NPM version](https://img.shields.io/npm/v/braces.svg?style=flat)](https://www.npmjs.com/package/braces) [![NPM monthly downloads](https://img.shields.io/npm/dm/braces.svg?style=flat)](https://npmjs.org/package/braces) [![NPM total downloads](https://img.shields.io/npm/dt/braces.svg?style=flat)](https://npmjs.org/package/braces) [![Linux Build Status](https://img.shields.io/travis/micromatch/braces.svg?style=flat&label=Travis)](https://travis-ci.org/micromatch/braces) [![Windows Build Status](https://img.shields.io/appveyor/ci/micromatch/braces.svg?style=flat&label=AppVeyor)](https://ci.appveyor.com/project/micromatch/braces) + +> Bash-like brace expansion, implemented in JavaScript. Safer than other brace expansion libs, with complete support for the Bash 4.3 braces specification, without sacrificing speed. + +Please consider following this project's author, [Jon Schlinkert](https://github.com/jonschlinkert), and consider starring the project to show your :heart: and support. + +## Install + +Install with [npm](https://www.npmjs.com/): + +```sh +$ npm install --save braces +``` + +## Why use braces? + +Brace patterns are great for matching ranges. Users (and implementors) shouldn't have to think about whether or not they will break their application (or yours) from accidentally defining an aggressive brace pattern. _Braces is the only library that offers a [solution to this problem](#performance)_. + +* **Safe(r)**: Braces isn't vulnerable to DoS attacks like [brace-expansion](https://github.com/juliangruber/brace-expansion), [minimatch](https://github.com/isaacs/minimatch) and [multimatch](https://github.com/sindresorhus/multimatch) (a different bug than the [other regex DoS bug](https://medium.com/node-security/minimatch-redos-vulnerability-590da24e6d3c#.jew0b6mpc)). +* **Accurate**: complete support for the [Bash 4.3 Brace Expansion](www.gnu.org/software/bash/) specification (passes all of the Bash braces tests) +* **[fast and performant](#benchmarks)**: Starts fast, runs fast and [scales well](#performance) as patterns increase in complexity. +* **Organized code base**: with parser and compiler that are eas(y|ier) to maintain and update when edge cases crop up. +* **Well-tested**: thousands of test assertions. Passes 100% of the [minimatch](https://github.com/isaacs/minimatch) and [brace-expansion](https://github.com/juliangruber/brace-expansion) unit tests as well (as of the writing of this). + +## Usage + +The main export is a function that takes one or more brace `patterns` and `options`. + +```js +var braces = require('braces'); +braces(pattern[, options]); +``` + +By default, braces returns an optimized regex-source string. To get an array of brace patterns, use `brace.expand()`. + +The following section explains the difference in more detail. _(If you're curious about "why" braces does this by default, see [brace matching pitfalls](#brace-matching-pitfalls)_. + +### Optimized vs. expanded braces + +**Optimized** + +By default, patterns are optimized for regex and matching: + +```js +console.log(braces('a/{x,y,z}/b')); +//=> ['a/(x|y|z)/b'] +``` + +**Expanded** + +To expand patterns the same way as Bash or [minimatch](https://github.com/isaacs/minimatch), use the [.expand](#expand) method: + +```js +console.log(braces.expand('a/{x,y,z}/b')); +//=> ['a/x/b', 'a/y/b', 'a/z/b'] +``` + +Or use [options.expand](#optionsexpand): + +```js +console.log(braces('a/{x,y,z}/b', {expand: true})); +//=> ['a/x/b', 'a/y/b', 'a/z/b'] +``` + +## Features + +* [lists](#lists): Supports "lists": `a/{b,c}/d` => `['a/b/d', 'a/c/d']` +* [sequences](#sequences): Supports alphabetical or numerical "sequences" (ranges): `{1..3}` => `['1', '2', '3']` +* [steps](#steps): Supports "steps" or increments: `{2..10..2}` => `['2', '4', '6', '8', '10']` +* [escaping](#escaping) +* [options](#options) + +### Lists + +Uses [fill-range](https://github.com/jonschlinkert/fill-range) for expanding alphabetical or numeric lists: + +```js +console.log(braces('a/{foo,bar,baz}/*.js')); +//=> ['a/(foo|bar|baz)/*.js'] + +console.log(braces.expand('a/{foo,bar,baz}/*.js')); +//=> ['a/foo/*.js', 'a/bar/*.js', 'a/baz/*.js'] +``` + +### Sequences + +Uses [fill-range](https://github.com/jonschlinkert/fill-range) for expanding alphabetical or numeric ranges (bash "sequences"): + +```js +console.log(braces.expand('{1..3}')); // ['1', '2', '3'] +console.log(braces.expand('a{01..03}b')); // ['a01b', 'a02b', 'a03b'] +console.log(braces.expand('a{1..3}b')); // ['a1b', 'a2b', 'a3b'] +console.log(braces.expand('{a..c}')); // ['a', 'b', 'c'] +console.log(braces.expand('foo/{a..c}')); // ['foo/a', 'foo/b', 'foo/c'] + +// supports padded ranges +console.log(braces('a{01..03}b')); //=> [ 'a(0[1-3])b' ] +console.log(braces('a{001..300}b')); //=> [ 'a(0{2}[1-9]|0[1-9][0-9]|[12][0-9]{2}|300)b' ] +``` + +### Steps + +Steps, or increments, may be used with ranges: + +```js +console.log(braces.expand('{2..10..2}')); +//=> ['2', '4', '6', '8', '10'] + +console.log(braces('{2..10..2}')); +//=> ['(2|4|6|8|10)'] +``` + +When the [.optimize](#optimize) method is used, or [options.optimize](#optionsoptimize) is set to true, sequences are passed to [to-regex-range](https://github.com/jonschlinkert/to-regex-range) for expansion. + +### Nesting + +Brace patterns may be nested. The results of each expanded string are not sorted, and left to right order is preserved. + +**"Expanded" braces** + +```js +console.log(braces.expand('a{b,c,/{x,y}}/e')); +//=> ['ab/e', 'ac/e', 'a/x/e', 'a/y/e'] + +console.log(braces.expand('a/{x,{1..5},y}/c')); +//=> ['a/x/c', 'a/1/c', 'a/2/c', 'a/3/c', 'a/4/c', 'a/5/c', 'a/y/c'] +``` + +**"Optimized" braces** + +```js +console.log(braces('a{b,c,/{x,y}}/e')); +//=> ['a(b|c|/(x|y))/e'] + +console.log(braces('a/{x,{1..5},y}/c')); +//=> ['a/(x|([1-5])|y)/c'] +``` + +### Escaping + +**Escaping braces** + +A brace pattern will not be expanded or evaluted if _either the opening or closing brace is escaped_: + +```js +console.log(braces.expand('a\\{d,c,b}e')); +//=> ['a{d,c,b}e'] + +console.log(braces.expand('a{d,c,b\\}e')); +//=> ['a{d,c,b}e'] +``` + +**Escaping commas** + +Commas inside braces may also be escaped: + +```js +console.log(braces.expand('a{b\\,c}d')); +//=> ['a{b,c}d'] + +console.log(braces.expand('a{d\\,c,b}e')); +//=> ['ad,ce', 'abe'] +``` + +**Single items** + +Following bash conventions, a brace pattern is also not expanded when it contains a single character: + +```js +console.log(braces.expand('a{b}c')); +//=> ['a{b}c'] +``` + +## Options + +### options.maxLength + +**Type**: `Number` + +**Default**: `65,536` + +**Description**: Limit the length of the input string. Useful when the input string is generated or your application allows users to pass a string, et cetera. + +```js +console.log(braces('a/{b,c}/d', { maxLength: 3 })); //=> throws an error +``` + +### options.expand + +**Type**: `Boolean` + +**Default**: `undefined` + +**Description**: Generate an "expanded" brace pattern (this option is unncessary with the `.expand` method, which does the same thing). + +```js +console.log(braces('a/{b,c}/d', {expand: true})); +//=> [ 'a/b/d', 'a/c/d' ] +``` + +### options.optimize + +**Type**: `Boolean` + +**Default**: `true` + +**Description**: Enabled by default. + +```js +console.log(braces('a/{b,c}/d')); +//=> [ 'a/(b|c)/d' ] +``` + +### options.nodupes + +**Type**: `Boolean` + +**Default**: `true` + +**Description**: Duplicates are removed by default. To keep duplicates, pass `{nodupes: false}` on the options + +### options.rangeLimit + +**Type**: `Number` + +**Default**: `250` + +**Description**: When `braces.expand()` is used, or `options.expand` is true, brace patterns will automatically be [optimized](#optionsoptimize) when the difference between the range minimum and range maximum exceeds the `rangeLimit`. This is to prevent huge ranges from freezing your application. + +You can set this to any number, or change `options.rangeLimit` to `Inifinity` to disable this altogether. + +**Examples** + +```js +// pattern exceeds the "rangeLimit", so it's optimized automatically +console.log(braces.expand('{1..1000}')); +//=> ['([1-9]|[1-9][0-9]{1,2}|1000)'] + +// pattern does not exceed "rangeLimit", so it's NOT optimized +console.log(braces.expand('{1..100}')); +//=> ['1', '2', '3', '4', '5', '6', '7', '8', '9', '10', '11', '12', '13', '14', '15', '16', '17', '18', '19', '20', '21', '22', '23', '24', '25', '26', '27', '28', '29', '30', '31', '32', '33', '34', '35', '36', '37', '38', '39', '40', '41', '42', '43', '44', '45', '46', '47', '48', '49', '50', '51', '52', '53', '54', '55', '56', '57', '58', '59', '60', '61', '62', '63', '64', '65', '66', '67', '68', '69', '70', '71', '72', '73', '74', '75', '76', '77', '78', '79', '80', '81', '82', '83', '84', '85', '86', '87', '88', '89', '90', '91', '92', '93', '94', '95', '96', '97', '98', '99', '100'] +``` + +### options.transform + +**Type**: `Function` + +**Default**: `undefined` + +**Description**: Customize range expansion. + +```js +var range = braces.expand('x{a..e}y', { + transform: function(str) { + return 'foo' + str; + } +}); + +console.log(range); +//=> [ 'xfooay', 'xfooby', 'xfoocy', 'xfoody', 'xfooey' ] +``` + +### options.quantifiers + +**Type**: `Boolean` + +**Default**: `undefined` + +**Description**: In regular expressions, quanitifiers can be used to specify how many times a token can be repeated. For example, `a{1,3}` will match the letter `a` one to three times. + +Unfortunately, regex quantifiers happen to share the same syntax as [Bash lists](#lists) + +The `quantifiers` option tells braces to detect when [regex quantifiers](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/RegExp#quantifiers) are defined in the given pattern, and not to try to expand them as lists. + +**Examples** + +```js +var braces = require('braces'); +console.log(braces('a/b{1,3}/{x,y,z}')); +//=> [ 'a/b(1|3)/(x|y|z)' ] +console.log(braces('a/b{1,3}/{x,y,z}', {quantifiers: true})); +//=> [ 'a/b{1,3}/(x|y|z)' ] +console.log(braces('a/b{1,3}/{x,y,z}', {quantifiers: true, expand: true})); +//=> [ 'a/b{1,3}/x', 'a/b{1,3}/y', 'a/b{1,3}/z' ] +``` + +### options.unescape + +**Type**: `Boolean` + +**Default**: `undefined` + +**Description**: Strip backslashes that were used for escaping from the result. + +## What is "brace expansion"? + +Brace expansion is a type of parameter expansion that was made popular by unix shells for generating lists of strings, as well as regex-like matching when used alongside wildcards (globs). + +In addition to "expansion", braces are also used for matching. In other words: + +* [brace expansion](#brace-expansion) is for generating new lists +* [brace matching](#brace-matching) is for filtering existing lists + +
+More about brace expansion (click to expand) + +There are two main types of brace expansion: + +1. **lists**: which are defined using comma-separated values inside curly braces: `{a,b,c}` +2. **sequences**: which are defined using a starting value and an ending value, separated by two dots: `a{1..3}b`. Optionally, a third argument may be passed to define a "step" or increment to use: `a{1..100..10}b`. These are also sometimes referred to as "ranges". + +Here are some example brace patterns to illustrate how they work: + +**Sets** + +``` +{a,b,c} => a b c +{a,b,c}{1,2} => a1 a2 b1 b2 c1 c2 +``` + +**Sequences** + +``` +{1..9} => 1 2 3 4 5 6 7 8 9 +{4..-4} => 4 3 2 1 0 -1 -2 -3 -4 +{1..20..3} => 1 4 7 10 13 16 19 +{a..j} => a b c d e f g h i j +{j..a} => j i h g f e d c b a +{a..z..3} => a d g j m p s v y +``` + +**Combination** + +Sets and sequences can be mixed together or used along with any other strings. + +``` +{a,b,c}{1..3} => a1 a2 a3 b1 b2 b3 c1 c2 c3 +foo/{a,b,c}/bar => foo/a/bar foo/b/bar foo/c/bar +``` + +The fact that braces can be "expanded" from relatively simple patterns makes them ideal for quickly generating test fixtures, file paths, and similar use cases. + +## Brace matching + +In addition to _expansion_, brace patterns are also useful for performing regular-expression-like matching. + +For example, the pattern `foo/{1..3}/bar` would match any of following strings: + +``` +foo/1/bar +foo/2/bar +foo/3/bar +``` + +But not: + +``` +baz/1/qux +baz/2/qux +baz/3/qux +``` + +Braces can also be combined with [glob patterns](https://github.com/jonschlinkert/micromatch) to perform more advanced wildcard matching. For example, the pattern `*/{1..3}/*` would match any of following strings: + +``` +foo/1/bar +foo/2/bar +foo/3/bar +baz/1/qux +baz/2/qux +baz/3/qux +``` + +## Brace matching pitfalls + +Although brace patterns offer a user-friendly way of matching ranges or sets of strings, there are also some major disadvantages and potential risks you should be aware of. + +### tldr + +**"brace bombs"** + +* brace expansion can eat up a huge amount of processing resources +* as brace patterns increase _linearly in size_, the system resources required to expand the pattern increase exponentially +* users can accidentally (or intentially) exhaust your system's resources resulting in the equivalent of a DoS attack (bonus: no programming knowledge is required!) + +For a more detailed explanation with examples, see the [geometric complexity](#geometric-complexity) section. + +### The solution + +Jump to the [performance section](#performance) to see how Braces solves this problem in comparison to other libraries. + +### Geometric complexity + +At minimum, brace patterns with sets limited to two elements have quadradic or `O(n^2)` complexity. But the complexity of the algorithm increases exponentially as the number of sets, _and elements per set_, increases, which is `O(n^c)`. + +For example, the following sets demonstrate quadratic (`O(n^2)`) complexity: + +``` +{1,2}{3,4} => (2X2) => 13 14 23 24 +{1,2}{3,4}{5,6} => (2X2X2) => 135 136 145 146 235 236 245 246 +``` + +But add an element to a set, and we get a n-fold Cartesian product with `O(n^c)` complexity: + +``` +{1,2,3}{4,5,6}{7,8,9} => (3X3X3) => 147 148 149 157 158 159 167 168 169 247 248 + 249 257 258 259 267 268 269 347 348 349 357 + 358 359 367 368 369 +``` + +Now, imagine how this complexity grows given that each element is a n-tuple: + +``` +{1..100}{1..100} => (100X100) => 10,000 elements (38.4 kB) +{1..100}{1..100}{1..100} => (100X100X100) => 1,000,000 elements (5.76 MB) +``` + +Although these examples are clearly contrived, they demonstrate how brace patterns can quickly grow out of control. + +**More information** + +Interested in learning more about brace expansion? + +* [linuxjournal/bash-brace-expansion](http://www.linuxjournal.com/content/bash-brace-expansion) +* [rosettacode/Brace_expansion](https://rosettacode.org/wiki/Brace_expansion) +* [cartesian product](https://en.wikipedia.org/wiki/Cartesian_product) + +
+ +## Performance + +Braces is not only screaming fast, it's also more accurate the other brace expansion libraries. + +### Better algorithms + +Fortunately there is a solution to the ["brace bomb" problem](#brace-matching-pitfalls): _don't expand brace patterns into an array when they're used for matching_. + +Instead, convert the pattern into an optimized regular expression. This is easier said than done, and braces is the only library that does this currently. + +**The proof is in the numbers** + +Minimatch gets exponentially slower as patterns increase in complexity, braces does not. The following results were generated using `braces()` and `minimatch.braceExpand()`, respectively. + +| **Pattern** | **braces** | **[minimatch](https://github.com/isaacs/minimatch)** | +| --- | --- | --- | +| `{1..9007199254740991}`[1] | `298 B` (5ms 459μs) | N/A (freezes) | +| `{1..1000000000000000}` | `41 B` (1ms 15μs) | N/A (freezes) | +| `{1..100000000000000}` | `40 B` (890μs) | N/A (freezes) | +| `{1..10000000000000}` | `39 B` (2ms 49μs) | N/A (freezes) | +| `{1..1000000000000}` | `38 B` (608μs) | N/A (freezes) | +| `{1..100000000000}` | `37 B` (397μs) | N/A (freezes) | +| `{1..10000000000}` | `35 B` (983μs) | N/A (freezes) | +| `{1..1000000000}` | `34 B` (798μs) | N/A (freezes) | +| `{1..100000000}` | `33 B` (733μs) | N/A (freezes) | +| `{1..10000000}` | `32 B` (5ms 632μs) | `78.89 MB` (16s 388ms 569μs) | +| `{1..1000000}` | `31 B` (1ms 381μs) | `6.89 MB` (1s 496ms 887μs) | +| `{1..100000}` | `30 B` (950μs) | `588.89 kB` (146ms 921μs) | +| `{1..10000}` | `29 B` (1ms 114μs) | `48.89 kB` (14ms 187μs) | +| `{1..1000}` | `28 B` (760μs) | `3.89 kB` (1ms 453μs) | +| `{1..100}` | `22 B` (345μs) | `291 B` (196μs) | +| `{1..10}` | `10 B` (533μs) | `20 B` (37μs) | +| `{1..3}` | `7 B` (190μs) | `5 B` (27μs) | + +### Faster algorithms + +When you need expansion, braces is still much faster. + +_(the following results were generated using `braces.expand()` and `minimatch.braceExpand()`, respectively)_ + +| **Pattern** | **braces** | **[minimatch](https://github.com/isaacs/minimatch)** | +| --- | --- | --- | +| `{1..10000000}` | `78.89 MB` (2s 698ms 642μs) | `78.89 MB` (18s 601ms 974μs) | +| `{1..1000000}` | `6.89 MB` (458ms 576μs) | `6.89 MB` (1s 491ms 621μs) | +| `{1..100000}` | `588.89 kB` (20ms 728μs) | `588.89 kB` (156ms 919μs) | +| `{1..10000}` | `48.89 kB` (2ms 202μs) | `48.89 kB` (13ms 641μs) | +| `{1..1000}` | `3.89 kB` (1ms 796μs) | `3.89 kB` (1ms 958μs) | +| `{1..100}` | `291 B` (424μs) | `291 B` (211μs) | +| `{1..10}` | `20 B` (487μs) | `20 B` (72μs) | +| `{1..3}` | `5 B` (166μs) | `5 B` (27μs) | + +If you'd like to run these comparisons yourself, see [test/support/generate.js](test/support/generate.js). + +## Benchmarks + +### Running benchmarks + +Install dev dependencies: + +```bash +npm i -d && npm benchmark +``` + +### Latest results + +```bash +Benchmarking: (8 of 8) + · combination-nested + · combination + · escaped + · list-basic + · list-multiple + · no-braces + · sequence-basic + · sequence-multiple + +# benchmark/fixtures/combination-nested.js (52 bytes) + brace-expansion x 4,756 ops/sec ±1.09% (86 runs sampled) + braces x 11,202,303 ops/sec ±1.06% (88 runs sampled) + minimatch x 4,816 ops/sec ±0.99% (87 runs sampled) + + fastest is braces + +# benchmark/fixtures/combination.js (51 bytes) + brace-expansion x 625 ops/sec ±0.87% (87 runs sampled) + braces x 11,031,884 ops/sec ±0.72% (90 runs sampled) + minimatch x 637 ops/sec ±0.84% (88 runs sampled) + + fastest is braces + +# benchmark/fixtures/escaped.js (44 bytes) + brace-expansion x 163,325 ops/sec ±1.05% (87 runs sampled) + braces x 10,655,071 ops/sec ±1.22% (88 runs sampled) + minimatch x 147,495 ops/sec ±0.96% (88 runs sampled) + + fastest is braces + +# benchmark/fixtures/list-basic.js (40 bytes) + brace-expansion x 99,726 ops/sec ±1.07% (83 runs sampled) + braces x 10,596,584 ops/sec ±0.98% (88 runs sampled) + minimatch x 100,069 ops/sec ±1.17% (86 runs sampled) + + fastest is braces + +# benchmark/fixtures/list-multiple.js (52 bytes) + brace-expansion x 34,348 ops/sec ±1.08% (88 runs sampled) + braces x 9,264,131 ops/sec ±1.12% (88 runs sampled) + minimatch x 34,893 ops/sec ±0.87% (87 runs sampled) + + fastest is braces + +# benchmark/fixtures/no-braces.js (48 bytes) + brace-expansion x 275,368 ops/sec ±1.18% (89 runs sampled) + braces x 9,134,677 ops/sec ±0.95% (88 runs sampled) + minimatch x 3,755,954 ops/sec ±1.13% (89 runs sampled) + + fastest is braces + +# benchmark/fixtures/sequence-basic.js (41 bytes) + brace-expansion x 5,492 ops/sec ±1.35% (87 runs sampled) + braces x 8,485,034 ops/sec ±1.28% (89 runs sampled) + minimatch x 5,341 ops/sec ±1.17% (87 runs sampled) + + fastest is braces + +# benchmark/fixtures/sequence-multiple.js (51 bytes) + brace-expansion x 116 ops/sec ±0.77% (77 runs sampled) + braces x 9,445,118 ops/sec ±1.32% (84 runs sampled) + minimatch x 109 ops/sec ±1.16% (76 runs sampled) + + fastest is braces +``` + +## About + +
+Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new). + +
+ +
+Running Tests + +Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command: + +```sh +$ npm install && npm test +``` + +
+ +
+Building docs + +_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_ + +To generate the readme, run the following command: + +```sh +$ npm install -g verbose/verb#dev verb-generate-readme && verb +``` + +
+ +### Related projects + +You might also be interested in these projects: + +* [expand-brackets](https://www.npmjs.com/package/expand-brackets): Expand POSIX bracket expressions (character classes) in glob patterns. | [homepage](https://github.com/jonschlinkert/expand-brackets "Expand POSIX bracket expressions (character classes) in glob patterns.") +* [extglob](https://www.npmjs.com/package/extglob): Extended glob support for JavaScript. Adds (almost) the expressive power of regular expressions to glob… [more](https://github.com/micromatch/extglob) | [homepage](https://github.com/micromatch/extglob "Extended glob support for JavaScript. Adds (almost) the expressive power of regular expressions to glob patterns.") +* [fill-range](https://www.npmjs.com/package/fill-range): Fill in a range of numbers or letters, optionally passing an increment or `step` to… [more](https://github.com/jonschlinkert/fill-range) | [homepage](https://github.com/jonschlinkert/fill-range "Fill in a range of numbers or letters, optionally passing an increment or `step` to use, or create a regex-compatible range with `options.toRegex`") +* [micromatch](https://www.npmjs.com/package/micromatch): Glob matching for javascript/node.js. A drop-in replacement and faster alternative to minimatch and multimatch. | [homepage](https://github.com/micromatch/micromatch "Glob matching for javascript/node.js. A drop-in replacement and faster alternative to minimatch and multimatch.") +* [nanomatch](https://www.npmjs.com/package/nanomatch): Fast, minimal glob matcher for node.js. Similar to micromatch, minimatch and multimatch, but complete Bash… [more](https://github.com/micromatch/nanomatch) | [homepage](https://github.com/micromatch/nanomatch "Fast, minimal glob matcher for node.js. Similar to micromatch, minimatch and multimatch, but complete Bash 4.3 wildcard support only (no support for exglobs, posix brackets or braces)") + +### Contributors + +| **Commits** | **Contributor** | +| --- | --- | +| 188 | [jonschlinkert](https://github.com/jonschlinkert) | +| 4 | [doowb](https://github.com/doowb) | +| 1 | [es128](https://github.com/es128) | +| 1 | [eush77](https://github.com/eush77) | +| 1 | [hemanth](https://github.com/hemanth) | + +### Author + +**Jon Schlinkert** + +* [linkedin/in/jonschlinkert](https://linkedin.com/in/jonschlinkert) +* [github/jonschlinkert](https://github.com/jonschlinkert) +* [twitter/jonschlinkert](https://twitter.com/jonschlinkert) + +### License + +Copyright © 2018, [Jon Schlinkert](https://github.com/jonschlinkert). +Released under the [MIT License](LICENSE). + +*** + +_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.6.0, on February 17, 2018._ + +
+
+
    +
  1. this is the largest safe integer allowed in JavaScript. + +
  2. +
+
\ No newline at end of file diff --git a/node_modules/braces/index.js b/node_modules/braces/index.js new file mode 100644 index 0000000000..048e1c2334 --- /dev/null +++ b/node_modules/braces/index.js @@ -0,0 +1,318 @@ +'use strict'; + +/** + * Module dependencies + */ + +var toRegex = require('to-regex'); +var unique = require('array-unique'); +var extend = require('extend-shallow'); + +/** + * Local dependencies + */ + +var compilers = require('./lib/compilers'); +var parsers = require('./lib/parsers'); +var Braces = require('./lib/braces'); +var utils = require('./lib/utils'); +var MAX_LENGTH = 1024 * 64; +var cache = {}; + +/** + * Convert the given `braces` pattern into a regex-compatible string. By default, only one string is generated for every input string. Set `options.expand` to true to return an array of patterns (similar to Bash or minimatch. Before using `options.expand`, it's recommended that you read the [performance notes](#performance)). + * + * ```js + * var braces = require('braces'); + * console.log(braces('{a,b,c}')); + * //=> ['(a|b|c)'] + * + * console.log(braces('{a,b,c}', {expand: true})); + * //=> ['a', 'b', 'c'] + * ``` + * @param {String} `str` + * @param {Object} `options` + * @return {String} + * @api public + */ + +function braces(pattern, options) { + var key = utils.createKey(String(pattern), options); + var arr = []; + + var disabled = options && options.cache === false; + if (!disabled && cache.hasOwnProperty(key)) { + return cache[key]; + } + + if (Array.isArray(pattern)) { + for (var i = 0; i < pattern.length; i++) { + arr.push.apply(arr, braces.create(pattern[i], options)); + } + } else { + arr = braces.create(pattern, options); + } + + if (options && options.nodupes === true) { + arr = unique(arr); + } + + if (!disabled) { + cache[key] = arr; + } + return arr; +} + +/** + * Expands a brace pattern into an array. This method is called by the main [braces](#braces) function when `options.expand` is true. Before using this method it's recommended that you read the [performance notes](#performance)) and advantages of using [.optimize](#optimize) instead. + * + * ```js + * var braces = require('braces'); + * console.log(braces.expand('a/{b,c}/d')); + * //=> ['a/b/d', 'a/c/d']; + * ``` + * @param {String} `pattern` Brace pattern + * @param {Object} `options` + * @return {Array} Returns an array of expanded values. + * @api public + */ + +braces.expand = function(pattern, options) { + return braces.create(pattern, extend({}, options, {expand: true})); +}; + +/** + * Expands a brace pattern into a regex-compatible, optimized string. This method is called by the main [braces](#braces) function by default. + * + * ```js + * var braces = require('braces'); + * console.log(braces.expand('a/{b,c}/d')); + * //=> ['a/(b|c)/d'] + * ``` + * @param {String} `pattern` Brace pattern + * @param {Object} `options` + * @return {Array} Returns an array of expanded values. + * @api public + */ + +braces.optimize = function(pattern, options) { + return braces.create(pattern, options); +}; + +/** + * Processes a brace pattern and returns either an expanded array (if `options.expand` is true), a highly optimized regex-compatible string. This method is called by the main [braces](#braces) function. + * + * ```js + * var braces = require('braces'); + * console.log(braces.create('user-{200..300}/project-{a,b,c}-{1..10}')) + * //=> 'user-(20[0-9]|2[1-9][0-9]|300)/project-(a|b|c)-([1-9]|10)' + * ``` + * @param {String} `pattern` Brace pattern + * @param {Object} `options` + * @return {Array} Returns an array of expanded values. + * @api public + */ + +braces.create = function(pattern, options) { + if (typeof pattern !== 'string') { + throw new TypeError('expected a string'); + } + + var maxLength = (options && options.maxLength) || MAX_LENGTH; + if (pattern.length >= maxLength) { + throw new Error('expected pattern to be less than ' + maxLength + ' characters'); + } + + function create() { + if (pattern === '' || pattern.length < 3) { + return [pattern]; + } + + if (utils.isEmptySets(pattern)) { + return []; + } + + if (utils.isQuotedString(pattern)) { + return [pattern.slice(1, -1)]; + } + + var proto = new Braces(options); + var result = !options || options.expand !== true + ? proto.optimize(pattern, options) + : proto.expand(pattern, options); + + // get the generated pattern(s) + var arr = result.output; + + // filter out empty strings if specified + if (options && options.noempty === true) { + arr = arr.filter(Boolean); + } + + // filter out duplicates if specified + if (options && options.nodupes === true) { + arr = unique(arr); + } + + Object.defineProperty(arr, 'result', { + enumerable: false, + value: result + }); + + return arr; + } + + return memoize('create', pattern, options, create); +}; + +/** + * Create a regular expression from the given string `pattern`. + * + * ```js + * var braces = require('braces'); + * + * console.log(braces.makeRe('id-{200..300}')); + * //=> /^(?:id-(20[0-9]|2[1-9][0-9]|300))$/ + * ``` + * @param {String} `pattern` The pattern to convert to regex. + * @param {Object} `options` + * @return {RegExp} + * @api public + */ + +braces.makeRe = function(pattern, options) { + if (typeof pattern !== 'string') { + throw new TypeError('expected a string'); + } + + var maxLength = (options && options.maxLength) || MAX_LENGTH; + if (pattern.length >= maxLength) { + throw new Error('expected pattern to be less than ' + maxLength + ' characters'); + } + + function makeRe() { + var arr = braces(pattern, options); + var opts = extend({strictErrors: false}, options); + return toRegex(arr, opts); + } + + return memoize('makeRe', pattern, options, makeRe); +}; + +/** + * Parse the given `str` with the given `options`. + * + * ```js + * var braces = require('braces'); + * var ast = braces.parse('a/{b,c}/d'); + * console.log(ast); + * // { type: 'root', + * // errors: [], + * // input: 'a/{b,c}/d', + * // nodes: + * // [ { type: 'bos', val: '' }, + * // { type: 'text', val: 'a/' }, + * // { type: 'brace', + * // nodes: + * // [ { type: 'brace.open', val: '{' }, + * // { type: 'text', val: 'b,c' }, + * // { type: 'brace.close', val: '}' } ] }, + * // { type: 'text', val: '/d' }, + * // { type: 'eos', val: '' } ] } + * ``` + * @param {String} `pattern` Brace pattern to parse + * @param {Object} `options` + * @return {Object} Returns an AST + * @api public + */ + +braces.parse = function(pattern, options) { + var proto = new Braces(options); + return proto.parse(pattern, options); +}; + +/** + * Compile the given `ast` or string with the given `options`. + * + * ```js + * var braces = require('braces'); + * var ast = braces.parse('a/{b,c}/d'); + * console.log(braces.compile(ast)); + * // { options: { source: 'string' }, + * // state: {}, + * // compilers: + * // { eos: [Function], + * // noop: [Function], + * // bos: [Function], + * // brace: [Function], + * // 'brace.open': [Function], + * // text: [Function], + * // 'brace.close': [Function] }, + * // output: [ 'a/(b|c)/d' ], + * // ast: + * // { ... }, + * // parsingErrors: [] } + * ``` + * @param {Object|String} `ast` AST from [.parse](#parse). If a string is passed it will be parsed first. + * @param {Object} `options` + * @return {Object} Returns an object that has an `output` property with the compiled string. + * @api public + */ + +braces.compile = function(ast, options) { + var proto = new Braces(options); + return proto.compile(ast, options); +}; + +/** + * Clear the regex cache. + * + * ```js + * braces.clearCache(); + * ``` + * @api public + */ + +braces.clearCache = function() { + cache = braces.cache = {}; +}; + +/** + * Memoize a generated regex or function. A unique key is generated + * from the method name, pattern, and user-defined options. Set + * options.memoize to false to disable. + */ + +function memoize(type, pattern, options, fn) { + var key = utils.createKey(type + ':' + pattern, options); + var disabled = options && options.cache === false; + if (disabled) { + braces.clearCache(); + return fn(pattern, options); + } + + if (cache.hasOwnProperty(key)) { + return cache[key]; + } + + var res = fn(pattern, options); + cache[key] = res; + return res; +} + +/** + * Expose `Braces` constructor and methods + * @type {Function} + */ + +braces.Braces = Braces; +braces.compilers = compilers; +braces.parsers = parsers; +braces.cache = cache; + +/** + * Expose `braces` + * @type {Function} + */ + +module.exports = braces; diff --git a/node_modules/braces/lib/braces.js b/node_modules/braces/lib/braces.js new file mode 100644 index 0000000000..baf6bf1bc2 --- /dev/null +++ b/node_modules/braces/lib/braces.js @@ -0,0 +1,104 @@ +'use strict'; + +var extend = require('extend-shallow'); +var Snapdragon = require('snapdragon'); +var compilers = require('./compilers'); +var parsers = require('./parsers'); +var utils = require('./utils'); + +/** + * Customize Snapdragon parser and renderer + */ + +function Braces(options) { + this.options = extend({}, options); +} + +/** + * Initialize braces + */ + +Braces.prototype.init = function(options) { + if (this.isInitialized) return; + this.isInitialized = true; + var opts = utils.createOptions({}, this.options, options); + this.snapdragon = this.options.snapdragon || new Snapdragon(opts); + this.compiler = this.snapdragon.compiler; + this.parser = this.snapdragon.parser; + + compilers(this.snapdragon, opts); + parsers(this.snapdragon, opts); + + /** + * Call Snapdragon `.parse` method. When AST is returned, we check to + * see if any unclosed braces are left on the stack and, if so, we iterate + * over the stack and correct the AST so that compilers are called in the correct + * order and unbalance braces are properly escaped. + */ + + utils.define(this.snapdragon, 'parse', function(pattern, options) { + var parsed = Snapdragon.prototype.parse.apply(this, arguments); + this.parser.ast.input = pattern; + + var stack = this.parser.stack; + while (stack.length) { + addParent({type: 'brace.close', val: ''}, stack.pop()); + } + + function addParent(node, parent) { + utils.define(node, 'parent', parent); + parent.nodes.push(node); + } + + // add non-enumerable parser reference + utils.define(parsed, 'parser', this.parser); + return parsed; + }); +}; + +/** + * Decorate `.parse` method + */ + +Braces.prototype.parse = function(ast, options) { + if (ast && typeof ast === 'object' && ast.nodes) return ast; + this.init(options); + return this.snapdragon.parse(ast, options); +}; + +/** + * Decorate `.compile` method + */ + +Braces.prototype.compile = function(ast, options) { + if (typeof ast === 'string') { + ast = this.parse(ast, options); + } else { + this.init(options); + } + return this.snapdragon.compile(ast, options); +}; + +/** + * Expand + */ + +Braces.prototype.expand = function(pattern) { + var ast = this.parse(pattern, {expand: true}); + return this.compile(ast, {expand: true}); +}; + +/** + * Optimize + */ + +Braces.prototype.optimize = function(pattern) { + var ast = this.parse(pattern, {optimize: true}); + return this.compile(ast, {optimize: true}); +}; + +/** + * Expose `Braces` + */ + +module.exports = Braces; diff --git a/node_modules/braces/lib/compilers.js b/node_modules/braces/lib/compilers.js new file mode 100644 index 0000000000..a3b820e415 --- /dev/null +++ b/node_modules/braces/lib/compilers.js @@ -0,0 +1,282 @@ +'use strict'; + +var utils = require('./utils'); + +module.exports = function(braces, options) { + braces.compiler + + /** + * bos + */ + + .set('bos', function() { + if (this.output) return; + this.ast.queue = isEscaped(this.ast) ? [this.ast.val] : []; + this.ast.count = 1; + }) + + /** + * Square brackets + */ + + .set('bracket', function(node) { + var close = node.close; + var open = !node.escaped ? '[' : '\\['; + var negated = node.negated; + var inner = node.inner; + + inner = inner.replace(/\\(?=[\\\w]|$)/g, '\\\\'); + if (inner === ']-') { + inner = '\\]\\-'; + } + + if (negated && inner.indexOf('.') === -1) { + inner += '.'; + } + if (negated && inner.indexOf('/') === -1) { + inner += '/'; + } + + var val = open + negated + inner + close; + var queue = node.parent.queue; + var last = utils.arrayify(queue.pop()); + + queue.push(utils.join(last, val)); + queue.push.apply(queue, []); + }) + + /** + * Brace + */ + + .set('brace', function(node) { + node.queue = isEscaped(node) ? [node.val] : []; + node.count = 1; + return this.mapVisit(node.nodes); + }) + + /** + * Open + */ + + .set('brace.open', function(node) { + node.parent.open = node.val; + }) + + /** + * Inner + */ + + .set('text', function(node) { + var queue = node.parent.queue; + var escaped = node.escaped; + var segs = [node.val]; + + if (node.optimize === false) { + options = utils.extend({}, options, {optimize: false}); + } + + if (node.multiplier > 1) { + node.parent.count *= node.multiplier; + } + + if (options.quantifiers === true && utils.isQuantifier(node.val)) { + escaped = true; + + } else if (node.val.length > 1) { + if (isType(node.parent, 'brace') && !isEscaped(node)) { + var expanded = utils.expand(node.val, options); + segs = expanded.segs; + + if (expanded.isOptimized) { + node.parent.isOptimized = true; + } + + // if nothing was expanded, we probably have a literal brace + if (!segs.length) { + var val = (expanded.val || node.val); + if (options.unescape !== false) { + // unescape unexpanded brace sequence/set separators + val = val.replace(/\\([,.])/g, '$1'); + // strip quotes + val = val.replace(/["'`]/g, ''); + } + + segs = [val]; + escaped = true; + } + } + + } else if (node.val === ',') { + if (options.expand) { + node.parent.queue.push(['']); + segs = ['']; + } else { + segs = ['|']; + } + } else { + escaped = true; + } + + if (escaped && isType(node.parent, 'brace')) { + if (node.parent.nodes.length <= 4 && node.parent.count === 1) { + node.parent.escaped = true; + } else if (node.parent.length <= 3) { + node.parent.escaped = true; + } + } + + if (!hasQueue(node.parent)) { + node.parent.queue = segs; + return; + } + + var last = utils.arrayify(queue.pop()); + if (node.parent.count > 1 && options.expand) { + last = multiply(last, node.parent.count); + node.parent.count = 1; + } + + queue.push(utils.join(utils.flatten(last), segs.shift())); + queue.push.apply(queue, segs); + }) + + /** + * Close + */ + + .set('brace.close', function(node) { + var queue = node.parent.queue; + var prev = node.parent.parent; + var last = prev.queue.pop(); + var open = node.parent.open; + var close = node.val; + + if (open && close && isOptimized(node, options)) { + open = '('; + close = ')'; + } + + // if a close brace exists, and the previous segment is one character + // don't wrap the result in braces or parens + var ele = utils.last(queue); + if (node.parent.count > 1 && options.expand) { + ele = multiply(queue.pop(), node.parent.count); + node.parent.count = 1; + queue.push(ele); + } + + if (close && typeof ele === 'string' && ele.length === 1) { + open = ''; + close = ''; + } + + if ((isLiteralBrace(node, options) || noInner(node)) && !node.parent.hasEmpty) { + queue.push(utils.join(open, queue.pop() || '')); + queue = utils.flatten(utils.join(queue, close)); + } + + if (typeof last === 'undefined') { + prev.queue = [queue]; + } else { + prev.queue.push(utils.flatten(utils.join(last, queue))); + } + }) + + /** + * eos + */ + + .set('eos', function(node) { + if (this.input) return; + + if (options.optimize !== false) { + this.output = utils.last(utils.flatten(this.ast.queue)); + } else if (Array.isArray(utils.last(this.ast.queue))) { + this.output = utils.flatten(this.ast.queue.pop()); + } else { + this.output = utils.flatten(this.ast.queue); + } + + if (node.parent.count > 1 && options.expand) { + this.output = multiply(this.output, node.parent.count); + } + + this.output = utils.arrayify(this.output); + this.ast.queue = []; + }); + +}; + +/** + * Multiply the segments in the current brace level + */ + +function multiply(queue, n, options) { + return utils.flatten(utils.repeat(utils.arrayify(queue), n)); +} + +/** + * Return true if `node` is escaped + */ + +function isEscaped(node) { + return node.escaped === true; +} + +/** + * Returns true if regex parens should be used for sets. If the parent `type` + * is not `brace`, then we're on a root node, which means we should never + * expand segments and open/close braces should be `{}` (since this indicates + * a brace is missing from the set) + */ + +function isOptimized(node, options) { + if (node.parent.isOptimized) return true; + return isType(node.parent, 'brace') + && !isEscaped(node.parent) + && options.expand !== true; +} + +/** + * Returns true if the value in `node` should be wrapped in a literal brace. + * @return {Boolean} + */ + +function isLiteralBrace(node, options) { + return isEscaped(node.parent) || options.optimize !== false; +} + +/** + * Returns true if the given `node` does not have an inner value. + * @return {Boolean} + */ + +function noInner(node, type) { + if (node.parent.queue.length === 1) { + return true; + } + var nodes = node.parent.nodes; + return nodes.length === 3 + && isType(nodes[0], 'brace.open') + && !isType(nodes[1], 'text') + && isType(nodes[2], 'brace.close'); +} + +/** + * Returns true if the given `node` is the given `type` + * @return {Boolean} + */ + +function isType(node, type) { + return typeof node !== 'undefined' && node.type === type; +} + +/** + * Returns true if the given `node` has a non-empty queue. + * @return {Boolean} + */ + +function hasQueue(node) { + return Array.isArray(node.queue) && node.queue.length; +} diff --git a/node_modules/braces/lib/parsers.js b/node_modules/braces/lib/parsers.js new file mode 100644 index 0000000000..8bf3e92b55 --- /dev/null +++ b/node_modules/braces/lib/parsers.js @@ -0,0 +1,360 @@ +'use strict'; + +var Node = require('snapdragon-node'); +var utils = require('./utils'); + +/** + * Braces parsers + */ + +module.exports = function(braces, options) { + braces.parser + .set('bos', function() { + if (!this.parsed) { + this.ast = this.nodes[0] = new Node(this.ast); + } + }) + + /** + * Character parsers + */ + + .set('escape', function() { + var pos = this.position(); + var m = this.match(/^(?:\\(.)|\$\{)/); + if (!m) return; + + var prev = this.prev(); + var last = utils.last(prev.nodes); + + var node = pos(new Node({ + type: 'text', + multiplier: 1, + val: m[0] + })); + + if (node.val === '\\\\') { + return node; + } + + if (node.val === '${') { + var str = this.input; + var idx = -1; + var ch; + + while ((ch = str[++idx])) { + this.consume(1); + node.val += ch; + if (ch === '\\') { + node.val += str[++idx]; + continue; + } + if (ch === '}') { + break; + } + } + } + + if (this.options.unescape !== false) { + node.val = node.val.replace(/\\([{}])/g, '$1'); + } + + if (last.val === '"' && this.input.charAt(0) === '"') { + last.val = node.val; + this.consume(1); + return; + } + + return concatNodes.call(this, pos, node, prev, options); + }) + + /** + * Brackets: "[...]" (basic, this is overridden by + * other parsers in more advanced implementations) + */ + + .set('bracket', function() { + var isInside = this.isInside('brace'); + var pos = this.position(); + var m = this.match(/^(?:\[([!^]?)([^\]]{2,}|\]-)(\]|[^*+?]+)|\[)/); + if (!m) return; + + var prev = this.prev(); + var val = m[0]; + var negated = m[1] ? '^' : ''; + var inner = m[2] || ''; + var close = m[3] || ''; + + if (isInside && prev.type === 'brace') { + prev.text = prev.text || ''; + prev.text += val; + } + + var esc = this.input.slice(0, 2); + if (inner === '' && esc === '\\]') { + inner += esc; + this.consume(2); + + var str = this.input; + var idx = -1; + var ch; + + while ((ch = str[++idx])) { + this.consume(1); + if (ch === ']') { + close = ch; + break; + } + inner += ch; + } + } + + return pos(new Node({ + type: 'bracket', + val: val, + escaped: close !== ']', + negated: negated, + inner: inner, + close: close + })); + }) + + /** + * Empty braces (we capture these early to + * speed up processing in the compiler) + */ + + .set('multiplier', function() { + var isInside = this.isInside('brace'); + var pos = this.position(); + var m = this.match(/^\{((?:,|\{,+\})+)\}/); + if (!m) return; + + this.multiplier = true; + var prev = this.prev(); + var val = m[0]; + + if (isInside && prev.type === 'brace') { + prev.text = prev.text || ''; + prev.text += val; + } + + var node = pos(new Node({ + type: 'text', + multiplier: 1, + match: m, + val: val + })); + + return concatNodes.call(this, pos, node, prev, options); + }) + + /** + * Open + */ + + .set('brace.open', function() { + var pos = this.position(); + var m = this.match(/^\{(?!(?:[^\\}]?|,+)\})/); + if (!m) return; + + var prev = this.prev(); + var last = utils.last(prev.nodes); + + // if the last parsed character was an extglob character + // we need to _not optimize_ the brace pattern because + // it might be mistaken for an extglob by a downstream parser + if (last && last.val && isExtglobChar(last.val.slice(-1))) { + last.optimize = false; + } + + var open = pos(new Node({ + type: 'brace.open', + val: m[0] + })); + + var node = pos(new Node({ + type: 'brace', + nodes: [] + })); + + node.push(open); + prev.push(node); + this.push('brace', node); + }) + + /** + * Close + */ + + .set('brace.close', function() { + var pos = this.position(); + var m = this.match(/^\}/); + if (!m || !m[0]) return; + + var brace = this.pop('brace'); + var node = pos(new Node({ + type: 'brace.close', + val: m[0] + })); + + if (!this.isType(brace, 'brace')) { + if (this.options.strict) { + throw new Error('missing opening "{"'); + } + node.type = 'text'; + node.multiplier = 0; + node.escaped = true; + return node; + } + + var prev = this.prev(); + var last = utils.last(prev.nodes); + if (last.text) { + var lastNode = utils.last(last.nodes); + if (lastNode.val === ')' && /[!@*?+]\(/.test(last.text)) { + var open = last.nodes[0]; + var text = last.nodes[1]; + if (open.type === 'brace.open' && text && text.type === 'text') { + text.optimize = false; + } + } + } + + if (brace.nodes.length > 2) { + var first = brace.nodes[1]; + if (first.type === 'text' && first.val === ',') { + brace.nodes.splice(1, 1); + brace.nodes.push(first); + } + } + + brace.push(node); + }) + + /** + * Capture boundary characters + */ + + .set('boundary', function() { + var pos = this.position(); + var m = this.match(/^[$^](?!\{)/); + if (!m) return; + return pos(new Node({ + type: 'text', + val: m[0] + })); + }) + + /** + * One or zero, non-comma characters wrapped in braces + */ + + .set('nobrace', function() { + var isInside = this.isInside('brace'); + var pos = this.position(); + var m = this.match(/^\{[^,]?\}/); + if (!m) return; + + var prev = this.prev(); + var val = m[0]; + + if (isInside && prev.type === 'brace') { + prev.text = prev.text || ''; + prev.text += val; + } + + return pos(new Node({ + type: 'text', + multiplier: 0, + val: val + })); + }) + + /** + * Text + */ + + .set('text', function() { + var isInside = this.isInside('brace'); + var pos = this.position(); + var m = this.match(/^((?!\\)[^${}[\]])+/); + if (!m) return; + + var prev = this.prev(); + var val = m[0]; + + if (isInside && prev.type === 'brace') { + prev.text = prev.text || ''; + prev.text += val; + } + + var node = pos(new Node({ + type: 'text', + multiplier: 1, + val: val + })); + + return concatNodes.call(this, pos, node, prev, options); + }); +}; + +/** + * Returns true if the character is an extglob character. + */ + +function isExtglobChar(ch) { + return ch === '!' || ch === '@' || ch === '*' || ch === '?' || ch === '+'; +} + +/** + * Combine text nodes, and calculate empty sets (`{,,}`) + * @param {Function} `pos` Function to calculate node position + * @param {Object} `node` AST node + * @return {Object} + */ + +function concatNodes(pos, node, parent, options) { + node.orig = node.val; + var prev = this.prev(); + var last = utils.last(prev.nodes); + var isEscaped = false; + + if (node.val.length > 1) { + var a = node.val.charAt(0); + var b = node.val.slice(-1); + + isEscaped = (a === '"' && b === '"') + || (a === "'" && b === "'") + || (a === '`' && b === '`'); + } + + if (isEscaped && options.unescape !== false) { + node.val = node.val.slice(1, node.val.length - 1); + node.escaped = true; + } + + if (node.match) { + var match = node.match[1]; + if (!match || match.indexOf('}') === -1) { + match = node.match[0]; + } + + // replace each set with a single "," + var val = match.replace(/\{/g, ',').replace(/\}/g, ''); + node.multiplier *= val.length; + node.val = ''; + } + + var simpleText = last.type === 'text' + && last.multiplier === 1 + && node.multiplier === 1 + && node.val; + + if (simpleText) { + last.val += node.val; + return; + } + + prev.push(node); +} diff --git a/node_modules/braces/lib/utils.js b/node_modules/braces/lib/utils.js new file mode 100644 index 0000000000..471667171d --- /dev/null +++ b/node_modules/braces/lib/utils.js @@ -0,0 +1,343 @@ +'use strict'; + +var splitString = require('split-string'); +var utils = module.exports; + +/** + * Module dependencies + */ + +utils.extend = require('extend-shallow'); +utils.flatten = require('arr-flatten'); +utils.isObject = require('isobject'); +utils.fillRange = require('fill-range'); +utils.repeat = require('repeat-element'); +utils.unique = require('array-unique'); + +utils.define = function(obj, key, val) { + Object.defineProperty(obj, key, { + writable: true, + configurable: true, + enumerable: false, + value: val + }); +}; + +/** + * Returns true if the given string contains only empty brace sets. + */ + +utils.isEmptySets = function(str) { + return /^(?:\{,\})+$/.test(str); +}; + +/** + * Returns true if the given string contains only empty brace sets. + */ + +utils.isQuotedString = function(str) { + var open = str.charAt(0); + if (open === '\'' || open === '"' || open === '`') { + return str.slice(-1) === open; + } + return false; +}; + +/** + * Create the key to use for memoization. The unique key is generated + * by iterating over the options and concatenating key-value pairs + * to the pattern string. + */ + +utils.createKey = function(pattern, options) { + var id = pattern; + if (typeof options === 'undefined') { + return id; + } + var keys = Object.keys(options); + for (var i = 0; i < keys.length; i++) { + var key = keys[i]; + id += ';' + key + '=' + String(options[key]); + } + return id; +}; + +/** + * Normalize options + */ + +utils.createOptions = function(options) { + var opts = utils.extend.apply(null, arguments); + if (typeof opts.expand === 'boolean') { + opts.optimize = !opts.expand; + } + if (typeof opts.optimize === 'boolean') { + opts.expand = !opts.optimize; + } + if (opts.optimize === true) { + opts.makeRe = true; + } + return opts; +}; + +/** + * Join patterns in `a` to patterns in `b` + */ + +utils.join = function(a, b, options) { + options = options || {}; + a = utils.arrayify(a); + b = utils.arrayify(b); + + if (!a.length) return b; + if (!b.length) return a; + + var len = a.length; + var idx = -1; + var arr = []; + + while (++idx < len) { + var val = a[idx]; + if (Array.isArray(val)) { + for (var i = 0; i < val.length; i++) { + val[i] = utils.join(val[i], b, options); + } + arr.push(val); + continue; + } + + for (var j = 0; j < b.length; j++) { + var bval = b[j]; + + if (Array.isArray(bval)) { + arr.push(utils.join(val, bval, options)); + } else { + arr.push(val + bval); + } + } + } + return arr; +}; + +/** + * Split the given string on `,` if not escaped. + */ + +utils.split = function(str, options) { + var opts = utils.extend({sep: ','}, options); + if (typeof opts.keepQuotes !== 'boolean') { + opts.keepQuotes = true; + } + if (opts.unescape === false) { + opts.keepEscaping = true; + } + return splitString(str, opts, utils.escapeBrackets(opts)); +}; + +/** + * Expand ranges or sets in the given `pattern`. + * + * @param {String} `str` + * @param {Object} `options` + * @return {Object} + */ + +utils.expand = function(str, options) { + var opts = utils.extend({rangeLimit: 10000}, options); + var segs = utils.split(str, opts); + var tok = { segs: segs }; + + if (utils.isQuotedString(str)) { + return tok; + } + + if (opts.rangeLimit === true) { + opts.rangeLimit = 10000; + } + + if (segs.length > 1) { + if (opts.optimize === false) { + tok.val = segs[0]; + return tok; + } + + tok.segs = utils.stringifyArray(tok.segs); + } else if (segs.length === 1) { + var arr = str.split('..'); + + if (arr.length === 1) { + tok.val = tok.segs[tok.segs.length - 1] || tok.val || str; + tok.segs = []; + return tok; + } + + if (arr.length === 2 && arr[0] === arr[1]) { + tok.escaped = true; + tok.val = arr[0]; + tok.segs = []; + return tok; + } + + if (arr.length > 1) { + if (opts.optimize !== false) { + opts.optimize = true; + delete opts.expand; + } + + if (opts.optimize !== true) { + var min = Math.min(arr[0], arr[1]); + var max = Math.max(arr[0], arr[1]); + var step = arr[2] || 1; + + if (opts.rangeLimit !== false && ((max - min) / step >= opts.rangeLimit)) { + throw new RangeError('expanded array length exceeds range limit. Use options.rangeLimit to increase or disable the limit.'); + } + } + + arr.push(opts); + tok.segs = utils.fillRange.apply(null, arr); + + if (!tok.segs.length) { + tok.escaped = true; + tok.val = str; + return tok; + } + + if (opts.optimize === true) { + tok.segs = utils.stringifyArray(tok.segs); + } + + if (tok.segs === '') { + tok.val = str; + } else { + tok.val = tok.segs[0]; + } + return tok; + } + } else { + tok.val = str; + } + return tok; +}; + +/** + * Ensure commas inside brackets and parens are not split. + * @param {Object} `tok` Token from the `split-string` module + * @return {undefined} + */ + +utils.escapeBrackets = function(options) { + return function(tok) { + if (tok.escaped && tok.val === 'b') { + tok.val = '\\b'; + return; + } + + if (tok.val !== '(' && tok.val !== '[') return; + var opts = utils.extend({}, options); + var brackets = []; + var parens = []; + var stack = []; + var val = tok.val; + var str = tok.str; + var i = tok.idx - 1; + + while (++i < str.length) { + var ch = str[i]; + + if (ch === '\\') { + val += (opts.keepEscaping === false ? '' : ch) + str[++i]; + continue; + } + + if (ch === '(') { + parens.push(ch); + stack.push(ch); + } + + if (ch === '[') { + brackets.push(ch); + stack.push(ch); + } + + if (ch === ')') { + parens.pop(); + stack.pop(); + if (!stack.length) { + val += ch; + break; + } + } + + if (ch === ']') { + brackets.pop(); + stack.pop(); + if (!stack.length) { + val += ch; + break; + } + } + val += ch; + } + + tok.split = false; + tok.val = val.slice(1); + tok.idx = i; + }; +}; + +/** + * Returns true if the given string looks like a regex quantifier + * @return {Boolean} + */ + +utils.isQuantifier = function(str) { + return /^(?:[0-9]?,[0-9]|[0-9],)$/.test(str); +}; + +/** + * Cast `val` to an array. + * @param {*} `val` + */ + +utils.stringifyArray = function(arr) { + return [utils.arrayify(arr).join('|')]; +}; + +/** + * Cast `val` to an array. + * @param {*} `val` + */ + +utils.arrayify = function(arr) { + if (typeof arr === 'undefined') { + return []; + } + if (typeof arr === 'string') { + return [arr]; + } + return arr; +}; + +/** + * Returns true if the given `str` is a non-empty string + * @return {Boolean} + */ + +utils.isString = function(str) { + return str != null && typeof str === 'string'; +}; + +/** + * Get the last element from `array` + * @param {Array} `array` + * @return {*} + */ + +utils.last = function(arr, n) { + return arr[arr.length - (n || 1)]; +}; + +utils.escapeRegex = function(str) { + return str.replace(/\\?([!^*?()[\]{}+?/])/g, '\\$1'); +}; diff --git a/node_modules/braces/node_modules/extend-shallow/LICENSE b/node_modules/braces/node_modules/extend-shallow/LICENSE new file mode 100644 index 0000000000..fa30c4cb3e --- /dev/null +++ b/node_modules/braces/node_modules/extend-shallow/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2014-2015, Jon Schlinkert. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/braces/node_modules/extend-shallow/README.md b/node_modules/braces/node_modules/extend-shallow/README.md new file mode 100644 index 0000000000..cdc45d4ff7 --- /dev/null +++ b/node_modules/braces/node_modules/extend-shallow/README.md @@ -0,0 +1,61 @@ +# extend-shallow [![NPM version](https://badge.fury.io/js/extend-shallow.svg)](http://badge.fury.io/js/extend-shallow) [![Build Status](https://travis-ci.org/jonschlinkert/extend-shallow.svg)](https://travis-ci.org/jonschlinkert/extend-shallow) + +> Extend an object with the properties of additional objects. node.js/javascript util. + +## Install + +Install with [npm](https://www.npmjs.com/) + +```sh +$ npm i extend-shallow --save +``` + +## Usage + +```js +var extend = require('extend-shallow'); + +extend({a: 'b'}, {c: 'd'}) +//=> {a: 'b', c: 'd'} +``` + +Pass an empty object to shallow clone: + +```js +var obj = {}; +extend(obj, {a: 'b'}, {c: 'd'}) +//=> {a: 'b', c: 'd'} +``` + +## Related + +* [extend-shallow](https://github.com/jonschlinkert/extend-shallow): Extend an object with the properties of additional objects. node.js/javascript util. +* [for-own](https://github.com/jonschlinkert/for-own): Iterate over the own enumerable properties of an object, and return an object with properties… [more](https://github.com/jonschlinkert/for-own) +* [for-in](https://github.com/jonschlinkert/for-in): Iterate over the own and inherited enumerable properties of an objecte, and return an object… [more](https://github.com/jonschlinkert/for-in) +* [is-plain-object](https://github.com/jonschlinkert/is-plain-object): Returns true if an object was created by the `Object` constructor. +* [isobject](https://github.com/jonschlinkert/isobject): Returns true if the value is an object and not an array or null. +* [kind-of](https://github.com/jonschlinkert/kind-of): Get the native type of a value. + +## Running tests + +Install dev dependencies: + +```sh +$ npm i -d && npm test +``` + +## Author + +**Jon Schlinkert** + ++ [github/jonschlinkert](https://github.com/jonschlinkert) ++ [twitter/jonschlinkert](http://twitter.com/jonschlinkert) + +## License + +Copyright © 2015 Jon Schlinkert +Released under the MIT license. + +*** + +_This file was generated by [verb-cli](https://github.com/assemble/verb-cli) on June 29, 2015._ \ No newline at end of file diff --git a/node_modules/braces/node_modules/extend-shallow/index.js b/node_modules/braces/node_modules/extend-shallow/index.js new file mode 100644 index 0000000000..92a067fcc4 --- /dev/null +++ b/node_modules/braces/node_modules/extend-shallow/index.js @@ -0,0 +1,33 @@ +'use strict'; + +var isObject = require('is-extendable'); + +module.exports = function extend(o/*, objects*/) { + if (!isObject(o)) { o = {}; } + + var len = arguments.length; + for (var i = 1; i < len; i++) { + var obj = arguments[i]; + + if (isObject(obj)) { + assign(o, obj); + } + } + return o; +}; + +function assign(a, b) { + for (var key in b) { + if (hasOwn(b, key)) { + a[key] = b[key]; + } + } +} + +/** + * Returns true if the given `key` is an own property of `obj`. + */ + +function hasOwn(obj, key) { + return Object.prototype.hasOwnProperty.call(obj, key); +} diff --git a/node_modules/braces/node_modules/extend-shallow/package.json b/node_modules/braces/node_modules/extend-shallow/package.json new file mode 100644 index 0000000000..427b4e043d --- /dev/null +++ b/node_modules/braces/node_modules/extend-shallow/package.json @@ -0,0 +1,87 @@ +{ + "_from": "extend-shallow@^2.0.1", + "_id": "extend-shallow@2.0.1", + "_inBundle": false, + "_integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "_location": "/braces/extend-shallow", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "extend-shallow@^2.0.1", + "name": "extend-shallow", + "escapedName": "extend-shallow", + "rawSpec": "^2.0.1", + "saveSpec": null, + "fetchSpec": "^2.0.1" + }, + "_requiredBy": [ + "/braces" + ], + "_resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "_shasum": "51af7d614ad9a9f610ea1bafbb989d6b1c56890f", + "_spec": "extend-shallow@^2.0.1", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/braces", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/jonschlinkert/extend-shallow/issues" + }, + "bundleDependencies": false, + "dependencies": { + "is-extendable": "^0.1.0" + }, + "deprecated": false, + "description": "Extend an object with the properties of additional objects. node.js/javascript util.", + "devDependencies": { + "array-slice": "^0.2.3", + "benchmarked": "^0.1.4", + "chalk": "^1.0.0", + "for-own": "^0.1.3", + "glob": "^5.0.12", + "is-plain-object": "^2.0.1", + "kind-of": "^2.0.0", + "minimist": "^1.1.1", + "mocha": "^2.2.5", + "should": "^7.0.1" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/jonschlinkert/extend-shallow", + "keywords": [ + "assign", + "extend", + "javascript", + "js", + "keys", + "merge", + "obj", + "object", + "prop", + "properties", + "property", + "props", + "shallow", + "util", + "utility", + "utils", + "value" + ], + "license": "MIT", + "main": "index.js", + "name": "extend-shallow", + "repository": { + "type": "git", + "url": "git+https://github.com/jonschlinkert/extend-shallow.git" + }, + "scripts": { + "test": "mocha" + }, + "version": "2.0.1" +} diff --git a/node_modules/braces/package.json b/node_modules/braces/package.json new file mode 100644 index 0000000000..94e2007731 --- /dev/null +++ b/node_modules/braces/package.json @@ -0,0 +1,160 @@ +{ + "_from": "braces@^2.3.1", + "_id": "braces@2.3.2", + "_inBundle": false, + "_integrity": "sha512-aNdbnj9P8PjdXU4ybaWLK2IF3jc/EoDYbC7AazW6to3TRsfXxscC9UXOB5iDiEQrkyIbWp2SLQda4+QAa7nc3w==", + "_location": "/braces", + "_phantomChildren": { + "is-extendable": "0.1.1" + }, + "_requested": { + "type": "range", + "registry": true, + "raw": "braces@^2.3.1", + "name": "braces", + "escapedName": "braces", + "rawSpec": "^2.3.1", + "saveSpec": null, + "fetchSpec": "^2.3.1" + }, + "_requiredBy": [ + "/anymatch/micromatch", + "/chokidar", + "/chokidar/micromatch", + "/findup-sync/micromatch", + "/matchdep/micromatch" + ], + "_resolved": "https://registry.npmjs.org/braces/-/braces-2.3.2.tgz", + "_shasum": "5979fd3f14cd531565e5fa2df1abfff1dfaee729", + "_spec": "braces@^2.3.1", + "_where": "/Users/edenk/Documents/Product/Repositories/developers-community/node_modules/anymatch/node_modules/micromatch", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/micromatch/braces/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "Brian Woodward", + "url": "https://twitter.com/doowb" + }, + { + "name": "Elan Shanker", + "url": "https://github.com/es128" + }, + { + "name": "Eugene Sharygin", + "url": "https://github.com/eush77" + }, + { + "name": "hemanth.hm", + "url": "http://h3manth.com" + }, + { + "name": "Jon Schlinkert", + "url": "http://twitter.com/jonschlinkert" + } + ], + "dependencies": { + "arr-flatten": "^1.1.0", + "array-unique": "^0.3.2", + "extend-shallow": "^2.0.1", + "fill-range": "^4.0.0", + "isobject": "^3.0.1", + "repeat-element": "^1.1.2", + "snapdragon": "^0.8.1", + "snapdragon-node": "^2.0.1", + "split-string": "^3.0.2", + "to-regex": "^3.0.1" + }, + "deprecated": false, + "description": "Bash-like brace expansion, implemented in JavaScript. Safer than other brace expansion libs, with complete support for the Bash 4.3 braces specification, without sacrificing speed.", + "devDependencies": { + "ansi-cyan": "^0.1.1", + "benchmarked": "^2.0.0", + "brace-expansion": "^1.1.8", + "cross-spawn": "^5.1.0", + "gulp": "^3.9.1", + "gulp-eslint": "^4.0.0", + "gulp-format-md": "^1.0.0", + "gulp-istanbul": "^1.1.2", + "gulp-mocha": "^3.0.1", + "gulp-unused": "^0.2.1", + "is-windows": "^1.0.1", + "minimatch": "^3.0.4", + "mocha": "^3.2.0", + "noncharacters": "^1.1.0", + "text-table": "^0.2.0", + "time-diff": "^0.3.1", + "yargs-parser": "^8.0.0" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js", + "lib" + ], + "homepage": "https://github.com/micromatch/braces", + "keywords": [ + "alpha", + "alphabetical", + "bash", + "brace", + "braces", + "expand", + "expansion", + "filepath", + "fill", + "fs", + "glob", + "globbing", + "letter", + "match", + "matches", + "matching", + "number", + "numerical", + "path", + "range", + "ranges", + "sh" + ], + "license": "MIT", + "main": "index.js", + "name": "braces", + "repository": { + "type": "git", + "url": "git+https://github.com/micromatch/braces.git" + }, + "scripts": { + "benchmark": "node benchmark", + "test": "mocha" + }, + "verb": { + "toc": false, + "layout": "default", + "tasks": [ + "readme" + ], + "lint": { + "reflinks": true + }, + "plugins": [ + "gulp-format-md" + ], + "related": { + "list": [ + "expand-brackets", + "extglob", + "fill-range", + "micromatch", + "nanomatch" + ] + } + }, + "version": "2.3.2" +} diff --git a/node_modules/browser-sync-client/LICENSE b/node_modules/browser-sync-client/LICENSE new file mode 100644 index 0000000000..e93fa7238f --- /dev/null +++ b/node_modules/browser-sync-client/LICENSE @@ -0,0 +1,202 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [2015] [Shane Osbourne] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/node_modules/browser-sync-client/README.md b/node_modules/browser-sync-client/README.md new file mode 100644 index 0000000000..5f79a11fd3 --- /dev/null +++ b/node_modules/browser-sync-client/README.md @@ -0,0 +1,19 @@ +# browser-sync-client [![Build Status](https://travis-ci.org/BrowserSync/browser-sync-client.svg)](https://travis-ci.org/BrowserSync/browser-sync-client) + +Client-side script for BrowserSync + +## Contributors + +``` + 177 Shane Osbourne + 2 Sergey Slipchenko + 1 Hugo Dias + 1 Shinnosuke Watanabe + 1 Tim Schaub + 1 Shane Daniel + 1 Matthieu Vachon +``` + +## License +Copyright (c) 2014 Shane Osbourne +Licensed under the MIT license. diff --git a/node_modules/browser-sync-client/dist/index.js b/node_modules/browser-sync-client/dist/index.js new file mode 100644 index 0000000000..1e71887d5f --- /dev/null +++ b/node_modules/browser-sync-client/dist/index.js @@ -0,0 +1,18986 @@ +/******/ (function(modules) { // webpackBootstrap +/******/ // The module cache +/******/ var installedModules = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ +/******/ // Check if module is in cache +/******/ if(installedModules[moduleId]) { +/******/ return installedModules[moduleId].exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = installedModules[moduleId] = { +/******/ i: moduleId, +/******/ l: false, +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); +/******/ +/******/ // Flag the module as loaded +/******/ module.l = true; +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = modules; +/******/ +/******/ // expose the module cache +/******/ __webpack_require__.c = installedModules; +/******/ +/******/ // define getter function for harmony exports +/******/ __webpack_require__.d = function(exports, name, getter) { +/******/ if(!__webpack_require__.o(exports, name)) { +/******/ Object.defineProperty(exports, name, { +/******/ configurable: false, +/******/ enumerable: true, +/******/ get: getter +/******/ }); +/******/ } +/******/ }; +/******/ +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = function(module) { +/******/ var getter = module && module.__esModule ? +/******/ function getDefault() { return module['default']; } : +/******/ function getModuleExports() { return module; }; +/******/ __webpack_require__.d(getter, 'a', getter); +/******/ return getter; +/******/ }; +/******/ +/******/ // Object.prototype.hasOwnProperty.call +/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; +/******/ +/******/ // __webpack_public_path__ +/******/ __webpack_require__.p = ""; +/******/ +/******/ // Load entry module and return exports +/******/ return __webpack_require__(__webpack_require__.s = 99); +/******/ }) +/************************************************************************/ +/******/ ([ +/* 0 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var __extends = (this && this.__extends) || function (d, b) { + for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +}; +var OuterSubscriber_1 = __webpack_require__(29); +var subscribeToResult_1 = __webpack_require__(30); +/* tslint:enable:max-line-length */ +/** + * Combines the source Observable with other Observables to create an Observable + * whose values are calculated from the latest values of each, only when the + * source emits. + * + * Whenever the source Observable emits a value, it + * computes a formula using that value plus the latest values from other input + * Observables, then emits the output of that formula. + * + * + * + * `withLatestFrom` combines each value from the source Observable (the + * instance) with the latest values from the other input Observables only when + * the source emits a value, optionally using a `project` function to determine + * the value to be emitted on the output Observable. All input Observables must + * emit at least one value before the output Observable will emit a value. + * + * @example On every click event, emit an array with the latest timer event plus the click event + * var clicks = Rx.Observable.fromEvent(document, 'click'); + * var timer = Rx.Observable.interval(1000); + * var result = clicks.withLatestFrom(timer); + * result.subscribe(x => console.log(x)); + * + * @see {@link combineLatest} + * + * @param {ObservableInput} other An input Observable to combine with the source + * Observable. More than one input Observables may be given as argument. + * @param {Function} [project] Projection function for combining values + * together. Receives all values in order of the Observables passed, where the + * first parameter is a value from the source Observable. (e.g. + * `a.withLatestFrom(b, c, (a1, b1, c1) => a1 + b1 + c1)`). If this is not + * passed, arrays will be emitted on the output Observable. + * @return {Observable} An Observable of projected values from the most recent + * values from each input Observable, or an array of the most recent values from + * each input Observable. + * @method withLatestFrom + * @owner Observable + */ +function withLatestFrom() { + var args = []; + for (var _i = 0; _i < arguments.length; _i++) { + args[_i - 0] = arguments[_i]; + } + return function (source) { + var project; + if (typeof args[args.length - 1] === 'function') { + project = args.pop(); + } + var observables = args; + return source.lift(new WithLatestFromOperator(observables, project)); + }; +} +exports.withLatestFrom = withLatestFrom; +var WithLatestFromOperator = (function () { + function WithLatestFromOperator(observables, project) { + this.observables = observables; + this.project = project; + } + WithLatestFromOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new WithLatestFromSubscriber(subscriber, this.observables, this.project)); + }; + return WithLatestFromOperator; +}()); +/** + * We need this JSDoc comment for affecting ESDoc. + * @ignore + * @extends {Ignored} + */ +var WithLatestFromSubscriber = (function (_super) { + __extends(WithLatestFromSubscriber, _super); + function WithLatestFromSubscriber(destination, observables, project) { + _super.call(this, destination); + this.observables = observables; + this.project = project; + this.toRespond = []; + var len = observables.length; + this.values = new Array(len); + for (var i = 0; i < len; i++) { + this.toRespond.push(i); + } + for (var i = 0; i < len; i++) { + var observable = observables[i]; + this.add(subscribeToResult_1.subscribeToResult(this, observable, observable, i)); + } + } + WithLatestFromSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { + this.values[outerIndex] = innerValue; + var toRespond = this.toRespond; + if (toRespond.length > 0) { + var found = toRespond.indexOf(outerIndex); + if (found !== -1) { + toRespond.splice(found, 1); + } + } + }; + WithLatestFromSubscriber.prototype.notifyComplete = function () { + // noop + }; + WithLatestFromSubscriber.prototype._next = function (value) { + if (this.toRespond.length === 0) { + var args = [value].concat(this.values); + if (this.project) { + this._tryProject(args); + } + else { + this.destination.next(args); + } + } + }; + WithLatestFromSubscriber.prototype._tryProject = function (args) { + var result; + try { + result = this.project.apply(this, args); + } + catch (err) { + this.destination.error(err); + return; + } + this.destination.next(result); + }; + return WithLatestFromSubscriber; +}(OuterSubscriber_1.OuterSubscriber)); +//# sourceMappingURL=withLatestFrom.js.map + +/***/ }), +/* 1 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var root_1 = __webpack_require__(7); +var toSubscriber_1 = __webpack_require__(103); +var observable_1 = __webpack_require__(45); +var pipe_1 = __webpack_require__(105); +/** + * A representation of any set of values over any amount of time. This is the most basic building block + * of RxJS. + * + * @class Observable + */ +var Observable = (function () { + /** + * @constructor + * @param {Function} subscribe the function that is called when the Observable is + * initially subscribed to. This function is given a Subscriber, to which new values + * can be `next`ed, or an `error` method can be called to raise an error, or + * `complete` can be called to notify of a successful completion. + */ + function Observable(subscribe) { + this._isScalar = false; + if (subscribe) { + this._subscribe = subscribe; + } + } + /** + * Creates a new Observable, with this Observable as the source, and the passed + * operator defined as the new observable's operator. + * @method lift + * @param {Operator} operator the operator defining the operation to take on the observable + * @return {Observable} a new observable with the Operator applied + */ + Observable.prototype.lift = function (operator) { + var observable = new Observable(); + observable.source = this; + observable.operator = operator; + return observable; + }; + /** + * Invokes an execution of an Observable and registers Observer handlers for notifications it will emit. + * + * Use it when you have all these Observables, but still nothing is happening. + * + * `subscribe` is not a regular operator, but a method that calls Observable's internal `subscribe` function. It + * might be for example a function that you passed to a {@link create} static factory, but most of the time it is + * a library implementation, which defines what and when will be emitted by an Observable. This means that calling + * `subscribe` is actually the moment when Observable starts its work, not when it is created, as it is often + * thought. + * + * Apart from starting the execution of an Observable, this method allows you to listen for values + * that an Observable emits, as well as for when it completes or errors. You can achieve this in two + * following ways. + * + * The first way is creating an object that implements {@link Observer} interface. It should have methods + * defined by that interface, but note that it should be just a regular JavaScript object, which you can create + * yourself in any way you want (ES6 class, classic function constructor, object literal etc.). In particular do + * not attempt to use any RxJS implementation details to create Observers - you don't need them. Remember also + * that your object does not have to implement all methods. If you find yourself creating a method that doesn't + * do anything, you can simply omit it. Note however, that if `error` method is not provided, all errors will + * be left uncaught. + * + * The second way is to give up on Observer object altogether and simply provide callback functions in place of its methods. + * This means you can provide three functions as arguments to `subscribe`, where first function is equivalent + * of a `next` method, second of an `error` method and third of a `complete` method. Just as in case of Observer, + * if you do not need to listen for something, you can omit a function, preferably by passing `undefined` or `null`, + * since `subscribe` recognizes these functions by where they were placed in function call. When it comes + * to `error` function, just as before, if not provided, errors emitted by an Observable will be thrown. + * + * Whatever style of calling `subscribe` you use, in both cases it returns a Subscription object. + * This object allows you to call `unsubscribe` on it, which in turn will stop work that an Observable does and will clean + * up all resources that an Observable used. Note that cancelling a subscription will not call `complete` callback + * provided to `subscribe` function, which is reserved for a regular completion signal that comes from an Observable. + * + * Remember that callbacks provided to `subscribe` are not guaranteed to be called asynchronously. + * It is an Observable itself that decides when these functions will be called. For example {@link of} + * by default emits all its values synchronously. Always check documentation for how given Observable + * will behave when subscribed and if its default behavior can be modified with a {@link Scheduler}. + * + * @example Subscribe with an Observer + * const sumObserver = { + * sum: 0, + * next(value) { + * console.log('Adding: ' + value); + * this.sum = this.sum + value; + * }, + * error() { // We actually could just remove this method, + * }, // since we do not really care about errors right now. + * complete() { + * console.log('Sum equals: ' + this.sum); + * } + * }; + * + * Rx.Observable.of(1, 2, 3) // Synchronously emits 1, 2, 3 and then completes. + * .subscribe(sumObserver); + * + * // Logs: + * // "Adding: 1" + * // "Adding: 2" + * // "Adding: 3" + * // "Sum equals: 6" + * + * + * @example Subscribe with functions + * let sum = 0; + * + * Rx.Observable.of(1, 2, 3) + * .subscribe( + * function(value) { + * console.log('Adding: ' + value); + * sum = sum + value; + * }, + * undefined, + * function() { + * console.log('Sum equals: ' + sum); + * } + * ); + * + * // Logs: + * // "Adding: 1" + * // "Adding: 2" + * // "Adding: 3" + * // "Sum equals: 6" + * + * + * @example Cancel a subscription + * const subscription = Rx.Observable.interval(1000).subscribe( + * num => console.log(num), + * undefined, + * () => console.log('completed!') // Will not be called, even + * ); // when cancelling subscription + * + * + * setTimeout(() => { + * subscription.unsubscribe(); + * console.log('unsubscribed!'); + * }, 2500); + * + * // Logs: + * // 0 after 1s + * // 1 after 2s + * // "unsubscribed!" after 2.5s + * + * + * @param {Observer|Function} observerOrNext (optional) Either an observer with methods to be called, + * or the first of three possible handlers, which is the handler for each value emitted from the subscribed + * Observable. + * @param {Function} error (optional) A handler for a terminal event resulting from an error. If no error handler is provided, + * the error will be thrown as unhandled. + * @param {Function} complete (optional) A handler for a terminal event resulting from successful completion. + * @return {ISubscription} a subscription reference to the registered handlers + * @method subscribe + */ + Observable.prototype.subscribe = function (observerOrNext, error, complete) { + var operator = this.operator; + var sink = toSubscriber_1.toSubscriber(observerOrNext, error, complete); + if (operator) { + operator.call(sink, this.source); + } + else { + sink.add(this.source || !sink.syncErrorThrowable ? this._subscribe(sink) : this._trySubscribe(sink)); + } + if (sink.syncErrorThrowable) { + sink.syncErrorThrowable = false; + if (sink.syncErrorThrown) { + throw sink.syncErrorValue; + } + } + return sink; + }; + Observable.prototype._trySubscribe = function (sink) { + try { + return this._subscribe(sink); + } + catch (err) { + sink.syncErrorThrown = true; + sink.syncErrorValue = err; + sink.error(err); + } + }; + /** + * @method forEach + * @param {Function} next a handler for each value emitted by the observable + * @param {PromiseConstructor} [PromiseCtor] a constructor function used to instantiate the Promise + * @return {Promise} a promise that either resolves on observable completion or + * rejects with the handled error + */ + Observable.prototype.forEach = function (next, PromiseCtor) { + var _this = this; + if (!PromiseCtor) { + if (root_1.root.Rx && root_1.root.Rx.config && root_1.root.Rx.config.Promise) { + PromiseCtor = root_1.root.Rx.config.Promise; + } + else if (root_1.root.Promise) { + PromiseCtor = root_1.root.Promise; + } + } + if (!PromiseCtor) { + throw new Error('no Promise impl found'); + } + return new PromiseCtor(function (resolve, reject) { + // Must be declared in a separate statement to avoid a RefernceError when + // accessing subscription below in the closure due to Temporal Dead Zone. + var subscription; + subscription = _this.subscribe(function (value) { + if (subscription) { + // if there is a subscription, then we can surmise + // the next handling is asynchronous. Any errors thrown + // need to be rejected explicitly and unsubscribe must be + // called manually + try { + next(value); + } + catch (err) { + reject(err); + subscription.unsubscribe(); + } + } + else { + // if there is NO subscription, then we're getting a nexted + // value synchronously during subscription. We can just call it. + // If it errors, Observable's `subscribe` will ensure the + // unsubscription logic is called, then synchronously rethrow the error. + // After that, Promise will trap the error and send it + // down the rejection path. + next(value); + } + }, reject, resolve); + }); + }; + /** @deprecated internal use only */ Observable.prototype._subscribe = function (subscriber) { + return this.source.subscribe(subscriber); + }; + /** + * An interop point defined by the es7-observable spec https://github.com/zenparsing/es-observable + * @method Symbol.observable + * @return {Observable} this instance of the observable + */ + Observable.prototype[observable_1.observable] = function () { + return this; + }; + /* tslint:enable:max-line-length */ + /** + * Used to stitch together functional operators into a chain. + * @method pipe + * @return {Observable} the Observable result of all of the operators having + * been called in the order they were passed in. + * + * @example + * + * import { map, filter, scan } from 'rxjs/operators'; + * + * Rx.Observable.interval(1000) + * .pipe( + * filter(x => x % 2 === 0), + * map(x => x + x), + * scan((acc, x) => acc + x) + * ) + * .subscribe(x => console.log(x)) + */ + Observable.prototype.pipe = function () { + var operations = []; + for (var _i = 0; _i < arguments.length; _i++) { + operations[_i - 0] = arguments[_i]; + } + if (operations.length === 0) { + return this; + } + return pipe_1.pipeFromArray(operations)(this); + }; + /* tslint:enable:max-line-length */ + Observable.prototype.toPromise = function (PromiseCtor) { + var _this = this; + if (!PromiseCtor) { + if (root_1.root.Rx && root_1.root.Rx.config && root_1.root.Rx.config.Promise) { + PromiseCtor = root_1.root.Rx.config.Promise; + } + else if (root_1.root.Promise) { + PromiseCtor = root_1.root.Promise; + } + } + if (!PromiseCtor) { + throw new Error('no Promise impl found'); + } + return new PromiseCtor(function (resolve, reject) { + var value; + _this.subscribe(function (x) { return value = x; }, function (err) { return reject(err); }, function () { return resolve(value); }); + }); + }; + // HACK: Since TypeScript inherits static properties too, we have to + // fight against TypeScript here so Subject can have a different static create signature + /** + * Creates a new cold Observable by calling the Observable constructor + * @static true + * @owner Observable + * @method create + * @param {Function} subscribe? the subscriber function to be passed to the Observable constructor + * @return {Observable} a new cold observable + */ + Observable.create = function (subscribe) { + return new Observable(subscribe); + }; + return Observable; +}()); +exports.Observable = Observable; +//# sourceMappingURL=Observable.js.map + +/***/ }), +/* 2 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var __extends = (this && this.__extends) || function (d, b) { + for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +}; +var Subscriber_1 = __webpack_require__(3); +/** + * Applies a given `project` function to each value emitted by the source + * Observable, and emits the resulting values as an Observable. + * + * Like [Array.prototype.map()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/map), + * it passes each source value through a transformation function to get + * corresponding output values. + * + * + * + * Similar to the well known `Array.prototype.map` function, this operator + * applies a projection to each value and emits that projection in the output + * Observable. + * + * @example Map every click to the clientX position of that click + * var clicks = Rx.Observable.fromEvent(document, 'click'); + * var positions = clicks.map(ev => ev.clientX); + * positions.subscribe(x => console.log(x)); + * + * @see {@link mapTo} + * @see {@link pluck} + * + * @param {function(value: T, index: number): R} project The function to apply + * to each `value` emitted by the source Observable. The `index` parameter is + * the number `i` for the i-th emission that has happened since the + * subscription, starting from the number `0`. + * @param {any} [thisArg] An optional argument to define what `this` is in the + * `project` function. + * @return {Observable} An Observable that emits the values from the source + * Observable transformed by the given `project` function. + * @method map + * @owner Observable + */ +function map(project, thisArg) { + return function mapOperation(source) { + if (typeof project !== 'function') { + throw new TypeError('argument is not a function. Are you looking for `mapTo()`?'); + } + return source.lift(new MapOperator(project, thisArg)); + }; +} +exports.map = map; +var MapOperator = (function () { + function MapOperator(project, thisArg) { + this.project = project; + this.thisArg = thisArg; + } + MapOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new MapSubscriber(subscriber, this.project, this.thisArg)); + }; + return MapOperator; +}()); +exports.MapOperator = MapOperator; +/** + * We need this JSDoc comment for affecting ESDoc. + * @ignore + * @extends {Ignored} + */ +var MapSubscriber = (function (_super) { + __extends(MapSubscriber, _super); + function MapSubscriber(destination, project, thisArg) { + _super.call(this, destination); + this.project = project; + this.count = 0; + this.thisArg = thisArg || this; + } + // NOTE: This looks unoptimized, but it's actually purposefully NOT + // using try/catch optimizations. + MapSubscriber.prototype._next = function (value) { + var result; + try { + result = this.project.call(this.thisArg, value, this.count++); + } + catch (err) { + this.destination.error(err); + return; + } + this.destination.next(result); + }; + return MapSubscriber; +}(Subscriber_1.Subscriber)); +//# sourceMappingURL=map.js.map + +/***/ }), +/* 3 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var __extends = (this && this.__extends) || function (d, b) { + for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +}; +var isFunction_1 = __webpack_require__(42); +var Subscription_1 = __webpack_require__(12); +var Observer_1 = __webpack_require__(57); +var rxSubscriber_1 = __webpack_require__(44); +/** + * Implements the {@link Observer} interface and extends the + * {@link Subscription} class. While the {@link Observer} is the public API for + * consuming the values of an {@link Observable}, all Observers get converted to + * a Subscriber, in order to provide Subscription-like capabilities such as + * `unsubscribe`. Subscriber is a common type in RxJS, and crucial for + * implementing operators, but it is rarely used as a public API. + * + * @class Subscriber + */ +var Subscriber = (function (_super) { + __extends(Subscriber, _super); + /** + * @param {Observer|function(value: T): void} [destinationOrNext] A partially + * defined Observer or a `next` callback function. + * @param {function(e: ?any): void} [error] The `error` callback of an + * Observer. + * @param {function(): void} [complete] The `complete` callback of an + * Observer. + */ + function Subscriber(destinationOrNext, error, complete) { + _super.call(this); + this.syncErrorValue = null; + this.syncErrorThrown = false; + this.syncErrorThrowable = false; + this.isStopped = false; + switch (arguments.length) { + case 0: + this.destination = Observer_1.empty; + break; + case 1: + if (!destinationOrNext) { + this.destination = Observer_1.empty; + break; + } + if (typeof destinationOrNext === 'object') { + // HACK(benlesh): To resolve an issue where Node users may have multiple + // copies of rxjs in their node_modules directory. + if (isTrustedSubscriber(destinationOrNext)) { + var trustedSubscriber = destinationOrNext[rxSubscriber_1.rxSubscriber](); + this.syncErrorThrowable = trustedSubscriber.syncErrorThrowable; + this.destination = trustedSubscriber; + trustedSubscriber.add(this); + } + else { + this.syncErrorThrowable = true; + this.destination = new SafeSubscriber(this, destinationOrNext); + } + break; + } + default: + this.syncErrorThrowable = true; + this.destination = new SafeSubscriber(this, destinationOrNext, error, complete); + break; + } + } + Subscriber.prototype[rxSubscriber_1.rxSubscriber] = function () { return this; }; + /** + * A static factory for a Subscriber, given a (potentially partial) definition + * of an Observer. + * @param {function(x: ?T): void} [next] The `next` callback of an Observer. + * @param {function(e: ?any): void} [error] The `error` callback of an + * Observer. + * @param {function(): void} [complete] The `complete` callback of an + * Observer. + * @return {Subscriber} A Subscriber wrapping the (partially defined) + * Observer represented by the given arguments. + */ + Subscriber.create = function (next, error, complete) { + var subscriber = new Subscriber(next, error, complete); + subscriber.syncErrorThrowable = false; + return subscriber; + }; + /** + * The {@link Observer} callback to receive notifications of type `next` from + * the Observable, with a value. The Observable may call this method 0 or more + * times. + * @param {T} [value] The `next` value. + * @return {void} + */ + Subscriber.prototype.next = function (value) { + if (!this.isStopped) { + this._next(value); + } + }; + /** + * The {@link Observer} callback to receive notifications of type `error` from + * the Observable, with an attached {@link Error}. Notifies the Observer that + * the Observable has experienced an error condition. + * @param {any} [err] The `error` exception. + * @return {void} + */ + Subscriber.prototype.error = function (err) { + if (!this.isStopped) { + this.isStopped = true; + this._error(err); + } + }; + /** + * The {@link Observer} callback to receive a valueless notification of type + * `complete` from the Observable. Notifies the Observer that the Observable + * has finished sending push-based notifications. + * @return {void} + */ + Subscriber.prototype.complete = function () { + if (!this.isStopped) { + this.isStopped = true; + this._complete(); + } + }; + Subscriber.prototype.unsubscribe = function () { + if (this.closed) { + return; + } + this.isStopped = true; + _super.prototype.unsubscribe.call(this); + }; + Subscriber.prototype._next = function (value) { + this.destination.next(value); + }; + Subscriber.prototype._error = function (err) { + this.destination.error(err); + this.unsubscribe(); + }; + Subscriber.prototype._complete = function () { + this.destination.complete(); + this.unsubscribe(); + }; + /** @deprecated internal use only */ Subscriber.prototype._unsubscribeAndRecycle = function () { + var _a = this, _parent = _a._parent, _parents = _a._parents; + this._parent = null; + this._parents = null; + this.unsubscribe(); + this.closed = false; + this.isStopped = false; + this._parent = _parent; + this._parents = _parents; + return this; + }; + return Subscriber; +}(Subscription_1.Subscription)); +exports.Subscriber = Subscriber; +/** + * We need this JSDoc comment for affecting ESDoc. + * @ignore + * @extends {Ignored} + */ +var SafeSubscriber = (function (_super) { + __extends(SafeSubscriber, _super); + function SafeSubscriber(_parentSubscriber, observerOrNext, error, complete) { + _super.call(this); + this._parentSubscriber = _parentSubscriber; + var next; + var context = this; + if (isFunction_1.isFunction(observerOrNext)) { + next = observerOrNext; + } + else if (observerOrNext) { + next = observerOrNext.next; + error = observerOrNext.error; + complete = observerOrNext.complete; + if (observerOrNext !== Observer_1.empty) { + context = Object.create(observerOrNext); + if (isFunction_1.isFunction(context.unsubscribe)) { + this.add(context.unsubscribe.bind(context)); + } + context.unsubscribe = this.unsubscribe.bind(this); + } + } + this._context = context; + this._next = next; + this._error = error; + this._complete = complete; + } + SafeSubscriber.prototype.next = function (value) { + if (!this.isStopped && this._next) { + var _parentSubscriber = this._parentSubscriber; + if (!_parentSubscriber.syncErrorThrowable) { + this.__tryOrUnsub(this._next, value); + } + else if (this.__tryOrSetError(_parentSubscriber, this._next, value)) { + this.unsubscribe(); + } + } + }; + SafeSubscriber.prototype.error = function (err) { + if (!this.isStopped) { + var _parentSubscriber = this._parentSubscriber; + if (this._error) { + if (!_parentSubscriber.syncErrorThrowable) { + this.__tryOrUnsub(this._error, err); + this.unsubscribe(); + } + else { + this.__tryOrSetError(_parentSubscriber, this._error, err); + this.unsubscribe(); + } + } + else if (!_parentSubscriber.syncErrorThrowable) { + this.unsubscribe(); + throw err; + } + else { + _parentSubscriber.syncErrorValue = err; + _parentSubscriber.syncErrorThrown = true; + this.unsubscribe(); + } + } + }; + SafeSubscriber.prototype.complete = function () { + var _this = this; + if (!this.isStopped) { + var _parentSubscriber = this._parentSubscriber; + if (this._complete) { + var wrappedComplete = function () { return _this._complete.call(_this._context); }; + if (!_parentSubscriber.syncErrorThrowable) { + this.__tryOrUnsub(wrappedComplete); + this.unsubscribe(); + } + else { + this.__tryOrSetError(_parentSubscriber, wrappedComplete); + this.unsubscribe(); + } + } + else { + this.unsubscribe(); + } + } + }; + SafeSubscriber.prototype.__tryOrUnsub = function (fn, value) { + try { + fn.call(this._context, value); + } + catch (err) { + this.unsubscribe(); + throw err; + } + }; + SafeSubscriber.prototype.__tryOrSetError = function (parent, fn, value) { + try { + fn.call(this._context, value); + } + catch (err) { + parent.syncErrorValue = err; + parent.syncErrorThrown = true; + return true; + } + return false; + }; + /** @deprecated internal use only */ SafeSubscriber.prototype._unsubscribe = function () { + var _parentSubscriber = this._parentSubscriber; + this._context = null; + this._parentSubscriber = null; + _parentSubscriber.unsubscribe(); + }; + return SafeSubscriber; +}(Subscriber)); +function isTrustedSubscriber(obj) { + return obj instanceof Subscriber || ('syncErrorThrowable' in obj && obj[rxSubscriber_1.rxSubscriber]); +} +//# sourceMappingURL=Subscriber.js.map + +/***/ }), +/* 4 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var __extends = (this && this.__extends) || function (d, b) { + for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +}; +var Subscriber_1 = __webpack_require__(3); +/* tslint:enable:max-line-length */ +/** + * Filter items emitted by the source Observable by only emitting those that + * satisfy a specified predicate. + * + * Like + * [Array.prototype.filter()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/filter), + * it only emits a value from the source if it passes a criterion function. + * + * + * + * Similar to the well-known `Array.prototype.filter` method, this operator + * takes values from the source Observable, passes them through a `predicate` + * function and only emits those values that yielded `true`. + * + * @example Emit only click events whose target was a DIV element + * var clicks = Rx.Observable.fromEvent(document, 'click'); + * var clicksOnDivs = clicks.filter(ev => ev.target.tagName === 'DIV'); + * clicksOnDivs.subscribe(x => console.log(x)); + * + * @see {@link distinct} + * @see {@link distinctUntilChanged} + * @see {@link distinctUntilKeyChanged} + * @see {@link ignoreElements} + * @see {@link partition} + * @see {@link skip} + * + * @param {function(value: T, index: number): boolean} predicate A function that + * evaluates each value emitted by the source Observable. If it returns `true`, + * the value is emitted, if `false` the value is not passed to the output + * Observable. The `index` parameter is the number `i` for the i-th source + * emission that has happened since the subscription, starting from the number + * `0`. + * @param {any} [thisArg] An optional argument to determine the value of `this` + * in the `predicate` function. + * @return {Observable} An Observable of values from the source that were + * allowed by the `predicate` function. + * @method filter + * @owner Observable + */ +function filter(predicate, thisArg) { + return function filterOperatorFunction(source) { + return source.lift(new FilterOperator(predicate, thisArg)); + }; +} +exports.filter = filter; +var FilterOperator = (function () { + function FilterOperator(predicate, thisArg) { + this.predicate = predicate; + this.thisArg = thisArg; + } + FilterOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new FilterSubscriber(subscriber, this.predicate, this.thisArg)); + }; + return FilterOperator; +}()); +/** + * We need this JSDoc comment for affecting ESDoc. + * @ignore + * @extends {Ignored} + */ +var FilterSubscriber = (function (_super) { + __extends(FilterSubscriber, _super); + function FilterSubscriber(destination, predicate, thisArg) { + _super.call(this, destination); + this.predicate = predicate; + this.thisArg = thisArg; + this.count = 0; + } + // the try catch block below is left specifically for + // optimization and perf reasons. a tryCatcher is not necessary here. + FilterSubscriber.prototype._next = function (value) { + var result; + try { + result = this.predicate.call(this.thisArg, value, this.count++); + } + catch (err) { + this.destination.error(err); + return; + } + if (result) { + this.destination.next(value); + } + }; + return FilterSubscriber; +}(Subscriber_1.Subscriber)); +//# sourceMappingURL=filter.js.map + +/***/ }), +/* 5 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var __extends = (this && this.__extends) || function (d, b) { + for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +}; +var Subscriber_1 = __webpack_require__(3); +/* tslint:enable:max-line-length */ +/** + * Perform a side effect for every emission on the source Observable, but return + * an Observable that is identical to the source. + * + * Intercepts each emission on the source and runs a + * function, but returns an output which is identical to the source as long as errors don't occur. + * + * + * + * Returns a mirrored Observable of the source Observable, but modified so that + * the provided Observer is called to perform a side effect for every value, + * error, and completion emitted by the source. Any errors that are thrown in + * the aforementioned Observer or handlers are safely sent down the error path + * of the output Observable. + * + * This operator is useful for debugging your Observables for the correct values + * or performing other side effects. + * + * Note: this is different to a `subscribe` on the Observable. If the Observable + * returned by `do` is not subscribed, the side effects specified by the + * Observer will never happen. `do` therefore simply spies on existing + * execution, it does not trigger an execution to happen like `subscribe` does. + * + * @example Map every click to the clientX position of that click, while also logging the click event + * var clicks = Rx.Observable.fromEvent(document, 'click'); + * var positions = clicks + * .do(ev => console.log(ev)) + * .map(ev => ev.clientX); + * positions.subscribe(x => console.log(x)); + * + * @see {@link map} + * @see {@link subscribe} + * + * @param {Observer|function} [nextOrObserver] A normal Observer object or a + * callback for `next`. + * @param {function} [error] Callback for errors in the source. + * @param {function} [complete] Callback for the completion of the source. + * @return {Observable} An Observable identical to the source, but runs the + * specified Observer or callback(s) for each item. + * @name tap + */ +function tap(nextOrObserver, error, complete) { + return function tapOperatorFunction(source) { + return source.lift(new DoOperator(nextOrObserver, error, complete)); + }; +} +exports.tap = tap; +var DoOperator = (function () { + function DoOperator(nextOrObserver, error, complete) { + this.nextOrObserver = nextOrObserver; + this.error = error; + this.complete = complete; + } + DoOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new DoSubscriber(subscriber, this.nextOrObserver, this.error, this.complete)); + }; + return DoOperator; +}()); +/** + * We need this JSDoc comment for affecting ESDoc. + * @ignore + * @extends {Ignored} + */ +var DoSubscriber = (function (_super) { + __extends(DoSubscriber, _super); + function DoSubscriber(destination, nextOrObserver, error, complete) { + _super.call(this, destination); + var safeSubscriber = new Subscriber_1.Subscriber(nextOrObserver, error, complete); + safeSubscriber.syncErrorThrowable = true; + this.add(safeSubscriber); + this.safeSubscriber = safeSubscriber; + } + DoSubscriber.prototype._next = function (value) { + var safeSubscriber = this.safeSubscriber; + safeSubscriber.next(value); + if (safeSubscriber.syncErrorThrown) { + this.destination.error(safeSubscriber.syncErrorValue); + } + else { + this.destination.next(value); + } + }; + DoSubscriber.prototype._error = function (err) { + var safeSubscriber = this.safeSubscriber; + safeSubscriber.error(err); + if (safeSubscriber.syncErrorThrown) { + this.destination.error(safeSubscriber.syncErrorValue); + } + else { + this.destination.error(err); + } + }; + DoSubscriber.prototype._complete = function () { + var safeSubscriber = this.safeSubscriber; + safeSubscriber.complete(); + if (safeSubscriber.syncErrorThrown) { + this.destination.error(safeSubscriber.syncErrorValue); + } + else { + this.destination.complete(); + } + }; + return DoSubscriber; +}(Subscriber_1.Subscriber)); +//# sourceMappingURL=tap.js.map + +/***/ }), +/* 6 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var map_1 = __webpack_require__(2); +/** + * Maps each source value (an object) to its specified nested property. + * + * Like {@link map}, but meant only for picking one of + * the nested properties of every emitted object. + * + * + * + * Given a list of strings describing a path to an object property, retrieves + * the value of a specified nested property from all values in the source + * Observable. If a property can't be resolved, it will return `undefined` for + * that value. + * + * @example Map every click to the tagName of the clicked target element + * var clicks = Rx.Observable.fromEvent(document, 'click'); + * var tagNames = clicks.pluck('target', 'tagName'); + * tagNames.subscribe(x => console.log(x)); + * + * @see {@link map} + * + * @param {...string} properties The nested properties to pluck from each source + * value (an object). + * @return {Observable} A new Observable of property values from the source values. + * @method pluck + * @owner Observable + */ +function pluck() { + var properties = []; + for (var _i = 0; _i < arguments.length; _i++) { + properties[_i - 0] = arguments[_i]; + } + var length = properties.length; + if (length === 0) { + throw new Error('list of properties cannot be empty.'); + } + return function (source) { return map_1.map(plucker(properties, length))(source); }; +} +exports.pluck = pluck; +function plucker(props, length) { + var mapper = function (x) { + var currentProp = x; + for (var i = 0; i < length; i++) { + var p = currentProp[props[i]]; + if (typeof p !== 'undefined') { + currentProp = p; + } + else { + return undefined; + } + } + return currentProp; + }; + return mapper; +} +//# sourceMappingURL=pluck.js.map + +/***/ }), +/* 7 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(global) { +// CommonJS / Node have global context exposed as "global" variable. +// We don't want to include the whole node.d.ts this this compilation unit so we'll just fake +// the global "global" var for now. +var __window = typeof window !== 'undefined' && window; +var __self = typeof self !== 'undefined' && typeof WorkerGlobalScope !== 'undefined' && + self instanceof WorkerGlobalScope && self; +var __global = typeof global !== 'undefined' && global; +var _root = __window || __global || __self; +exports.root = _root; +// Workaround Closure Compiler restriction: The body of a goog.module cannot use throw. +// This is needed when used with angular/tsickle which inserts a goog.module statement. +// Wrap in IIFE +(function () { + if (!_root) { + throw new Error('RxJS could not find any global context (window, self, global)'); + } +})(); +//# sourceMappingURL=root.js.map +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(24))) + +/***/ }), +/* 8 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +Object.defineProperty(exports, "__esModule", { value: true }); +var _a; +var BehaviorSubject_1 = __webpack_require__(13); +var set_options_effect_1 = __webpack_require__(53); +var file_reload_effect_1 = __webpack_require__(86); +var browser_set_location_effect_1 = __webpack_require__(89); +var simulate_click_effect_1 = __webpack_require__(90); +var set_element_value_effect_1 = __webpack_require__(91); +var set_element_toggle_value_effect_1 = __webpack_require__(92); +var set_scroll_1 = __webpack_require__(153); +var browser_reload_effect_1 = __webpack_require__(93); +var EffectNames; +(function (EffectNames) { + EffectNames["FileReload"] = "@@FileReload"; + EffectNames["PreBrowserReload"] = "@@PreBrowserReload"; + EffectNames["BrowserReload"] = "@@BrowserReload"; + EffectNames["BrowserSetLocation"] = "@@BrowserSetLocation"; + EffectNames["BrowserSetScroll"] = "@@BrowserSetScroll"; + EffectNames["SetOptions"] = "@@SetOptions"; + EffectNames["SimulateClick"] = "@@SimulateClick"; + EffectNames["SetElementValue"] = "@@SetElementValue"; + EffectNames["SetElementToggleValue"] = "@@SetElementToggleValue"; +})(EffectNames = exports.EffectNames || (exports.EffectNames = {})); +exports.effectOutputHandlers$ = new BehaviorSubject_1.BehaviorSubject((_a = {}, + _a[EffectNames.SetOptions] = set_options_effect_1.setOptionsEffect, + _a[EffectNames.FileReload] = file_reload_effect_1.fileReloadEffect, + _a[EffectNames.BrowserReload] = browser_reload_effect_1.browserReloadEffect, + _a[EffectNames.BrowserSetLocation] = browser_set_location_effect_1.browserSetLocationEffect, + _a[EffectNames.SimulateClick] = simulate_click_effect_1.simulateClickEffect, + _a[EffectNames.SetElementValue] = set_element_value_effect_1.setElementValueEffect, + _a[EffectNames.SetElementToggleValue] = set_element_toggle_value_effect_1.setElementToggleValueEffect, + _a[EffectNames.BrowserSetScroll] = set_scroll_1.setScrollEffect, + _a)); + + +/***/ }), +/* 9 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var ArrayObservable_1 = __webpack_require__(23); +exports.of = ArrayObservable_1.ArrayObservable.of; +//# sourceMappingURL=of.js.map + +/***/ }), +/* 10 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var __assign = (this && this.__assign) || function () { + __assign = Object.assign || function(t) { + for (var s, i = 1, n = arguments.length; i < n; i++) { + s = arguments[i]; + for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) + t[p] = s[p]; + } + return t; + }; + return __assign.apply(this, arguments); +}; +Object.defineProperty(exports, "__esModule", { value: true }); +var _a; +var BehaviorSubject_1 = __webpack_require__(13); +var withLatestFrom_1 = __webpack_require__(0); +var ignoreElements_1 = __webpack_require__(11); +var tap_1 = __webpack_require__(5); +var pluck_1 = __webpack_require__(6); +var ScrollEvent_1 = __webpack_require__(85); +var ClickEvent_1 = __webpack_require__(94); +var KeyupEvent_1 = __webpack_require__(95); +var BrowserNotify_1 = __webpack_require__(156); +var BrowserLocation_1 = __webpack_require__(157); +var BrowserReload_1 = __webpack_require__(96); +var FileReload_1 = __webpack_require__(165); +var Connection_1 = __webpack_require__(166); +var Disconnect_1 = __webpack_require__(167); +var FormToggleEvent_1 = __webpack_require__(98); +var OptionsSet_1 = __webpack_require__(168); +var IncomingSocketNames; +(function (IncomingSocketNames) { + IncomingSocketNames["Connection"] = "connection"; + IncomingSocketNames["Disconnect"] = "disconnect"; + IncomingSocketNames["FileReload"] = "file:reload"; + IncomingSocketNames["BrowserReload"] = "browser:reload"; + IncomingSocketNames["BrowserLocation"] = "browser:location"; + IncomingSocketNames["BrowserNotify"] = "browser:notify"; + IncomingSocketNames["Scroll"] = "scroll"; + IncomingSocketNames["Click"] = "click"; + IncomingSocketNames["Keyup"] = "input:text"; + IncomingSocketNames["InputToggle"] = "input:toggles"; + IncomingSocketNames["OptionsSet"] = "options:set"; +})(IncomingSocketNames = exports.IncomingSocketNames || (exports.IncomingSocketNames = {})); +var OutgoingSocketEvents; +(function (OutgoingSocketEvents) { + OutgoingSocketEvents["Scroll"] = "@@outgoing/scroll"; + OutgoingSocketEvents["Click"] = "@@outgoing/click"; + OutgoingSocketEvents["Keyup"] = "@@outgoing/keyup"; + OutgoingSocketEvents["InputToggle"] = "@@outgoing/Toggle"; +})(OutgoingSocketEvents = exports.OutgoingSocketEvents || (exports.OutgoingSocketEvents = {})); +exports.socketHandlers$ = new BehaviorSubject_1.BehaviorSubject((_a = {}, + _a[IncomingSocketNames.Connection] = Connection_1.incomingConnection, + _a[IncomingSocketNames.Disconnect] = Disconnect_1.incomingDisconnect, + _a[IncomingSocketNames.FileReload] = FileReload_1.incomingFileReload, + _a[IncomingSocketNames.BrowserReload] = BrowserReload_1.incomingBrowserReload, + _a[IncomingSocketNames.BrowserLocation] = BrowserLocation_1.incomingBrowserLocation, + _a[IncomingSocketNames.BrowserNotify] = BrowserNotify_1.incomingBrowserNotify, + _a[IncomingSocketNames.Scroll] = ScrollEvent_1.incomingScrollHandler, + _a[IncomingSocketNames.Click] = ClickEvent_1.incomingHandler$, + _a[IncomingSocketNames.Keyup] = KeyupEvent_1.incomingKeyupHandler, + _a[IncomingSocketNames.InputToggle] = FormToggleEvent_1.incomingInputsToggles, + _a[IncomingSocketNames.OptionsSet] = OptionsSet_1.incomingOptionsSet, + _a[OutgoingSocketEvents.Scroll] = emitWithPathname(IncomingSocketNames.Scroll), + _a[OutgoingSocketEvents.Click] = emitWithPathname(IncomingSocketNames.Click), + _a[OutgoingSocketEvents.Keyup] = emitWithPathname(IncomingSocketNames.Keyup), + _a[OutgoingSocketEvents.InputToggle] = emitWithPathname(IncomingSocketNames.InputToggle), + _a)); +function emitWithPathname(name) { + return function (xs, inputs) { + return xs.pipe(withLatestFrom_1.withLatestFrom(inputs.io$, inputs.window$.pipe(pluck_1.pluck("location", "pathname"))), tap_1.tap(function (_a) { + var event = _a[0], io = _a[1], pathname = _a[2]; + return io.emit(name, __assign({}, event, { pathname: pathname })); + }), ignoreElements_1.ignoreElements()); + }; +} + + +/***/ }), +/* 11 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var __extends = (this && this.__extends) || function (d, b) { + for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +}; +var Subscriber_1 = __webpack_require__(3); +var noop_1 = __webpack_require__(58); +/** + * Ignores all items emitted by the source Observable and only passes calls of `complete` or `error`. + * + * + * + * @return {Observable} An empty Observable that only calls `complete` + * or `error`, based on which one is called by the source Observable. + * @method ignoreElements + * @owner Observable + */ +function ignoreElements() { + return function ignoreElementsOperatorFunction(source) { + return source.lift(new IgnoreElementsOperator()); + }; +} +exports.ignoreElements = ignoreElements; +var IgnoreElementsOperator = (function () { + function IgnoreElementsOperator() { + } + IgnoreElementsOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new IgnoreElementsSubscriber(subscriber)); + }; + return IgnoreElementsOperator; +}()); +/** + * We need this JSDoc comment for affecting ESDoc. + * @ignore + * @extends {Ignored} + */ +var IgnoreElementsSubscriber = (function (_super) { + __extends(IgnoreElementsSubscriber, _super); + function IgnoreElementsSubscriber() { + _super.apply(this, arguments); + } + IgnoreElementsSubscriber.prototype._next = function (unused) { + noop_1.noop(); + }; + return IgnoreElementsSubscriber; +}(Subscriber_1.Subscriber)); +//# sourceMappingURL=ignoreElements.js.map + +/***/ }), +/* 12 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var isArray_1 = __webpack_require__(26); +var isObject_1 = __webpack_require__(56); +var isFunction_1 = __webpack_require__(42); +var tryCatch_1 = __webpack_require__(43); +var errorObject_1 = __webpack_require__(27); +var UnsubscriptionError_1 = __webpack_require__(104); +/** + * Represents a disposable resource, such as the execution of an Observable. A + * Subscription has one important method, `unsubscribe`, that takes no argument + * and just disposes the resource held by the subscription. + * + * Additionally, subscriptions may be grouped together through the `add()` + * method, which will attach a child Subscription to the current Subscription. + * When a Subscription is unsubscribed, all its children (and its grandchildren) + * will be unsubscribed as well. + * + * @class Subscription + */ +var Subscription = (function () { + /** + * @param {function(): void} [unsubscribe] A function describing how to + * perform the disposal of resources when the `unsubscribe` method is called. + */ + function Subscription(unsubscribe) { + /** + * A flag to indicate whether this Subscription has already been unsubscribed. + * @type {boolean} + */ + this.closed = false; + this._parent = null; + this._parents = null; + this._subscriptions = null; + if (unsubscribe) { + this._unsubscribe = unsubscribe; + } + } + /** + * Disposes the resources held by the subscription. May, for instance, cancel + * an ongoing Observable execution or cancel any other type of work that + * started when the Subscription was created. + * @return {void} + */ + Subscription.prototype.unsubscribe = function () { + var hasErrors = false; + var errors; + if (this.closed) { + return; + } + var _a = this, _parent = _a._parent, _parents = _a._parents, _unsubscribe = _a._unsubscribe, _subscriptions = _a._subscriptions; + this.closed = true; + this._parent = null; + this._parents = null; + // null out _subscriptions first so any child subscriptions that attempt + // to remove themselves from this subscription will noop + this._subscriptions = null; + var index = -1; + var len = _parents ? _parents.length : 0; + // if this._parent is null, then so is this._parents, and we + // don't have to remove ourselves from any parent subscriptions. + while (_parent) { + _parent.remove(this); + // if this._parents is null or index >= len, + // then _parent is set to null, and the loop exits + _parent = ++index < len && _parents[index] || null; + } + if (isFunction_1.isFunction(_unsubscribe)) { + var trial = tryCatch_1.tryCatch(_unsubscribe).call(this); + if (trial === errorObject_1.errorObject) { + hasErrors = true; + errors = errors || (errorObject_1.errorObject.e instanceof UnsubscriptionError_1.UnsubscriptionError ? + flattenUnsubscriptionErrors(errorObject_1.errorObject.e.errors) : [errorObject_1.errorObject.e]); + } + } + if (isArray_1.isArray(_subscriptions)) { + index = -1; + len = _subscriptions.length; + while (++index < len) { + var sub = _subscriptions[index]; + if (isObject_1.isObject(sub)) { + var trial = tryCatch_1.tryCatch(sub.unsubscribe).call(sub); + if (trial === errorObject_1.errorObject) { + hasErrors = true; + errors = errors || []; + var err = errorObject_1.errorObject.e; + if (err instanceof UnsubscriptionError_1.UnsubscriptionError) { + errors = errors.concat(flattenUnsubscriptionErrors(err.errors)); + } + else { + errors.push(err); + } + } + } + } + } + if (hasErrors) { + throw new UnsubscriptionError_1.UnsubscriptionError(errors); + } + }; + /** + * Adds a tear down to be called during the unsubscribe() of this + * Subscription. + * + * If the tear down being added is a subscription that is already + * unsubscribed, is the same reference `add` is being called on, or is + * `Subscription.EMPTY`, it will not be added. + * + * If this subscription is already in an `closed` state, the passed + * tear down logic will be executed immediately. + * + * @param {TeardownLogic} teardown The additional logic to execute on + * teardown. + * @return {Subscription} Returns the Subscription used or created to be + * added to the inner subscriptions list. This Subscription can be used with + * `remove()` to remove the passed teardown logic from the inner subscriptions + * list. + */ + Subscription.prototype.add = function (teardown) { + if (!teardown || (teardown === Subscription.EMPTY)) { + return Subscription.EMPTY; + } + if (teardown === this) { + return this; + } + var subscription = teardown; + switch (typeof teardown) { + case 'function': + subscription = new Subscription(teardown); + case 'object': + if (subscription.closed || typeof subscription.unsubscribe !== 'function') { + return subscription; + } + else if (this.closed) { + subscription.unsubscribe(); + return subscription; + } + else if (typeof subscription._addParent !== 'function' /* quack quack */) { + var tmp = subscription; + subscription = new Subscription(); + subscription._subscriptions = [tmp]; + } + break; + default: + throw new Error('unrecognized teardown ' + teardown + ' added to Subscription.'); + } + var subscriptions = this._subscriptions || (this._subscriptions = []); + subscriptions.push(subscription); + subscription._addParent(this); + return subscription; + }; + /** + * Removes a Subscription from the internal list of subscriptions that will + * unsubscribe during the unsubscribe process of this Subscription. + * @param {Subscription} subscription The subscription to remove. + * @return {void} + */ + Subscription.prototype.remove = function (subscription) { + var subscriptions = this._subscriptions; + if (subscriptions) { + var subscriptionIndex = subscriptions.indexOf(subscription); + if (subscriptionIndex !== -1) { + subscriptions.splice(subscriptionIndex, 1); + } + } + }; + Subscription.prototype._addParent = function (parent) { + var _a = this, _parent = _a._parent, _parents = _a._parents; + if (!_parent || _parent === parent) { + // If we don't have a parent, or the new parent is the same as the + // current parent, then set this._parent to the new parent. + this._parent = parent; + } + else if (!_parents) { + // If there's already one parent, but not multiple, allocate an Array to + // store the rest of the parent Subscriptions. + this._parents = [parent]; + } + else if (_parents.indexOf(parent) === -1) { + // Only add the new parent to the _parents list if it's not already there. + _parents.push(parent); + } + }; + Subscription.EMPTY = (function (empty) { + empty.closed = true; + return empty; + }(new Subscription())); + return Subscription; +}()); +exports.Subscription = Subscription; +function flattenUnsubscriptionErrors(errors) { + return errors.reduce(function (errs, err) { return errs.concat((err instanceof UnsubscriptionError_1.UnsubscriptionError) ? err.errors : err); }, []); +} +//# sourceMappingURL=Subscription.js.map + +/***/ }), +/* 13 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var __extends = (this && this.__extends) || function (d, b) { + for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +}; +var Subject_1 = __webpack_require__(37); +var ObjectUnsubscribedError_1 = __webpack_require__(73); +/** + * @class BehaviorSubject + */ +var BehaviorSubject = (function (_super) { + __extends(BehaviorSubject, _super); + function BehaviorSubject(_value) { + _super.call(this); + this._value = _value; + } + Object.defineProperty(BehaviorSubject.prototype, "value", { + get: function () { + return this.getValue(); + }, + enumerable: true, + configurable: true + }); + /** @deprecated internal use only */ BehaviorSubject.prototype._subscribe = function (subscriber) { + var subscription = _super.prototype._subscribe.call(this, subscriber); + if (subscription && !subscription.closed) { + subscriber.next(this._value); + } + return subscription; + }; + BehaviorSubject.prototype.getValue = function () { + if (this.hasError) { + throw this.thrownError; + } + else if (this.closed) { + throw new ObjectUnsubscribedError_1.ObjectUnsubscribedError(); + } + else { + return this._value; + } + }; + BehaviorSubject.prototype.next = function (value) { + _super.prototype.next.call(this, this._value = value); + }; + return BehaviorSubject; +}(Subject_1.Subject)); +exports.BehaviorSubject = BehaviorSubject; +//# sourceMappingURL=BehaviorSubject.js.map + +/***/ }), +/* 14 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +Object.defineProperty(exports, "__esModule", { value: true }); +var _a; +var BehaviorSubject_1 = __webpack_require__(13); +var timer_1 = __webpack_require__(52); +var of_1 = __webpack_require__(9); +var logger_1 = __webpack_require__(142); +var filter_1 = __webpack_require__(4); +var tap_1 = __webpack_require__(5); +var withLatestFrom_1 = __webpack_require__(0); +var switchMap_1 = __webpack_require__(20); +var pluck_1 = __webpack_require__(6); +function initLogger(options) { + var log = new logger_1.Nanologger(options.logPrefix || "", { + colors: { magenta: "#0F2634" } + }); + return of_1.of(log); +} +exports.initLogger = initLogger; +var LogNames; +(function (LogNames) { + LogNames["Log"] = "@@Log"; + LogNames["Info"] = "@@Log.info"; + LogNames["Debug"] = "@@Log.debug"; +})(LogNames = exports.LogNames || (exports.LogNames = {})); +var Overlay; +(function (Overlay) { + Overlay["Info"] = "@@Overlay.info"; +})(Overlay = exports.Overlay || (exports.Overlay = {})); +function consoleInfo() { + var args = []; + for (var _i = 0; _i < arguments.length; _i++) { + args[_i] = arguments[_i]; + } + return [LogNames.Log, [LogNames.Info, args]]; +} +exports.consoleInfo = consoleInfo; +function consoleDebug() { + var args = []; + for (var _i = 0; _i < arguments.length; _i++) { + args[_i] = arguments[_i]; + } + return [LogNames.Log, [LogNames.Debug, args]]; +} +exports.consoleDebug = consoleDebug; +function overlayInfo(message, timeout) { + if (timeout === void 0) { timeout = 2000; } + return [Overlay.Info, [message, timeout]]; +} +exports.overlayInfo = overlayInfo; +exports.logHandler$ = new BehaviorSubject_1.BehaviorSubject((_a = {}, + _a[LogNames.Log] = function (xs, inputs) { + return xs.pipe( + /** + * access injectNotification from the options stream + */ + withLatestFrom_1.withLatestFrom(inputs.logInstance$, inputs.option$.pipe(pluck_1.pluck("injectNotification"))), + /** + * only accept messages if injectNotification !== console + */ + filter_1.filter(function (_a) { + var injectNotification = _a[2]; + return injectNotification === "console"; + }), tap_1.tap(function (_a) { + var event = _a[0], log = _a[1]; + switch (event[0]) { + case LogNames.Info: { + return log.info.apply(log, event[1]); + } + case LogNames.Debug: { + return log.debug.apply(log, event[1]); + } + } + })); + }, + _a[Overlay.Info] = function (xs, inputs) { + return xs.pipe(withLatestFrom_1.withLatestFrom(inputs.option$, inputs.notifyElement$, inputs.document$), + /** + * Reject all notifications if notify: false + */ + filter_1.filter(function (_a) { + var options = _a[1]; + return Boolean(options.notify); + }), + /** + * Set the HTML of the notify element + */ + tap_1.tap(function (_a) { + var event = _a[0], options = _a[1], element = _a[2], document = _a[3]; + element.innerHTML = event[0]; + element.style.display = "block"; + document.body.appendChild(element); + }), + /** + * Now remove the element after the given timeout + */ + switchMap_1.switchMap(function (_a) { + var event = _a[0], options = _a[1], element = _a[2], document = _a[3]; + return timer_1.timer(event[1] || 2000).pipe(tap_1.tap(function () { + element.style.display = "none"; + if (element.parentNode) { + document.body.removeChild(element); + } + })); + })); + }, + _a)); + + +/***/ }), +/* 15 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var __extends = (this && this.__extends) || function (d, b) { + for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +}; +var subscribeToResult_1 = __webpack_require__(30); +var OuterSubscriber_1 = __webpack_require__(29); +/* tslint:enable:max-line-length */ +/** + * Projects each source value to an Observable which is merged in the output + * Observable. + * + * Maps each value to an Observable, then flattens all of + * these inner Observables using {@link mergeAll}. + * + * + * + * Returns an Observable that emits items based on applying a function that you + * supply to each item emitted by the source Observable, where that function + * returns an Observable, and then merging those resulting Observables and + * emitting the results of this merger. + * + * @example Map and flatten each letter to an Observable ticking every 1 second + * var letters = Rx.Observable.of('a', 'b', 'c'); + * var result = letters.mergeMap(x => + * Rx.Observable.interval(1000).map(i => x+i) + * ); + * result.subscribe(x => console.log(x)); + * + * // Results in the following: + * // a0 + * // b0 + * // c0 + * // a1 + * // b1 + * // c1 + * // continues to list a,b,c with respective ascending integers + * + * @see {@link concatMap} + * @see {@link exhaustMap} + * @see {@link merge} + * @see {@link mergeAll} + * @see {@link mergeMapTo} + * @see {@link mergeScan} + * @see {@link switchMap} + * + * @param {function(value: T, ?index: number): ObservableInput} project A function + * that, when applied to an item emitted by the source Observable, returns an + * Observable. + * @param {function(outerValue: T, innerValue: I, outerIndex: number, innerIndex: number): any} [resultSelector] + * A function to produce the value on the output Observable based on the values + * and the indices of the source (outer) emission and the inner Observable + * emission. The arguments passed to this function are: + * - `outerValue`: the value that came from the source + * - `innerValue`: the value that came from the projected Observable + * - `outerIndex`: the "index" of the value that came from the source + * - `innerIndex`: the "index" of the value from the projected Observable + * @param {number} [concurrent=Number.POSITIVE_INFINITY] Maximum number of input + * Observables being subscribed to concurrently. + * @return {Observable} An Observable that emits the result of applying the + * projection function (and the optional `resultSelector`) to each item emitted + * by the source Observable and merging the results of the Observables obtained + * from this transformation. + * @method mergeMap + * @owner Observable + */ +function mergeMap(project, resultSelector, concurrent) { + if (concurrent === void 0) { concurrent = Number.POSITIVE_INFINITY; } + return function mergeMapOperatorFunction(source) { + if (typeof resultSelector === 'number') { + concurrent = resultSelector; + resultSelector = null; + } + return source.lift(new MergeMapOperator(project, resultSelector, concurrent)); + }; +} +exports.mergeMap = mergeMap; +var MergeMapOperator = (function () { + function MergeMapOperator(project, resultSelector, concurrent) { + if (concurrent === void 0) { concurrent = Number.POSITIVE_INFINITY; } + this.project = project; + this.resultSelector = resultSelector; + this.concurrent = concurrent; + } + MergeMapOperator.prototype.call = function (observer, source) { + return source.subscribe(new MergeMapSubscriber(observer, this.project, this.resultSelector, this.concurrent)); + }; + return MergeMapOperator; +}()); +exports.MergeMapOperator = MergeMapOperator; +/** + * We need this JSDoc comment for affecting ESDoc. + * @ignore + * @extends {Ignored} + */ +var MergeMapSubscriber = (function (_super) { + __extends(MergeMapSubscriber, _super); + function MergeMapSubscriber(destination, project, resultSelector, concurrent) { + if (concurrent === void 0) { concurrent = Number.POSITIVE_INFINITY; } + _super.call(this, destination); + this.project = project; + this.resultSelector = resultSelector; + this.concurrent = concurrent; + this.hasCompleted = false; + this.buffer = []; + this.active = 0; + this.index = 0; + } + MergeMapSubscriber.prototype._next = function (value) { + if (this.active < this.concurrent) { + this._tryNext(value); + } + else { + this.buffer.push(value); + } + }; + MergeMapSubscriber.prototype._tryNext = function (value) { + var result; + var index = this.index++; + try { + result = this.project(value, index); + } + catch (err) { + this.destination.error(err); + return; + } + this.active++; + this._innerSub(result, value, index); + }; + MergeMapSubscriber.prototype._innerSub = function (ish, value, index) { + this.add(subscribeToResult_1.subscribeToResult(this, ish, value, index)); + }; + MergeMapSubscriber.prototype._complete = function () { + this.hasCompleted = true; + if (this.active === 0 && this.buffer.length === 0) { + this.destination.complete(); + } + }; + MergeMapSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { + if (this.resultSelector) { + this._notifyResultSelector(outerValue, innerValue, outerIndex, innerIndex); + } + else { + this.destination.next(innerValue); + } + }; + MergeMapSubscriber.prototype._notifyResultSelector = function (outerValue, innerValue, outerIndex, innerIndex) { + var result; + try { + result = this.resultSelector(outerValue, innerValue, outerIndex, innerIndex); + } + catch (err) { + this.destination.error(err); + return; + } + this.destination.next(result); + }; + MergeMapSubscriber.prototype.notifyComplete = function (innerSub) { + var buffer = this.buffer; + this.remove(innerSub); + this.active--; + if (buffer.length > 0) { + this._next(buffer.shift()); + } + else if (this.active === 0 && this.hasCompleted) { + this.destination.complete(); + } + }; + return MergeMapSubscriber; +}(OuterSubscriber_1.OuterSubscriber)); +exports.MergeMapSubscriber = MergeMapSubscriber; +//# sourceMappingURL=mergeMap.js.map + +/***/ }), +/* 16 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var EmptyObservable_1 = __webpack_require__(28); +exports.empty = EmptyObservable_1.EmptyObservable.create; +//# sourceMappingURL=empty.js.map + +/***/ }), +/* 17 */ +/***/ (function(module, exports, __webpack_require__) { + + +/** + * Expose `Emitter`. + */ + +if (true) { + module.exports = Emitter; +} + +/** + * Initialize a new `Emitter`. + * + * @api public + */ + +function Emitter(obj) { + if (obj) return mixin(obj); +}; + +/** + * Mixin the emitter properties. + * + * @param {Object} obj + * @return {Object} + * @api private + */ + +function mixin(obj) { + for (var key in Emitter.prototype) { + obj[key] = Emitter.prototype[key]; + } + return obj; +} + +/** + * Listen on the given `event` with `fn`. + * + * @param {String} event + * @param {Function} fn + * @return {Emitter} + * @api public + */ + +Emitter.prototype.on = +Emitter.prototype.addEventListener = function(event, fn){ + this._callbacks = this._callbacks || {}; + (this._callbacks['$' + event] = this._callbacks['$' + event] || []) + .push(fn); + return this; +}; + +/** + * Adds an `event` listener that will be invoked a single + * time then automatically removed. + * + * @param {String} event + * @param {Function} fn + * @return {Emitter} + * @api public + */ + +Emitter.prototype.once = function(event, fn){ + function on() { + this.off(event, on); + fn.apply(this, arguments); + } + + on.fn = fn; + this.on(event, on); + return this; +}; + +/** + * Remove the given callback for `event` or all + * registered callbacks. + * + * @param {String} event + * @param {Function} fn + * @return {Emitter} + * @api public + */ + +Emitter.prototype.off = +Emitter.prototype.removeListener = +Emitter.prototype.removeAllListeners = +Emitter.prototype.removeEventListener = function(event, fn){ + this._callbacks = this._callbacks || {}; + + // all + if (0 == arguments.length) { + this._callbacks = {}; + return this; + } + + // specific event + var callbacks = this._callbacks['$' + event]; + if (!callbacks) return this; + + // remove all handlers + if (1 == arguments.length) { + delete this._callbacks['$' + event]; + return this; + } + + // remove specific handler + var cb; + for (var i = 0; i < callbacks.length; i++) { + cb = callbacks[i]; + if (cb === fn || cb.fn === fn) { + callbacks.splice(i, 1); + break; + } + } + return this; +}; + +/** + * Emit `event` with the given args. + * + * @param {String} event + * @param {Mixed} ... + * @return {Emitter} + */ + +Emitter.prototype.emit = function(event){ + this._callbacks = this._callbacks || {}; + var args = [].slice.call(arguments, 1) + , callbacks = this._callbacks['$' + event]; + + if (callbacks) { + callbacks = callbacks.slice(0); + for (var i = 0, len = callbacks.length; i < len; ++i) { + callbacks[i].apply(this, args); + } + } + + return this; +}; + +/** + * Return array of callbacks for `event`. + * + * @param {String} event + * @return {Array} + * @api public + */ + +Emitter.prototype.listeners = function(event){ + this._callbacks = this._callbacks || {}; + return this._callbacks['$' + event] || []; +}; + +/** + * Check if this emitter has `event` handlers. + * + * @param {String} event + * @return {Boolean} + * @api public + */ + +Emitter.prototype.hasListeners = function(event){ + return !! this.listeners(event).length; +}; + + +/***/ }), +/* 18 */ +/***/ (function(module, exports, __webpack_require__) { + +/** + * Module dependencies. + */ + +var keys = __webpack_require__(121); +var hasBinary = __webpack_require__(67); +var sliceBuffer = __webpack_require__(123); +var after = __webpack_require__(124); +var utf8 = __webpack_require__(125); + +var base64encoder; +if (typeof ArrayBuffer !== 'undefined') { + base64encoder = __webpack_require__(126); +} + +/** + * Check if we are running an android browser. That requires us to use + * ArrayBuffer with polling transports... + * + * http://ghinda.net/jpeg-blob-ajax-android/ + */ + +var isAndroid = typeof navigator !== 'undefined' && /Android/i.test(navigator.userAgent); + +/** + * Check if we are running in PhantomJS. + * Uploading a Blob with PhantomJS does not work correctly, as reported here: + * https://github.com/ariya/phantomjs/issues/11395 + * @type boolean + */ +var isPhantomJS = typeof navigator !== 'undefined' && /PhantomJS/i.test(navigator.userAgent); + +/** + * When true, avoids using Blobs to encode payloads. + * @type boolean + */ +var dontSendBlobs = isAndroid || isPhantomJS; + +/** + * Current protocol version. + */ + +exports.protocol = 3; + +/** + * Packet types. + */ + +var packets = exports.packets = { + open: 0 // non-ws + , close: 1 // non-ws + , ping: 2 + , pong: 3 + , message: 4 + , upgrade: 5 + , noop: 6 +}; + +var packetslist = keys(packets); + +/** + * Premade error packet. + */ + +var err = { type: 'error', data: 'parser error' }; + +/** + * Create a blob api even for blob builder when vendor prefixes exist + */ + +var Blob = __webpack_require__(127); + +/** + * Encodes a packet. + * + * [ ] + * + * Example: + * + * 5hello world + * 3 + * 4 + * + * Binary is encoded in an identical principle + * + * @api private + */ + +exports.encodePacket = function (packet, supportsBinary, utf8encode, callback) { + if (typeof supportsBinary === 'function') { + callback = supportsBinary; + supportsBinary = false; + } + + if (typeof utf8encode === 'function') { + callback = utf8encode; + utf8encode = null; + } + + var data = (packet.data === undefined) + ? undefined + : packet.data.buffer || packet.data; + + if (typeof ArrayBuffer !== 'undefined' && data instanceof ArrayBuffer) { + return encodeArrayBuffer(packet, supportsBinary, callback); + } else if (typeof Blob !== 'undefined' && data instanceof Blob) { + return encodeBlob(packet, supportsBinary, callback); + } + + // might be an object with { base64: true, data: dataAsBase64String } + if (data && data.base64) { + return encodeBase64Object(packet, callback); + } + + // Sending data as a utf-8 string + var encoded = packets[packet.type]; + + // data fragment is optional + if (undefined !== packet.data) { + encoded += utf8encode ? utf8.encode(String(packet.data), { strict: false }) : String(packet.data); + } + + return callback('' + encoded); + +}; + +function encodeBase64Object(packet, callback) { + // packet data is an object { base64: true, data: dataAsBase64String } + var message = 'b' + exports.packets[packet.type] + packet.data.data; + return callback(message); +} + +/** + * Encode packet helpers for binary types + */ + +function encodeArrayBuffer(packet, supportsBinary, callback) { + if (!supportsBinary) { + return exports.encodeBase64Packet(packet, callback); + } + + var data = packet.data; + var contentArray = new Uint8Array(data); + var resultBuffer = new Uint8Array(1 + data.byteLength); + + resultBuffer[0] = packets[packet.type]; + for (var i = 0; i < contentArray.length; i++) { + resultBuffer[i+1] = contentArray[i]; + } + + return callback(resultBuffer.buffer); +} + +function encodeBlobAsArrayBuffer(packet, supportsBinary, callback) { + if (!supportsBinary) { + return exports.encodeBase64Packet(packet, callback); + } + + var fr = new FileReader(); + fr.onload = function() { + exports.encodePacket({ type: packet.type, data: fr.result }, supportsBinary, true, callback); + }; + return fr.readAsArrayBuffer(packet.data); +} + +function encodeBlob(packet, supportsBinary, callback) { + if (!supportsBinary) { + return exports.encodeBase64Packet(packet, callback); + } + + if (dontSendBlobs) { + return encodeBlobAsArrayBuffer(packet, supportsBinary, callback); + } + + var length = new Uint8Array(1); + length[0] = packets[packet.type]; + var blob = new Blob([length.buffer, packet.data]); + + return callback(blob); +} + +/** + * Encodes a packet with binary data in a base64 string + * + * @param {Object} packet, has `type` and `data` + * @return {String} base64 encoded message + */ + +exports.encodeBase64Packet = function(packet, callback) { + var message = 'b' + exports.packets[packet.type]; + if (typeof Blob !== 'undefined' && packet.data instanceof Blob) { + var fr = new FileReader(); + fr.onload = function() { + var b64 = fr.result.split(',')[1]; + callback(message + b64); + }; + return fr.readAsDataURL(packet.data); + } + + var b64data; + try { + b64data = String.fromCharCode.apply(null, new Uint8Array(packet.data)); + } catch (e) { + // iPhone Safari doesn't let you apply with typed arrays + var typed = new Uint8Array(packet.data); + var basic = new Array(typed.length); + for (var i = 0; i < typed.length; i++) { + basic[i] = typed[i]; + } + b64data = String.fromCharCode.apply(null, basic); + } + message += btoa(b64data); + return callback(message); +}; + +/** + * Decodes a packet. Changes format to Blob if requested. + * + * @return {Object} with `type` and `data` (if any) + * @api private + */ + +exports.decodePacket = function (data, binaryType, utf8decode) { + if (data === undefined) { + return err; + } + // String data + if (typeof data === 'string') { + if (data.charAt(0) === 'b') { + return exports.decodeBase64Packet(data.substr(1), binaryType); + } + + if (utf8decode) { + data = tryDecode(data); + if (data === false) { + return err; + } + } + var type = data.charAt(0); + + if (Number(type) != type || !packetslist[type]) { + return err; + } + + if (data.length > 1) { + return { type: packetslist[type], data: data.substring(1) }; + } else { + return { type: packetslist[type] }; + } + } + + var asArray = new Uint8Array(data); + var type = asArray[0]; + var rest = sliceBuffer(data, 1); + if (Blob && binaryType === 'blob') { + rest = new Blob([rest]); + } + return { type: packetslist[type], data: rest }; +}; + +function tryDecode(data) { + try { + data = utf8.decode(data, { strict: false }); + } catch (e) { + return false; + } + return data; +} + +/** + * Decodes a packet encoded in a base64 string + * + * @param {String} base64 encoded message + * @return {Object} with `type` and `data` (if any) + */ + +exports.decodeBase64Packet = function(msg, binaryType) { + var type = packetslist[msg.charAt(0)]; + if (!base64encoder) { + return { type: type, data: { base64: true, data: msg.substr(1) } }; + } + + var data = base64encoder.decode(msg.substr(1)); + + if (binaryType === 'blob' && Blob) { + data = new Blob([data]); + } + + return { type: type, data: data }; +}; + +/** + * Encodes multiple messages (payload). + * + * :data + * + * Example: + * + * 11:hello world2:hi + * + * If any contents are binary, they will be encoded as base64 strings. Base64 + * encoded strings are marked with a b before the length specifier + * + * @param {Array} packets + * @api private + */ + +exports.encodePayload = function (packets, supportsBinary, callback) { + if (typeof supportsBinary === 'function') { + callback = supportsBinary; + supportsBinary = null; + } + + var isBinary = hasBinary(packets); + + if (supportsBinary && isBinary) { + if (Blob && !dontSendBlobs) { + return exports.encodePayloadAsBlob(packets, callback); + } + + return exports.encodePayloadAsArrayBuffer(packets, callback); + } + + if (!packets.length) { + return callback('0:'); + } + + function setLengthHeader(message) { + return message.length + ':' + message; + } + + function encodeOne(packet, doneCallback) { + exports.encodePacket(packet, !isBinary ? false : supportsBinary, false, function(message) { + doneCallback(null, setLengthHeader(message)); + }); + } + + map(packets, encodeOne, function(err, results) { + return callback(results.join('')); + }); +}; + +/** + * Async array map using after + */ + +function map(ary, each, done) { + var result = new Array(ary.length); + var next = after(ary.length, done); + + var eachWithIndex = function(i, el, cb) { + each(el, function(error, msg) { + result[i] = msg; + cb(error, result); + }); + }; + + for (var i = 0; i < ary.length; i++) { + eachWithIndex(i, ary[i], next); + } +} + +/* + * Decodes data when a payload is maybe expected. Possible binary contents are + * decoded from their base64 representation + * + * @param {String} data, callback method + * @api public + */ + +exports.decodePayload = function (data, binaryType, callback) { + if (typeof data !== 'string') { + return exports.decodePayloadAsBinary(data, binaryType, callback); + } + + if (typeof binaryType === 'function') { + callback = binaryType; + binaryType = null; + } + + var packet; + if (data === '') { + // parser error - ignoring payload + return callback(err, 0, 1); + } + + var length = '', n, msg; + + for (var i = 0, l = data.length; i < l; i++) { + var chr = data.charAt(i); + + if (chr !== ':') { + length += chr; + continue; + } + + if (length === '' || (length != (n = Number(length)))) { + // parser error - ignoring payload + return callback(err, 0, 1); + } + + msg = data.substr(i + 1, n); + + if (length != msg.length) { + // parser error - ignoring payload + return callback(err, 0, 1); + } + + if (msg.length) { + packet = exports.decodePacket(msg, binaryType, false); + + if (err.type === packet.type && err.data === packet.data) { + // parser error in individual packet - ignoring payload + return callback(err, 0, 1); + } + + var ret = callback(packet, i + n, l); + if (false === ret) return; + } + + // advance cursor + i += n; + length = ''; + } + + if (length !== '') { + // parser error - ignoring payload + return callback(err, 0, 1); + } + +}; + +/** + * Encodes multiple messages (payload) as binary. + * + * <1 = binary, 0 = string>[...] + * + * Example: + * 1 3 255 1 2 3, if the binary contents are interpreted as 8 bit integers + * + * @param {Array} packets + * @return {ArrayBuffer} encoded payload + * @api private + */ + +exports.encodePayloadAsArrayBuffer = function(packets, callback) { + if (!packets.length) { + return callback(new ArrayBuffer(0)); + } + + function encodeOne(packet, doneCallback) { + exports.encodePacket(packet, true, true, function(data) { + return doneCallback(null, data); + }); + } + + map(packets, encodeOne, function(err, encodedPackets) { + var totalLength = encodedPackets.reduce(function(acc, p) { + var len; + if (typeof p === 'string'){ + len = p.length; + } else { + len = p.byteLength; + } + return acc + len.toString().length + len + 2; // string/binary identifier + separator = 2 + }, 0); + + var resultArray = new Uint8Array(totalLength); + + var bufferIndex = 0; + encodedPackets.forEach(function(p) { + var isString = typeof p === 'string'; + var ab = p; + if (isString) { + var view = new Uint8Array(p.length); + for (var i = 0; i < p.length; i++) { + view[i] = p.charCodeAt(i); + } + ab = view.buffer; + } + + if (isString) { // not true binary + resultArray[bufferIndex++] = 0; + } else { // true binary + resultArray[bufferIndex++] = 1; + } + + var lenStr = ab.byteLength.toString(); + for (var i = 0; i < lenStr.length; i++) { + resultArray[bufferIndex++] = parseInt(lenStr[i]); + } + resultArray[bufferIndex++] = 255; + + var view = new Uint8Array(ab); + for (var i = 0; i < view.length; i++) { + resultArray[bufferIndex++] = view[i]; + } + }); + + return callback(resultArray.buffer); + }); +}; + +/** + * Encode as Blob + */ + +exports.encodePayloadAsBlob = function(packets, callback) { + function encodeOne(packet, doneCallback) { + exports.encodePacket(packet, true, true, function(encoded) { + var binaryIdentifier = new Uint8Array(1); + binaryIdentifier[0] = 1; + if (typeof encoded === 'string') { + var view = new Uint8Array(encoded.length); + for (var i = 0; i < encoded.length; i++) { + view[i] = encoded.charCodeAt(i); + } + encoded = view.buffer; + binaryIdentifier[0] = 0; + } + + var len = (encoded instanceof ArrayBuffer) + ? encoded.byteLength + : encoded.size; + + var lenStr = len.toString(); + var lengthAry = new Uint8Array(lenStr.length + 1); + for (var i = 0; i < lenStr.length; i++) { + lengthAry[i] = parseInt(lenStr[i]); + } + lengthAry[lenStr.length] = 255; + + if (Blob) { + var blob = new Blob([binaryIdentifier.buffer, lengthAry.buffer, encoded]); + doneCallback(null, blob); + } + }); + } + + map(packets, encodeOne, function(err, results) { + return callback(new Blob(results)); + }); +}; + +/* + * Decodes data when a payload is maybe expected. Strings are decoded by + * interpreting each byte as a key code for entries marked to start with 0. See + * description of encodePayloadAsBinary + * + * @param {ArrayBuffer} data, callback method + * @api public + */ + +exports.decodePayloadAsBinary = function (data, binaryType, callback) { + if (typeof binaryType === 'function') { + callback = binaryType; + binaryType = null; + } + + var bufferTail = data; + var buffers = []; + + while (bufferTail.byteLength > 0) { + var tailArray = new Uint8Array(bufferTail); + var isString = tailArray[0] === 0; + var msgLength = ''; + + for (var i = 1; ; i++) { + if (tailArray[i] === 255) break; + + // 310 = char length of Number.MAX_VALUE + if (msgLength.length > 310) { + return callback(err, 0, 1); + } + + msgLength += tailArray[i]; + } + + bufferTail = sliceBuffer(bufferTail, 2 + msgLength.length); + msgLength = parseInt(msgLength); + + var msg = sliceBuffer(bufferTail, 0, msgLength); + if (isString) { + try { + msg = String.fromCharCode.apply(null, new Uint8Array(msg)); + } catch (e) { + // iPhone Safari doesn't let you apply to typed arrays + var typed = new Uint8Array(msg); + msg = ''; + for (var i = 0; i < typed.length; i++) { + msg += String.fromCharCode(typed[i]); + } + } + } + + buffers.push(msg); + bufferTail = sliceBuffer(bufferTail, msgLength); + } + + var total = buffers.length; + buffers.forEach(function(buffer, i) { + callback(exports.decodePacket(buffer, binaryType, true), i, total); + }); +}; + + +/***/ }), +/* 19 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +Object.defineProperty(exports, "__esModule", { value: true }); +var _a; +var BehaviorSubject_1 = __webpack_require__(13); +var prop_set_dom_effect_1 = __webpack_require__(76); +var style_set_dom_effect_1 = __webpack_require__(81); +var link_replace_dom_effect_1 = __webpack_require__(82); +var set_scroll_dom_effect_1 = __webpack_require__(83); +var set_window_name_dom_effect_1 = __webpack_require__(84); +var Events; +(function (Events) { + Events["PropSet"] = "@@BSDOM.Events.PropSet"; + Events["StyleSet"] = "@@BSDOM.Events.StyleSet"; + Events["LinkReplace"] = "@@BSDOM.Events.LinkReplace"; + Events["SetScroll"] = "@@BSDOM.Events.SetScroll"; + Events["SetWindowName"] = "@@BSDOM.Events.SetWindowName"; +})(Events = exports.Events || (exports.Events = {})); +exports.domHandlers$ = new BehaviorSubject_1.BehaviorSubject((_a = {}, + _a[Events.PropSet] = prop_set_dom_effect_1.propSetDomEffect, + _a[Events.StyleSet] = style_set_dom_effect_1.styleSetDomEffect, + _a[Events.LinkReplace] = link_replace_dom_effect_1.linkReplaceDomEffect, + _a[Events.SetScroll] = set_scroll_dom_effect_1.setScrollDomEffect, + _a[Events.SetWindowName] = set_window_name_dom_effect_1.setWindowNameDomEffect, + _a)); + + +/***/ }), +/* 20 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var __extends = (this && this.__extends) || function (d, b) { + for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +}; +var OuterSubscriber_1 = __webpack_require__(29); +var subscribeToResult_1 = __webpack_require__(30); +/* tslint:enable:max-line-length */ +/** + * Projects each source value to an Observable which is merged in the output + * Observable, emitting values only from the most recently projected Observable. + * + * Maps each value to an Observable, then flattens all of + * these inner Observables using {@link switch}. + * + * + * + * Returns an Observable that emits items based on applying a function that you + * supply to each item emitted by the source Observable, where that function + * returns an (so-called "inner") Observable. Each time it observes one of these + * inner Observables, the output Observable begins emitting the items emitted by + * that inner Observable. When a new inner Observable is emitted, `switchMap` + * stops emitting items from the earlier-emitted inner Observable and begins + * emitting items from the new one. It continues to behave like this for + * subsequent inner Observables. + * + * @example Rerun an interval Observable on every click event + * var clicks = Rx.Observable.fromEvent(document, 'click'); + * var result = clicks.switchMap((ev) => Rx.Observable.interval(1000)); + * result.subscribe(x => console.log(x)); + * + * @see {@link concatMap} + * @see {@link exhaustMap} + * @see {@link mergeMap} + * @see {@link switch} + * @see {@link switchMapTo} + * + * @param {function(value: T, ?index: number): ObservableInput} project A function + * that, when applied to an item emitted by the source Observable, returns an + * Observable. + * @param {function(outerValue: T, innerValue: I, outerIndex: number, innerIndex: number): any} [resultSelector] + * A function to produce the value on the output Observable based on the values + * and the indices of the source (outer) emission and the inner Observable + * emission. The arguments passed to this function are: + * - `outerValue`: the value that came from the source + * - `innerValue`: the value that came from the projected Observable + * - `outerIndex`: the "index" of the value that came from the source + * - `innerIndex`: the "index" of the value from the projected Observable + * @return {Observable} An Observable that emits the result of applying the + * projection function (and the optional `resultSelector`) to each item emitted + * by the source Observable and taking only the values from the most recently + * projected inner Observable. + * @method switchMap + * @owner Observable + */ +function switchMap(project, resultSelector) { + return function switchMapOperatorFunction(source) { + return source.lift(new SwitchMapOperator(project, resultSelector)); + }; +} +exports.switchMap = switchMap; +var SwitchMapOperator = (function () { + function SwitchMapOperator(project, resultSelector) { + this.project = project; + this.resultSelector = resultSelector; + } + SwitchMapOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new SwitchMapSubscriber(subscriber, this.project, this.resultSelector)); + }; + return SwitchMapOperator; +}()); +/** + * We need this JSDoc comment for affecting ESDoc. + * @ignore + * @extends {Ignored} + */ +var SwitchMapSubscriber = (function (_super) { + __extends(SwitchMapSubscriber, _super); + function SwitchMapSubscriber(destination, project, resultSelector) { + _super.call(this, destination); + this.project = project; + this.resultSelector = resultSelector; + this.index = 0; + } + SwitchMapSubscriber.prototype._next = function (value) { + var result; + var index = this.index++; + try { + result = this.project(value, index); + } + catch (error) { + this.destination.error(error); + return; + } + this._innerSub(result, value, index); + }; + SwitchMapSubscriber.prototype._innerSub = function (result, value, index) { + var innerSubscription = this.innerSubscription; + if (innerSubscription) { + innerSubscription.unsubscribe(); + } + this.add(this.innerSubscription = subscribeToResult_1.subscribeToResult(this, result, value, index)); + }; + SwitchMapSubscriber.prototype._complete = function () { + var innerSubscription = this.innerSubscription; + if (!innerSubscription || innerSubscription.closed) { + _super.prototype._complete.call(this); + } + }; + /** @deprecated internal use only */ SwitchMapSubscriber.prototype._unsubscribe = function () { + this.innerSubscription = null; + }; + SwitchMapSubscriber.prototype.notifyComplete = function (innerSub) { + this.remove(innerSub); + this.innerSubscription = null; + if (this.isStopped) { + _super.prototype._complete.call(this); + } + }; + SwitchMapSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { + if (this.resultSelector) { + this._tryNotifyNext(outerValue, innerValue, outerIndex, innerIndex); + } + else { + this.destination.next(innerValue); + } + }; + SwitchMapSubscriber.prototype._tryNotifyNext = function (outerValue, innerValue, outerIndex, innerIndex) { + var result; + try { + result = this.resultSelector(outerValue, innerValue, outerIndex, innerIndex); + } + catch (err) { + this.destination.error(err); + return; + } + this.destination.next(result); + }; + return SwitchMapSubscriber; +}(OuterSubscriber_1.OuterSubscriber)); +//# sourceMappingURL=switchMap.js.map + +/***/ }), +/* 21 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +Object.defineProperty(exports, "__esModule", { value: true }); +var concat_1 = __webpack_require__(54); +var timer_1 = __webpack_require__(52); +var of_1 = __webpack_require__(9); +var switchMap_1 = __webpack_require__(20); +var startWith_1 = __webpack_require__(152); +var mapTo_1 = __webpack_require__(88); +function each(incoming) { + return [].slice.call(incoming || []); +} +exports.each = each; +exports.splitUrl = function (url) { + var hash, index, params; + if ((index = url.indexOf("#")) >= 0) { + hash = url.slice(index); + url = url.slice(0, index); + } + else { + hash = ""; + } + if ((index = url.indexOf("?")) >= 0) { + params = url.slice(index); + url = url.slice(0, index); + } + else { + params = ""; + } + return { url: url, params: params, hash: hash }; +}; +exports.pathFromUrl = function (url) { + var path; + (url = exports.splitUrl(url).url); + if (url.indexOf("file://") === 0) { + path = url.replace(new RegExp("^file://(localhost)?"), ""); + } + else { + // http : // hostname :8080 / + path = url.replace(new RegExp("^([^:]+:)?//([^:/]+)(:\\d*)?/"), "/"); + } + // decodeURI has special handling of stuff like semicolons, so use decodeURIComponent + return decodeURIComponent(path); +}; +exports.pickBestMatch = function (path, objects, pathFunc) { + var score; + var bestMatch = { score: 0, object: null }; + objects.forEach(function (object) { + score = exports.numberOfMatchingSegments(path, pathFunc(object)); + if (score > bestMatch.score) { + bestMatch = { object: object, score: score }; + } + }); + if (bestMatch.score > 0) { + return bestMatch; + } + else { + return null; + } +}; +exports.numberOfMatchingSegments = function (path1, path2) { + path1 = normalisePath(path1); + path2 = normalisePath(path2); + if (path1 === path2) { + return 10000; + } + var comps1 = path1.split("/").reverse(); + var comps2 = path2.split("/").reverse(); + var len = Math.min(comps1.length, comps2.length); + var eqCount = 0; + while (eqCount < len && comps1[eqCount] === comps2[eqCount]) { + ++eqCount; + } + return eqCount; +}; +exports.pathsMatch = function (path1, path2) { + return exports.numberOfMatchingSegments(path1, path2) > 0; +}; +function getLocation(url) { + var location = document.createElement("a"); + location.href = url; + if (location.host === "") { + location.href = location.href; + } + return location; +} +exports.getLocation = getLocation; +/** + * @param {string} search + * @param {string} key + * @param {string} suffix + */ +function updateSearch(search, key, suffix) { + if (search === "") { + return "?" + suffix; + } + return ("?" + + search + .slice(1) + .split("&") + .map(function (item) { + return item.split("="); + }) + .filter(function (tuple) { + return tuple[0] !== key; + }) + .map(function (item) { + return [item[0], item[1]].join("="); + }) + .concat(suffix) + .join("&")); +} +exports.updateSearch = updateSearch; +var blacklist = [ + // never allow .map files through + function (incoming) { + return incoming.ext === "map"; + } +]; +/** + * @param incoming + * @returns {boolean} + */ +function isBlacklisted(incoming) { + return blacklist.some(function (fn) { + return fn(incoming); + }); +} +exports.isBlacklisted = isBlacklisted; +function createTimedBooleanSwitch(source$, timeout) { + if (timeout === void 0) { timeout = 1000; } + return source$.pipe(switchMap_1.switchMap(function () { + return concat_1.concat(of_1.of(false), timer_1.timer(timeout).pipe(mapTo_1.mapTo(true))); + }), startWith_1.startWith(true)); +} +exports.createTimedBooleanSwitch = createTimedBooleanSwitch; +function array(incoming) { + return [].slice.call(incoming); +} +exports.array = array; +function normalisePath(path) { + return path + .replace(/^\/+/, "") + .replace(/\\/g, "/") + .toLowerCase(); +} +exports.normalisePath = normalisePath; + + +/***/ }), +/* 22 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +Object.defineProperty(exports, "__esModule", { value: true }); +function getWindow() { + return window; +} +exports.getWindow = getWindow; +/** + * @returns {HTMLDocument} + */ +function getDocument() { + return document; +} +exports.getDocument = getDocument; +/** + * Get the current x/y position crossbow + * @returns {{x: *, y: *}} + */ +function getBrowserScrollPosition(window, document) { + var scrollX; + var scrollY; + var dElement = document.documentElement; + var dBody = document.body; + if (window.pageYOffset !== undefined) { + scrollX = window.pageXOffset; + scrollY = window.pageYOffset; + } + else { + scrollX = dElement.scrollLeft || dBody.scrollLeft || 0; + scrollY = dElement.scrollTop || dBody.scrollTop || 0; + } + return { + x: scrollX, + y: scrollY + }; +} +exports.getBrowserScrollPosition = getBrowserScrollPosition; +/** + * @returns {{x: number, y: number}} + */ +function getDocumentScrollSpace(document) { + var dElement = document.documentElement; + var dBody = document.body; + return { + x: dBody.scrollHeight - dElement.clientWidth, + y: dBody.scrollHeight - dElement.clientHeight + }; +} +exports.getDocumentScrollSpace = getDocumentScrollSpace; +/** + * Saves scroll position into cookies + */ +function saveScrollPosition(window, document) { + var pos = getBrowserScrollPosition(window, document); + document.cookie = "bs_scroll_pos=" + [pos.x, pos.y].join(","); +} +exports.saveScrollPosition = saveScrollPosition; +/** + * Restores scroll position from cookies + */ +function restoreScrollPosition() { + var pos = getDocument() + .cookie.replace(/(?:(?:^|.*;\s*)bs_scroll_pos\s*\=\s*([^;]*).*$)|^.*$/, "$1") + .split(","); + getWindow().scrollTo(Number(pos[0]), Number(pos[1])); +} +exports.restoreScrollPosition = restoreScrollPosition; +/** + * @param tagName + * @param elem + * @returns {*|number} + */ +function getElementIndex(tagName, elem) { + var allElems = getDocument().getElementsByTagName(tagName); + return Array.prototype.indexOf.call(allElems, elem); +} +exports.getElementIndex = getElementIndex; +/** + * Force Change event on radio & checkboxes (IE) + */ +function forceChange(elem) { + elem.blur(); + elem.focus(); +} +exports.forceChange = forceChange; +/** + * @param elem + * @returns {{tagName: (elem.tagName|*), index: *}} + */ +function getElementData(elem) { + var tagName = elem.tagName; + var index = getElementIndex(tagName, elem); + return { + tagName: tagName, + index: index + }; +} +exports.getElementData = getElementData; +/** + * @param {string} tagName + * @param {number} index + */ +function getSingleElement(tagName, index) { + var elems = getDocument().getElementsByTagName(tagName); + return elems[index]; +} +exports.getSingleElement = getSingleElement; +/** + * Get the body element + */ +function getBody() { + return getDocument().getElementsByTagName("body")[0]; +} +exports.getBody = getBody; +/** + * @param {{x: number, y: number}} pos + */ +function setScroll(pos) { + getWindow().scrollTo(pos.x, pos.y); +} +exports.setScroll = setScroll; +/** + * Hard reload + */ +function reloadBrowser() { + getWindow().location.reload(true); +} +exports.reloadBrowser = reloadBrowser; +/** + * Foreach polyfill + * @param coll + * @param fn + */ +function forEach(coll, fn) { + for (var i = 0, n = coll.length; i < n; i += 1) { + fn(coll[i], i, coll); + } +} +exports.forEach = forEach; +/** + * Are we dealing with old IE? + * @returns {boolean} + */ +function isOldIe() { + return typeof getWindow().attachEvent !== "undefined"; +} +exports.isOldIe = isOldIe; +/** + * Split the URL information + * @returns {object} + */ +function getLocation(url) { + var location = getDocument().createElement("a"); + location.href = url; + if (location.host === "") { + location.href = location.href; + } + return location; +} +exports.getLocation = getLocation; +/** + * @param {String} val + * @returns {boolean} + */ +function isUndefined(val) { + return "undefined" === typeof val; +} +exports.isUndefined = isUndefined; +/** + * @param obj + * @param path + */ +function getByPath(obj, path) { + for (var i = 0, tempPath = path.split("."), len = tempPath.length; i < len; i++) { + if (!obj || typeof obj !== "object") { + return false; + } + obj = obj[tempPath[i]]; + } + if (typeof obj === "undefined") { + return false; + } + return obj; +} +exports.getByPath = getByPath; +function getScrollPosition(window, document) { + var pos = getBrowserScrollPosition(window, document); + return { + raw: pos, + proportional: getScrollTopPercentage(pos, document) // Get % of y axis of scroll + }; +} +exports.getScrollPosition = getScrollPosition; +function getScrollPositionForElement(element) { + var raw = { + x: element.scrollLeft, + y: element.scrollTop + }; + var scrollSpace = { + x: element.scrollWidth, + y: element.scrollHeight + }; + return { + raw: raw, + proportional: getScrollPercentage(scrollSpace, raw).y // Get % of y axis of scroll + }; +} +exports.getScrollPositionForElement = getScrollPositionForElement; +function getScrollTopPercentage(pos, document) { + var scrollSpace = getDocumentScrollSpace(document); + var percentage = getScrollPercentage(scrollSpace, pos); + return percentage.y; +} +exports.getScrollTopPercentage = getScrollTopPercentage; +function getScrollPercentage(scrollSpace, scrollPosition) { + var x = scrollPosition.x / scrollSpace.x; + var y = scrollPosition.y / scrollSpace.y; + return { + x: x || 0, + y: y + }; +} +exports.getScrollPercentage = getScrollPercentage; + + +/***/ }), +/* 23 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var __extends = (this && this.__extends) || function (d, b) { + for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +}; +var Observable_1 = __webpack_require__(1); +var ScalarObservable_1 = __webpack_require__(46); +var EmptyObservable_1 = __webpack_require__(28); +var isScheduler_1 = __webpack_require__(25); +/** + * We need this JSDoc comment for affecting ESDoc. + * @extends {Ignored} + * @hide true + */ +var ArrayObservable = (function (_super) { + __extends(ArrayObservable, _super); + function ArrayObservable(array, scheduler) { + _super.call(this); + this.array = array; + this.scheduler = scheduler; + if (!scheduler && array.length === 1) { + this._isScalar = true; + this.value = array[0]; + } + } + ArrayObservable.create = function (array, scheduler) { + return new ArrayObservable(array, scheduler); + }; + /** + * Creates an Observable that emits some values you specify as arguments, + * immediately one after the other, and then emits a complete notification. + * + * Emits the arguments you provide, then completes. + * + * + * + * + * This static operator is useful for creating a simple Observable that only + * emits the arguments given, and the complete notification thereafter. It can + * be used for composing with other Observables, such as with {@link concat}. + * By default, it uses a `null` IScheduler, which means the `next` + * notifications are sent synchronously, although with a different IScheduler + * it is possible to determine when those notifications will be delivered. + * + * @example Emit 10, 20, 30, then 'a', 'b', 'c', then start ticking every second. + * var numbers = Rx.Observable.of(10, 20, 30); + * var letters = Rx.Observable.of('a', 'b', 'c'); + * var interval = Rx.Observable.interval(1000); + * var result = numbers.concat(letters).concat(interval); + * result.subscribe(x => console.log(x)); + * + * @see {@link create} + * @see {@link empty} + * @see {@link never} + * @see {@link throw} + * + * @param {...T} values Arguments that represent `next` values to be emitted. + * @param {Scheduler} [scheduler] A {@link IScheduler} to use for scheduling + * the emissions of the `next` notifications. + * @return {Observable} An Observable that emits each given input value. + * @static true + * @name of + * @owner Observable + */ + ArrayObservable.of = function () { + var array = []; + for (var _i = 0; _i < arguments.length; _i++) { + array[_i - 0] = arguments[_i]; + } + var scheduler = array[array.length - 1]; + if (isScheduler_1.isScheduler(scheduler)) { + array.pop(); + } + else { + scheduler = null; + } + var len = array.length; + if (len > 1) { + return new ArrayObservable(array, scheduler); + } + else if (len === 1) { + return new ScalarObservable_1.ScalarObservable(array[0], scheduler); + } + else { + return new EmptyObservable_1.EmptyObservable(scheduler); + } + }; + ArrayObservable.dispatch = function (state) { + var array = state.array, index = state.index, count = state.count, subscriber = state.subscriber; + if (index >= count) { + subscriber.complete(); + return; + } + subscriber.next(array[index]); + if (subscriber.closed) { + return; + } + state.index = index + 1; + this.schedule(state); + }; + /** @deprecated internal use only */ ArrayObservable.prototype._subscribe = function (subscriber) { + var index = 0; + var array = this.array; + var count = array.length; + var scheduler = this.scheduler; + if (scheduler) { + return scheduler.schedule(ArrayObservable.dispatch, 0, { + array: array, index: index, count: count, subscriber: subscriber + }); + } + else { + for (var i = 0; i < count && !subscriber.closed; i++) { + subscriber.next(array[i]); + } + subscriber.complete(); + } + }; + return ArrayObservable; +}(Observable_1.Observable)); +exports.ArrayObservable = ArrayObservable; +//# sourceMappingURL=ArrayObservable.js.map + +/***/ }), +/* 24 */ +/***/ (function(module, exports) { + +var g; + +// This works in non-strict mode +g = (function() { + return this; +})(); + +try { + // This works if eval is allowed (see CSP) + g = g || Function("return this")() || (1,eval)("this"); +} catch(e) { + // This works if the window reference is available + if(typeof window === "object") + g = window; +} + +// g can still be undefined, but nothing to do about it... +// We return undefined, instead of nothing here, so it's +// easier to handle this case. if(!global) { ...} + +module.exports = g; + + +/***/ }), +/* 25 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +function isScheduler(value) { + return value && typeof value.schedule === 'function'; +} +exports.isScheduler = isScheduler; +//# sourceMappingURL=isScheduler.js.map + +/***/ }), +/* 26 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +exports.isArray = Array.isArray || (function (x) { return x && typeof x.length === 'number'; }); +//# sourceMappingURL=isArray.js.map + +/***/ }), +/* 27 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +// typeof any so that it we don't have to cast when comparing a result to the error object +exports.errorObject = { e: {} }; +//# sourceMappingURL=errorObject.js.map + +/***/ }), +/* 28 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var __extends = (this && this.__extends) || function (d, b) { + for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +}; +var Observable_1 = __webpack_require__(1); +/** + * We need this JSDoc comment for affecting ESDoc. + * @extends {Ignored} + * @hide true + */ +var EmptyObservable = (function (_super) { + __extends(EmptyObservable, _super); + function EmptyObservable(scheduler) { + _super.call(this); + this.scheduler = scheduler; + } + /** + * Creates an Observable that emits no items to the Observer and immediately + * emits a complete notification. + * + * Just emits 'complete', and nothing else. + * + * + * + * + * This static operator is useful for creating a simple Observable that only + * emits the complete notification. It can be used for composing with other + * Observables, such as in a {@link mergeMap}. + * + * @example Emit the number 7, then complete. + * var result = Rx.Observable.empty().startWith(7); + * result.subscribe(x => console.log(x)); + * + * @example Map and flatten only odd numbers to the sequence 'a', 'b', 'c' + * var interval = Rx.Observable.interval(1000); + * var result = interval.mergeMap(x => + * x % 2 === 1 ? Rx.Observable.of('a', 'b', 'c') : Rx.Observable.empty() + * ); + * result.subscribe(x => console.log(x)); + * + * // Results in the following to the console: + * // x is equal to the count on the interval eg(0,1,2,3,...) + * // x will occur every 1000ms + * // if x % 2 is equal to 1 print abc + * // if x % 2 is not equal to 1 nothing will be output + * + * @see {@link create} + * @see {@link never} + * @see {@link of} + * @see {@link throw} + * + * @param {Scheduler} [scheduler] A {@link IScheduler} to use for scheduling + * the emission of the complete notification. + * @return {Observable} An "empty" Observable: emits only the complete + * notification. + * @static true + * @name empty + * @owner Observable + */ + EmptyObservable.create = function (scheduler) { + return new EmptyObservable(scheduler); + }; + EmptyObservable.dispatch = function (arg) { + var subscriber = arg.subscriber; + subscriber.complete(); + }; + /** @deprecated internal use only */ EmptyObservable.prototype._subscribe = function (subscriber) { + var scheduler = this.scheduler; + if (scheduler) { + return scheduler.schedule(EmptyObservable.dispatch, 0, { subscriber: subscriber }); + } + else { + subscriber.complete(); + } + }; + return EmptyObservable; +}(Observable_1.Observable)); +exports.EmptyObservable = EmptyObservable; +//# sourceMappingURL=EmptyObservable.js.map + +/***/ }), +/* 29 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var __extends = (this && this.__extends) || function (d, b) { + for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +}; +var Subscriber_1 = __webpack_require__(3); +/** + * We need this JSDoc comment for affecting ESDoc. + * @ignore + * @extends {Ignored} + */ +var OuterSubscriber = (function (_super) { + __extends(OuterSubscriber, _super); + function OuterSubscriber() { + _super.apply(this, arguments); + } + OuterSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { + this.destination.next(innerValue); + }; + OuterSubscriber.prototype.notifyError = function (error, innerSub) { + this.destination.error(error); + }; + OuterSubscriber.prototype.notifyComplete = function (innerSub) { + this.destination.complete(); + }; + return OuterSubscriber; +}(Subscriber_1.Subscriber)); +exports.OuterSubscriber = OuterSubscriber; +//# sourceMappingURL=OuterSubscriber.js.map + +/***/ }), +/* 30 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var root_1 = __webpack_require__(7); +var isArrayLike_1 = __webpack_require__(59); +var isPromise_1 = __webpack_require__(60); +var isObject_1 = __webpack_require__(56); +var Observable_1 = __webpack_require__(1); +var iterator_1 = __webpack_require__(31); +var InnerSubscriber_1 = __webpack_require__(106); +var observable_1 = __webpack_require__(45); +function subscribeToResult(outerSubscriber, result, outerValue, outerIndex) { + var destination = new InnerSubscriber_1.InnerSubscriber(outerSubscriber, outerValue, outerIndex); + if (destination.closed) { + return null; + } + if (result instanceof Observable_1.Observable) { + if (result._isScalar) { + destination.next(result.value); + destination.complete(); + return null; + } + else { + destination.syncErrorThrowable = true; + return result.subscribe(destination); + } + } + else if (isArrayLike_1.isArrayLike(result)) { + for (var i = 0, len = result.length; i < len && !destination.closed; i++) { + destination.next(result[i]); + } + if (!destination.closed) { + destination.complete(); + } + } + else if (isPromise_1.isPromise(result)) { + result.then(function (value) { + if (!destination.closed) { + destination.next(value); + destination.complete(); + } + }, function (err) { return destination.error(err); }) + .then(null, function (err) { + // Escaping the Promise trap: globally throw unhandled errors + root_1.root.setTimeout(function () { throw err; }); + }); + return destination; + } + else if (result && typeof result[iterator_1.iterator] === 'function') { + var iterator = result[iterator_1.iterator](); + do { + var item = iterator.next(); + if (item.done) { + destination.complete(); + break; + } + destination.next(item.value); + if (destination.closed) { + break; + } + } while (true); + } + else if (result && typeof result[observable_1.observable] === 'function') { + var obs = result[observable_1.observable](); + if (typeof obs.subscribe !== 'function') { + destination.error(new TypeError('Provided object does not correctly implement Symbol.observable')); + } + else { + return obs.subscribe(new InnerSubscriber_1.InnerSubscriber(outerSubscriber, outerValue, outerIndex)); + } + } + else { + var value = isObject_1.isObject(result) ? 'an invalid object' : "'" + result + "'"; + var msg = ("You provided " + value + " where a stream was expected.") + + ' You can provide an Observable, Promise, Array, or Iterable.'; + destination.error(new TypeError(msg)); + } + return null; +} +exports.subscribeToResult = subscribeToResult; +//# sourceMappingURL=subscribeToResult.js.map + +/***/ }), +/* 31 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var root_1 = __webpack_require__(7); +function symbolIteratorPonyfill(root) { + var Symbol = root.Symbol; + if (typeof Symbol === 'function') { + if (!Symbol.iterator) { + Symbol.iterator = Symbol('iterator polyfill'); + } + return Symbol.iterator; + } + else { + // [for Mozilla Gecko 27-35:](https://mzl.la/2ewE1zC) + var Set_1 = root.Set; + if (Set_1 && typeof new Set_1()['@@iterator'] === 'function') { + return '@@iterator'; + } + var Map_1 = root.Map; + // required for compatability with es6-shim + if (Map_1) { + var keys = Object.getOwnPropertyNames(Map_1.prototype); + for (var i = 0; i < keys.length; ++i) { + var key = keys[i]; + // according to spec, Map.prototype[@@iterator] and Map.orototype.entries must be equal. + if (key !== 'entries' && key !== 'size' && Map_1.prototype[key] === Map_1.prototype['entries']) { + return key; + } + } + } + return '@@iterator'; + } +} +exports.symbolIteratorPonyfill = symbolIteratorPonyfill; +exports.iterator = symbolIteratorPonyfill(root_1.root); +/** + * @deprecated use iterator instead + */ +exports.$$iterator = exports.iterator; +//# sourceMappingURL=iterator.js.map + +/***/ }), +/* 32 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(process) {/** + * This is the web browser implementation of `debug()`. + * + * Expose `debug()` as the module. + */ + +exports = module.exports = __webpack_require__(110); +exports.log = log; +exports.formatArgs = formatArgs; +exports.save = save; +exports.load = load; +exports.useColors = useColors; +exports.storage = 'undefined' != typeof chrome + && 'undefined' != typeof chrome.storage + ? chrome.storage.local + : localstorage(); + +/** + * Colors. + */ + +exports.colors = [ + '#0000CC', '#0000FF', '#0033CC', '#0033FF', '#0066CC', '#0066FF', '#0099CC', + '#0099FF', '#00CC00', '#00CC33', '#00CC66', '#00CC99', '#00CCCC', '#00CCFF', + '#3300CC', '#3300FF', '#3333CC', '#3333FF', '#3366CC', '#3366FF', '#3399CC', + '#3399FF', '#33CC00', '#33CC33', '#33CC66', '#33CC99', '#33CCCC', '#33CCFF', + '#6600CC', '#6600FF', '#6633CC', '#6633FF', '#66CC00', '#66CC33', '#9900CC', + '#9900FF', '#9933CC', '#9933FF', '#99CC00', '#99CC33', '#CC0000', '#CC0033', + '#CC0066', '#CC0099', '#CC00CC', '#CC00FF', '#CC3300', '#CC3333', '#CC3366', + '#CC3399', '#CC33CC', '#CC33FF', '#CC6600', '#CC6633', '#CC9900', '#CC9933', + '#CCCC00', '#CCCC33', '#FF0000', '#FF0033', '#FF0066', '#FF0099', '#FF00CC', + '#FF00FF', '#FF3300', '#FF3333', '#FF3366', '#FF3399', '#FF33CC', '#FF33FF', + '#FF6600', '#FF6633', '#FF9900', '#FF9933', '#FFCC00', '#FFCC33' +]; + +/** + * Currently only WebKit-based Web Inspectors, Firefox >= v31, + * and the Firebug extension (any Firefox version) are known + * to support "%c" CSS customizations. + * + * TODO: add a `localStorage` variable to explicitly enable/disable colors + */ + +function useColors() { + // NB: In an Electron preload script, document will be defined but not fully + // initialized. Since we know we're in Chrome, we'll just detect this case + // explicitly + if (typeof window !== 'undefined' && window.process && window.process.type === 'renderer') { + return true; + } + + // Internet Explorer and Edge do not support colors. + if (typeof navigator !== 'undefined' && navigator.userAgent && navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/)) { + return false; + } + + // is webkit? http://stackoverflow.com/a/16459606/376773 + // document is undefined in react-native: https://github.com/facebook/react-native/pull/1632 + return (typeof document !== 'undefined' && document.documentElement && document.documentElement.style && document.documentElement.style.WebkitAppearance) || + // is firebug? http://stackoverflow.com/a/398120/376773 + (typeof window !== 'undefined' && window.console && (window.console.firebug || (window.console.exception && window.console.table))) || + // is firefox >= v31? + // https://developer.mozilla.org/en-US/docs/Tools/Web_Console#Styling_messages + (typeof navigator !== 'undefined' && navigator.userAgent && navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/) && parseInt(RegExp.$1, 10) >= 31) || + // double check webkit in userAgent just in case we are in a worker + (typeof navigator !== 'undefined' && navigator.userAgent && navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)); +} + +/** + * Map %j to `JSON.stringify()`, since no Web Inspectors do that by default. + */ + +exports.formatters.j = function(v) { + try { + return JSON.stringify(v); + } catch (err) { + return '[UnexpectedJSONParseError]: ' + err.message; + } +}; + + +/** + * Colorize log arguments if enabled. + * + * @api public + */ + +function formatArgs(args) { + var useColors = this.useColors; + + args[0] = (useColors ? '%c' : '') + + this.namespace + + (useColors ? ' %c' : ' ') + + args[0] + + (useColors ? '%c ' : ' ') + + '+' + exports.humanize(this.diff); + + if (!useColors) return; + + var c = 'color: ' + this.color; + args.splice(1, 0, c, 'color: inherit') + + // the final "%c" is somewhat tricky, because there could be other + // arguments passed either before or after the %c, so we need to + // figure out the correct index to insert the CSS into + var index = 0; + var lastC = 0; + args[0].replace(/%[a-zA-Z%]/g, function(match) { + if ('%%' === match) return; + index++; + if ('%c' === match) { + // we only are interested in the *last* %c + // (the user may have provided their own) + lastC = index; + } + }); + + args.splice(lastC, 0, c); +} + +/** + * Invokes `console.log()` when available. + * No-op when `console.log` is not a "function". + * + * @api public + */ + +function log() { + // this hackery is required for IE8/9, where + // the `console.log` function doesn't have 'apply' + return 'object' === typeof console + && console.log + && Function.prototype.apply.call(console.log, console, arguments); +} + +/** + * Save `namespaces`. + * + * @param {String} namespaces + * @api private + */ + +function save(namespaces) { + try { + if (null == namespaces) { + exports.storage.removeItem('debug'); + } else { + exports.storage.debug = namespaces; + } + } catch(e) {} +} + +/** + * Load `namespaces`. + * + * @return {String} returns the previously persisted debug modes + * @api private + */ + +function load() { + var r; + try { + r = exports.storage.debug; + } catch(e) {} + + // If debug isn't set in LS, and we're in Electron, try to load $DEBUG + if (!r && typeof process !== 'undefined' && 'env' in process) { + r = process.env.DEBUG; + } + + return r; +} + +/** + * Enable namespaces listed in `localStorage.debug` initially. + */ + +exports.enable(load()); + +/** + * Localstorage attempts to return the localstorage. + * + * This is necessary because safari throws + * when a user disables cookies/localstorage + * and you attempt to access it. + * + * @return {LocalStorage} + * @api private + */ + +function localstorage() { + try { + return window.localStorage; + } catch (e) {} +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(33))) + +/***/ }), +/* 33 */ +/***/ (function(module, exports) { + +// shim for using process in browser +var process = module.exports = {}; + +// cached from whatever global is present so that test runners that stub it +// don't break things. But we need to wrap it in a try catch in case it is +// wrapped in strict mode code which doesn't define any globals. It's inside a +// function because try/catches deoptimize in certain engines. + +var cachedSetTimeout; +var cachedClearTimeout; + +function defaultSetTimout() { + throw new Error('setTimeout has not been defined'); +} +function defaultClearTimeout () { + throw new Error('clearTimeout has not been defined'); +} +(function () { + try { + if (typeof setTimeout === 'function') { + cachedSetTimeout = setTimeout; + } else { + cachedSetTimeout = defaultSetTimout; + } + } catch (e) { + cachedSetTimeout = defaultSetTimout; + } + try { + if (typeof clearTimeout === 'function') { + cachedClearTimeout = clearTimeout; + } else { + cachedClearTimeout = defaultClearTimeout; + } + } catch (e) { + cachedClearTimeout = defaultClearTimeout; + } +} ()) +function runTimeout(fun) { + if (cachedSetTimeout === setTimeout) { + //normal enviroments in sane situations + return setTimeout(fun, 0); + } + // if setTimeout wasn't available but was latter defined + if ((cachedSetTimeout === defaultSetTimout || !cachedSetTimeout) && setTimeout) { + cachedSetTimeout = setTimeout; + return setTimeout(fun, 0); + } + try { + // when when somebody has screwed with setTimeout but no I.E. maddness + return cachedSetTimeout(fun, 0); + } catch(e){ + try { + // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally + return cachedSetTimeout.call(null, fun, 0); + } catch(e){ + // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error + return cachedSetTimeout.call(this, fun, 0); + } + } + + +} +function runClearTimeout(marker) { + if (cachedClearTimeout === clearTimeout) { + //normal enviroments in sane situations + return clearTimeout(marker); + } + // if clearTimeout wasn't available but was latter defined + if ((cachedClearTimeout === defaultClearTimeout || !cachedClearTimeout) && clearTimeout) { + cachedClearTimeout = clearTimeout; + return clearTimeout(marker); + } + try { + // when when somebody has screwed with setTimeout but no I.E. maddness + return cachedClearTimeout(marker); + } catch (e){ + try { + // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally + return cachedClearTimeout.call(null, marker); + } catch (e){ + // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error. + // Some versions of I.E. have different rules for clearTimeout vs setTimeout + return cachedClearTimeout.call(this, marker); + } + } + + + +} +var queue = []; +var draining = false; +var currentQueue; +var queueIndex = -1; + +function cleanUpNextTick() { + if (!draining || !currentQueue) { + return; + } + draining = false; + if (currentQueue.length) { + queue = currentQueue.concat(queue); + } else { + queueIndex = -1; + } + if (queue.length) { + drainQueue(); + } +} + +function drainQueue() { + if (draining) { + return; + } + var timeout = runTimeout(cleanUpNextTick); + draining = true; + + var len = queue.length; + while(len) { + currentQueue = queue; + queue = []; + while (++queueIndex < len) { + if (currentQueue) { + currentQueue[queueIndex].run(); + } + } + queueIndex = -1; + len = queue.length; + } + currentQueue = null; + draining = false; + runClearTimeout(timeout); +} + +process.nextTick = function (fun) { + var args = new Array(arguments.length - 1); + if (arguments.length > 1) { + for (var i = 1; i < arguments.length; i++) { + args[i - 1] = arguments[i]; + } + } + queue.push(new Item(fun, args)); + if (queue.length === 1 && !draining) { + runTimeout(drainQueue); + } +}; + +// v8 likes predictible objects +function Item(fun, array) { + this.fun = fun; + this.array = array; +} +Item.prototype.run = function () { + this.fun.apply(null, this.array); +}; +process.title = 'browser'; +process.browser = true; +process.env = {}; +process.argv = []; +process.version = ''; // empty string to avoid regexp issues +process.versions = {}; + +function noop() {} + +process.on = noop; +process.addListener = noop; +process.once = noop; +process.off = noop; +process.removeListener = noop; +process.removeAllListeners = noop; +process.emit = noop; +process.prependListener = noop; +process.prependOnceListener = noop; + +process.listeners = function (name) { return [] } + +process.binding = function (name) { + throw new Error('process.binding is not supported'); +}; + +process.cwd = function () { return '/' }; +process.chdir = function (dir) { + throw new Error('process.chdir is not supported'); +}; +process.umask = function() { return 0; }; + + +/***/ }), +/* 34 */ +/***/ (function(module, exports) { + +/** + * Compiles a querystring + * Returns string representation of the object + * + * @param {Object} + * @api private + */ + +exports.encode = function (obj) { + var str = ''; + + for (var i in obj) { + if (obj.hasOwnProperty(i)) { + if (str.length) str += '&'; + str += encodeURIComponent(i) + '=' + encodeURIComponent(obj[i]); + } + } + + return str; +}; + +/** + * Parses a simple querystring into an object + * + * @param {String} qs + * @api private + */ + +exports.decode = function(qs){ + var qry = {}; + var pairs = qs.split('&'); + for (var i = 0, l = pairs.length; i < l; i++) { + var pair = pairs[i].split('='); + qry[decodeURIComponent(pair[0])] = decodeURIComponent(pair[1]); + } + return qry; +}; + + +/***/ }), +/* 35 */ +/***/ (function(module, exports) { + + +module.exports = function(a, b){ + var fn = function(){}; + fn.prototype = b.prototype; + a.prototype = new fn; + a.prototype.constructor = a; +}; + +/***/ }), +/* 36 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(process) {/** + * This is the web browser implementation of `debug()`. + * + * Expose `debug()` as the module. + */ + +exports = module.exports = __webpack_require__(128); +exports.log = log; +exports.formatArgs = formatArgs; +exports.save = save; +exports.load = load; +exports.useColors = useColors; +exports.storage = 'undefined' != typeof chrome + && 'undefined' != typeof chrome.storage + ? chrome.storage.local + : localstorage(); + +/** + * Colors. + */ + +exports.colors = [ + '#0000CC', '#0000FF', '#0033CC', '#0033FF', '#0066CC', '#0066FF', '#0099CC', + '#0099FF', '#00CC00', '#00CC33', '#00CC66', '#00CC99', '#00CCCC', '#00CCFF', + '#3300CC', '#3300FF', '#3333CC', '#3333FF', '#3366CC', '#3366FF', '#3399CC', + '#3399FF', '#33CC00', '#33CC33', '#33CC66', '#33CC99', '#33CCCC', '#33CCFF', + '#6600CC', '#6600FF', '#6633CC', '#6633FF', '#66CC00', '#66CC33', '#9900CC', + '#9900FF', '#9933CC', '#9933FF', '#99CC00', '#99CC33', '#CC0000', '#CC0033', + '#CC0066', '#CC0099', '#CC00CC', '#CC00FF', '#CC3300', '#CC3333', '#CC3366', + '#CC3399', '#CC33CC', '#CC33FF', '#CC6600', '#CC6633', '#CC9900', '#CC9933', + '#CCCC00', '#CCCC33', '#FF0000', '#FF0033', '#FF0066', '#FF0099', '#FF00CC', + '#FF00FF', '#FF3300', '#FF3333', '#FF3366', '#FF3399', '#FF33CC', '#FF33FF', + '#FF6600', '#FF6633', '#FF9900', '#FF9933', '#FFCC00', '#FFCC33' +]; + +/** + * Currently only WebKit-based Web Inspectors, Firefox >= v31, + * and the Firebug extension (any Firefox version) are known + * to support "%c" CSS customizations. + * + * TODO: add a `localStorage` variable to explicitly enable/disable colors + */ + +function useColors() { + // NB: In an Electron preload script, document will be defined but not fully + // initialized. Since we know we're in Chrome, we'll just detect this case + // explicitly + if (typeof window !== 'undefined' && window.process && window.process.type === 'renderer') { + return true; + } + + // Internet Explorer and Edge do not support colors. + if (typeof navigator !== 'undefined' && navigator.userAgent && navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/)) { + return false; + } + + // is webkit? http://stackoverflow.com/a/16459606/376773 + // document is undefined in react-native: https://github.com/facebook/react-native/pull/1632 + return (typeof document !== 'undefined' && document.documentElement && document.documentElement.style && document.documentElement.style.WebkitAppearance) || + // is firebug? http://stackoverflow.com/a/398120/376773 + (typeof window !== 'undefined' && window.console && (window.console.firebug || (window.console.exception && window.console.table))) || + // is firefox >= v31? + // https://developer.mozilla.org/en-US/docs/Tools/Web_Console#Styling_messages + (typeof navigator !== 'undefined' && navigator.userAgent && navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/) && parseInt(RegExp.$1, 10) >= 31) || + // double check webkit in userAgent just in case we are in a worker + (typeof navigator !== 'undefined' && navigator.userAgent && navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)); +} + +/** + * Map %j to `JSON.stringify()`, since no Web Inspectors do that by default. + */ + +exports.formatters.j = function(v) { + try { + return JSON.stringify(v); + } catch (err) { + return '[UnexpectedJSONParseError]: ' + err.message; + } +}; + + +/** + * Colorize log arguments if enabled. + * + * @api public + */ + +function formatArgs(args) { + var useColors = this.useColors; + + args[0] = (useColors ? '%c' : '') + + this.namespace + + (useColors ? ' %c' : ' ') + + args[0] + + (useColors ? '%c ' : ' ') + + '+' + exports.humanize(this.diff); + + if (!useColors) return; + + var c = 'color: ' + this.color; + args.splice(1, 0, c, 'color: inherit') + + // the final "%c" is somewhat tricky, because there could be other + // arguments passed either before or after the %c, so we need to + // figure out the correct index to insert the CSS into + var index = 0; + var lastC = 0; + args[0].replace(/%[a-zA-Z%]/g, function(match) { + if ('%%' === match) return; + index++; + if ('%c' === match) { + // we only are interested in the *last* %c + // (the user may have provided their own) + lastC = index; + } + }); + + args.splice(lastC, 0, c); +} + +/** + * Invokes `console.log()` when available. + * No-op when `console.log` is not a "function". + * + * @api public + */ + +function log() { + // this hackery is required for IE8/9, where + // the `console.log` function doesn't have 'apply' + return 'object' === typeof console + && console.log + && Function.prototype.apply.call(console.log, console, arguments); +} + +/** + * Save `namespaces`. + * + * @param {String} namespaces + * @api private + */ + +function save(namespaces) { + try { + if (null == namespaces) { + exports.storage.removeItem('debug'); + } else { + exports.storage.debug = namespaces; + } + } catch(e) {} +} + +/** + * Load `namespaces`. + * + * @return {String} returns the previously persisted debug modes + * @api private + */ + +function load() { + var r; + try { + r = exports.storage.debug; + } catch(e) {} + + // If debug isn't set in LS, and we're in Electron, try to load $DEBUG + if (!r && typeof process !== 'undefined' && 'env' in process) { + r = process.env.DEBUG; + } + + return r; +} + +/** + * Enable namespaces listed in `localStorage.debug` initially. + */ + +exports.enable(load()); + +/** + * Localstorage attempts to return the localstorage. + * + * This is necessary because safari throws + * when a user disables cookies/localstorage + * and you attempt to access it. + * + * @return {LocalStorage} + * @api private + */ + +function localstorage() { + try { + return window.localStorage; + } catch (e) {} +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(33))) + +/***/ }), +/* 37 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var __extends = (this && this.__extends) || function (d, b) { + for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +}; +var Observable_1 = __webpack_require__(1); +var Subscriber_1 = __webpack_require__(3); +var Subscription_1 = __webpack_require__(12); +var ObjectUnsubscribedError_1 = __webpack_require__(73); +var SubjectSubscription_1 = __webpack_require__(134); +var rxSubscriber_1 = __webpack_require__(44); +/** + * @class SubjectSubscriber + */ +var SubjectSubscriber = (function (_super) { + __extends(SubjectSubscriber, _super); + function SubjectSubscriber(destination) { + _super.call(this, destination); + this.destination = destination; + } + return SubjectSubscriber; +}(Subscriber_1.Subscriber)); +exports.SubjectSubscriber = SubjectSubscriber; +/** + * @class Subject + */ +var Subject = (function (_super) { + __extends(Subject, _super); + function Subject() { + _super.call(this); + this.observers = []; + this.closed = false; + this.isStopped = false; + this.hasError = false; + this.thrownError = null; + } + Subject.prototype[rxSubscriber_1.rxSubscriber] = function () { + return new SubjectSubscriber(this); + }; + Subject.prototype.lift = function (operator) { + var subject = new AnonymousSubject(this, this); + subject.operator = operator; + return subject; + }; + Subject.prototype.next = function (value) { + if (this.closed) { + throw new ObjectUnsubscribedError_1.ObjectUnsubscribedError(); + } + if (!this.isStopped) { + var observers = this.observers; + var len = observers.length; + var copy = observers.slice(); + for (var i = 0; i < len; i++) { + copy[i].next(value); + } + } + }; + Subject.prototype.error = function (err) { + if (this.closed) { + throw new ObjectUnsubscribedError_1.ObjectUnsubscribedError(); + } + this.hasError = true; + this.thrownError = err; + this.isStopped = true; + var observers = this.observers; + var len = observers.length; + var copy = observers.slice(); + for (var i = 0; i < len; i++) { + copy[i].error(err); + } + this.observers.length = 0; + }; + Subject.prototype.complete = function () { + if (this.closed) { + throw new ObjectUnsubscribedError_1.ObjectUnsubscribedError(); + } + this.isStopped = true; + var observers = this.observers; + var len = observers.length; + var copy = observers.slice(); + for (var i = 0; i < len; i++) { + copy[i].complete(); + } + this.observers.length = 0; + }; + Subject.prototype.unsubscribe = function () { + this.isStopped = true; + this.closed = true; + this.observers = null; + }; + Subject.prototype._trySubscribe = function (subscriber) { + if (this.closed) { + throw new ObjectUnsubscribedError_1.ObjectUnsubscribedError(); + } + else { + return _super.prototype._trySubscribe.call(this, subscriber); + } + }; + /** @deprecated internal use only */ Subject.prototype._subscribe = function (subscriber) { + if (this.closed) { + throw new ObjectUnsubscribedError_1.ObjectUnsubscribedError(); + } + else if (this.hasError) { + subscriber.error(this.thrownError); + return Subscription_1.Subscription.EMPTY; + } + else if (this.isStopped) { + subscriber.complete(); + return Subscription_1.Subscription.EMPTY; + } + else { + this.observers.push(subscriber); + return new SubjectSubscription_1.SubjectSubscription(this, subscriber); + } + }; + Subject.prototype.asObservable = function () { + var observable = new Observable_1.Observable(); + observable.source = this; + return observable; + }; + Subject.create = function (destination, source) { + return new AnonymousSubject(destination, source); + }; + return Subject; +}(Observable_1.Observable)); +exports.Subject = Subject; +/** + * @class AnonymousSubject + */ +var AnonymousSubject = (function (_super) { + __extends(AnonymousSubject, _super); + function AnonymousSubject(destination, source) { + _super.call(this); + this.destination = destination; + this.source = source; + } + AnonymousSubject.prototype.next = function (value) { + var destination = this.destination; + if (destination && destination.next) { + destination.next(value); + } + }; + AnonymousSubject.prototype.error = function (err) { + var destination = this.destination; + if (destination && destination.error) { + this.destination.error(err); + } + }; + AnonymousSubject.prototype.complete = function () { + var destination = this.destination; + if (destination && destination.complete) { + this.destination.complete(); + } + }; + /** @deprecated internal use only */ AnonymousSubject.prototype._subscribe = function (subscriber) { + var source = this.source; + if (source) { + return this.source.subscribe(subscriber); + } + else { + return Subscription_1.Subscription.EMPTY; + } + }; + return AnonymousSubject; +}(Subject)); +exports.AnonymousSubject = AnonymousSubject; +//# sourceMappingURL=Subject.js.map + +/***/ }), +/* 38 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var Observable_1 = __webpack_require__(1); +var ArrayObservable_1 = __webpack_require__(23); +var isScheduler_1 = __webpack_require__(25); +var mergeAll_1 = __webpack_require__(55); +/* tslint:enable:max-line-length */ +/** + * Creates an output Observable which concurrently emits all values from every + * given input Observable. + * + * Flattens multiple Observables together by blending + * their values into one Observable. + * + * + * + * `merge` subscribes to each given input Observable (as arguments), and simply + * forwards (without doing any transformation) all the values from all the input + * Observables to the output Observable. The output Observable only completes + * once all input Observables have completed. Any error delivered by an input + * Observable will be immediately emitted on the output Observable. + * + * @example Merge together two Observables: 1s interval and clicks + * var clicks = Rx.Observable.fromEvent(document, 'click'); + * var timer = Rx.Observable.interval(1000); + * var clicksOrTimer = Rx.Observable.merge(clicks, timer); + * clicksOrTimer.subscribe(x => console.log(x)); + * + * // Results in the following: + * // timer will emit ascending values, one every second(1000ms) to console + * // clicks logs MouseEvents to console everytime the "document" is clicked + * // Since the two streams are merged you see these happening + * // as they occur. + * + * @example Merge together 3 Observables, but only 2 run concurrently + * var timer1 = Rx.Observable.interval(1000).take(10); + * var timer2 = Rx.Observable.interval(2000).take(6); + * var timer3 = Rx.Observable.interval(500).take(10); + * var concurrent = 2; // the argument + * var merged = Rx.Observable.merge(timer1, timer2, timer3, concurrent); + * merged.subscribe(x => console.log(x)); + * + * // Results in the following: + * // - First timer1 and timer2 will run concurrently + * // - timer1 will emit a value every 1000ms for 10 iterations + * // - timer2 will emit a value every 2000ms for 6 iterations + * // - after timer1 hits it's max iteration, timer2 will + * // continue, and timer3 will start to run concurrently with timer2 + * // - when timer2 hits it's max iteration it terminates, and + * // timer3 will continue to emit a value every 500ms until it is complete + * + * @see {@link mergeAll} + * @see {@link mergeMap} + * @see {@link mergeMapTo} + * @see {@link mergeScan} + * + * @param {...ObservableInput} observables Input Observables to merge together. + * @param {number} [concurrent=Number.POSITIVE_INFINITY] Maximum number of input + * Observables being subscribed to concurrently. + * @param {Scheduler} [scheduler=null] The IScheduler to use for managing + * concurrency of input Observables. + * @return {Observable} an Observable that emits items that are the result of + * every input Observable. + * @static true + * @name merge + * @owner Observable + */ +function merge() { + var observables = []; + for (var _i = 0; _i < arguments.length; _i++) { + observables[_i - 0] = arguments[_i]; + } + var concurrent = Number.POSITIVE_INFINITY; + var scheduler = null; + var last = observables[observables.length - 1]; + if (isScheduler_1.isScheduler(last)) { + scheduler = observables.pop(); + if (observables.length > 1 && typeof observables[observables.length - 1] === 'number') { + concurrent = observables.pop(); + } + } + else if (typeof last === 'number') { + concurrent = observables.pop(); + } + if (scheduler === null && observables.length === 1 && observables[0] instanceof Observable_1.Observable) { + return observables[0]; + } + return mergeAll_1.mergeAll(concurrent)(new ArrayObservable_1.ArrayObservable(observables, scheduler)); +} +exports.merge = merge; +//# sourceMappingURL=merge.js.map + +/***/ }), +/* 39 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var __extends = (this && this.__extends) || function (d, b) { + for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +}; +var Subscriber_1 = __webpack_require__(3); +/** + * Returns an Observable that skips the first `count` items emitted by the source Observable. + * + * + * + * @param {Number} count - The number of times, items emitted by source Observable should be skipped. + * @return {Observable} An Observable that skips values emitted by the source Observable. + * + * @method skip + * @owner Observable + */ +function skip(count) { + return function (source) { return source.lift(new SkipOperator(count)); }; +} +exports.skip = skip; +var SkipOperator = (function () { + function SkipOperator(total) { + this.total = total; + } + SkipOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new SkipSubscriber(subscriber, this.total)); + }; + return SkipOperator; +}()); +/** + * We need this JSDoc comment for affecting ESDoc. + * @ignore + * @extends {Ignored} + */ +var SkipSubscriber = (function (_super) { + __extends(SkipSubscriber, _super); + function SkipSubscriber(destination, total) { + _super.call(this, destination); + this.total = total; + this.count = 0; + } + SkipSubscriber.prototype._next = function (x) { + if (++this.count > this.total) { + this.destination.next(x); + } + }; + return SkipSubscriber; +}(Subscriber_1.Subscriber)); +//# sourceMappingURL=skip.js.map + +/***/ }), +/* 40 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var __extends = (this && this.__extends) || function (d, b) { + for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +}; +var Subscriber_1 = __webpack_require__(3); +var tryCatch_1 = __webpack_require__(43); +var errorObject_1 = __webpack_require__(27); +/* tslint:enable:max-line-length */ +/** + * Returns an Observable that emits all items emitted by the source Observable that are distinct by comparison from the previous item. + * + * If a comparator function is provided, then it will be called for each item to test for whether or not that value should be emitted. + * + * If a comparator function is not provided, an equality check is used by default. + * + * @example A simple example with numbers + * Observable.of(1, 1, 2, 2, 2, 1, 1, 2, 3, 3, 4) + * .distinctUntilChanged() + * .subscribe(x => console.log(x)); // 1, 2, 1, 2, 3, 4 + * + * @example An example using a compare function + * interface Person { + * age: number, + * name: string + * } + * + * Observable.of( + * { age: 4, name: 'Foo'}, + * { age: 7, name: 'Bar'}, + * { age: 5, name: 'Foo'}) + * { age: 6, name: 'Foo'}) + * .distinctUntilChanged((p: Person, q: Person) => p.name === q.name) + * .subscribe(x => console.log(x)); + * + * // displays: + * // { age: 4, name: 'Foo' } + * // { age: 7, name: 'Bar' } + * // { age: 5, name: 'Foo' } + * + * @see {@link distinct} + * @see {@link distinctUntilKeyChanged} + * + * @param {function} [compare] Optional comparison function called to test if an item is distinct from the previous item in the source. + * @return {Observable} An Observable that emits items from the source Observable with distinct values. + * @method distinctUntilChanged + * @owner Observable + */ +function distinctUntilChanged(compare, keySelector) { + return function (source) { return source.lift(new DistinctUntilChangedOperator(compare, keySelector)); }; +} +exports.distinctUntilChanged = distinctUntilChanged; +var DistinctUntilChangedOperator = (function () { + function DistinctUntilChangedOperator(compare, keySelector) { + this.compare = compare; + this.keySelector = keySelector; + } + DistinctUntilChangedOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new DistinctUntilChangedSubscriber(subscriber, this.compare, this.keySelector)); + }; + return DistinctUntilChangedOperator; +}()); +/** + * We need this JSDoc comment for affecting ESDoc. + * @ignore + * @extends {Ignored} + */ +var DistinctUntilChangedSubscriber = (function (_super) { + __extends(DistinctUntilChangedSubscriber, _super); + function DistinctUntilChangedSubscriber(destination, compare, keySelector) { + _super.call(this, destination); + this.keySelector = keySelector; + this.hasKey = false; + if (typeof compare === 'function') { + this.compare = compare; + } + } + DistinctUntilChangedSubscriber.prototype.compare = function (x, y) { + return x === y; + }; + DistinctUntilChangedSubscriber.prototype._next = function (value) { + var keySelector = this.keySelector; + var key = value; + if (keySelector) { + key = tryCatch_1.tryCatch(this.keySelector)(value); + if (key === errorObject_1.errorObject) { + return this.destination.error(errorObject_1.errorObject.e); + } + } + var result = false; + if (this.hasKey) { + result = tryCatch_1.tryCatch(this.compare)(this.key, key); + if (result === errorObject_1.errorObject) { + return this.destination.error(errorObject_1.errorObject.e); + } + } + else { + this.hasKey = true; + } + if (Boolean(result) === false) { + this.key = key; + this.destination.next(value); + } + }; + return DistinctUntilChangedSubscriber; +}(Subscriber_1.Subscriber)); +//# sourceMappingURL=distinctUntilChanged.js.map + +/***/ }), +/* 41 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var FromEventObservable_1 = __webpack_require__(172); +exports.fromEvent = FromEventObservable_1.FromEventObservable.create; +//# sourceMappingURL=fromEvent.js.map + +/***/ }), +/* 42 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +function isFunction(x) { + return typeof x === 'function'; +} +exports.isFunction = isFunction; +//# sourceMappingURL=isFunction.js.map + +/***/ }), +/* 43 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var errorObject_1 = __webpack_require__(27); +var tryCatchTarget; +function tryCatcher() { + try { + return tryCatchTarget.apply(this, arguments); + } + catch (e) { + errorObject_1.errorObject.e = e; + return errorObject_1.errorObject; + } +} +function tryCatch(fn) { + tryCatchTarget = fn; + return tryCatcher; +} +exports.tryCatch = tryCatch; +; +//# sourceMappingURL=tryCatch.js.map + +/***/ }), +/* 44 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var root_1 = __webpack_require__(7); +var Symbol = root_1.root.Symbol; +exports.rxSubscriber = (typeof Symbol === 'function' && typeof Symbol.for === 'function') ? + Symbol.for('rxSubscriber') : '@@rxSubscriber'; +/** + * @deprecated use rxSubscriber instead + */ +exports.$$rxSubscriber = exports.rxSubscriber; +//# sourceMappingURL=rxSubscriber.js.map + +/***/ }), +/* 45 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var root_1 = __webpack_require__(7); +function getSymbolObservable(context) { + var $$observable; + var Symbol = context.Symbol; + if (typeof Symbol === 'function') { + if (Symbol.observable) { + $$observable = Symbol.observable; + } + else { + $$observable = Symbol('observable'); + Symbol.observable = $$observable; + } + } + else { + $$observable = '@@observable'; + } + return $$observable; +} +exports.getSymbolObservable = getSymbolObservable; +exports.observable = getSymbolObservable(root_1.root); +/** + * @deprecated use observable instead + */ +exports.$$observable = exports.observable; +//# sourceMappingURL=observable.js.map + +/***/ }), +/* 46 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var __extends = (this && this.__extends) || function (d, b) { + for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +}; +var Observable_1 = __webpack_require__(1); +/** + * We need this JSDoc comment for affecting ESDoc. + * @extends {Ignored} + * @hide true + */ +var ScalarObservable = (function (_super) { + __extends(ScalarObservable, _super); + function ScalarObservable(value, scheduler) { + _super.call(this); + this.value = value; + this.scheduler = scheduler; + this._isScalar = true; + if (scheduler) { + this._isScalar = false; + } + } + ScalarObservable.create = function (value, scheduler) { + return new ScalarObservable(value, scheduler); + }; + ScalarObservable.dispatch = function (state) { + var done = state.done, value = state.value, subscriber = state.subscriber; + if (done) { + subscriber.complete(); + return; + } + subscriber.next(value); + if (subscriber.closed) { + return; + } + state.done = true; + this.schedule(state); + }; + /** @deprecated internal use only */ ScalarObservable.prototype._subscribe = function (subscriber) { + var value = this.value; + var scheduler = this.scheduler; + if (scheduler) { + return scheduler.schedule(ScalarObservable.dispatch, 0, { + done: false, value: value, subscriber: subscriber + }); + } + else { + subscriber.next(value); + if (!subscriber.closed) { + subscriber.complete(); + } + } + }; + return ScalarObservable; +}(Observable_1.Observable)); +exports.ScalarObservable = ScalarObservable; +//# sourceMappingURL=ScalarObservable.js.map + +/***/ }), +/* 47 */ +/***/ (function(module, exports) { + +/** + * Helpers. + */ + +var s = 1000; +var m = s * 60; +var h = m * 60; +var d = h * 24; +var y = d * 365.25; + +/** + * Parse or format the given `val`. + * + * Options: + * + * - `long` verbose formatting [false] + * + * @param {String|Number} val + * @param {Object} [options] + * @throws {Error} throw an error if val is not a non-empty string or a number + * @return {String|Number} + * @api public + */ + +module.exports = function(val, options) { + options = options || {}; + var type = typeof val; + if (type === 'string' && val.length > 0) { + return parse(val); + } else if (type === 'number' && isNaN(val) === false) { + return options.long ? fmtLong(val) : fmtShort(val); + } + throw new Error( + 'val is not a non-empty string or a valid number. val=' + + JSON.stringify(val) + ); +}; + +/** + * Parse the given `str` and return milliseconds. + * + * @param {String} str + * @return {Number} + * @api private + */ + +function parse(str) { + str = String(str); + if (str.length > 100) { + return; + } + var match = /^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec( + str + ); + if (!match) { + return; + } + var n = parseFloat(match[1]); + var type = (match[2] || 'ms').toLowerCase(); + switch (type) { + case 'years': + case 'year': + case 'yrs': + case 'yr': + case 'y': + return n * y; + case 'days': + case 'day': + case 'd': + return n * d; + case 'hours': + case 'hour': + case 'hrs': + case 'hr': + case 'h': + return n * h; + case 'minutes': + case 'minute': + case 'mins': + case 'min': + case 'm': + return n * m; + case 'seconds': + case 'second': + case 'secs': + case 'sec': + case 's': + return n * s; + case 'milliseconds': + case 'millisecond': + case 'msecs': + case 'msec': + case 'ms': + return n; + default: + return undefined; + } +} + +/** + * Short format for `ms`. + * + * @param {Number} ms + * @return {String} + * @api private + */ + +function fmtShort(ms) { + if (ms >= d) { + return Math.round(ms / d) + 'd'; + } + if (ms >= h) { + return Math.round(ms / h) + 'h'; + } + if (ms >= m) { + return Math.round(ms / m) + 'm'; + } + if (ms >= s) { + return Math.round(ms / s) + 's'; + } + return ms + 'ms'; +} + +/** + * Long format for `ms`. + * + * @param {Number} ms + * @return {String} + * @api private + */ + +function fmtLong(ms) { + return plural(ms, d, 'day') || + plural(ms, h, 'hour') || + plural(ms, m, 'minute') || + plural(ms, s, 'second') || + ms + ' ms'; +} + +/** + * Pluralization helper. + */ + +function plural(ms, n, name) { + if (ms < n) { + return; + } + if (ms < n * 1.5) { + return Math.floor(ms / n) + ' ' + name; + } + return Math.ceil(ms / n) + ' ' + name + 's'; +} + + +/***/ }), +/* 48 */ +/***/ (function(module, exports, __webpack_require__) { + + +/** + * Module dependencies. + */ + +var debug = __webpack_require__(111)('socket.io-parser'); +var Emitter = __webpack_require__(17); +var binary = __webpack_require__(113); +var isArray = __webpack_require__(62); +var isBuf = __webpack_require__(63); + +/** + * Protocol version. + * + * @api public + */ + +exports.protocol = 4; + +/** + * Packet types. + * + * @api public + */ + +exports.types = [ + 'CONNECT', + 'DISCONNECT', + 'EVENT', + 'ACK', + 'ERROR', + 'BINARY_EVENT', + 'BINARY_ACK' +]; + +/** + * Packet type `connect`. + * + * @api public + */ + +exports.CONNECT = 0; + +/** + * Packet type `disconnect`. + * + * @api public + */ + +exports.DISCONNECT = 1; + +/** + * Packet type `event`. + * + * @api public + */ + +exports.EVENT = 2; + +/** + * Packet type `ack`. + * + * @api public + */ + +exports.ACK = 3; + +/** + * Packet type `error`. + * + * @api public + */ + +exports.ERROR = 4; + +/** + * Packet type 'binary event' + * + * @api public + */ + +exports.BINARY_EVENT = 5; + +/** + * Packet type `binary ack`. For acks with binary arguments. + * + * @api public + */ + +exports.BINARY_ACK = 6; + +/** + * Encoder constructor. + * + * @api public + */ + +exports.Encoder = Encoder; + +/** + * Decoder constructor. + * + * @api public + */ + +exports.Decoder = Decoder; + +/** + * A socket.io Encoder instance + * + * @api public + */ + +function Encoder() {} + +var ERROR_PACKET = exports.ERROR + '"encode error"'; + +/** + * Encode a packet as a single string if non-binary, or as a + * buffer sequence, depending on packet type. + * + * @param {Object} obj - packet object + * @param {Function} callback - function to handle encodings (likely engine.write) + * @return Calls callback with Array of encodings + * @api public + */ + +Encoder.prototype.encode = function(obj, callback){ + debug('encoding packet %j', obj); + + if (exports.BINARY_EVENT === obj.type || exports.BINARY_ACK === obj.type) { + encodeAsBinary(obj, callback); + } else { + var encoding = encodeAsString(obj); + callback([encoding]); + } +}; + +/** + * Encode packet as string. + * + * @param {Object} packet + * @return {String} encoded + * @api private + */ + +function encodeAsString(obj) { + + // first is type + var str = '' + obj.type; + + // attachments if we have them + if (exports.BINARY_EVENT === obj.type || exports.BINARY_ACK === obj.type) { + str += obj.attachments + '-'; + } + + // if we have a namespace other than `/` + // we append it followed by a comma `,` + if (obj.nsp && '/' !== obj.nsp) { + str += obj.nsp + ','; + } + + // immediately followed by the id + if (null != obj.id) { + str += obj.id; + } + + // json data + if (null != obj.data) { + var payload = tryStringify(obj.data); + if (payload !== false) { + str += payload; + } else { + return ERROR_PACKET; + } + } + + debug('encoded %j as %s', obj, str); + return str; +} + +function tryStringify(str) { + try { + return JSON.stringify(str); + } catch(e){ + return false; + } +} + +/** + * Encode packet as 'buffer sequence' by removing blobs, and + * deconstructing packet into object with placeholders and + * a list of buffers. + * + * @param {Object} packet + * @return {Buffer} encoded + * @api private + */ + +function encodeAsBinary(obj, callback) { + + function writeEncoding(bloblessData) { + var deconstruction = binary.deconstructPacket(bloblessData); + var pack = encodeAsString(deconstruction.packet); + var buffers = deconstruction.buffers; + + buffers.unshift(pack); // add packet info to beginning of data list + callback(buffers); // write all the buffers + } + + binary.removeBlobs(obj, writeEncoding); +} + +/** + * A socket.io Decoder instance + * + * @return {Object} decoder + * @api public + */ + +function Decoder() { + this.reconstructor = null; +} + +/** + * Mix in `Emitter` with Decoder. + */ + +Emitter(Decoder.prototype); + +/** + * Decodes an encoded packet string into packet JSON. + * + * @param {String} obj - encoded packet + * @return {Object} packet + * @api public + */ + +Decoder.prototype.add = function(obj) { + var packet; + if (typeof obj === 'string') { + packet = decodeString(obj); + if (exports.BINARY_EVENT === packet.type || exports.BINARY_ACK === packet.type) { // binary packet's json + this.reconstructor = new BinaryReconstructor(packet); + + // no attachments, labeled binary but no binary data to follow + if (this.reconstructor.reconPack.attachments === 0) { + this.emit('decoded', packet); + } + } else { // non-binary full packet + this.emit('decoded', packet); + } + } else if (isBuf(obj) || obj.base64) { // raw binary data + if (!this.reconstructor) { + throw new Error('got binary data when not reconstructing a packet'); + } else { + packet = this.reconstructor.takeBinaryData(obj); + if (packet) { // received final buffer + this.reconstructor = null; + this.emit('decoded', packet); + } + } + } else { + throw new Error('Unknown type: ' + obj); + } +}; + +/** + * Decode a packet String (JSON data) + * + * @param {String} str + * @return {Object} packet + * @api private + */ + +function decodeString(str) { + var i = 0; + // look up type + var p = { + type: Number(str.charAt(0)) + }; + + if (null == exports.types[p.type]) { + return error('unknown packet type ' + p.type); + } + + // look up attachments if type binary + if (exports.BINARY_EVENT === p.type || exports.BINARY_ACK === p.type) { + var buf = ''; + while (str.charAt(++i) !== '-') { + buf += str.charAt(i); + if (i == str.length) break; + } + if (buf != Number(buf) || str.charAt(i) !== '-') { + throw new Error('Illegal attachments'); + } + p.attachments = Number(buf); + } + + // look up namespace (if any) + if ('/' === str.charAt(i + 1)) { + p.nsp = ''; + while (++i) { + var c = str.charAt(i); + if (',' === c) break; + p.nsp += c; + if (i === str.length) break; + } + } else { + p.nsp = '/'; + } + + // look up id + var next = str.charAt(i + 1); + if ('' !== next && Number(next) == next) { + p.id = ''; + while (++i) { + var c = str.charAt(i); + if (null == c || Number(c) != c) { + --i; + break; + } + p.id += str.charAt(i); + if (i === str.length) break; + } + p.id = Number(p.id); + } + + // look up json data + if (str.charAt(++i)) { + var payload = tryParse(str.substr(i)); + var isPayloadValid = payload !== false && (p.type === exports.ERROR || isArray(payload)); + if (isPayloadValid) { + p.data = payload; + } else { + return error('invalid payload'); + } + } + + debug('decoded %s as %j', str, p); + return p; +} + +function tryParse(str) { + try { + return JSON.parse(str); + } catch(e){ + return false; + } +} + +/** + * Deallocates a parser's resources + * + * @api public + */ + +Decoder.prototype.destroy = function() { + if (this.reconstructor) { + this.reconstructor.finishedReconstruction(); + } +}; + +/** + * A manager of a binary event's 'buffer sequence'. Should + * be constructed whenever a packet of type BINARY_EVENT is + * decoded. + * + * @param {Object} packet + * @return {BinaryReconstructor} initialized reconstructor + * @api private + */ + +function BinaryReconstructor(packet) { + this.reconPack = packet; + this.buffers = []; +} + +/** + * Method to be called when binary data received from connection + * after a BINARY_EVENT packet. + * + * @param {Buffer | ArrayBuffer} binData - the raw binary data received + * @return {null | Object} returns null if more binary data is expected or + * a reconstructed packet object if all buffers have been received. + * @api private + */ + +BinaryReconstructor.prototype.takeBinaryData = function(binData) { + this.buffers.push(binData); + if (this.buffers.length === this.reconPack.attachments) { // done with buffer list + var packet = binary.reconstructPacket(this.reconPack, this.buffers); + this.finishedReconstruction(); + return packet; + } + return null; +}; + +/** + * Cleans up binary packet reconstruction variables. + * + * @api private + */ + +BinaryReconstructor.prototype.finishedReconstruction = function() { + this.reconPack = null; + this.buffers = []; +}; + +function error(msg) { + return { + type: exports.ERROR, + data: 'parser error: ' + msg + }; +} + + +/***/ }), +/* 49 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(global) {/*! + * The buffer module from node.js, for the browser. + * + * @author Feross Aboukhadijeh + * @license MIT + */ +/* eslint-disable no-proto */ + + + +var base64 = __webpack_require__(114) +var ieee754 = __webpack_require__(115) +var isArray = __webpack_require__(116) + +exports.Buffer = Buffer +exports.SlowBuffer = SlowBuffer +exports.INSPECT_MAX_BYTES = 50 + +/** + * If `Buffer.TYPED_ARRAY_SUPPORT`: + * === true Use Uint8Array implementation (fastest) + * === false Use Object implementation (most compatible, even IE6) + * + * Browsers that support typed arrays are IE 10+, Firefox 4+, Chrome 7+, Safari 5.1+, + * Opera 11.6+, iOS 4.2+. + * + * Due to various browser bugs, sometimes the Object implementation will be used even + * when the browser supports typed arrays. + * + * Note: + * + * - Firefox 4-29 lacks support for adding new properties to `Uint8Array` instances, + * See: https://bugzilla.mozilla.org/show_bug.cgi?id=695438. + * + * - Chrome 9-10 is missing the `TypedArray.prototype.subarray` function. + * + * - IE10 has a broken `TypedArray.prototype.subarray` function which returns arrays of + * incorrect length in some situations. + + * We detect these buggy browsers and set `Buffer.TYPED_ARRAY_SUPPORT` to `false` so they + * get the Object implementation, which is slower but behaves correctly. + */ +Buffer.TYPED_ARRAY_SUPPORT = global.TYPED_ARRAY_SUPPORT !== undefined + ? global.TYPED_ARRAY_SUPPORT + : typedArraySupport() + +/* + * Export kMaxLength after typed array support is determined. + */ +exports.kMaxLength = kMaxLength() + +function typedArraySupport () { + try { + var arr = new Uint8Array(1) + arr.__proto__ = {__proto__: Uint8Array.prototype, foo: function () { return 42 }} + return arr.foo() === 42 && // typed array instances can be augmented + typeof arr.subarray === 'function' && // chrome 9-10 lack `subarray` + arr.subarray(1, 1).byteLength === 0 // ie10 has broken `subarray` + } catch (e) { + return false + } +} + +function kMaxLength () { + return Buffer.TYPED_ARRAY_SUPPORT + ? 0x7fffffff + : 0x3fffffff +} + +function createBuffer (that, length) { + if (kMaxLength() < length) { + throw new RangeError('Invalid typed array length') + } + if (Buffer.TYPED_ARRAY_SUPPORT) { + // Return an augmented `Uint8Array` instance, for best performance + that = new Uint8Array(length) + that.__proto__ = Buffer.prototype + } else { + // Fallback: Return an object instance of the Buffer class + if (that === null) { + that = new Buffer(length) + } + that.length = length + } + + return that +} + +/** + * The Buffer constructor returns instances of `Uint8Array` that have their + * prototype changed to `Buffer.prototype`. Furthermore, `Buffer` is a subclass of + * `Uint8Array`, so the returned instances will have all the node `Buffer` methods + * and the `Uint8Array` methods. Square bracket notation works as expected -- it + * returns a single octet. + * + * The `Uint8Array` prototype remains unmodified. + */ + +function Buffer (arg, encodingOrOffset, length) { + if (!Buffer.TYPED_ARRAY_SUPPORT && !(this instanceof Buffer)) { + return new Buffer(arg, encodingOrOffset, length) + } + + // Common case. + if (typeof arg === 'number') { + if (typeof encodingOrOffset === 'string') { + throw new Error( + 'If encoding is specified then the first argument must be a string' + ) + } + return allocUnsafe(this, arg) + } + return from(this, arg, encodingOrOffset, length) +} + +Buffer.poolSize = 8192 // not used by this implementation + +// TODO: Legacy, not needed anymore. Remove in next major version. +Buffer._augment = function (arr) { + arr.__proto__ = Buffer.prototype + return arr +} + +function from (that, value, encodingOrOffset, length) { + if (typeof value === 'number') { + throw new TypeError('"value" argument must not be a number') + } + + if (typeof ArrayBuffer !== 'undefined' && value instanceof ArrayBuffer) { + return fromArrayBuffer(that, value, encodingOrOffset, length) + } + + if (typeof value === 'string') { + return fromString(that, value, encodingOrOffset) + } + + return fromObject(that, value) +} + +/** + * Functionally equivalent to Buffer(arg, encoding) but throws a TypeError + * if value is a number. + * Buffer.from(str[, encoding]) + * Buffer.from(array) + * Buffer.from(buffer) + * Buffer.from(arrayBuffer[, byteOffset[, length]]) + **/ +Buffer.from = function (value, encodingOrOffset, length) { + return from(null, value, encodingOrOffset, length) +} + +if (Buffer.TYPED_ARRAY_SUPPORT) { + Buffer.prototype.__proto__ = Uint8Array.prototype + Buffer.__proto__ = Uint8Array + if (typeof Symbol !== 'undefined' && Symbol.species && + Buffer[Symbol.species] === Buffer) { + // Fix subarray() in ES2016. See: https://github.com/feross/buffer/pull/97 + Object.defineProperty(Buffer, Symbol.species, { + value: null, + configurable: true + }) + } +} + +function assertSize (size) { + if (typeof size !== 'number') { + throw new TypeError('"size" argument must be a number') + } else if (size < 0) { + throw new RangeError('"size" argument must not be negative') + } +} + +function alloc (that, size, fill, encoding) { + assertSize(size) + if (size <= 0) { + return createBuffer(that, size) + } + if (fill !== undefined) { + // Only pay attention to encoding if it's a string. This + // prevents accidentally sending in a number that would + // be interpretted as a start offset. + return typeof encoding === 'string' + ? createBuffer(that, size).fill(fill, encoding) + : createBuffer(that, size).fill(fill) + } + return createBuffer(that, size) +} + +/** + * Creates a new filled Buffer instance. + * alloc(size[, fill[, encoding]]) + **/ +Buffer.alloc = function (size, fill, encoding) { + return alloc(null, size, fill, encoding) +} + +function allocUnsafe (that, size) { + assertSize(size) + that = createBuffer(that, size < 0 ? 0 : checked(size) | 0) + if (!Buffer.TYPED_ARRAY_SUPPORT) { + for (var i = 0; i < size; ++i) { + that[i] = 0 + } + } + return that +} + +/** + * Equivalent to Buffer(num), by default creates a non-zero-filled Buffer instance. + * */ +Buffer.allocUnsafe = function (size) { + return allocUnsafe(null, size) +} +/** + * Equivalent to SlowBuffer(num), by default creates a non-zero-filled Buffer instance. + */ +Buffer.allocUnsafeSlow = function (size) { + return allocUnsafe(null, size) +} + +function fromString (that, string, encoding) { + if (typeof encoding !== 'string' || encoding === '') { + encoding = 'utf8' + } + + if (!Buffer.isEncoding(encoding)) { + throw new TypeError('"encoding" must be a valid string encoding') + } + + var length = byteLength(string, encoding) | 0 + that = createBuffer(that, length) + + var actual = that.write(string, encoding) + + if (actual !== length) { + // Writing a hex string, for example, that contains invalid characters will + // cause everything after the first invalid character to be ignored. (e.g. + // 'abxxcd' will be treated as 'ab') + that = that.slice(0, actual) + } + + return that +} + +function fromArrayLike (that, array) { + var length = array.length < 0 ? 0 : checked(array.length) | 0 + that = createBuffer(that, length) + for (var i = 0; i < length; i += 1) { + that[i] = array[i] & 255 + } + return that +} + +function fromArrayBuffer (that, array, byteOffset, length) { + array.byteLength // this throws if `array` is not a valid ArrayBuffer + + if (byteOffset < 0 || array.byteLength < byteOffset) { + throw new RangeError('\'offset\' is out of bounds') + } + + if (array.byteLength < byteOffset + (length || 0)) { + throw new RangeError('\'length\' is out of bounds') + } + + if (byteOffset === undefined && length === undefined) { + array = new Uint8Array(array) + } else if (length === undefined) { + array = new Uint8Array(array, byteOffset) + } else { + array = new Uint8Array(array, byteOffset, length) + } + + if (Buffer.TYPED_ARRAY_SUPPORT) { + // Return an augmented `Uint8Array` instance, for best performance + that = array + that.__proto__ = Buffer.prototype + } else { + // Fallback: Return an object instance of the Buffer class + that = fromArrayLike(that, array) + } + return that +} + +function fromObject (that, obj) { + if (Buffer.isBuffer(obj)) { + var len = checked(obj.length) | 0 + that = createBuffer(that, len) + + if (that.length === 0) { + return that + } + + obj.copy(that, 0, 0, len) + return that + } + + if (obj) { + if ((typeof ArrayBuffer !== 'undefined' && + obj.buffer instanceof ArrayBuffer) || 'length' in obj) { + if (typeof obj.length !== 'number' || isnan(obj.length)) { + return createBuffer(that, 0) + } + return fromArrayLike(that, obj) + } + + if (obj.type === 'Buffer' && isArray(obj.data)) { + return fromArrayLike(that, obj.data) + } + } + + throw new TypeError('First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.') +} + +function checked (length) { + // Note: cannot use `length < kMaxLength()` here because that fails when + // length is NaN (which is otherwise coerced to zero.) + if (length >= kMaxLength()) { + throw new RangeError('Attempt to allocate Buffer larger than maximum ' + + 'size: 0x' + kMaxLength().toString(16) + ' bytes') + } + return length | 0 +} + +function SlowBuffer (length) { + if (+length != length) { // eslint-disable-line eqeqeq + length = 0 + } + return Buffer.alloc(+length) +} + +Buffer.isBuffer = function isBuffer (b) { + return !!(b != null && b._isBuffer) +} + +Buffer.compare = function compare (a, b) { + if (!Buffer.isBuffer(a) || !Buffer.isBuffer(b)) { + throw new TypeError('Arguments must be Buffers') + } + + if (a === b) return 0 + + var x = a.length + var y = b.length + + for (var i = 0, len = Math.min(x, y); i < len; ++i) { + if (a[i] !== b[i]) { + x = a[i] + y = b[i] + break + } + } + + if (x < y) return -1 + if (y < x) return 1 + return 0 +} + +Buffer.isEncoding = function isEncoding (encoding) { + switch (String(encoding).toLowerCase()) { + case 'hex': + case 'utf8': + case 'utf-8': + case 'ascii': + case 'latin1': + case 'binary': + case 'base64': + case 'ucs2': + case 'ucs-2': + case 'utf16le': + case 'utf-16le': + return true + default: + return false + } +} + +Buffer.concat = function concat (list, length) { + if (!isArray(list)) { + throw new TypeError('"list" argument must be an Array of Buffers') + } + + if (list.length === 0) { + return Buffer.alloc(0) + } + + var i + if (length === undefined) { + length = 0 + for (i = 0; i < list.length; ++i) { + length += list[i].length + } + } + + var buffer = Buffer.allocUnsafe(length) + var pos = 0 + for (i = 0; i < list.length; ++i) { + var buf = list[i] + if (!Buffer.isBuffer(buf)) { + throw new TypeError('"list" argument must be an Array of Buffers') + } + buf.copy(buffer, pos) + pos += buf.length + } + return buffer +} + +function byteLength (string, encoding) { + if (Buffer.isBuffer(string)) { + return string.length + } + if (typeof ArrayBuffer !== 'undefined' && typeof ArrayBuffer.isView === 'function' && + (ArrayBuffer.isView(string) || string instanceof ArrayBuffer)) { + return string.byteLength + } + if (typeof string !== 'string') { + string = '' + string + } + + var len = string.length + if (len === 0) return 0 + + // Use a for loop to avoid recursion + var loweredCase = false + for (;;) { + switch (encoding) { + case 'ascii': + case 'latin1': + case 'binary': + return len + case 'utf8': + case 'utf-8': + case undefined: + return utf8ToBytes(string).length + case 'ucs2': + case 'ucs-2': + case 'utf16le': + case 'utf-16le': + return len * 2 + case 'hex': + return len >>> 1 + case 'base64': + return base64ToBytes(string).length + default: + if (loweredCase) return utf8ToBytes(string).length // assume utf8 + encoding = ('' + encoding).toLowerCase() + loweredCase = true + } + } +} +Buffer.byteLength = byteLength + +function slowToString (encoding, start, end) { + var loweredCase = false + + // No need to verify that "this.length <= MAX_UINT32" since it's a read-only + // property of a typed array. + + // This behaves neither like String nor Uint8Array in that we set start/end + // to their upper/lower bounds if the value passed is out of range. + // undefined is handled specially as per ECMA-262 6th Edition, + // Section 13.3.3.7 Runtime Semantics: KeyedBindingInitialization. + if (start === undefined || start < 0) { + start = 0 + } + // Return early if start > this.length. Done here to prevent potential uint32 + // coercion fail below. + if (start > this.length) { + return '' + } + + if (end === undefined || end > this.length) { + end = this.length + } + + if (end <= 0) { + return '' + } + + // Force coersion to uint32. This will also coerce falsey/NaN values to 0. + end >>>= 0 + start >>>= 0 + + if (end <= start) { + return '' + } + + if (!encoding) encoding = 'utf8' + + while (true) { + switch (encoding) { + case 'hex': + return hexSlice(this, start, end) + + case 'utf8': + case 'utf-8': + return utf8Slice(this, start, end) + + case 'ascii': + return asciiSlice(this, start, end) + + case 'latin1': + case 'binary': + return latin1Slice(this, start, end) + + case 'base64': + return base64Slice(this, start, end) + + case 'ucs2': + case 'ucs-2': + case 'utf16le': + case 'utf-16le': + return utf16leSlice(this, start, end) + + default: + if (loweredCase) throw new TypeError('Unknown encoding: ' + encoding) + encoding = (encoding + '').toLowerCase() + loweredCase = true + } + } +} + +// The property is used by `Buffer.isBuffer` and `is-buffer` (in Safari 5-7) to detect +// Buffer instances. +Buffer.prototype._isBuffer = true + +function swap (b, n, m) { + var i = b[n] + b[n] = b[m] + b[m] = i +} + +Buffer.prototype.swap16 = function swap16 () { + var len = this.length + if (len % 2 !== 0) { + throw new RangeError('Buffer size must be a multiple of 16-bits') + } + for (var i = 0; i < len; i += 2) { + swap(this, i, i + 1) + } + return this +} + +Buffer.prototype.swap32 = function swap32 () { + var len = this.length + if (len % 4 !== 0) { + throw new RangeError('Buffer size must be a multiple of 32-bits') + } + for (var i = 0; i < len; i += 4) { + swap(this, i, i + 3) + swap(this, i + 1, i + 2) + } + return this +} + +Buffer.prototype.swap64 = function swap64 () { + var len = this.length + if (len % 8 !== 0) { + throw new RangeError('Buffer size must be a multiple of 64-bits') + } + for (var i = 0; i < len; i += 8) { + swap(this, i, i + 7) + swap(this, i + 1, i + 6) + swap(this, i + 2, i + 5) + swap(this, i + 3, i + 4) + } + return this +} + +Buffer.prototype.toString = function toString () { + var length = this.length | 0 + if (length === 0) return '' + if (arguments.length === 0) return utf8Slice(this, 0, length) + return slowToString.apply(this, arguments) +} + +Buffer.prototype.equals = function equals (b) { + if (!Buffer.isBuffer(b)) throw new TypeError('Argument must be a Buffer') + if (this === b) return true + return Buffer.compare(this, b) === 0 +} + +Buffer.prototype.inspect = function inspect () { + var str = '' + var max = exports.INSPECT_MAX_BYTES + if (this.length > 0) { + str = this.toString('hex', 0, max).match(/.{2}/g).join(' ') + if (this.length > max) str += ' ... ' + } + return '' +} + +Buffer.prototype.compare = function compare (target, start, end, thisStart, thisEnd) { + if (!Buffer.isBuffer(target)) { + throw new TypeError('Argument must be a Buffer') + } + + if (start === undefined) { + start = 0 + } + if (end === undefined) { + end = target ? target.length : 0 + } + if (thisStart === undefined) { + thisStart = 0 + } + if (thisEnd === undefined) { + thisEnd = this.length + } + + if (start < 0 || end > target.length || thisStart < 0 || thisEnd > this.length) { + throw new RangeError('out of range index') + } + + if (thisStart >= thisEnd && start >= end) { + return 0 + } + if (thisStart >= thisEnd) { + return -1 + } + if (start >= end) { + return 1 + } + + start >>>= 0 + end >>>= 0 + thisStart >>>= 0 + thisEnd >>>= 0 + + if (this === target) return 0 + + var x = thisEnd - thisStart + var y = end - start + var len = Math.min(x, y) + + var thisCopy = this.slice(thisStart, thisEnd) + var targetCopy = target.slice(start, end) + + for (var i = 0; i < len; ++i) { + if (thisCopy[i] !== targetCopy[i]) { + x = thisCopy[i] + y = targetCopy[i] + break + } + } + + if (x < y) return -1 + if (y < x) return 1 + return 0 +} + +// Finds either the first index of `val` in `buffer` at offset >= `byteOffset`, +// OR the last index of `val` in `buffer` at offset <= `byteOffset`. +// +// Arguments: +// - buffer - a Buffer to search +// - val - a string, Buffer, or number +// - byteOffset - an index into `buffer`; will be clamped to an int32 +// - encoding - an optional encoding, relevant is val is a string +// - dir - true for indexOf, false for lastIndexOf +function bidirectionalIndexOf (buffer, val, byteOffset, encoding, dir) { + // Empty buffer means no match + if (buffer.length === 0) return -1 + + // Normalize byteOffset + if (typeof byteOffset === 'string') { + encoding = byteOffset + byteOffset = 0 + } else if (byteOffset > 0x7fffffff) { + byteOffset = 0x7fffffff + } else if (byteOffset < -0x80000000) { + byteOffset = -0x80000000 + } + byteOffset = +byteOffset // Coerce to Number. + if (isNaN(byteOffset)) { + // byteOffset: it it's undefined, null, NaN, "foo", etc, search whole buffer + byteOffset = dir ? 0 : (buffer.length - 1) + } + + // Normalize byteOffset: negative offsets start from the end of the buffer + if (byteOffset < 0) byteOffset = buffer.length + byteOffset + if (byteOffset >= buffer.length) { + if (dir) return -1 + else byteOffset = buffer.length - 1 + } else if (byteOffset < 0) { + if (dir) byteOffset = 0 + else return -1 + } + + // Normalize val + if (typeof val === 'string') { + val = Buffer.from(val, encoding) + } + + // Finally, search either indexOf (if dir is true) or lastIndexOf + if (Buffer.isBuffer(val)) { + // Special case: looking for empty string/buffer always fails + if (val.length === 0) { + return -1 + } + return arrayIndexOf(buffer, val, byteOffset, encoding, dir) + } else if (typeof val === 'number') { + val = val & 0xFF // Search for a byte value [0-255] + if (Buffer.TYPED_ARRAY_SUPPORT && + typeof Uint8Array.prototype.indexOf === 'function') { + if (dir) { + return Uint8Array.prototype.indexOf.call(buffer, val, byteOffset) + } else { + return Uint8Array.prototype.lastIndexOf.call(buffer, val, byteOffset) + } + } + return arrayIndexOf(buffer, [ val ], byteOffset, encoding, dir) + } + + throw new TypeError('val must be string, number or Buffer') +} + +function arrayIndexOf (arr, val, byteOffset, encoding, dir) { + var indexSize = 1 + var arrLength = arr.length + var valLength = val.length + + if (encoding !== undefined) { + encoding = String(encoding).toLowerCase() + if (encoding === 'ucs2' || encoding === 'ucs-2' || + encoding === 'utf16le' || encoding === 'utf-16le') { + if (arr.length < 2 || val.length < 2) { + return -1 + } + indexSize = 2 + arrLength /= 2 + valLength /= 2 + byteOffset /= 2 + } + } + + function read (buf, i) { + if (indexSize === 1) { + return buf[i] + } else { + return buf.readUInt16BE(i * indexSize) + } + } + + var i + if (dir) { + var foundIndex = -1 + for (i = byteOffset; i < arrLength; i++) { + if (read(arr, i) === read(val, foundIndex === -1 ? 0 : i - foundIndex)) { + if (foundIndex === -1) foundIndex = i + if (i - foundIndex + 1 === valLength) return foundIndex * indexSize + } else { + if (foundIndex !== -1) i -= i - foundIndex + foundIndex = -1 + } + } + } else { + if (byteOffset + valLength > arrLength) byteOffset = arrLength - valLength + for (i = byteOffset; i >= 0; i--) { + var found = true + for (var j = 0; j < valLength; j++) { + if (read(arr, i + j) !== read(val, j)) { + found = false + break + } + } + if (found) return i + } + } + + return -1 +} + +Buffer.prototype.includes = function includes (val, byteOffset, encoding) { + return this.indexOf(val, byteOffset, encoding) !== -1 +} + +Buffer.prototype.indexOf = function indexOf (val, byteOffset, encoding) { + return bidirectionalIndexOf(this, val, byteOffset, encoding, true) +} + +Buffer.prototype.lastIndexOf = function lastIndexOf (val, byteOffset, encoding) { + return bidirectionalIndexOf(this, val, byteOffset, encoding, false) +} + +function hexWrite (buf, string, offset, length) { + offset = Number(offset) || 0 + var remaining = buf.length - offset + if (!length) { + length = remaining + } else { + length = Number(length) + if (length > remaining) { + length = remaining + } + } + + // must be an even number of digits + var strLen = string.length + if (strLen % 2 !== 0) throw new TypeError('Invalid hex string') + + if (length > strLen / 2) { + length = strLen / 2 + } + for (var i = 0; i < length; ++i) { + var parsed = parseInt(string.substr(i * 2, 2), 16) + if (isNaN(parsed)) return i + buf[offset + i] = parsed + } + return i +} + +function utf8Write (buf, string, offset, length) { + return blitBuffer(utf8ToBytes(string, buf.length - offset), buf, offset, length) +} + +function asciiWrite (buf, string, offset, length) { + return blitBuffer(asciiToBytes(string), buf, offset, length) +} + +function latin1Write (buf, string, offset, length) { + return asciiWrite(buf, string, offset, length) +} + +function base64Write (buf, string, offset, length) { + return blitBuffer(base64ToBytes(string), buf, offset, length) +} + +function ucs2Write (buf, string, offset, length) { + return blitBuffer(utf16leToBytes(string, buf.length - offset), buf, offset, length) +} + +Buffer.prototype.write = function write (string, offset, length, encoding) { + // Buffer#write(string) + if (offset === undefined) { + encoding = 'utf8' + length = this.length + offset = 0 + // Buffer#write(string, encoding) + } else if (length === undefined && typeof offset === 'string') { + encoding = offset + length = this.length + offset = 0 + // Buffer#write(string, offset[, length][, encoding]) + } else if (isFinite(offset)) { + offset = offset | 0 + if (isFinite(length)) { + length = length | 0 + if (encoding === undefined) encoding = 'utf8' + } else { + encoding = length + length = undefined + } + // legacy write(string, encoding, offset, length) - remove in v0.13 + } else { + throw new Error( + 'Buffer.write(string, encoding, offset[, length]) is no longer supported' + ) + } + + var remaining = this.length - offset + if (length === undefined || length > remaining) length = remaining + + if ((string.length > 0 && (length < 0 || offset < 0)) || offset > this.length) { + throw new RangeError('Attempt to write outside buffer bounds') + } + + if (!encoding) encoding = 'utf8' + + var loweredCase = false + for (;;) { + switch (encoding) { + case 'hex': + return hexWrite(this, string, offset, length) + + case 'utf8': + case 'utf-8': + return utf8Write(this, string, offset, length) + + case 'ascii': + return asciiWrite(this, string, offset, length) + + case 'latin1': + case 'binary': + return latin1Write(this, string, offset, length) + + case 'base64': + // Warning: maxLength not taken into account in base64Write + return base64Write(this, string, offset, length) + + case 'ucs2': + case 'ucs-2': + case 'utf16le': + case 'utf-16le': + return ucs2Write(this, string, offset, length) + + default: + if (loweredCase) throw new TypeError('Unknown encoding: ' + encoding) + encoding = ('' + encoding).toLowerCase() + loweredCase = true + } + } +} + +Buffer.prototype.toJSON = function toJSON () { + return { + type: 'Buffer', + data: Array.prototype.slice.call(this._arr || this, 0) + } +} + +function base64Slice (buf, start, end) { + if (start === 0 && end === buf.length) { + return base64.fromByteArray(buf) + } else { + return base64.fromByteArray(buf.slice(start, end)) + } +} + +function utf8Slice (buf, start, end) { + end = Math.min(buf.length, end) + var res = [] + + var i = start + while (i < end) { + var firstByte = buf[i] + var codePoint = null + var bytesPerSequence = (firstByte > 0xEF) ? 4 + : (firstByte > 0xDF) ? 3 + : (firstByte > 0xBF) ? 2 + : 1 + + if (i + bytesPerSequence <= end) { + var secondByte, thirdByte, fourthByte, tempCodePoint + + switch (bytesPerSequence) { + case 1: + if (firstByte < 0x80) { + codePoint = firstByte + } + break + case 2: + secondByte = buf[i + 1] + if ((secondByte & 0xC0) === 0x80) { + tempCodePoint = (firstByte & 0x1F) << 0x6 | (secondByte & 0x3F) + if (tempCodePoint > 0x7F) { + codePoint = tempCodePoint + } + } + break + case 3: + secondByte = buf[i + 1] + thirdByte = buf[i + 2] + if ((secondByte & 0xC0) === 0x80 && (thirdByte & 0xC0) === 0x80) { + tempCodePoint = (firstByte & 0xF) << 0xC | (secondByte & 0x3F) << 0x6 | (thirdByte & 0x3F) + if (tempCodePoint > 0x7FF && (tempCodePoint < 0xD800 || tempCodePoint > 0xDFFF)) { + codePoint = tempCodePoint + } + } + break + case 4: + secondByte = buf[i + 1] + thirdByte = buf[i + 2] + fourthByte = buf[i + 3] + if ((secondByte & 0xC0) === 0x80 && (thirdByte & 0xC0) === 0x80 && (fourthByte & 0xC0) === 0x80) { + tempCodePoint = (firstByte & 0xF) << 0x12 | (secondByte & 0x3F) << 0xC | (thirdByte & 0x3F) << 0x6 | (fourthByte & 0x3F) + if (tempCodePoint > 0xFFFF && tempCodePoint < 0x110000) { + codePoint = tempCodePoint + } + } + } + } + + if (codePoint === null) { + // we did not generate a valid codePoint so insert a + // replacement char (U+FFFD) and advance only 1 byte + codePoint = 0xFFFD + bytesPerSequence = 1 + } else if (codePoint > 0xFFFF) { + // encode to utf16 (surrogate pair dance) + codePoint -= 0x10000 + res.push(codePoint >>> 10 & 0x3FF | 0xD800) + codePoint = 0xDC00 | codePoint & 0x3FF + } + + res.push(codePoint) + i += bytesPerSequence + } + + return decodeCodePointsArray(res) +} + +// Based on http://stackoverflow.com/a/22747272/680742, the browser with +// the lowest limit is Chrome, with 0x10000 args. +// We go 1 magnitude less, for safety +var MAX_ARGUMENTS_LENGTH = 0x1000 + +function decodeCodePointsArray (codePoints) { + var len = codePoints.length + if (len <= MAX_ARGUMENTS_LENGTH) { + return String.fromCharCode.apply(String, codePoints) // avoid extra slice() + } + + // Decode in chunks to avoid "call stack size exceeded". + var res = '' + var i = 0 + while (i < len) { + res += String.fromCharCode.apply( + String, + codePoints.slice(i, i += MAX_ARGUMENTS_LENGTH) + ) + } + return res +} + +function asciiSlice (buf, start, end) { + var ret = '' + end = Math.min(buf.length, end) + + for (var i = start; i < end; ++i) { + ret += String.fromCharCode(buf[i] & 0x7F) + } + return ret +} + +function latin1Slice (buf, start, end) { + var ret = '' + end = Math.min(buf.length, end) + + for (var i = start; i < end; ++i) { + ret += String.fromCharCode(buf[i]) + } + return ret +} + +function hexSlice (buf, start, end) { + var len = buf.length + + if (!start || start < 0) start = 0 + if (!end || end < 0 || end > len) end = len + + var out = '' + for (var i = start; i < end; ++i) { + out += toHex(buf[i]) + } + return out +} + +function utf16leSlice (buf, start, end) { + var bytes = buf.slice(start, end) + var res = '' + for (var i = 0; i < bytes.length; i += 2) { + res += String.fromCharCode(bytes[i] + bytes[i + 1] * 256) + } + return res +} + +Buffer.prototype.slice = function slice (start, end) { + var len = this.length + start = ~~start + end = end === undefined ? len : ~~end + + if (start < 0) { + start += len + if (start < 0) start = 0 + } else if (start > len) { + start = len + } + + if (end < 0) { + end += len + if (end < 0) end = 0 + } else if (end > len) { + end = len + } + + if (end < start) end = start + + var newBuf + if (Buffer.TYPED_ARRAY_SUPPORT) { + newBuf = this.subarray(start, end) + newBuf.__proto__ = Buffer.prototype + } else { + var sliceLen = end - start + newBuf = new Buffer(sliceLen, undefined) + for (var i = 0; i < sliceLen; ++i) { + newBuf[i] = this[i + start] + } + } + + return newBuf +} + +/* + * Need to make sure that buffer isn't trying to write out of bounds. + */ +function checkOffset (offset, ext, length) { + if ((offset % 1) !== 0 || offset < 0) throw new RangeError('offset is not uint') + if (offset + ext > length) throw new RangeError('Trying to access beyond buffer length') +} + +Buffer.prototype.readUIntLE = function readUIntLE (offset, byteLength, noAssert) { + offset = offset | 0 + byteLength = byteLength | 0 + if (!noAssert) checkOffset(offset, byteLength, this.length) + + var val = this[offset] + var mul = 1 + var i = 0 + while (++i < byteLength && (mul *= 0x100)) { + val += this[offset + i] * mul + } + + return val +} + +Buffer.prototype.readUIntBE = function readUIntBE (offset, byteLength, noAssert) { + offset = offset | 0 + byteLength = byteLength | 0 + if (!noAssert) { + checkOffset(offset, byteLength, this.length) + } + + var val = this[offset + --byteLength] + var mul = 1 + while (byteLength > 0 && (mul *= 0x100)) { + val += this[offset + --byteLength] * mul + } + + return val +} + +Buffer.prototype.readUInt8 = function readUInt8 (offset, noAssert) { + if (!noAssert) checkOffset(offset, 1, this.length) + return this[offset] +} + +Buffer.prototype.readUInt16LE = function readUInt16LE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 2, this.length) + return this[offset] | (this[offset + 1] << 8) +} + +Buffer.prototype.readUInt16BE = function readUInt16BE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 2, this.length) + return (this[offset] << 8) | this[offset + 1] +} + +Buffer.prototype.readUInt32LE = function readUInt32LE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 4, this.length) + + return ((this[offset]) | + (this[offset + 1] << 8) | + (this[offset + 2] << 16)) + + (this[offset + 3] * 0x1000000) +} + +Buffer.prototype.readUInt32BE = function readUInt32BE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 4, this.length) + + return (this[offset] * 0x1000000) + + ((this[offset + 1] << 16) | + (this[offset + 2] << 8) | + this[offset + 3]) +} + +Buffer.prototype.readIntLE = function readIntLE (offset, byteLength, noAssert) { + offset = offset | 0 + byteLength = byteLength | 0 + if (!noAssert) checkOffset(offset, byteLength, this.length) + + var val = this[offset] + var mul = 1 + var i = 0 + while (++i < byteLength && (mul *= 0x100)) { + val += this[offset + i] * mul + } + mul *= 0x80 + + if (val >= mul) val -= Math.pow(2, 8 * byteLength) + + return val +} + +Buffer.prototype.readIntBE = function readIntBE (offset, byteLength, noAssert) { + offset = offset | 0 + byteLength = byteLength | 0 + if (!noAssert) checkOffset(offset, byteLength, this.length) + + var i = byteLength + var mul = 1 + var val = this[offset + --i] + while (i > 0 && (mul *= 0x100)) { + val += this[offset + --i] * mul + } + mul *= 0x80 + + if (val >= mul) val -= Math.pow(2, 8 * byteLength) + + return val +} + +Buffer.prototype.readInt8 = function readInt8 (offset, noAssert) { + if (!noAssert) checkOffset(offset, 1, this.length) + if (!(this[offset] & 0x80)) return (this[offset]) + return ((0xff - this[offset] + 1) * -1) +} + +Buffer.prototype.readInt16LE = function readInt16LE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 2, this.length) + var val = this[offset] | (this[offset + 1] << 8) + return (val & 0x8000) ? val | 0xFFFF0000 : val +} + +Buffer.prototype.readInt16BE = function readInt16BE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 2, this.length) + var val = this[offset + 1] | (this[offset] << 8) + return (val & 0x8000) ? val | 0xFFFF0000 : val +} + +Buffer.prototype.readInt32LE = function readInt32LE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 4, this.length) + + return (this[offset]) | + (this[offset + 1] << 8) | + (this[offset + 2] << 16) | + (this[offset + 3] << 24) +} + +Buffer.prototype.readInt32BE = function readInt32BE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 4, this.length) + + return (this[offset] << 24) | + (this[offset + 1] << 16) | + (this[offset + 2] << 8) | + (this[offset + 3]) +} + +Buffer.prototype.readFloatLE = function readFloatLE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 4, this.length) + return ieee754.read(this, offset, true, 23, 4) +} + +Buffer.prototype.readFloatBE = function readFloatBE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 4, this.length) + return ieee754.read(this, offset, false, 23, 4) +} + +Buffer.prototype.readDoubleLE = function readDoubleLE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 8, this.length) + return ieee754.read(this, offset, true, 52, 8) +} + +Buffer.prototype.readDoubleBE = function readDoubleBE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 8, this.length) + return ieee754.read(this, offset, false, 52, 8) +} + +function checkInt (buf, value, offset, ext, max, min) { + if (!Buffer.isBuffer(buf)) throw new TypeError('"buffer" argument must be a Buffer instance') + if (value > max || value < min) throw new RangeError('"value" argument is out of bounds') + if (offset + ext > buf.length) throw new RangeError('Index out of range') +} + +Buffer.prototype.writeUIntLE = function writeUIntLE (value, offset, byteLength, noAssert) { + value = +value + offset = offset | 0 + byteLength = byteLength | 0 + if (!noAssert) { + var maxBytes = Math.pow(2, 8 * byteLength) - 1 + checkInt(this, value, offset, byteLength, maxBytes, 0) + } + + var mul = 1 + var i = 0 + this[offset] = value & 0xFF + while (++i < byteLength && (mul *= 0x100)) { + this[offset + i] = (value / mul) & 0xFF + } + + return offset + byteLength +} + +Buffer.prototype.writeUIntBE = function writeUIntBE (value, offset, byteLength, noAssert) { + value = +value + offset = offset | 0 + byteLength = byteLength | 0 + if (!noAssert) { + var maxBytes = Math.pow(2, 8 * byteLength) - 1 + checkInt(this, value, offset, byteLength, maxBytes, 0) + } + + var i = byteLength - 1 + var mul = 1 + this[offset + i] = value & 0xFF + while (--i >= 0 && (mul *= 0x100)) { + this[offset + i] = (value / mul) & 0xFF + } + + return offset + byteLength +} + +Buffer.prototype.writeUInt8 = function writeUInt8 (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 1, 0xff, 0) + if (!Buffer.TYPED_ARRAY_SUPPORT) value = Math.floor(value) + this[offset] = (value & 0xff) + return offset + 1 +} + +function objectWriteUInt16 (buf, value, offset, littleEndian) { + if (value < 0) value = 0xffff + value + 1 + for (var i = 0, j = Math.min(buf.length - offset, 2); i < j; ++i) { + buf[offset + i] = (value & (0xff << (8 * (littleEndian ? i : 1 - i)))) >>> + (littleEndian ? i : 1 - i) * 8 + } +} + +Buffer.prototype.writeUInt16LE = function writeUInt16LE (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 2, 0xffff, 0) + if (Buffer.TYPED_ARRAY_SUPPORT) { + this[offset] = (value & 0xff) + this[offset + 1] = (value >>> 8) + } else { + objectWriteUInt16(this, value, offset, true) + } + return offset + 2 +} + +Buffer.prototype.writeUInt16BE = function writeUInt16BE (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 2, 0xffff, 0) + if (Buffer.TYPED_ARRAY_SUPPORT) { + this[offset] = (value >>> 8) + this[offset + 1] = (value & 0xff) + } else { + objectWriteUInt16(this, value, offset, false) + } + return offset + 2 +} + +function objectWriteUInt32 (buf, value, offset, littleEndian) { + if (value < 0) value = 0xffffffff + value + 1 + for (var i = 0, j = Math.min(buf.length - offset, 4); i < j; ++i) { + buf[offset + i] = (value >>> (littleEndian ? i : 3 - i) * 8) & 0xff + } +} + +Buffer.prototype.writeUInt32LE = function writeUInt32LE (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 4, 0xffffffff, 0) + if (Buffer.TYPED_ARRAY_SUPPORT) { + this[offset + 3] = (value >>> 24) + this[offset + 2] = (value >>> 16) + this[offset + 1] = (value >>> 8) + this[offset] = (value & 0xff) + } else { + objectWriteUInt32(this, value, offset, true) + } + return offset + 4 +} + +Buffer.prototype.writeUInt32BE = function writeUInt32BE (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 4, 0xffffffff, 0) + if (Buffer.TYPED_ARRAY_SUPPORT) { + this[offset] = (value >>> 24) + this[offset + 1] = (value >>> 16) + this[offset + 2] = (value >>> 8) + this[offset + 3] = (value & 0xff) + } else { + objectWriteUInt32(this, value, offset, false) + } + return offset + 4 +} + +Buffer.prototype.writeIntLE = function writeIntLE (value, offset, byteLength, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) { + var limit = Math.pow(2, 8 * byteLength - 1) + + checkInt(this, value, offset, byteLength, limit - 1, -limit) + } + + var i = 0 + var mul = 1 + var sub = 0 + this[offset] = value & 0xFF + while (++i < byteLength && (mul *= 0x100)) { + if (value < 0 && sub === 0 && this[offset + i - 1] !== 0) { + sub = 1 + } + this[offset + i] = ((value / mul) >> 0) - sub & 0xFF + } + + return offset + byteLength +} + +Buffer.prototype.writeIntBE = function writeIntBE (value, offset, byteLength, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) { + var limit = Math.pow(2, 8 * byteLength - 1) + + checkInt(this, value, offset, byteLength, limit - 1, -limit) + } + + var i = byteLength - 1 + var mul = 1 + var sub = 0 + this[offset + i] = value & 0xFF + while (--i >= 0 && (mul *= 0x100)) { + if (value < 0 && sub === 0 && this[offset + i + 1] !== 0) { + sub = 1 + } + this[offset + i] = ((value / mul) >> 0) - sub & 0xFF + } + + return offset + byteLength +} + +Buffer.prototype.writeInt8 = function writeInt8 (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 1, 0x7f, -0x80) + if (!Buffer.TYPED_ARRAY_SUPPORT) value = Math.floor(value) + if (value < 0) value = 0xff + value + 1 + this[offset] = (value & 0xff) + return offset + 1 +} + +Buffer.prototype.writeInt16LE = function writeInt16LE (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 2, 0x7fff, -0x8000) + if (Buffer.TYPED_ARRAY_SUPPORT) { + this[offset] = (value & 0xff) + this[offset + 1] = (value >>> 8) + } else { + objectWriteUInt16(this, value, offset, true) + } + return offset + 2 +} + +Buffer.prototype.writeInt16BE = function writeInt16BE (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 2, 0x7fff, -0x8000) + if (Buffer.TYPED_ARRAY_SUPPORT) { + this[offset] = (value >>> 8) + this[offset + 1] = (value & 0xff) + } else { + objectWriteUInt16(this, value, offset, false) + } + return offset + 2 +} + +Buffer.prototype.writeInt32LE = function writeInt32LE (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 4, 0x7fffffff, -0x80000000) + if (Buffer.TYPED_ARRAY_SUPPORT) { + this[offset] = (value & 0xff) + this[offset + 1] = (value >>> 8) + this[offset + 2] = (value >>> 16) + this[offset + 3] = (value >>> 24) + } else { + objectWriteUInt32(this, value, offset, true) + } + return offset + 4 +} + +Buffer.prototype.writeInt32BE = function writeInt32BE (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 4, 0x7fffffff, -0x80000000) + if (value < 0) value = 0xffffffff + value + 1 + if (Buffer.TYPED_ARRAY_SUPPORT) { + this[offset] = (value >>> 24) + this[offset + 1] = (value >>> 16) + this[offset + 2] = (value >>> 8) + this[offset + 3] = (value & 0xff) + } else { + objectWriteUInt32(this, value, offset, false) + } + return offset + 4 +} + +function checkIEEE754 (buf, value, offset, ext, max, min) { + if (offset + ext > buf.length) throw new RangeError('Index out of range') + if (offset < 0) throw new RangeError('Index out of range') +} + +function writeFloat (buf, value, offset, littleEndian, noAssert) { + if (!noAssert) { + checkIEEE754(buf, value, offset, 4, 3.4028234663852886e+38, -3.4028234663852886e+38) + } + ieee754.write(buf, value, offset, littleEndian, 23, 4) + return offset + 4 +} + +Buffer.prototype.writeFloatLE = function writeFloatLE (value, offset, noAssert) { + return writeFloat(this, value, offset, true, noAssert) +} + +Buffer.prototype.writeFloatBE = function writeFloatBE (value, offset, noAssert) { + return writeFloat(this, value, offset, false, noAssert) +} + +function writeDouble (buf, value, offset, littleEndian, noAssert) { + if (!noAssert) { + checkIEEE754(buf, value, offset, 8, 1.7976931348623157E+308, -1.7976931348623157E+308) + } + ieee754.write(buf, value, offset, littleEndian, 52, 8) + return offset + 8 +} + +Buffer.prototype.writeDoubleLE = function writeDoubleLE (value, offset, noAssert) { + return writeDouble(this, value, offset, true, noAssert) +} + +Buffer.prototype.writeDoubleBE = function writeDoubleBE (value, offset, noAssert) { + return writeDouble(this, value, offset, false, noAssert) +} + +// copy(targetBuffer, targetStart=0, sourceStart=0, sourceEnd=buffer.length) +Buffer.prototype.copy = function copy (target, targetStart, start, end) { + if (!start) start = 0 + if (!end && end !== 0) end = this.length + if (targetStart >= target.length) targetStart = target.length + if (!targetStart) targetStart = 0 + if (end > 0 && end < start) end = start + + // Copy 0 bytes; we're done + if (end === start) return 0 + if (target.length === 0 || this.length === 0) return 0 + + // Fatal error conditions + if (targetStart < 0) { + throw new RangeError('targetStart out of bounds') + } + if (start < 0 || start >= this.length) throw new RangeError('sourceStart out of bounds') + if (end < 0) throw new RangeError('sourceEnd out of bounds') + + // Are we oob? + if (end > this.length) end = this.length + if (target.length - targetStart < end - start) { + end = target.length - targetStart + start + } + + var len = end - start + var i + + if (this === target && start < targetStart && targetStart < end) { + // descending copy from end + for (i = len - 1; i >= 0; --i) { + target[i + targetStart] = this[i + start] + } + } else if (len < 1000 || !Buffer.TYPED_ARRAY_SUPPORT) { + // ascending copy from start + for (i = 0; i < len; ++i) { + target[i + targetStart] = this[i + start] + } + } else { + Uint8Array.prototype.set.call( + target, + this.subarray(start, start + len), + targetStart + ) + } + + return len +} + +// Usage: +// buffer.fill(number[, offset[, end]]) +// buffer.fill(buffer[, offset[, end]]) +// buffer.fill(string[, offset[, end]][, encoding]) +Buffer.prototype.fill = function fill (val, start, end, encoding) { + // Handle string cases: + if (typeof val === 'string') { + if (typeof start === 'string') { + encoding = start + start = 0 + end = this.length + } else if (typeof end === 'string') { + encoding = end + end = this.length + } + if (val.length === 1) { + var code = val.charCodeAt(0) + if (code < 256) { + val = code + } + } + if (encoding !== undefined && typeof encoding !== 'string') { + throw new TypeError('encoding must be a string') + } + if (typeof encoding === 'string' && !Buffer.isEncoding(encoding)) { + throw new TypeError('Unknown encoding: ' + encoding) + } + } else if (typeof val === 'number') { + val = val & 255 + } + + // Invalid ranges are not set to a default, so can range check early. + if (start < 0 || this.length < start || this.length < end) { + throw new RangeError('Out of range index') + } + + if (end <= start) { + return this + } + + start = start >>> 0 + end = end === undefined ? this.length : end >>> 0 + + if (!val) val = 0 + + var i + if (typeof val === 'number') { + for (i = start; i < end; ++i) { + this[i] = val + } + } else { + var bytes = Buffer.isBuffer(val) + ? val + : utf8ToBytes(new Buffer(val, encoding).toString()) + var len = bytes.length + for (i = 0; i < end - start; ++i) { + this[i + start] = bytes[i % len] + } + } + + return this +} + +// HELPER FUNCTIONS +// ================ + +var INVALID_BASE64_RE = /[^+\/0-9A-Za-z-_]/g + +function base64clean (str) { + // Node strips out invalid characters like \n and \t from the string, base64-js does not + str = stringtrim(str).replace(INVALID_BASE64_RE, '') + // Node converts strings with length < 2 to '' + if (str.length < 2) return '' + // Node allows for non-padded base64 strings (missing trailing ===), base64-js does not + while (str.length % 4 !== 0) { + str = str + '=' + } + return str +} + +function stringtrim (str) { + if (str.trim) return str.trim() + return str.replace(/^\s+|\s+$/g, '') +} + +function toHex (n) { + if (n < 16) return '0' + n.toString(16) + return n.toString(16) +} + +function utf8ToBytes (string, units) { + units = units || Infinity + var codePoint + var length = string.length + var leadSurrogate = null + var bytes = [] + + for (var i = 0; i < length; ++i) { + codePoint = string.charCodeAt(i) + + // is surrogate component + if (codePoint > 0xD7FF && codePoint < 0xE000) { + // last char was a lead + if (!leadSurrogate) { + // no lead yet + if (codePoint > 0xDBFF) { + // unexpected trail + if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD) + continue + } else if (i + 1 === length) { + // unpaired lead + if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD) + continue + } + + // valid lead + leadSurrogate = codePoint + + continue + } + + // 2 leads in a row + if (codePoint < 0xDC00) { + if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD) + leadSurrogate = codePoint + continue + } + + // valid surrogate pair + codePoint = (leadSurrogate - 0xD800 << 10 | codePoint - 0xDC00) + 0x10000 + } else if (leadSurrogate) { + // valid bmp char, but last char was a lead + if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD) + } + + leadSurrogate = null + + // encode utf8 + if (codePoint < 0x80) { + if ((units -= 1) < 0) break + bytes.push(codePoint) + } else if (codePoint < 0x800) { + if ((units -= 2) < 0) break + bytes.push( + codePoint >> 0x6 | 0xC0, + codePoint & 0x3F | 0x80 + ) + } else if (codePoint < 0x10000) { + if ((units -= 3) < 0) break + bytes.push( + codePoint >> 0xC | 0xE0, + codePoint >> 0x6 & 0x3F | 0x80, + codePoint & 0x3F | 0x80 + ) + } else if (codePoint < 0x110000) { + if ((units -= 4) < 0) break + bytes.push( + codePoint >> 0x12 | 0xF0, + codePoint >> 0xC & 0x3F | 0x80, + codePoint >> 0x6 & 0x3F | 0x80, + codePoint & 0x3F | 0x80 + ) + } else { + throw new Error('Invalid code point') + } + } + + return bytes +} + +function asciiToBytes (str) { + var byteArray = [] + for (var i = 0; i < str.length; ++i) { + // Node's code seems to be doing this and not & 0x7F.. + byteArray.push(str.charCodeAt(i) & 0xFF) + } + return byteArray +} + +function utf16leToBytes (str, units) { + var c, hi, lo + var byteArray = [] + for (var i = 0; i < str.length; ++i) { + if ((units -= 2) < 0) break + + c = str.charCodeAt(i) + hi = c >> 8 + lo = c % 256 + byteArray.push(lo) + byteArray.push(hi) + } + + return byteArray +} + +function base64ToBytes (str) { + return base64.toByteArray(base64clean(str)) +} + +function blitBuffer (src, dst, offset, length) { + for (var i = 0; i < length; ++i) { + if ((i + offset >= dst.length) || (i >= src.length)) break + dst[i + offset] = src[i] + } + return i +} + +function isnan (val) { + return val !== val // eslint-disable-line no-self-compare +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(24))) + +/***/ }), +/* 50 */ +/***/ (function(module, exports, __webpack_require__) { + +// browser shim for xmlhttprequest module + +var hasCORS = __webpack_require__(119); + +module.exports = function (opts) { + var xdomain = opts.xdomain; + + // scheme must be same when usign XDomainRequest + // http://blogs.msdn.com/b/ieinternals/archive/2010/05/13/xdomainrequest-restrictions-limitations-and-workarounds.aspx + var xscheme = opts.xscheme; + + // XDomainRequest has a flow of not sending cookie, therefore it should be disabled as a default. + // https://github.com/Automattic/engine.io-client/pull/217 + var enablesXDR = opts.enablesXDR; + + // XMLHttpRequest can be disabled on IE + try { + if ('undefined' !== typeof XMLHttpRequest && (!xdomain || hasCORS)) { + return new XMLHttpRequest(); + } + } catch (e) { } + + // Use XDomainRequest for IE8 if enablesXDR is true + // because loading bar keeps flashing when using jsonp-polling + // https://github.com/yujiosaka/socke.io-ie8-loading-example + try { + if ('undefined' !== typeof XDomainRequest && !xscheme && enablesXDR) { + return new XDomainRequest(); + } + } catch (e) { } + + if (!xdomain) { + try { + return new self[['Active'].concat('Object').join('X')]('Microsoft.XMLHTTP'); + } catch (e) { } + } +}; + + +/***/ }), +/* 51 */ +/***/ (function(module, exports, __webpack_require__) { + +/** + * Module dependencies. + */ + +var parser = __webpack_require__(18); +var Emitter = __webpack_require__(17); + +/** + * Module exports. + */ + +module.exports = Transport; + +/** + * Transport abstract constructor. + * + * @param {Object} options. + * @api private + */ + +function Transport (opts) { + this.path = opts.path; + this.hostname = opts.hostname; + this.port = opts.port; + this.secure = opts.secure; + this.query = opts.query; + this.timestampParam = opts.timestampParam; + this.timestampRequests = opts.timestampRequests; + this.readyState = ''; + this.agent = opts.agent || false; + this.socket = opts.socket; + this.enablesXDR = opts.enablesXDR; + + // SSL options for Node.js client + this.pfx = opts.pfx; + this.key = opts.key; + this.passphrase = opts.passphrase; + this.cert = opts.cert; + this.ca = opts.ca; + this.ciphers = opts.ciphers; + this.rejectUnauthorized = opts.rejectUnauthorized; + this.forceNode = opts.forceNode; + + // results of ReactNative environment detection + this.isReactNative = opts.isReactNative; + + // other options for Node.js client + this.extraHeaders = opts.extraHeaders; + this.localAddress = opts.localAddress; +} + +/** + * Mix in `Emitter`. + */ + +Emitter(Transport.prototype); + +/** + * Emits an error. + * + * @param {String} str + * @return {Transport} for chaining + * @api public + */ + +Transport.prototype.onError = function (msg, desc) { + var err = new Error(msg); + err.type = 'TransportError'; + err.description = desc; + this.emit('error', err); + return this; +}; + +/** + * Opens the transport. + * + * @api public + */ + +Transport.prototype.open = function () { + if ('closed' === this.readyState || '' === this.readyState) { + this.readyState = 'opening'; + this.doOpen(); + } + + return this; +}; + +/** + * Closes the transport. + * + * @api private + */ + +Transport.prototype.close = function () { + if ('opening' === this.readyState || 'open' === this.readyState) { + this.doClose(); + this.onClose(); + } + + return this; +}; + +/** + * Sends multiple packets. + * + * @param {Array} packets + * @api private + */ + +Transport.prototype.send = function (packets) { + if ('open' === this.readyState) { + this.write(packets); + } else { + throw new Error('Transport not open'); + } +}; + +/** + * Called upon open + * + * @api private + */ + +Transport.prototype.onOpen = function () { + this.readyState = 'open'; + this.writable = true; + this.emit('open'); +}; + +/** + * Called with data. + * + * @param {String} data + * @api private + */ + +Transport.prototype.onData = function (data) { + var packet = parser.decodePacket(data, this.socket.binaryType); + this.onPacket(packet); +}; + +/** + * Called with a decoded packet. + */ + +Transport.prototype.onPacket = function (packet) { + this.emit('packet', packet); +}; + +/** + * Called upon close. + * + * @api private + */ + +Transport.prototype.onClose = function () { + this.readyState = 'closed'; + this.emit('close'); +}; + + +/***/ }), +/* 52 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var TimerObservable_1 = __webpack_require__(138); +exports.timer = TimerObservable_1.TimerObservable.create; +//# sourceMappingURL=timer.js.map + +/***/ }), +/* 53 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +Object.defineProperty(exports, "__esModule", { value: true }); +var ignoreElements_1 = __webpack_require__(11); +var tap_1 = __webpack_require__(5); +var effects_1 = __webpack_require__(8); +/** + * Set the local client options + * @param xs + * @param inputs + */ +function setOptionsEffect(xs, inputs) { + return xs.pipe(tap_1.tap(function (options) { return inputs.option$.next(options); }), + // map(() => consoleInfo('set options')) + ignoreElements_1.ignoreElements()); +} +exports.setOptionsEffect = setOptionsEffect; +function setOptions(options) { + return [effects_1.EffectNames.SetOptions, options]; +} +exports.setOptions = setOptions; + + +/***/ }), +/* 54 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var isScheduler_1 = __webpack_require__(25); +var of_1 = __webpack_require__(9); +var from_1 = __webpack_require__(87); +var concatAll_1 = __webpack_require__(150); +/* tslint:enable:max-line-length */ +/** + * Creates an output Observable which sequentially emits all values from given + * Observable and then moves on to the next. + * + * Concatenates multiple Observables together by + * sequentially emitting their values, one Observable after the other. + * + * + * + * `concat` joins multiple Observables together, by subscribing to them one at a time and + * merging their results into the output Observable. You can pass either an array of + * Observables, or put them directly as arguments. Passing an empty array will result + * in Observable that completes immediately. + * + * `concat` will subscribe to first input Observable and emit all its values, without + * changing or affecting them in any way. When that Observable completes, it will + * subscribe to then next Observable passed and, again, emit its values. This will be + * repeated, until the operator runs out of Observables. When last input Observable completes, + * `concat` will complete as well. At any given moment only one Observable passed to operator + * emits values. If you would like to emit values from passed Observables concurrently, check out + * {@link merge} instead, especially with optional `concurrent` parameter. As a matter of fact, + * `concat` is an equivalent of `merge` operator with `concurrent` parameter set to `1`. + * + * Note that if some input Observable never completes, `concat` will also never complete + * and Observables following the one that did not complete will never be subscribed. On the other + * hand, if some Observable simply completes immediately after it is subscribed, it will be + * invisible for `concat`, which will just move on to the next Observable. + * + * If any Observable in chain errors, instead of passing control to the next Observable, + * `concat` will error immediately as well. Observables that would be subscribed after + * the one that emitted error, never will. + * + * If you pass to `concat` the same Observable many times, its stream of values + * will be "replayed" on every subscription, which means you can repeat given Observable + * as many times as you like. If passing the same Observable to `concat` 1000 times becomes tedious, + * you can always use {@link repeat}. + * + * @example Concatenate a timer counting from 0 to 3 with a synchronous sequence from 1 to 10 + * var timer = Rx.Observable.interval(1000).take(4); + * var sequence = Rx.Observable.range(1, 10); + * var result = Rx.Observable.concat(timer, sequence); + * result.subscribe(x => console.log(x)); + * + * // results in: + * // 0 -1000ms-> 1 -1000ms-> 2 -1000ms-> 3 -immediate-> 1 ... 10 + * + * + * @example Concatenate an array of 3 Observables + * var timer1 = Rx.Observable.interval(1000).take(10); + * var timer2 = Rx.Observable.interval(2000).take(6); + * var timer3 = Rx.Observable.interval(500).take(10); + * var result = Rx.Observable.concat([timer1, timer2, timer3]); // note that array is passed + * result.subscribe(x => console.log(x)); + * + * // results in the following: + * // (Prints to console sequentially) + * // -1000ms-> 0 -1000ms-> 1 -1000ms-> ... 9 + * // -2000ms-> 0 -2000ms-> 1 -2000ms-> ... 5 + * // -500ms-> 0 -500ms-> 1 -500ms-> ... 9 + * + * + * @example Concatenate the same Observable to repeat it + * const timer = Rx.Observable.interval(1000).take(2); + * + * Rx.Observable.concat(timer, timer) // concating the same Observable! + * .subscribe( + * value => console.log(value), + * err => {}, + * () => console.log('...and it is done!') + * ); + * + * // Logs: + * // 0 after 1s + * // 1 after 2s + * // 0 after 3s + * // 1 after 4s + * // "...and it is done!" also after 4s + * + * @see {@link concatAll} + * @see {@link concatMap} + * @see {@link concatMapTo} + * + * @param {ObservableInput} input1 An input Observable to concatenate with others. + * @param {ObservableInput} input2 An input Observable to concatenate with others. + * More than one input Observables may be given as argument. + * @param {Scheduler} [scheduler=null] An optional IScheduler to schedule each + * Observable subscription on. + * @return {Observable} All values of each passed Observable merged into a + * single Observable, in order, in serial fashion. + * @static true + * @name concat + * @owner Observable + */ +function concat() { + var observables = []; + for (var _i = 0; _i < arguments.length; _i++) { + observables[_i - 0] = arguments[_i]; + } + if (observables.length === 1 || (observables.length === 2 && isScheduler_1.isScheduler(observables[1]))) { + return from_1.from(observables[0]); + } + return concatAll_1.concatAll()(of_1.of.apply(void 0, observables)); +} +exports.concat = concat; +//# sourceMappingURL=concat.js.map + +/***/ }), +/* 55 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var mergeMap_1 = __webpack_require__(15); +var identity_1 = __webpack_require__(151); +/** + * Converts a higher-order Observable into a first-order Observable which + * concurrently delivers all values that are emitted on the inner Observables. + * + * Flattens an Observable-of-Observables. + * + * + * + * `mergeAll` subscribes to an Observable that emits Observables, also known as + * a higher-order Observable. Each time it observes one of these emitted inner + * Observables, it subscribes to that and delivers all the values from the + * inner Observable on the output Observable. The output Observable only + * completes once all inner Observables have completed. Any error delivered by + * a inner Observable will be immediately emitted on the output Observable. + * + * @example Spawn a new interval Observable for each click event, and blend their outputs as one Observable + * var clicks = Rx.Observable.fromEvent(document, 'click'); + * var higherOrder = clicks.map((ev) => Rx.Observable.interval(1000)); + * var firstOrder = higherOrder.mergeAll(); + * firstOrder.subscribe(x => console.log(x)); + * + * @example Count from 0 to 9 every second for each click, but only allow 2 concurrent timers + * var clicks = Rx.Observable.fromEvent(document, 'click'); + * var higherOrder = clicks.map((ev) => Rx.Observable.interval(1000).take(10)); + * var firstOrder = higherOrder.mergeAll(2); + * firstOrder.subscribe(x => console.log(x)); + * + * @see {@link combineAll} + * @see {@link concatAll} + * @see {@link exhaust} + * @see {@link merge} + * @see {@link mergeMap} + * @see {@link mergeMapTo} + * @see {@link mergeScan} + * @see {@link switch} + * @see {@link zipAll} + * + * @param {number} [concurrent=Number.POSITIVE_INFINITY] Maximum number of inner + * Observables being subscribed to concurrently. + * @return {Observable} An Observable that emits values coming from all the + * inner Observables emitted by the source Observable. + * @method mergeAll + * @owner Observable + */ +function mergeAll(concurrent) { + if (concurrent === void 0) { concurrent = Number.POSITIVE_INFINITY; } + return mergeMap_1.mergeMap(identity_1.identity, null, concurrent); +} +exports.mergeAll = mergeAll; +//# sourceMappingURL=mergeAll.js.map + +/***/ }), +/* 56 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +function isObject(x) { + return x != null && typeof x === 'object'; +} +exports.isObject = isObject; +//# sourceMappingURL=isObject.js.map + +/***/ }), +/* 57 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +exports.empty = { + closed: true, + next: function (value) { }, + error: function (err) { throw err; }, + complete: function () { } +}; +//# sourceMappingURL=Observer.js.map + +/***/ }), +/* 58 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/* tslint:disable:no-empty */ +function noop() { } +exports.noop = noop; +//# sourceMappingURL=noop.js.map + +/***/ }), +/* 59 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +exports.isArrayLike = (function (x) { return x && typeof x.length === 'number'; }); +//# sourceMappingURL=isArrayLike.js.map + +/***/ }), +/* 60 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +function isPromise(value) { + return value && typeof value.subscribe !== 'function' && typeof value.then === 'function'; +} +exports.isPromise = isPromise; +//# sourceMappingURL=isPromise.js.map + +/***/ }), +/* 61 */ +/***/ (function(module, exports) { + +/** + * Parses an URI + * + * @author Steven Levithan (MIT license) + * @api private + */ + +var re = /^(?:(?![^:@]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@]*)(?::([^:@]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/; + +var parts = [ + 'source', 'protocol', 'authority', 'userInfo', 'user', 'password', 'host', 'port', 'relative', 'path', 'directory', 'file', 'query', 'anchor' +]; + +module.exports = function parseuri(str) { + var src = str, + b = str.indexOf('['), + e = str.indexOf(']'); + + if (b != -1 && e != -1) { + str = str.substring(0, b) + str.substring(b, e).replace(/:/g, ';') + str.substring(e, str.length); + } + + var m = re.exec(str || ''), + uri = {}, + i = 14; + + while (i--) { + uri[parts[i]] = m[i] || ''; + } + + if (b != -1 && e != -1) { + uri.source = src; + uri.host = uri.host.substring(1, uri.host.length - 1).replace(/;/g, ':'); + uri.authority = uri.authority.replace('[', '').replace(']', '').replace(/;/g, ':'); + uri.ipv6uri = true; + } + + return uri; +}; + + +/***/ }), +/* 62 */ +/***/ (function(module, exports) { + +var toString = {}.toString; + +module.exports = Array.isArray || function (arr) { + return toString.call(arr) == '[object Array]'; +}; + + +/***/ }), +/* 63 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) { +module.exports = isBuf; + +var withNativeBuffer = typeof Buffer === 'function' && typeof Buffer.isBuffer === 'function'; +var withNativeArrayBuffer = typeof ArrayBuffer === 'function'; + +var isView = function (obj) { + return typeof ArrayBuffer.isView === 'function' ? ArrayBuffer.isView(obj) : (obj.buffer instanceof ArrayBuffer); +}; + +/** + * Returns true if obj is a buffer or an arraybuffer. + * + * @api private + */ + +function isBuf(obj) { + return (withNativeBuffer && Buffer.isBuffer(obj)) || + (withNativeArrayBuffer && (obj instanceof ArrayBuffer || isView(obj))); +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(49).Buffer)) + +/***/ }), +/* 64 */ +/***/ (function(module, exports, __webpack_require__) { + + +/** + * Module dependencies. + */ + +var eio = __webpack_require__(117); +var Socket = __webpack_require__(70); +var Emitter = __webpack_require__(17); +var parser = __webpack_require__(48); +var on = __webpack_require__(71); +var bind = __webpack_require__(72); +var debug = __webpack_require__(32)('socket.io-client:manager'); +var indexOf = __webpack_require__(69); +var Backoff = __webpack_require__(133); + +/** + * IE6+ hasOwnProperty + */ + +var has = Object.prototype.hasOwnProperty; + +/** + * Module exports + */ + +module.exports = Manager; + +/** + * `Manager` constructor. + * + * @param {String} engine instance or engine uri/opts + * @param {Object} options + * @api public + */ + +function Manager (uri, opts) { + if (!(this instanceof Manager)) return new Manager(uri, opts); + if (uri && ('object' === typeof uri)) { + opts = uri; + uri = undefined; + } + opts = opts || {}; + + opts.path = opts.path || '/socket.io'; + this.nsps = {}; + this.subs = []; + this.opts = opts; + this.reconnection(opts.reconnection !== false); + this.reconnectionAttempts(opts.reconnectionAttempts || Infinity); + this.reconnectionDelay(opts.reconnectionDelay || 1000); + this.reconnectionDelayMax(opts.reconnectionDelayMax || 5000); + this.randomizationFactor(opts.randomizationFactor || 0.5); + this.backoff = new Backoff({ + min: this.reconnectionDelay(), + max: this.reconnectionDelayMax(), + jitter: this.randomizationFactor() + }); + this.timeout(null == opts.timeout ? 20000 : opts.timeout); + this.readyState = 'closed'; + this.uri = uri; + this.connecting = []; + this.lastPing = null; + this.encoding = false; + this.packetBuffer = []; + var _parser = opts.parser || parser; + this.encoder = new _parser.Encoder(); + this.decoder = new _parser.Decoder(); + this.autoConnect = opts.autoConnect !== false; + if (this.autoConnect) this.open(); +} + +/** + * Propagate given event to sockets and emit on `this` + * + * @api private + */ + +Manager.prototype.emitAll = function () { + this.emit.apply(this, arguments); + for (var nsp in this.nsps) { + if (has.call(this.nsps, nsp)) { + this.nsps[nsp].emit.apply(this.nsps[nsp], arguments); + } + } +}; + +/** + * Update `socket.id` of all sockets + * + * @api private + */ + +Manager.prototype.updateSocketIds = function () { + for (var nsp in this.nsps) { + if (has.call(this.nsps, nsp)) { + this.nsps[nsp].id = this.generateId(nsp); + } + } +}; + +/** + * generate `socket.id` for the given `nsp` + * + * @param {String} nsp + * @return {String} + * @api private + */ + +Manager.prototype.generateId = function (nsp) { + return (nsp === '/' ? '' : (nsp + '#')) + this.engine.id; +}; + +/** + * Mix in `Emitter`. + */ + +Emitter(Manager.prototype); + +/** + * Sets the `reconnection` config. + * + * @param {Boolean} true/false if it should automatically reconnect + * @return {Manager} self or value + * @api public + */ + +Manager.prototype.reconnection = function (v) { + if (!arguments.length) return this._reconnection; + this._reconnection = !!v; + return this; +}; + +/** + * Sets the reconnection attempts config. + * + * @param {Number} max reconnection attempts before giving up + * @return {Manager} self or value + * @api public + */ + +Manager.prototype.reconnectionAttempts = function (v) { + if (!arguments.length) return this._reconnectionAttempts; + this._reconnectionAttempts = v; + return this; +}; + +/** + * Sets the delay between reconnections. + * + * @param {Number} delay + * @return {Manager} self or value + * @api public + */ + +Manager.prototype.reconnectionDelay = function (v) { + if (!arguments.length) return this._reconnectionDelay; + this._reconnectionDelay = v; + this.backoff && this.backoff.setMin(v); + return this; +}; + +Manager.prototype.randomizationFactor = function (v) { + if (!arguments.length) return this._randomizationFactor; + this._randomizationFactor = v; + this.backoff && this.backoff.setJitter(v); + return this; +}; + +/** + * Sets the maximum delay between reconnections. + * + * @param {Number} delay + * @return {Manager} self or value + * @api public + */ + +Manager.prototype.reconnectionDelayMax = function (v) { + if (!arguments.length) return this._reconnectionDelayMax; + this._reconnectionDelayMax = v; + this.backoff && this.backoff.setMax(v); + return this; +}; + +/** + * Sets the connection timeout. `false` to disable + * + * @return {Manager} self or value + * @api public + */ + +Manager.prototype.timeout = function (v) { + if (!arguments.length) return this._timeout; + this._timeout = v; + return this; +}; + +/** + * Starts trying to reconnect if reconnection is enabled and we have not + * started reconnecting yet + * + * @api private + */ + +Manager.prototype.maybeReconnectOnOpen = function () { + // Only try to reconnect if it's the first time we're connecting + if (!this.reconnecting && this._reconnection && this.backoff.attempts === 0) { + // keeps reconnection from firing twice for the same reconnection loop + this.reconnect(); + } +}; + +/** + * Sets the current transport `socket`. + * + * @param {Function} optional, callback + * @return {Manager} self + * @api public + */ + +Manager.prototype.open = +Manager.prototype.connect = function (fn, opts) { + debug('readyState %s', this.readyState); + if (~this.readyState.indexOf('open')) return this; + + debug('opening %s', this.uri); + this.engine = eio(this.uri, this.opts); + var socket = this.engine; + var self = this; + this.readyState = 'opening'; + this.skipReconnect = false; + + // emit `open` + var openSub = on(socket, 'open', function () { + self.onopen(); + fn && fn(); + }); + + // emit `connect_error` + var errorSub = on(socket, 'error', function (data) { + debug('connect_error'); + self.cleanup(); + self.readyState = 'closed'; + self.emitAll('connect_error', data); + if (fn) { + var err = new Error('Connection error'); + err.data = data; + fn(err); + } else { + // Only do this if there is no fn to handle the error + self.maybeReconnectOnOpen(); + } + }); + + // emit `connect_timeout` + if (false !== this._timeout) { + var timeout = this._timeout; + debug('connect attempt will timeout after %d', timeout); + + // set timer + var timer = setTimeout(function () { + debug('connect attempt timed out after %d', timeout); + openSub.destroy(); + socket.close(); + socket.emit('error', 'timeout'); + self.emitAll('connect_timeout', timeout); + }, timeout); + + this.subs.push({ + destroy: function () { + clearTimeout(timer); + } + }); + } + + this.subs.push(openSub); + this.subs.push(errorSub); + + return this; +}; + +/** + * Called upon transport open. + * + * @api private + */ + +Manager.prototype.onopen = function () { + debug('open'); + + // clear old subs + this.cleanup(); + + // mark as open + this.readyState = 'open'; + this.emit('open'); + + // add new subs + var socket = this.engine; + this.subs.push(on(socket, 'data', bind(this, 'ondata'))); + this.subs.push(on(socket, 'ping', bind(this, 'onping'))); + this.subs.push(on(socket, 'pong', bind(this, 'onpong'))); + this.subs.push(on(socket, 'error', bind(this, 'onerror'))); + this.subs.push(on(socket, 'close', bind(this, 'onclose'))); + this.subs.push(on(this.decoder, 'decoded', bind(this, 'ondecoded'))); +}; + +/** + * Called upon a ping. + * + * @api private + */ + +Manager.prototype.onping = function () { + this.lastPing = new Date(); + this.emitAll('ping'); +}; + +/** + * Called upon a packet. + * + * @api private + */ + +Manager.prototype.onpong = function () { + this.emitAll('pong', new Date() - this.lastPing); +}; + +/** + * Called with data. + * + * @api private + */ + +Manager.prototype.ondata = function (data) { + this.decoder.add(data); +}; + +/** + * Called when parser fully decodes a packet. + * + * @api private + */ + +Manager.prototype.ondecoded = function (packet) { + this.emit('packet', packet); +}; + +/** + * Called upon socket error. + * + * @api private + */ + +Manager.prototype.onerror = function (err) { + debug('error', err); + this.emitAll('error', err); +}; + +/** + * Creates a new socket for the given `nsp`. + * + * @return {Socket} + * @api public + */ + +Manager.prototype.socket = function (nsp, opts) { + var socket = this.nsps[nsp]; + if (!socket) { + socket = new Socket(this, nsp, opts); + this.nsps[nsp] = socket; + var self = this; + socket.on('connecting', onConnecting); + socket.on('connect', function () { + socket.id = self.generateId(nsp); + }); + + if (this.autoConnect) { + // manually call here since connecting event is fired before listening + onConnecting(); + } + } + + function onConnecting () { + if (!~indexOf(self.connecting, socket)) { + self.connecting.push(socket); + } + } + + return socket; +}; + +/** + * Called upon a socket close. + * + * @param {Socket} socket + */ + +Manager.prototype.destroy = function (socket) { + var index = indexOf(this.connecting, socket); + if (~index) this.connecting.splice(index, 1); + if (this.connecting.length) return; + + this.close(); +}; + +/** + * Writes a packet. + * + * @param {Object} packet + * @api private + */ + +Manager.prototype.packet = function (packet) { + debug('writing packet %j', packet); + var self = this; + if (packet.query && packet.type === 0) packet.nsp += '?' + packet.query; + + if (!self.encoding) { + // encode, then write to engine with result + self.encoding = true; + this.encoder.encode(packet, function (encodedPackets) { + for (var i = 0; i < encodedPackets.length; i++) { + self.engine.write(encodedPackets[i], packet.options); + } + self.encoding = false; + self.processPacketQueue(); + }); + } else { // add packet to the queue + self.packetBuffer.push(packet); + } +}; + +/** + * If packet buffer is non-empty, begins encoding the + * next packet in line. + * + * @api private + */ + +Manager.prototype.processPacketQueue = function () { + if (this.packetBuffer.length > 0 && !this.encoding) { + var pack = this.packetBuffer.shift(); + this.packet(pack); + } +}; + +/** + * Clean up transport subscriptions and packet buffer. + * + * @api private + */ + +Manager.prototype.cleanup = function () { + debug('cleanup'); + + var subsLength = this.subs.length; + for (var i = 0; i < subsLength; i++) { + var sub = this.subs.shift(); + sub.destroy(); + } + + this.packetBuffer = []; + this.encoding = false; + this.lastPing = null; + + this.decoder.destroy(); +}; + +/** + * Close the current socket. + * + * @api private + */ + +Manager.prototype.close = +Manager.prototype.disconnect = function () { + debug('disconnect'); + this.skipReconnect = true; + this.reconnecting = false; + if ('opening' === this.readyState) { + // `onclose` will not fire because + // an open event never happened + this.cleanup(); + } + this.backoff.reset(); + this.readyState = 'closed'; + if (this.engine) this.engine.close(); +}; + +/** + * Called upon engine close. + * + * @api private + */ + +Manager.prototype.onclose = function (reason) { + debug('onclose'); + + this.cleanup(); + this.backoff.reset(); + this.readyState = 'closed'; + this.emit('close', reason); + + if (this._reconnection && !this.skipReconnect) { + this.reconnect(); + } +}; + +/** + * Attempt a reconnection. + * + * @api private + */ + +Manager.prototype.reconnect = function () { + if (this.reconnecting || this.skipReconnect) return this; + + var self = this; + + if (this.backoff.attempts >= this._reconnectionAttempts) { + debug('reconnect failed'); + this.backoff.reset(); + this.emitAll('reconnect_failed'); + this.reconnecting = false; + } else { + var delay = this.backoff.duration(); + debug('will wait %dms before reconnect attempt', delay); + + this.reconnecting = true; + var timer = setTimeout(function () { + if (self.skipReconnect) return; + + debug('attempting reconnect'); + self.emitAll('reconnect_attempt', self.backoff.attempts); + self.emitAll('reconnecting', self.backoff.attempts); + + // check again for the case socket closed in above events + if (self.skipReconnect) return; + + self.open(function (err) { + if (err) { + debug('reconnect attempt error'); + self.reconnecting = false; + self.reconnect(); + self.emitAll('reconnect_error', err.data); + } else { + debug('reconnect success'); + self.onreconnect(); + } + }); + }, delay); + + this.subs.push({ + destroy: function () { + clearTimeout(timer); + } + }); + } +}; + +/** + * Called upon successful reconnect. + * + * @api private + */ + +Manager.prototype.onreconnect = function () { + var attempt = this.backoff.attempts; + this.reconnecting = false; + this.backoff.reset(); + this.updateSocketIds(); + this.emitAll('reconnect', attempt); +}; + + +/***/ }), +/* 65 */ +/***/ (function(module, exports, __webpack_require__) { + +/** + * Module dependencies + */ + +var XMLHttpRequest = __webpack_require__(50); +var XHR = __webpack_require__(120); +var JSONP = __webpack_require__(129); +var websocket = __webpack_require__(130); + +/** + * Export transports. + */ + +exports.polling = polling; +exports.websocket = websocket; + +/** + * Polling transport polymorphic constructor. + * Decides on xhr vs jsonp based on feature detection. + * + * @api private + */ + +function polling (opts) { + var xhr; + var xd = false; + var xs = false; + var jsonp = false !== opts.jsonp; + + if (typeof location !== 'undefined') { + var isSSL = 'https:' === location.protocol; + var port = location.port; + + // some user agents have empty `location.port` + if (!port) { + port = isSSL ? 443 : 80; + } + + xd = opts.hostname !== location.hostname || port !== opts.port; + xs = opts.secure !== isSSL; + } + + opts.xdomain = xd; + opts.xscheme = xs; + xhr = new XMLHttpRequest(opts); + + if ('open' in xhr && !opts.forceJSONP) { + return new XHR(opts); + } else { + if (!jsonp) throw new Error('JSONP disabled'); + return new JSONP(opts); + } +} + + +/***/ }), +/* 66 */ +/***/ (function(module, exports, __webpack_require__) { + +/** + * Module dependencies. + */ + +var Transport = __webpack_require__(51); +var parseqs = __webpack_require__(34); +var parser = __webpack_require__(18); +var inherit = __webpack_require__(35); +var yeast = __webpack_require__(68); +var debug = __webpack_require__(36)('engine.io-client:polling'); + +/** + * Module exports. + */ + +module.exports = Polling; + +/** + * Is XHR2 supported? + */ + +var hasXHR2 = (function () { + var XMLHttpRequest = __webpack_require__(50); + var xhr = new XMLHttpRequest({ xdomain: false }); + return null != xhr.responseType; +})(); + +/** + * Polling interface. + * + * @param {Object} opts + * @api private + */ + +function Polling (opts) { + var forceBase64 = (opts && opts.forceBase64); + if (!hasXHR2 || forceBase64) { + this.supportsBinary = false; + } + Transport.call(this, opts); +} + +/** + * Inherits from Transport. + */ + +inherit(Polling, Transport); + +/** + * Transport name. + */ + +Polling.prototype.name = 'polling'; + +/** + * Opens the socket (triggers polling). We write a PING message to determine + * when the transport is open. + * + * @api private + */ + +Polling.prototype.doOpen = function () { + this.poll(); +}; + +/** + * Pauses polling. + * + * @param {Function} callback upon buffers are flushed and transport is paused + * @api private + */ + +Polling.prototype.pause = function (onPause) { + var self = this; + + this.readyState = 'pausing'; + + function pause () { + debug('paused'); + self.readyState = 'paused'; + onPause(); + } + + if (this.polling || !this.writable) { + var total = 0; + + if (this.polling) { + debug('we are currently polling - waiting to pause'); + total++; + this.once('pollComplete', function () { + debug('pre-pause polling complete'); + --total || pause(); + }); + } + + if (!this.writable) { + debug('we are currently writing - waiting to pause'); + total++; + this.once('drain', function () { + debug('pre-pause writing complete'); + --total || pause(); + }); + } + } else { + pause(); + } +}; + +/** + * Starts polling cycle. + * + * @api public + */ + +Polling.prototype.poll = function () { + debug('polling'); + this.polling = true; + this.doPoll(); + this.emit('poll'); +}; + +/** + * Overloads onData to detect payloads. + * + * @api private + */ + +Polling.prototype.onData = function (data) { + var self = this; + debug('polling got data %s', data); + var callback = function (packet, index, total) { + // if its the first message we consider the transport open + if ('opening' === self.readyState) { + self.onOpen(); + } + + // if its a close packet, we close the ongoing requests + if ('close' === packet.type) { + self.onClose(); + return false; + } + + // otherwise bypass onData and handle the message + self.onPacket(packet); + }; + + // decode payload + parser.decodePayload(data, this.socket.binaryType, callback); + + // if an event did not trigger closing + if ('closed' !== this.readyState) { + // if we got data we're not polling + this.polling = false; + this.emit('pollComplete'); + + if ('open' === this.readyState) { + this.poll(); + } else { + debug('ignoring poll - transport state "%s"', this.readyState); + } + } +}; + +/** + * For polling, send a close packet. + * + * @api private + */ + +Polling.prototype.doClose = function () { + var self = this; + + function close () { + debug('writing close packet'); + self.write([{ type: 'close' }]); + } + + if ('open' === this.readyState) { + debug('transport open - closing'); + close(); + } else { + // in case we're trying to close while + // handshaking is in progress (GH-164) + debug('transport not open - deferring close'); + this.once('open', close); + } +}; + +/** + * Writes a packets payload. + * + * @param {Array} data packets + * @param {Function} drain callback + * @api private + */ + +Polling.prototype.write = function (packets) { + var self = this; + this.writable = false; + var callbackfn = function () { + self.writable = true; + self.emit('drain'); + }; + + parser.encodePayload(packets, this.supportsBinary, function (data) { + self.doWrite(data, callbackfn); + }); +}; + +/** + * Generates uri for connection. + * + * @api private + */ + +Polling.prototype.uri = function () { + var query = this.query || {}; + var schema = this.secure ? 'https' : 'http'; + var port = ''; + + // cache busting is forced + if (false !== this.timestampRequests) { + query[this.timestampParam] = yeast(); + } + + if (!this.supportsBinary && !query.sid) { + query.b64 = 1; + } + + query = parseqs.encode(query); + + // avoid port if default for schema + if (this.port && (('https' === schema && Number(this.port) !== 443) || + ('http' === schema && Number(this.port) !== 80))) { + port = ':' + this.port; + } + + // prepend ? to query + if (query.length) { + query = '?' + query; + } + + var ipv6 = this.hostname.indexOf(':') !== -1; + return schema + '://' + (ipv6 ? '[' + this.hostname + ']' : this.hostname) + port + this.path + query; +}; + + +/***/ }), +/* 67 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {/* global Blob File */ + +/* + * Module requirements. + */ + +var isArray = __webpack_require__(122); + +var toString = Object.prototype.toString; +var withNativeBlob = typeof Blob === 'function' || + typeof Blob !== 'undefined' && toString.call(Blob) === '[object BlobConstructor]'; +var withNativeFile = typeof File === 'function' || + typeof File !== 'undefined' && toString.call(File) === '[object FileConstructor]'; + +/** + * Module exports. + */ + +module.exports = hasBinary; + +/** + * Checks for binary data. + * + * Supports Buffer, ArrayBuffer, Blob and File. + * + * @param {Object} anything + * @api public + */ + +function hasBinary (obj) { + if (!obj || typeof obj !== 'object') { + return false; + } + + if (isArray(obj)) { + for (var i = 0, l = obj.length; i < l; i++) { + if (hasBinary(obj[i])) { + return true; + } + } + return false; + } + + if ((typeof Buffer === 'function' && Buffer.isBuffer && Buffer.isBuffer(obj)) || + (typeof ArrayBuffer === 'function' && obj instanceof ArrayBuffer) || + (withNativeBlob && obj instanceof Blob) || + (withNativeFile && obj instanceof File) + ) { + return true; + } + + // see: https://github.com/Automattic/has-binary/pull/4 + if (obj.toJSON && typeof obj.toJSON === 'function' && arguments.length === 1) { + return hasBinary(obj.toJSON(), true); + } + + for (var key in obj) { + if (Object.prototype.hasOwnProperty.call(obj, key) && hasBinary(obj[key])) { + return true; + } + } + + return false; +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(49).Buffer)) + +/***/ }), +/* 68 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var alphabet = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-_'.split('') + , length = 64 + , map = {} + , seed = 0 + , i = 0 + , prev; + +/** + * Return a string representing the specified number. + * + * @param {Number} num The number to convert. + * @returns {String} The string representation of the number. + * @api public + */ +function encode(num) { + var encoded = ''; + + do { + encoded = alphabet[num % length] + encoded; + num = Math.floor(num / length); + } while (num > 0); + + return encoded; +} + +/** + * Return the integer value specified by the given string. + * + * @param {String} str The string to convert. + * @returns {Number} The integer value represented by the string. + * @api public + */ +function decode(str) { + var decoded = 0; + + for (i = 0; i < str.length; i++) { + decoded = decoded * length + map[str.charAt(i)]; + } + + return decoded; +} + +/** + * Yeast: A tiny growing id generator. + * + * @returns {String} A unique id. + * @api public + */ +function yeast() { + var now = encode(+new Date()); + + if (now !== prev) return seed = 0, prev = now; + return now +'.'+ encode(seed++); +} + +// +// Map each character to its index. +// +for (; i < length; i++) map[alphabet[i]] = i; + +// +// Expose the `yeast`, `encode` and `decode` functions. +// +yeast.encode = encode; +yeast.decode = decode; +module.exports = yeast; + + +/***/ }), +/* 69 */ +/***/ (function(module, exports) { + + +var indexOf = [].indexOf; + +module.exports = function(arr, obj){ + if (indexOf) return arr.indexOf(obj); + for (var i = 0; i < arr.length; ++i) { + if (arr[i] === obj) return i; + } + return -1; +}; + +/***/ }), +/* 70 */ +/***/ (function(module, exports, __webpack_require__) { + + +/** + * Module dependencies. + */ + +var parser = __webpack_require__(48); +var Emitter = __webpack_require__(17); +var toArray = __webpack_require__(132); +var on = __webpack_require__(71); +var bind = __webpack_require__(72); +var debug = __webpack_require__(32)('socket.io-client:socket'); +var parseqs = __webpack_require__(34); +var hasBin = __webpack_require__(67); + +/** + * Module exports. + */ + +module.exports = exports = Socket; + +/** + * Internal events (blacklisted). + * These events can't be emitted by the user. + * + * @api private + */ + +var events = { + connect: 1, + connect_error: 1, + connect_timeout: 1, + connecting: 1, + disconnect: 1, + error: 1, + reconnect: 1, + reconnect_attempt: 1, + reconnect_failed: 1, + reconnect_error: 1, + reconnecting: 1, + ping: 1, + pong: 1 +}; + +/** + * Shortcut to `Emitter#emit`. + */ + +var emit = Emitter.prototype.emit; + +/** + * `Socket` constructor. + * + * @api public + */ + +function Socket (io, nsp, opts) { + this.io = io; + this.nsp = nsp; + this.json = this; // compat + this.ids = 0; + this.acks = {}; + this.receiveBuffer = []; + this.sendBuffer = []; + this.connected = false; + this.disconnected = true; + this.flags = {}; + if (opts && opts.query) { + this.query = opts.query; + } + if (this.io.autoConnect) this.open(); +} + +/** + * Mix in `Emitter`. + */ + +Emitter(Socket.prototype); + +/** + * Subscribe to open, close and packet events + * + * @api private + */ + +Socket.prototype.subEvents = function () { + if (this.subs) return; + + var io = this.io; + this.subs = [ + on(io, 'open', bind(this, 'onopen')), + on(io, 'packet', bind(this, 'onpacket')), + on(io, 'close', bind(this, 'onclose')) + ]; +}; + +/** + * "Opens" the socket. + * + * @api public + */ + +Socket.prototype.open = +Socket.prototype.connect = function () { + if (this.connected) return this; + + this.subEvents(); + this.io.open(); // ensure open + if ('open' === this.io.readyState) this.onopen(); + this.emit('connecting'); + return this; +}; + +/** + * Sends a `message` event. + * + * @return {Socket} self + * @api public + */ + +Socket.prototype.send = function () { + var args = toArray(arguments); + args.unshift('message'); + this.emit.apply(this, args); + return this; +}; + +/** + * Override `emit`. + * If the event is in `events`, it's emitted normally. + * + * @param {String} event name + * @return {Socket} self + * @api public + */ + +Socket.prototype.emit = function (ev) { + if (events.hasOwnProperty(ev)) { + emit.apply(this, arguments); + return this; + } + + var args = toArray(arguments); + var packet = { + type: (this.flags.binary !== undefined ? this.flags.binary : hasBin(args)) ? parser.BINARY_EVENT : parser.EVENT, + data: args + }; + + packet.options = {}; + packet.options.compress = !this.flags || false !== this.flags.compress; + + // event ack callback + if ('function' === typeof args[args.length - 1]) { + debug('emitting packet with ack id %d', this.ids); + this.acks[this.ids] = args.pop(); + packet.id = this.ids++; + } + + if (this.connected) { + this.packet(packet); + } else { + this.sendBuffer.push(packet); + } + + this.flags = {}; + + return this; +}; + +/** + * Sends a packet. + * + * @param {Object} packet + * @api private + */ + +Socket.prototype.packet = function (packet) { + packet.nsp = this.nsp; + this.io.packet(packet); +}; + +/** + * Called upon engine `open`. + * + * @api private + */ + +Socket.prototype.onopen = function () { + debug('transport is open - connecting'); + + // write connect packet if necessary + if ('/' !== this.nsp) { + if (this.query) { + var query = typeof this.query === 'object' ? parseqs.encode(this.query) : this.query; + debug('sending connect packet with query %s', query); + this.packet({type: parser.CONNECT, query: query}); + } else { + this.packet({type: parser.CONNECT}); + } + } +}; + +/** + * Called upon engine `close`. + * + * @param {String} reason + * @api private + */ + +Socket.prototype.onclose = function (reason) { + debug('close (%s)', reason); + this.connected = false; + this.disconnected = true; + delete this.id; + this.emit('disconnect', reason); +}; + +/** + * Called with socket packet. + * + * @param {Object} packet + * @api private + */ + +Socket.prototype.onpacket = function (packet) { + var sameNamespace = packet.nsp === this.nsp; + var rootNamespaceError = packet.type === parser.ERROR && packet.nsp === '/'; + + if (!sameNamespace && !rootNamespaceError) return; + + switch (packet.type) { + case parser.CONNECT: + this.onconnect(); + break; + + case parser.EVENT: + this.onevent(packet); + break; + + case parser.BINARY_EVENT: + this.onevent(packet); + break; + + case parser.ACK: + this.onack(packet); + break; + + case parser.BINARY_ACK: + this.onack(packet); + break; + + case parser.DISCONNECT: + this.ondisconnect(); + break; + + case parser.ERROR: + this.emit('error', packet.data); + break; + } +}; + +/** + * Called upon a server event. + * + * @param {Object} packet + * @api private + */ + +Socket.prototype.onevent = function (packet) { + var args = packet.data || []; + debug('emitting event %j', args); + + if (null != packet.id) { + debug('attaching ack callback to event'); + args.push(this.ack(packet.id)); + } + + if (this.connected) { + emit.apply(this, args); + } else { + this.receiveBuffer.push(args); + } +}; + +/** + * Produces an ack callback to emit with an event. + * + * @api private + */ + +Socket.prototype.ack = function (id) { + var self = this; + var sent = false; + return function () { + // prevent double callbacks + if (sent) return; + sent = true; + var args = toArray(arguments); + debug('sending ack %j', args); + + self.packet({ + type: hasBin(args) ? parser.BINARY_ACK : parser.ACK, + id: id, + data: args + }); + }; +}; + +/** + * Called upon a server acknowlegement. + * + * @param {Object} packet + * @api private + */ + +Socket.prototype.onack = function (packet) { + var ack = this.acks[packet.id]; + if ('function' === typeof ack) { + debug('calling ack %s with %j', packet.id, packet.data); + ack.apply(this, packet.data); + delete this.acks[packet.id]; + } else { + debug('bad ack %s', packet.id); + } +}; + +/** + * Called upon server connect. + * + * @api private + */ + +Socket.prototype.onconnect = function () { + this.connected = true; + this.disconnected = false; + this.emit('connect'); + this.emitBuffered(); +}; + +/** + * Emit buffered events (received and emitted). + * + * @api private + */ + +Socket.prototype.emitBuffered = function () { + var i; + for (i = 0; i < this.receiveBuffer.length; i++) { + emit.apply(this, this.receiveBuffer[i]); + } + this.receiveBuffer = []; + + for (i = 0; i < this.sendBuffer.length; i++) { + this.packet(this.sendBuffer[i]); + } + this.sendBuffer = []; +}; + +/** + * Called upon server disconnect. + * + * @api private + */ + +Socket.prototype.ondisconnect = function () { + debug('server disconnect (%s)', this.nsp); + this.destroy(); + this.onclose('io server disconnect'); +}; + +/** + * Called upon forced client/server side disconnections, + * this method ensures the manager stops tracking us and + * that reconnections don't get triggered for this. + * + * @api private. + */ + +Socket.prototype.destroy = function () { + if (this.subs) { + // clean subscriptions to avoid reconnections + for (var i = 0; i < this.subs.length; i++) { + this.subs[i].destroy(); + } + this.subs = null; + } + + this.io.destroy(this); +}; + +/** + * Disconnects the socket manually. + * + * @return {Socket} self + * @api public + */ + +Socket.prototype.close = +Socket.prototype.disconnect = function () { + if (this.connected) { + debug('performing disconnect (%s)', this.nsp); + this.packet({ type: parser.DISCONNECT }); + } + + // remove socket from pool + this.destroy(); + + if (this.connected) { + // fire events + this.onclose('io client disconnect'); + } + return this; +}; + +/** + * Sets the compress flag. + * + * @param {Boolean} if `true`, compresses the sending data + * @return {Socket} self + * @api public + */ + +Socket.prototype.compress = function (compress) { + this.flags.compress = compress; + return this; +}; + +/** + * Sets the binary flag + * + * @param {Boolean} whether the emitted data contains binary + * @return {Socket} self + * @api public + */ + +Socket.prototype.binary = function (binary) { + this.flags.binary = binary; + return this; +}; + + +/***/ }), +/* 71 */ +/***/ (function(module, exports) { + + +/** + * Module exports. + */ + +module.exports = on; + +/** + * Helper for subscriptions. + * + * @param {Object|EventEmitter} obj with `Emitter` mixin or `EventEmitter` + * @param {String} event name + * @param {Function} callback + * @api public + */ + +function on (obj, ev, fn) { + obj.on(ev, fn); + return { + destroy: function () { + obj.removeListener(ev, fn); + } + }; +} + + +/***/ }), +/* 72 */ +/***/ (function(module, exports) { + +/** + * Slice reference. + */ + +var slice = [].slice; + +/** + * Bind `obj` to `fn`. + * + * @param {Object} obj + * @param {Function|String} fn or string + * @return {Function} + * @api public + */ + +module.exports = function(obj, fn){ + if ('string' == typeof fn) fn = obj[fn]; + if ('function' != typeof fn) throw new Error('bind() requires a function'); + var args = slice.call(arguments, 2); + return function(){ + return fn.apply(obj, args.concat(slice.call(arguments))); + } +}; + + +/***/ }), +/* 73 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var __extends = (this && this.__extends) || function (d, b) { + for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +}; +/** + * An error thrown when an action is invalid because the object has been + * unsubscribed. + * + * @see {@link Subject} + * @see {@link BehaviorSubject} + * + * @class ObjectUnsubscribedError + */ +var ObjectUnsubscribedError = (function (_super) { + __extends(ObjectUnsubscribedError, _super); + function ObjectUnsubscribedError() { + var err = _super.call(this, 'object unsubscribed'); + this.name = err.name = 'ObjectUnsubscribedError'; + this.stack = err.stack; + this.message = err.message; + } + return ObjectUnsubscribedError; +}(Error)); +exports.ObjectUnsubscribedError = ObjectUnsubscribedError; +//# sourceMappingURL=ObjectUnsubscribedError.js.map + +/***/ }), +/* 74 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var multicast_1 = __webpack_require__(135); +var refCount_1 = __webpack_require__(75); +var Subject_1 = __webpack_require__(37); +function shareSubjectFactory() { + return new Subject_1.Subject(); +} +/** + * Returns a new Observable that multicasts (shares) the original Observable. As long as there is at least one + * Subscriber this Observable will be subscribed and emitting data. When all subscribers have unsubscribed it will + * unsubscribe from the source Observable. Because the Observable is multicasting it makes the stream `hot`. + * This is an alias for .multicast(() => new Subject()).refCount(). + * + * + * + * @return {Observable} An Observable that upon connection causes the source Observable to emit items to its Observers. + * @method share + * @owner Observable + */ +function share() { + return function (source) { return refCount_1.refCount()(multicast_1.multicast(shareSubjectFactory)(source)); }; +} +exports.share = share; +; +//# sourceMappingURL=share.js.map + +/***/ }), +/* 75 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var __extends = (this && this.__extends) || function (d, b) { + for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +}; +var Subscriber_1 = __webpack_require__(3); +function refCount() { + return function refCountOperatorFunction(source) { + return source.lift(new RefCountOperator(source)); + }; +} +exports.refCount = refCount; +var RefCountOperator = (function () { + function RefCountOperator(connectable) { + this.connectable = connectable; + } + RefCountOperator.prototype.call = function (subscriber, source) { + var connectable = this.connectable; + connectable._refCount++; + var refCounter = new RefCountSubscriber(subscriber, connectable); + var subscription = source.subscribe(refCounter); + if (!refCounter.closed) { + refCounter.connection = connectable.connect(); + } + return subscription; + }; + return RefCountOperator; +}()); +var RefCountSubscriber = (function (_super) { + __extends(RefCountSubscriber, _super); + function RefCountSubscriber(destination, connectable) { + _super.call(this, destination); + this.connectable = connectable; + } + /** @deprecated internal use only */ RefCountSubscriber.prototype._unsubscribe = function () { + var connectable = this.connectable; + if (!connectable) { + this.connection = null; + return; + } + this.connectable = null; + var refCount = connectable._refCount; + if (refCount <= 0) { + this.connection = null; + return; + } + connectable._refCount = refCount - 1; + if (refCount > 1) { + this.connection = null; + return; + } + /// + // Compare the local RefCountSubscriber's connection Subscription to the + // connection Subscription on the shared ConnectableObservable. In cases + // where the ConnectableObservable source synchronously emits values, and + // the RefCountSubscriber's downstream Observers synchronously unsubscribe, + // execution continues to here before the RefCountOperator has a chance to + // supply the RefCountSubscriber with the shared connection Subscription. + // For example: + // ``` + // Observable.range(0, 10) + // .publish() + // .refCount() + // .take(5) + // .subscribe(); + // ``` + // In order to account for this case, RefCountSubscriber should only dispose + // the ConnectableObservable's shared connection Subscription if the + // connection Subscription exists, *and* either: + // a. RefCountSubscriber doesn't have a reference to the shared connection + // Subscription yet, or, + // b. RefCountSubscriber's connection Subscription reference is identical + // to the shared connection Subscription + /// + var connection = this.connection; + var sharedConnection = connectable._connection; + this.connection = null; + if (sharedConnection && (!connection || sharedConnection === connection)) { + sharedConnection.unsubscribe(); + } + }; + return RefCountSubscriber; +}(Subscriber_1.Subscriber)); +//# sourceMappingURL=refCount.js.map + +/***/ }), +/* 76 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +Object.defineProperty(exports, "__esModule", { value: true }); +var map_1 = __webpack_require__(2); +var tap_1 = __webpack_require__(5); +var dom_effects_1 = __webpack_require__(19); +var Log = __webpack_require__(14); +function propSetDomEffect(xs) { + return xs.pipe(tap_1.tap(function (event) { + var target = event.target, prop = event.prop, value = event.value; + target[prop] = value; + }), map_1.map(function (e) { + return Log.consoleInfo("[PropSet]", e.target, e.prop + " = " + e.pathname); + })); +} +exports.propSetDomEffect = propSetDomEffect; +function propSet(incoming) { + return [dom_effects_1.Events.PropSet, incoming]; +} +exports.propSet = propSet; + + +/***/ }), +/* 77 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var isArray_1 = __webpack_require__(26); +function isNumeric(val) { + // parseFloat NaNs numeric-cast false positives (null|true|false|"") + // ...but misinterprets leading-number strings, particularly hex literals ("0x...") + // subtraction forces infinities to NaN + // adding 1 corrects loss of precision from parseFloat (#15100) + return !isArray_1.isArray(val) && (val - parseFloat(val) + 1) >= 0; +} +exports.isNumeric = isNumeric; +; +//# sourceMappingURL=isNumeric.js.map + +/***/ }), +/* 78 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var AsyncAction_1 = __webpack_require__(79); +var AsyncScheduler_1 = __webpack_require__(80); +/** + * + * Async Scheduler + * + * Schedule task as if you used setTimeout(task, duration) + * + * `async` scheduler schedules tasks asynchronously, by putting them on the JavaScript + * event loop queue. It is best used to delay tasks in time or to schedule tasks repeating + * in intervals. + * + * If you just want to "defer" task, that is to perform it right after currently + * executing synchronous code ends (commonly achieved by `setTimeout(deferredTask, 0)`), + * better choice will be the {@link asap} scheduler. + * + * @example Use async scheduler to delay task + * const task = () => console.log('it works!'); + * + * Rx.Scheduler.async.schedule(task, 2000); + * + * // After 2 seconds logs: + * // "it works!" + * + * + * @example Use async scheduler to repeat task in intervals + * function task(state) { + * console.log(state); + * this.schedule(state + 1, 1000); // `this` references currently executing Action, + * // which we reschedule with new state and delay + * } + * + * Rx.Scheduler.async.schedule(task, 3000, 0); + * + * // Logs: + * // 0 after 3s + * // 1 after 4s + * // 2 after 5s + * // 3 after 6s + * + * @static true + * @name async + * @owner Scheduler + */ +exports.async = new AsyncScheduler_1.AsyncScheduler(AsyncAction_1.AsyncAction); +//# sourceMappingURL=async.js.map + +/***/ }), +/* 79 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var __extends = (this && this.__extends) || function (d, b) { + for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +}; +var root_1 = __webpack_require__(7); +var Action_1 = __webpack_require__(139); +/** + * We need this JSDoc comment for affecting ESDoc. + * @ignore + * @extends {Ignored} + */ +var AsyncAction = (function (_super) { + __extends(AsyncAction, _super); + function AsyncAction(scheduler, work) { + _super.call(this, scheduler, work); + this.scheduler = scheduler; + this.pending = false; + this.work = work; + } + AsyncAction.prototype.schedule = function (state, delay) { + if (delay === void 0) { delay = 0; } + if (this.closed) { + return this; + } + // Always replace the current state with the new state. + this.state = state; + // Set the pending flag indicating that this action has been scheduled, or + // has recursively rescheduled itself. + this.pending = true; + var id = this.id; + var scheduler = this.scheduler; + // + // Important implementation note: + // + // Actions only execute once by default, unless rescheduled from within the + // scheduled callback. This allows us to implement single and repeat + // actions via the same code path, without adding API surface area, as well + // as mimic traditional recursion but across asynchronous boundaries. + // + // However, JS runtimes and timers distinguish between intervals achieved by + // serial `setTimeout` calls vs. a single `setInterval` call. An interval of + // serial `setTimeout` calls can be individually delayed, which delays + // scheduling the next `setTimeout`, and so on. `setInterval` attempts to + // guarantee the interval callback will be invoked more precisely to the + // interval period, regardless of load. + // + // Therefore, we use `setInterval` to schedule single and repeat actions. + // If the action reschedules itself with the same delay, the interval is not + // canceled. If the action doesn't reschedule, or reschedules with a + // different delay, the interval will be canceled after scheduled callback + // execution. + // + if (id != null) { + this.id = this.recycleAsyncId(scheduler, id, delay); + } + this.delay = delay; + // If this action has already an async Id, don't request a new one. + this.id = this.id || this.requestAsyncId(scheduler, this.id, delay); + return this; + }; + AsyncAction.prototype.requestAsyncId = function (scheduler, id, delay) { + if (delay === void 0) { delay = 0; } + return root_1.root.setInterval(scheduler.flush.bind(scheduler, this), delay); + }; + AsyncAction.prototype.recycleAsyncId = function (scheduler, id, delay) { + if (delay === void 0) { delay = 0; } + // If this action is rescheduled with the same delay time, don't clear the interval id. + if (delay !== null && this.delay === delay && this.pending === false) { + return id; + } + // Otherwise, if the action's delay time is different from the current delay, + // or the action has been rescheduled before it's executed, clear the interval id + return root_1.root.clearInterval(id) && undefined || undefined; + }; + /** + * Immediately executes this action and the `work` it contains. + * @return {any} + */ + AsyncAction.prototype.execute = function (state, delay) { + if (this.closed) { + return new Error('executing a cancelled action'); + } + this.pending = false; + var error = this._execute(state, delay); + if (error) { + return error; + } + else if (this.pending === false && this.id != null) { + // Dequeue if the action didn't reschedule itself. Don't call + // unsubscribe(), because the action could reschedule later. + // For example: + // ``` + // scheduler.schedule(function doWork(counter) { + // /* ... I'm a busy worker bee ... */ + // var originalAction = this; + // /* wait 100ms before rescheduling the action */ + // setTimeout(function () { + // originalAction.schedule(counter + 1); + // }, 100); + // }, 1000); + // ``` + this.id = this.recycleAsyncId(this.scheduler, this.id, null); + } + }; + AsyncAction.prototype._execute = function (state, delay) { + var errored = false; + var errorValue = undefined; + try { + this.work(state); + } + catch (e) { + errored = true; + errorValue = !!e && e || new Error(e); + } + if (errored) { + this.unsubscribe(); + return errorValue; + } + }; + /** @deprecated internal use only */ AsyncAction.prototype._unsubscribe = function () { + var id = this.id; + var scheduler = this.scheduler; + var actions = scheduler.actions; + var index = actions.indexOf(this); + this.work = null; + this.state = null; + this.pending = false; + this.scheduler = null; + if (index !== -1) { + actions.splice(index, 1); + } + if (id != null) { + this.id = this.recycleAsyncId(scheduler, id, null); + } + this.delay = null; + }; + return AsyncAction; +}(Action_1.Action)); +exports.AsyncAction = AsyncAction; +//# sourceMappingURL=AsyncAction.js.map + +/***/ }), +/* 80 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var __extends = (this && this.__extends) || function (d, b) { + for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +}; +var Scheduler_1 = __webpack_require__(140); +var AsyncScheduler = (function (_super) { + __extends(AsyncScheduler, _super); + function AsyncScheduler() { + _super.apply(this, arguments); + this.actions = []; + /** + * A flag to indicate whether the Scheduler is currently executing a batch of + * queued actions. + * @type {boolean} + */ + this.active = false; + /** + * An internal ID used to track the latest asynchronous task such as those + * coming from `setTimeout`, `setInterval`, `requestAnimationFrame`, and + * others. + * @type {any} + */ + this.scheduled = undefined; + } + AsyncScheduler.prototype.flush = function (action) { + var actions = this.actions; + if (this.active) { + actions.push(action); + return; + } + var error; + this.active = true; + do { + if (error = action.execute(action.state, action.delay)) { + break; + } + } while (action = actions.shift()); // exhaust the scheduler queue + this.active = false; + if (error) { + while (action = actions.shift()) { + action.unsubscribe(); + } + throw error; + } + }; + return AsyncScheduler; +}(Scheduler_1.Scheduler)); +exports.AsyncScheduler = AsyncScheduler; +//# sourceMappingURL=AsyncScheduler.js.map + +/***/ }), +/* 81 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +Object.defineProperty(exports, "__esModule", { value: true }); +var map_1 = __webpack_require__(2); +var dom_effects_1 = __webpack_require__(19); +var tap_1 = __webpack_require__(5); +var Log = __webpack_require__(14); +function styleSetDomEffect(xs) { + return xs.pipe(tap_1.tap(function (event) { + var style = event.style, styleName = event.styleName, newValue = event.newValue; + style[styleName] = newValue; + }), map_1.map(function (e) { return Log.consoleInfo("[StyleSet] " + e.styleName + " = " + e.pathName); })); +} +exports.styleSetDomEffect = styleSetDomEffect; +function styleSet(incoming) { + return [dom_effects_1.Events.StyleSet, incoming]; +} +exports.styleSet = styleSet; + + +/***/ }), +/* 82 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +Object.defineProperty(exports, "__esModule", { value: true }); +var map_1 = __webpack_require__(2); +var filter_1 = __webpack_require__(4); +var withLatestFrom_1 = __webpack_require__(0); +var Log = __webpack_require__(14); +var pluck_1 = __webpack_require__(6); +var dom_effects_1 = __webpack_require__(19); +function linkReplaceDomEffect(xs, inputs) { + return xs.pipe(withLatestFrom_1.withLatestFrom(inputs.option$.pipe(pluck_1.pluck("injectNotification"))), filter_1.filter(function (_a) { + var inject = _a[1]; + return inject; + }), map_1.map(function (_a) { + var incoming = _a[0], inject = _a[1]; + var message = "[LinkReplace] " + incoming.basename; + if (inject === "overlay") { + return Log.overlayInfo(message); + } + return Log.consoleInfo(message); + })); +} +exports.linkReplaceDomEffect = linkReplaceDomEffect; +function linkReplace(incoming) { + return [dom_effects_1.Events.LinkReplace, incoming]; +} +exports.linkReplace = linkReplace; + + +/***/ }), +/* 83 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +Object.defineProperty(exports, "__esModule", { value: true }); +var ignoreElements_1 = __webpack_require__(11); +var withLatestFrom_1 = __webpack_require__(0); +var tap_1 = __webpack_require__(5); +var dom_effects_1 = __webpack_require__(19); +function setScroll(x, y) { + return [dom_effects_1.Events.SetScroll, { x: x, y: y }]; +} +exports.setScroll = setScroll; +function setScrollDomEffect(xs, inputs) { + return xs.pipe(withLatestFrom_1.withLatestFrom(inputs.window$), tap_1.tap(function (_a) { + var event = _a[0], window = _a[1]; + return window.scrollTo(event.x, event.y); + }), ignoreElements_1.ignoreElements()); +} +exports.setScrollDomEffect = setScrollDomEffect; + + +/***/ }), +/* 84 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +Object.defineProperty(exports, "__esModule", { value: true }); +var ignoreElements_1 = __webpack_require__(11); +var withLatestFrom_1 = __webpack_require__(0); +var tap_1 = __webpack_require__(5); +var dom_effects_1 = __webpack_require__(19); +function setWindowNameDomEffect(xs, inputs) { + return xs.pipe(withLatestFrom_1.withLatestFrom(inputs.window$), tap_1.tap(function (_a) { + var value = _a[0], window = _a[1]; + return (window.name = value); + }), ignoreElements_1.ignoreElements()); +} +exports.setWindowNameDomEffect = setWindowNameDomEffect; +function setWindowName(incoming) { + return [dom_effects_1.Events.SetWindowName, incoming]; +} +exports.setWindowName = setWindowName; + + +/***/ }), +/* 85 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +Object.defineProperty(exports, "__esModule", { value: true }); +var socket_messages_1 = __webpack_require__(10); +var pluck_1 = __webpack_require__(6); +var filter_1 = __webpack_require__(4); +var map_1 = __webpack_require__(2); +var withLatestFrom_1 = __webpack_require__(0); +var effects_1 = __webpack_require__(8); +function outgoing(data, tagName, index, mappingIndex) { + if (mappingIndex === void 0) { mappingIndex = -1; } + return [ + socket_messages_1.OutgoingSocketEvents.Scroll, + { position: data, tagName: tagName, index: index, mappingIndex: mappingIndex } + ]; +} +exports.outgoing = outgoing; +function incomingScrollHandler(xs, inputs) { + return xs.pipe(withLatestFrom_1.withLatestFrom(inputs.option$.pipe(pluck_1.pluck("ghostMode", "scroll")), inputs.window$.pipe(pluck_1.pluck("location", "pathname"))), filter_1.filter(function (_a) { + var event = _a[0], canScroll = _a[1], pathname = _a[2]; + return canScroll && event.pathname === pathname; + }), map_1.map(function (_a) { + var event = _a[0]; + return [effects_1.EffectNames.BrowserSetScroll, event]; + })); +} +exports.incomingScrollHandler = incomingScrollHandler; + + +/***/ }), +/* 86 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +Object.defineProperty(exports, "__esModule", { value: true }); +var effects_1 = __webpack_require__(8); +var Reloader_1 = __webpack_require__(143); +var withLatestFrom_1 = __webpack_require__(0); +var mergeMap_1 = __webpack_require__(15); +function fileReload(event) { + return [effects_1.EffectNames.FileReload, event]; +} +exports.fileReload = fileReload; +/** + * Attempt to reload files in place + * @param xs + * @param inputs + */ +function fileReloadEffect(xs, inputs) { + return xs.pipe(withLatestFrom_1.withLatestFrom(inputs.option$, inputs.document$, inputs.navigator$), mergeMap_1.mergeMap(function (_a) { + var event = _a[0], options = _a[1], document = _a[2], navigator = _a[3]; + return Reloader_1.reload(document, navigator)(event, { + tagNames: options.tagNames, + liveCSS: true, + liveImg: true + }); + })); +} +exports.fileReloadEffect = fileReloadEffect; + + +/***/ }), +/* 87 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var FromObservable_1 = __webpack_require__(144); +exports.from = FromObservable_1.FromObservable.create; +//# sourceMappingURL=from.js.map + +/***/ }), +/* 88 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var __extends = (this && this.__extends) || function (d, b) { + for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +}; +var Subscriber_1 = __webpack_require__(3); +/** + * Emits the given constant value on the output Observable every time the source + * Observable emits a value. + * + * Like {@link map}, but it maps every source value to + * the same output value every time. + * + * + * + * Takes a constant `value` as argument, and emits that whenever the source + * Observable emits a value. In other words, ignores the actual source value, + * and simply uses the emission moment to know when to emit the given `value`. + * + * @example Map every click to the string 'Hi' + * var clicks = Rx.Observable.fromEvent(document, 'click'); + * var greetings = clicks.mapTo('Hi'); + * greetings.subscribe(x => console.log(x)); + * + * @see {@link map} + * + * @param {any} value The value to map each source value to. + * @return {Observable} An Observable that emits the given `value` every time + * the source Observable emits something. + * @method mapTo + * @owner Observable + */ +function mapTo(value) { + return function (source) { return source.lift(new MapToOperator(value)); }; +} +exports.mapTo = mapTo; +var MapToOperator = (function () { + function MapToOperator(value) { + this.value = value; + } + MapToOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new MapToSubscriber(subscriber, this.value)); + }; + return MapToOperator; +}()); +/** + * We need this JSDoc comment for affecting ESDoc. + * @ignore + * @extends {Ignored} + */ +var MapToSubscriber = (function (_super) { + __extends(MapToSubscriber, _super); + function MapToSubscriber(destination, value) { + _super.call(this, destination); + this.value = value; + } + MapToSubscriber.prototype._next = function (x) { + this.destination.next(this.value); + }; + return MapToSubscriber; +}(Subscriber_1.Subscriber)); +//# sourceMappingURL=mapTo.js.map + +/***/ }), +/* 89 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +Object.defineProperty(exports, "__esModule", { value: true }); +var ignoreElements_1 = __webpack_require__(11); +var tap_1 = __webpack_require__(5); +var withLatestFrom_1 = __webpack_require__(0); +var effects_1 = __webpack_require__(8); +function browserSetLocationEffect(xs, inputs) { + return xs.pipe(withLatestFrom_1.withLatestFrom(inputs.window$), tap_1.tap(function (_a) { + var event = _a[0], window = _a[1]; + if (event.path) { + return (window.location = + window.location.protocol + + "//" + + window.location.host + + event.path); + } + if (event.url) { + return (window.location = event.url); + } + }), ignoreElements_1.ignoreElements()); +} +exports.browserSetLocationEffect = browserSetLocationEffect; +function browserSetLocation(input) { + return [effects_1.EffectNames.BrowserSetLocation, input]; +} +exports.browserSetLocation = browserSetLocation; + + +/***/ }), +/* 90 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +Object.defineProperty(exports, "__esModule", { value: true }); +var ignoreElements_1 = __webpack_require__(11); +var tap_1 = __webpack_require__(5); +var withLatestFrom_1 = __webpack_require__(0); +var effects_1 = __webpack_require__(8); +function simulateClickEffect(xs, inputs) { + return xs.pipe(withLatestFrom_1.withLatestFrom(inputs.window$, inputs.document$), tap_1.tap(function (_a) { + var event = _a[0], window = _a[1], document = _a[2]; + var elems = document.getElementsByTagName(event.tagName); + var match = elems[event.index]; + if (match) { + if (document.createEvent) { + window.setTimeout(function () { + var evObj = document.createEvent("MouseEvents"); + evObj.initEvent("click", true, true); + match.dispatchEvent(evObj); + }, 0); + } + else { + window.setTimeout(function () { + if (document.createEventObject) { + var evObj = document.createEventObject(); + evObj.cancelBubble = true; + match.fireEvent("on" + "click", evObj); + } + }, 0); + } + } + }), ignoreElements_1.ignoreElements()); +} +exports.simulateClickEffect = simulateClickEffect; +function simulateClick(event) { + return [effects_1.EffectNames.SimulateClick, event]; +} +exports.simulateClick = simulateClick; + + +/***/ }), +/* 91 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +Object.defineProperty(exports, "__esModule", { value: true }); +var tap_1 = __webpack_require__(5); +var withLatestFrom_1 = __webpack_require__(0); +var effects_1 = __webpack_require__(8); +function setElementValueEffect(xs, inputs) { + return xs.pipe(withLatestFrom_1.withLatestFrom(inputs.document$), tap_1.tap(function (_a) { + var event = _a[0], document = _a[1]; + var elems = document.getElementsByTagName(event.tagName); + var match = elems[event.index]; + if (match) { + match.value = event.value; + } + })); +} +exports.setElementValueEffect = setElementValueEffect; +function setElementValue(event) { + return [effects_1.EffectNames.SetElementValue, event]; +} +exports.setElementValue = setElementValue; + + +/***/ }), +/* 92 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +Object.defineProperty(exports, "__esModule", { value: true }); +var tap_1 = __webpack_require__(5); +var withLatestFrom_1 = __webpack_require__(0); +var effects_1 = __webpack_require__(8); +function setElementToggleValueEffect(xs, inputs) { + return xs.pipe(withLatestFrom_1.withLatestFrom(inputs.document$), tap_1.tap(function (_a) { + var event = _a[0], document = _a[1]; + var elems = document.getElementsByTagName(event.tagName); + var match = elems[event.index]; + if (match) { + if (event.type === "radio") { + match.checked = true; + } + if (event.type === "checkbox") { + match.checked = event.checked; + } + if (event.tagName === "SELECT") { + match.value = event.value; + } + } + })); +} +exports.setElementToggleValueEffect = setElementToggleValueEffect; +function setElementToggleValue(event) { + return [effects_1.EffectNames.SetElementToggleValue, event]; +} +exports.setElementToggleValue = setElementToggleValue; + + +/***/ }), +/* 93 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +Object.defineProperty(exports, "__esModule", { value: true }); +var effects_1 = __webpack_require__(8); +var tap_1 = __webpack_require__(5); +var withLatestFrom_1 = __webpack_require__(0); +function browserReload() { + return [effects_1.EffectNames.BrowserReload]; +} +exports.browserReload = browserReload; +function preBrowserReload() { + return [effects_1.EffectNames.PreBrowserReload]; +} +exports.preBrowserReload = preBrowserReload; +function browserReloadEffect(xs, inputs) { + return xs.pipe(withLatestFrom_1.withLatestFrom(inputs.window$), tap_1.tap(function (_a) { + var window = _a[1]; + return window.location.reload(true); + })); +} +exports.browserReloadEffect = browserReloadEffect; + + +/***/ }), +/* 94 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +Object.defineProperty(exports, "__esModule", { value: true }); +var socket_messages_1 = __webpack_require__(10); +var pluck_1 = __webpack_require__(6); +var filter_1 = __webpack_require__(4); +var map_1 = __webpack_require__(2); +var withLatestFrom_1 = __webpack_require__(0); +var simulate_click_effect_1 = __webpack_require__(90); +function outgoing(data) { + return [socket_messages_1.OutgoingSocketEvents.Click, data]; +} +exports.outgoing = outgoing; +function incomingHandler$(xs, inputs) { + return xs.pipe(withLatestFrom_1.withLatestFrom(inputs.option$.pipe(pluck_1.pluck("ghostMode", "clicks")), inputs.window$.pipe(pluck_1.pluck("location", "pathname"))), filter_1.filter(function (_a) { + var event = _a[0], canClick = _a[1], pathname = _a[2]; + return canClick && event.pathname === pathname; + }), map_1.map(function (_a) { + var event = _a[0]; + return simulate_click_effect_1.simulateClick(event); + })); +} +exports.incomingHandler$ = incomingHandler$; + + +/***/ }), +/* 95 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var __assign = (this && this.__assign) || function () { + __assign = Object.assign || function(t) { + for (var s, i = 1, n = arguments.length; i < n; i++) { + s = arguments[i]; + for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) + t[p] = s[p]; + } + return t; + }; + return __assign.apply(this, arguments); +}; +Object.defineProperty(exports, "__esModule", { value: true }); +var socket_messages_1 = __webpack_require__(10); +var pluck_1 = __webpack_require__(6); +var filter_1 = __webpack_require__(4); +var map_1 = __webpack_require__(2); +var withLatestFrom_1 = __webpack_require__(0); +var set_element_value_effect_1 = __webpack_require__(91); +function outgoing(element, value) { + return [ + socket_messages_1.OutgoingSocketEvents.Keyup, + __assign({}, element, { value: value }) + ]; +} +exports.outgoing = outgoing; +function incomingKeyupHandler(xs, inputs) { + return xs.pipe(withLatestFrom_1.withLatestFrom(inputs.option$.pipe(pluck_1.pluck("ghostMode", "forms", "inputs")), inputs.window$.pipe(pluck_1.pluck("location", "pathname"))), filter_1.filter(function (_a) { + var event = _a[0], canKeyup = _a[1], pathname = _a[2]; + return canKeyup && event.pathname === pathname; + }), map_1.map(function (_a) { + var event = _a[0]; + return set_element_value_effect_1.setElementValue(event); + })); +} +exports.incomingKeyupHandler = incomingKeyupHandler; + + +/***/ }), +/* 96 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +Object.defineProperty(exports, "__esModule", { value: true }); +var filter_1 = __webpack_require__(4); +var withLatestFrom_1 = __webpack_require__(0); +var mergeMap_1 = __webpack_require__(15); +var concat_1 = __webpack_require__(54); +var of_1 = __webpack_require__(9); +var browser_reload_effect_1 = __webpack_require__(93); +var subscribeOn_1 = __webpack_require__(158); +var async_1 = __webpack_require__(78); +function incomingBrowserReload(xs, inputs) { + return xs.pipe(withLatestFrom_1.withLatestFrom(inputs.option$), filter_1.filter(function (_a) { + var event = _a[0], options = _a[1]; + return options.codeSync; + }), mergeMap_1.mergeMap(reloadBrowserSafe)); +} +exports.incomingBrowserReload = incomingBrowserReload; +function reloadBrowserSafe() { + return concat_1.concat( + /** + * Emit a warning message allowing others to do some work + */ + of_1.of(browser_reload_effect_1.preBrowserReload()), + /** + * On the next tick, perform the reload + */ + of_1.of(browser_reload_effect_1.browserReload()).pipe(subscribeOn_1.subscribeOn(async_1.async))); +} +exports.reloadBrowserSafe = reloadBrowserSafe; + + +/***/ }), +/* 97 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(global) {var scope = (typeof global !== "undefined" && global) || + (typeof self !== "undefined" && self) || + window; +var apply = Function.prototype.apply; + +// DOM APIs, for completeness + +exports.setTimeout = function() { + return new Timeout(apply.call(setTimeout, scope, arguments), clearTimeout); +}; +exports.setInterval = function() { + return new Timeout(apply.call(setInterval, scope, arguments), clearInterval); +}; +exports.clearTimeout = +exports.clearInterval = function(timeout) { + if (timeout) { + timeout.close(); + } +}; + +function Timeout(id, clearFn) { + this._id = id; + this._clearFn = clearFn; +} +Timeout.prototype.unref = Timeout.prototype.ref = function() {}; +Timeout.prototype.close = function() { + this._clearFn.call(scope, this._id); +}; + +// Does not start the time, just sets up the members needed. +exports.enroll = function(item, msecs) { + clearTimeout(item._idleTimeoutId); + item._idleTimeout = msecs; +}; + +exports.unenroll = function(item) { + clearTimeout(item._idleTimeoutId); + item._idleTimeout = -1; +}; + +exports._unrefActive = exports.active = function(item) { + clearTimeout(item._idleTimeoutId); + + var msecs = item._idleTimeout; + if (msecs >= 0) { + item._idleTimeoutId = setTimeout(function onTimeout() { + if (item._onTimeout) + item._onTimeout(); + }, msecs); + } +}; + +// setimmediate attaches itself to the global object +__webpack_require__(163); +// On some exotic environments, it's not clear which object `setimmediate` was +// able to install onto. Search each possibility in the same order as the +// `setimmediate` library. +exports.setImmediate = (typeof self !== "undefined" && self.setImmediate) || + (typeof global !== "undefined" && global.setImmediate) || + (this && this.setImmediate); +exports.clearImmediate = (typeof self !== "undefined" && self.clearImmediate) || + (typeof global !== "undefined" && global.clearImmediate) || + (this && this.clearImmediate); + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(24))) + +/***/ }), +/* 98 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var __assign = (this && this.__assign) || function () { + __assign = Object.assign || function(t) { + for (var s, i = 1, n = arguments.length; i < n; i++) { + s = arguments[i]; + for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) + t[p] = s[p]; + } + return t; + }; + return __assign.apply(this, arguments); +}; +Object.defineProperty(exports, "__esModule", { value: true }); +var socket_messages_1 = __webpack_require__(10); +var pluck_1 = __webpack_require__(6); +var filter_1 = __webpack_require__(4); +var map_1 = __webpack_require__(2); +var withLatestFrom_1 = __webpack_require__(0); +var set_element_toggle_value_effect_1 = __webpack_require__(92); +function outgoing(element, props) { + return [ + socket_messages_1.OutgoingSocketEvents.InputToggle, + __assign({}, element, props) + ]; +} +exports.outgoing = outgoing; +function incomingInputsToggles(xs, inputs) { + return xs.pipe(withLatestFrom_1.withLatestFrom(inputs.option$.pipe(pluck_1.pluck("ghostMode", "forms", "toggles")), inputs.window$.pipe(pluck_1.pluck("location", "pathname"))), filter_1.filter(function (_a) { + var toggles = _a[1]; + return toggles === true; + }), map_1.map(function (_a) { + var event = _a[0]; + return set_element_toggle_value_effect_1.setElementToggleValue(event); + })); +} +exports.incomingInputsToggles = incomingInputsToggles; + + +/***/ }), +/* 99 */ +/***/ (function(module, exports, __webpack_require__) { + +module.exports = __webpack_require__(100); + + +/***/ }), +/* 100 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var __assign = (this && this.__assign) || function () { + __assign = Object.assign || function(t) { + for (var s, i = 1, n = arguments.length; i < n; i++) { + s = arguments[i]; + for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) + t[p] = s[p]; + } + return t; + }; + return __assign.apply(this, arguments); +}; +Object.defineProperty(exports, "__esModule", { value: true }); +var zip_1 = __webpack_require__(101); +var socket_1 = __webpack_require__(107); +var notify_1 = __webpack_require__(137); +var dom_effects_1 = __webpack_require__(19); +var socket_messages_1 = __webpack_require__(10); +var merge_1 = __webpack_require__(38); +var log_1 = __webpack_require__(14); +var effects_1 = __webpack_require__(8); +var scroll_restore_1 = __webpack_require__(169); +var listeners_1 = __webpack_require__(170); +var groupBy_1 = __webpack_require__(176); +var withLatestFrom_1 = __webpack_require__(0); +var mergeMap_1 = __webpack_require__(15); +var share_1 = __webpack_require__(74); +var filter_1 = __webpack_require__(4); +var pluck_1 = __webpack_require__(6); +var of_1 = __webpack_require__(9); +var window$ = socket_1.initWindow(); +var document$ = socket_1.initDocument(); +var names$ = scroll_restore_1.initWindowName(window); +var _a = socket_1.initSocket(), socket$ = _a.socket$, io$ = _a.io$; +var option$ = socket_1.initOptions(); +var navigator$ = of_1.of(navigator); +var notifyElement$ = notify_1.initNotify(option$.getValue()); +var logInstance$ = log_1.initLogger(option$.getValue()); +var outgoing$ = listeners_1.initListeners(window, document, socket$, option$); +var inputs = { + window$: window$, + document$: document$, + socket$: socket$, + option$: option$, + navigator$: navigator$, + notifyElement$: notifyElement$, + logInstance$: logInstance$, + io$: io$, + outgoing$: outgoing$ +}; +function getStream(name, inputs) { + return function (handlers$, inputStream$) { + return inputStream$.pipe(groupBy_1.groupBy(function (_a) { + var keyName = _a[0]; + return keyName; + }), withLatestFrom_1.withLatestFrom(handlers$), filter_1.filter(function (_a) { + var x = _a[0], handlers = _a[1]; + return typeof handlers[x.key] === "function"; + }), mergeMap_1.mergeMap(function (_a) { + var x = _a[0], handlers = _a[1]; + return handlers[x.key](x.pipe(pluck_1.pluck(String(1))), inputs); + }), share_1.share()); + }; +} +var combinedEffectHandler$ = zip_1.zip(effects_1.effectOutputHandlers$, scroll_restore_1.scrollRestoreHandlers$, function () { + var args = []; + for (var _i = 0; _i < arguments.length; _i++) { + args[_i] = arguments[_i]; + } + return args.reduce(function (acc, item) { return (__assign({}, acc, item)); }, {}); +}); +var output$ = getStream("[socket]", inputs)(socket_messages_1.socketHandlers$, merge_1.merge(inputs.socket$, outgoing$)); +var effect$ = getStream("[effect]", inputs)(combinedEffectHandler$, output$); +var dom$ = getStream("[dom-effect]", inputs)(dom_effects_1.domHandlers$, merge_1.merge(effect$, names$)); +var merged$ = merge_1.merge(output$, effect$, dom$); +var log$ = getStream("[log]", inputs)(log_1.logHandler$, merged$); +log$.subscribe(); +// resume$.next(true); +// var socket = require("./socket"); +// var shims = require("./client-shims"); +// var notify = require("./notify"); +// // var codeSync = require("./code-sync"); +// const { BrowserSync } = require("./browser-sync"); +// var ghostMode = require("./ghostmode"); +// var events = require("./events"); +// var utils = require("./browser.utils"); +// +// const mitt = require("mitt").default; +// +// var shouldReload = false; +// var initialised = false; +// +// /** +// * @param options +// */ +// function init(options: bs.InitOptions) { +// if (shouldReload && options.reloadOnRestart) { +// utils.reloadBrowser(); +// } +// +// var BS = window.___browserSync___ || {}; +// var emitter = mitt(); +// +// if (!BS.client) { +// BS.client = true; +// +// var browserSync = new BrowserSync({ options, emitter, socket }); +// +// // codeSync.init(browserSync); +// +// // // Always init on page load +// // ghostMode.init(browserSync); +// // +// // notify.init(browserSync); +// // +// // if (options.notify) { +// // notify.flash("Connected to BrowserSync"); +// // } +// } +// +// // if (!initialised) { +// // socket.on("disconnect", function() { +// // if (options.notify) { +// // notify.flash("Disconnected from BrowserSync"); +// // } +// // shouldReload = true; +// // }); +// // initialised = true; +// // } +// } +// +// /** +// * Handle individual socket connections +// */ +// socket.on("connection", init); + + +/***/ }), +/* 101 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var zip_1 = __webpack_require__(102); +exports.zip = zip_1.zipStatic; +//# sourceMappingURL=zip.js.map + +/***/ }), +/* 102 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var __extends = (this && this.__extends) || function (d, b) { + for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +}; +var ArrayObservable_1 = __webpack_require__(23); +var isArray_1 = __webpack_require__(26); +var Subscriber_1 = __webpack_require__(3); +var OuterSubscriber_1 = __webpack_require__(29); +var subscribeToResult_1 = __webpack_require__(30); +var iterator_1 = __webpack_require__(31); +/* tslint:enable:max-line-length */ +/** + * @param observables + * @return {Observable} + * @method zip + * @owner Observable + */ +function zip() { + var observables = []; + for (var _i = 0; _i < arguments.length; _i++) { + observables[_i - 0] = arguments[_i]; + } + return function zipOperatorFunction(source) { + return source.lift.call(zipStatic.apply(void 0, [source].concat(observables))); + }; +} +exports.zip = zip; +/* tslint:enable:max-line-length */ +/** + * Combines multiple Observables to create an Observable whose values are calculated from the values, in order, of each + * of its input Observables. + * + * If the latest parameter is a function, this function is used to compute the created value from the input values. + * Otherwise, an array of the input values is returned. + * + * @example Combine age and name from different sources + * + * let age$ = Observable.of(27, 25, 29); + * let name$ = Observable.of('Foo', 'Bar', 'Beer'); + * let isDev$ = Observable.of(true, true, false); + * + * Observable + * .zip(age$, + * name$, + * isDev$, + * (age: number, name: string, isDev: boolean) => ({ age, name, isDev })) + * .subscribe(x => console.log(x)); + * + * // outputs + * // { age: 27, name: 'Foo', isDev: true } + * // { age: 25, name: 'Bar', isDev: true } + * // { age: 29, name: 'Beer', isDev: false } + * + * @param observables + * @return {Observable} + * @static true + * @name zip + * @owner Observable + */ +function zipStatic() { + var observables = []; + for (var _i = 0; _i < arguments.length; _i++) { + observables[_i - 0] = arguments[_i]; + } + var project = observables[observables.length - 1]; + if (typeof project === 'function') { + observables.pop(); + } + return new ArrayObservable_1.ArrayObservable(observables).lift(new ZipOperator(project)); +} +exports.zipStatic = zipStatic; +var ZipOperator = (function () { + function ZipOperator(project) { + this.project = project; + } + ZipOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new ZipSubscriber(subscriber, this.project)); + }; + return ZipOperator; +}()); +exports.ZipOperator = ZipOperator; +/** + * We need this JSDoc comment for affecting ESDoc. + * @ignore + * @extends {Ignored} + */ +var ZipSubscriber = (function (_super) { + __extends(ZipSubscriber, _super); + function ZipSubscriber(destination, project, values) { + if (values === void 0) { values = Object.create(null); } + _super.call(this, destination); + this.iterators = []; + this.active = 0; + this.project = (typeof project === 'function') ? project : null; + this.values = values; + } + ZipSubscriber.prototype._next = function (value) { + var iterators = this.iterators; + if (isArray_1.isArray(value)) { + iterators.push(new StaticArrayIterator(value)); + } + else if (typeof value[iterator_1.iterator] === 'function') { + iterators.push(new StaticIterator(value[iterator_1.iterator]())); + } + else { + iterators.push(new ZipBufferIterator(this.destination, this, value)); + } + }; + ZipSubscriber.prototype._complete = function () { + var iterators = this.iterators; + var len = iterators.length; + if (len === 0) { + this.destination.complete(); + return; + } + this.active = len; + for (var i = 0; i < len; i++) { + var iterator = iterators[i]; + if (iterator.stillUnsubscribed) { + this.add(iterator.subscribe(iterator, i)); + } + else { + this.active--; // not an observable + } + } + }; + ZipSubscriber.prototype.notifyInactive = function () { + this.active--; + if (this.active === 0) { + this.destination.complete(); + } + }; + ZipSubscriber.prototype.checkIterators = function () { + var iterators = this.iterators; + var len = iterators.length; + var destination = this.destination; + // abort if not all of them have values + for (var i = 0; i < len; i++) { + var iterator = iterators[i]; + if (typeof iterator.hasValue === 'function' && !iterator.hasValue()) { + return; + } + } + var shouldComplete = false; + var args = []; + for (var i = 0; i < len; i++) { + var iterator = iterators[i]; + var result = iterator.next(); + // check to see if it's completed now that you've gotten + // the next value. + if (iterator.hasCompleted()) { + shouldComplete = true; + } + if (result.done) { + destination.complete(); + return; + } + args.push(result.value); + } + if (this.project) { + this._tryProject(args); + } + else { + destination.next(args); + } + if (shouldComplete) { + destination.complete(); + } + }; + ZipSubscriber.prototype._tryProject = function (args) { + var result; + try { + result = this.project.apply(this, args); + } + catch (err) { + this.destination.error(err); + return; + } + this.destination.next(result); + }; + return ZipSubscriber; +}(Subscriber_1.Subscriber)); +exports.ZipSubscriber = ZipSubscriber; +var StaticIterator = (function () { + function StaticIterator(iterator) { + this.iterator = iterator; + this.nextResult = iterator.next(); + } + StaticIterator.prototype.hasValue = function () { + return true; + }; + StaticIterator.prototype.next = function () { + var result = this.nextResult; + this.nextResult = this.iterator.next(); + return result; + }; + StaticIterator.prototype.hasCompleted = function () { + var nextResult = this.nextResult; + return nextResult && nextResult.done; + }; + return StaticIterator; +}()); +var StaticArrayIterator = (function () { + function StaticArrayIterator(array) { + this.array = array; + this.index = 0; + this.length = 0; + this.length = array.length; + } + StaticArrayIterator.prototype[iterator_1.iterator] = function () { + return this; + }; + StaticArrayIterator.prototype.next = function (value) { + var i = this.index++; + var array = this.array; + return i < this.length ? { value: array[i], done: false } : { value: null, done: true }; + }; + StaticArrayIterator.prototype.hasValue = function () { + return this.array.length > this.index; + }; + StaticArrayIterator.prototype.hasCompleted = function () { + return this.array.length === this.index; + }; + return StaticArrayIterator; +}()); +/** + * We need this JSDoc comment for affecting ESDoc. + * @ignore + * @extends {Ignored} + */ +var ZipBufferIterator = (function (_super) { + __extends(ZipBufferIterator, _super); + function ZipBufferIterator(destination, parent, observable) { + _super.call(this, destination); + this.parent = parent; + this.observable = observable; + this.stillUnsubscribed = true; + this.buffer = []; + this.isComplete = false; + } + ZipBufferIterator.prototype[iterator_1.iterator] = function () { + return this; + }; + // NOTE: there is actually a name collision here with Subscriber.next and Iterator.next + // this is legit because `next()` will never be called by a subscription in this case. + ZipBufferIterator.prototype.next = function () { + var buffer = this.buffer; + if (buffer.length === 0 && this.isComplete) { + return { value: null, done: true }; + } + else { + return { value: buffer.shift(), done: false }; + } + }; + ZipBufferIterator.prototype.hasValue = function () { + return this.buffer.length > 0; + }; + ZipBufferIterator.prototype.hasCompleted = function () { + return this.buffer.length === 0 && this.isComplete; + }; + ZipBufferIterator.prototype.notifyComplete = function () { + if (this.buffer.length > 0) { + this.isComplete = true; + this.parent.notifyInactive(); + } + else { + this.destination.complete(); + } + }; + ZipBufferIterator.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { + this.buffer.push(innerValue); + this.parent.checkIterators(); + }; + ZipBufferIterator.prototype.subscribe = function (value, index) { + return subscribeToResult_1.subscribeToResult(this, this.observable, this, index); + }; + return ZipBufferIterator; +}(OuterSubscriber_1.OuterSubscriber)); +//# sourceMappingURL=zip.js.map + +/***/ }), +/* 103 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var Subscriber_1 = __webpack_require__(3); +var rxSubscriber_1 = __webpack_require__(44); +var Observer_1 = __webpack_require__(57); +function toSubscriber(nextOrObserver, error, complete) { + if (nextOrObserver) { + if (nextOrObserver instanceof Subscriber_1.Subscriber) { + return nextOrObserver; + } + if (nextOrObserver[rxSubscriber_1.rxSubscriber]) { + return nextOrObserver[rxSubscriber_1.rxSubscriber](); + } + } + if (!nextOrObserver && !error && !complete) { + return new Subscriber_1.Subscriber(Observer_1.empty); + } + return new Subscriber_1.Subscriber(nextOrObserver, error, complete); +} +exports.toSubscriber = toSubscriber; +//# sourceMappingURL=toSubscriber.js.map + +/***/ }), +/* 104 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var __extends = (this && this.__extends) || function (d, b) { + for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +}; +/** + * An error thrown when one or more errors have occurred during the + * `unsubscribe` of a {@link Subscription}. + */ +var UnsubscriptionError = (function (_super) { + __extends(UnsubscriptionError, _super); + function UnsubscriptionError(errors) { + _super.call(this); + this.errors = errors; + var err = Error.call(this, errors ? + errors.length + " errors occurred during unsubscription:\n " + errors.map(function (err, i) { return ((i + 1) + ") " + err.toString()); }).join('\n ') : ''); + this.name = err.name = 'UnsubscriptionError'; + this.stack = err.stack; + this.message = err.message; + } + return UnsubscriptionError; +}(Error)); +exports.UnsubscriptionError = UnsubscriptionError; +//# sourceMappingURL=UnsubscriptionError.js.map + +/***/ }), +/* 105 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var noop_1 = __webpack_require__(58); +/* tslint:enable:max-line-length */ +function pipe() { + var fns = []; + for (var _i = 0; _i < arguments.length; _i++) { + fns[_i - 0] = arguments[_i]; + } + return pipeFromArray(fns); +} +exports.pipe = pipe; +/* @internal */ +function pipeFromArray(fns) { + if (!fns) { + return noop_1.noop; + } + if (fns.length === 1) { + return fns[0]; + } + return function piped(input) { + return fns.reduce(function (prev, fn) { return fn(prev); }, input); + }; +} +exports.pipeFromArray = pipeFromArray; +//# sourceMappingURL=pipe.js.map + +/***/ }), +/* 106 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var __extends = (this && this.__extends) || function (d, b) { + for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +}; +var Subscriber_1 = __webpack_require__(3); +/** + * We need this JSDoc comment for affecting ESDoc. + * @ignore + * @extends {Ignored} + */ +var InnerSubscriber = (function (_super) { + __extends(InnerSubscriber, _super); + function InnerSubscriber(parent, outerValue, outerIndex) { + _super.call(this); + this.parent = parent; + this.outerValue = outerValue; + this.outerIndex = outerIndex; + this.index = 0; + } + InnerSubscriber.prototype._next = function (value) { + this.parent.notifyNext(this.outerValue, value, this.outerIndex, this.index++, this); + }; + InnerSubscriber.prototype._error = function (error) { + this.parent.notifyError(error, this); + this.unsubscribe(); + }; + InnerSubscriber.prototype._complete = function () { + this.parent.notifyComplete(this); + this.unsubscribe(); + }; + return InnerSubscriber; +}(Subscriber_1.Subscriber)); +exports.InnerSubscriber = InnerSubscriber; +//# sourceMappingURL=InnerSubscriber.js.map + +/***/ }), +/* 107 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +Object.defineProperty(exports, "__esModule", { value: true }); +var socket = __webpack_require__(108); +var Observable_1 = __webpack_require__(1); +var BehaviorSubject_1 = __webpack_require__(13); +var of_1 = __webpack_require__(9); +var share_1 = __webpack_require__(74); +/** + * Alias for socket.emit + * @param name + * @param data + */ +// export function emit(name, data) { +// if (io && io.emit) { +// // send relative path of where the event is sent +// data.url = window.location.pathname; +// io.emit(name, data); +// } +// } +// +// /** +// * Alias for socket.on +// * @param name +// * @param func +// */ +// export function on(name, func) { +// io.on(name, func); +// } +function initWindow() { + return of_1.of(window); +} +exports.initWindow = initWindow; +function initDocument() { + return of_1.of(document); +} +exports.initDocument = initDocument; +function initNavigator() { + return of_1.of(navigator); +} +exports.initNavigator = initNavigator; +function initOptions() { + return new BehaviorSubject_1.BehaviorSubject(window.___browserSync___.options); +} +exports.initOptions = initOptions; +function initSocket() { + /** + * @type {{emit: emit, on: on}} + */ + var socketConfig = window.___browserSync___.socketConfig; + var socketUrl = window.___browserSync___.socketUrl; + var io = socket(socketUrl, socketConfig); + var onevent = io.onevent; + var socket$ = Observable_1.Observable.create(function (obs) { + io.onevent = function (packet) { + onevent.call(this, packet); + obs.next(packet.data); + }; + }).pipe(share_1.share()); + var io$ = new BehaviorSubject_1.BehaviorSubject(io); + /** + * *****BACK-COMPAT******* + * Scripts that come after Browsersync may rely on the previous window.___browserSync___.socket + */ + window.___browserSync___.socket = io; + return { socket$: socket$, io$: io$ }; +} +exports.initSocket = initSocket; + + +/***/ }), +/* 108 */ +/***/ (function(module, exports, __webpack_require__) { + + +/** + * Module dependencies. + */ + +var url = __webpack_require__(109); +var parser = __webpack_require__(48); +var Manager = __webpack_require__(64); +var debug = __webpack_require__(32)('socket.io-client'); + +/** + * Module exports. + */ + +module.exports = exports = lookup; + +/** + * Managers cache. + */ + +var cache = exports.managers = {}; + +/** + * Looks up an existing `Manager` for multiplexing. + * If the user summons: + * + * `io('http://localhost/a');` + * `io('http://localhost/b');` + * + * We reuse the existing instance based on same scheme/port/host, + * and we initialize sockets for each namespace. + * + * @api public + */ + +function lookup (uri, opts) { + if (typeof uri === 'object') { + opts = uri; + uri = undefined; + } + + opts = opts || {}; + + var parsed = url(uri); + var source = parsed.source; + var id = parsed.id; + var path = parsed.path; + var sameNamespace = cache[id] && path in cache[id].nsps; + var newConnection = opts.forceNew || opts['force new connection'] || + false === opts.multiplex || sameNamespace; + + var io; + + if (newConnection) { + debug('ignoring socket cache for %s', source); + io = Manager(source, opts); + } else { + if (!cache[id]) { + debug('new io instance for %s', source); + cache[id] = Manager(source, opts); + } + io = cache[id]; + } + if (parsed.query && !opts.query) { + opts.query = parsed.query; + } + return io.socket(parsed.path, opts); +} + +/** + * Protocol version. + * + * @api public + */ + +exports.protocol = parser.protocol; + +/** + * `connect`. + * + * @param {String} uri + * @api public + */ + +exports.connect = lookup; + +/** + * Expose constructors for standalone build. + * + * @api public + */ + +exports.Manager = __webpack_require__(64); +exports.Socket = __webpack_require__(70); + + +/***/ }), +/* 109 */ +/***/ (function(module, exports, __webpack_require__) { + + +/** + * Module dependencies. + */ + +var parseuri = __webpack_require__(61); +var debug = __webpack_require__(32)('socket.io-client:url'); + +/** + * Module exports. + */ + +module.exports = url; + +/** + * URL parser. + * + * @param {String} url + * @param {Object} An object meant to mimic window.location. + * Defaults to window.location. + * @api public + */ + +function url (uri, loc) { + var obj = uri; + + // default to window.location + loc = loc || (typeof location !== 'undefined' && location); + if (null == uri) uri = loc.protocol + '//' + loc.host; + + // relative path support + if ('string' === typeof uri) { + if ('/' === uri.charAt(0)) { + if ('/' === uri.charAt(1)) { + uri = loc.protocol + uri; + } else { + uri = loc.host + uri; + } + } + + if (!/^(https?|wss?):\/\//.test(uri)) { + debug('protocol-less url %s', uri); + if ('undefined' !== typeof loc) { + uri = loc.protocol + '//' + uri; + } else { + uri = 'https://' + uri; + } + } + + // parse + debug('parse %s', uri); + obj = parseuri(uri); + } + + // make sure we treat `localhost:80` and `localhost` equally + if (!obj.port) { + if (/^(http|ws)$/.test(obj.protocol)) { + obj.port = '80'; + } else if (/^(http|ws)s$/.test(obj.protocol)) { + obj.port = '443'; + } + } + + obj.path = obj.path || '/'; + + var ipv6 = obj.host.indexOf(':') !== -1; + var host = ipv6 ? '[' + obj.host + ']' : obj.host; + + // define unique id + obj.id = obj.protocol + '://' + host + ':' + obj.port; + // define href + obj.href = obj.protocol + '://' + host + (loc && loc.port === obj.port ? '' : (':' + obj.port)); + + return obj; +} + + +/***/ }), +/* 110 */ +/***/ (function(module, exports, __webpack_require__) { + + +/** + * This is the common logic for both the Node.js and web browser + * implementations of `debug()`. + * + * Expose `debug()` as the module. + */ + +exports = module.exports = createDebug.debug = createDebug['default'] = createDebug; +exports.coerce = coerce; +exports.disable = disable; +exports.enable = enable; +exports.enabled = enabled; +exports.humanize = __webpack_require__(47); + +/** + * Active `debug` instances. + */ +exports.instances = []; + +/** + * The currently active debug mode names, and names to skip. + */ + +exports.names = []; +exports.skips = []; + +/** + * Map of special "%n" handling functions, for the debug "format" argument. + * + * Valid key names are a single, lower or upper-case letter, i.e. "n" and "N". + */ + +exports.formatters = {}; + +/** + * Select a color. + * @param {String} namespace + * @return {Number} + * @api private + */ + +function selectColor(namespace) { + var hash = 0, i; + + for (i in namespace) { + hash = ((hash << 5) - hash) + namespace.charCodeAt(i); + hash |= 0; // Convert to 32bit integer + } + + return exports.colors[Math.abs(hash) % exports.colors.length]; +} + +/** + * Create a debugger with the given `namespace`. + * + * @param {String} namespace + * @return {Function} + * @api public + */ + +function createDebug(namespace) { + + var prevTime; + + function debug() { + // disabled? + if (!debug.enabled) return; + + var self = debug; + + // set `diff` timestamp + var curr = +new Date(); + var ms = curr - (prevTime || curr); + self.diff = ms; + self.prev = prevTime; + self.curr = curr; + prevTime = curr; + + // turn the `arguments` into a proper Array + var args = new Array(arguments.length); + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i]; + } + + args[0] = exports.coerce(args[0]); + + if ('string' !== typeof args[0]) { + // anything else let's inspect with %O + args.unshift('%O'); + } + + // apply any `formatters` transformations + var index = 0; + args[0] = args[0].replace(/%([a-zA-Z%])/g, function(match, format) { + // if we encounter an escaped % then don't increase the array index + if (match === '%%') return match; + index++; + var formatter = exports.formatters[format]; + if ('function' === typeof formatter) { + var val = args[index]; + match = formatter.call(self, val); + + // now we need to remove `args[index]` since it's inlined in the `format` + args.splice(index, 1); + index--; + } + return match; + }); + + // apply env-specific formatting (colors, etc.) + exports.formatArgs.call(self, args); + + var logFn = debug.log || exports.log || console.log.bind(console); + logFn.apply(self, args); + } + + debug.namespace = namespace; + debug.enabled = exports.enabled(namespace); + debug.useColors = exports.useColors(); + debug.color = selectColor(namespace); + debug.destroy = destroy; + + // env-specific initialization logic for debug instances + if ('function' === typeof exports.init) { + exports.init(debug); + } + + exports.instances.push(debug); + + return debug; +} + +function destroy () { + var index = exports.instances.indexOf(this); + if (index !== -1) { + exports.instances.splice(index, 1); + return true; + } else { + return false; + } +} + +/** + * Enables a debug mode by namespaces. This can include modes + * separated by a colon and wildcards. + * + * @param {String} namespaces + * @api public + */ + +function enable(namespaces) { + exports.save(namespaces); + + exports.names = []; + exports.skips = []; + + var i; + var split = (typeof namespaces === 'string' ? namespaces : '').split(/[\s,]+/); + var len = split.length; + + for (i = 0; i < len; i++) { + if (!split[i]) continue; // ignore empty strings + namespaces = split[i].replace(/\*/g, '.*?'); + if (namespaces[0] === '-') { + exports.skips.push(new RegExp('^' + namespaces.substr(1) + '$')); + } else { + exports.names.push(new RegExp('^' + namespaces + '$')); + } + } + + for (i = 0; i < exports.instances.length; i++) { + var instance = exports.instances[i]; + instance.enabled = exports.enabled(instance.namespace); + } +} + +/** + * Disable debug output. + * + * @api public + */ + +function disable() { + exports.enable(''); +} + +/** + * Returns true if the given mode name is enabled, false otherwise. + * + * @param {String} name + * @return {Boolean} + * @api public + */ + +function enabled(name) { + if (name[name.length - 1] === '*') { + return true; + } + var i, len; + for (i = 0, len = exports.skips.length; i < len; i++) { + if (exports.skips[i].test(name)) { + return false; + } + } + for (i = 0, len = exports.names.length; i < len; i++) { + if (exports.names[i].test(name)) { + return true; + } + } + return false; +} + +/** + * Coerce `val`. + * + * @param {Mixed} val + * @return {Mixed} + * @api private + */ + +function coerce(val) { + if (val instanceof Error) return val.stack || val.message; + return val; +} + + +/***/ }), +/* 111 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(process) {/** + * This is the web browser implementation of `debug()`. + * + * Expose `debug()` as the module. + */ + +exports = module.exports = __webpack_require__(112); +exports.log = log; +exports.formatArgs = formatArgs; +exports.save = save; +exports.load = load; +exports.useColors = useColors; +exports.storage = 'undefined' != typeof chrome + && 'undefined' != typeof chrome.storage + ? chrome.storage.local + : localstorage(); + +/** + * Colors. + */ + +exports.colors = [ + '#0000CC', '#0000FF', '#0033CC', '#0033FF', '#0066CC', '#0066FF', '#0099CC', + '#0099FF', '#00CC00', '#00CC33', '#00CC66', '#00CC99', '#00CCCC', '#00CCFF', + '#3300CC', '#3300FF', '#3333CC', '#3333FF', '#3366CC', '#3366FF', '#3399CC', + '#3399FF', '#33CC00', '#33CC33', '#33CC66', '#33CC99', '#33CCCC', '#33CCFF', + '#6600CC', '#6600FF', '#6633CC', '#6633FF', '#66CC00', '#66CC33', '#9900CC', + '#9900FF', '#9933CC', '#9933FF', '#99CC00', '#99CC33', '#CC0000', '#CC0033', + '#CC0066', '#CC0099', '#CC00CC', '#CC00FF', '#CC3300', '#CC3333', '#CC3366', + '#CC3399', '#CC33CC', '#CC33FF', '#CC6600', '#CC6633', '#CC9900', '#CC9933', + '#CCCC00', '#CCCC33', '#FF0000', '#FF0033', '#FF0066', '#FF0099', '#FF00CC', + '#FF00FF', '#FF3300', '#FF3333', '#FF3366', '#FF3399', '#FF33CC', '#FF33FF', + '#FF6600', '#FF6633', '#FF9900', '#FF9933', '#FFCC00', '#FFCC33' +]; + +/** + * Currently only WebKit-based Web Inspectors, Firefox >= v31, + * and the Firebug extension (any Firefox version) are known + * to support "%c" CSS customizations. + * + * TODO: add a `localStorage` variable to explicitly enable/disable colors + */ + +function useColors() { + // NB: In an Electron preload script, document will be defined but not fully + // initialized. Since we know we're in Chrome, we'll just detect this case + // explicitly + if (typeof window !== 'undefined' && window.process && window.process.type === 'renderer') { + return true; + } + + // Internet Explorer and Edge do not support colors. + if (typeof navigator !== 'undefined' && navigator.userAgent && navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/)) { + return false; + } + + // is webkit? http://stackoverflow.com/a/16459606/376773 + // document is undefined in react-native: https://github.com/facebook/react-native/pull/1632 + return (typeof document !== 'undefined' && document.documentElement && document.documentElement.style && document.documentElement.style.WebkitAppearance) || + // is firebug? http://stackoverflow.com/a/398120/376773 + (typeof window !== 'undefined' && window.console && (window.console.firebug || (window.console.exception && window.console.table))) || + // is firefox >= v31? + // https://developer.mozilla.org/en-US/docs/Tools/Web_Console#Styling_messages + (typeof navigator !== 'undefined' && navigator.userAgent && navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/) && parseInt(RegExp.$1, 10) >= 31) || + // double check webkit in userAgent just in case we are in a worker + (typeof navigator !== 'undefined' && navigator.userAgent && navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)); +} + +/** + * Map %j to `JSON.stringify()`, since no Web Inspectors do that by default. + */ + +exports.formatters.j = function(v) { + try { + return JSON.stringify(v); + } catch (err) { + return '[UnexpectedJSONParseError]: ' + err.message; + } +}; + + +/** + * Colorize log arguments if enabled. + * + * @api public + */ + +function formatArgs(args) { + var useColors = this.useColors; + + args[0] = (useColors ? '%c' : '') + + this.namespace + + (useColors ? ' %c' : ' ') + + args[0] + + (useColors ? '%c ' : ' ') + + '+' + exports.humanize(this.diff); + + if (!useColors) return; + + var c = 'color: ' + this.color; + args.splice(1, 0, c, 'color: inherit') + + // the final "%c" is somewhat tricky, because there could be other + // arguments passed either before or after the %c, so we need to + // figure out the correct index to insert the CSS into + var index = 0; + var lastC = 0; + args[0].replace(/%[a-zA-Z%]/g, function(match) { + if ('%%' === match) return; + index++; + if ('%c' === match) { + // we only are interested in the *last* %c + // (the user may have provided their own) + lastC = index; + } + }); + + args.splice(lastC, 0, c); +} + +/** + * Invokes `console.log()` when available. + * No-op when `console.log` is not a "function". + * + * @api public + */ + +function log() { + // this hackery is required for IE8/9, where + // the `console.log` function doesn't have 'apply' + return 'object' === typeof console + && console.log + && Function.prototype.apply.call(console.log, console, arguments); +} + +/** + * Save `namespaces`. + * + * @param {String} namespaces + * @api private + */ + +function save(namespaces) { + try { + if (null == namespaces) { + exports.storage.removeItem('debug'); + } else { + exports.storage.debug = namespaces; + } + } catch(e) {} +} + +/** + * Load `namespaces`. + * + * @return {String} returns the previously persisted debug modes + * @api private + */ + +function load() { + var r; + try { + r = exports.storage.debug; + } catch(e) {} + + // If debug isn't set in LS, and we're in Electron, try to load $DEBUG + if (!r && typeof process !== 'undefined' && 'env' in process) { + r = process.env.DEBUG; + } + + return r; +} + +/** + * Enable namespaces listed in `localStorage.debug` initially. + */ + +exports.enable(load()); + +/** + * Localstorage attempts to return the localstorage. + * + * This is necessary because safari throws + * when a user disables cookies/localstorage + * and you attempt to access it. + * + * @return {LocalStorage} + * @api private + */ + +function localstorage() { + try { + return window.localStorage; + } catch (e) {} +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(33))) + +/***/ }), +/* 112 */ +/***/ (function(module, exports, __webpack_require__) { + + +/** + * This is the common logic for both the Node.js and web browser + * implementations of `debug()`. + * + * Expose `debug()` as the module. + */ + +exports = module.exports = createDebug.debug = createDebug['default'] = createDebug; +exports.coerce = coerce; +exports.disable = disable; +exports.enable = enable; +exports.enabled = enabled; +exports.humanize = __webpack_require__(47); + +/** + * Active `debug` instances. + */ +exports.instances = []; + +/** + * The currently active debug mode names, and names to skip. + */ + +exports.names = []; +exports.skips = []; + +/** + * Map of special "%n" handling functions, for the debug "format" argument. + * + * Valid key names are a single, lower or upper-case letter, i.e. "n" and "N". + */ + +exports.formatters = {}; + +/** + * Select a color. + * @param {String} namespace + * @return {Number} + * @api private + */ + +function selectColor(namespace) { + var hash = 0, i; + + for (i in namespace) { + hash = ((hash << 5) - hash) + namespace.charCodeAt(i); + hash |= 0; // Convert to 32bit integer + } + + return exports.colors[Math.abs(hash) % exports.colors.length]; +} + +/** + * Create a debugger with the given `namespace`. + * + * @param {String} namespace + * @return {Function} + * @api public + */ + +function createDebug(namespace) { + + var prevTime; + + function debug() { + // disabled? + if (!debug.enabled) return; + + var self = debug; + + // set `diff` timestamp + var curr = +new Date(); + var ms = curr - (prevTime || curr); + self.diff = ms; + self.prev = prevTime; + self.curr = curr; + prevTime = curr; + + // turn the `arguments` into a proper Array + var args = new Array(arguments.length); + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i]; + } + + args[0] = exports.coerce(args[0]); + + if ('string' !== typeof args[0]) { + // anything else let's inspect with %O + args.unshift('%O'); + } + + // apply any `formatters` transformations + var index = 0; + args[0] = args[0].replace(/%([a-zA-Z%])/g, function(match, format) { + // if we encounter an escaped % then don't increase the array index + if (match === '%%') return match; + index++; + var formatter = exports.formatters[format]; + if ('function' === typeof formatter) { + var val = args[index]; + match = formatter.call(self, val); + + // now we need to remove `args[index]` since it's inlined in the `format` + args.splice(index, 1); + index--; + } + return match; + }); + + // apply env-specific formatting (colors, etc.) + exports.formatArgs.call(self, args); + + var logFn = debug.log || exports.log || console.log.bind(console); + logFn.apply(self, args); + } + + debug.namespace = namespace; + debug.enabled = exports.enabled(namespace); + debug.useColors = exports.useColors(); + debug.color = selectColor(namespace); + debug.destroy = destroy; + + // env-specific initialization logic for debug instances + if ('function' === typeof exports.init) { + exports.init(debug); + } + + exports.instances.push(debug); + + return debug; +} + +function destroy () { + var index = exports.instances.indexOf(this); + if (index !== -1) { + exports.instances.splice(index, 1); + return true; + } else { + return false; + } +} + +/** + * Enables a debug mode by namespaces. This can include modes + * separated by a colon and wildcards. + * + * @param {String} namespaces + * @api public + */ + +function enable(namespaces) { + exports.save(namespaces); + + exports.names = []; + exports.skips = []; + + var i; + var split = (typeof namespaces === 'string' ? namespaces : '').split(/[\s,]+/); + var len = split.length; + + for (i = 0; i < len; i++) { + if (!split[i]) continue; // ignore empty strings + namespaces = split[i].replace(/\*/g, '.*?'); + if (namespaces[0] === '-') { + exports.skips.push(new RegExp('^' + namespaces.substr(1) + '$')); + } else { + exports.names.push(new RegExp('^' + namespaces + '$')); + } + } + + for (i = 0; i < exports.instances.length; i++) { + var instance = exports.instances[i]; + instance.enabled = exports.enabled(instance.namespace); + } +} + +/** + * Disable debug output. + * + * @api public + */ + +function disable() { + exports.enable(''); +} + +/** + * Returns true if the given mode name is enabled, false otherwise. + * + * @param {String} name + * @return {Boolean} + * @api public + */ + +function enabled(name) { + if (name[name.length - 1] === '*') { + return true; + } + var i, len; + for (i = 0, len = exports.skips.length; i < len; i++) { + if (exports.skips[i].test(name)) { + return false; + } + } + for (i = 0, len = exports.names.length; i < len; i++) { + if (exports.names[i].test(name)) { + return true; + } + } + return false; +} + +/** + * Coerce `val`. + * + * @param {Mixed} val + * @return {Mixed} + * @api private + */ + +function coerce(val) { + if (val instanceof Error) return val.stack || val.message; + return val; +} + + +/***/ }), +/* 113 */ +/***/ (function(module, exports, __webpack_require__) { + +/*global Blob,File*/ + +/** + * Module requirements + */ + +var isArray = __webpack_require__(62); +var isBuf = __webpack_require__(63); +var toString = Object.prototype.toString; +var withNativeBlob = typeof Blob === 'function' || (typeof Blob !== 'undefined' && toString.call(Blob) === '[object BlobConstructor]'); +var withNativeFile = typeof File === 'function' || (typeof File !== 'undefined' && toString.call(File) === '[object FileConstructor]'); + +/** + * Replaces every Buffer | ArrayBuffer in packet with a numbered placeholder. + * Anything with blobs or files should be fed through removeBlobs before coming + * here. + * + * @param {Object} packet - socket.io event packet + * @return {Object} with deconstructed packet and list of buffers + * @api public + */ + +exports.deconstructPacket = function(packet) { + var buffers = []; + var packetData = packet.data; + var pack = packet; + pack.data = _deconstructPacket(packetData, buffers); + pack.attachments = buffers.length; // number of binary 'attachments' + return {packet: pack, buffers: buffers}; +}; + +function _deconstructPacket(data, buffers) { + if (!data) return data; + + if (isBuf(data)) { + var placeholder = { _placeholder: true, num: buffers.length }; + buffers.push(data); + return placeholder; + } else if (isArray(data)) { + var newData = new Array(data.length); + for (var i = 0; i < data.length; i++) { + newData[i] = _deconstructPacket(data[i], buffers); + } + return newData; + } else if (typeof data === 'object' && !(data instanceof Date)) { + var newData = {}; + for (var key in data) { + newData[key] = _deconstructPacket(data[key], buffers); + } + return newData; + } + return data; +} + +/** + * Reconstructs a binary packet from its placeholder packet and buffers + * + * @param {Object} packet - event packet with placeholders + * @param {Array} buffers - binary buffers to put in placeholder positions + * @return {Object} reconstructed packet + * @api public + */ + +exports.reconstructPacket = function(packet, buffers) { + packet.data = _reconstructPacket(packet.data, buffers); + packet.attachments = undefined; // no longer useful + return packet; +}; + +function _reconstructPacket(data, buffers) { + if (!data) return data; + + if (data && data._placeholder) { + return buffers[data.num]; // appropriate buffer (should be natural order anyway) + } else if (isArray(data)) { + for (var i = 0; i < data.length; i++) { + data[i] = _reconstructPacket(data[i], buffers); + } + } else if (typeof data === 'object') { + for (var key in data) { + data[key] = _reconstructPacket(data[key], buffers); + } + } + + return data; +} + +/** + * Asynchronously removes Blobs or Files from data via + * FileReader's readAsArrayBuffer method. Used before encoding + * data as msgpack. Calls callback with the blobless data. + * + * @param {Object} data + * @param {Function} callback + * @api private + */ + +exports.removeBlobs = function(data, callback) { + function _removeBlobs(obj, curKey, containingObject) { + if (!obj) return obj; + + // convert any blob + if ((withNativeBlob && obj instanceof Blob) || + (withNativeFile && obj instanceof File)) { + pendingBlobs++; + + // async filereader + var fileReader = new FileReader(); + fileReader.onload = function() { // this.result == arraybuffer + if (containingObject) { + containingObject[curKey] = this.result; + } + else { + bloblessData = this.result; + } + + // if nothing pending its callback time + if(! --pendingBlobs) { + callback(bloblessData); + } + }; + + fileReader.readAsArrayBuffer(obj); // blob -> arraybuffer + } else if (isArray(obj)) { // handle array + for (var i = 0; i < obj.length; i++) { + _removeBlobs(obj[i], i, obj); + } + } else if (typeof obj === 'object' && !isBuf(obj)) { // and object + for (var key in obj) { + _removeBlobs(obj[key], key, obj); + } + } + } + + var pendingBlobs = 0; + var bloblessData = data; + _removeBlobs(bloblessData); + if (!pendingBlobs) { + callback(bloblessData); + } +}; + + +/***/ }), +/* 114 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +exports.byteLength = byteLength +exports.toByteArray = toByteArray +exports.fromByteArray = fromByteArray + +var lookup = [] +var revLookup = [] +var Arr = typeof Uint8Array !== 'undefined' ? Uint8Array : Array + +var code = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/' +for (var i = 0, len = code.length; i < len; ++i) { + lookup[i] = code[i] + revLookup[code.charCodeAt(i)] = i +} + +// Support decoding URL-safe base64 strings, as Node.js does. +// See: https://en.wikipedia.org/wiki/Base64#URL_applications +revLookup['-'.charCodeAt(0)] = 62 +revLookup['_'.charCodeAt(0)] = 63 + +function getLens (b64) { + var len = b64.length + + if (len % 4 > 0) { + throw new Error('Invalid string. Length must be a multiple of 4') + } + + // Trim off extra bytes after placeholder bytes are found + // See: https://github.com/beatgammit/base64-js/issues/42 + var validLen = b64.indexOf('=') + if (validLen === -1) validLen = len + + var placeHoldersLen = validLen === len + ? 0 + : 4 - (validLen % 4) + + return [validLen, placeHoldersLen] +} + +// base64 is 4/3 + up to two characters of the original data +function byteLength (b64) { + var lens = getLens(b64) + var validLen = lens[0] + var placeHoldersLen = lens[1] + return ((validLen + placeHoldersLen) * 3 / 4) - placeHoldersLen +} + +function _byteLength (b64, validLen, placeHoldersLen) { + return ((validLen + placeHoldersLen) * 3 / 4) - placeHoldersLen +} + +function toByteArray (b64) { + var tmp + var lens = getLens(b64) + var validLen = lens[0] + var placeHoldersLen = lens[1] + + var arr = new Arr(_byteLength(b64, validLen, placeHoldersLen)) + + var curByte = 0 + + // if there are placeholders, only get up to the last complete 4 chars + var len = placeHoldersLen > 0 + ? validLen - 4 + : validLen + + for (var i = 0; i < len; i += 4) { + tmp = + (revLookup[b64.charCodeAt(i)] << 18) | + (revLookup[b64.charCodeAt(i + 1)] << 12) | + (revLookup[b64.charCodeAt(i + 2)] << 6) | + revLookup[b64.charCodeAt(i + 3)] + arr[curByte++] = (tmp >> 16) & 0xFF + arr[curByte++] = (tmp >> 8) & 0xFF + arr[curByte++] = tmp & 0xFF + } + + if (placeHoldersLen === 2) { + tmp = + (revLookup[b64.charCodeAt(i)] << 2) | + (revLookup[b64.charCodeAt(i + 1)] >> 4) + arr[curByte++] = tmp & 0xFF + } + + if (placeHoldersLen === 1) { + tmp = + (revLookup[b64.charCodeAt(i)] << 10) | + (revLookup[b64.charCodeAt(i + 1)] << 4) | + (revLookup[b64.charCodeAt(i + 2)] >> 2) + arr[curByte++] = (tmp >> 8) & 0xFF + arr[curByte++] = tmp & 0xFF + } + + return arr +} + +function tripletToBase64 (num) { + return lookup[num >> 18 & 0x3F] + + lookup[num >> 12 & 0x3F] + + lookup[num >> 6 & 0x3F] + + lookup[num & 0x3F] +} + +function encodeChunk (uint8, start, end) { + var tmp + var output = [] + for (var i = start; i < end; i += 3) { + tmp = + ((uint8[i] << 16) & 0xFF0000) + + ((uint8[i + 1] << 8) & 0xFF00) + + (uint8[i + 2] & 0xFF) + output.push(tripletToBase64(tmp)) + } + return output.join('') +} + +function fromByteArray (uint8) { + var tmp + var len = uint8.length + var extraBytes = len % 3 // if we have 1 byte left, pad 2 bytes + var parts = [] + var maxChunkLength = 16383 // must be multiple of 3 + + // go through the array every three bytes, we'll deal with trailing stuff later + for (var i = 0, len2 = len - extraBytes; i < len2; i += maxChunkLength) { + parts.push(encodeChunk( + uint8, i, (i + maxChunkLength) > len2 ? len2 : (i + maxChunkLength) + )) + } + + // pad the end with zeros, but make sure to not forget the extra bytes + if (extraBytes === 1) { + tmp = uint8[len - 1] + parts.push( + lookup[tmp >> 2] + + lookup[(tmp << 4) & 0x3F] + + '==' + ) + } else if (extraBytes === 2) { + tmp = (uint8[len - 2] << 8) + uint8[len - 1] + parts.push( + lookup[tmp >> 10] + + lookup[(tmp >> 4) & 0x3F] + + lookup[(tmp << 2) & 0x3F] + + '=' + ) + } + + return parts.join('') +} + + +/***/ }), +/* 115 */ +/***/ (function(module, exports) { + +exports.read = function (buffer, offset, isLE, mLen, nBytes) { + var e, m + var eLen = (nBytes * 8) - mLen - 1 + var eMax = (1 << eLen) - 1 + var eBias = eMax >> 1 + var nBits = -7 + var i = isLE ? (nBytes - 1) : 0 + var d = isLE ? -1 : 1 + var s = buffer[offset + i] + + i += d + + e = s & ((1 << (-nBits)) - 1) + s >>= (-nBits) + nBits += eLen + for (; nBits > 0; e = (e * 256) + buffer[offset + i], i += d, nBits -= 8) {} + + m = e & ((1 << (-nBits)) - 1) + e >>= (-nBits) + nBits += mLen + for (; nBits > 0; m = (m * 256) + buffer[offset + i], i += d, nBits -= 8) {} + + if (e === 0) { + e = 1 - eBias + } else if (e === eMax) { + return m ? NaN : ((s ? -1 : 1) * Infinity) + } else { + m = m + Math.pow(2, mLen) + e = e - eBias + } + return (s ? -1 : 1) * m * Math.pow(2, e - mLen) +} + +exports.write = function (buffer, value, offset, isLE, mLen, nBytes) { + var e, m, c + var eLen = (nBytes * 8) - mLen - 1 + var eMax = (1 << eLen) - 1 + var eBias = eMax >> 1 + var rt = (mLen === 23 ? Math.pow(2, -24) - Math.pow(2, -77) : 0) + var i = isLE ? 0 : (nBytes - 1) + var d = isLE ? 1 : -1 + var s = value < 0 || (value === 0 && 1 / value < 0) ? 1 : 0 + + value = Math.abs(value) + + if (isNaN(value) || value === Infinity) { + m = isNaN(value) ? 1 : 0 + e = eMax + } else { + e = Math.floor(Math.log(value) / Math.LN2) + if (value * (c = Math.pow(2, -e)) < 1) { + e-- + c *= 2 + } + if (e + eBias >= 1) { + value += rt / c + } else { + value += rt * Math.pow(2, 1 - eBias) + } + if (value * c >= 2) { + e++ + c /= 2 + } + + if (e + eBias >= eMax) { + m = 0 + e = eMax + } else if (e + eBias >= 1) { + m = ((value * c) - 1) * Math.pow(2, mLen) + e = e + eBias + } else { + m = value * Math.pow(2, eBias - 1) * Math.pow(2, mLen) + e = 0 + } + } + + for (; mLen >= 8; buffer[offset + i] = m & 0xff, i += d, m /= 256, mLen -= 8) {} + + e = (e << mLen) | m + eLen += mLen + for (; eLen > 0; buffer[offset + i] = e & 0xff, i += d, e /= 256, eLen -= 8) {} + + buffer[offset + i - d] |= s * 128 +} + + +/***/ }), +/* 116 */ +/***/ (function(module, exports) { + +var toString = {}.toString; + +module.exports = Array.isArray || function (arr) { + return toString.call(arr) == '[object Array]'; +}; + + +/***/ }), +/* 117 */ +/***/ (function(module, exports, __webpack_require__) { + + +module.exports = __webpack_require__(118); + +/** + * Exports parser + * + * @api public + * + */ +module.exports.parser = __webpack_require__(18); + + +/***/ }), +/* 118 */ +/***/ (function(module, exports, __webpack_require__) { + +/** + * Module dependencies. + */ + +var transports = __webpack_require__(65); +var Emitter = __webpack_require__(17); +var debug = __webpack_require__(36)('engine.io-client:socket'); +var index = __webpack_require__(69); +var parser = __webpack_require__(18); +var parseuri = __webpack_require__(61); +var parseqs = __webpack_require__(34); + +/** + * Module exports. + */ + +module.exports = Socket; + +/** + * Socket constructor. + * + * @param {String|Object} uri or options + * @param {Object} options + * @api public + */ + +function Socket (uri, opts) { + if (!(this instanceof Socket)) return new Socket(uri, opts); + + opts = opts || {}; + + if (uri && 'object' === typeof uri) { + opts = uri; + uri = null; + } + + if (uri) { + uri = parseuri(uri); + opts.hostname = uri.host; + opts.secure = uri.protocol === 'https' || uri.protocol === 'wss'; + opts.port = uri.port; + if (uri.query) opts.query = uri.query; + } else if (opts.host) { + opts.hostname = parseuri(opts.host).host; + } + + this.secure = null != opts.secure ? opts.secure + : (typeof location !== 'undefined' && 'https:' === location.protocol); + + if (opts.hostname && !opts.port) { + // if no port is specified manually, use the protocol default + opts.port = this.secure ? '443' : '80'; + } + + this.agent = opts.agent || false; + this.hostname = opts.hostname || + (typeof location !== 'undefined' ? location.hostname : 'localhost'); + this.port = opts.port || (typeof location !== 'undefined' && location.port + ? location.port + : (this.secure ? 443 : 80)); + this.query = opts.query || {}; + if ('string' === typeof this.query) this.query = parseqs.decode(this.query); + this.upgrade = false !== opts.upgrade; + this.path = (opts.path || '/engine.io').replace(/\/$/, '') + '/'; + this.forceJSONP = !!opts.forceJSONP; + this.jsonp = false !== opts.jsonp; + this.forceBase64 = !!opts.forceBase64; + this.enablesXDR = !!opts.enablesXDR; + this.timestampParam = opts.timestampParam || 't'; + this.timestampRequests = opts.timestampRequests; + this.transports = opts.transports || ['polling', 'websocket']; + this.transportOptions = opts.transportOptions || {}; + this.readyState = ''; + this.writeBuffer = []; + this.prevBufferLen = 0; + this.policyPort = opts.policyPort || 843; + this.rememberUpgrade = opts.rememberUpgrade || false; + this.binaryType = null; + this.onlyBinaryUpgrades = opts.onlyBinaryUpgrades; + this.perMessageDeflate = false !== opts.perMessageDeflate ? (opts.perMessageDeflate || {}) : false; + + if (true === this.perMessageDeflate) this.perMessageDeflate = {}; + if (this.perMessageDeflate && null == this.perMessageDeflate.threshold) { + this.perMessageDeflate.threshold = 1024; + } + + // SSL options for Node.js client + this.pfx = opts.pfx || null; + this.key = opts.key || null; + this.passphrase = opts.passphrase || null; + this.cert = opts.cert || null; + this.ca = opts.ca || null; + this.ciphers = opts.ciphers || null; + this.rejectUnauthorized = opts.rejectUnauthorized === undefined ? true : opts.rejectUnauthorized; + this.forceNode = !!opts.forceNode; + + // detect ReactNative environment + this.isReactNative = (typeof navigator !== 'undefined' && typeof navigator.product === 'string' && navigator.product.toLowerCase() === 'reactnative'); + + // other options for Node.js or ReactNative client + if (typeof self === 'undefined' || this.isReactNative) { + if (opts.extraHeaders && Object.keys(opts.extraHeaders).length > 0) { + this.extraHeaders = opts.extraHeaders; + } + + if (opts.localAddress) { + this.localAddress = opts.localAddress; + } + } + + // set on handshake + this.id = null; + this.upgrades = null; + this.pingInterval = null; + this.pingTimeout = null; + + // set on heartbeat + this.pingIntervalTimer = null; + this.pingTimeoutTimer = null; + + this.open(); +} + +Socket.priorWebsocketSuccess = false; + +/** + * Mix in `Emitter`. + */ + +Emitter(Socket.prototype); + +/** + * Protocol version. + * + * @api public + */ + +Socket.protocol = parser.protocol; // this is an int + +/** + * Expose deps for legacy compatibility + * and standalone browser access. + */ + +Socket.Socket = Socket; +Socket.Transport = __webpack_require__(51); +Socket.transports = __webpack_require__(65); +Socket.parser = __webpack_require__(18); + +/** + * Creates transport of the given type. + * + * @param {String} transport name + * @return {Transport} + * @api private + */ + +Socket.prototype.createTransport = function (name) { + debug('creating transport "%s"', name); + var query = clone(this.query); + + // append engine.io protocol identifier + query.EIO = parser.protocol; + + // transport name + query.transport = name; + + // per-transport options + var options = this.transportOptions[name] || {}; + + // session id if we already have one + if (this.id) query.sid = this.id; + + var transport = new transports[name]({ + query: query, + socket: this, + agent: options.agent || this.agent, + hostname: options.hostname || this.hostname, + port: options.port || this.port, + secure: options.secure || this.secure, + path: options.path || this.path, + forceJSONP: options.forceJSONP || this.forceJSONP, + jsonp: options.jsonp || this.jsonp, + forceBase64: options.forceBase64 || this.forceBase64, + enablesXDR: options.enablesXDR || this.enablesXDR, + timestampRequests: options.timestampRequests || this.timestampRequests, + timestampParam: options.timestampParam || this.timestampParam, + policyPort: options.policyPort || this.policyPort, + pfx: options.pfx || this.pfx, + key: options.key || this.key, + passphrase: options.passphrase || this.passphrase, + cert: options.cert || this.cert, + ca: options.ca || this.ca, + ciphers: options.ciphers || this.ciphers, + rejectUnauthorized: options.rejectUnauthorized || this.rejectUnauthorized, + perMessageDeflate: options.perMessageDeflate || this.perMessageDeflate, + extraHeaders: options.extraHeaders || this.extraHeaders, + forceNode: options.forceNode || this.forceNode, + localAddress: options.localAddress || this.localAddress, + requestTimeout: options.requestTimeout || this.requestTimeout, + protocols: options.protocols || void (0), + isReactNative: this.isReactNative + }); + + return transport; +}; + +function clone (obj) { + var o = {}; + for (var i in obj) { + if (obj.hasOwnProperty(i)) { + o[i] = obj[i]; + } + } + return o; +} + +/** + * Initializes transport to use and starts probe. + * + * @api private + */ +Socket.prototype.open = function () { + var transport; + if (this.rememberUpgrade && Socket.priorWebsocketSuccess && this.transports.indexOf('websocket') !== -1) { + transport = 'websocket'; + } else if (0 === this.transports.length) { + // Emit error on next tick so it can be listened to + var self = this; + setTimeout(function () { + self.emit('error', 'No transports available'); + }, 0); + return; + } else { + transport = this.transports[0]; + } + this.readyState = 'opening'; + + // Retry with the next transport if the transport is disabled (jsonp: false) + try { + transport = this.createTransport(transport); + } catch (e) { + this.transports.shift(); + this.open(); + return; + } + + transport.open(); + this.setTransport(transport); +}; + +/** + * Sets the current transport. Disables the existing one (if any). + * + * @api private + */ + +Socket.prototype.setTransport = function (transport) { + debug('setting transport %s', transport.name); + var self = this; + + if (this.transport) { + debug('clearing existing transport %s', this.transport.name); + this.transport.removeAllListeners(); + } + + // set up transport + this.transport = transport; + + // set up transport listeners + transport + .on('drain', function () { + self.onDrain(); + }) + .on('packet', function (packet) { + self.onPacket(packet); + }) + .on('error', function (e) { + self.onError(e); + }) + .on('close', function () { + self.onClose('transport close'); + }); +}; + +/** + * Probes a transport. + * + * @param {String} transport name + * @api private + */ + +Socket.prototype.probe = function (name) { + debug('probing transport "%s"', name); + var transport = this.createTransport(name, { probe: 1 }); + var failed = false; + var self = this; + + Socket.priorWebsocketSuccess = false; + + function onTransportOpen () { + if (self.onlyBinaryUpgrades) { + var upgradeLosesBinary = !this.supportsBinary && self.transport.supportsBinary; + failed = failed || upgradeLosesBinary; + } + if (failed) return; + + debug('probe transport "%s" opened', name); + transport.send([{ type: 'ping', data: 'probe' }]); + transport.once('packet', function (msg) { + if (failed) return; + if ('pong' === msg.type && 'probe' === msg.data) { + debug('probe transport "%s" pong', name); + self.upgrading = true; + self.emit('upgrading', transport); + if (!transport) return; + Socket.priorWebsocketSuccess = 'websocket' === transport.name; + + debug('pausing current transport "%s"', self.transport.name); + self.transport.pause(function () { + if (failed) return; + if ('closed' === self.readyState) return; + debug('changing transport and sending upgrade packet'); + + cleanup(); + + self.setTransport(transport); + transport.send([{ type: 'upgrade' }]); + self.emit('upgrade', transport); + transport = null; + self.upgrading = false; + self.flush(); + }); + } else { + debug('probe transport "%s" failed', name); + var err = new Error('probe error'); + err.transport = transport.name; + self.emit('upgradeError', err); + } + }); + } + + function freezeTransport () { + if (failed) return; + + // Any callback called by transport should be ignored since now + failed = true; + + cleanup(); + + transport.close(); + transport = null; + } + + // Handle any error that happens while probing + function onerror (err) { + var error = new Error('probe error: ' + err); + error.transport = transport.name; + + freezeTransport(); + + debug('probe transport "%s" failed because of error: %s', name, err); + + self.emit('upgradeError', error); + } + + function onTransportClose () { + onerror('transport closed'); + } + + // When the socket is closed while we're probing + function onclose () { + onerror('socket closed'); + } + + // When the socket is upgraded while we're probing + function onupgrade (to) { + if (transport && to.name !== transport.name) { + debug('"%s" works - aborting "%s"', to.name, transport.name); + freezeTransport(); + } + } + + // Remove all listeners on the transport and on self + function cleanup () { + transport.removeListener('open', onTransportOpen); + transport.removeListener('error', onerror); + transport.removeListener('close', onTransportClose); + self.removeListener('close', onclose); + self.removeListener('upgrading', onupgrade); + } + + transport.once('open', onTransportOpen); + transport.once('error', onerror); + transport.once('close', onTransportClose); + + this.once('close', onclose); + this.once('upgrading', onupgrade); + + transport.open(); +}; + +/** + * Called when connection is deemed open. + * + * @api public + */ + +Socket.prototype.onOpen = function () { + debug('socket open'); + this.readyState = 'open'; + Socket.priorWebsocketSuccess = 'websocket' === this.transport.name; + this.emit('open'); + this.flush(); + + // we check for `readyState` in case an `open` + // listener already closed the socket + if ('open' === this.readyState && this.upgrade && this.transport.pause) { + debug('starting upgrade probes'); + for (var i = 0, l = this.upgrades.length; i < l; i++) { + this.probe(this.upgrades[i]); + } + } +}; + +/** + * Handles a packet. + * + * @api private + */ + +Socket.prototype.onPacket = function (packet) { + if ('opening' === this.readyState || 'open' === this.readyState || + 'closing' === this.readyState) { + debug('socket receive: type "%s", data "%s"', packet.type, packet.data); + + this.emit('packet', packet); + + // Socket is live - any packet counts + this.emit('heartbeat'); + + switch (packet.type) { + case 'open': + this.onHandshake(JSON.parse(packet.data)); + break; + + case 'pong': + this.setPing(); + this.emit('pong'); + break; + + case 'error': + var err = new Error('server error'); + err.code = packet.data; + this.onError(err); + break; + + case 'message': + this.emit('data', packet.data); + this.emit('message', packet.data); + break; + } + } else { + debug('packet received with socket readyState "%s"', this.readyState); + } +}; + +/** + * Called upon handshake completion. + * + * @param {Object} handshake obj + * @api private + */ + +Socket.prototype.onHandshake = function (data) { + this.emit('handshake', data); + this.id = data.sid; + this.transport.query.sid = data.sid; + this.upgrades = this.filterUpgrades(data.upgrades); + this.pingInterval = data.pingInterval; + this.pingTimeout = data.pingTimeout; + this.onOpen(); + // In case open handler closes socket + if ('closed' === this.readyState) return; + this.setPing(); + + // Prolong liveness of socket on heartbeat + this.removeListener('heartbeat', this.onHeartbeat); + this.on('heartbeat', this.onHeartbeat); +}; + +/** + * Resets ping timeout. + * + * @api private + */ + +Socket.prototype.onHeartbeat = function (timeout) { + clearTimeout(this.pingTimeoutTimer); + var self = this; + self.pingTimeoutTimer = setTimeout(function () { + if ('closed' === self.readyState) return; + self.onClose('ping timeout'); + }, timeout || (self.pingInterval + self.pingTimeout)); +}; + +/** + * Pings server every `this.pingInterval` and expects response + * within `this.pingTimeout` or closes connection. + * + * @api private + */ + +Socket.prototype.setPing = function () { + var self = this; + clearTimeout(self.pingIntervalTimer); + self.pingIntervalTimer = setTimeout(function () { + debug('writing ping packet - expecting pong within %sms', self.pingTimeout); + self.ping(); + self.onHeartbeat(self.pingTimeout); + }, self.pingInterval); +}; + +/** +* Sends a ping packet. +* +* @api private +*/ + +Socket.prototype.ping = function () { + var self = this; + this.sendPacket('ping', function () { + self.emit('ping'); + }); +}; + +/** + * Called on `drain` event + * + * @api private + */ + +Socket.prototype.onDrain = function () { + this.writeBuffer.splice(0, this.prevBufferLen); + + // setting prevBufferLen = 0 is very important + // for example, when upgrading, upgrade packet is sent over, + // and a nonzero prevBufferLen could cause problems on `drain` + this.prevBufferLen = 0; + + if (0 === this.writeBuffer.length) { + this.emit('drain'); + } else { + this.flush(); + } +}; + +/** + * Flush write buffers. + * + * @api private + */ + +Socket.prototype.flush = function () { + if ('closed' !== this.readyState && this.transport.writable && + !this.upgrading && this.writeBuffer.length) { + debug('flushing %d packets in socket', this.writeBuffer.length); + this.transport.send(this.writeBuffer); + // keep track of current length of writeBuffer + // splice writeBuffer and callbackBuffer on `drain` + this.prevBufferLen = this.writeBuffer.length; + this.emit('flush'); + } +}; + +/** + * Sends a message. + * + * @param {String} message. + * @param {Function} callback function. + * @param {Object} options. + * @return {Socket} for chaining. + * @api public + */ + +Socket.prototype.write = +Socket.prototype.send = function (msg, options, fn) { + this.sendPacket('message', msg, options, fn); + return this; +}; + +/** + * Sends a packet. + * + * @param {String} packet type. + * @param {String} data. + * @param {Object} options. + * @param {Function} callback function. + * @api private + */ + +Socket.prototype.sendPacket = function (type, data, options, fn) { + if ('function' === typeof data) { + fn = data; + data = undefined; + } + + if ('function' === typeof options) { + fn = options; + options = null; + } + + if ('closing' === this.readyState || 'closed' === this.readyState) { + return; + } + + options = options || {}; + options.compress = false !== options.compress; + + var packet = { + type: type, + data: data, + options: options + }; + this.emit('packetCreate', packet); + this.writeBuffer.push(packet); + if (fn) this.once('flush', fn); + this.flush(); +}; + +/** + * Closes the connection. + * + * @api private + */ + +Socket.prototype.close = function () { + if ('opening' === this.readyState || 'open' === this.readyState) { + this.readyState = 'closing'; + + var self = this; + + if (this.writeBuffer.length) { + this.once('drain', function () { + if (this.upgrading) { + waitForUpgrade(); + } else { + close(); + } + }); + } else if (this.upgrading) { + waitForUpgrade(); + } else { + close(); + } + } + + function close () { + self.onClose('forced close'); + debug('socket closing - telling transport to close'); + self.transport.close(); + } + + function cleanupAndClose () { + self.removeListener('upgrade', cleanupAndClose); + self.removeListener('upgradeError', cleanupAndClose); + close(); + } + + function waitForUpgrade () { + // wait for upgrade to finish since we can't send packets while pausing a transport + self.once('upgrade', cleanupAndClose); + self.once('upgradeError', cleanupAndClose); + } + + return this; +}; + +/** + * Called upon transport error + * + * @api private + */ + +Socket.prototype.onError = function (err) { + debug('socket error %j', err); + Socket.priorWebsocketSuccess = false; + this.emit('error', err); + this.onClose('transport error', err); +}; + +/** + * Called upon transport close. + * + * @api private + */ + +Socket.prototype.onClose = function (reason, desc) { + if ('opening' === this.readyState || 'open' === this.readyState || 'closing' === this.readyState) { + debug('socket close with reason: "%s"', reason); + var self = this; + + // clear timers + clearTimeout(this.pingIntervalTimer); + clearTimeout(this.pingTimeoutTimer); + + // stop event from firing again for transport + this.transport.removeAllListeners('close'); + + // ensure transport won't stay open + this.transport.close(); + + // ignore further transport communication + this.transport.removeAllListeners(); + + // set ready state + this.readyState = 'closed'; + + // clear session id + this.id = null; + + // emit close event + this.emit('close', reason, desc); + + // clean buffers after, so users can still + // grab the buffers on `close` event + self.writeBuffer = []; + self.prevBufferLen = 0; + } +}; + +/** + * Filters upgrades, returning only those matching client transports. + * + * @param {Array} server upgrades + * @api private + * + */ + +Socket.prototype.filterUpgrades = function (upgrades) { + var filteredUpgrades = []; + for (var i = 0, j = upgrades.length; i < j; i++) { + if (~index(this.transports, upgrades[i])) filteredUpgrades.push(upgrades[i]); + } + return filteredUpgrades; +}; + + +/***/ }), +/* 119 */ +/***/ (function(module, exports) { + + +/** + * Module exports. + * + * Logic borrowed from Modernizr: + * + * - https://github.com/Modernizr/Modernizr/blob/master/feature-detects/cors.js + */ + +try { + module.exports = typeof XMLHttpRequest !== 'undefined' && + 'withCredentials' in new XMLHttpRequest(); +} catch (err) { + // if XMLHttp support is disabled in IE then it will throw + // when trying to create + module.exports = false; +} + + +/***/ }), +/* 120 */ +/***/ (function(module, exports, __webpack_require__) { + +/* global attachEvent */ + +/** + * Module requirements. + */ + +var XMLHttpRequest = __webpack_require__(50); +var Polling = __webpack_require__(66); +var Emitter = __webpack_require__(17); +var inherit = __webpack_require__(35); +var debug = __webpack_require__(36)('engine.io-client:polling-xhr'); + +/** + * Module exports. + */ + +module.exports = XHR; +module.exports.Request = Request; + +/** + * Empty function + */ + +function empty () {} + +/** + * XHR Polling constructor. + * + * @param {Object} opts + * @api public + */ + +function XHR (opts) { + Polling.call(this, opts); + this.requestTimeout = opts.requestTimeout; + this.extraHeaders = opts.extraHeaders; + + if (typeof location !== 'undefined') { + var isSSL = 'https:' === location.protocol; + var port = location.port; + + // some user agents have empty `location.port` + if (!port) { + port = isSSL ? 443 : 80; + } + + this.xd = (typeof location !== 'undefined' && opts.hostname !== location.hostname) || + port !== opts.port; + this.xs = opts.secure !== isSSL; + } +} + +/** + * Inherits from Polling. + */ + +inherit(XHR, Polling); + +/** + * XHR supports binary + */ + +XHR.prototype.supportsBinary = true; + +/** + * Creates a request. + * + * @param {String} method + * @api private + */ + +XHR.prototype.request = function (opts) { + opts = opts || {}; + opts.uri = this.uri(); + opts.xd = this.xd; + opts.xs = this.xs; + opts.agent = this.agent || false; + opts.supportsBinary = this.supportsBinary; + opts.enablesXDR = this.enablesXDR; + + // SSL options for Node.js client + opts.pfx = this.pfx; + opts.key = this.key; + opts.passphrase = this.passphrase; + opts.cert = this.cert; + opts.ca = this.ca; + opts.ciphers = this.ciphers; + opts.rejectUnauthorized = this.rejectUnauthorized; + opts.requestTimeout = this.requestTimeout; + + // other options for Node.js client + opts.extraHeaders = this.extraHeaders; + + return new Request(opts); +}; + +/** + * Sends data. + * + * @param {String} data to send. + * @param {Function} called upon flush. + * @api private + */ + +XHR.prototype.doWrite = function (data, fn) { + var isBinary = typeof data !== 'string' && data !== undefined; + var req = this.request({ method: 'POST', data: data, isBinary: isBinary }); + var self = this; + req.on('success', fn); + req.on('error', function (err) { + self.onError('xhr post error', err); + }); + this.sendXhr = req; +}; + +/** + * Starts a poll cycle. + * + * @api private + */ + +XHR.prototype.doPoll = function () { + debug('xhr poll'); + var req = this.request(); + var self = this; + req.on('data', function (data) { + self.onData(data); + }); + req.on('error', function (err) { + self.onError('xhr poll error', err); + }); + this.pollXhr = req; +}; + +/** + * Request constructor + * + * @param {Object} options + * @api public + */ + +function Request (opts) { + this.method = opts.method || 'GET'; + this.uri = opts.uri; + this.xd = !!opts.xd; + this.xs = !!opts.xs; + this.async = false !== opts.async; + this.data = undefined !== opts.data ? opts.data : null; + this.agent = opts.agent; + this.isBinary = opts.isBinary; + this.supportsBinary = opts.supportsBinary; + this.enablesXDR = opts.enablesXDR; + this.requestTimeout = opts.requestTimeout; + + // SSL options for Node.js client + this.pfx = opts.pfx; + this.key = opts.key; + this.passphrase = opts.passphrase; + this.cert = opts.cert; + this.ca = opts.ca; + this.ciphers = opts.ciphers; + this.rejectUnauthorized = opts.rejectUnauthorized; + + // other options for Node.js client + this.extraHeaders = opts.extraHeaders; + + this.create(); +} + +/** + * Mix in `Emitter`. + */ + +Emitter(Request.prototype); + +/** + * Creates the XHR object and sends the request. + * + * @api private + */ + +Request.prototype.create = function () { + var opts = { agent: this.agent, xdomain: this.xd, xscheme: this.xs, enablesXDR: this.enablesXDR }; + + // SSL options for Node.js client + opts.pfx = this.pfx; + opts.key = this.key; + opts.passphrase = this.passphrase; + opts.cert = this.cert; + opts.ca = this.ca; + opts.ciphers = this.ciphers; + opts.rejectUnauthorized = this.rejectUnauthorized; + + var xhr = this.xhr = new XMLHttpRequest(opts); + var self = this; + + try { + debug('xhr open %s: %s', this.method, this.uri); + xhr.open(this.method, this.uri, this.async); + try { + if (this.extraHeaders) { + xhr.setDisableHeaderCheck && xhr.setDisableHeaderCheck(true); + for (var i in this.extraHeaders) { + if (this.extraHeaders.hasOwnProperty(i)) { + xhr.setRequestHeader(i, this.extraHeaders[i]); + } + } + } + } catch (e) {} + + if ('POST' === this.method) { + try { + if (this.isBinary) { + xhr.setRequestHeader('Content-type', 'application/octet-stream'); + } else { + xhr.setRequestHeader('Content-type', 'text/plain;charset=UTF-8'); + } + } catch (e) {} + } + + try { + xhr.setRequestHeader('Accept', '*/*'); + } catch (e) {} + + // ie6 check + if ('withCredentials' in xhr) { + xhr.withCredentials = true; + } + + if (this.requestTimeout) { + xhr.timeout = this.requestTimeout; + } + + if (this.hasXDR()) { + xhr.onload = function () { + self.onLoad(); + }; + xhr.onerror = function () { + self.onError(xhr.responseText); + }; + } else { + xhr.onreadystatechange = function () { + if (xhr.readyState === 2) { + try { + var contentType = xhr.getResponseHeader('Content-Type'); + if (self.supportsBinary && contentType === 'application/octet-stream') { + xhr.responseType = 'arraybuffer'; + } + } catch (e) {} + } + if (4 !== xhr.readyState) return; + if (200 === xhr.status || 1223 === xhr.status) { + self.onLoad(); + } else { + // make sure the `error` event handler that's user-set + // does not throw in the same tick and gets caught here + setTimeout(function () { + self.onError(xhr.status); + }, 0); + } + }; + } + + debug('xhr data %s', this.data); + xhr.send(this.data); + } catch (e) { + // Need to defer since .create() is called directly fhrom the constructor + // and thus the 'error' event can only be only bound *after* this exception + // occurs. Therefore, also, we cannot throw here at all. + setTimeout(function () { + self.onError(e); + }, 0); + return; + } + + if (typeof document !== 'undefined') { + this.index = Request.requestsCount++; + Request.requests[this.index] = this; + } +}; + +/** + * Called upon successful response. + * + * @api private + */ + +Request.prototype.onSuccess = function () { + this.emit('success'); + this.cleanup(); +}; + +/** + * Called if we have data. + * + * @api private + */ + +Request.prototype.onData = function (data) { + this.emit('data', data); + this.onSuccess(); +}; + +/** + * Called upon error. + * + * @api private + */ + +Request.prototype.onError = function (err) { + this.emit('error', err); + this.cleanup(true); +}; + +/** + * Cleans up house. + * + * @api private + */ + +Request.prototype.cleanup = function (fromError) { + if ('undefined' === typeof this.xhr || null === this.xhr) { + return; + } + // xmlhttprequest + if (this.hasXDR()) { + this.xhr.onload = this.xhr.onerror = empty; + } else { + this.xhr.onreadystatechange = empty; + } + + if (fromError) { + try { + this.xhr.abort(); + } catch (e) {} + } + + if (typeof document !== 'undefined') { + delete Request.requests[this.index]; + } + + this.xhr = null; +}; + +/** + * Called upon load. + * + * @api private + */ + +Request.prototype.onLoad = function () { + var data; + try { + var contentType; + try { + contentType = this.xhr.getResponseHeader('Content-Type'); + } catch (e) {} + if (contentType === 'application/octet-stream') { + data = this.xhr.response || this.xhr.responseText; + } else { + data = this.xhr.responseText; + } + } catch (e) { + this.onError(e); + } + if (null != data) { + this.onData(data); + } +}; + +/** + * Check if it has XDomainRequest. + * + * @api private + */ + +Request.prototype.hasXDR = function () { + return typeof XDomainRequest !== 'undefined' && !this.xs && this.enablesXDR; +}; + +/** + * Aborts the request. + * + * @api public + */ + +Request.prototype.abort = function () { + this.cleanup(); +}; + +/** + * Aborts pending requests when unloading the window. This is needed to prevent + * memory leaks (e.g. when using IE) and to ensure that no spurious error is + * emitted. + */ + +Request.requestsCount = 0; +Request.requests = {}; + +if (typeof document !== 'undefined') { + if (typeof attachEvent === 'function') { + attachEvent('onunload', unloadHandler); + } else if (typeof addEventListener === 'function') { + var terminationEvent = 'onpagehide' in self ? 'pagehide' : 'unload'; + addEventListener(terminationEvent, unloadHandler, false); + } +} + +function unloadHandler () { + for (var i in Request.requests) { + if (Request.requests.hasOwnProperty(i)) { + Request.requests[i].abort(); + } + } +} + + +/***/ }), +/* 121 */ +/***/ (function(module, exports) { + + +/** + * Gets the keys for an object. + * + * @return {Array} keys + * @api private + */ + +module.exports = Object.keys || function keys (obj){ + var arr = []; + var has = Object.prototype.hasOwnProperty; + + for (var i in obj) { + if (has.call(obj, i)) { + arr.push(i); + } + } + return arr; +}; + + +/***/ }), +/* 122 */ +/***/ (function(module, exports) { + +var toString = {}.toString; + +module.exports = Array.isArray || function (arr) { + return toString.call(arr) == '[object Array]'; +}; + + +/***/ }), +/* 123 */ +/***/ (function(module, exports) { + +/** + * An abstraction for slicing an arraybuffer even when + * ArrayBuffer.prototype.slice is not supported + * + * @api public + */ + +module.exports = function(arraybuffer, start, end) { + var bytes = arraybuffer.byteLength; + start = start || 0; + end = end || bytes; + + if (arraybuffer.slice) { return arraybuffer.slice(start, end); } + + if (start < 0) { start += bytes; } + if (end < 0) { end += bytes; } + if (end > bytes) { end = bytes; } + + if (start >= bytes || start >= end || bytes === 0) { + return new ArrayBuffer(0); + } + + var abv = new Uint8Array(arraybuffer); + var result = new Uint8Array(end - start); + for (var i = start, ii = 0; i < end; i++, ii++) { + result[ii] = abv[i]; + } + return result.buffer; +}; + + +/***/ }), +/* 124 */ +/***/ (function(module, exports) { + +module.exports = after + +function after(count, callback, err_cb) { + var bail = false + err_cb = err_cb || noop + proxy.count = count + + return (count === 0) ? callback() : proxy + + function proxy(err, result) { + if (proxy.count <= 0) { + throw new Error('after called too many times') + } + --proxy.count + + // after first error, rest are passed to err_cb + if (err) { + bail = true + callback(err) + // future error callbacks will go to error handler + callback = err_cb + } else if (proxy.count === 0 && !bail) { + callback(null, result) + } + } +} + +function noop() {} + + +/***/ }), +/* 125 */ +/***/ (function(module, exports) { + +/*! https://mths.be/utf8js v2.1.2 by @mathias */ + +var stringFromCharCode = String.fromCharCode; + +// Taken from https://mths.be/punycode +function ucs2decode(string) { + var output = []; + var counter = 0; + var length = string.length; + var value; + var extra; + while (counter < length) { + value = string.charCodeAt(counter++); + if (value >= 0xD800 && value <= 0xDBFF && counter < length) { + // high surrogate, and there is a next character + extra = string.charCodeAt(counter++); + if ((extra & 0xFC00) == 0xDC00) { // low surrogate + output.push(((value & 0x3FF) << 10) + (extra & 0x3FF) + 0x10000); + } else { + // unmatched surrogate; only append this code unit, in case the next + // code unit is the high surrogate of a surrogate pair + output.push(value); + counter--; + } + } else { + output.push(value); + } + } + return output; +} + +// Taken from https://mths.be/punycode +function ucs2encode(array) { + var length = array.length; + var index = -1; + var value; + var output = ''; + while (++index < length) { + value = array[index]; + if (value > 0xFFFF) { + value -= 0x10000; + output += stringFromCharCode(value >>> 10 & 0x3FF | 0xD800); + value = 0xDC00 | value & 0x3FF; + } + output += stringFromCharCode(value); + } + return output; +} + +function checkScalarValue(codePoint, strict) { + if (codePoint >= 0xD800 && codePoint <= 0xDFFF) { + if (strict) { + throw Error( + 'Lone surrogate U+' + codePoint.toString(16).toUpperCase() + + ' is not a scalar value' + ); + } + return false; + } + return true; +} +/*--------------------------------------------------------------------------*/ + +function createByte(codePoint, shift) { + return stringFromCharCode(((codePoint >> shift) & 0x3F) | 0x80); +} + +function encodeCodePoint(codePoint, strict) { + if ((codePoint & 0xFFFFFF80) == 0) { // 1-byte sequence + return stringFromCharCode(codePoint); + } + var symbol = ''; + if ((codePoint & 0xFFFFF800) == 0) { // 2-byte sequence + symbol = stringFromCharCode(((codePoint >> 6) & 0x1F) | 0xC0); + } + else if ((codePoint & 0xFFFF0000) == 0) { // 3-byte sequence + if (!checkScalarValue(codePoint, strict)) { + codePoint = 0xFFFD; + } + symbol = stringFromCharCode(((codePoint >> 12) & 0x0F) | 0xE0); + symbol += createByte(codePoint, 6); + } + else if ((codePoint & 0xFFE00000) == 0) { // 4-byte sequence + symbol = stringFromCharCode(((codePoint >> 18) & 0x07) | 0xF0); + symbol += createByte(codePoint, 12); + symbol += createByte(codePoint, 6); + } + symbol += stringFromCharCode((codePoint & 0x3F) | 0x80); + return symbol; +} + +function utf8encode(string, opts) { + opts = opts || {}; + var strict = false !== opts.strict; + + var codePoints = ucs2decode(string); + var length = codePoints.length; + var index = -1; + var codePoint; + var byteString = ''; + while (++index < length) { + codePoint = codePoints[index]; + byteString += encodeCodePoint(codePoint, strict); + } + return byteString; +} + +/*--------------------------------------------------------------------------*/ + +function readContinuationByte() { + if (byteIndex >= byteCount) { + throw Error('Invalid byte index'); + } + + var continuationByte = byteArray[byteIndex] & 0xFF; + byteIndex++; + + if ((continuationByte & 0xC0) == 0x80) { + return continuationByte & 0x3F; + } + + // If we end up here, it’s not a continuation byte + throw Error('Invalid continuation byte'); +} + +function decodeSymbol(strict) { + var byte1; + var byte2; + var byte3; + var byte4; + var codePoint; + + if (byteIndex > byteCount) { + throw Error('Invalid byte index'); + } + + if (byteIndex == byteCount) { + return false; + } + + // Read first byte + byte1 = byteArray[byteIndex] & 0xFF; + byteIndex++; + + // 1-byte sequence (no continuation bytes) + if ((byte1 & 0x80) == 0) { + return byte1; + } + + // 2-byte sequence + if ((byte1 & 0xE0) == 0xC0) { + byte2 = readContinuationByte(); + codePoint = ((byte1 & 0x1F) << 6) | byte2; + if (codePoint >= 0x80) { + return codePoint; + } else { + throw Error('Invalid continuation byte'); + } + } + + // 3-byte sequence (may include unpaired surrogates) + if ((byte1 & 0xF0) == 0xE0) { + byte2 = readContinuationByte(); + byte3 = readContinuationByte(); + codePoint = ((byte1 & 0x0F) << 12) | (byte2 << 6) | byte3; + if (codePoint >= 0x0800) { + return checkScalarValue(codePoint, strict) ? codePoint : 0xFFFD; + } else { + throw Error('Invalid continuation byte'); + } + } + + // 4-byte sequence + if ((byte1 & 0xF8) == 0xF0) { + byte2 = readContinuationByte(); + byte3 = readContinuationByte(); + byte4 = readContinuationByte(); + codePoint = ((byte1 & 0x07) << 0x12) | (byte2 << 0x0C) | + (byte3 << 0x06) | byte4; + if (codePoint >= 0x010000 && codePoint <= 0x10FFFF) { + return codePoint; + } + } + + throw Error('Invalid UTF-8 detected'); +} + +var byteArray; +var byteCount; +var byteIndex; +function utf8decode(byteString, opts) { + opts = opts || {}; + var strict = false !== opts.strict; + + byteArray = ucs2decode(byteString); + byteCount = byteArray.length; + byteIndex = 0; + var codePoints = []; + var tmp; + while ((tmp = decodeSymbol(strict)) !== false) { + codePoints.push(tmp); + } + return ucs2encode(codePoints); +} + +module.exports = { + version: '2.1.2', + encode: utf8encode, + decode: utf8decode +}; + + +/***/ }), +/* 126 */ +/***/ (function(module, exports) { + +/* + * base64-arraybuffer + * https://github.com/niklasvh/base64-arraybuffer + * + * Copyright (c) 2012 Niklas von Hertzen + * Licensed under the MIT license. + */ +(function(){ + "use strict"; + + var chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"; + + // Use a lookup table to find the index. + var lookup = new Uint8Array(256); + for (var i = 0; i < chars.length; i++) { + lookup[chars.charCodeAt(i)] = i; + } + + exports.encode = function(arraybuffer) { + var bytes = new Uint8Array(arraybuffer), + i, len = bytes.length, base64 = ""; + + for (i = 0; i < len; i+=3) { + base64 += chars[bytes[i] >> 2]; + base64 += chars[((bytes[i] & 3) << 4) | (bytes[i + 1] >> 4)]; + base64 += chars[((bytes[i + 1] & 15) << 2) | (bytes[i + 2] >> 6)]; + base64 += chars[bytes[i + 2] & 63]; + } + + if ((len % 3) === 2) { + base64 = base64.substring(0, base64.length - 1) + "="; + } else if (len % 3 === 1) { + base64 = base64.substring(0, base64.length - 2) + "=="; + } + + return base64; + }; + + exports.decode = function(base64) { + var bufferLength = base64.length * 0.75, + len = base64.length, i, p = 0, + encoded1, encoded2, encoded3, encoded4; + + if (base64[base64.length - 1] === "=") { + bufferLength--; + if (base64[base64.length - 2] === "=") { + bufferLength--; + } + } + + var arraybuffer = new ArrayBuffer(bufferLength), + bytes = new Uint8Array(arraybuffer); + + for (i = 0; i < len; i+=4) { + encoded1 = lookup[base64.charCodeAt(i)]; + encoded2 = lookup[base64.charCodeAt(i+1)]; + encoded3 = lookup[base64.charCodeAt(i+2)]; + encoded4 = lookup[base64.charCodeAt(i+3)]; + + bytes[p++] = (encoded1 << 2) | (encoded2 >> 4); + bytes[p++] = ((encoded2 & 15) << 4) | (encoded3 >> 2); + bytes[p++] = ((encoded3 & 3) << 6) | (encoded4 & 63); + } + + return arraybuffer; + }; +})(); + + +/***/ }), +/* 127 */ +/***/ (function(module, exports) { + +/** + * Create a blob builder even when vendor prefixes exist + */ + +var BlobBuilder = typeof BlobBuilder !== 'undefined' ? BlobBuilder : + typeof WebKitBlobBuilder !== 'undefined' ? WebKitBlobBuilder : + typeof MSBlobBuilder !== 'undefined' ? MSBlobBuilder : + typeof MozBlobBuilder !== 'undefined' ? MozBlobBuilder : + false; + +/** + * Check if Blob constructor is supported + */ + +var blobSupported = (function() { + try { + var a = new Blob(['hi']); + return a.size === 2; + } catch(e) { + return false; + } +})(); + +/** + * Check if Blob constructor supports ArrayBufferViews + * Fails in Safari 6, so we need to map to ArrayBuffers there. + */ + +var blobSupportsArrayBufferView = blobSupported && (function() { + try { + var b = new Blob([new Uint8Array([1,2])]); + return b.size === 2; + } catch(e) { + return false; + } +})(); + +/** + * Check if BlobBuilder is supported + */ + +var blobBuilderSupported = BlobBuilder + && BlobBuilder.prototype.append + && BlobBuilder.prototype.getBlob; + +/** + * Helper function that maps ArrayBufferViews to ArrayBuffers + * Used by BlobBuilder constructor and old browsers that didn't + * support it in the Blob constructor. + */ + +function mapArrayBufferViews(ary) { + return ary.map(function(chunk) { + if (chunk.buffer instanceof ArrayBuffer) { + var buf = chunk.buffer; + + // if this is a subarray, make a copy so we only + // include the subarray region from the underlying buffer + if (chunk.byteLength !== buf.byteLength) { + var copy = new Uint8Array(chunk.byteLength); + copy.set(new Uint8Array(buf, chunk.byteOffset, chunk.byteLength)); + buf = copy.buffer; + } + + return buf; + } + + return chunk; + }); +} + +function BlobBuilderConstructor(ary, options) { + options = options || {}; + + var bb = new BlobBuilder(); + mapArrayBufferViews(ary).forEach(function(part) { + bb.append(part); + }); + + return (options.type) ? bb.getBlob(options.type) : bb.getBlob(); +}; + +function BlobConstructor(ary, options) { + return new Blob(mapArrayBufferViews(ary), options || {}); +}; + +if (typeof Blob !== 'undefined') { + BlobBuilderConstructor.prototype = Blob.prototype; + BlobConstructor.prototype = Blob.prototype; +} + +module.exports = (function() { + if (blobSupported) { + return blobSupportsArrayBufferView ? Blob : BlobConstructor; + } else if (blobBuilderSupported) { + return BlobBuilderConstructor; + } else { + return undefined; + } +})(); + + +/***/ }), +/* 128 */ +/***/ (function(module, exports, __webpack_require__) { + + +/** + * This is the common logic for both the Node.js and web browser + * implementations of `debug()`. + * + * Expose `debug()` as the module. + */ + +exports = module.exports = createDebug.debug = createDebug['default'] = createDebug; +exports.coerce = coerce; +exports.disable = disable; +exports.enable = enable; +exports.enabled = enabled; +exports.humanize = __webpack_require__(47); + +/** + * Active `debug` instances. + */ +exports.instances = []; + +/** + * The currently active debug mode names, and names to skip. + */ + +exports.names = []; +exports.skips = []; + +/** + * Map of special "%n" handling functions, for the debug "format" argument. + * + * Valid key names are a single, lower or upper-case letter, i.e. "n" and "N". + */ + +exports.formatters = {}; + +/** + * Select a color. + * @param {String} namespace + * @return {Number} + * @api private + */ + +function selectColor(namespace) { + var hash = 0, i; + + for (i in namespace) { + hash = ((hash << 5) - hash) + namespace.charCodeAt(i); + hash |= 0; // Convert to 32bit integer + } + + return exports.colors[Math.abs(hash) % exports.colors.length]; +} + +/** + * Create a debugger with the given `namespace`. + * + * @param {String} namespace + * @return {Function} + * @api public + */ + +function createDebug(namespace) { + + var prevTime; + + function debug() { + // disabled? + if (!debug.enabled) return; + + var self = debug; + + // set `diff` timestamp + var curr = +new Date(); + var ms = curr - (prevTime || curr); + self.diff = ms; + self.prev = prevTime; + self.curr = curr; + prevTime = curr; + + // turn the `arguments` into a proper Array + var args = new Array(arguments.length); + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i]; + } + + args[0] = exports.coerce(args[0]); + + if ('string' !== typeof args[0]) { + // anything else let's inspect with %O + args.unshift('%O'); + } + + // apply any `formatters` transformations + var index = 0; + args[0] = args[0].replace(/%([a-zA-Z%])/g, function(match, format) { + // if we encounter an escaped % then don't increase the array index + if (match === '%%') return match; + index++; + var formatter = exports.formatters[format]; + if ('function' === typeof formatter) { + var val = args[index]; + match = formatter.call(self, val); + + // now we need to remove `args[index]` since it's inlined in the `format` + args.splice(index, 1); + index--; + } + return match; + }); + + // apply env-specific formatting (colors, etc.) + exports.formatArgs.call(self, args); + + var logFn = debug.log || exports.log || console.log.bind(console); + logFn.apply(self, args); + } + + debug.namespace = namespace; + debug.enabled = exports.enabled(namespace); + debug.useColors = exports.useColors(); + debug.color = selectColor(namespace); + debug.destroy = destroy; + + // env-specific initialization logic for debug instances + if ('function' === typeof exports.init) { + exports.init(debug); + } + + exports.instances.push(debug); + + return debug; +} + +function destroy () { + var index = exports.instances.indexOf(this); + if (index !== -1) { + exports.instances.splice(index, 1); + return true; + } else { + return false; + } +} + +/** + * Enables a debug mode by namespaces. This can include modes + * separated by a colon and wildcards. + * + * @param {String} namespaces + * @api public + */ + +function enable(namespaces) { + exports.save(namespaces); + + exports.names = []; + exports.skips = []; + + var i; + var split = (typeof namespaces === 'string' ? namespaces : '').split(/[\s,]+/); + var len = split.length; + + for (i = 0; i < len; i++) { + if (!split[i]) continue; // ignore empty strings + namespaces = split[i].replace(/\*/g, '.*?'); + if (namespaces[0] === '-') { + exports.skips.push(new RegExp('^' + namespaces.substr(1) + '$')); + } else { + exports.names.push(new RegExp('^' + namespaces + '$')); + } + } + + for (i = 0; i < exports.instances.length; i++) { + var instance = exports.instances[i]; + instance.enabled = exports.enabled(instance.namespace); + } +} + +/** + * Disable debug output. + * + * @api public + */ + +function disable() { + exports.enable(''); +} + +/** + * Returns true if the given mode name is enabled, false otherwise. + * + * @param {String} name + * @return {Boolean} + * @api public + */ + +function enabled(name) { + if (name[name.length - 1] === '*') { + return true; + } + var i, len; + for (i = 0, len = exports.skips.length; i < len; i++) { + if (exports.skips[i].test(name)) { + return false; + } + } + for (i = 0, len = exports.names.length; i < len; i++) { + if (exports.names[i].test(name)) { + return true; + } + } + return false; +} + +/** + * Coerce `val`. + * + * @param {Mixed} val + * @return {Mixed} + * @api private + */ + +function coerce(val) { + if (val instanceof Error) return val.stack || val.message; + return val; +} + + +/***/ }), +/* 129 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(global) {/** + * Module requirements. + */ + +var Polling = __webpack_require__(66); +var inherit = __webpack_require__(35); + +/** + * Module exports. + */ + +module.exports = JSONPPolling; + +/** + * Cached regular expressions. + */ + +var rNewline = /\n/g; +var rEscapedNewline = /\\n/g; + +/** + * Global JSONP callbacks. + */ + +var callbacks; + +/** + * Noop. + */ + +function empty () { } + +/** + * Until https://github.com/tc39/proposal-global is shipped. + */ +function glob () { + return typeof self !== 'undefined' ? self + : typeof window !== 'undefined' ? window + : typeof global !== 'undefined' ? global : {}; +} + +/** + * JSONP Polling constructor. + * + * @param {Object} opts. + * @api public + */ + +function JSONPPolling (opts) { + Polling.call(this, opts); + + this.query = this.query || {}; + + // define global callbacks array if not present + // we do this here (lazily) to avoid unneeded global pollution + if (!callbacks) { + // we need to consider multiple engines in the same page + var global = glob(); + callbacks = global.___eio = (global.___eio || []); + } + + // callback identifier + this.index = callbacks.length; + + // add callback to jsonp global + var self = this; + callbacks.push(function (msg) { + self.onData(msg); + }); + + // append to query string + this.query.j = this.index; + + // prevent spurious errors from being emitted when the window is unloaded + if (typeof addEventListener === 'function') { + addEventListener('beforeunload', function () { + if (self.script) self.script.onerror = empty; + }, false); + } +} + +/** + * Inherits from Polling. + */ + +inherit(JSONPPolling, Polling); + +/* + * JSONP only supports binary as base64 encoded strings + */ + +JSONPPolling.prototype.supportsBinary = false; + +/** + * Closes the socket. + * + * @api private + */ + +JSONPPolling.prototype.doClose = function () { + if (this.script) { + this.script.parentNode.removeChild(this.script); + this.script = null; + } + + if (this.form) { + this.form.parentNode.removeChild(this.form); + this.form = null; + this.iframe = null; + } + + Polling.prototype.doClose.call(this); +}; + +/** + * Starts a poll cycle. + * + * @api private + */ + +JSONPPolling.prototype.doPoll = function () { + var self = this; + var script = document.createElement('script'); + + if (this.script) { + this.script.parentNode.removeChild(this.script); + this.script = null; + } + + script.async = true; + script.src = this.uri(); + script.onerror = function (e) { + self.onError('jsonp poll error', e); + }; + + var insertAt = document.getElementsByTagName('script')[0]; + if (insertAt) { + insertAt.parentNode.insertBefore(script, insertAt); + } else { + (document.head || document.body).appendChild(script); + } + this.script = script; + + var isUAgecko = 'undefined' !== typeof navigator && /gecko/i.test(navigator.userAgent); + + if (isUAgecko) { + setTimeout(function () { + var iframe = document.createElement('iframe'); + document.body.appendChild(iframe); + document.body.removeChild(iframe); + }, 100); + } +}; + +/** + * Writes with a hidden iframe. + * + * @param {String} data to send + * @param {Function} called upon flush. + * @api private + */ + +JSONPPolling.prototype.doWrite = function (data, fn) { + var self = this; + + if (!this.form) { + var form = document.createElement('form'); + var area = document.createElement('textarea'); + var id = this.iframeId = 'eio_iframe_' + this.index; + var iframe; + + form.className = 'socketio'; + form.style.position = 'absolute'; + form.style.top = '-1000px'; + form.style.left = '-1000px'; + form.target = id; + form.method = 'POST'; + form.setAttribute('accept-charset', 'utf-8'); + area.name = 'd'; + form.appendChild(area); + document.body.appendChild(form); + + this.form = form; + this.area = area; + } + + this.form.action = this.uri(); + + function complete () { + initIframe(); + fn(); + } + + function initIframe () { + if (self.iframe) { + try { + self.form.removeChild(self.iframe); + } catch (e) { + self.onError('jsonp polling iframe removal error', e); + } + } + + try { + // ie6 dynamic iframes with target="" support (thanks Chris Lambacher) + var html = ''),a.close(),s=a.w.frames[0].document,t=s.createElement("div")}catch(e){t=i.createElement("div"),s=i.body}var u=function(n){return function(){var r=Array.prototype.slice.call(arguments,0);r.unshift(t),s.appendChild(t),t.addBehavior("#default#userData"),t.load(o);var i=n.apply(e,r);return s.removeChild(t),i}},c=new RegExp("[!\"#$%&'()*+,/\\\\:;<=>?@[\\]^`{|}~]","g"),l=function(t){return t.replace(/^d/,"___$&").replace(c,"___")};e.set=u(function(t,n,r){return n=l(n),void 0===r?e.remove(n):(t.setAttribute(n,e.serialize(r)),t.save(o),r)}),e.get=u(function(t,n,r){n=l(n);var i=e.deserialize(t.getAttribute(n));return void 0===i?r:i}),e.remove=u(function(t,e){e=l(e),t.removeAttribute(e),t.save(o)}),e.clear=u(function(t){var e=t.XMLDocument.documentElement.attributes;t.load(o);for(var n=e.length-1;n>=0;n--)t.removeAttribute(e[n].name);t.save(o)}),e.getAll=function(t){var n={};return e.forEach(function(t,e){n[t]=e}),n},e.forEach=u(function(t,n){for(var r,i=t.XMLDocument.documentElement.attributes,o=0;r=i[o];++o)n(r.name,e.deserialize(t.getAttribute(r.name)))})}try{var f="__storejs__";e.set(f,f),e.get(f)!=f&&(e.disabled=!0),e.remove(f)}catch(t){e.disabled=!0}return e.enabled=!e.disabled,e})}).call(e,n(0))},function(t,e,n){var r,i,o;!function(n,s){"use strict";"object"==typeof t&&"object"==typeof t.exports?t.exports=s():(i=[],r=s,void 0!==(o="function"==typeof r?r.apply(e,i):r)&&(t.exports=o))}(0,function(){"use strict";function t(t){if(!t)return!0;if(o(t)&&0===t.length)return!0;if(!r(t)){for(var e in t)if(f.call(t,e))return!1;return!0}return!1}function e(t){return l.call(t)}function n(t){return"number"==typeof t||"[object Number]"===e(t)}function r(t){return"string"==typeof t||"[object String]"===e(t)}function i(t){return"object"==typeof t&&"[object Object]"===e(t)}function o(t){return"object"==typeof t&&"number"==typeof t.length&&"[object Array]"===e(t)}function s(t){return"boolean"==typeof t||"[object Boolean]"===e(t)}function a(t){var e=parseInt(t);return e.toString()===t?e:t}function u(e,i,o,s){if(n(i)&&(i=[i]),t(i))return e;if(r(i))return u(e,i.split(".").map(a),o,s);var c=i[0];if(1===i.length){var l=e[c];return void 0!==l&&s||(e[c]=o),l}return void 0===e[c]&&(n(i[1])?e[c]=[]:e[c]={}),u(e[c],i.slice(1),o,s)}function c(e,i){if(n(i)&&(i=[i]),!t(e)){if(t(i))return e;if(r(i))return c(e,i.split("."));var s=a(i[0]),u=e[s];if(1===i.length)void 0!==u&&(o(e)?e.splice(s,1):delete e[s]);else if(void 0!==e[s])return c(e[s],i.slice(1));return e}}var l=Object.prototype.toString,f=Object.prototype.hasOwnProperty,h=function(t){return Object.keys(h).reduce(function(e,n){return"function"==typeof h[n]&&(e[n]=h[n].bind(h,t)),e},{})};return h.has=function(e,s){if(t(e))return!1;if(n(s)?s=[s]:r(s)&&(s=s.split(".")),t(s)||0===s.length)return!1;for(var a=0;an[e]?1:-1}),n&&r.reverse(),r}}},function(t,e,n){var t=n(5);t.directive("icon",n(73)),t.directive("linkTo",n(74)),t.directive("switch",n(75)),t.directive("newTab",n(76))},function(t,e){t.exports=function(){return{scope:{icon:"@"},restrict:"E",replace:!0,template:'',link:function(t,e,n){return t.iconName="#svg-"+t.icon,t}}}},function(t,e){t.exports=function(){return{restrict:"E",replace:!1,transclude:!0,scope:{path:"@"},template:"as",controller:["$scope","$location","$injector",function(t,e,n){var r=n.get("pagesConfig"),i=n.get("Pages");t.navi=function(t){var n=r[t];i.enable(n),e.path(t)}}]}}},function(t,e){t.exports=function(){return{scope:{toggle:"&",item:"=",switchid:"@",title:"@",tagline:"@",active:"=",prop:"@"},restrict:"E",replace:!0,transclude:!0,templateUrl:"bs-switch.html",controllerAs:"ctrl",controller:["$scope",function(t){this.item=t.item}]}}},function(t,e){t.exports=function(){return{scope:{url:"@",mode:"@"},restrict:"E",replace:!0,template:' New Tab '}}}]); \ No newline at end of file diff --git a/node_modules/browser-sync-ui/public/js/app.js.map b/node_modules/browser-sync-ui/public/js/app.js.map new file mode 100644 index 0000000000..fe778cf1aa --- /dev/null +++ b/node_modules/browser-sync-ui/public/js/app.js.map @@ -0,0 +1 @@ +{"version":3,"sources":["webpack:///js/app.js","webpack:///webpack/bootstrap dbdfcc42c882e3972c4b","webpack:///./app.js","webpack:////Users/shakyshane/Sites/oss/UI/~/angular/index.js","webpack:////Users/shakyshane/Sites/oss/UI/~/angular/angular.js","webpack:////Users/shakyshane/Sites/oss/UI/~/angular-route/index.js","webpack:////Users/shakyshane/Sites/oss/UI/~/angular-route/angular-route.js","webpack:////Users/shakyshane/Sites/oss/UI/~/angular-sanitize/index.js","webpack:////Users/shakyshane/Sites/oss/UI/~/angular-sanitize/angular-sanitize.js","webpack:////Users/shakyshane/Sites/oss/UI/~/angular-touch/index.js","webpack:////Users/shakyshane/Sites/oss/UI/~/angular-touch/angular-touch.js","webpack:///./modules/bsDisconnect.js","webpack:///./angular.js","webpack:///./modules/bsNotify.js","webpack:///./modules/bsHistory.js","webpack:///./modules/bsClients.js","webpack:///./modules/bsSocket.js","webpack:////Users/shakyshane/Sites/oss/UI/~/socket.io-client/lib/index.js","webpack:////Users/shakyshane/Sites/oss/UI/~/socket.io-client/lib/url.js","webpack:////Users/shakyshane/Sites/oss/UI/~/socket.io-client/~/parseuri/index.js","webpack:////Users/shakyshane/Sites/oss/UI/~/socket.io-client/~/debug/src/browser.js","webpack:////Users/shakyshane/Sites/oss/UI/~/process/browser.js","webpack:////Users/shakyshane/Sites/oss/UI/~/socket.io-client/~/debug/src/debug.js","webpack:////Users/shakyshane/Sites/oss/UI/~/socket.io-client/~/ms/index.js","webpack:////Users/shakyshane/Sites/oss/UI/~/socket.io-client/~/socket.io-parser/index.js","webpack:////Users/shakyshane/Sites/oss/UI/~/component-emitter/index.js","webpack:////Users/shakyshane/Sites/oss/UI/~/has-binary2/index.js","webpack:////Users/shakyshane/Sites/oss/UI/~/has-binary2/~/isarray/index.js","webpack:////Users/shakyshane/Sites/oss/UI/~/socket.io-client/~/socket.io-parser/binary.js","webpack:////Users/shakyshane/Sites/oss/UI/~/socket.io-client/~/isarray/index.js","webpack:////Users/shakyshane/Sites/oss/UI/~/socket.io-client/~/socket.io-parser/is-buffer.js","webpack:////Users/shakyshane/Sites/oss/UI/~/socket.io-client/lib/manager.js","webpack:////Users/shakyshane/Sites/oss/UI/~/engine.io-client/lib/index.js","webpack:////Users/shakyshane/Sites/oss/UI/~/engine.io-client/lib/socket.js","webpack:////Users/shakyshane/Sites/oss/UI/~/engine.io-client/lib/transports/index.js","webpack:////Users/shakyshane/Sites/oss/UI/~/engine.io-client/lib/xmlhttprequest.js","webpack:////Users/shakyshane/Sites/oss/UI/~/has-cors/index.js","webpack:////Users/shakyshane/Sites/oss/UI/~/engine.io-client/lib/transports/polling-xhr.js","webpack:////Users/shakyshane/Sites/oss/UI/~/engine.io-client/lib/transports/polling.js","webpack:////Users/shakyshane/Sites/oss/UI/~/engine.io-client/lib/transport.js","webpack:////Users/shakyshane/Sites/oss/UI/~/engine.io-client/~/engine.io-parser/lib/browser.js","webpack:////Users/shakyshane/Sites/oss/UI/~/engine.io-client/~/engine.io-parser/lib/keys.js","webpack:////Users/shakyshane/Sites/oss/UI/~/arraybuffer.slice/index.js","webpack:////Users/shakyshane/Sites/oss/UI/~/engine.io-client/~/after/index.js","webpack:////Users/shakyshane/Sites/oss/UI/~/engine.io-client/~/engine.io-parser/lib/utf8.js","webpack:///(webpack)/buildin/module.js","webpack:////Users/shakyshane/Sites/oss/UI/~/base64-arraybuffer/lib/base64-arraybuffer.js","webpack:////Users/shakyshane/Sites/oss/UI/~/blob/index.js","webpack:////Users/shakyshane/Sites/oss/UI/~/parseqs/index.js","webpack:////Users/shakyshane/Sites/oss/UI/~/component-inherit/index.js","webpack:////Users/shakyshane/Sites/oss/UI/~/yeast/index.js","webpack:////Users/shakyshane/Sites/oss/UI/~/engine.io-client/~/debug/src/browser.js","webpack:////Users/shakyshane/Sites/oss/UI/~/engine.io-client/~/debug/src/debug.js","webpack:////Users/shakyshane/Sites/oss/UI/~/engine.io-client/~/ms/index.js","webpack:////Users/shakyshane/Sites/oss/UI/~/engine.io-client/lib/transports/polling-jsonp.js","webpack:////Users/shakyshane/Sites/oss/UI/~/engine.io-client/lib/transports/websocket.js","webpack:////Users/shakyshane/Sites/oss/UI/~/indexof/index.js","webpack:////Users/shakyshane/Sites/oss/UI/~/engine.io-client/~/parseuri/index.js","webpack:////Users/shakyshane/Sites/oss/UI/~/socket.io-client/lib/socket.js","webpack:////Users/shakyshane/Sites/oss/UI/~/to-array/index.js","webpack:////Users/shakyshane/Sites/oss/UI/~/socket.io-client/lib/on.js","webpack:////Users/shakyshane/Sites/oss/UI/~/component-bind/index.js","webpack:////Users/shakyshane/Sites/oss/UI/~/backo2/index.js","webpack:///./services/Pages.js","webpack:///./module.js","webpack:///./services/Options.js","webpack:///./modules/bsStore.js","webpack:////Users/shakyshane/Sites/oss/UI/~/store/store.js","webpack:////Users/shakyshane/Sites/oss/UI/~/object-path/index.js","webpack:///./main/controller.js","webpack:///./filters.js","webpack:///./utils.js","webpack:///./directives.js","webpack:///./directives/icon.js","webpack:///./directives/link-to.js","webpack:///./directives/switch.js","webpack:///./directives/new-tab.js"],"names":["modules","__webpack_require__","moduleId","installedModules","exports","module","id","loaded","call","m","c","p","Config","$locationProvider","html5Mode","enabled","requireBase","angular","window","config","document","undefined","minErr","ErrorConstructor","Error","paramPrefix","i","SKIP_INDEXES","templateArgs","arguments","code","message","template","replace","match","index","slice","shiftedIndex","length","toDebugString","encodeURIComponent","isArrayLike","obj","isWindow","isArray","isString","jqLite","Object","isNumber","Array","item","forEach","iterator","context","key","isFunction","hasOwnProperty","isPrimitive","isBlankObject","forEachSorted","keys","sort","reverseParams","iteratorFn","value","nextUid","uid","setHashKey","h","$$hashKey","baseExtend","dst","objs","deep","ii","isObject","j","jj","src","isDate","Date","valueOf","isRegExp","RegExp","nodeName","cloneNode","isElement","clone","extend","merge","toInt","str","parseInt","inherit","parent","extra","create","noop","identity","$","valueFn","hasCustomToString","toString","isUndefined","isDefined","getPrototypeOf","isScope","$evalAsync","$watch","isFile","isFormData","isBlob","isBoolean","isPromiseLike","then","isTypedArray","TYPED_ARRAY_REGEXP","test","node","prop","attr","find","makeMap","items","split","nodeName_","element","lowercase","arrayRemove","array","indexOf","splice","copy","source","destination","copyRecurse","push","copyElement","stackSource","stackDest","ngMinErr","needsRecurse","constructor","getTime","lastIndex","type","shallowCopy","charAt","equals","o1","o2","keySet","t1","t2","createMap","concat","array1","array2","sliceArgs","args","startIndex","bind","self","fn","curryArgs","apply","toJsonReplacer","val","toJson","pretty","JSON","stringify","fromJson","json","parse","timezoneToOffset","timezone","fallback","ALL_COLONS","requestedTimezoneOffset","isNaN","addDateMinutes","date","minutes","setMinutes","getMinutes","convertTimezoneToLocal","reverse","dateTimezoneOffset","getTimezoneOffset","timezoneOffset","startingTag","empty","e","elemHtml","append","html","nodeType","NODE_TYPE_TEXT","tryDecodeURIComponent","decodeURIComponent","parseKeyValue","keyValue","splitPoint","substring","toKeyValue","parts","arrayValue","encodeUriQuery","join","encodeUriSegment","pctEncodeSpaces","getNgAttribute","ngAttr","ngAttrPrefixes","getAttribute","angularInit","bootstrap","appElement","prefix","name","hasAttribute","candidate","querySelector","strictDi","defaultConfig","doBootstrap","injector","tag","unshift","$provide","debugInfoEnabled","$compileProvider","createInjector","invoke","scope","compile","$apply","data","NG_ENABLE_DEBUG_INFO","NG_DEFER_BOOTSTRAP","resumeBootstrap","extraModules","resumeDeferredBootstrap","reloadWithDebugInfo","location","reload","getTestability","rootElement","get","snake_case","separator","SNAKE_CASE_REGEXP","letter","pos","toLowerCase","bindJQuery","originalCleanData","bindJQueryFired","jqName","jq","jQuery","on","JQLitePrototype","isolateScope","controller","inheritedData","cleanData","elems","events","skipDestroyOnNextJQueryCleanData","elem","_data","$destroy","triggerHandler","JQLite","assertArg","arg","reason","assertArgFn","acceptArrayAnnotation","assertNotHasOwnProperty","getter","path","bindFnToScope","lastInstance","len","getBlockNodes","nodes","blockNodes","endNode","nextSibling","setupModuleLoader","ensure","factory","$injectorMinErr","$$minErr","requires","configFn","invokeLater","provider","method","insertMethod","queue","invokeQueue","moduleInstance","invokeLaterAndSetModuleName","recipeName","factoryFunction","$$moduleName","configBlocks","runBlocks","_invokeQueue","_configBlocks","_runBlocks","service","constant","decorator","animation","filter","directive","run","block","this","serializeObject","seen","publishExternalAPI","version","uppercase","callbacks","counter","$$csp","csp","angularModule","$$sanitizeUri","$$SanitizeUriProvider","$CompileProvider","a","htmlAnchorDirective","input","inputDirective","textarea","form","formDirective","script","scriptDirective","select","selectDirective","style","styleDirective","option","optionDirective","ngBind","ngBindDirective","ngBindHtml","ngBindHtmlDirective","ngBindTemplate","ngBindTemplateDirective","ngClass","ngClassDirective","ngClassEven","ngClassEvenDirective","ngClassOdd","ngClassOddDirective","ngCloak","ngCloakDirective","ngController","ngControllerDirective","ngForm","ngFormDirective","ngHide","ngHideDirective","ngIf","ngIfDirective","ngInclude","ngIncludeDirective","ngInit","ngInitDirective","ngNonBindable","ngNonBindableDirective","ngPluralize","ngPluralizeDirective","ngRepeat","ngRepeatDirective","ngShow","ngShowDirective","ngStyle","ngStyleDirective","ngSwitch","ngSwitchDirective","ngSwitchWhen","ngSwitchWhenDirective","ngSwitchDefault","ngSwitchDefaultDirective","ngOptions","ngOptionsDirective","ngTransclude","ngTranscludeDirective","ngModel","ngModelDirective","ngList","ngListDirective","ngChange","ngChangeDirective","pattern","patternDirective","ngPattern","required","requiredDirective","ngRequired","minlength","minlengthDirective","ngMinlength","maxlength","maxlengthDirective","ngMaxlength","ngValue","ngValueDirective","ngModelOptions","ngModelOptionsDirective","ngIncludeFillContentDirective","ngAttributeAliasDirectives","ngEventDirectives","$anchorScroll","$AnchorScrollProvider","$animate","$AnimateProvider","$animateCss","$CoreAnimateCssProvider","$$animateJs","$$CoreAnimateJsProvider","$$animateQueue","$$CoreAnimateQueueProvider","$$AnimateRunner","$$AnimateRunnerFactoryProvider","$$animateAsyncRun","$$AnimateAsyncRunFactoryProvider","$browser","$BrowserProvider","$cacheFactory","$CacheFactoryProvider","$controller","$ControllerProvider","$document","$DocumentProvider","$exceptionHandler","$ExceptionHandlerProvider","$filter","$FilterProvider","$$forceReflow","$$ForceReflowProvider","$interpolate","$InterpolateProvider","$interval","$IntervalProvider","$http","$HttpProvider","$httpParamSerializer","$HttpParamSerializerProvider","$httpParamSerializerJQLike","$HttpParamSerializerJQLikeProvider","$httpBackend","$HttpBackendProvider","$xhrFactory","$xhrFactoryProvider","$location","$LocationProvider","$log","$LogProvider","$parse","$ParseProvider","$rootScope","$RootScopeProvider","$q","$QProvider","$$q","$$QProvider","$sce","$SceProvider","$sceDelegate","$SceDelegateProvider","$sniffer","$SnifferProvider","$templateCache","$TemplateCacheProvider","$templateRequest","$TemplateRequestProvider","$$testability","$$TestabilityProvider","$timeout","$TimeoutProvider","$window","$WindowProvider","$$rAF","$$RAFProvider","$$jqLite","$$jqLiteProvider","$$HashMap","$$HashMapProvider","$$cookieReader","$$CookieReaderProvider","jqNextId","jqId","camelCase","SPECIAL_CHARS_REGEXP","_","offset","toUpperCase","MOZ_HACK_REGEXP","jqLiteIsTextNode","HTML_REGEXP","jqLiteAcceptsData","NODE_TYPE_ELEMENT","NODE_TYPE_DOCUMENT","jqLiteHasData","jqCache","ng339","jqLiteBuildFragment","tmp","wrap","fragment","createDocumentFragment","createTextNode","appendChild","createElement","TAG_NAME_REGEXP","exec","wrapMap","_default","innerHTML","XHTML_TAG_REGEXP","lastChild","childNodes","firstChild","textContent","jqLiteParseHTML","parsed","SINGLE_TAG_REGEXP","jqLiteWrapNode","wrapper","parentNode","replaceChild","argIsString","trim","jqLiteMinErr","jqLiteAddNodes","jqLiteClone","jqLiteDealoc","onlyDescendants","jqLiteRemoveData","querySelectorAll","descendants","l","jqLiteOff","unsupported","expandoStore","jqLiteExpandoStore","handle","removeHandler","listenerFns","removeEventListenerFn","MOUSE_EVENT_MAP","expandoId","createIfNecessary","jqLiteData","isSimpleSetter","isSimpleGetter","massGetter","jqLiteHasClass","selector","jqLiteRemoveClass","cssClasses","setAttribute","cssClass","jqLiteAddClass","existingClasses","root","elements","jqLiteController","jqLiteInheritedData","documentElement","names","NODE_TYPE_DOCUMENT_FRAGMENT","host","jqLiteEmpty","removeChild","jqLiteRemove","keepData","jqLiteDocumentLoaded","action","win","readyState","setTimeout","getBooleanAttrName","booleanAttr","BOOLEAN_ATTR","BOOLEAN_ELEMENTS","getAliasedAttrName","ALIASED_ATTR","createEventHandler","eventHandler","event","isDefaultPrevented","defaultPrevented","eventFns","eventFnsLength","immediatePropagationStopped","originalStopImmediatePropagation","stopImmediatePropagation","stopPropagation","isImmediatePropagationStopped","handlerWrapper","specialHandlerWrapper","defaultHandlerWrapper","handler","specialMouseHandlerWrapper","target","related","relatedTarget","jqLiteContains","$get","hasClass","classes","addClass","removeClass","hashKey","nextUidFn","objType","HashMap","isolatedUid","put","anonFn","fnText","STRIP_COMMENTS","FN_ARGS","annotate","$inject","argDecl","last","FN_ARG_SPLIT","FN_ARG","all","underscore","modulesToLoad","supportObject","delegate","provider_","providerInjector","instantiate","providerCache","providerSuffix","enforceReturnValue","result","instanceInjector","factoryFn","enforce","$injector","instanceCache","serviceName","decorFn","origProvider","orig$get","origInstance","$delegate","loadModules","moduleFn","runInvokeQueue","invokeArgs","loadedModules","stack","createInternalInjector","cache","getService","caller","INSTANTIATING","err","shift","locals","$$annotate","Type","instance","prototype","returnedValue","has","autoScrollingEnabled","disableAutoScrolling","getFirstAnchor","list","some","getYOffset","scroll","yOffset","getComputedStyle","position","getBoundingClientRect","bottom","scrollTo","scrollIntoView","elemTop","top","scrollBy","hash","elm","getElementById","getElementsByName","newVal","oldVal","mergeClasses","b","extractElementNode","ELEMENT_NODE","splitClasses","klass","prepareAnimateOptions","options","Browser","completeOutstandingRequest","outstandingRequestCount","outstandingRequestCallbacks","pop","error","getHash","url","substr","cacheStateAndFireUrlChange","pendingLocation","cacheState","fireUrlChange","getCurrentState","history","state","cachedState","lastCachedState","lastBrowserUrl","lastHistoryState","urlChangeListeners","listener","clearTimeout","pendingDeferIds","isMock","$$completeOutstandingRequest","$$incOutstandingRequestCount","notifyWhenNoOutstandingRequests","callback","href","baseElement","sameState","sameBase","stripHash","urlChangeInit","onUrlChange","$$applicationDestroyed","off","$$checkUrlChange","baseHref","defer","delay","timeoutId","cancel","deferId","cacheFactory","cacheId","refresh","entry","freshEnd","staleEnd","n","link","nextEntry","prevEntry","caches","size","stats","capacity","Number","MAX_VALUE","lruHash","lruEntry","remove","removeAll","destroy","info","$$sanitizeUriProvider","parseIsolateBindings","directiveName","isController","LOCAL_REGEXP","bindings","definition","scopeName","bindingCache","$compileMinErr","mode","collection","optional","attrName","parseDirectiveBindings","bindToController","controllerAs","identifierForController","assertValidDirectiveName","hasDirectives","Suffix","COMMENT_DIRECTIVE_REGEXP","CLASS_DIRECTIVE_REGEXP","ALL_OR_NOTHING_ATTRS","REQUIRE_PREFIX_REGEXP","EVENT_HANDLER_ATTR_REGEXP","registerDirective","directiveFactory","directives","priority","require","restrict","aHrefSanitizationWhitelist","regexp","imgSrcSanitizationWhitelist","safeAddClass","$element","className","$compileNodes","transcludeFn","maxPriority","ignoreDirective","previousCompileContext","NOT_EMPTY","domNode","nodeValue","compositeLinkFn","compileNodes","$$addScopeClass","namespace","cloneConnectFn","needsNewScope","$parent","$new","parentBoundTranscludeFn","transcludeControllers","futureParentElement","$$boundTransclude","detectNamespaceForChildElements","$linkNode","wrapTemplate","controllerName","$$addScopeInfo","parentElement","nodeList","$rootElement","nodeLinkFn","childLinkFn","childScope","idx","childBoundTranscludeFn","stableNodeList","nodeLinkFnFound","nodeListLength","linkFns","transcludeOnThisElement","createBoundTranscludeFn","transclude","templateOnThisElement","attrs","linkFnFound","Attributes","collectDirectives","applyDirectivesToNode","$$element","terminal","previousBoundTranscludeFn","boundTranscludeFn","transcludedScope","cloneFn","controllers","containingScope","$$transcluded","attrsMap","$attr","addDirective","directiveNormalize","nName","ngAttrName","isNgAttr","nAttrs","attributes","attrStartName","attrEndName","NG_ATTR_BINDING","PREFIX_REGEXP","multiElementMatch","MULTI_ELEMENT_DIR_RE","directiveIsMultiElement","addAttrInterpolateDirective","animVal","msie","addTextInterpolateDirective","NODE_TYPE_COMMENT","byPriority","groupScan","attrStart","attrEnd","depth","groupElementsLinkFnWrapper","linkFn","compileNode","templateAttrs","jqCollection","originalReplaceDirective","preLinkFns","postLinkFns","addLinkFns","pre","post","newIsolateScopeDirective","$$isolateScope","cloneAndAnnotateFn","getControllers","elementControllers","inheritType","dataName","setupControllers","controllerDirectives","controllerKey","$scope","$attrs","$transclude","controllerInstance","linkNode","controllersBoundTransclude","cloneAttachFn","hasElementTranscludeDirective","scopeToChild","controllerScope","removeScopeBindingWatches","removeControllerBindingWatches","newScopeDirective","templateDirective","$$originalDirective","$$isolateBindings","initializeDirectiveBindings","$on","controllerDirective","$$bindings","identifier","controllerResult","invokeLinkFn","templateUrl","$template","directiveValue","terminalPriority","nonTlbTranscludeDirective","hasTranscludeDirective","hasTemplate","$compileNode","replaceDirective","childTranscludeFn","$$start","$$end","assertNoDuplicate","$$tlb","createComment","replaceWith","contents","$$newScope","denormalizeTemplate","removeComments","templateNamespace","newTemplateAttrs","templateDirectives","unprocessedDirectives","markDirectiveScope","mergeTemplateAttributes","compileTemplateUrl","Math","max","newScope","tDirectives","startAttrName","endAttrName","multiElement","srcAttr","dstAttr","$set","tAttrs","afterTemplateNodeLinkFn","afterTemplateChildLinkFn","linkQueue","beforeTemplateCompileNode","origAsyncDirective","derivedSyncDirective","content","tempTemplateAttrs","beforeTemplateLinkNode","linkRootElement","$$destroyed","oldClasses","ignoreChildLinkFn","diff","what","previousDirective","wrapModuleNameIfDefined","moduleName","text","interpolateFn","templateNode","templateNodeParent","hasCompileParent","$$addBindingClass","$$addBindingInfo","expressions","getTrustedContext","attrNormalizedName","HTML","RESOURCE_URL","allOrNothing","trustedContext","$$observers","newValue","$$inter","$$scope","oldValue","$updateClass","elementsToRemove","newNode","firstElementToRemove","removeCount","j2","hasData","expando","k","kk","annotation","removeWatchCollection","lastValue","parentGet","parentSet","compare","$observe","literal","assign","parentValueWatch","parentValue","$stateful","removeWatch","$watchCollection","attributesToCopy","$normalize","$addClass","classVal","$removeClass","newClasses","toAdd","tokenDifference","toRemove","writeAttr","booleanKey","aliasedKey","observer","trimmedSrcset","srcPattern","rawUris","nbrUrisWith2parts","floor","innerIdx","lastTuple","removeAttr","listeners","startSymbol","endSymbol","binding","isolated","noTemplate","str1","str2","values","tokens1","tokens2","outer","token","jqNodes","ident","CNTRL_REG","globals","register","allowGlobals","addIdentifier","expression","later","$controllerMinErr","controllerPrototype","exception","cause","serializeValue","v","toISOString","params","serialize","toSerialize","topLevel","defaultHttpResponseTransform","headers","tempData","JSON_PROTECTION_PREFIX","contentType","APPLICATION_JSON","isJsonLike","jsonStart","JSON_START","JSON_ENDS","parseHeaders","fillInParsed","line","headerVal","headerKey","headersGetter","headersObj","transformData","status","fns","isSuccess","defaults","transformResponse","transformRequest","d","common","Accept","CONTENT_TYPE_APPLICATION_JSON","patch","xsrfCookieName","xsrfHeaderName","paramSerializer","useApplyAsync","useLegacyPromise","useLegacyPromiseExtensions","interceptorFactories","interceptors","requestConfig","response","resp","reject","executeHeaderFns","headerContent","processedHeaders","headerFn","header","mergeHeaders","defHeaderName","lowercaseDefHeaderName","reqHeaderName","defHeaders","reqHeaders","defaultHeadersIteration","serverRequest","reqData","withCredentials","sendReq","chain","promise","when","reversedInterceptors","interceptor","request","requestError","responseError","thenFn","rejectFn","success","$httpMinErrLegacyFn","createShortMethods","createShortMethodsWithData","done","headersString","statusText","resolveHttpPromise","resolvePromise","$applyAsync","$$phase","deferred","resolve","resolvePromiseWithResult","removePendingReq","pendingRequests","cachedResp","buildUrl","defaultCache","xsrfValue","urlIsSameOrigin","timeout","responseType","serializedParams","interceptorFactory","XMLHttpRequest","createHttpBackend","createXhr","$browserDefer","rawDocument","jsonpReq","callbackId","async","body","called","addEventListenerFn","timeoutRequest","jsonpDone","xhr","abort","completeRequest","open","setRequestHeader","onload","responseText","urlResolve","protocol","getAllResponseHeaders","onerror","onabort","send","escape","ch","unescapeText","escapedStartRegexp","escapedEndRegexp","mustHaveExpression","parseStringifyInterceptor","getValue","$interpolateMinErr","interr","endIndex","exp","parseFns","textLength","expressionPositions","startSymbolLength","endSymbolLength","throwNoconcat","compute","getTrusted","$$watchDelegate","$watchGroup","oldValues","currValue","interval","count","invokeApply","hasParams","setInterval","clearInterval","iteration","skipApply","$$intervalId","notify","intervals","encodePath","segments","parseAbsoluteUrl","absoluteUrl","locationObj","parsedUrl","$$protocol","$$host","hostname","$$port","port","DEFAULT_PORTS","parseAppUrl","relativeUrl","prefixed","$$path","pathname","$$search","search","$$hash","beginsWith","begin","whole","trimEmptyHash","stripFile","lastIndexOf","serverBase","LocationHtml5Url","appBase","appBaseNoFile","basePrefix","$$html5","$$parse","pathUrl","$locationMinErr","$$compose","$$url","$$absUrl","$$parseLinkUrl","relHref","appUrl","prevAppUrl","rewrittenUrl","LocationHashbangUrl","hashPrefix","removeWindowsDriveName","base","firstPathSegmentMatch","windowsFilePathExp","withoutHashUrl","withoutBaseUrl","LocationHashbangInHtml5Url","locationGetter","property","locationGetterSetter","preprocess","rewriteLinks","setBrowserUrlWithFallback","oldUrl","oldState","$$state","afterLocationChange","$broadcast","absUrl","LocationMode","initialUrl","IGNORE_URI_REGEXP","ctrlKey","metaKey","shiftKey","which","button","absHref","preventDefault","initializing","newUrl","newState","$digest","currentReplace","$$replace","urlOrStateChanged","debug","debugEnabled","flag","formatError","sourceURL","consoleLog","console","logFn","log","hasApply","arg1","arg2","warn","ensureSafeMemberName","fullExpression","$parseMinErr","getStringValue","ensureSafeObject","children","ensureSafeFunction","CALL","APPLY","BIND","ensureSafeAssignContext","Function","ifDefined","plusFn","r","isStateless","filterName","findConstantAndWatchExpressions","ast","allConstants","argsToWatch","AST","Program","expr","Literal","toWatch","UnaryExpression","argument","BinaryExpression","left","right","LogicalExpression","ConditionalExpression","alternate","consequent","Identifier","MemberExpression","object","computed","CallExpression","callee","AssignmentExpression","ArrayExpression","ObjectExpression","properties","ThisExpression","getInputs","lastExpression","isAssignable","assignableAST","NGValueParameter","operator","isLiteral","isConstant","ASTCompiler","astBuilder","ASTInterpreter","isPossiblyDangerousMemberName","getValueOf","objectValueOf","cacheDefault","cacheExpensive","interceptorFn","expensiveChecks","parsedExpression","oneTime","cacheKey","runningChecksEnabled","parseOptions","$parseOptionsExpensive","$parseOptions","lexer","Lexer","parser","Parser","constantWatchDelegate","oneTimeLiteralWatchDelegate","oneTimeWatchDelegate","inputs","inputsWatchDelegate","expensiveChecksInterceptor","addInterceptor","expensiveCheckFn","expensiveCheckOldValue","expressionInputDirtyCheck","oldValueOfValue","objectEquality","prettyPrintExpression","lastResult","inputExpressions","oldInputValueOf","newInputValue","oldInputValueOfValues","oldInputValues","changed","unwatch","old","$$postDigest","isAllDefined","allDefined","watchDelegate","useInputs","regularWatch","noUnsafeEval","$$runningExpensiveChecks","qFactory","nextTick","exceptionHandler","callOnce","resolveFn","Promise","simpleBind","processQueue","pending","processScheduled","scheduleProcessQueue","Deferred","promises","results","$qMinErr","TypeError","onFulfilled","onRejected","progressBack","catch","finally","handleCallback","$$reject","$$resolve","progress","makePromise","resolved","isResolved","callbackOutput","errback","$Q","Q","resolver","requestAnimationFrame","webkitRequestAnimationFrame","cancelAnimationFrame","webkitCancelAnimationFrame","webkitCancelRequestAnimationFrame","rafSupported","raf","timer","supported","createChildScopeClass","ChildScope","$$watchers","$$nextSibling","$$childHead","$$childTail","$$listeners","$$listenerCount","$$watchersCount","$id","$$ChildScope","TTL","$rootScopeMinErr","lastDirtyWatch","applyAsyncId","digestTtl","destroyChildScope","$event","currentScope","cleanUpScope","$$prevSibling","$root","Scope","beginPhase","phase","clearPhase","incrementWatchersCount","current","decrementListenerCount","initWatchVal","flushApplyAsync","applyAsyncQueue","scheduleApplyAsync","isolate","child","watchExp","watcher","eq","watchExpressions","watchGroupAction","changeReactionScheduled","firstRun","newValues","deregisterFns","shouldCall","unwatchFn","$watchCollectionInterceptor","_value","newLength","bothNaN","newItem","oldItem","internalArray","oldLength","changeDetected","internalObject","$watchCollectionAction","initRun","veryOldValue","trackVeryOldValue","changeDetector","watch","watchers","dirty","next","logIdx","asyncTask","ttl","watchLog","asyncQueue","$eval","traverseScopesLoop","msg","postDigestQueue","eventName","$applyAsyncExpression","namedListeners","indexOfListener","$emit","targetScope","listenerArgs","$$asyncQueue","$$postDigestQueue","$$applyAsyncQueue","uri","isImage","normalizedVal","regex","adjustMatcher","matcher","$sceMinErr","escapeForRegexp","adjustMatchers","matchers","adjustedMatchers","SCE_CONTEXTS","resourceUrlWhitelist","resourceUrlBlacklist","matchUrl","isResourceUrlAllowedByPolicy","allowed","generateHolderType","Base","holderType","trustedValue","$$unwrapTrustedValue","trustAs","Constructor","byType","maybeTrusted","trustedValueHolderBase","htmlSanitizer","CSS","URL","JS","sce","isEnabled","parseAs","enumValue","lName","vendorPrefix","eventSupport","android","navigator","userAgent","boxee","vendorRegex","bodyStyle","transitions","animations","webkitTransition","webkitAnimation","pushState","hasEvent","divElm","handleRequestFn","tpl","ignoreRequestError","handleError","totalPendingRequests","getTrustedResourceUrl","transformer","httpOptions","testability","findBindings","opt_exactMatch","getElementsByClassName","matches","dataBinding","bindingName","findModels","prefixes","attributeEquals","getLocation","setLocation","whenStable","deferreds","$$timeoutId","urlParsingNode","requestUrl","originUrl","$$CookieReader","safeDecodeURIComponent","lastCookies","lastCookieString","cookieArray","cookie","currentCookieString","filters","suffix","currencyFilter","dateFilter","filterFilter","jsonFilter","limitToFilter","lowercaseFilter","numberFilter","orderByFilter","uppercaseFilter","comparator","predicateFn","matchAgainstAnyProp","expressionType","getTypeForFilter","createPredicateFn","shouldMatchPrimitives","actual","expected","deepCompare","dontMatchWholeObject","actualType","expectedType","expectedVal","matchAnyProperty","actualVal","$locale","formats","NUMBER_FORMATS","amount","currencySymbol","fractionSize","CURRENCY_SYM","PATTERNS","maxFrac","formatNumber","GROUP_SEP","DECIMAL_SEP","number","numStr","digits","numberOfIntegerDigits","zeros","exponent","ZERO_CHAR","MAX_DIGITS","roundNumber","parsedNumber","minFrac","fractionLen","min","roundAt","digit","carry","reduceRight","groupSep","decimalSep","isInfinity","isFinite","isZero","abs","formattedText","integerLen","decimals","reduce","groups","lgSize","gSize","negPre","negSuf","posPre","posSuf","padNumber","num","neg","dateGetter","dateStrGetter","shortForm","timeZoneGetter","zone","paddedZone","getFirstThursdayOfYear","year","dayOfWeekOnFirst","getDay","getThursdayThisWeek","datetime","getFullYear","getMonth","getDate","weekGetter","firstThurs","thisThurs","round","ampmGetter","getHours","AMPMS","eraGetter","ERAS","longEraGetter","ERANAMES","jsonStringToDate","string","R_ISO8601_STR","tzHour","tzMin","dateSetter","setUTCFullYear","setFullYear","timeSetter","setUTCHours","setHours","s","ms","parseFloat","format","DATETIME_FORMATS","NUMBER_STRING","DATE_FORMATS_SPLIT","DATE_FORMATS","spacing","limit","Infinity","processPredicates","sortPredicate","reverseOrder","map","predicate","descending","objectValue","getPredicateValue","v1","v2","getComparisonObject","predicateValues","predicates","doComparison","compareValues","ngDirective","nullFormRenameControl","control","$name","FormController","controls","$error","$$success","$pending","$dirty","$pristine","$valid","$invalid","$submitted","$$parentForm","nullFormCtrl","$rollbackViewValue","$commitViewValue","$addControl","$$renameControl","newName","oldName","$removeControl","$setValidity","addSetValidityMethod","ctrl","set","unset","$setDirty","PRISTINE_CLASS","DIRTY_CLASS","$setPristine","setClass","SUBMITTED_CLASS","$setUntouched","$setSubmitted","stringBasedInputType","$formatters","$isEmpty","textInputType","baseInputType","composing","ev","ngTrim","$viewValue","$$hasNativeValidators","$setViewValue","deferListener","origValue","keyCode","PARTIAL_VALIDATION_TYPES","PARTIAL_VALIDATION_EVENTS","validity","VALIDITY_STATE_PROPERTY","origBadInput","badInput","origTypeMismatch","typeMismatch","$render","weekParser","isoWeek","existingDate","WEEK_REGEXP","week","hours","seconds","milliseconds","addDays","getSeconds","getMilliseconds","NaN","createDateParser","mapping","iso","ISO_DATE_REGEXP","yyyy","MM","dd","HH","mm","ss","sss","part","createDateInputType","parseDate","isValidDate","parseObservedDateValue","badInputChecker","previousDate","$options","$$parserName","$parsers","parsedDate","ngModelMinErr","ngMin","minVal","$validators","$validate","ngMax","maxVal","nativeValidation","numberInputType","NUMBER_REGEXP","urlInputType","modelValue","viewValue","URL_REGEXP","emailInputType","email","EMAIL_REGEXP","radioInputType","checked","parseConstantExpr","parseFn","checkboxInputType","trueValue","ngTrueValue","falseValue","ngFalseValue","classDirective","arrayDifference","arrayClasses","addClasses","digestClassCounts","removeClasses","classCounts","classesToUpdate","updateClasses","ngClassWatchAction","$index","old$index","mod","setValidity","validationErrorKey","createAndSet","unsetAndCleanup","cachedToggleClass","PENDING_CLASS","toggleValidationCss","isObjectEmpty","combinedState","switchValue","classCache","isValid","VALID_CLASS","INVALID_CLASS","chromeHack","optionElement","selected","REGEX_STRING_REGEXP","manualLowercase","String","fromCharCode","charCodeAt","manualUppercase","documentMode","rules","ngCspElement","ngCspAttribute","noInlineStyle","name_","el","NODE_TYPE_ATTRIBUTE","full","major","minor","dot","codeName","addEventListener","removeEventListener","mouseleave","mouseenter","thead","col","tr","td","optgroup","tbody","tfoot","colgroup","caption","th","Node","contains","compareDocumentPosition","ready","trigger","fired","removeData","removeAttribute","css","lowercasedName","getNamedItem","specified","ret","getText","$dv","multiple","nodeCount","types","addHandler","noEventListener","one","onFn","replaceNode","insertBefore","contentDocument","prepend","wrapNode","detach","after","newElement","toggleClass","condition","classCondition","nextElementSibling","getElementsByTagName","extraParameters","dummyEvent","eventFnsCopy","handlerArgs","arg3","unbind","$animateMinErr","NG_ANIMATE_CLASSNAME","postDigestElements","updateData","handleCSSClassChanges","existing","addRemoveClassesPostDigest","add","classesAdded","classesRemoved","pin","domOperation","from","to","runner","complete","$$registeredAnimations","classNameFilter","$$classNameFilter","reservedRegex","domInsert","afterElement","afterNode","previousElementSibling","end","enter","move","leave","addclass","animate","tempClasses","waitForTick","waitQueue","passed","AnimateRunner","setHost","rafTick","timeoutTick","_doneCallbacks","_tick","doc","hidden","_state","INITIAL_STATE","DONE_PENDING_STATE","DONE_COMPLETE_STATE","runners","onProgress","getPromise","resolveHandler","rejectHandler","pause","resume","_resolve","initialOptions","applyAnimationContents","closed","$$prepared","cleanupStyles","start","offsetWidth","Content-Type","[","{","$httpMinErr","PATH_MATCH","http","https","ftp","locationPrototype","paramValue","Location","OPERATORS","ESCAPE","f","t","'","\"","lex","tokens","readString","peek","readNumber","isIdent","readIdent","is","isWhitespace","ch2","ch3","op1","op2","op3","throwError","chars","isExpOperator","colStr","peekCh","quote","rawString","hex","rep","ExpressionStatement","Property","program","expressionStatement","expect","filterChain","assignment","ternary","logicalOR","consume","logicalAND","equality","relational","additive","multiplicative","unary","primary","arrayDeclaration","constants","parseArguments","baseExpression","peekToken","kind","e1","e2","e3","e4","peekAhead","true","false","null","nextId","vars","own","assignable","stage","computing","recurse","return_","generateFunction","fnKey","intoId","watchId","fnString","USE","STRICT","filterPrefix","watchFns","varsPrefix","section","nameId","recursionFn","skipWatchIdCheck","if_","lazyAssign","computedMember","lazyRecurse","plus","not","getHasOwnProperty","nonComputedMember","addEnsureSafeObject","notNull","addEnsureSafeAssignContext","addEnsureSafeMemberName","addEnsureSafeFunction","member","defaultValue","stringEscapeRegex","stringEscapeFn","skip","init","rhs","lhs","unary+","unary-","unary!","binary+","binary-","binary*","binary/","binary%","binary===","binary!==","binary==","binary!=","binary<","binary>","binary<=","binary>=","binary&&","binary||","ternary?:","astCompiler","yy","y","MMMM","MMM","M","H","hh","EEEE","EEE","Z","ww","w","G","GG","GGG","GGGG","xlinkHref","propName","defaultLinkFn","normalized","htmlAttr","formDirectiveFactory","isNgForm","getSetter","formElement","nameAttr","ctrls","handleFormSubmission","parentFormCtrl","setter","DATE_REGEXP","DATETIMELOCAL_REGEXP","MONTH_REGEXP","TIME_REGEXP","inputType","datetime-local","time","month","radio","checkbox","submit","reset","file","CONSTANT_VALUE_REGEXP","tplAttr","$compile","templateElement","tElement","ngBindHtmlGetter","ngBindHtmlWatch","getTrustedHtml","$viewChangeListeners","forceAsyncEvents","blur","focus","previousElements","srcExp","onloadExp","autoScrollExp","autoscroll","previousElement","currentElement","changeCounter","cleanupLastIncludeContent","afterAnimation","thisChangeId","trimValues","UNTOUCHED_CLASS","TOUCHED_CLASS","NgModelController","$modelValue","$$rawModelValue","$asyncValidators","$untouched","$touched","parserValid","parsedNgModel","parsedNgModelAssign","ngModelGet","ngModelSet","pendingDebounce","$$setOptions","getterSetter","invokeModelGetter","invokeModelSetter","$$$p","currentValidationRunId","$setTouched","$$lastCommittedViewValue","prevValid","prevModelValue","allowInvalid","$$runValidators","allValid","$$writeModelToScope","doneCallback","processParseErrors","errorKey","processSyncValidators","syncValidatorsValid","validator","processAsyncValidators","validatorPromises","validationDone","localValidationRunId","$$parseAndValidate","writeToModelIfNeeded","updateOnDefault","$$debounceViewValueCommit","debounce","debounceDelay","formatters","modelCtrl","formCtrl","updateOn","DEFAULT_REGEXP","that","ngOptionsMinErr","NG_OPTIONS_REGEXP","parseOptionsExpression","optionsExp","selectElement","Option","selectValue","label","group","disabled","getOptionValuesKeys","optionValues","optionValuesKeys","keyName","itemKey","valueName","selectAs","trackBy","selectAsFn","viewValueFn","trackByFn","getTrackByValueFn","getTrackByValue","getLocals","displayFn","groupByFn","disableWhenFn","valuesFn","getWatchables","watchedArray","optionValuesLength","disableWhen","getOptions","optionItems","selectValueMap","optionItem","getOptionFromViewValue","getViewValueFromOption","ngOptionsPostLink","updateOptionElement","addOrReuseElement","removeExcessElements","skipEmptyAndUnknownOptions","emptyOption_","emptyOption","unknownOption_","unknownOption","updateOptions","previousValue","selectCtrl","readValue","groupMap","providedEmptyOption","groupElement","optGroupTemplate","currentOptionElement","optionTemplate","ngModelCtrl","nextValue","isNotPrimitive","renderEmptyOption","removeEmptyOption","renderUnknownOption","removeUnknownOption","writeValue","selectedValues","selections","selectedOption","registerOption","BRACE","IS_WHEN","updateElementText","newText","lastCount","numberExp","whenExp","whens","whensExpFns","braceReplacement","watchRemover","attributeName","tmpMatch","whenKey","countIsNaN","pluralCat","whenExpFn","NG_REMOVED","ngRepeatMinErr","updateScope","valueIdentifier","keyIdentifier","arrayLength","$first","$last","$middle","$odd","$even","getBlockStart","getBlockEnd","ngRepeatEndComment","aliasAs","trackByExp","trackByExpGetter","trackByIdExpFn","trackByIdArrayFn","trackByIdObjFn","hashFnLocals","lastBlockMap","nextNode","collectionLength","trackById","trackByIdFn","collectionKeys","nextBlockOrder","previousNode","nextBlockMap","blockKey","NG_HIDE_CLASS","NG_HIDE_IN_PROGRESS_CLASS","newStyles","oldStyles","cases","ngSwitchController","watchExpr","selectedTranscludes","selectedElements","previousLeaveAnimations","selectedScopes","spliceFactory","selectedTransclude","caseElement","selectedScope","anchor","noopNgModelController","SelectController","optionsMap","unknownVal","hasOption","addOption","removeOption","optionScope","optionAttrs","interpolateValueFn","interpolateTextFn","selectPreLink","lastView","lastViewRef","selectPostLink","selectCtrlName","patternExp","intVal","getDecimals","getVF","opt_precision","pow","PLURAL_CATEGORY","ZERO","ONE","TWO","FEW","MANY","OTHER","DAY","FIRSTDAYOFWEEK","MONTH","SHORTDAY","SHORTMONTH","STANDALONEMONTH","WEEKENDRANGE","fullDate","longDate","medium","mediumDate","mediumTime","short","shortDate","shortTime","minInt","localeID","vf","head","$RouteProvider","pathRegExp","opts","insensitive","caseInsensitiveMatch","originalPath","slash","star","routes","route","routeCopy","reloadOnSearch","redirectPath","redirectTo","otherwise","$routeParams","switchRouteMatcher","prepareRoute","$locationEvent","lastRoute","$route","preparedRoute","parseRoute","preparedRouteIsUpdateOnly","$$route","pathParams","forceReload","commitRoute","nextRoute","interpolate","loadedTemplateUrl","segment","segmentMatch","fakeLocationEvent","updateParams","newParams","$routeMinErr","$RouteParamsProvider","ngViewFactory","cleanupLastView","previousLeaveAnimation","update","ngViewFillContentFactory","ngRouteModule","$SanitizeProvider","buf","htmlParser","htmlSanitizeWriter","sanitizeText","writer","lowercaseKeys","parseStartTag","tagName","rest","blockElements","inlineElements","parseEndTag","optionalEndTagElements","voidElements","ATTR_REGEXP","doubleQuotedValue","singleQuotedValue","unquotedValue","decodeEntities","specialElements","COMMENT_REGEXP","CDATA_REGEXP","comment","DOCTYPE_REGEXP","BEGING_END_TAGE_REGEXP","END_TAG_REGEXP","BEGIN_TAG_REGEXP","START_TAG_REGEXP","$sanitizeMinErr","hiddenPre","encodeEntities","SURROGATE_PAIR_REGEXP","hi","low","NON_ALPHANUMERIC_REGEXP","uriValidator","ignore","out","validElements","lkey","validAttrs","uriAttrs","optionalEndTagBlockElements","optionalEndTagInlineElements","svgElements","htmlAttrs","svgAttrs","$sanitize","LINKY_URL_REGEXP","MAILTO_REGEXP","addText","addLink","raw","makeSwipeDirective","direction","ngTouch","$swipe","MAX_VERTICAL_DISTANCE","MAX_VERTICAL_RATIO","MIN_HORIZONTAL_DISTANCE","validSwipe","coords","startCoords","deltaY","deltaX","x","valid","swipeHandler","pointerTypes","getCoordinates","originalEvent","touches","changedTouches","clientX","clientY","getEvents","eventType","res","pointerType","POINTER_EVENTS","MOVE_BUFFER_RADIUS","mouse","touch","eventHandlers","totalX","totalY","lastPos","active","hit","x1","y1","x2","y2","CLICKBUSTER_THRESHOLD","checkAllowableRegions","touchCoordinates","onClick","now","lastPreventedTime","PREVENT_DURATION","lastLabelClickCoordinates","onTouchStart","preventGhostClick","TAP_DURATION","MOVE_TOLERANCE","ACTIVE_CLASS_NAME","resetState","tapping","tapElement","startTime","touchStartX","touchStartY","clickHandler","ngClick","srcElement","dist","sqrt","onclick","touchend","disconnectController","DEFAULT_HEADING","DEFAULT_MESSAGE","_disconnected","ui","visible","heading","socketEvents","connection","disconnect","notifyController","DEFAULT_STATUS","DEFAULT_TIMEOUT","show","evt","_timer","HistoryService","Socket","visited","updateStack","updateHistory","urls","getData","emit","clear","ClientsService","api","reloadAll","clientEvent","sendAllTo","scrollAllTo","proportional","override","highlight","SocketService","session","io","socket","prev","publicApi","removeEvent","removeListener","uiEvent","newSession","defineProperty","socketConfig","___browserSync___","socketUrl","lookup","sameNamespace","nsps","newConnection","forceNew","multiplex","Manager","query","managers","connect","global","loc","parseuri","ipv6","re","authority","ipv6uri","process","useColors","WebkitAppearance","firebug","table","$1","formatArgs","humanize","color","lastC","save","namespaces","storage","removeItem","load","env","DEBUG","localstorage","localStorage","chrome","local","colors","enable","defaultSetTimout","defaultClearTimeout","runTimeout","fun","cachedSetTimeout","runClearTimeout","marker","cachedClearTimeout","cleanUpNextTick","draining","currentQueue","queueIndex","drainQueue","Item","title","browser","argv","versions","addListener","once","removeAllListeners","cwd","chdir","dir","umask","selectColor","createDebug","curr","prevTime","coerce","formatter","skips","disable","fmtShort","fmtLong","plural","ceil","long","Encoder","encodeAsString","BINARY_EVENT","BINARY_ACK","attachments","nsp","encodeAsBinary","writeEncoding","bloblessData","deconstruction","binary","deconstructPacket","pack","packet","buffers","removeBlobs","Decoder","reconstructor","decodeString","tryParse","BinaryReconstructor","reconPack","ERROR","Emitter","hasBin","isBuf","CONNECT","DISCONNECT","EVENT","ACK","encode","encoding","base64","takeBinaryData","finishedReconstruction","binData","reconstructPacket","mixin","_callbacks","cb","hasListeners","hasBinary","Buffer","isBuffer","ArrayBuffer","withNativeBlob","Blob","withNativeFile","File","toJSON","arr","_deconstructPacket","placeholder","_placeholder","newData","_reconstructPacket","packetData","_removeBlobs","curKey","containingObject","pendingBlobs","fileReader","FileReader","readAsArrayBuffer","subs","reconnection","reconnectionAttempts","reconnectionDelay","reconnectionDelayMax","randomizationFactor","backoff","Backoff","jitter","connecting","lastPing","packetBuffer","_parser","encoder","decoder","autoConnect","eio","emitAll","updateSocketIds","generateId","engine","_reconnection","_reconnectionAttempts","_reconnectionDelay","setMin","_randomizationFactor","setJitter","_reconnectionDelayMax","setMax","_timeout","maybeReconnectOnOpen","reconnecting","attempts","reconnect","skipReconnect","openSub","onopen","errorSub","cleanup","close","onping","onpong","ondata","ondecoded","onConnecting","encodedPackets","write","processPacketQueue","subsLength","sub","onclose","duration","onreconnect","attempt","secure","agent","parseqs","decode","upgrade","forceJSONP","jsonp","forceBase64","enablesXDR","timestampParam","timestampRequests","transports","transportOptions","writeBuffer","prevBufferLen","policyPort","rememberUpgrade","binaryType","onlyBinaryUpgrades","perMessageDeflate","threshold","pfx","passphrase","cert","ca","ciphers","rejectUnauthorized","forceNode","freeGlobal","extraHeaders","localAddress","upgrades","pingInterval","pingTimeout","pingIntervalTimer","pingTimeoutTimer","o","priorWebsocketSuccess","Transport","createTransport","EIO","transport","sid","requestTimeout","protocols","setTransport","onDrain","onPacket","onError","onClose","probe","onTransportOpen","upgradeLosesBinary","supportsBinary","failed","upgrading","flush","freezeTransport","onTransportClose","onupgrade","onOpen","onHandshake","setPing","filterUpgrades","onHeartbeat","ping","sendPacket","writable","compress","cleanupAndClose","waitForUpgrade","desc","filteredUpgrades","polling","xd","xs","isSSL","xdomain","xscheme","XHR","JSONP","websocket","hasCORS","XDomainRequest","Polling","Request","isBinary","unloadHandler","requests","doWrite","req","sendXhr","doPoll","onData","pollXhr","setDisableHeaderCheck","hasXDR","onLoad","onreadystatechange","getResponseHeader","requestsCount","onSuccess","fromError","attachEvent","hasXHR2","yeast","doOpen","poll","onPause","total","decodePayload","doClose","packets","callbackfn","encodePayload","schema","b64","description","decodePacket","encodeBase64Object","encodeArrayBuffer","encodeBase64Packet","contentArray","Uint8Array","resultBuffer","byteLength","buffer","encodeBlobAsArrayBuffer","fr","encodePacket","encodeBlob","dontSendBlobs","blob","tryDecode","utf8","strict","ary","each","eachWithIndex","base64encoder","sliceBuffer","isAndroid","isPhantomJS","pong","packetslist","utf8encode","encoded","readAsDataURL","b64data","typed","basic","btoa","utf8decode","decodeBase64Packet","asArray","setLengthHeader","encodeOne","encodePayloadAsBlob","encodePayloadAsArrayBuffer","decodePayloadAsBinary","chr","totalLength","acc","resultArray","bufferIndex","ab","view","lenStr","binaryIdentifier","lengthAry","bufferTail","tailArray","msgLength","arraybuffer","bytes","abv","err_cb","proxy","bail","__WEBPACK_AMD_DEFINE_RESULT__","ucs2decode","output","ucs2encode","stringFromCharCode","checkScalarValue","codePoint","createByte","encodeCodePoint","symbol","codePoints","byteString","readContinuationByte","byteIndex","byteCount","continuationByte","byteArray","decodeSymbol","byte1","byte2","byte3","byte4","freeExports","webpackPolyfill","deprecate","paths","encoded1","encoded2","encoded3","encoded4","bufferLength","mapArrayBufferViews","chunk","byteOffset","BlobBuilderConstructor","bb","BlobBuilder","getBlob","BlobConstructor","WebKitBlobBuilder","MSBlobBuilder","MozBlobBuilder","blobSupported","blobSupportsArrayBufferView","blobBuilderSupported","qs","qry","pairs","pair","alphabet","decoded","seed","JSONPPolling","___eio","rNewline","rEscapedNewline","iframe","insertAt","isUAgecko","initIframe","iframeId","area","WS","usingBrowserWebSocket","BrowserWebSocket","WebSocket","NodeWebSocket","MozWebSocket","check","ws","supports","addEventListeners","onmessage","ids","acks","receiveBuffer","sendBuffer","connected","disconnected","toArray","connect_error","connect_timeout","reconnect_attempt","reconnect_failed","reconnect_error","subEvents","flags","onpacket","onconnect","onevent","onack","ondisconnect","ack","sent","emitBuffered","factor","rand","random","deviation","ContentSections","pagesConfig","$section","transform","app","OptionsService","Store","ns","bs","store","objectPath","StoreModule","__WEBPACK_AMD_DEFINE_FACTORY__","__WEBPACK_AMD_DEFINE_ARRAY__","isLocalStorageNameSupported","localStorageName","scriptTag","defaultVal","transact","transactionFn","getAll","deserialize","setItem","getItem","addBehavior","storageOwner","storageContainer","ActiveXObject","frames","withIEStorage","storeFunction","forbiddenCharsRegex","ieKeyFix","XMLDocument","testKey","isEmpty","_hasOwnProperty","toStr","getKey","intKey","doNotReplace","currentPath","del","ensureExists","insert","at","coalesce","MainController","browsers","socketId","Pages","Clients","menu","sectionMenu","setActiveSection","toggleMenu","transformOptions","displayUrl","getDisplayUrl","external","utils","ucfirst","localRootUrl","orderObjectBy","scheme","localUrl","field","filtered","icon","iconName","pages","navi","toggle","switchid","tagline"],"mappings":"CAAS,SAAUA,GCInB,QAAAC,GAAAC,GAGA,GAAAC,EAAAD,GACA,MAAAC,GAAAD,GAAAE,OAGA,IAAAC,GAAAF,EAAAD,IACAE,WACAE,GAAAJ,EACAK,QAAA,EAUA,OANAP,GAAAE,GAAAM,KAAAH,EAAAD,QAAAC,IAAAD,QAAAH,GAGAI,EAAAE,QAAA,EAGAF,EAAAD,QAvBA,GAAAD,KAqCA,OATAF,GAAAQ,EAAAT,EAGAC,EAAAS,EAAAP,EAGAF,EAAAU,EAAA,GAGAV,EAAA,KDMM,SAASI,EAAQD,EAASH,GAE/BI,EAAOD,QAAUH,EAAoB,IAKhC,SAASI,EAAQD,EAASH,GE1BhC,QAAAW,GAAAC,GACAA,EAAAC,WACAC,SAAA,EACAC,aAAA,IA5BAf,EAAA,GACAA,EAAA,GACAA,EAAA,GACAA,EAAA,EAEA,IAAAgB,GAAAC,OAAAD,OAEAA,GACAZ,OAAA,eACA,YACA,YACA,eACA,WACA,WACA,UACA,UACA,UACA,eAEAc,QAAA,oBAAAP,GAmBAX,GAAA,IACAA,EAAA,IACAA,EAAA,IACAA,EAAA,IACAA,EAAA,IACAA,EAAA,IACAA,EAAA,IACAA,EAAA,IACAA,EAAA,IACAA,EAAA,IACAA,EAAA,KF4DM,SAASI,EAAQD,EAASH,GG5Gh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,IACA5wB,SAAA,EACA0zB,YAAA,EACAhnB,OACAgD,KAAA,KAEA3P,SAAA,4DACAyO,YAAA,0CAAAipB,EAAAzc,EAAA+L,GAEA,GAAAujF,GAAAvjF,EAAAvZ,IAAA,eACA07F,EAAAniF,EAAAvZ,IAAA,QAEAiqB,GAAA8yE,KAAA,SAAA76F,GACA,GAAAzO,GAAAqpG,EAAA56F,EACAw5F,GAAAre,OAAA5pF,GACA+Z,EAAAtL,c1E0xvCM,SAAStR,EAAQD,G2E3yvCvBC,EAAAD,QAAA,WACA,OACAuO,OACA89F,OAAA,IACAvpG,KAAA,IACAwpG,SAAA,IACA7e,MAAA,IACA8e,QAAA,IACApnB,OAAA,IACAh+E,KAAA,KAEAsrB,SAAA,IACA5wB,SAAA,EACA0zB,YAAA,EACAsF,YAAA,iBACAnJ,aAAA,OACArhB,YAAA,kBAAAipB,GACA,GAAAs4B,GAAA79C,IACA69C,GAAA9uD,KAAAw2B,EAAAx2B,U3EozvCM,SAAS7C,EAAQD,G4Et0vCvBC,EAAAD,QAAA,WACA,OACAuO,OACAue,IAAA,IACAsE,KAAA,KAEAqB,SAAA,IACA5wB,SAAA,EACAD,SAAA","file":"js/app.js","sourcesContent":["/******/ (function(modules) { // webpackBootstrap\n/******/ \t// The module cache\n/******/ \tvar installedModules = {};\n/******/\n/******/ \t// The require function\n/******/ \tfunction __webpack_require__(moduleId) {\n/******/\n/******/ \t\t// Check if module is in cache\n/******/ \t\tif(installedModules[moduleId])\n/******/ \t\t\treturn installedModules[moduleId].exports;\n/******/\n/******/ \t\t// Create a new module (and put it into the cache)\n/******/ \t\tvar module = installedModules[moduleId] = {\n/******/ \t\t\texports: {},\n/******/ \t\t\tid: moduleId,\n/******/ \t\t\tloaded: false\n/******/ \t\t};\n/******/\n/******/ \t\t// Execute the module function\n/******/ \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n/******/\n/******/ \t\t// Flag the module as loaded\n/******/ \t\tmodule.loaded = true;\n/******/\n/******/ \t\t// Return the exports of the module\n/******/ \t\treturn module.exports;\n/******/ \t}\n/******/\n/******/\n/******/ \t// expose the modules object (__webpack_modules__)\n/******/ \t__webpack_require__.m = modules;\n/******/\n/******/ \t// expose the module cache\n/******/ \t__webpack_require__.c = installedModules;\n/******/\n/******/ \t// __webpack_public_path__\n/******/ \t__webpack_require__.p = \"\";\n/******/\n/******/ \t// Load entry module and return exports\n/******/ \treturn __webpack_require__(0);\n/******/ })\n/************************************************************************/\n/******/ ([\n/* 0 */\n/***/ function(module, exports, __webpack_require__) {\n\n\tmodule.exports = __webpack_require__(1);\n\n\n/***/ },\n/* 1 */\n/***/ function(module, exports, __webpack_require__) {\n\n\t__webpack_require__(2);\n\t__webpack_require__(4);\n\t__webpack_require__(6);\n\t__webpack_require__(8);\n\t\n\tvar angular = window.angular;\n\t\n\tangular\n\t .module(\"BrowserSync\", [\n\t \"bsHistory\",\n\t \"bsClients\",\n\t \"bsDisconnect\",\n\t \"bsNotify\",\n\t \"bsSocket\",\n\t \"bsStore\",\n\t \"ngRoute\",\n\t \"ngTouch\",\n\t \"ngSanitize\"\n\t ])\n\t .config([\"$locationProvider\", Config]);\n\t\n\t/**\n\t * @constructor\n\t * @param $locationProvider\n\t */\n\tfunction Config($locationProvider) {\n\t $locationProvider.html5Mode({\n\t enabled: true,\n\t requireBase: false\n\t });\n\t}\n\t\n\t\n\t/**\n\t * Modules\n\t * @type {exports}\n\t */\n\t/* jshint ignore:start */\n\tvar discon = __webpack_require__(10);\n\tvar notify = __webpack_require__(12);\n\tvar history = __webpack_require__(13);\n\tvar clients = __webpack_require__(14);\n\tvar socket = __webpack_require__(15);\n\tvar app = __webpack_require__(63);\n\tvar options = __webpack_require__(65);\n\tvar Store = __webpack_require__(66);\n\tvar mainCtrl = __webpack_require__(69);\n\tvar filter = __webpack_require__(70);\n\tvar directives = __webpack_require__(72);\n\t\n\t/* jshint ignore:end */\n\n\n/***/ },\n/* 2 */\n/***/ function(module, exports, __webpack_require__) {\n\n\t__webpack_require__(3);\n\tmodule.exports = angular;\n\n\n/***/ },\n/* 3 */\n/***/ function(module, exports) {\n\n\t/**\n\t * @license AngularJS v1.4.14\n\t * (c) 2010-2015 Google, Inc. http://angularjs.org\n\t * License: MIT\n\t */\n\t(function(window, document, undefined) {'use strict';\n\t\n\t/**\n\t * @description\n\t *\n\t * This object provides a utility for producing rich Error messages within\n\t * Angular. It can be called as follows:\n\t *\n\t * var exampleMinErr = minErr('example');\n\t * throw exampleMinErr('one', 'This {0} is {1}', foo, bar);\n\t *\n\t * The above creates an instance of minErr in the example namespace. The\n\t * resulting error will have a namespaced error code of example.one. The\n\t * resulting error will replace {0} with the value of foo, and {1} with the\n\t * value of bar. The object is not restricted in the number of arguments it can\n\t * take.\n\t *\n\t * If fewer arguments are specified than necessary for interpolation, the extra\n\t * interpolation markers will be preserved in the final string.\n\t *\n\t * Since data will be parsed statically during a build step, some restrictions\n\t * are applied with respect to how minErr instances are created and called.\n\t * Instances should have names of the form namespaceMinErr for a minErr created\n\t * using minErr('namespace') . Error codes, namespaces and template strings\n\t * should all be static strings, not variables or general expressions.\n\t *\n\t * @param {string} module The namespace to use for the new minErr instance.\n\t * @param {function} ErrorConstructor Custom error constructor to be instantiated when returning\n\t * error from returned function, for cases when a particular type of error is useful.\n\t * @returns {function(code:string, template:string, ...templateArgs): Error} minErr instance\n\t */\n\t\n\tfunction minErr(module, ErrorConstructor) {\n\t ErrorConstructor = ErrorConstructor || Error;\n\t return function() {\n\t var SKIP_INDEXES = 2;\n\t\n\t var templateArgs = arguments,\n\t code = templateArgs[0],\n\t message = '[' + (module ? module + ':' : '') + code + '] ',\n\t template = templateArgs[1],\n\t paramPrefix, i;\n\t\n\t message += template.replace(/\\{\\d+\\}/g, function(match) {\n\t var index = +match.slice(1, -1),\n\t shiftedIndex = index + SKIP_INDEXES;\n\t\n\t if (shiftedIndex < templateArgs.length) {\n\t return toDebugString(templateArgs[shiftedIndex]);\n\t }\n\t\n\t return match;\n\t });\n\t\n\t message += '\\nhttp://errors.angularjs.org/1.4.14/' +\n\t (module ? module + '/' : '') + code;\n\t\n\t for (i = SKIP_INDEXES, paramPrefix = '?'; i < templateArgs.length; i++, paramPrefix = '&') {\n\t message += paramPrefix + 'p' + (i - SKIP_INDEXES) + '=' +\n\t encodeURIComponent(toDebugString(templateArgs[i]));\n\t }\n\t\n\t return new ErrorConstructor(message);\n\t };\n\t}\n\t\n\t/* We need to tell jshint what variables are being exported */\n\t/* global angular: true,\n\t msie: true,\n\t jqLite: true,\n\t jQuery: true,\n\t slice: true,\n\t splice: true,\n\t push: true,\n\t toString: true,\n\t ngMinErr: true,\n\t angularModule: true,\n\t uid: true,\n\t REGEX_STRING_REGEXP: true,\n\t VALIDITY_STATE_PROPERTY: true,\n\t\n\t lowercase: true,\n\t uppercase: true,\n\t manualLowercase: true,\n\t manualUppercase: true,\n\t nodeName_: true,\n\t isArrayLike: true,\n\t forEach: true,\n\t forEachSorted: true,\n\t reverseParams: true,\n\t nextUid: true,\n\t setHashKey: true,\n\t extend: true,\n\t toInt: true,\n\t inherit: true,\n\t merge: true,\n\t noop: true,\n\t identity: true,\n\t valueFn: true,\n\t isUndefined: true,\n\t isDefined: true,\n\t isObject: true,\n\t isBlankObject: true,\n\t isString: true,\n\t isNumber: true,\n\t isDate: true,\n\t isArray: true,\n\t isFunction: true,\n\t isRegExp: true,\n\t isWindow: true,\n\t isScope: true,\n\t isFile: true,\n\t isFormData: true,\n\t isBlob: true,\n\t isBoolean: true,\n\t isPromiseLike: true,\n\t trim: true,\n\t escapeForRegexp: true,\n\t isElement: true,\n\t makeMap: true,\n\t includes: true,\n\t arrayRemove: true,\n\t copy: true,\n\t shallowCopy: true,\n\t equals: true,\n\t csp: true,\n\t jq: true,\n\t concat: true,\n\t sliceArgs: true,\n\t bind: true,\n\t toJsonReplacer: true,\n\t toJson: true,\n\t fromJson: true,\n\t convertTimezoneToLocal: true,\n\t timezoneToOffset: true,\n\t startingTag: true,\n\t tryDecodeURIComponent: true,\n\t parseKeyValue: true,\n\t toKeyValue: true,\n\t encodeUriSegment: true,\n\t encodeUriQuery: true,\n\t angularInit: true,\n\t bootstrap: true,\n\t getTestability: true,\n\t snake_case: true,\n\t bindJQuery: true,\n\t assertArg: true,\n\t assertArgFn: true,\n\t assertNotHasOwnProperty: true,\n\t getter: true,\n\t getBlockNodes: true,\n\t hasOwnProperty: true,\n\t createMap: true,\n\t\n\t NODE_TYPE_ELEMENT: true,\n\t NODE_TYPE_ATTRIBUTE: true,\n\t NODE_TYPE_TEXT: true,\n\t NODE_TYPE_COMMENT: true,\n\t NODE_TYPE_DOCUMENT: true,\n\t NODE_TYPE_DOCUMENT_FRAGMENT: true,\n\t*/\n\t\n\t////////////////////////////////////\n\t\n\t/**\n\t * @ngdoc module\n\t * @name ng\n\t * @module ng\n\t * @description\n\t *\n\t * # ng (core module)\n\t * The ng module is loaded by default when an AngularJS application is started. The module itself\n\t * contains the essential components for an AngularJS application to function. The table below\n\t * lists a high level breakdown of each of the services/factories, filters, directives and testing\n\t * components available within this core module.\n\t *\n\t *
\n\t */\n\t\n\tvar REGEX_STRING_REGEXP = /^\\/(.+)\\/([a-z]*)$/;\n\t\n\t// The name of a form control's ValidityState property.\n\t// This is used so that it's possible for internal tests to create mock ValidityStates.\n\tvar VALIDITY_STATE_PROPERTY = 'validity';\n\t\n\t/**\n\t * @ngdoc function\n\t * @name angular.lowercase\n\t * @module ng\n\t * @kind function\n\t *\n\t * @description Converts the specified string to lowercase.\n\t * @param {string} string String to be converted to lowercase.\n\t * @returns {string} Lowercased string.\n\t */\n\tvar lowercase = function(string) {return isString(string) ? string.toLowerCase() : string;};\n\tvar hasOwnProperty = Object.prototype.hasOwnProperty;\n\t\n\t/**\n\t * @ngdoc function\n\t * @name angular.uppercase\n\t * @module ng\n\t * @kind function\n\t *\n\t * @description Converts the specified string to uppercase.\n\t * @param {string} string String to be converted to uppercase.\n\t * @returns {string} Uppercased string.\n\t */\n\tvar uppercase = function(string) {return isString(string) ? string.toUpperCase() : string;};\n\t\n\t\n\tvar manualLowercase = function(s) {\n\t /* jshint bitwise: false */\n\t return isString(s)\n\t ? s.replace(/[A-Z]/g, function(ch) {return String.fromCharCode(ch.charCodeAt(0) | 32);})\n\t : s;\n\t};\n\tvar manualUppercase = function(s) {\n\t /* jshint bitwise: false */\n\t return isString(s)\n\t ? s.replace(/[a-z]/g, function(ch) {return String.fromCharCode(ch.charCodeAt(0) & ~32);})\n\t : s;\n\t};\n\t\n\t\n\t// String#toLowerCase and String#toUpperCase don't produce correct results in browsers with Turkish\n\t// locale, for this reason we need to detect this case and redefine lowercase/uppercase methods\n\t// with correct but slower alternatives.\n\tif ('i' !== 'I'.toLowerCase()) {\n\t lowercase = manualLowercase;\n\t uppercase = manualUppercase;\n\t}\n\t\n\t\n\tvar\n\t msie, // holds major version number for IE, or NaN if UA is not IE.\n\t jqLite, // delay binding since jQuery could be loaded after us.\n\t jQuery, // delay binding\n\t slice = [].slice,\n\t splice = [].splice,\n\t push = [].push,\n\t toString = Object.prototype.toString,\n\t getPrototypeOf = Object.getPrototypeOf,\n\t ngMinErr = minErr('ng'),\n\t\n\t /** @name angular */\n\t angular = window.angular || (window.angular = {}),\n\t angularModule,\n\t uid = 0;\n\t\n\t/**\n\t * documentMode is an IE-only property\n\t * http://msdn.microsoft.com/en-us/library/ie/cc196988(v=vs.85).aspx\n\t */\n\tmsie = document.documentMode;\n\t\n\t\n\t/**\n\t * @private\n\t * @param {*} obj\n\t * @return {boolean} Returns true if `obj` is an array or array-like object (NodeList, Arguments,\n\t * String ...)\n\t */\n\tfunction isArrayLike(obj) {\n\t\n\t // `null`, `undefined` and `window` are not array-like\n\t if (obj == null || isWindow(obj)) return false;\n\t\n\t // arrays, strings and jQuery/jqLite objects are array like\n\t // * jqLite is either the jQuery or jqLite constructor function\n\t // * we have to check the existance of jqLite first as this method is called\n\t // via the forEach method when constructing the jqLite object in the first place\n\t if (isArray(obj) || isString(obj) || (jqLite && obj instanceof jqLite)) return true;\n\t\n\t // Support: iOS 8.2 (not reproducible in simulator)\n\t // \"length\" in obj used to prevent JIT error (gh-11508)\n\t var length = \"length\" in Object(obj) && obj.length;\n\t\n\t // NodeList objects (with `item` method) and\n\t // other objects with suitable length characteristics are array-like\n\t return isNumber(length) &&\n\t (length >= 0 && ((length - 1) in obj || obj instanceof Array) || typeof obj.item == 'function');\n\t\n\t}\n\t\n\t/**\n\t * @ngdoc function\n\t * @name angular.forEach\n\t * @module ng\n\t * @kind function\n\t *\n\t * @description\n\t * Invokes the `iterator` function once for each item in `obj` collection, which can be either an\n\t * object or an array. The `iterator` function is invoked with `iterator(value, key, obj)`, where `value`\n\t * is the value of an object property or an array element, `key` is the object property key or\n\t * array element index and obj is the `obj` itself. Specifying a `context` for the function is optional.\n\t *\n\t * It is worth noting that `.forEach` does not iterate over inherited properties because it filters\n\t * using the `hasOwnProperty` method.\n\t *\n\t * Unlike ES262's\n\t * [Array.prototype.forEach](http://www.ecma-international.org/ecma-262/5.1/#sec-15.4.4.18),\n\t * providing 'undefined' or 'null' values for `obj` will not throw a TypeError, but rather just\n\t * return the value provided.\n\t *\n\t ```js\n\t var values = {name: 'misko', gender: 'male'};\n\t var log = [];\n\t angular.forEach(values, function(value, key) {\n\t this.push(key + ': ' + value);\n\t }, log);\n\t expect(log).toEqual(['name: misko', 'gender: male']);\n\t ```\n\t *\n\t * @param {Object|Array} obj Object to iterate over.\n\t * @param {Function} iterator Iterator function.\n\t * @param {Object=} context Object to become context (`this`) for the iterator function.\n\t * @returns {Object|Array} Reference to `obj`.\n\t */\n\t\n\tfunction forEach(obj, iterator, context) {\n\t var key, length;\n\t if (obj) {\n\t if (isFunction(obj)) {\n\t for (key in obj) {\n\t // Need to check if hasOwnProperty exists,\n\t // as on IE8 the result of querySelectorAll is an object without a hasOwnProperty function\n\t if (key != 'prototype' && key != 'length' && key != 'name' && (!obj.hasOwnProperty || obj.hasOwnProperty(key))) {\n\t iterator.call(context, obj[key], key, obj);\n\t }\n\t }\n\t } else if (isArray(obj) || isArrayLike(obj)) {\n\t var isPrimitive = typeof obj !== 'object';\n\t for (key = 0, length = obj.length; key < length; key++) {\n\t if (isPrimitive || key in obj) {\n\t iterator.call(context, obj[key], key, obj);\n\t }\n\t }\n\t } else if (obj.forEach && obj.forEach !== forEach) {\n\t obj.forEach(iterator, context, obj);\n\t } else if (isBlankObject(obj)) {\n\t // createMap() fast path --- Safe to avoid hasOwnProperty check because prototype chain is empty\n\t for (key in obj) {\n\t iterator.call(context, obj[key], key, obj);\n\t }\n\t } else if (typeof obj.hasOwnProperty === 'function') {\n\t // Slow path for objects inheriting Object.prototype, hasOwnProperty check needed\n\t for (key in obj) {\n\t if (obj.hasOwnProperty(key)) {\n\t iterator.call(context, obj[key], key, obj);\n\t }\n\t }\n\t } else {\n\t // Slow path for objects which do not have a method `hasOwnProperty`\n\t for (key in obj) {\n\t if (hasOwnProperty.call(obj, key)) {\n\t iterator.call(context, obj[key], key, obj);\n\t }\n\t }\n\t }\n\t }\n\t return obj;\n\t}\n\t\n\tfunction forEachSorted(obj, iterator, context) {\n\t var keys = Object.keys(obj).sort();\n\t for (var i = 0; i < keys.length; i++) {\n\t iterator.call(context, obj[keys[i]], keys[i]);\n\t }\n\t return keys;\n\t}\n\t\n\t\n\t/**\n\t * when using forEach the params are value, key, but it is often useful to have key, value.\n\t * @param {function(string, *)} iteratorFn\n\t * @returns {function(*, string)}\n\t */\n\tfunction reverseParams(iteratorFn) {\n\t return function(value, key) {iteratorFn(key, value);};\n\t}\n\t\n\t/**\n\t * A consistent way of creating unique IDs in angular.\n\t *\n\t * Using simple numbers allows us to generate 28.6 million unique ids per second for 10 years before\n\t * we hit number precision issues in JavaScript.\n\t *\n\t * Math.pow(2,53) / 60 / 60 / 24 / 365 / 10 = 28.6M\n\t *\n\t * @returns {number} an unique alpha-numeric string\n\t */\n\tfunction nextUid() {\n\t return ++uid;\n\t}\n\t\n\t\n\t/**\n\t * Set or clear the hashkey for an object.\n\t * @param obj object\n\t * @param h the hashkey (!truthy to delete the hashkey)\n\t */\n\tfunction setHashKey(obj, h) {\n\t if (h) {\n\t obj.$$hashKey = h;\n\t } else {\n\t delete obj.$$hashKey;\n\t }\n\t}\n\t\n\t\n\tfunction baseExtend(dst, objs, deep) {\n\t var h = dst.$$hashKey;\n\t\n\t for (var i = 0, ii = objs.length; i < ii; ++i) {\n\t var obj = objs[i];\n\t if (!isObject(obj) && !isFunction(obj)) continue;\n\t var keys = Object.keys(obj);\n\t for (var j = 0, jj = keys.length; j < jj; j++) {\n\t var key = keys[j];\n\t var src = obj[key];\n\t\n\t if (deep && isObject(src)) {\n\t if (isDate(src)) {\n\t dst[key] = new Date(src.valueOf());\n\t } else if (isRegExp(src)) {\n\t dst[key] = new RegExp(src);\n\t } else if (src.nodeName) {\n\t dst[key] = src.cloneNode(true);\n\t } else if (isElement(src)) {\n\t dst[key] = src.clone();\n\t } else {\n\t if (!isObject(dst[key])) dst[key] = isArray(src) ? [] : {};\n\t baseExtend(dst[key], [src], true);\n\t }\n\t } else {\n\t dst[key] = src;\n\t }\n\t }\n\t }\n\t\n\t setHashKey(dst, h);\n\t return dst;\n\t}\n\t\n\t/**\n\t * @ngdoc function\n\t * @name angular.extend\n\t * @module ng\n\t * @kind function\n\t *\n\t * @description\n\t * Extends the destination object `dst` by copying own enumerable properties from the `src` object(s)\n\t * to `dst`. You can specify multiple `src` objects. If you want to preserve original objects, you can do so\n\t * by passing an empty object as the target: `var object = angular.extend({}, object1, object2)`.\n\t *\n\t * **Note:** Keep in mind that `angular.extend` does not support recursive merge (deep copy). Use\n\t * {@link angular.merge} for this.\n\t *\n\t * @param {Object} dst Destination object.\n\t * @param {...Object} src Source object(s).\n\t * @returns {Object} Reference to `dst`.\n\t */\n\tfunction extend(dst) {\n\t return baseExtend(dst, slice.call(arguments, 1), false);\n\t}\n\t\n\t\n\t/**\n\t* @ngdoc function\n\t* @name angular.merge\n\t* @module ng\n\t* @kind function\n\t*\n\t* @description\n\t* Deeply extends the destination object `dst` by copying own enumerable properties from the `src` object(s)\n\t* to `dst`. You can specify multiple `src` objects. If you want to preserve original objects, you can do so\n\t* by passing an empty object as the target: `var object = angular.merge({}, object1, object2)`.\n\t*\n\t* Unlike {@link angular.extend extend()}, `merge()` recursively descends into object properties of source\n\t* objects, performing a deep copy.\n\t*\n\t* @param {Object} dst Destination object.\n\t* @param {...Object} src Source object(s).\n\t* @returns {Object} Reference to `dst`.\n\t*/\n\tfunction merge(dst) {\n\t return baseExtend(dst, slice.call(arguments, 1), true);\n\t}\n\t\n\t\n\t\n\tfunction toInt(str) {\n\t return parseInt(str, 10);\n\t}\n\t\n\t\n\tfunction inherit(parent, extra) {\n\t return extend(Object.create(parent), extra);\n\t}\n\t\n\t/**\n\t * @ngdoc function\n\t * @name angular.noop\n\t * @module ng\n\t * @kind function\n\t *\n\t * @description\n\t * A function that performs no operations. This function can be useful when writing code in the\n\t * functional style.\n\t ```js\n\t function foo(callback) {\n\t var result = calculateResult();\n\t (callback || angular.noop)(result);\n\t }\n\t ```\n\t */\n\tfunction noop() {}\n\tnoop.$inject = [];\n\t\n\t\n\t/**\n\t * @ngdoc function\n\t * @name angular.identity\n\t * @module ng\n\t * @kind function\n\t *\n\t * @description\n\t * A function that returns its first argument. This function is useful when writing code in the\n\t * functional style.\n\t *\n\t ```js\n\t function transformer(transformationFn, value) {\n\t return (transformationFn || angular.identity)(value);\n\t };\n\t\n\t // E.g.\n\t function getResult(fn, input) {\n\t return (fn || angular.identity)(input);\n\t };\n\t\n\t getResult(function(n) { return n * 2; }, 21); // returns 42\n\t getResult(null, 21); // returns 21\n\t getResult(undefined, 21); // returns 21\n\t ```\n\t *\n\t * @param {*} value to be returned.\n\t * @returns {*} the value passed in.\n\t */\n\tfunction identity($) {return $;}\n\tidentity.$inject = [];\n\t\n\t\n\tfunction valueFn(value) {return function() {return value;};}\n\t\n\tfunction hasCustomToString(obj) {\n\t return isFunction(obj.toString) && obj.toString !== toString;\n\t}\n\t\n\t\n\t/**\n\t * @ngdoc function\n\t * @name angular.isUndefined\n\t * @module ng\n\t * @kind function\n\t *\n\t * @description\n\t * Determines if a reference is undefined.\n\t *\n\t * @param {*} value Reference to check.\n\t * @returns {boolean} True if `value` is undefined.\n\t */\n\tfunction isUndefined(value) {return typeof value === 'undefined';}\n\t\n\t\n\t/**\n\t * @ngdoc function\n\t * @name angular.isDefined\n\t * @module ng\n\t * @kind function\n\t *\n\t * @description\n\t * Determines if a reference is defined.\n\t *\n\t * @param {*} value Reference to check.\n\t * @returns {boolean} True if `value` is defined.\n\t */\n\tfunction isDefined(value) {return typeof value !== 'undefined';}\n\t\n\t\n\t/**\n\t * @ngdoc function\n\t * @name angular.isObject\n\t * @module ng\n\t * @kind function\n\t *\n\t * @description\n\t * Determines if a reference is an `Object`. Unlike `typeof` in JavaScript, `null`s are not\n\t * considered to be objects. Note that JavaScript arrays are objects.\n\t *\n\t * @param {*} value Reference to check.\n\t * @returns {boolean} True if `value` is an `Object` but not `null`.\n\t */\n\tfunction isObject(value) {\n\t // http://jsperf.com/isobject4\n\t return value !== null && typeof value === 'object';\n\t}\n\t\n\t\n\t/**\n\t * Determine if a value is an object with a null prototype\n\t *\n\t * @returns {boolean} True if `value` is an `Object` with a null prototype\n\t */\n\tfunction isBlankObject(value) {\n\t return value !== null && typeof value === 'object' && !getPrototypeOf(value);\n\t}\n\t\n\t\n\t/**\n\t * @ngdoc function\n\t * @name angular.isString\n\t * @module ng\n\t * @kind function\n\t *\n\t * @description\n\t * Determines if a reference is a `String`.\n\t *\n\t * @param {*} value Reference to check.\n\t * @returns {boolean} True if `value` is a `String`.\n\t */\n\tfunction isString(value) {return typeof value === 'string';}\n\t\n\t\n\t/**\n\t * @ngdoc function\n\t * @name angular.isNumber\n\t * @module ng\n\t * @kind function\n\t *\n\t * @description\n\t * Determines if a reference is a `Number`.\n\t *\n\t * This includes the \"special\" numbers `NaN`, `+Infinity` and `-Infinity`.\n\t *\n\t * If you wish to exclude these then you can use the native\n\t * [`isFinite'](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/isFinite)\n\t * method.\n\t *\n\t * @param {*} value Reference to check.\n\t * @returns {boolean} True if `value` is a `Number`.\n\t */\n\tfunction isNumber(value) {return typeof value === 'number';}\n\t\n\t\n\t/**\n\t * @ngdoc function\n\t * @name angular.isDate\n\t * @module ng\n\t * @kind function\n\t *\n\t * @description\n\t * Determines if a value is a date.\n\t *\n\t * @param {*} value Reference to check.\n\t * @returns {boolean} True if `value` is a `Date`.\n\t */\n\tfunction isDate(value) {\n\t return toString.call(value) === '[object Date]';\n\t}\n\t\n\t\n\t/**\n\t * @ngdoc function\n\t * @name angular.isArray\n\t * @module ng\n\t * @kind function\n\t *\n\t * @description\n\t * Determines if a reference is an `Array`.\n\t *\n\t * @param {*} value Reference to check.\n\t * @returns {boolean} True if `value` is an `Array`.\n\t */\n\tvar isArray = Array.isArray;\n\t\n\t/**\n\t * @ngdoc function\n\t * @name angular.isFunction\n\t * @module ng\n\t * @kind function\n\t *\n\t * @description\n\t * Determines if a reference is a `Function`.\n\t *\n\t * @param {*} value Reference to check.\n\t * @returns {boolean} True if `value` is a `Function`.\n\t */\n\tfunction isFunction(value) {return typeof value === 'function';}\n\t\n\t\n\t/**\n\t * Determines if a value is a regular expression object.\n\t *\n\t * @private\n\t * @param {*} value Reference to check.\n\t * @returns {boolean} True if `value` is a `RegExp`.\n\t */\n\tfunction isRegExp(value) {\n\t return toString.call(value) === '[object RegExp]';\n\t}\n\t\n\t\n\t/**\n\t * Checks if `obj` is a window object.\n\t *\n\t * @private\n\t * @param {*} obj Object to check\n\t * @returns {boolean} True if `obj` is a window obj.\n\t */\n\tfunction isWindow(obj) {\n\t return obj && obj.window === obj;\n\t}\n\t\n\t\n\tfunction isScope(obj) {\n\t return obj && obj.$evalAsync && obj.$watch;\n\t}\n\t\n\t\n\tfunction isFile(obj) {\n\t return toString.call(obj) === '[object File]';\n\t}\n\t\n\t\n\tfunction isFormData(obj) {\n\t return toString.call(obj) === '[object FormData]';\n\t}\n\t\n\t\n\tfunction isBlob(obj) {\n\t return toString.call(obj) === '[object Blob]';\n\t}\n\t\n\t\n\tfunction isBoolean(value) {\n\t return typeof value === 'boolean';\n\t}\n\t\n\t\n\tfunction isPromiseLike(obj) {\n\t return obj && isFunction(obj.then);\n\t}\n\t\n\t\n\tvar TYPED_ARRAY_REGEXP = /^\\[object (?:Uint8|Uint8Clamped|Uint16|Uint32|Int8|Int16|Int32|Float32|Float64)Array\\]$/;\n\tfunction isTypedArray(value) {\n\t return value && isNumber(value.length) && TYPED_ARRAY_REGEXP.test(toString.call(value));\n\t}\n\t\n\t\n\tvar trim = function(value) {\n\t return isString(value) ? value.trim() : value;\n\t};\n\t\n\t// Copied from:\n\t// http://docs.closure-library.googlecode.com/git/local_closure_goog_string_string.js.source.html#line1021\n\t// Prereq: s is a string.\n\tvar escapeForRegexp = function(s) {\n\t return s.replace(/([-()\\[\\]{}+?*.$\\^|,:#= 0) {\n\t array.splice(index, 1);\n\t }\n\t return index;\n\t}\n\t\n\t/**\n\t * @ngdoc function\n\t * @name angular.copy\n\t * @module ng\n\t * @kind function\n\t *\n\t * @description\n\t * Creates a deep copy of `source`, which should be an object or an array.\n\t *\n\t * * If no destination is supplied, a copy of the object or array is created.\n\t * * If a destination is provided, all of its elements (for arrays) or properties (for objects)\n\t * are deleted and then all elements/properties from the source are copied to it.\n\t * * If `source` is not an object or array (inc. `null` and `undefined`), `source` is returned.\n\t * * If `source` is identical to 'destination' an exception will be thrown.\n\t *\n\t * @param {*} source The source that will be used to make a copy.\n\t * Can be any type, including primitives, `null`, and `undefined`.\n\t * @param {(Object|Array)=} destination Destination into which the source is copied. If\n\t * provided, must be of the same type as `source`.\n\t * @returns {*} The copy or updated `destination`, if `destination` was specified.\n\t *\n\t * @example\n\t \n\t \n\t
\n\t
\n\t Name:
\n\t E-mail:
\n\t Gender: male\n\t female
\n\t \n\t \n\t
\n\t
form = {{user | json}}
\n\t
master = {{master | json}}
\n\t
\n\t\n\t \n\t
\n\t
\n\t */\n\tfunction copy(source, destination) {\n\t var stackSource = [];\n\t var stackDest = [];\n\t\n\t if (destination) {\n\t if (isTypedArray(destination)) {\n\t throw ngMinErr('cpta', \"Can't copy! TypedArray destination cannot be mutated.\");\n\t }\n\t if (source === destination) {\n\t throw ngMinErr('cpi', \"Can't copy! Source and destination are identical.\");\n\t }\n\t\n\t // Empty the destination object\n\t if (isArray(destination)) {\n\t destination.length = 0;\n\t } else {\n\t forEach(destination, function(value, key) {\n\t if (key !== '$$hashKey') {\n\t delete destination[key];\n\t }\n\t });\n\t }\n\t\n\t stackSource.push(source);\n\t stackDest.push(destination);\n\t return copyRecurse(source, destination);\n\t }\n\t\n\t return copyElement(source);\n\t\n\t function copyRecurse(source, destination) {\n\t var h = destination.$$hashKey;\n\t var result, key;\n\t if (isArray(source)) {\n\t for (var i = 0, ii = source.length; i < ii; i++) {\n\t destination.push(copyElement(source[i]));\n\t }\n\t } else if (isBlankObject(source)) {\n\t // createMap() fast path --- Safe to avoid hasOwnProperty check because prototype chain is empty\n\t for (key in source) {\n\t destination[key] = copyElement(source[key]);\n\t }\n\t } else if (source && typeof source.hasOwnProperty === 'function') {\n\t // Slow path, which must rely on hasOwnProperty\n\t for (key in source) {\n\t if (source.hasOwnProperty(key)) {\n\t destination[key] = copyElement(source[key]);\n\t }\n\t }\n\t } else {\n\t // Slowest path --- hasOwnProperty can't be called as a method\n\t for (key in source) {\n\t if (hasOwnProperty.call(source, key)) {\n\t destination[key] = copyElement(source[key]);\n\t }\n\t }\n\t }\n\t setHashKey(destination, h);\n\t return destination;\n\t }\n\t\n\t function copyElement(source) {\n\t // Simple values\n\t if (!isObject(source)) {\n\t return source;\n\t }\n\t\n\t // Already copied values\n\t var index = stackSource.indexOf(source);\n\t if (index !== -1) {\n\t return stackDest[index];\n\t }\n\t\n\t if (isWindow(source) || isScope(source)) {\n\t throw ngMinErr('cpws',\n\t \"Can't copy! Making copies of Window or Scope instances is not supported.\");\n\t }\n\t\n\t var needsRecurse = false;\n\t var destination;\n\t\n\t if (isArray(source)) {\n\t destination = [];\n\t needsRecurse = true;\n\t } else if (isTypedArray(source)) {\n\t destination = new source.constructor(source);\n\t } else if (isDate(source)) {\n\t destination = new Date(source.getTime());\n\t } else if (isRegExp(source)) {\n\t destination = new RegExp(source.source, source.toString().match(/[^\\/]*$/)[0]);\n\t destination.lastIndex = source.lastIndex;\n\t } else if (isBlob(source)) {\n\t destination = new source.constructor([source], {type: source.type});\n\t } else if (isFunction(source.cloneNode)) {\n\t destination = source.cloneNode(true);\n\t } else {\n\t destination = Object.create(getPrototypeOf(source));\n\t needsRecurse = true;\n\t }\n\t\n\t stackSource.push(source);\n\t stackDest.push(destination);\n\t\n\t return needsRecurse\n\t ? copyRecurse(source, destination)\n\t : destination;\n\t }\n\t}\n\t\n\t/**\n\t * Creates a shallow copy of an object, an array or a primitive.\n\t *\n\t * Assumes that there are no proto properties for objects.\n\t */\n\tfunction shallowCopy(src, dst) {\n\t if (isArray(src)) {\n\t dst = dst || [];\n\t\n\t for (var i = 0, ii = src.length; i < ii; i++) {\n\t dst[i] = src[i];\n\t }\n\t } else if (isObject(src)) {\n\t dst = dst || {};\n\t\n\t for (var key in src) {\n\t if (!(key.charAt(0) === '$' && key.charAt(1) === '$')) {\n\t dst[key] = src[key];\n\t }\n\t }\n\t }\n\t\n\t return dst || src;\n\t}\n\t\n\t\n\t/**\n\t * @ngdoc function\n\t * @name angular.equals\n\t * @module ng\n\t * @kind function\n\t *\n\t * @description\n\t * Determines if two objects or two values are equivalent. Supports value types, regular\n\t * expressions, arrays and objects.\n\t *\n\t * Two objects or values are considered equivalent if at least one of the following is true:\n\t *\n\t * * Both objects or values pass `===` comparison.\n\t * * Both objects or values are of the same type and all of their properties are equal by\n\t * comparing them with `angular.equals`.\n\t * * Both values are NaN. (In JavaScript, NaN == NaN => false. But we consider two NaN as equal)\n\t * * Both values represent the same regular expression (In JavaScript,\n\t * /abc/ == /abc/ => false. But we consider two regular expressions as equal when their textual\n\t * representation matches).\n\t *\n\t * During a property comparison, properties of `function` type and properties with names\n\t * that begin with `$` are ignored.\n\t *\n\t * Scope and DOMWindow objects are being compared only by identify (`===`).\n\t *\n\t * @param {*} o1 Object or value to compare.\n\t * @param {*} o2 Object or value to compare.\n\t * @returns {boolean} True if arguments are equal.\n\t */\n\tfunction equals(o1, o2) {\n\t if (o1 === o2) return true;\n\t if (o1 === null || o2 === null) return false;\n\t if (o1 !== o1 && o2 !== o2) return true; // NaN === NaN\n\t var t1 = typeof o1, t2 = typeof o2, length, key, keySet;\n\t if (t1 == t2) {\n\t if (t1 == 'object') {\n\t if (isArray(o1)) {\n\t if (!isArray(o2)) return false;\n\t if ((length = o1.length) == o2.length) {\n\t for (key = 0; key < length; key++) {\n\t if (!equals(o1[key], o2[key])) return false;\n\t }\n\t return true;\n\t }\n\t } else if (isDate(o1)) {\n\t if (!isDate(o2)) return false;\n\t return equals(o1.getTime(), o2.getTime());\n\t } else if (isRegExp(o1)) {\n\t return isRegExp(o2) ? o1.toString() == o2.toString() : false;\n\t } else {\n\t if (isScope(o1) || isScope(o2) || isWindow(o1) || isWindow(o2) ||\n\t isArray(o2) || isDate(o2) || isRegExp(o2)) return false;\n\t keySet = createMap();\n\t for (key in o1) {\n\t if (key.charAt(0) === '$' || isFunction(o1[key])) continue;\n\t if (!equals(o1[key], o2[key])) return false;\n\t keySet[key] = true;\n\t }\n\t for (key in o2) {\n\t if (!(key in keySet) &&\n\t key.charAt(0) !== '$' &&\n\t isDefined(o2[key]) &&\n\t !isFunction(o2[key])) return false;\n\t }\n\t return true;\n\t }\n\t }\n\t }\n\t return false;\n\t}\n\t\n\tvar csp = function() {\n\t if (!isDefined(csp.rules)) {\n\t\n\t\n\t var ngCspElement = (document.querySelector('[ng-csp]') ||\n\t document.querySelector('[data-ng-csp]'));\n\t\n\t if (ngCspElement) {\n\t var ngCspAttribute = ngCspElement.getAttribute('ng-csp') ||\n\t ngCspElement.getAttribute('data-ng-csp');\n\t csp.rules = {\n\t noUnsafeEval: !ngCspAttribute || (ngCspAttribute.indexOf('no-unsafe-eval') !== -1),\n\t noInlineStyle: !ngCspAttribute || (ngCspAttribute.indexOf('no-inline-style') !== -1)\n\t };\n\t } else {\n\t csp.rules = {\n\t noUnsafeEval: noUnsafeEval(),\n\t noInlineStyle: false\n\t };\n\t }\n\t }\n\t\n\t return csp.rules;\n\t\n\t function noUnsafeEval() {\n\t try {\n\t /* jshint -W031, -W054 */\n\t new Function('');\n\t /* jshint +W031, +W054 */\n\t return false;\n\t } catch (e) {\n\t return true;\n\t }\n\t }\n\t};\n\t\n\t/**\n\t * @ngdoc directive\n\t * @module ng\n\t * @name ngJq\n\t *\n\t * @element ANY\n\t * @param {string=} ngJq the name of the library available under `window`\n\t * to be used for angular.element\n\t * @description\n\t * Use this directive to force the angular.element library. This should be\n\t * used to force either jqLite by leaving ng-jq blank or setting the name of\n\t * the jquery variable under window (eg. jQuery).\n\t *\n\t * Since angular looks for this directive when it is loaded (doesn't wait for the\n\t * DOMContentLoaded event), it must be placed on an element that comes before the script\n\t * which loads angular. Also, only the first instance of `ng-jq` will be used and all\n\t * others ignored.\n\t *\n\t * @example\n\t * This example shows how to force jqLite using the `ngJq` directive to the `html` tag.\n\t ```html\n\t \n\t \n\t ...\n\t ...\n\t \n\t ```\n\t * @example\n\t * This example shows how to use a jQuery based library of a different name.\n\t * The library name must be available at the top most 'window'.\n\t ```html\n\t \n\t \n\t ...\n\t ...\n\t \n\t ```\n\t */\n\tvar jq = function() {\n\t if (isDefined(jq.name_)) return jq.name_;\n\t var el;\n\t var i, ii = ngAttrPrefixes.length, prefix, name;\n\t for (i = 0; i < ii; ++i) {\n\t prefix = ngAttrPrefixes[i];\n\t if (el = document.querySelector('[' + prefix.replace(':', '\\\\:') + 'jq]')) {\n\t name = el.getAttribute(prefix + 'jq');\n\t break;\n\t }\n\t }\n\t\n\t return (jq.name_ = name);\n\t};\n\t\n\tfunction concat(array1, array2, index) {\n\t return array1.concat(slice.call(array2, index));\n\t}\n\t\n\tfunction sliceArgs(args, startIndex) {\n\t return slice.call(args, startIndex || 0);\n\t}\n\t\n\t\n\t/* jshint -W101 */\n\t/**\n\t * @ngdoc function\n\t * @name angular.bind\n\t * @module ng\n\t * @kind function\n\t *\n\t * @description\n\t * Returns a function which calls function `fn` bound to `self` (`self` becomes the `this` for\n\t * `fn`). You can supply optional `args` that are prebound to the function. This feature is also\n\t * known as [partial application](http://en.wikipedia.org/wiki/Partial_application), as\n\t * distinguished from [function currying](http://en.wikipedia.org/wiki/Currying#Contrast_with_partial_function_application).\n\t *\n\t * @param {Object} self Context which `fn` should be evaluated in.\n\t * @param {function()} fn Function to be bound.\n\t * @param {...*} args Optional arguments to be prebound to the `fn` function call.\n\t * @returns {function()} Function that wraps the `fn` with all the specified bindings.\n\t */\n\t/* jshint +W101 */\n\tfunction bind(self, fn) {\n\t var curryArgs = arguments.length > 2 ? sliceArgs(arguments, 2) : [];\n\t if (isFunction(fn) && !(fn instanceof RegExp)) {\n\t return curryArgs.length\n\t ? function() {\n\t return arguments.length\n\t ? fn.apply(self, concat(curryArgs, arguments, 0))\n\t : fn.apply(self, curryArgs);\n\t }\n\t : function() {\n\t return arguments.length\n\t ? fn.apply(self, arguments)\n\t : fn.call(self);\n\t };\n\t } else {\n\t // in IE, native methods are not functions so they cannot be bound (note: they don't need to be)\n\t return fn;\n\t }\n\t}\n\t\n\t\n\tfunction toJsonReplacer(key, value) {\n\t var val = value;\n\t\n\t if (typeof key === 'string' && key.charAt(0) === '$' && key.charAt(1) === '$') {\n\t val = undefined;\n\t } else if (isWindow(value)) {\n\t val = '$WINDOW';\n\t } else if (value && document === value) {\n\t val = '$DOCUMENT';\n\t } else if (isScope(value)) {\n\t val = '$SCOPE';\n\t }\n\t\n\t return val;\n\t}\n\t\n\t\n\t/**\n\t * @ngdoc function\n\t * @name angular.toJson\n\t * @module ng\n\t * @kind function\n\t *\n\t * @description\n\t * Serializes input into a JSON-formatted string. Properties with leading $$ characters will be\n\t * stripped since angular uses this notation internally.\n\t *\n\t * @param {Object|Array|Date|string|number} obj Input to be serialized into JSON.\n\t * @param {boolean|number} [pretty=2] If set to true, the JSON output will contain newlines and whitespace.\n\t * If set to an integer, the JSON output will contain that many spaces per indentation.\n\t * @returns {string|undefined} JSON-ified string representing `obj`.\n\t */\n\tfunction toJson(obj, pretty) {\n\t if (isUndefined(obj)) return undefined;\n\t if (!isNumber(pretty)) {\n\t pretty = pretty ? 2 : null;\n\t }\n\t return JSON.stringify(obj, toJsonReplacer, pretty);\n\t}\n\t\n\t\n\t/**\n\t * @ngdoc function\n\t * @name angular.fromJson\n\t * @module ng\n\t * @kind function\n\t *\n\t * @description\n\t * Deserializes a JSON string.\n\t *\n\t * @param {string} json JSON string to deserialize.\n\t * @returns {Object|Array|string|number} Deserialized JSON string.\n\t */\n\tfunction fromJson(json) {\n\t return isString(json)\n\t ? JSON.parse(json)\n\t : json;\n\t}\n\t\n\t\n\tvar ALL_COLONS = /:/g;\n\tfunction timezoneToOffset(timezone, fallback) {\n\t // IE/Edge do not \"understand\" colon (`:`) in timezone\n\t timezone = timezone.replace(ALL_COLONS, '');\n\t var requestedTimezoneOffset = Date.parse('Jan 01, 1970 00:00:00 ' + timezone) / 60000;\n\t return isNaN(requestedTimezoneOffset) ? fallback : requestedTimezoneOffset;\n\t}\n\t\n\t\n\tfunction addDateMinutes(date, minutes) {\n\t date = new Date(date.getTime());\n\t date.setMinutes(date.getMinutes() + minutes);\n\t return date;\n\t}\n\t\n\t\n\tfunction convertTimezoneToLocal(date, timezone, reverse) {\n\t reverse = reverse ? -1 : 1;\n\t var dateTimezoneOffset = date.getTimezoneOffset();\n\t var timezoneOffset = timezoneToOffset(timezone, dateTimezoneOffset);\n\t return addDateMinutes(date, reverse * (timezoneOffset - dateTimezoneOffset));\n\t}\n\t\n\t\n\t/**\n\t * @returns {string} Returns the string representation of the element.\n\t */\n\tfunction startingTag(element) {\n\t element = jqLite(element).clone();\n\t try {\n\t // turns out IE does not let you set .html() on elements which\n\t // are not allowed to have children. So we just ignore it.\n\t element.empty();\n\t } catch (e) {}\n\t var elemHtml = jqLite('
').append(element).html();\n\t try {\n\t return element[0].nodeType === NODE_TYPE_TEXT ? lowercase(elemHtml) :\n\t elemHtml.\n\t match(/^(<[^>]+>)/)[1].\n\t replace(/^<([\\w\\-]+)/, function(match, nodeName) {return '<' + lowercase(nodeName);});\n\t } catch (e) {\n\t return lowercase(elemHtml);\n\t }\n\t\n\t}\n\t\n\t\n\t/////////////////////////////////////////////////\n\t\n\t/**\n\t * Tries to decode the URI component without throwing an exception.\n\t *\n\t * @private\n\t * @param str value potential URI component to check.\n\t * @returns {boolean} True if `value` can be decoded\n\t * with the decodeURIComponent function.\n\t */\n\tfunction tryDecodeURIComponent(value) {\n\t try {\n\t return decodeURIComponent(value);\n\t } catch (e) {\n\t // Ignore any invalid uri component\n\t }\n\t}\n\t\n\t\n\t/**\n\t * Parses an escaped url query string into key-value pairs.\n\t * @returns {Object.}\n\t */\n\tfunction parseKeyValue(/**string*/keyValue) {\n\t var obj = {};\n\t forEach((keyValue || \"\").split('&'), function(keyValue) {\n\t var splitPoint, key, val;\n\t if (keyValue) {\n\t key = keyValue = keyValue.replace(/\\+/g,'%20');\n\t splitPoint = keyValue.indexOf('=');\n\t if (splitPoint !== -1) {\n\t key = keyValue.substring(0, splitPoint);\n\t val = keyValue.substring(splitPoint + 1);\n\t }\n\t key = tryDecodeURIComponent(key);\n\t if (isDefined(key)) {\n\t val = isDefined(val) ? tryDecodeURIComponent(val) : true;\n\t if (!hasOwnProperty.call(obj, key)) {\n\t obj[key] = val;\n\t } else if (isArray(obj[key])) {\n\t obj[key].push(val);\n\t } else {\n\t obj[key] = [obj[key],val];\n\t }\n\t }\n\t }\n\t });\n\t return obj;\n\t}\n\t\n\tfunction toKeyValue(obj) {\n\t var parts = [];\n\t forEach(obj, function(value, key) {\n\t if (isArray(value)) {\n\t forEach(value, function(arrayValue) {\n\t parts.push(encodeUriQuery(key, true) +\n\t (arrayValue === true ? '' : '=' + encodeUriQuery(arrayValue, true)));\n\t });\n\t } else {\n\t parts.push(encodeUriQuery(key, true) +\n\t (value === true ? '' : '=' + encodeUriQuery(value, true)));\n\t }\n\t });\n\t return parts.length ? parts.join('&') : '';\n\t}\n\t\n\t\n\t/**\n\t * We need our custom method because encodeURIComponent is too aggressive and doesn't follow\n\t * http://www.ietf.org/rfc/rfc3986.txt with regards to the character set (pchar) allowed in path\n\t * segments:\n\t * segment = *pchar\n\t * pchar = unreserved / pct-encoded / sub-delims / \":\" / \"@\"\n\t * pct-encoded = \"%\" HEXDIG HEXDIG\n\t * unreserved = ALPHA / DIGIT / \"-\" / \".\" / \"_\" / \"~\"\n\t * sub-delims = \"!\" / \"$\" / \"&\" / \"'\" / \"(\" / \")\"\n\t * / \"*\" / \"+\" / \",\" / \";\" / \"=\"\n\t */\n\tfunction encodeUriSegment(val) {\n\t return encodeUriQuery(val, true).\n\t replace(/%26/gi, '&').\n\t replace(/%3D/gi, '=').\n\t replace(/%2B/gi, '+');\n\t}\n\t\n\t\n\t/**\n\t * This method is intended for encoding *key* or *value* parts of query component. We need a custom\n\t * method because encodeURIComponent is too aggressive and encodes stuff that doesn't have to be\n\t * encoded per http://tools.ietf.org/html/rfc3986:\n\t * query = *( pchar / \"/\" / \"?\" )\n\t * pchar = unreserved / pct-encoded / sub-delims / \":\" / \"@\"\n\t * unreserved = ALPHA / DIGIT / \"-\" / \".\" / \"_\" / \"~\"\n\t * pct-encoded = \"%\" HEXDIG HEXDIG\n\t * sub-delims = \"!\" / \"$\" / \"&\" / \"'\" / \"(\" / \")\"\n\t * / \"*\" / \"+\" / \",\" / \";\" / \"=\"\n\t */\n\tfunction encodeUriQuery(val, pctEncodeSpaces) {\n\t return encodeURIComponent(val).\n\t replace(/%40/gi, '@').\n\t replace(/%3A/gi, ':').\n\t replace(/%24/g, '$').\n\t replace(/%2C/gi, ',').\n\t replace(/%3B/gi, ';').\n\t replace(/%20/g, (pctEncodeSpaces ? '%20' : '+'));\n\t}\n\t\n\tvar ngAttrPrefixes = ['ng-', 'data-ng-', 'ng:', 'x-ng-'];\n\t\n\tfunction getNgAttribute(element, ngAttr) {\n\t var attr, i, ii = ngAttrPrefixes.length;\n\t for (i = 0; i < ii; ++i) {\n\t attr = ngAttrPrefixes[i] + ngAttr;\n\t if (isString(attr = element.getAttribute(attr))) {\n\t return attr;\n\t }\n\t }\n\t return null;\n\t}\n\t\n\t/**\n\t * @ngdoc directive\n\t * @name ngApp\n\t * @module ng\n\t *\n\t * @element ANY\n\t * @param {angular.Module} ngApp an optional application\n\t * {@link angular.module module} name to load.\n\t * @param {boolean=} ngStrictDi if this attribute is present on the app element, the injector will be\n\t * created in \"strict-di\" mode. This means that the application will fail to invoke functions which\n\t * do not use explicit function annotation (and are thus unsuitable for minification), as described\n\t * in {@link guide/di the Dependency Injection guide}, and useful debugging info will assist in\n\t * tracking down the root of these bugs.\n\t *\n\t * @description\n\t *\n\t * Use this directive to **auto-bootstrap** an AngularJS application. The `ngApp` directive\n\t * designates the **root element** of the application and is typically placed near the root element\n\t * of the page - e.g. on the `` or `` tags.\n\t *\n\t * Only one AngularJS application can be auto-bootstrapped per HTML document. The first `ngApp`\n\t * found in the document will be used to define the root element to auto-bootstrap as an\n\t * application. To run multiple applications in an HTML document you must manually bootstrap them using\n\t * {@link angular.bootstrap} instead. AngularJS applications cannot be nested within each other.\n\t *\n\t * You can specify an **AngularJS module** to be used as the root module for the application. This\n\t * module will be loaded into the {@link auto.$injector} when the application is bootstrapped. It\n\t * should contain the application code needed or have dependencies on other modules that will\n\t * contain the code. See {@link angular.module} for more information.\n\t *\n\t * In the example below if the `ngApp` directive were not placed on the `html` element then the\n\t * document would not be compiled, the `AppController` would not be instantiated and the `{{ a+b }}`\n\t * would not be resolved to `3`.\n\t *\n\t * `ngApp` is the easiest, and most common way to bootstrap an application.\n\t *\n\t \n\t \n\t
\n\t I can add: {{a}} + {{b}} = {{ a+b }}\n\t
\n\t
\n\t \n\t angular.module('ngAppDemo', []).controller('ngAppDemoController', function($scope) {\n\t $scope.a = 1;\n\t $scope.b = 2;\n\t });\n\t \n\t
\n\t *\n\t * Using `ngStrictDi`, you would see something like this:\n\t *\n\t \n\t \n\t
\n\t
\n\t I can add: {{a}} + {{b}} = {{ a+b }}\n\t\n\t

This renders because the controller does not fail to\n\t instantiate, by using explicit annotation style (see\n\t script.js for details)\n\t

\n\t
\n\t\n\t
\n\t Name:
\n\t Hello, {{name}}!\n\t\n\t

This renders because the controller does not fail to\n\t instantiate, by using explicit annotation style\n\t (see script.js for details)\n\t

\n\t
\n\t\n\t
\n\t I can add: {{a}} + {{b}} = {{ a+b }}\n\t\n\t

The controller could not be instantiated, due to relying\n\t on automatic function annotations (which are disabled in\n\t strict mode). As such, the content of this section is not\n\t interpolated, and there should be an error in your web console.\n\t

\n\t
\n\t
\n\t
\n\t \n\t angular.module('ngAppStrictDemo', [])\n\t // BadController will fail to instantiate, due to relying on automatic function annotation,\n\t // rather than an explicit annotation\n\t .controller('BadController', function($scope) {\n\t $scope.a = 1;\n\t $scope.b = 2;\n\t })\n\t // Unlike BadController, GoodController1 and GoodController2 will not fail to be instantiated,\n\t // due to using explicit annotations using the array style and $inject property, respectively.\n\t .controller('GoodController1', ['$scope', function($scope) {\n\t $scope.a = 1;\n\t $scope.b = 2;\n\t }])\n\t .controller('GoodController2', GoodController2);\n\t function GoodController2($scope) {\n\t $scope.name = \"World\";\n\t }\n\t GoodController2.$inject = ['$scope'];\n\t \n\t \n\t div[ng-controller] {\n\t margin-bottom: 1em;\n\t -webkit-border-radius: 4px;\n\t border-radius: 4px;\n\t border: 1px solid;\n\t padding: .5em;\n\t }\n\t div[ng-controller^=Good] {\n\t border-color: #d6e9c6;\n\t background-color: #dff0d8;\n\t color: #3c763d;\n\t }\n\t div[ng-controller^=Bad] {\n\t border-color: #ebccd1;\n\t background-color: #f2dede;\n\t color: #a94442;\n\t margin-bottom: 0;\n\t }\n\t \n\t
\n\t */\n\tfunction angularInit(element, bootstrap) {\n\t var appElement,\n\t module,\n\t config = {};\n\t\n\t // The element `element` has priority over any other element\n\t forEach(ngAttrPrefixes, function(prefix) {\n\t var name = prefix + 'app';\n\t\n\t if (!appElement && element.hasAttribute && element.hasAttribute(name)) {\n\t appElement = element;\n\t module = element.getAttribute(name);\n\t }\n\t });\n\t forEach(ngAttrPrefixes, function(prefix) {\n\t var name = prefix + 'app';\n\t var candidate;\n\t\n\t if (!appElement && (candidate = element.querySelector('[' + name.replace(':', '\\\\:') + ']'))) {\n\t appElement = candidate;\n\t module = candidate.getAttribute(name);\n\t }\n\t });\n\t if (appElement) {\n\t config.strictDi = getNgAttribute(appElement, \"strict-di\") !== null;\n\t bootstrap(appElement, module ? [module] : [], config);\n\t }\n\t}\n\t\n\t/**\n\t * @ngdoc function\n\t * @name angular.bootstrap\n\t * @module ng\n\t * @description\n\t * Use this function to manually start up angular application.\n\t *\n\t * See: {@link guide/bootstrap Bootstrap}\n\t *\n\t * Note that Protractor based end-to-end tests cannot use this function to bootstrap manually.\n\t * They must use {@link ng.directive:ngApp ngApp}.\n\t *\n\t * Angular will detect if it has been loaded into the browser more than once and only allow the\n\t * first loaded script to be bootstrapped and will report a warning to the browser console for\n\t * each of the subsequent scripts. This prevents strange results in applications, where otherwise\n\t * multiple instances of Angular try to work on the DOM.\n\t *\n\t * ```html\n\t * \n\t * \n\t * \n\t *
\n\t * {{greeting}}\n\t *
\n\t *\n\t * \n\t * \n\t * \n\t * \n\t * ```\n\t *\n\t * @param {DOMElement} element DOM element which is the root of angular application.\n\t * @param {Array=} modules an array of modules to load into the application.\n\t * Each item in the array should be the name of a predefined module or a (DI annotated)\n\t * function that will be invoked by the injector as a `config` block.\n\t * See: {@link angular.module modules}\n\t * @param {Object=} config an object for defining configuration options for the application. The\n\t * following keys are supported:\n\t *\n\t * * `strictDi` - disable automatic function annotation for the application. This is meant to\n\t * assist in finding bugs which break minified code. Defaults to `false`.\n\t *\n\t * @returns {auto.$injector} Returns the newly created injector for this app.\n\t */\n\tfunction bootstrap(element, modules, config) {\n\t if (!isObject(config)) config = {};\n\t var defaultConfig = {\n\t strictDi: false\n\t };\n\t config = extend(defaultConfig, config);\n\t var doBootstrap = function() {\n\t element = jqLite(element);\n\t\n\t if (element.injector()) {\n\t var tag = (element[0] === document) ? 'document' : startingTag(element);\n\t //Encode angle brackets to prevent input from being sanitized to empty string #8683\n\t throw ngMinErr(\n\t 'btstrpd',\n\t \"App already bootstrapped with this element '{0}'\",\n\t tag.replace(//,'>'));\n\t }\n\t\n\t modules = modules || [];\n\t modules.unshift(['$provide', function($provide) {\n\t $provide.value('$rootElement', element);\n\t }]);\n\t\n\t if (config.debugInfoEnabled) {\n\t // Pushing so that this overrides `debugInfoEnabled` setting defined in user's `modules`.\n\t modules.push(['$compileProvider', function($compileProvider) {\n\t $compileProvider.debugInfoEnabled(true);\n\t }]);\n\t }\n\t\n\t modules.unshift('ng');\n\t var injector = createInjector(modules, config.strictDi);\n\t injector.invoke(['$rootScope', '$rootElement', '$compile', '$injector',\n\t function bootstrapApply(scope, element, compile, injector) {\n\t scope.$apply(function() {\n\t element.data('$injector', injector);\n\t compile(element)(scope);\n\t });\n\t }]\n\t );\n\t return injector;\n\t };\n\t\n\t var NG_ENABLE_DEBUG_INFO = /^NG_ENABLE_DEBUG_INFO!/;\n\t var NG_DEFER_BOOTSTRAP = /^NG_DEFER_BOOTSTRAP!/;\n\t\n\t if (window && NG_ENABLE_DEBUG_INFO.test(window.name)) {\n\t config.debugInfoEnabled = true;\n\t window.name = window.name.replace(NG_ENABLE_DEBUG_INFO, '');\n\t }\n\t\n\t if (window && !NG_DEFER_BOOTSTRAP.test(window.name)) {\n\t return doBootstrap();\n\t }\n\t\n\t window.name = window.name.replace(NG_DEFER_BOOTSTRAP, '');\n\t angular.resumeBootstrap = function(extraModules) {\n\t forEach(extraModules, function(module) {\n\t modules.push(module);\n\t });\n\t return doBootstrap();\n\t };\n\t\n\t if (isFunction(angular.resumeDeferredBootstrap)) {\n\t angular.resumeDeferredBootstrap();\n\t }\n\t}\n\t\n\t/**\n\t * @ngdoc function\n\t * @name angular.reloadWithDebugInfo\n\t * @module ng\n\t * @description\n\t * Use this function to reload the current application with debug information turned on.\n\t * This takes precedence over a call to `$compileProvider.debugInfoEnabled(false)`.\n\t *\n\t * See {@link ng.$compileProvider#debugInfoEnabled} for more.\n\t */\n\tfunction reloadWithDebugInfo() {\n\t window.name = 'NG_ENABLE_DEBUG_INFO!' + window.name;\n\t window.location.reload();\n\t}\n\t\n\t/**\n\t * @name angular.getTestability\n\t * @module ng\n\t * @description\n\t * Get the testability service for the instance of Angular on the given\n\t * element.\n\t * @param {DOMElement} element DOM element which is the root of angular application.\n\t */\n\tfunction getTestability(rootElement) {\n\t var injector = angular.element(rootElement).injector();\n\t if (!injector) {\n\t throw ngMinErr('test',\n\t 'no injector found for element argument to getTestability');\n\t }\n\t return injector.get('$$testability');\n\t}\n\t\n\tvar SNAKE_CASE_REGEXP = /[A-Z]/g;\n\tfunction snake_case(name, separator) {\n\t separator = separator || '_';\n\t return name.replace(SNAKE_CASE_REGEXP, function(letter, pos) {\n\t return (pos ? separator : '') + letter.toLowerCase();\n\t });\n\t}\n\t\n\tvar bindJQueryFired = false;\n\tvar skipDestroyOnNextJQueryCleanData;\n\tfunction bindJQuery() {\n\t var originalCleanData;\n\t\n\t if (bindJQueryFired) {\n\t return;\n\t }\n\t\n\t // bind to jQuery if present;\n\t var jqName = jq();\n\t jQuery = isUndefined(jqName) ? window.jQuery : // use jQuery (if present)\n\t !jqName ? undefined : // use jqLite\n\t window[jqName]; // use jQuery specified by `ngJq`\n\t\n\t // Use jQuery if it exists with proper functionality, otherwise default to us.\n\t // Angular 1.2+ requires jQuery 1.7+ for on()/off() support.\n\t // Angular 1.3+ technically requires at least jQuery 2.1+ but it may work with older\n\t // versions. It will not work for sure with jQuery <1.7, though.\n\t if (jQuery && jQuery.fn.on) {\n\t jqLite = jQuery;\n\t extend(jQuery.fn, {\n\t scope: JQLitePrototype.scope,\n\t isolateScope: JQLitePrototype.isolateScope,\n\t controller: JQLitePrototype.controller,\n\t injector: JQLitePrototype.injector,\n\t inheritedData: JQLitePrototype.inheritedData\n\t });\n\t\n\t // All nodes removed from the DOM via various jQuery APIs like .remove()\n\t // are passed through jQuery.cleanData. Monkey-patch this method to fire\n\t // the $destroy event on all removed nodes.\n\t originalCleanData = jQuery.cleanData;\n\t jQuery.cleanData = function(elems) {\n\t var events;\n\t if (!skipDestroyOnNextJQueryCleanData) {\n\t for (var i = 0, elem; (elem = elems[i]) != null; i++) {\n\t events = jQuery._data(elem, \"events\");\n\t if (events && events.$destroy) {\n\t jQuery(elem).triggerHandler('$destroy');\n\t }\n\t }\n\t } else {\n\t skipDestroyOnNextJQueryCleanData = false;\n\t }\n\t originalCleanData(elems);\n\t };\n\t } else {\n\t jqLite = JQLite;\n\t }\n\t\n\t angular.element = jqLite;\n\t\n\t // Prevent double-proxying.\n\t bindJQueryFired = true;\n\t}\n\t\n\t/**\n\t * throw error if the argument is falsy.\n\t */\n\tfunction assertArg(arg, name, reason) {\n\t if (!arg) {\n\t throw ngMinErr('areq', \"Argument '{0}' is {1}\", (name || '?'), (reason || \"required\"));\n\t }\n\t return arg;\n\t}\n\t\n\tfunction assertArgFn(arg, name, acceptArrayAnnotation) {\n\t if (acceptArrayAnnotation && isArray(arg)) {\n\t arg = arg[arg.length - 1];\n\t }\n\t\n\t assertArg(isFunction(arg), name, 'not a function, got ' +\n\t (arg && typeof arg === 'object' ? arg.constructor.name || 'Object' : typeof arg));\n\t return arg;\n\t}\n\t\n\t/**\n\t * throw error if the name given is hasOwnProperty\n\t * @param {String} name the name to test\n\t * @param {String} context the context in which the name is used, such as module or directive\n\t */\n\tfunction assertNotHasOwnProperty(name, context) {\n\t if (name === 'hasOwnProperty') {\n\t throw ngMinErr('badname', \"hasOwnProperty is not a valid {0} name\", context);\n\t }\n\t}\n\t\n\t/**\n\t * Return the value accessible from the object by path. Any undefined traversals are ignored\n\t * @param {Object} obj starting object\n\t * @param {String} path path to traverse\n\t * @param {boolean} [bindFnToScope=true]\n\t * @returns {Object} value as accessible by path\n\t */\n\t//TODO(misko): this function needs to be removed\n\tfunction getter(obj, path, bindFnToScope) {\n\t if (!path) return obj;\n\t var keys = path.split('.');\n\t var key;\n\t var lastInstance = obj;\n\t var len = keys.length;\n\t\n\t for (var i = 0; i < len; i++) {\n\t key = keys[i];\n\t if (obj) {\n\t obj = (lastInstance = obj)[key];\n\t }\n\t }\n\t if (!bindFnToScope && isFunction(obj)) {\n\t return bind(lastInstance, obj);\n\t }\n\t return obj;\n\t}\n\t\n\t/**\n\t * Return the DOM siblings between the first and last node in the given array.\n\t * @param {Array} array like object\n\t * @returns {Array} the inputted object or a jqLite collection containing the nodes\n\t */\n\tfunction getBlockNodes(nodes) {\n\t // TODO(perf): update `nodes` instead of creating a new object?\n\t var node = nodes[0];\n\t var endNode = nodes[nodes.length - 1];\n\t var blockNodes;\n\t\n\t for (var i = 1; node !== endNode && (node = node.nextSibling); i++) {\n\t if (blockNodes || nodes[i] !== node) {\n\t if (!blockNodes) {\n\t blockNodes = jqLite(slice.call(nodes, 0, i));\n\t }\n\t blockNodes.push(node);\n\t }\n\t }\n\t\n\t return blockNodes || nodes;\n\t}\n\t\n\t\n\t/**\n\t * Creates a new object without a prototype. This object is useful for lookup without having to\n\t * guard against prototypically inherited properties via hasOwnProperty.\n\t *\n\t * Related micro-benchmarks:\n\t * - http://jsperf.com/object-create2\n\t * - http://jsperf.com/proto-map-lookup/2\n\t * - http://jsperf.com/for-in-vs-object-keys2\n\t *\n\t * @returns {Object}\n\t */\n\tfunction createMap() {\n\t return Object.create(null);\n\t}\n\t\n\tvar NODE_TYPE_ELEMENT = 1;\n\tvar NODE_TYPE_ATTRIBUTE = 2;\n\tvar NODE_TYPE_TEXT = 3;\n\tvar NODE_TYPE_COMMENT = 8;\n\tvar NODE_TYPE_DOCUMENT = 9;\n\tvar NODE_TYPE_DOCUMENT_FRAGMENT = 11;\n\t\n\t/**\n\t * @ngdoc type\n\t * @name angular.Module\n\t * @module ng\n\t * @description\n\t *\n\t * Interface for configuring angular {@link angular.module modules}.\n\t */\n\t\n\tfunction setupModuleLoader(window) {\n\t\n\t var $injectorMinErr = minErr('$injector');\n\t var ngMinErr = minErr('ng');\n\t\n\t function ensure(obj, name, factory) {\n\t return obj[name] || (obj[name] = factory());\n\t }\n\t\n\t var angular = ensure(window, 'angular', Object);\n\t\n\t // We need to expose `angular.$$minErr` to modules such as `ngResource` that reference it during bootstrap\n\t angular.$$minErr = angular.$$minErr || minErr;\n\t\n\t return ensure(angular, 'module', function() {\n\t /** @type {Object.} */\n\t var modules = {};\n\t\n\t /**\n\t * @ngdoc function\n\t * @name angular.module\n\t * @module ng\n\t * @description\n\t *\n\t * The `angular.module` is a global place for creating, registering and retrieving Angular\n\t * modules.\n\t * All modules (angular core or 3rd party) that should be available to an application must be\n\t * registered using this mechanism.\n\t *\n\t * Passing one argument retrieves an existing {@link angular.Module},\n\t * whereas passing more than one argument creates a new {@link angular.Module}\n\t *\n\t *\n\t * # Module\n\t *\n\t * A module is a collection of services, directives, controllers, filters, and configuration information.\n\t * `angular.module` is used to configure the {@link auto.$injector $injector}.\n\t *\n\t * ```js\n\t * // Create a new module\n\t * var myModule = angular.module('myModule', []);\n\t *\n\t * // register a new service\n\t * myModule.value('appName', 'MyCoolApp');\n\t *\n\t * // configure existing services inside initialization blocks.\n\t * myModule.config(['$locationProvider', function($locationProvider) {\n\t * // Configure existing providers\n\t * $locationProvider.hashPrefix('!');\n\t * }]);\n\t * ```\n\t *\n\t * Then you can create an injector and load your modules like this:\n\t *\n\t * ```js\n\t * var injector = angular.injector(['ng', 'myModule'])\n\t * ```\n\t *\n\t * However it's more likely that you'll just use\n\t * {@link ng.directive:ngApp ngApp} or\n\t * {@link angular.bootstrap} to simplify this process for you.\n\t *\n\t * @param {!string} name The name of the module to create or retrieve.\n\t * @param {!Array.=} requires If specified then new module is being created. If\n\t * unspecified then the module is being retrieved for further configuration.\n\t * @param {Function=} configFn Optional configuration function for the module. Same as\n\t * {@link angular.Module#config Module#config()}.\n\t * @returns {angular.Module} new module with the {@link angular.Module} api.\n\t */\n\t return function module(name, requires, configFn) {\n\t var assertNotHasOwnProperty = function(name, context) {\n\t if (name === 'hasOwnProperty') {\n\t throw ngMinErr('badname', 'hasOwnProperty is not a valid {0} name', context);\n\t }\n\t };\n\t\n\t assertNotHasOwnProperty(name, 'module');\n\t if (requires && modules.hasOwnProperty(name)) {\n\t modules[name] = null;\n\t }\n\t return ensure(modules, name, function() {\n\t if (!requires) {\n\t throw $injectorMinErr('nomod', \"Module '{0}' is not available! You either misspelled \" +\n\t \"the module name or forgot to load it. If registering a module ensure that you \" +\n\t \"specify the dependencies as the second argument.\", name);\n\t }\n\t\n\t /** @type {!Array.>} */\n\t var invokeQueue = [];\n\t\n\t /** @type {!Array.} */\n\t var configBlocks = [];\n\t\n\t /** @type {!Array.} */\n\t var runBlocks = [];\n\t\n\t var config = invokeLater('$injector', 'invoke', 'push', configBlocks);\n\t\n\t /** @type {angular.Module} */\n\t var moduleInstance = {\n\t // Private state\n\t _invokeQueue: invokeQueue,\n\t _configBlocks: configBlocks,\n\t _runBlocks: runBlocks,\n\t\n\t /**\n\t * @ngdoc property\n\t * @name angular.Module#requires\n\t * @module ng\n\t *\n\t * @description\n\t * Holds the list of modules which the injector will load before the current module is\n\t * loaded.\n\t */\n\t requires: requires,\n\t\n\t /**\n\t * @ngdoc property\n\t * @name angular.Module#name\n\t * @module ng\n\t *\n\t * @description\n\t * Name of the module.\n\t */\n\t name: name,\n\t\n\t\n\t /**\n\t * @ngdoc method\n\t * @name angular.Module#provider\n\t * @module ng\n\t * @param {string} name service name\n\t * @param {Function} providerType Construction function for creating new instance of the\n\t * service.\n\t * @description\n\t * See {@link auto.$provide#provider $provide.provider()}.\n\t */\n\t provider: invokeLaterAndSetModuleName('$provide', 'provider'),\n\t\n\t /**\n\t * @ngdoc method\n\t * @name angular.Module#factory\n\t * @module ng\n\t * @param {string} name service name\n\t * @param {Function} providerFunction Function for creating new instance of the service.\n\t * @description\n\t * See {@link auto.$provide#factory $provide.factory()}.\n\t */\n\t factory: invokeLaterAndSetModuleName('$provide', 'factory'),\n\t\n\t /**\n\t * @ngdoc method\n\t * @name angular.Module#service\n\t * @module ng\n\t * @param {string} name service name\n\t * @param {Function} constructor A constructor function that will be instantiated.\n\t * @description\n\t * See {@link auto.$provide#service $provide.service()}.\n\t */\n\t service: invokeLaterAndSetModuleName('$provide', 'service'),\n\t\n\t /**\n\t * @ngdoc method\n\t * @name angular.Module#value\n\t * @module ng\n\t * @param {string} name service name\n\t * @param {*} object Service instance object.\n\t * @description\n\t * See {@link auto.$provide#value $provide.value()}.\n\t */\n\t value: invokeLater('$provide', 'value'),\n\t\n\t /**\n\t * @ngdoc method\n\t * @name angular.Module#constant\n\t * @module ng\n\t * @param {string} name constant name\n\t * @param {*} object Constant value.\n\t * @description\n\t * Because the constants are fixed, they get applied before other provide methods.\n\t * See {@link auto.$provide#constant $provide.constant()}.\n\t */\n\t constant: invokeLater('$provide', 'constant', 'unshift'),\n\t\n\t /**\n\t * @ngdoc method\n\t * @name angular.Module#decorator\n\t * @module ng\n\t * @param {string} name The name of the service to decorate.\n\t * @param {Function} decorFn This function will be invoked when the service needs to be\n\t * instantiated and should return the decorated service instance.\n\t * @description\n\t * See {@link auto.$provide#decorator $provide.decorator()}.\n\t */\n\t decorator: invokeLaterAndSetModuleName('$provide', 'decorator'),\n\t\n\t /**\n\t * @ngdoc method\n\t * @name angular.Module#animation\n\t * @module ng\n\t * @param {string} name animation name\n\t * @param {Function} animationFactory Factory function for creating new instance of an\n\t * animation.\n\t * @description\n\t *\n\t * **NOTE**: animations take effect only if the **ngAnimate** module is loaded.\n\t *\n\t *\n\t * Defines an animation hook that can be later used with\n\t * {@link $animate $animate} service and directives that use this service.\n\t *\n\t * ```js\n\t * module.animation('.animation-name', function($inject1, $inject2) {\n\t * return {\n\t * eventName : function(element, done) {\n\t * //code to run the animation\n\t * //once complete, then run done()\n\t * return function cancellationFunction(element) {\n\t * //code to cancel the animation\n\t * }\n\t * }\n\t * }\n\t * })\n\t * ```\n\t *\n\t * See {@link ng.$animateProvider#register $animateProvider.register()} and\n\t * {@link ngAnimate ngAnimate module} for more information.\n\t */\n\t animation: invokeLaterAndSetModuleName('$animateProvider', 'register'),\n\t\n\t /**\n\t * @ngdoc method\n\t * @name angular.Module#filter\n\t * @module ng\n\t * @param {string} name Filter name - this must be a valid angular expression identifier\n\t * @param {Function} filterFactory Factory function for creating new instance of filter.\n\t * @description\n\t * See {@link ng.$filterProvider#register $filterProvider.register()}.\n\t *\n\t *
\n\t * **Note:** Filter names must be valid angular {@link expression} identifiers, such as `uppercase` or `orderBy`.\n\t * Names with special characters, such as hyphens and dots, are not allowed. If you wish to namespace\n\t * your filters, then you can use capitalization (`myappSubsectionFilterx`) or underscores\n\t * (`myapp_subsection_filterx`).\n\t *
\n\t */\n\t filter: invokeLaterAndSetModuleName('$filterProvider', 'register'),\n\t\n\t /**\n\t * @ngdoc method\n\t * @name angular.Module#controller\n\t * @module ng\n\t * @param {string|Object} name Controller name, or an object map of controllers where the\n\t * keys are the names and the values are the constructors.\n\t * @param {Function} constructor Controller constructor function.\n\t * @description\n\t * See {@link ng.$controllerProvider#register $controllerProvider.register()}.\n\t */\n\t controller: invokeLaterAndSetModuleName('$controllerProvider', 'register'),\n\t\n\t /**\n\t * @ngdoc method\n\t * @name angular.Module#directive\n\t * @module ng\n\t * @param {string|Object} name Directive name, or an object map of directives where the\n\t * keys are the names and the values are the factories.\n\t * @param {Function} directiveFactory Factory function for creating new instance of\n\t * directives.\n\t * @description\n\t * See {@link ng.$compileProvider#directive $compileProvider.directive()}.\n\t */\n\t directive: invokeLaterAndSetModuleName('$compileProvider', 'directive'),\n\t\n\t /**\n\t * @ngdoc method\n\t * @name angular.Module#config\n\t * @module ng\n\t * @param {Function} configFn Execute this function on module load. Useful for service\n\t * configuration.\n\t * @description\n\t * Use this method to register work which needs to be performed on module loading.\n\t * For more about how to configure services, see\n\t * {@link providers#provider-recipe Provider Recipe}.\n\t */\n\t config: config,\n\t\n\t /**\n\t * @ngdoc method\n\t * @name angular.Module#run\n\t * @module ng\n\t * @param {Function} initializationFn Execute this function after injector creation.\n\t * Useful for application initialization.\n\t * @description\n\t * Use this method to register work which should be performed when the injector is done\n\t * loading all modules.\n\t */\n\t run: function(block) {\n\t runBlocks.push(block);\n\t return this;\n\t }\n\t };\n\t\n\t if (configFn) {\n\t config(configFn);\n\t }\n\t\n\t return moduleInstance;\n\t\n\t /**\n\t * @param {string} provider\n\t * @param {string} method\n\t * @param {String=} insertMethod\n\t * @returns {angular.Module}\n\t */\n\t function invokeLater(provider, method, insertMethod, queue) {\n\t if (!queue) queue = invokeQueue;\n\t return function() {\n\t queue[insertMethod || 'push']([provider, method, arguments]);\n\t return moduleInstance;\n\t };\n\t }\n\t\n\t /**\n\t * @param {string} provider\n\t * @param {string} method\n\t * @returns {angular.Module}\n\t */\n\t function invokeLaterAndSetModuleName(provider, method) {\n\t return function(recipeName, factoryFunction) {\n\t if (factoryFunction && isFunction(factoryFunction)) factoryFunction.$$moduleName = name;\n\t invokeQueue.push([provider, method, arguments]);\n\t return moduleInstance;\n\t };\n\t }\n\t });\n\t };\n\t });\n\t\n\t}\n\t\n\t/* global: toDebugString: true */\n\t\n\tfunction serializeObject(obj) {\n\t var seen = [];\n\t\n\t return JSON.stringify(obj, function(key, val) {\n\t val = toJsonReplacer(key, val);\n\t if (isObject(val)) {\n\t\n\t if (seen.indexOf(val) >= 0) return '...';\n\t\n\t seen.push(val);\n\t }\n\t return val;\n\t });\n\t}\n\t\n\tfunction toDebugString(obj) {\n\t if (typeof obj === 'function') {\n\t return obj.toString().replace(/ \\{[\\s\\S]*$/, '');\n\t } else if (isUndefined(obj)) {\n\t return 'undefined';\n\t } else if (typeof obj !== 'string') {\n\t return serializeObject(obj);\n\t }\n\t return obj;\n\t}\n\t\n\t/* global angularModule: true,\n\t version: true,\n\t\n\t $CompileProvider,\n\t\n\t htmlAnchorDirective,\n\t inputDirective,\n\t inputDirective,\n\t formDirective,\n\t scriptDirective,\n\t selectDirective,\n\t styleDirective,\n\t optionDirective,\n\t ngBindDirective,\n\t ngBindHtmlDirective,\n\t ngBindTemplateDirective,\n\t ngClassDirective,\n\t ngClassEvenDirective,\n\t ngClassOddDirective,\n\t ngCloakDirective,\n\t ngControllerDirective,\n\t ngFormDirective,\n\t ngHideDirective,\n\t ngIfDirective,\n\t ngIncludeDirective,\n\t ngIncludeFillContentDirective,\n\t ngInitDirective,\n\t ngNonBindableDirective,\n\t ngPluralizeDirective,\n\t ngRepeatDirective,\n\t ngShowDirective,\n\t ngStyleDirective,\n\t ngSwitchDirective,\n\t ngSwitchWhenDirective,\n\t ngSwitchDefaultDirective,\n\t ngOptionsDirective,\n\t ngTranscludeDirective,\n\t ngModelDirective,\n\t ngListDirective,\n\t ngChangeDirective,\n\t patternDirective,\n\t patternDirective,\n\t requiredDirective,\n\t requiredDirective,\n\t minlengthDirective,\n\t minlengthDirective,\n\t maxlengthDirective,\n\t maxlengthDirective,\n\t ngValueDirective,\n\t ngModelOptionsDirective,\n\t ngAttributeAliasDirectives,\n\t ngEventDirectives,\n\t\n\t $AnchorScrollProvider,\n\t $AnimateProvider,\n\t $CoreAnimateCssProvider,\n\t $$CoreAnimateJsProvider,\n\t $$CoreAnimateQueueProvider,\n\t $$AnimateRunnerFactoryProvider,\n\t $$AnimateAsyncRunFactoryProvider,\n\t $BrowserProvider,\n\t $CacheFactoryProvider,\n\t $ControllerProvider,\n\t $DocumentProvider,\n\t $ExceptionHandlerProvider,\n\t $FilterProvider,\n\t $$ForceReflowProvider,\n\t $InterpolateProvider,\n\t $IntervalProvider,\n\t $$HashMapProvider,\n\t $HttpProvider,\n\t $HttpParamSerializerProvider,\n\t $HttpParamSerializerJQLikeProvider,\n\t $HttpBackendProvider,\n\t $xhrFactoryProvider,\n\t $LocationProvider,\n\t $LogProvider,\n\t $ParseProvider,\n\t $RootScopeProvider,\n\t $QProvider,\n\t $$QProvider,\n\t $$SanitizeUriProvider,\n\t $SceProvider,\n\t $SceDelegateProvider,\n\t $SnifferProvider,\n\t $TemplateCacheProvider,\n\t $TemplateRequestProvider,\n\t $$TestabilityProvider,\n\t $TimeoutProvider,\n\t $$RAFProvider,\n\t $WindowProvider,\n\t $$jqLiteProvider,\n\t $$CookieReaderProvider\n\t*/\n\t\n\t\n\t/**\n\t * @ngdoc object\n\t * @name angular.version\n\t * @module ng\n\t * @description\n\t * An object that contains information about the current AngularJS version.\n\t *\n\t * This object has the following properties:\n\t *\n\t * - `full` – `{string}` – Full version string, such as \"0.9.18\".\n\t * - `major` – `{number}` – Major version number, such as \"0\".\n\t * - `minor` – `{number}` – Minor version number, such as \"9\".\n\t * - `dot` – `{number}` – Dot version number, such as \"18\".\n\t * - `codeName` – `{string}` – Code name of the release, such as \"jiggling-armfat\".\n\t */\n\tvar version = {\n\t full: '1.4.14', // all of these placeholder strings will be replaced by grunt's\n\t major: 1, // package task\n\t minor: 4,\n\t dot: 14,\n\t codeName: 'material-distinction'\n\t};\n\t\n\t\n\tfunction publishExternalAPI(angular) {\n\t extend(angular, {\n\t 'bootstrap': bootstrap,\n\t 'copy': copy,\n\t 'extend': extend,\n\t 'merge': merge,\n\t 'equals': equals,\n\t 'element': jqLite,\n\t 'forEach': forEach,\n\t 'injector': createInjector,\n\t 'noop': noop,\n\t 'bind': bind,\n\t 'toJson': toJson,\n\t 'fromJson': fromJson,\n\t 'identity': identity,\n\t 'isUndefined': isUndefined,\n\t 'isDefined': isDefined,\n\t 'isString': isString,\n\t 'isFunction': isFunction,\n\t 'isObject': isObject,\n\t 'isNumber': isNumber,\n\t 'isElement': isElement,\n\t 'isArray': isArray,\n\t 'version': version,\n\t 'isDate': isDate,\n\t 'lowercase': lowercase,\n\t 'uppercase': uppercase,\n\t 'callbacks': {counter: 0},\n\t 'getTestability': getTestability,\n\t '$$minErr': minErr,\n\t '$$csp': csp,\n\t 'reloadWithDebugInfo': reloadWithDebugInfo\n\t });\n\t\n\t angularModule = setupModuleLoader(window);\n\t\n\t angularModule('ng', ['ngLocale'], ['$provide',\n\t function ngModule($provide) {\n\t // $$sanitizeUriProvider needs to be before $compileProvider as it is used by it.\n\t $provide.provider({\n\t $$sanitizeUri: $$SanitizeUriProvider\n\t });\n\t $provide.provider('$compile', $CompileProvider).\n\t directive({\n\t a: htmlAnchorDirective,\n\t input: inputDirective,\n\t textarea: inputDirective,\n\t form: formDirective,\n\t script: scriptDirective,\n\t select: selectDirective,\n\t style: styleDirective,\n\t option: optionDirective,\n\t ngBind: ngBindDirective,\n\t ngBindHtml: ngBindHtmlDirective,\n\t ngBindTemplate: ngBindTemplateDirective,\n\t ngClass: ngClassDirective,\n\t ngClassEven: ngClassEvenDirective,\n\t ngClassOdd: ngClassOddDirective,\n\t ngCloak: ngCloakDirective,\n\t ngController: ngControllerDirective,\n\t ngForm: ngFormDirective,\n\t ngHide: ngHideDirective,\n\t ngIf: ngIfDirective,\n\t ngInclude: ngIncludeDirective,\n\t ngInit: ngInitDirective,\n\t ngNonBindable: ngNonBindableDirective,\n\t ngPluralize: ngPluralizeDirective,\n\t ngRepeat: ngRepeatDirective,\n\t ngShow: ngShowDirective,\n\t ngStyle: ngStyleDirective,\n\t ngSwitch: ngSwitchDirective,\n\t ngSwitchWhen: ngSwitchWhenDirective,\n\t ngSwitchDefault: ngSwitchDefaultDirective,\n\t ngOptions: ngOptionsDirective,\n\t ngTransclude: ngTranscludeDirective,\n\t ngModel: ngModelDirective,\n\t ngList: ngListDirective,\n\t ngChange: ngChangeDirective,\n\t pattern: patternDirective,\n\t ngPattern: patternDirective,\n\t required: requiredDirective,\n\t ngRequired: requiredDirective,\n\t minlength: minlengthDirective,\n\t ngMinlength: minlengthDirective,\n\t maxlength: maxlengthDirective,\n\t ngMaxlength: maxlengthDirective,\n\t ngValue: ngValueDirective,\n\t ngModelOptions: ngModelOptionsDirective\n\t }).\n\t directive({\n\t ngInclude: ngIncludeFillContentDirective\n\t }).\n\t directive(ngAttributeAliasDirectives).\n\t directive(ngEventDirectives);\n\t $provide.provider({\n\t $anchorScroll: $AnchorScrollProvider,\n\t $animate: $AnimateProvider,\n\t $animateCss: $CoreAnimateCssProvider,\n\t $$animateJs: $$CoreAnimateJsProvider,\n\t $$animateQueue: $$CoreAnimateQueueProvider,\n\t $$AnimateRunner: $$AnimateRunnerFactoryProvider,\n\t $$animateAsyncRun: $$AnimateAsyncRunFactoryProvider,\n\t $browser: $BrowserProvider,\n\t $cacheFactory: $CacheFactoryProvider,\n\t $controller: $ControllerProvider,\n\t $document: $DocumentProvider,\n\t $exceptionHandler: $ExceptionHandlerProvider,\n\t $filter: $FilterProvider,\n\t $$forceReflow: $$ForceReflowProvider,\n\t $interpolate: $InterpolateProvider,\n\t $interval: $IntervalProvider,\n\t $http: $HttpProvider,\n\t $httpParamSerializer: $HttpParamSerializerProvider,\n\t $httpParamSerializerJQLike: $HttpParamSerializerJQLikeProvider,\n\t $httpBackend: $HttpBackendProvider,\n\t $xhrFactory: $xhrFactoryProvider,\n\t $location: $LocationProvider,\n\t $log: $LogProvider,\n\t $parse: $ParseProvider,\n\t $rootScope: $RootScopeProvider,\n\t $q: $QProvider,\n\t $$q: $$QProvider,\n\t $sce: $SceProvider,\n\t $sceDelegate: $SceDelegateProvider,\n\t $sniffer: $SnifferProvider,\n\t $templateCache: $TemplateCacheProvider,\n\t $templateRequest: $TemplateRequestProvider,\n\t $$testability: $$TestabilityProvider,\n\t $timeout: $TimeoutProvider,\n\t $window: $WindowProvider,\n\t $$rAF: $$RAFProvider,\n\t $$jqLite: $$jqLiteProvider,\n\t $$HashMap: $$HashMapProvider,\n\t $$cookieReader: $$CookieReaderProvider\n\t });\n\t }\n\t ]);\n\t}\n\t\n\t/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *\n\t * Any commits to this file should be reviewed with security in mind. *\n\t * Changes to this file can potentially create security vulnerabilities. *\n\t * An approval from 2 Core members with history of modifying *\n\t * this file is required. *\n\t * *\n\t * Does the change somehow allow for arbitrary javascript to be executed? *\n\t * Or allows for someone to change the prototype of built-in objects? *\n\t * Or gives undesired access to variables likes document or window? *\n\t * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */\n\t\n\t/* global JQLitePrototype: true,\n\t addEventListenerFn: true,\n\t removeEventListenerFn: true,\n\t BOOLEAN_ATTR: true,\n\t ALIASED_ATTR: true,\n\t*/\n\t\n\t//////////////////////////////////\n\t//JQLite\n\t//////////////////////////////////\n\t\n\t/**\n\t * @ngdoc function\n\t * @name angular.element\n\t * @module ng\n\t * @kind function\n\t *\n\t * @description\n\t * Wraps a raw DOM element or HTML string as a [jQuery](http://jquery.com) element.\n\t *\n\t * If jQuery is available, `angular.element` is an alias for the\n\t * [jQuery](http://api.jquery.com/jQuery/) function. If jQuery is not available, `angular.element`\n\t * delegates to Angular's built-in subset of jQuery, called \"jQuery lite\" or **jqLite**.\n\t *\n\t * jqLite is a tiny, API-compatible subset of jQuery that allows\n\t * Angular to manipulate the DOM in a cross-browser compatible way. jqLite implements only the most\n\t * commonly needed functionality with the goal of having a very small footprint.\n\t *\n\t * To use `jQuery`, simply ensure it is loaded before the `angular.js` file. You can also use the\n\t * {@link ngJq `ngJq`} directive to specify that jqlite should be used over jQuery, or to use a\n\t * specific version of jQuery if multiple versions exist on the page.\n\t *\n\t *
**Note:** All element references in Angular are always wrapped with jQuery or\n\t * jqLite (such as the element argument in a directive's compile / link function). They are never raw DOM references.
\n\t *\n\t *
**Note:** Keep in mind that this function will not find elements\n\t * by tag name / CSS selector. For lookups by tag name, try instead `angular.element(document).find(...)`\n\t * or `$document.find()`, or use the standard DOM APIs, e.g. `document.querySelectorAll()`.
\n\t *\n\t * ## Angular's jqLite\n\t * jqLite provides only the following jQuery methods:\n\t *\n\t * - [`addClass()`](http://api.jquery.com/addClass/)\n\t * - [`after()`](http://api.jquery.com/after/)\n\t * - [`append()`](http://api.jquery.com/append/)\n\t * - [`attr()`](http://api.jquery.com/attr/) - Does not support functions as parameters\n\t * - [`bind()`](http://api.jquery.com/bind/) - Does not support namespaces, selectors or eventData\n\t * - [`children()`](http://api.jquery.com/children/) - Does not support selectors\n\t * - [`clone()`](http://api.jquery.com/clone/)\n\t * - [`contents()`](http://api.jquery.com/contents/)\n\t * - [`css()`](http://api.jquery.com/css/) - Only retrieves inline-styles, does not call `getComputedStyle()`.\n\t * As a setter, does not convert numbers to strings or append 'px', and also does not have automatic property prefixing.\n\t * - [`data()`](http://api.jquery.com/data/)\n\t * - [`detach()`](http://api.jquery.com/detach/)\n\t * - [`empty()`](http://api.jquery.com/empty/)\n\t * - [`eq()`](http://api.jquery.com/eq/)\n\t * - [`find()`](http://api.jquery.com/find/) - Limited to lookups by tag name\n\t * - [`hasClass()`](http://api.jquery.com/hasClass/)\n\t * - [`html()`](http://api.jquery.com/html/)\n\t * - [`next()`](http://api.jquery.com/next/) - Does not support selectors\n\t * - [`on()`](http://api.jquery.com/on/) - Does not support namespaces, selectors or eventData\n\t * - [`off()`](http://api.jquery.com/off/) - Does not support namespaces, selectors or event object as parameter\n\t * - [`one()`](http://api.jquery.com/one/) - Does not support namespaces or selectors\n\t * - [`parent()`](http://api.jquery.com/parent/) - Does not support selectors\n\t * - [`prepend()`](http://api.jquery.com/prepend/)\n\t * - [`prop()`](http://api.jquery.com/prop/)\n\t * - [`ready()`](http://api.jquery.com/ready/)\n\t * - [`remove()`](http://api.jquery.com/remove/)\n\t * - [`removeAttr()`](http://api.jquery.com/removeAttr/)\n\t * - [`removeClass()`](http://api.jquery.com/removeClass/)\n\t * - [`removeData()`](http://api.jquery.com/removeData/)\n\t * - [`replaceWith()`](http://api.jquery.com/replaceWith/)\n\t * - [`text()`](http://api.jquery.com/text/)\n\t * - [`toggleClass()`](http://api.jquery.com/toggleClass/)\n\t * - [`triggerHandler()`](http://api.jquery.com/triggerHandler/) - Passes a dummy event object to handlers.\n\t * - [`unbind()`](http://api.jquery.com/unbind/) - Does not support namespaces or event object as parameter\n\t * - [`val()`](http://api.jquery.com/val/)\n\t * - [`wrap()`](http://api.jquery.com/wrap/)\n\t *\n\t * ## jQuery/jqLite Extras\n\t * Angular also provides the following additional methods and events to both jQuery and jqLite:\n\t *\n\t * ### Events\n\t * - `$destroy` - AngularJS intercepts all jqLite/jQuery's DOM destruction apis and fires this event\n\t * on all DOM nodes being removed. This can be used to clean up any 3rd party bindings to the DOM\n\t * element before it is removed.\n\t *\n\t * ### Methods\n\t * - `controller(name)` - retrieves the controller of the current element or its parent. By default\n\t * retrieves controller associated with the `ngController` directive. If `name` is provided as\n\t * camelCase directive name, then the controller for this directive will be retrieved (e.g.\n\t * `'ngModel'`).\n\t * - `injector()` - retrieves the injector of the current element or its parent.\n\t * - `scope()` - retrieves the {@link ng.$rootScope.Scope scope} of the current\n\t * element or its parent. Requires {@link guide/production#disabling-debug-data Debug Data} to\n\t * be enabled.\n\t * - `isolateScope()` - retrieves an isolate {@link ng.$rootScope.Scope scope} if one is attached directly to the\n\t * current element. This getter should be used only on elements that contain a directive which starts a new isolate\n\t * scope. Calling `scope()` on this element always returns the original non-isolate scope.\n\t * Requires {@link guide/production#disabling-debug-data Debug Data} to be enabled.\n\t * - `inheritedData()` - same as `data()`, but walks up the DOM until a value is found or the top\n\t * parent element is reached.\n\t *\n\t * @param {string|DOMElement} element HTML string or DOMElement to be wrapped into jQuery.\n\t * @returns {Object} jQuery object.\n\t */\n\t\n\tJQLite.expando = 'ng339';\n\t\n\tvar jqCache = JQLite.cache = {},\n\t jqId = 1,\n\t addEventListenerFn = function(element, type, fn) {\n\t element.addEventListener(type, fn, false);\n\t },\n\t removeEventListenerFn = function(element, type, fn) {\n\t element.removeEventListener(type, fn, false);\n\t };\n\t\n\t/*\n\t * !!! This is an undocumented \"private\" function !!!\n\t */\n\tJQLite._data = function(node) {\n\t //jQuery always returns an object on cache miss\n\t return this.cache[node[this.expando]] || {};\n\t};\n\t\n\tfunction jqNextId() { return ++jqId; }\n\t\n\t\n\tvar SPECIAL_CHARS_REGEXP = /([\\:\\-\\_]+(.))/g;\n\tvar MOZ_HACK_REGEXP = /^moz([A-Z])/;\n\tvar MOUSE_EVENT_MAP= { mouseleave: \"mouseout\", mouseenter: \"mouseover\"};\n\tvar jqLiteMinErr = minErr('jqLite');\n\t\n\t/**\n\t * Converts snake_case to camelCase.\n\t * Also there is special case for Moz prefix starting with upper case letter.\n\t * @param name Name to normalize\n\t */\n\tfunction camelCase(name) {\n\t return name.\n\t replace(SPECIAL_CHARS_REGEXP, function(_, separator, letter, offset) {\n\t return offset ? letter.toUpperCase() : letter;\n\t }).\n\t replace(MOZ_HACK_REGEXP, 'Moz$1');\n\t}\n\t\n\tvar SINGLE_TAG_REGEXP = /^<([\\w-]+)\\s*\\/?>(?:<\\/\\1>|)$/;\n\tvar HTML_REGEXP = /<|&#?\\w+;/;\n\tvar TAG_NAME_REGEXP = /<([\\w:-]+)/;\n\tvar XHTML_TAG_REGEXP = /<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\\w:-]+)[^>]*)\\/>/gi;\n\t\n\tvar wrapMap = {\n\t 'option': [1, ''],\n\t\n\t 'thead': [1, '', '
'],\n\t 'col': [2, '', '
'],\n\t 'tr': [2, '', '
'],\n\t 'td': [3, '', '
'],\n\t '_default': [0, \"\", \"\"]\n\t};\n\t\n\twrapMap.optgroup = wrapMap.option;\n\twrapMap.tbody = wrapMap.tfoot = wrapMap.colgroup = wrapMap.caption = wrapMap.thead;\n\twrapMap.th = wrapMap.td;\n\t\n\t\n\tfunction jqLiteIsTextNode(html) {\n\t return !HTML_REGEXP.test(html);\n\t}\n\t\n\tfunction jqLiteAcceptsData(node) {\n\t // The window object can accept data but has no nodeType\n\t // Otherwise we are only interested in elements (1) and documents (9)\n\t var nodeType = node.nodeType;\n\t return nodeType === NODE_TYPE_ELEMENT || !nodeType || nodeType === NODE_TYPE_DOCUMENT;\n\t}\n\t\n\tfunction jqLiteHasData(node) {\n\t for (var key in jqCache[node.ng339]) {\n\t return true;\n\t }\n\t return false;\n\t}\n\t\n\tfunction jqLiteBuildFragment(html, context) {\n\t var tmp, tag, wrap,\n\t fragment = context.createDocumentFragment(),\n\t nodes = [], i;\n\t\n\t if (jqLiteIsTextNode(html)) {\n\t // Convert non-html into a text node\n\t nodes.push(context.createTextNode(html));\n\t } else {\n\t // Convert html into DOM nodes\n\t tmp = tmp || fragment.appendChild(context.createElement(\"div\"));\n\t tag = (TAG_NAME_REGEXP.exec(html) || [\"\", \"\"])[1].toLowerCase();\n\t wrap = wrapMap[tag] || wrapMap._default;\n\t tmp.innerHTML = wrap[1] + html.replace(XHTML_TAG_REGEXP, \"<$1>\") + wrap[2];\n\t\n\t // Descend through wrappers to the right content\n\t i = wrap[0];\n\t while (i--) {\n\t tmp = tmp.lastChild;\n\t }\n\t\n\t nodes = concat(nodes, tmp.childNodes);\n\t\n\t tmp = fragment.firstChild;\n\t tmp.textContent = \"\";\n\t }\n\t\n\t // Remove wrapper from fragment\n\t fragment.textContent = \"\";\n\t fragment.innerHTML = \"\"; // Clear inner HTML\n\t forEach(nodes, function(node) {\n\t fragment.appendChild(node);\n\t });\n\t\n\t return fragment;\n\t}\n\t\n\tfunction jqLiteParseHTML(html, context) {\n\t context = context || document;\n\t var parsed;\n\t\n\t if ((parsed = SINGLE_TAG_REGEXP.exec(html))) {\n\t return [context.createElement(parsed[1])];\n\t }\n\t\n\t if ((parsed = jqLiteBuildFragment(html, context))) {\n\t return parsed.childNodes;\n\t }\n\t\n\t return [];\n\t}\n\t\n\tfunction jqLiteWrapNode(node, wrapper) {\n\t var parent = node.parentNode;\n\t\n\t if (parent) {\n\t parent.replaceChild(wrapper, node);\n\t }\n\t\n\t wrapper.appendChild(node);\n\t}\n\t\n\t\n\t// IE9-11 has no method \"contains\" in SVG element and in Node.prototype. Bug #10259.\n\tvar jqLiteContains = Node.prototype.contains || function(arg) {\n\t // jshint bitwise: false\n\t return !!(this.compareDocumentPosition(arg) & 16);\n\t // jshint bitwise: true\n\t};\n\t\n\t/////////////////////////////////////////////\n\tfunction JQLite(element) {\n\t if (element instanceof JQLite) {\n\t return element;\n\t }\n\t\n\t var argIsString;\n\t\n\t if (isString(element)) {\n\t element = trim(element);\n\t argIsString = true;\n\t }\n\t if (!(this instanceof JQLite)) {\n\t if (argIsString && element.charAt(0) != '<') {\n\t throw jqLiteMinErr('nosel', 'Looking up elements via selectors is not supported by jqLite! See: http://docs.angularjs.org/api/angular.element');\n\t }\n\t return new JQLite(element);\n\t }\n\t\n\t if (argIsString) {\n\t jqLiteAddNodes(this, jqLiteParseHTML(element));\n\t } else {\n\t jqLiteAddNodes(this, element);\n\t }\n\t}\n\t\n\tfunction jqLiteClone(element) {\n\t return element.cloneNode(true);\n\t}\n\t\n\tfunction jqLiteDealoc(element, onlyDescendants) {\n\t if (!onlyDescendants) jqLiteRemoveData(element);\n\t\n\t if (element.querySelectorAll) {\n\t var descendants = element.querySelectorAll('*');\n\t for (var i = 0, l = descendants.length; i < l; i++) {\n\t jqLiteRemoveData(descendants[i]);\n\t }\n\t }\n\t}\n\t\n\tfunction jqLiteOff(element, type, fn, unsupported) {\n\t if (isDefined(unsupported)) throw jqLiteMinErr('offargs', 'jqLite#off() does not support the `selector` argument');\n\t\n\t var expandoStore = jqLiteExpandoStore(element);\n\t var events = expandoStore && expandoStore.events;\n\t var handle = expandoStore && expandoStore.handle;\n\t\n\t if (!handle) return; //no listeners registered\n\t\n\t if (!type) {\n\t for (type in events) {\n\t if (type !== '$destroy') {\n\t removeEventListenerFn(element, type, handle);\n\t }\n\t delete events[type];\n\t }\n\t } else {\n\t\n\t var removeHandler = function(type) {\n\t var listenerFns = events[type];\n\t if (isDefined(fn)) {\n\t arrayRemove(listenerFns || [], fn);\n\t }\n\t if (!(isDefined(fn) && listenerFns && listenerFns.length > 0)) {\n\t removeEventListenerFn(element, type, handle);\n\t delete events[type];\n\t }\n\t };\n\t\n\t forEach(type.split(' '), function(type) {\n\t removeHandler(type);\n\t if (MOUSE_EVENT_MAP[type]) {\n\t removeHandler(MOUSE_EVENT_MAP[type]);\n\t }\n\t });\n\t }\n\t}\n\t\n\tfunction jqLiteRemoveData(element, name) {\n\t var expandoId = element.ng339;\n\t var expandoStore = expandoId && jqCache[expandoId];\n\t\n\t if (expandoStore) {\n\t if (name) {\n\t delete expandoStore.data[name];\n\t return;\n\t }\n\t\n\t if (expandoStore.handle) {\n\t if (expandoStore.events.$destroy) {\n\t expandoStore.handle({}, '$destroy');\n\t }\n\t jqLiteOff(element);\n\t }\n\t delete jqCache[expandoId];\n\t element.ng339 = undefined; // don't delete DOM expandos. IE and Chrome don't like it\n\t }\n\t}\n\t\n\t\n\tfunction jqLiteExpandoStore(element, createIfNecessary) {\n\t var expandoId = element.ng339,\n\t expandoStore = expandoId && jqCache[expandoId];\n\t\n\t if (createIfNecessary && !expandoStore) {\n\t element.ng339 = expandoId = jqNextId();\n\t expandoStore = jqCache[expandoId] = {events: {}, data: {}, handle: undefined};\n\t }\n\t\n\t return expandoStore;\n\t}\n\t\n\t\n\tfunction jqLiteData(element, key, value) {\n\t if (jqLiteAcceptsData(element)) {\n\t\n\t var isSimpleSetter = isDefined(value);\n\t var isSimpleGetter = !isSimpleSetter && key && !isObject(key);\n\t var massGetter = !key;\n\t var expandoStore = jqLiteExpandoStore(element, !isSimpleGetter);\n\t var data = expandoStore && expandoStore.data;\n\t\n\t if (isSimpleSetter) { // data('key', value)\n\t data[key] = value;\n\t } else {\n\t if (massGetter) { // data()\n\t return data;\n\t } else {\n\t if (isSimpleGetter) { // data('key')\n\t // don't force creation of expandoStore if it doesn't exist yet\n\t return data && data[key];\n\t } else { // mass-setter: data({key1: val1, key2: val2})\n\t extend(data, key);\n\t }\n\t }\n\t }\n\t }\n\t}\n\t\n\tfunction jqLiteHasClass(element, selector) {\n\t if (!element.getAttribute) return false;\n\t return ((\" \" + (element.getAttribute('class') || '') + \" \").replace(/[\\n\\t]/g, \" \").\n\t indexOf(\" \" + selector + \" \") > -1);\n\t}\n\t\n\tfunction jqLiteRemoveClass(element, cssClasses) {\n\t if (cssClasses && element.setAttribute) {\n\t forEach(cssClasses.split(' '), function(cssClass) {\n\t element.setAttribute('class', trim(\n\t (\" \" + (element.getAttribute('class') || '') + \" \")\n\t .replace(/[\\n\\t]/g, \" \")\n\t .replace(\" \" + trim(cssClass) + \" \", \" \"))\n\t );\n\t });\n\t }\n\t}\n\t\n\tfunction jqLiteAddClass(element, cssClasses) {\n\t if (cssClasses && element.setAttribute) {\n\t var existingClasses = (' ' + (element.getAttribute('class') || '') + ' ')\n\t .replace(/[\\n\\t]/g, \" \");\n\t\n\t forEach(cssClasses.split(' '), function(cssClass) {\n\t cssClass = trim(cssClass);\n\t if (existingClasses.indexOf(' ' + cssClass + ' ') === -1) {\n\t existingClasses += cssClass + ' ';\n\t }\n\t });\n\t\n\t element.setAttribute('class', trim(existingClasses));\n\t }\n\t}\n\t\n\t\n\tfunction jqLiteAddNodes(root, elements) {\n\t // THIS CODE IS VERY HOT. Don't make changes without benchmarking.\n\t\n\t if (elements) {\n\t\n\t // if a Node (the most common case)\n\t if (elements.nodeType) {\n\t root[root.length++] = elements;\n\t } else {\n\t var length = elements.length;\n\t\n\t // if an Array or NodeList and not a Window\n\t if (typeof length === 'number' && elements.window !== elements) {\n\t if (length) {\n\t for (var i = 0; i < length; i++) {\n\t root[root.length++] = elements[i];\n\t }\n\t }\n\t } else {\n\t root[root.length++] = elements;\n\t }\n\t }\n\t }\n\t}\n\t\n\t\n\tfunction jqLiteController(element, name) {\n\t return jqLiteInheritedData(element, '$' + (name || 'ngController') + 'Controller');\n\t}\n\t\n\tfunction jqLiteInheritedData(element, name, value) {\n\t // if element is the document object work with the html element instead\n\t // this makes $(document).scope() possible\n\t if (element.nodeType == NODE_TYPE_DOCUMENT) {\n\t element = element.documentElement;\n\t }\n\t var names = isArray(name) ? name : [name];\n\t\n\t while (element) {\n\t for (var i = 0, ii = names.length; i < ii; i++) {\n\t if (isDefined(value = jqLite.data(element, names[i]))) return value;\n\t }\n\t\n\t // If dealing with a document fragment node with a host element, and no parent, use the host\n\t // element as the parent. This enables directives within a Shadow DOM or polyfilled Shadow DOM\n\t // to lookup parent controllers.\n\t element = element.parentNode || (element.nodeType === NODE_TYPE_DOCUMENT_FRAGMENT && element.host);\n\t }\n\t}\n\t\n\tfunction jqLiteEmpty(element) {\n\t jqLiteDealoc(element, true);\n\t while (element.firstChild) {\n\t element.removeChild(element.firstChild);\n\t }\n\t}\n\t\n\tfunction jqLiteRemove(element, keepData) {\n\t if (!keepData) jqLiteDealoc(element);\n\t var parent = element.parentNode;\n\t if (parent) parent.removeChild(element);\n\t}\n\t\n\t\n\tfunction jqLiteDocumentLoaded(action, win) {\n\t win = win || window;\n\t if (win.document.readyState === 'complete') {\n\t // Force the action to be run async for consistent behaviour\n\t // from the action's point of view\n\t // i.e. it will definitely not be in a $apply\n\t win.setTimeout(action);\n\t } else {\n\t // No need to unbind this handler as load is only ever called once\n\t jqLite(win).on('load', action);\n\t }\n\t}\n\t\n\t//////////////////////////////////////////\n\t// Functions which are declared directly.\n\t//////////////////////////////////////////\n\tvar JQLitePrototype = JQLite.prototype = {\n\t ready: function(fn) {\n\t var fired = false;\n\t\n\t function trigger() {\n\t if (fired) return;\n\t fired = true;\n\t fn();\n\t }\n\t\n\t // check if document is already loaded\n\t if (document.readyState === 'complete') {\n\t setTimeout(trigger);\n\t } else {\n\t this.on('DOMContentLoaded', trigger); // works for modern browsers and IE9\n\t // we can not use jqLite since we are not done loading and jQuery could be loaded later.\n\t // jshint -W064\n\t JQLite(window).on('load', trigger); // fallback to window.onload for others\n\t // jshint +W064\n\t }\n\t },\n\t toString: function() {\n\t var value = [];\n\t forEach(this, function(e) { value.push('' + e);});\n\t return '[' + value.join(', ') + ']';\n\t },\n\t\n\t eq: function(index) {\n\t return (index >= 0) ? jqLite(this[index]) : jqLite(this[this.length + index]);\n\t },\n\t\n\t length: 0,\n\t push: push,\n\t sort: [].sort,\n\t splice: [].splice\n\t};\n\t\n\t//////////////////////////////////////////\n\t// Functions iterating getter/setters.\n\t// these functions return self on setter and\n\t// value on get.\n\t//////////////////////////////////////////\n\tvar BOOLEAN_ATTR = {};\n\tforEach('multiple,selected,checked,disabled,readOnly,required,open'.split(','), function(value) {\n\t BOOLEAN_ATTR[lowercase(value)] = value;\n\t});\n\tvar BOOLEAN_ELEMENTS = {};\n\tforEach('input,select,option,textarea,button,form,details'.split(','), function(value) {\n\t BOOLEAN_ELEMENTS[value] = true;\n\t});\n\tvar ALIASED_ATTR = {\n\t 'ngMinlength': 'minlength',\n\t 'ngMaxlength': 'maxlength',\n\t 'ngMin': 'min',\n\t 'ngMax': 'max',\n\t 'ngPattern': 'pattern'\n\t};\n\t\n\tfunction getBooleanAttrName(element, name) {\n\t // check dom last since we will most likely fail on name\n\t var booleanAttr = BOOLEAN_ATTR[name.toLowerCase()];\n\t\n\t // booleanAttr is here twice to minimize DOM access\n\t return booleanAttr && BOOLEAN_ELEMENTS[nodeName_(element)] && booleanAttr;\n\t}\n\t\n\tfunction getAliasedAttrName(name) {\n\t return ALIASED_ATTR[name];\n\t}\n\t\n\tforEach({\n\t data: jqLiteData,\n\t removeData: jqLiteRemoveData,\n\t hasData: jqLiteHasData\n\t}, function(fn, name) {\n\t JQLite[name] = fn;\n\t});\n\t\n\tforEach({\n\t data: jqLiteData,\n\t inheritedData: jqLiteInheritedData,\n\t\n\t scope: function(element) {\n\t // Can't use jqLiteData here directly so we stay compatible with jQuery!\n\t return jqLite.data(element, '$scope') || jqLiteInheritedData(element.parentNode || element, ['$isolateScope', '$scope']);\n\t },\n\t\n\t isolateScope: function(element) {\n\t // Can't use jqLiteData here directly so we stay compatible with jQuery!\n\t return jqLite.data(element, '$isolateScope') || jqLite.data(element, '$isolateScopeNoTemplate');\n\t },\n\t\n\t controller: jqLiteController,\n\t\n\t injector: function(element) {\n\t return jqLiteInheritedData(element, '$injector');\n\t },\n\t\n\t removeAttr: function(element, name) {\n\t element.removeAttribute(name);\n\t },\n\t\n\t hasClass: jqLiteHasClass,\n\t\n\t css: function(element, name, value) {\n\t name = camelCase(name);\n\t\n\t if (isDefined(value)) {\n\t element.style[name] = value;\n\t } else {\n\t return element.style[name];\n\t }\n\t },\n\t\n\t attr: function(element, name, value) {\n\t var nodeType = element.nodeType;\n\t if (nodeType === NODE_TYPE_TEXT || nodeType === NODE_TYPE_ATTRIBUTE || nodeType === NODE_TYPE_COMMENT) {\n\t return;\n\t }\n\t var lowercasedName = lowercase(name);\n\t if (BOOLEAN_ATTR[lowercasedName]) {\n\t if (isDefined(value)) {\n\t if (!!value) {\n\t element[name] = true;\n\t element.setAttribute(name, lowercasedName);\n\t } else {\n\t element[name] = false;\n\t element.removeAttribute(lowercasedName);\n\t }\n\t } else {\n\t return (element[name] ||\n\t (element.attributes.getNamedItem(name) || noop).specified)\n\t ? lowercasedName\n\t : undefined;\n\t }\n\t } else if (isDefined(value)) {\n\t element.setAttribute(name, value);\n\t } else if (element.getAttribute) {\n\t // the extra argument \"2\" is to get the right thing for a.href in IE, see jQuery code\n\t // some elements (e.g. Document) don't have get attribute, so return undefined\n\t var ret = element.getAttribute(name, 2);\n\t // normalize non-existing attributes to undefined (as jQuery)\n\t return ret === null ? undefined : ret;\n\t }\n\t },\n\t\n\t prop: function(element, name, value) {\n\t if (isDefined(value)) {\n\t element[name] = value;\n\t } else {\n\t return element[name];\n\t }\n\t },\n\t\n\t text: (function() {\n\t getText.$dv = '';\n\t return getText;\n\t\n\t function getText(element, value) {\n\t if (isUndefined(value)) {\n\t var nodeType = element.nodeType;\n\t return (nodeType === NODE_TYPE_ELEMENT || nodeType === NODE_TYPE_TEXT) ? element.textContent : '';\n\t }\n\t element.textContent = value;\n\t }\n\t })(),\n\t\n\t val: function(element, value) {\n\t if (isUndefined(value)) {\n\t if (element.multiple && nodeName_(element) === 'select') {\n\t var result = [];\n\t forEach(element.options, function(option) {\n\t if (option.selected) {\n\t result.push(option.value || option.text);\n\t }\n\t });\n\t return result.length === 0 ? null : result;\n\t }\n\t return element.value;\n\t }\n\t element.value = value;\n\t },\n\t\n\t html: function(element, value) {\n\t if (isUndefined(value)) {\n\t return element.innerHTML;\n\t }\n\t jqLiteDealoc(element, true);\n\t element.innerHTML = value;\n\t },\n\t\n\t empty: jqLiteEmpty\n\t}, function(fn, name) {\n\t /**\n\t * Properties: writes return selection, reads return first value\n\t */\n\t JQLite.prototype[name] = function(arg1, arg2) {\n\t var i, key;\n\t var nodeCount = this.length;\n\t\n\t // jqLiteHasClass has only two arguments, but is a getter-only fn, so we need to special-case it\n\t // in a way that survives minification.\n\t // jqLiteEmpty takes no arguments but is a setter.\n\t if (fn !== jqLiteEmpty &&\n\t (isUndefined((fn.length == 2 && (fn !== jqLiteHasClass && fn !== jqLiteController)) ? arg1 : arg2))) {\n\t if (isObject(arg1)) {\n\t\n\t // we are a write, but the object properties are the key/values\n\t for (i = 0; i < nodeCount; i++) {\n\t if (fn === jqLiteData) {\n\t // data() takes the whole object in jQuery\n\t fn(this[i], arg1);\n\t } else {\n\t for (key in arg1) {\n\t fn(this[i], key, arg1[key]);\n\t }\n\t }\n\t }\n\t // return self for chaining\n\t return this;\n\t } else {\n\t // we are a read, so read the first child.\n\t // TODO: do we still need this?\n\t var value = fn.$dv;\n\t // Only if we have $dv do we iterate over all, otherwise it is just the first element.\n\t var jj = (isUndefined(value)) ? Math.min(nodeCount, 1) : nodeCount;\n\t for (var j = 0; j < jj; j++) {\n\t var nodeValue = fn(this[j], arg1, arg2);\n\t value = value ? value + nodeValue : nodeValue;\n\t }\n\t return value;\n\t }\n\t } else {\n\t // we are a write, so apply to all children\n\t for (i = 0; i < nodeCount; i++) {\n\t fn(this[i], arg1, arg2);\n\t }\n\t // return self for chaining\n\t return this;\n\t }\n\t };\n\t});\n\t\n\tfunction createEventHandler(element, events) {\n\t var eventHandler = function(event, type) {\n\t // jQuery specific api\n\t event.isDefaultPrevented = function() {\n\t return event.defaultPrevented;\n\t };\n\t\n\t var eventFns = events[type || event.type];\n\t var eventFnsLength = eventFns ? eventFns.length : 0;\n\t\n\t if (!eventFnsLength) return;\n\t\n\t if (isUndefined(event.immediatePropagationStopped)) {\n\t var originalStopImmediatePropagation = event.stopImmediatePropagation;\n\t event.stopImmediatePropagation = function() {\n\t event.immediatePropagationStopped = true;\n\t\n\t if (event.stopPropagation) {\n\t event.stopPropagation();\n\t }\n\t\n\t if (originalStopImmediatePropagation) {\n\t originalStopImmediatePropagation.call(event);\n\t }\n\t };\n\t }\n\t\n\t event.isImmediatePropagationStopped = function() {\n\t return event.immediatePropagationStopped === true;\n\t };\n\t\n\t // Some events have special handlers that wrap the real handler\n\t var handlerWrapper = eventFns.specialHandlerWrapper || defaultHandlerWrapper;\n\t\n\t // Copy event handlers in case event handlers array is modified during execution.\n\t if ((eventFnsLength > 1)) {\n\t eventFns = shallowCopy(eventFns);\n\t }\n\t\n\t for (var i = 0; i < eventFnsLength; i++) {\n\t if (!event.isImmediatePropagationStopped()) {\n\t handlerWrapper(element, event, eventFns[i]);\n\t }\n\t }\n\t };\n\t\n\t // TODO: this is a hack for angularMocks/clearDataCache that makes it possible to deregister all\n\t // events on `element`\n\t eventHandler.elem = element;\n\t return eventHandler;\n\t}\n\t\n\tfunction defaultHandlerWrapper(element, event, handler) {\n\t handler.call(element, event);\n\t}\n\t\n\tfunction specialMouseHandlerWrapper(target, event, handler) {\n\t // Refer to jQuery's implementation of mouseenter & mouseleave\n\t // Read about mouseenter and mouseleave:\n\t // http://www.quirksmode.org/js/events_mouse.html#link8\n\t var related = event.relatedTarget;\n\t // For mousenter/leave call the handler if related is outside the target.\n\t // NB: No relatedTarget if the mouse left/entered the browser window\n\t if (!related || (related !== target && !jqLiteContains.call(target, related))) {\n\t handler.call(target, event);\n\t }\n\t}\n\t\n\t//////////////////////////////////////////\n\t// Functions iterating traversal.\n\t// These functions chain results into a single\n\t// selector.\n\t//////////////////////////////////////////\n\tforEach({\n\t removeData: jqLiteRemoveData,\n\t\n\t on: function jqLiteOn(element, type, fn, unsupported) {\n\t if (isDefined(unsupported)) throw jqLiteMinErr('onargs', 'jqLite#on() does not support the `selector` or `eventData` parameters');\n\t\n\t // Do not add event handlers to non-elements because they will not be cleaned up.\n\t if (!jqLiteAcceptsData(element)) {\n\t return;\n\t }\n\t\n\t var expandoStore = jqLiteExpandoStore(element, true);\n\t var events = expandoStore.events;\n\t var handle = expandoStore.handle;\n\t\n\t if (!handle) {\n\t handle = expandoStore.handle = createEventHandler(element, events);\n\t }\n\t\n\t // http://jsperf.com/string-indexof-vs-split\n\t var types = type.indexOf(' ') >= 0 ? type.split(' ') : [type];\n\t var i = types.length;\n\t\n\t var addHandler = function(type, specialHandlerWrapper, noEventListener) {\n\t var eventFns = events[type];\n\t\n\t if (!eventFns) {\n\t eventFns = events[type] = [];\n\t eventFns.specialHandlerWrapper = specialHandlerWrapper;\n\t if (type !== '$destroy' && !noEventListener) {\n\t addEventListenerFn(element, type, handle);\n\t }\n\t }\n\t\n\t eventFns.push(fn);\n\t };\n\t\n\t while (i--) {\n\t type = types[i];\n\t if (MOUSE_EVENT_MAP[type]) {\n\t addHandler(MOUSE_EVENT_MAP[type], specialMouseHandlerWrapper);\n\t addHandler(type, undefined, true);\n\t } else {\n\t addHandler(type);\n\t }\n\t }\n\t },\n\t\n\t off: jqLiteOff,\n\t\n\t one: function(element, type, fn) {\n\t element = jqLite(element);\n\t\n\t //add the listener twice so that when it is called\n\t //you can remove the original function and still be\n\t //able to call element.off(ev, fn) normally\n\t element.on(type, function onFn() {\n\t element.off(type, fn);\n\t element.off(type, onFn);\n\t });\n\t element.on(type, fn);\n\t },\n\t\n\t replaceWith: function(element, replaceNode) {\n\t var index, parent = element.parentNode;\n\t jqLiteDealoc(element);\n\t forEach(new JQLite(replaceNode), function(node) {\n\t if (index) {\n\t parent.insertBefore(node, index.nextSibling);\n\t } else {\n\t parent.replaceChild(node, element);\n\t }\n\t index = node;\n\t });\n\t },\n\t\n\t children: function(element) {\n\t var children = [];\n\t forEach(element.childNodes, function(element) {\n\t if (element.nodeType === NODE_TYPE_ELEMENT) {\n\t children.push(element);\n\t }\n\t });\n\t return children;\n\t },\n\t\n\t contents: function(element) {\n\t return element.contentDocument || element.childNodes || [];\n\t },\n\t\n\t append: function(element, node) {\n\t var nodeType = element.nodeType;\n\t if (nodeType !== NODE_TYPE_ELEMENT && nodeType !== NODE_TYPE_DOCUMENT_FRAGMENT) return;\n\t\n\t node = new JQLite(node);\n\t\n\t for (var i = 0, ii = node.length; i < ii; i++) {\n\t var child = node[i];\n\t element.appendChild(child);\n\t }\n\t },\n\t\n\t prepend: function(element, node) {\n\t if (element.nodeType === NODE_TYPE_ELEMENT) {\n\t var index = element.firstChild;\n\t forEach(new JQLite(node), function(child) {\n\t element.insertBefore(child, index);\n\t });\n\t }\n\t },\n\t\n\t wrap: function(element, wrapNode) {\n\t jqLiteWrapNode(element, jqLite(wrapNode).eq(0).clone()[0]);\n\t },\n\t\n\t remove: jqLiteRemove,\n\t\n\t detach: function(element) {\n\t jqLiteRemove(element, true);\n\t },\n\t\n\t after: function(element, newElement) {\n\t var index = element, parent = element.parentNode;\n\t newElement = new JQLite(newElement);\n\t\n\t for (var i = 0, ii = newElement.length; i < ii; i++) {\n\t var node = newElement[i];\n\t parent.insertBefore(node, index.nextSibling);\n\t index = node;\n\t }\n\t },\n\t\n\t addClass: jqLiteAddClass,\n\t removeClass: jqLiteRemoveClass,\n\t\n\t toggleClass: function(element, selector, condition) {\n\t if (selector) {\n\t forEach(selector.split(' '), function(className) {\n\t var classCondition = condition;\n\t if (isUndefined(classCondition)) {\n\t classCondition = !jqLiteHasClass(element, className);\n\t }\n\t (classCondition ? jqLiteAddClass : jqLiteRemoveClass)(element, className);\n\t });\n\t }\n\t },\n\t\n\t parent: function(element) {\n\t var parent = element.parentNode;\n\t return parent && parent.nodeType !== NODE_TYPE_DOCUMENT_FRAGMENT ? parent : null;\n\t },\n\t\n\t next: function(element) {\n\t return element.nextElementSibling;\n\t },\n\t\n\t find: function(element, selector) {\n\t if (element.getElementsByTagName) {\n\t return element.getElementsByTagName(selector);\n\t } else {\n\t return [];\n\t }\n\t },\n\t\n\t clone: jqLiteClone,\n\t\n\t triggerHandler: function(element, event, extraParameters) {\n\t\n\t var dummyEvent, eventFnsCopy, handlerArgs;\n\t var eventName = event.type || event;\n\t var expandoStore = jqLiteExpandoStore(element);\n\t var events = expandoStore && expandoStore.events;\n\t var eventFns = events && events[eventName];\n\t\n\t if (eventFns) {\n\t // Create a dummy event to pass to the handlers\n\t dummyEvent = {\n\t preventDefault: function() { this.defaultPrevented = true; },\n\t isDefaultPrevented: function() { return this.defaultPrevented === true; },\n\t stopImmediatePropagation: function() { this.immediatePropagationStopped = true; },\n\t isImmediatePropagationStopped: function() { return this.immediatePropagationStopped === true; },\n\t stopPropagation: noop,\n\t type: eventName,\n\t target: element\n\t };\n\t\n\t // If a custom event was provided then extend our dummy event with it\n\t if (event.type) {\n\t dummyEvent = extend(dummyEvent, event);\n\t }\n\t\n\t // Copy event handlers in case event handlers array is modified during execution.\n\t eventFnsCopy = shallowCopy(eventFns);\n\t handlerArgs = extraParameters ? [dummyEvent].concat(extraParameters) : [dummyEvent];\n\t\n\t forEach(eventFnsCopy, function(fn) {\n\t if (!dummyEvent.isImmediatePropagationStopped()) {\n\t fn.apply(element, handlerArgs);\n\t }\n\t });\n\t }\n\t }\n\t}, function(fn, name) {\n\t /**\n\t * chaining functions\n\t */\n\t JQLite.prototype[name] = function(arg1, arg2, arg3) {\n\t var value;\n\t\n\t for (var i = 0, ii = this.length; i < ii; i++) {\n\t if (isUndefined(value)) {\n\t value = fn(this[i], arg1, arg2, arg3);\n\t if (isDefined(value)) {\n\t // any function which returns a value needs to be wrapped\n\t value = jqLite(value);\n\t }\n\t } else {\n\t jqLiteAddNodes(value, fn(this[i], arg1, arg2, arg3));\n\t }\n\t }\n\t return isDefined(value) ? value : this;\n\t };\n\t\n\t // bind legacy bind/unbind to on/off\n\t JQLite.prototype.bind = JQLite.prototype.on;\n\t JQLite.prototype.unbind = JQLite.prototype.off;\n\t});\n\t\n\t\n\t// Provider for private $$jqLite service\n\tfunction $$jqLiteProvider() {\n\t this.$get = function $$jqLite() {\n\t return extend(JQLite, {\n\t hasClass: function(node, classes) {\n\t if (node.attr) node = node[0];\n\t return jqLiteHasClass(node, classes);\n\t },\n\t addClass: function(node, classes) {\n\t if (node.attr) node = node[0];\n\t return jqLiteAddClass(node, classes);\n\t },\n\t removeClass: function(node, classes) {\n\t if (node.attr) node = node[0];\n\t return jqLiteRemoveClass(node, classes);\n\t }\n\t });\n\t };\n\t}\n\t\n\t/**\n\t * Computes a hash of an 'obj'.\n\t * Hash of a:\n\t * string is string\n\t * number is number as string\n\t * object is either result of calling $$hashKey function on the object or uniquely generated id,\n\t * that is also assigned to the $$hashKey property of the object.\n\t *\n\t * @param obj\n\t * @returns {string} hash string such that the same input will have the same hash string.\n\t * The resulting string key is in 'type:hashKey' format.\n\t */\n\tfunction hashKey(obj, nextUidFn) {\n\t var key = obj && obj.$$hashKey;\n\t\n\t if (key) {\n\t if (typeof key === 'function') {\n\t key = obj.$$hashKey();\n\t }\n\t return key;\n\t }\n\t\n\t var objType = typeof obj;\n\t if (objType == 'function' || (objType == 'object' && obj !== null)) {\n\t key = obj.$$hashKey = objType + ':' + (nextUidFn || nextUid)();\n\t } else {\n\t key = objType + ':' + obj;\n\t }\n\t\n\t return key;\n\t}\n\t\n\t/**\n\t * HashMap which can use objects as keys\n\t */\n\tfunction HashMap(array, isolatedUid) {\n\t if (isolatedUid) {\n\t var uid = 0;\n\t this.nextUid = function() {\n\t return ++uid;\n\t };\n\t }\n\t forEach(array, this.put, this);\n\t}\n\tHashMap.prototype = {\n\t /**\n\t * Store key value pair\n\t * @param key key to store can be any type\n\t * @param value value to store can be any type\n\t */\n\t put: function(key, value) {\n\t this[hashKey(key, this.nextUid)] = value;\n\t },\n\t\n\t /**\n\t * @param key\n\t * @returns {Object} the value for the key\n\t */\n\t get: function(key) {\n\t return this[hashKey(key, this.nextUid)];\n\t },\n\t\n\t /**\n\t * Remove the key/value pair\n\t * @param key\n\t */\n\t remove: function(key) {\n\t var value = this[key = hashKey(key, this.nextUid)];\n\t delete this[key];\n\t return value;\n\t }\n\t};\n\t\n\tvar $$HashMapProvider = [function() {\n\t this.$get = [function() {\n\t return HashMap;\n\t }];\n\t}];\n\t\n\t/**\n\t * @ngdoc function\n\t * @module ng\n\t * @name angular.injector\n\t * @kind function\n\t *\n\t * @description\n\t * Creates an injector object that can be used for retrieving services as well as for\n\t * dependency injection (see {@link guide/di dependency injection}).\n\t *\n\t * @param {Array.} modules A list of module functions or their aliases. See\n\t * {@link angular.module}. The `ng` module must be explicitly added.\n\t * @param {boolean=} [strictDi=false] Whether the injector should be in strict mode, which\n\t * disallows argument name annotation inference.\n\t * @returns {injector} Injector object. See {@link auto.$injector $injector}.\n\t *\n\t * @example\n\t * Typical usage\n\t * ```js\n\t * // create an injector\n\t * var $injector = angular.injector(['ng']);\n\t *\n\t * // use the injector to kick off your application\n\t * // use the type inference to auto inject arguments, or use implicit injection\n\t * $injector.invoke(function($rootScope, $compile, $document) {\n\t * $compile($document)($rootScope);\n\t * $rootScope.$digest();\n\t * });\n\t * ```\n\t *\n\t * Sometimes you want to get access to the injector of a currently running Angular app\n\t * from outside Angular. Perhaps, you want to inject and compile some markup after the\n\t * application has been bootstrapped. You can do this using the extra `injector()` added\n\t * to JQuery/jqLite elements. See {@link angular.element}.\n\t *\n\t * *This is fairly rare but could be the case if a third party library is injecting the\n\t * markup.*\n\t *\n\t * In the following example a new block of HTML containing a `ng-controller`\n\t * directive is added to the end of the document body by JQuery. We then compile and link\n\t * it into the current AngularJS scope.\n\t *\n\t * ```js\n\t * var $div = $('
{{content.label}}
');\n\t * $(document.body).append($div);\n\t *\n\t * angular.element(document).injector().invoke(function($compile) {\n\t * var scope = angular.element($div).scope();\n\t * $compile($div)(scope);\n\t * });\n\t * ```\n\t */\n\t\n\t\n\t/**\n\t * @ngdoc module\n\t * @name auto\n\t * @description\n\t *\n\t * Implicit module which gets automatically added to each {@link auto.$injector $injector}.\n\t */\n\t\n\tvar FN_ARGS = /^[^\\(]*\\(\\s*([^\\)]*)\\)/m;\n\tvar FN_ARG_SPLIT = /,/;\n\tvar FN_ARG = /^\\s*(_?)(\\S+?)\\1\\s*$/;\n\tvar STRIP_COMMENTS = /((\\/\\/.*$)|(\\/\\*[\\s\\S]*?\\*\\/))/mg;\n\tvar $injectorMinErr = minErr('$injector');\n\t\n\tfunction anonFn(fn) {\n\t // For anonymous functions, showing at the very least the function signature can help in\n\t // debugging.\n\t var fnText = fn.toString().replace(STRIP_COMMENTS, ''),\n\t args = fnText.match(FN_ARGS);\n\t if (args) {\n\t return 'function(' + (args[1] || '').replace(/[\\s\\r\\n]+/, ' ') + ')';\n\t }\n\t return 'fn';\n\t}\n\t\n\tfunction annotate(fn, strictDi, name) {\n\t var $inject,\n\t fnText,\n\t argDecl,\n\t last;\n\t\n\t if (typeof fn === 'function') {\n\t if (!($inject = fn.$inject)) {\n\t $inject = [];\n\t if (fn.length) {\n\t if (strictDi) {\n\t if (!isString(name) || !name) {\n\t name = fn.name || anonFn(fn);\n\t }\n\t throw $injectorMinErr('strictdi',\n\t '{0} is not using explicit annotation and cannot be invoked in strict mode', name);\n\t }\n\t fnText = fn.toString().replace(STRIP_COMMENTS, '');\n\t argDecl = fnText.match(FN_ARGS);\n\t forEach(argDecl[1].split(FN_ARG_SPLIT), function(arg) {\n\t arg.replace(FN_ARG, function(all, underscore, name) {\n\t $inject.push(name);\n\t });\n\t });\n\t }\n\t fn.$inject = $inject;\n\t }\n\t } else if (isArray(fn)) {\n\t last = fn.length - 1;\n\t assertArgFn(fn[last], 'fn');\n\t $inject = fn.slice(0, last);\n\t } else {\n\t assertArgFn(fn, 'fn', true);\n\t }\n\t return $inject;\n\t}\n\t\n\t///////////////////////////////////////\n\t\n\t/**\n\t * @ngdoc service\n\t * @name $injector\n\t *\n\t * @description\n\t *\n\t * `$injector` is used to retrieve object instances as defined by\n\t * {@link auto.$provide provider}, instantiate types, invoke methods,\n\t * and load modules.\n\t *\n\t * The following always holds true:\n\t *\n\t * ```js\n\t * var $injector = angular.injector();\n\t * expect($injector.get('$injector')).toBe($injector);\n\t * expect($injector.invoke(function($injector) {\n\t * return $injector;\n\t * })).toBe($injector);\n\t * ```\n\t *\n\t * # Injection Function Annotation\n\t *\n\t * JavaScript does not have annotations, and annotations are needed for dependency injection. The\n\t * following are all valid ways of annotating function with injection arguments and are equivalent.\n\t *\n\t * ```js\n\t * // inferred (only works if code not minified/obfuscated)\n\t * $injector.invoke(function(serviceA){});\n\t *\n\t * // annotated\n\t * function explicit(serviceA) {};\n\t * explicit.$inject = ['serviceA'];\n\t * $injector.invoke(explicit);\n\t *\n\t * // inline\n\t * $injector.invoke(['serviceA', function(serviceA){}]);\n\t * ```\n\t *\n\t * ## Inference\n\t *\n\t * In JavaScript calling `toString()` on a function returns the function definition. The definition\n\t * can then be parsed and the function arguments can be extracted. This method of discovering\n\t * annotations is disallowed when the injector is in strict mode.\n\t * *NOTE:* This does not work with minification, and obfuscation tools since these tools change the\n\t * argument names.\n\t *\n\t * ## `$inject` Annotation\n\t * By adding an `$inject` property onto a function the injection parameters can be specified.\n\t *\n\t * ## Inline\n\t * As an array of injection names, where the last item in the array is the function to call.\n\t */\n\t\n\t/**\n\t * @ngdoc method\n\t * @name $injector#get\n\t *\n\t * @description\n\t * Return an instance of the service.\n\t *\n\t * @param {string} name The name of the instance to retrieve.\n\t * @param {string=} caller An optional string to provide the origin of the function call for error messages.\n\t * @return {*} The instance.\n\t */\n\t\n\t/**\n\t * @ngdoc method\n\t * @name $injector#invoke\n\t *\n\t * @description\n\t * Invoke the method and supply the method arguments from the `$injector`.\n\t *\n\t * @param {Function|Array.} fn The injectable function to invoke. Function parameters are\n\t * injected according to the {@link guide/di $inject Annotation} rules.\n\t * @param {Object=} self The `this` for the invoked method.\n\t * @param {Object=} locals Optional object. If preset then any argument names are read from this\n\t * object first, before the `$injector` is consulted.\n\t * @returns {*} the value returned by the invoked `fn` function.\n\t */\n\t\n\t/**\n\t * @ngdoc method\n\t * @name $injector#has\n\t *\n\t * @description\n\t * Allows the user to query if the particular service exists.\n\t *\n\t * @param {string} name Name of the service to query.\n\t * @returns {boolean} `true` if injector has given service.\n\t */\n\t\n\t/**\n\t * @ngdoc method\n\t * @name $injector#instantiate\n\t * @description\n\t * Create a new instance of JS type. The method takes a constructor function, invokes the new\n\t * operator, and supplies all of the arguments to the constructor function as specified by the\n\t * constructor annotation.\n\t *\n\t * @param {Function} Type Annotated constructor function.\n\t * @param {Object=} locals Optional object. If preset then any argument names are read from this\n\t * object first, before the `$injector` is consulted.\n\t * @returns {Object} new instance of `Type`.\n\t */\n\t\n\t/**\n\t * @ngdoc method\n\t * @name $injector#annotate\n\t *\n\t * @description\n\t * Returns an array of service names which the function is requesting for injection. This API is\n\t * used by the injector to determine which services need to be injected into the function when the\n\t * function is invoked. There are three ways in which the function can be annotated with the needed\n\t * dependencies.\n\t *\n\t * # Argument names\n\t *\n\t * The simplest form is to extract the dependencies from the arguments of the function. This is done\n\t * by converting the function into a string using `toString()` method and extracting the argument\n\t * names.\n\t * ```js\n\t * // Given\n\t * function MyController($scope, $route) {\n\t * // ...\n\t * }\n\t *\n\t * // Then\n\t * expect(injector.annotate(MyController)).toEqual(['$scope', '$route']);\n\t * ```\n\t *\n\t * You can disallow this method by using strict injection mode.\n\t *\n\t * This method does not work with code minification / obfuscation. For this reason the following\n\t * annotation strategies are supported.\n\t *\n\t * # The `$inject` property\n\t *\n\t * If a function has an `$inject` property and its value is an array of strings, then the strings\n\t * represent names of services to be injected into the function.\n\t * ```js\n\t * // Given\n\t * var MyController = function(obfuscatedScope, obfuscatedRoute) {\n\t * // ...\n\t * }\n\t * // Define function dependencies\n\t * MyController['$inject'] = ['$scope', '$route'];\n\t *\n\t * // Then\n\t * expect(injector.annotate(MyController)).toEqual(['$scope', '$route']);\n\t * ```\n\t *\n\t * # The array notation\n\t *\n\t * It is often desirable to inline Injected functions and that's when setting the `$inject` property\n\t * is very inconvenient. In these situations using the array notation to specify the dependencies in\n\t * a way that survives minification is a better choice:\n\t *\n\t * ```js\n\t * // We wish to write this (not minification / obfuscation safe)\n\t * injector.invoke(function($compile, $rootScope) {\n\t * // ...\n\t * });\n\t *\n\t * // We are forced to write break inlining\n\t * var tmpFn = function(obfuscatedCompile, obfuscatedRootScope) {\n\t * // ...\n\t * };\n\t * tmpFn.$inject = ['$compile', '$rootScope'];\n\t * injector.invoke(tmpFn);\n\t *\n\t * // To better support inline function the inline annotation is supported\n\t * injector.invoke(['$compile', '$rootScope', function(obfCompile, obfRootScope) {\n\t * // ...\n\t * }]);\n\t *\n\t * // Therefore\n\t * expect(injector.annotate(\n\t * ['$compile', '$rootScope', function(obfus_$compile, obfus_$rootScope) {}])\n\t * ).toEqual(['$compile', '$rootScope']);\n\t * ```\n\t *\n\t * @param {Function|Array.} fn Function for which dependent service names need to\n\t * be retrieved as described above.\n\t *\n\t * @param {boolean=} [strictDi=false] Disallow argument name annotation inference.\n\t *\n\t * @returns {Array.} The names of the services which the function requires.\n\t */\n\t\n\t\n\t\n\t\n\t/**\n\t * @ngdoc service\n\t * @name $provide\n\t *\n\t * @description\n\t *\n\t * The {@link auto.$provide $provide} service has a number of methods for registering components\n\t * with the {@link auto.$injector $injector}. Many of these functions are also exposed on\n\t * {@link angular.Module}.\n\t *\n\t * An Angular **service** is a singleton object created by a **service factory**. These **service\n\t * factories** are functions which, in turn, are created by a **service provider**.\n\t * The **service providers** are constructor functions. When instantiated they must contain a\n\t * property called `$get`, which holds the **service factory** function.\n\t *\n\t * When you request a service, the {@link auto.$injector $injector} is responsible for finding the\n\t * correct **service provider**, instantiating it and then calling its `$get` **service factory**\n\t * function to get the instance of the **service**.\n\t *\n\t * Often services have no configuration options and there is no need to add methods to the service\n\t * provider. The provider will be no more than a constructor function with a `$get` property. For\n\t * these cases the {@link auto.$provide $provide} service has additional helper methods to register\n\t * services without specifying a provider.\n\t *\n\t * * {@link auto.$provide#provider provider(provider)} - registers a **service provider** with the\n\t * {@link auto.$injector $injector}\n\t * * {@link auto.$provide#constant constant(obj)} - registers a value/object that can be accessed by\n\t * providers and services.\n\t * * {@link auto.$provide#value value(obj)} - registers a value/object that can only be accessed by\n\t * services, not providers.\n\t * * {@link auto.$provide#factory factory(fn)} - registers a service **factory function**, `fn`,\n\t * that will be wrapped in a **service provider** object, whose `$get` property will contain the\n\t * given factory function.\n\t * * {@link auto.$provide#service service(class)} - registers a **constructor function**, `class`\n\t * that will be wrapped in a **service provider** object, whose `$get` property will instantiate\n\t * a new object using the given constructor function.\n\t *\n\t * See the individual methods for more information and examples.\n\t */\n\t\n\t/**\n\t * @ngdoc method\n\t * @name $provide#provider\n\t * @description\n\t *\n\t * Register a **provider function** with the {@link auto.$injector $injector}. Provider functions\n\t * are constructor functions, whose instances are responsible for \"providing\" a factory for a\n\t * service.\n\t *\n\t * Service provider names start with the name of the service they provide followed by `Provider`.\n\t * For example, the {@link ng.$log $log} service has a provider called\n\t * {@link ng.$logProvider $logProvider}.\n\t *\n\t * Service provider objects can have additional methods which allow configuration of the provider\n\t * and its service. Importantly, you can configure what kind of service is created by the `$get`\n\t * method, or how that service will act. For example, the {@link ng.$logProvider $logProvider} has a\n\t * method {@link ng.$logProvider#debugEnabled debugEnabled}\n\t * which lets you specify whether the {@link ng.$log $log} service will log debug messages to the\n\t * console or not.\n\t *\n\t * @param {string} name The name of the instance. NOTE: the provider will be available under `name +\n\t 'Provider'` key.\n\t * @param {(Object|function())} provider If the provider is:\n\t *\n\t * - `Object`: then it should have a `$get` method. The `$get` method will be invoked using\n\t * {@link auto.$injector#invoke $injector.invoke()} when an instance needs to be created.\n\t * - `Constructor`: a new instance of the provider will be created using\n\t * {@link auto.$injector#instantiate $injector.instantiate()}, then treated as `object`.\n\t *\n\t * @returns {Object} registered provider instance\n\t\n\t * @example\n\t *\n\t * The following example shows how to create a simple event tracking service and register it using\n\t * {@link auto.$provide#provider $provide.provider()}.\n\t *\n\t * ```js\n\t * // Define the eventTracker provider\n\t * function EventTrackerProvider() {\n\t * var trackingUrl = '/track';\n\t *\n\t * // A provider method for configuring where the tracked events should been saved\n\t * this.setTrackingUrl = function(url) {\n\t * trackingUrl = url;\n\t * };\n\t *\n\t * // The service factory function\n\t * this.$get = ['$http', function($http) {\n\t * var trackedEvents = {};\n\t * return {\n\t * // Call this to track an event\n\t * event: function(event) {\n\t * var count = trackedEvents[event] || 0;\n\t * count += 1;\n\t * trackedEvents[event] = count;\n\t * return count;\n\t * },\n\t * // Call this to save the tracked events to the trackingUrl\n\t * save: function() {\n\t * $http.post(trackingUrl, trackedEvents);\n\t * }\n\t * };\n\t * }];\n\t * }\n\t *\n\t * describe('eventTracker', function() {\n\t * var postSpy;\n\t *\n\t * beforeEach(module(function($provide) {\n\t * // Register the eventTracker provider\n\t * $provide.provider('eventTracker', EventTrackerProvider);\n\t * }));\n\t *\n\t * beforeEach(module(function(eventTrackerProvider) {\n\t * // Configure eventTracker provider\n\t * eventTrackerProvider.setTrackingUrl('/custom-track');\n\t * }));\n\t *\n\t * it('tracks events', inject(function(eventTracker) {\n\t * expect(eventTracker.event('login')).toEqual(1);\n\t * expect(eventTracker.event('login')).toEqual(2);\n\t * }));\n\t *\n\t * it('saves to the tracking url', inject(function(eventTracker, $http) {\n\t * postSpy = spyOn($http, 'post');\n\t * eventTracker.event('login');\n\t * eventTracker.save();\n\t * expect(postSpy).toHaveBeenCalled();\n\t * expect(postSpy.mostRecentCall.args[0]).not.toEqual('/track');\n\t * expect(postSpy.mostRecentCall.args[0]).toEqual('/custom-track');\n\t * expect(postSpy.mostRecentCall.args[1]).toEqual({ 'login': 1 });\n\t * }));\n\t * });\n\t * ```\n\t */\n\t\n\t/**\n\t * @ngdoc method\n\t * @name $provide#factory\n\t * @description\n\t *\n\t * Register a **service factory**, which will be called to return the service instance.\n\t * This is short for registering a service where its provider consists of only a `$get` property,\n\t * which is the given service factory function.\n\t * You should use {@link auto.$provide#factory $provide.factory(getFn)} if you do not need to\n\t * configure your service in a provider.\n\t *\n\t * @param {string} name The name of the instance.\n\t * @param {Function|Array.} $getFn The injectable $getFn for the instance creation.\n\t * Internally this is a short hand for `$provide.provider(name, {$get: $getFn})`.\n\t * @returns {Object} registered provider instance\n\t *\n\t * @example\n\t * Here is an example of registering a service\n\t * ```js\n\t * $provide.factory('ping', ['$http', function($http) {\n\t * return function ping() {\n\t * return $http.send('/ping');\n\t * };\n\t * }]);\n\t * ```\n\t * You would then inject and use this service like this:\n\t * ```js\n\t * someModule.controller('Ctrl', ['ping', function(ping) {\n\t * ping();\n\t * }]);\n\t * ```\n\t */\n\t\n\t\n\t/**\n\t * @ngdoc method\n\t * @name $provide#service\n\t * @description\n\t *\n\t * Register a **service constructor**, which will be invoked with `new` to create the service\n\t * instance.\n\t * This is short for registering a service where its provider's `$get` property is a factory\n\t * function that returns an instance instantiated by the injector from the service constructor\n\t * function.\n\t *\n\t * Internally it looks a bit like this:\n\t *\n\t * ```\n\t * {\n\t * $get: function() {\n\t * return $injector.instantiate(constructor);\n\t * }\n\t * }\n\t * ```\n\t *\n\t *\n\t * You should use {@link auto.$provide#service $provide.service(class)} if you define your service\n\t * as a type/class.\n\t *\n\t * @param {string} name The name of the instance.\n\t * @param {Function|Array.} constructor An injectable class (constructor function)\n\t * that will be instantiated.\n\t * @returns {Object} registered provider instance\n\t *\n\t * @example\n\t * Here is an example of registering a service using\n\t * {@link auto.$provide#service $provide.service(class)}.\n\t * ```js\n\t * var Ping = function($http) {\n\t * this.$http = $http;\n\t * };\n\t *\n\t * Ping.$inject = ['$http'];\n\t *\n\t * Ping.prototype.send = function() {\n\t * return this.$http.get('/ping');\n\t * };\n\t * $provide.service('ping', Ping);\n\t * ```\n\t * You would then inject and use this service like this:\n\t * ```js\n\t * someModule.controller('Ctrl', ['ping', function(ping) {\n\t * ping.send();\n\t * }]);\n\t * ```\n\t */\n\t\n\t\n\t/**\n\t * @ngdoc method\n\t * @name $provide#value\n\t * @description\n\t *\n\t * Register a **value service** with the {@link auto.$injector $injector}, such as a string, a\n\t * number, an array, an object or a function. This is short for registering a service where its\n\t * provider's `$get` property is a factory function that takes no arguments and returns the **value\n\t * service**. That also means it is not possible to inject other services into a value service.\n\t *\n\t * Value services are similar to constant services, except that they cannot be injected into a\n\t * module configuration function (see {@link angular.Module#config}) but they can be overridden by\n\t * an Angular {@link auto.$provide#decorator decorator}.\n\t *\n\t * @param {string} name The name of the instance.\n\t * @param {*} value The value.\n\t * @returns {Object} registered provider instance\n\t *\n\t * @example\n\t * Here are some examples of creating value services.\n\t * ```js\n\t * $provide.value('ADMIN_USER', 'admin');\n\t *\n\t * $provide.value('RoleLookup', { admin: 0, writer: 1, reader: 2 });\n\t *\n\t * $provide.value('halfOf', function(value) {\n\t * return value / 2;\n\t * });\n\t * ```\n\t */\n\t\n\t\n\t/**\n\t * @ngdoc method\n\t * @name $provide#constant\n\t * @description\n\t *\n\t * Register a **constant service** with the {@link auto.$injector $injector}, such as a string,\n\t * a number, an array, an object or a function. Like the {@link auto.$provide#value value}, it is not\n\t * possible to inject other services into a constant.\n\t *\n\t * But unlike {@link auto.$provide#value value}, a constant can be\n\t * injected into a module configuration function (see {@link angular.Module#config}) and it cannot\n\t * be overridden by an Angular {@link auto.$provide#decorator decorator}.\n\t *\n\t * @param {string} name The name of the constant.\n\t * @param {*} value The constant value.\n\t * @returns {Object} registered instance\n\t *\n\t * @example\n\t * Here a some examples of creating constants:\n\t * ```js\n\t * $provide.constant('SHARD_HEIGHT', 306);\n\t *\n\t * $provide.constant('MY_COLOURS', ['red', 'blue', 'grey']);\n\t *\n\t * $provide.constant('double', function(value) {\n\t * return value * 2;\n\t * });\n\t * ```\n\t */\n\t\n\t\n\t/**\n\t * @ngdoc method\n\t * @name $provide#decorator\n\t * @description\n\t *\n\t * Register a **service decorator** with the {@link auto.$injector $injector}. A service decorator\n\t * intercepts the creation of a service, allowing it to override or modify the behavior of the\n\t * service. The object returned by the decorator may be the original service, or a new service\n\t * object which replaces or wraps and delegates to the original service.\n\t *\n\t * @param {string} name The name of the service to decorate.\n\t * @param {Function|Array.} decorator This function will be invoked when the service needs to be\n\t * instantiated and should return the decorated service instance. The function is called using\n\t * the {@link auto.$injector#invoke injector.invoke} method and is therefore fully injectable.\n\t * Local injection arguments:\n\t *\n\t * * `$delegate` - The original service instance, which can be monkey patched, configured,\n\t * decorated or delegated to.\n\t *\n\t * @example\n\t * Here we decorate the {@link ng.$log $log} service to convert warnings to errors by intercepting\n\t * calls to {@link ng.$log#error $log.warn()}.\n\t * ```js\n\t * $provide.decorator('$log', ['$delegate', function($delegate) {\n\t * $delegate.warn = $delegate.error;\n\t * return $delegate;\n\t * }]);\n\t * ```\n\t */\n\t\n\t\n\tfunction createInjector(modulesToLoad, strictDi) {\n\t strictDi = (strictDi === true);\n\t var INSTANTIATING = {},\n\t providerSuffix = 'Provider',\n\t path = [],\n\t loadedModules = new HashMap([], true),\n\t providerCache = {\n\t $provide: {\n\t provider: supportObject(provider),\n\t factory: supportObject(factory),\n\t service: supportObject(service),\n\t value: supportObject(value),\n\t constant: supportObject(constant),\n\t decorator: decorator\n\t }\n\t },\n\t providerInjector = (providerCache.$injector =\n\t createInternalInjector(providerCache, function(serviceName, caller) {\n\t if (angular.isString(caller)) {\n\t path.push(caller);\n\t }\n\t throw $injectorMinErr('unpr', \"Unknown provider: {0}\", path.join(' <- '));\n\t })),\n\t instanceCache = {},\n\t instanceInjector = (instanceCache.$injector =\n\t createInternalInjector(instanceCache, function(serviceName, caller) {\n\t var provider = providerInjector.get(serviceName + providerSuffix, caller);\n\t return instanceInjector.invoke(provider.$get, provider, undefined, serviceName);\n\t }));\n\t\n\t\n\t forEach(loadModules(modulesToLoad), function(fn) { if (fn) instanceInjector.invoke(fn); });\n\t\n\t return instanceInjector;\n\t\n\t ////////////////////////////////////\n\t // $provider\n\t ////////////////////////////////////\n\t\n\t function supportObject(delegate) {\n\t return function(key, value) {\n\t if (isObject(key)) {\n\t forEach(key, reverseParams(delegate));\n\t } else {\n\t return delegate(key, value);\n\t }\n\t };\n\t }\n\t\n\t function provider(name, provider_) {\n\t assertNotHasOwnProperty(name, 'service');\n\t if (isFunction(provider_) || isArray(provider_)) {\n\t provider_ = providerInjector.instantiate(provider_);\n\t }\n\t if (!provider_.$get) {\n\t throw $injectorMinErr('pget', \"Provider '{0}' must define $get factory method.\", name);\n\t }\n\t return providerCache[name + providerSuffix] = provider_;\n\t }\n\t\n\t function enforceReturnValue(name, factory) {\n\t return function enforcedReturnValue() {\n\t var result = instanceInjector.invoke(factory, this);\n\t if (isUndefined(result)) {\n\t throw $injectorMinErr('undef', \"Provider '{0}' must return a value from $get factory method.\", name);\n\t }\n\t return result;\n\t };\n\t }\n\t\n\t function factory(name, factoryFn, enforce) {\n\t return provider(name, {\n\t $get: enforce !== false ? enforceReturnValue(name, factoryFn) : factoryFn\n\t });\n\t }\n\t\n\t function service(name, constructor) {\n\t return factory(name, ['$injector', function($injector) {\n\t return $injector.instantiate(constructor);\n\t }]);\n\t }\n\t\n\t function value(name, val) { return factory(name, valueFn(val), false); }\n\t\n\t function constant(name, value) {\n\t assertNotHasOwnProperty(name, 'constant');\n\t providerCache[name] = value;\n\t instanceCache[name] = value;\n\t }\n\t\n\t function decorator(serviceName, decorFn) {\n\t var origProvider = providerInjector.get(serviceName + providerSuffix),\n\t orig$get = origProvider.$get;\n\t\n\t origProvider.$get = function() {\n\t var origInstance = instanceInjector.invoke(orig$get, origProvider);\n\t return instanceInjector.invoke(decorFn, null, {$delegate: origInstance});\n\t };\n\t }\n\t\n\t ////////////////////////////////////\n\t // Module Loading\n\t ////////////////////////////////////\n\t function loadModules(modulesToLoad) {\n\t assertArg(isUndefined(modulesToLoad) || isArray(modulesToLoad), 'modulesToLoad', 'not an array');\n\t var runBlocks = [], moduleFn;\n\t forEach(modulesToLoad, function(module) {\n\t if (loadedModules.get(module)) return;\n\t loadedModules.put(module, true);\n\t\n\t function runInvokeQueue(queue) {\n\t var i, ii;\n\t for (i = 0, ii = queue.length; i < ii; i++) {\n\t var invokeArgs = queue[i],\n\t provider = providerInjector.get(invokeArgs[0]);\n\t\n\t provider[invokeArgs[1]].apply(provider, invokeArgs[2]);\n\t }\n\t }\n\t\n\t try {\n\t if (isString(module)) {\n\t moduleFn = angularModule(module);\n\t runBlocks = runBlocks.concat(loadModules(moduleFn.requires)).concat(moduleFn._runBlocks);\n\t runInvokeQueue(moduleFn._invokeQueue);\n\t runInvokeQueue(moduleFn._configBlocks);\n\t } else if (isFunction(module)) {\n\t runBlocks.push(providerInjector.invoke(module));\n\t } else if (isArray(module)) {\n\t runBlocks.push(providerInjector.invoke(module));\n\t } else {\n\t assertArgFn(module, 'module');\n\t }\n\t } catch (e) {\n\t if (isArray(module)) {\n\t module = module[module.length - 1];\n\t }\n\t if (e.message && e.stack && e.stack.indexOf(e.message) == -1) {\n\t // Safari & FF's stack traces don't contain error.message content\n\t // unlike those of Chrome and IE\n\t // So if stack doesn't contain message, we create a new string that contains both.\n\t // Since error.stack is read-only in Safari, I'm overriding e and not e.stack here.\n\t /* jshint -W022 */\n\t e = e.message + '\\n' + e.stack;\n\t }\n\t throw $injectorMinErr('modulerr', \"Failed to instantiate module {0} due to:\\n{1}\",\n\t module, e.stack || e.message || e);\n\t }\n\t });\n\t return runBlocks;\n\t }\n\t\n\t ////////////////////////////////////\n\t // internal Injector\n\t ////////////////////////////////////\n\t\n\t function createInternalInjector(cache, factory) {\n\t\n\t function getService(serviceName, caller) {\n\t if (cache.hasOwnProperty(serviceName)) {\n\t if (cache[serviceName] === INSTANTIATING) {\n\t throw $injectorMinErr('cdep', 'Circular dependency found: {0}',\n\t serviceName + ' <- ' + path.join(' <- '));\n\t }\n\t return cache[serviceName];\n\t } else {\n\t try {\n\t path.unshift(serviceName);\n\t cache[serviceName] = INSTANTIATING;\n\t return cache[serviceName] = factory(serviceName, caller);\n\t } catch (err) {\n\t if (cache[serviceName] === INSTANTIATING) {\n\t delete cache[serviceName];\n\t }\n\t throw err;\n\t } finally {\n\t path.shift();\n\t }\n\t }\n\t }\n\t\n\t function invoke(fn, self, locals, serviceName) {\n\t if (typeof locals === 'string') {\n\t serviceName = locals;\n\t locals = null;\n\t }\n\t\n\t var args = [],\n\t $inject = createInjector.$$annotate(fn, strictDi, serviceName),\n\t length, i,\n\t key;\n\t\n\t for (i = 0, length = $inject.length; i < length; i++) {\n\t key = $inject[i];\n\t if (typeof key !== 'string') {\n\t throw $injectorMinErr('itkn',\n\t 'Incorrect injection token! Expected service name as string, got {0}', key);\n\t }\n\t args.push(\n\t locals && locals.hasOwnProperty(key)\n\t ? locals[key]\n\t : getService(key, serviceName)\n\t );\n\t }\n\t if (isArray(fn)) {\n\t fn = fn[length];\n\t }\n\t\n\t // http://jsperf.com/angularjs-invoke-apply-vs-switch\n\t // #5388\n\t return fn.apply(self, args);\n\t }\n\t\n\t function instantiate(Type, locals, serviceName) {\n\t // Check if Type is annotated and use just the given function at n-1 as parameter\n\t // e.g. someModule.factory('greeter', ['$window', function(renamed$window) {}]);\n\t // Object creation: http://jsperf.com/create-constructor/2\n\t var instance = Object.create((isArray(Type) ? Type[Type.length - 1] : Type).prototype || null);\n\t var returnedValue = invoke(Type, instance, locals, serviceName);\n\t\n\t return isObject(returnedValue) || isFunction(returnedValue) ? returnedValue : instance;\n\t }\n\t\n\t return {\n\t invoke: invoke,\n\t instantiate: instantiate,\n\t get: getService,\n\t annotate: createInjector.$$annotate,\n\t has: function(name) {\n\t return providerCache.hasOwnProperty(name + providerSuffix) || cache.hasOwnProperty(name);\n\t }\n\t };\n\t }\n\t}\n\t\n\tcreateInjector.$$annotate = annotate;\n\t\n\t/**\n\t * @ngdoc provider\n\t * @name $anchorScrollProvider\n\t *\n\t * @description\n\t * Use `$anchorScrollProvider` to disable automatic scrolling whenever\n\t * {@link ng.$location#hash $location.hash()} changes.\n\t */\n\tfunction $AnchorScrollProvider() {\n\t\n\t var autoScrollingEnabled = true;\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $anchorScrollProvider#disableAutoScrolling\n\t *\n\t * @description\n\t * By default, {@link ng.$anchorScroll $anchorScroll()} will automatically detect changes to\n\t * {@link ng.$location#hash $location.hash()} and scroll to the element matching the new hash.
\n\t * Use this method to disable automatic scrolling.\n\t *\n\t * If automatic scrolling is disabled, one must explicitly call\n\t * {@link ng.$anchorScroll $anchorScroll()} in order to scroll to the element related to the\n\t * current hash.\n\t */\n\t this.disableAutoScrolling = function() {\n\t autoScrollingEnabled = false;\n\t };\n\t\n\t /**\n\t * @ngdoc service\n\t * @name $anchorScroll\n\t * @kind function\n\t * @requires $window\n\t * @requires $location\n\t * @requires $rootScope\n\t *\n\t * @description\n\t * When called, it scrolls to the element related to the specified `hash` or (if omitted) to the\n\t * current value of {@link ng.$location#hash $location.hash()}, according to the rules specified\n\t * in the\n\t * [HTML5 spec](http://www.w3.org/html/wg/drafts/html/master/browsers.html#an-indicated-part-of-the-document).\n\t *\n\t * It also watches the {@link ng.$location#hash $location.hash()} and automatically scrolls to\n\t * match any anchor whenever it changes. This can be disabled by calling\n\t * {@link ng.$anchorScrollProvider#disableAutoScrolling $anchorScrollProvider.disableAutoScrolling()}.\n\t *\n\t * Additionally, you can use its {@link ng.$anchorScroll#yOffset yOffset} property to specify a\n\t * vertical scroll-offset (either fixed or dynamic).\n\t *\n\t * @param {string=} hash The hash specifying the element to scroll to. If omitted, the value of\n\t * {@link ng.$location#hash $location.hash()} will be used.\n\t *\n\t * @property {(number|function|jqLite)} yOffset\n\t * If set, specifies a vertical scroll-offset. This is often useful when there are fixed\n\t * positioned elements at the top of the page, such as navbars, headers etc.\n\t *\n\t * `yOffset` can be specified in various ways:\n\t * - **number**: A fixed number of pixels to be used as offset.

\n\t * - **function**: A getter function called everytime `$anchorScroll()` is executed. Must return\n\t * a number representing the offset (in pixels).

\n\t * - **jqLite**: A jqLite/jQuery element to be used for specifying the offset. The distance from\n\t * the top of the page to the element's bottom will be used as offset.
\n\t * **Note**: The element will be taken into account only as long as its `position` is set to\n\t * `fixed`. This option is useful, when dealing with responsive navbars/headers that adjust\n\t * their height and/or positioning according to the viewport's size.\n\t *\n\t *
\n\t *
\n\t * In order for `yOffset` to work properly, scrolling should take place on the document's root and\n\t * not some child element.\n\t *
\n\t *\n\t * @example\n\t \n\t \n\t
\n\t Go to bottom\n\t You're at the bottom!\n\t
\n\t
\n\t \n\t angular.module('anchorScrollExample', [])\n\t .controller('ScrollController', ['$scope', '$location', '$anchorScroll',\n\t function ($scope, $location, $anchorScroll) {\n\t $scope.gotoBottom = function() {\n\t // set the location.hash to the id of\n\t // the element you wish to scroll to.\n\t $location.hash('bottom');\n\t\n\t // call $anchorScroll()\n\t $anchorScroll();\n\t };\n\t }]);\n\t \n\t \n\t #scrollArea {\n\t height: 280px;\n\t overflow: auto;\n\t }\n\t\n\t #bottom {\n\t display: block;\n\t margin-top: 2000px;\n\t }\n\t \n\t
\n\t *\n\t *
\n\t * The example below illustrates the use of a vertical scroll-offset (specified as a fixed value).\n\t * See {@link ng.$anchorScroll#yOffset $anchorScroll.yOffset} for more details.\n\t *\n\t * @example\n\t \n\t \n\t \n\t
\n\t Anchor {{x}} of 5\n\t
\n\t
\n\t \n\t angular.module('anchorScrollOffsetExample', [])\n\t .run(['$anchorScroll', function($anchorScroll) {\n\t $anchorScroll.yOffset = 50; // always scroll by 50 extra pixels\n\t }])\n\t .controller('headerCtrl', ['$anchorScroll', '$location', '$scope',\n\t function ($anchorScroll, $location, $scope) {\n\t $scope.gotoAnchor = function(x) {\n\t var newHash = 'anchor' + x;\n\t if ($location.hash() !== newHash) {\n\t // set the $location.hash to `newHash` and\n\t // $anchorScroll will automatically scroll to it\n\t $location.hash('anchor' + x);\n\t } else {\n\t // call $anchorScroll() explicitly,\n\t // since $location.hash hasn't changed\n\t $anchorScroll();\n\t }\n\t };\n\t }\n\t ]);\n\t \n\t \n\t body {\n\t padding-top: 50px;\n\t }\n\t\n\t .anchor {\n\t border: 2px dashed DarkOrchid;\n\t padding: 10px 10px 200px 10px;\n\t }\n\t\n\t .fixed-header {\n\t background-color: rgba(0, 0, 0, 0.2);\n\t height: 50px;\n\t position: fixed;\n\t top: 0; left: 0; right: 0;\n\t }\n\t\n\t .fixed-header > a {\n\t display: inline-block;\n\t margin: 5px 15px;\n\t }\n\t \n\t
\n\t */\n\t this.$get = ['$window', '$location', '$rootScope', function($window, $location, $rootScope) {\n\t var document = $window.document;\n\t\n\t // Helper function to get first anchor from a NodeList\n\t // (using `Array#some()` instead of `angular#forEach()` since it's more performant\n\t // and working in all supported browsers.)\n\t function getFirstAnchor(list) {\n\t var result = null;\n\t Array.prototype.some.call(list, function(element) {\n\t if (nodeName_(element) === 'a') {\n\t result = element;\n\t return true;\n\t }\n\t });\n\t return result;\n\t }\n\t\n\t function getYOffset() {\n\t\n\t var offset = scroll.yOffset;\n\t\n\t if (isFunction(offset)) {\n\t offset = offset();\n\t } else if (isElement(offset)) {\n\t var elem = offset[0];\n\t var style = $window.getComputedStyle(elem);\n\t if (style.position !== 'fixed') {\n\t offset = 0;\n\t } else {\n\t offset = elem.getBoundingClientRect().bottom;\n\t }\n\t } else if (!isNumber(offset)) {\n\t offset = 0;\n\t }\n\t\n\t return offset;\n\t }\n\t\n\t function scrollTo(elem) {\n\t if (elem) {\n\t elem.scrollIntoView();\n\t\n\t var offset = getYOffset();\n\t\n\t if (offset) {\n\t // `offset` is the number of pixels we should scroll UP in order to align `elem` properly.\n\t // This is true ONLY if the call to `elem.scrollIntoView()` initially aligns `elem` at the\n\t // top of the viewport.\n\t //\n\t // IF the number of pixels from the top of `elem` to the end of the page's content is less\n\t // than the height of the viewport, then `elem.scrollIntoView()` will align the `elem` some\n\t // way down the page.\n\t //\n\t // This is often the case for elements near the bottom of the page.\n\t //\n\t // In such cases we do not need to scroll the whole `offset` up, just the difference between\n\t // the top of the element and the offset, which is enough to align the top of `elem` at the\n\t // desired position.\n\t var elemTop = elem.getBoundingClientRect().top;\n\t $window.scrollBy(0, elemTop - offset);\n\t }\n\t } else {\n\t $window.scrollTo(0, 0);\n\t }\n\t }\n\t\n\t function scroll(hash) {\n\t hash = isString(hash) ? hash : $location.hash();\n\t var elm;\n\t\n\t // empty hash, scroll to the top of the page\n\t if (!hash) scrollTo(null);\n\t\n\t // element with given id\n\t else if ((elm = document.getElementById(hash))) scrollTo(elm);\n\t\n\t // first anchor with given name :-D\n\t else if ((elm = getFirstAnchor(document.getElementsByName(hash)))) scrollTo(elm);\n\t\n\t // no element and hash == 'top', scroll to the top of the page\n\t else if (hash === 'top') scrollTo(null);\n\t }\n\t\n\t // does not scroll when user clicks on anchor link that is currently on\n\t // (no url change, no $location.hash() change), browser native does scroll\n\t if (autoScrollingEnabled) {\n\t $rootScope.$watch(function autoScrollWatch() {return $location.hash();},\n\t function autoScrollWatchAction(newVal, oldVal) {\n\t // skip the initial scroll if $location.hash is empty\n\t if (newVal === oldVal && newVal === '') return;\n\t\n\t jqLiteDocumentLoaded(function() {\n\t $rootScope.$evalAsync(scroll);\n\t });\n\t });\n\t }\n\t\n\t return scroll;\n\t }];\n\t}\n\t\n\tvar $animateMinErr = minErr('$animate');\n\tvar ELEMENT_NODE = 1;\n\tvar NG_ANIMATE_CLASSNAME = 'ng-animate';\n\t\n\tfunction mergeClasses(a,b) {\n\t if (!a && !b) return '';\n\t if (!a) return b;\n\t if (!b) return a;\n\t if (isArray(a)) a = a.join(' ');\n\t if (isArray(b)) b = b.join(' ');\n\t return a + ' ' + b;\n\t}\n\t\n\tfunction extractElementNode(element) {\n\t for (var i = 0; i < element.length; i++) {\n\t var elm = element[i];\n\t if (elm.nodeType === ELEMENT_NODE) {\n\t return elm;\n\t }\n\t }\n\t}\n\t\n\tfunction splitClasses(classes) {\n\t if (isString(classes)) {\n\t classes = classes.split(' ');\n\t }\n\t\n\t // Use createMap() to prevent class assumptions involving property names in\n\t // Object.prototype\n\t var obj = createMap();\n\t forEach(classes, function(klass) {\n\t // sometimes the split leaves empty string values\n\t // incase extra spaces were applied to the options\n\t if (klass.length) {\n\t obj[klass] = true;\n\t }\n\t });\n\t return obj;\n\t}\n\t\n\t// if any other type of options value besides an Object value is\n\t// passed into the $animate.method() animation then this helper code\n\t// will be run which will ignore it. While this patch is not the\n\t// greatest solution to this, a lot of existing plugins depend on\n\t// $animate to either call the callback (< 1.2) or return a promise\n\t// that can be changed. This helper function ensures that the options\n\t// are wiped clean incase a callback function is provided.\n\tfunction prepareAnimateOptions(options) {\n\t return isObject(options)\n\t ? options\n\t : {};\n\t}\n\t\n\tvar $$CoreAnimateJsProvider = function() {\n\t this.$get = function() {};\n\t};\n\t\n\t// this is prefixed with Core since it conflicts with\n\t// the animateQueueProvider defined in ngAnimate/animateQueue.js\n\tvar $$CoreAnimateQueueProvider = function() {\n\t var postDigestQueue = new HashMap();\n\t var postDigestElements = [];\n\t\n\t this.$get = ['$$AnimateRunner', '$rootScope',\n\t function($$AnimateRunner, $rootScope) {\n\t return {\n\t enabled: noop,\n\t on: noop,\n\t off: noop,\n\t pin: noop,\n\t\n\t push: function(element, event, options, domOperation) {\n\t domOperation && domOperation();\n\t\n\t options = options || {};\n\t options.from && element.css(options.from);\n\t options.to && element.css(options.to);\n\t\n\t if (options.addClass || options.removeClass) {\n\t addRemoveClassesPostDigest(element, options.addClass, options.removeClass);\n\t }\n\t\n\t var runner = new $$AnimateRunner(); // jshint ignore:line\n\t\n\t // since there are no animations to run the runner needs to be\n\t // notified that the animation call is complete.\n\t runner.complete();\n\t return runner;\n\t }\n\t };\n\t\n\t\n\t function updateData(data, classes, value) {\n\t var changed = false;\n\t if (classes) {\n\t classes = isString(classes) ? classes.split(' ') :\n\t isArray(classes) ? classes : [];\n\t forEach(classes, function(className) {\n\t if (className) {\n\t changed = true;\n\t data[className] = value;\n\t }\n\t });\n\t }\n\t return changed;\n\t }\n\t\n\t function handleCSSClassChanges() {\n\t forEach(postDigestElements, function(element) {\n\t var data = postDigestQueue.get(element);\n\t if (data) {\n\t var existing = splitClasses(element.attr('class'));\n\t var toAdd = '';\n\t var toRemove = '';\n\t forEach(data, function(status, className) {\n\t var hasClass = !!existing[className];\n\t if (status !== hasClass) {\n\t if (status) {\n\t toAdd += (toAdd.length ? ' ' : '') + className;\n\t } else {\n\t toRemove += (toRemove.length ? ' ' : '') + className;\n\t }\n\t }\n\t });\n\t\n\t forEach(element, function(elm) {\n\t toAdd && jqLiteAddClass(elm, toAdd);\n\t toRemove && jqLiteRemoveClass(elm, toRemove);\n\t });\n\t postDigestQueue.remove(element);\n\t }\n\t });\n\t postDigestElements.length = 0;\n\t }\n\t\n\t\n\t function addRemoveClassesPostDigest(element, add, remove) {\n\t var data = postDigestQueue.get(element) || {};\n\t\n\t var classesAdded = updateData(data, add, true);\n\t var classesRemoved = updateData(data, remove, false);\n\t\n\t if (classesAdded || classesRemoved) {\n\t\n\t postDigestQueue.put(element, data);\n\t postDigestElements.push(element);\n\t\n\t if (postDigestElements.length === 1) {\n\t $rootScope.$$postDigest(handleCSSClassChanges);\n\t }\n\t }\n\t }\n\t }];\n\t};\n\t\n\t/**\n\t * @ngdoc provider\n\t * @name $animateProvider\n\t *\n\t * @description\n\t * Default implementation of $animate that doesn't perform any animations, instead just\n\t * synchronously performs DOM updates and resolves the returned runner promise.\n\t *\n\t * In order to enable animations the `ngAnimate` module has to be loaded.\n\t *\n\t * To see the functional implementation check out `src/ngAnimate/animate.js`.\n\t */\n\tvar $AnimateProvider = ['$provide', function($provide) {\n\t var provider = this;\n\t\n\t this.$$registeredAnimations = Object.create(null);\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $animateProvider#register\n\t *\n\t * @description\n\t * Registers a new injectable animation factory function. The factory function produces the\n\t * animation object which contains callback functions for each event that is expected to be\n\t * animated.\n\t *\n\t * * `eventFn`: `function(element, ... , doneFunction, options)`\n\t * The element to animate, the `doneFunction` and the options fed into the animation. Depending\n\t * on the type of animation additional arguments will be injected into the animation function. The\n\t * list below explains the function signatures for the different animation methods:\n\t *\n\t * - setClass: function(element, addedClasses, removedClasses, doneFunction, options)\n\t * - addClass: function(element, addedClasses, doneFunction, options)\n\t * - removeClass: function(element, removedClasses, doneFunction, options)\n\t * - enter, leave, move: function(element, doneFunction, options)\n\t * - animate: function(element, fromStyles, toStyles, doneFunction, options)\n\t *\n\t * Make sure to trigger the `doneFunction` once the animation is fully complete.\n\t *\n\t * ```js\n\t * return {\n\t * //enter, leave, move signature\n\t * eventFn : function(element, done, options) {\n\t * //code to run the animation\n\t * //once complete, then run done()\n\t * return function endFunction(wasCancelled) {\n\t * //code to cancel the animation\n\t * }\n\t * }\n\t * }\n\t * ```\n\t *\n\t * @param {string} name The name of the animation (this is what the class-based CSS value will be compared to).\n\t * @param {Function} factory The factory function that will be executed to return the animation\n\t * object.\n\t */\n\t this.register = function(name, factory) {\n\t if (name && name.charAt(0) !== '.') {\n\t throw $animateMinErr('notcsel', \"Expecting class selector starting with '.' got '{0}'.\", name);\n\t }\n\t\n\t var key = name + '-animation';\n\t provider.$$registeredAnimations[name.substr(1)] = key;\n\t $provide.factory(key, factory);\n\t };\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $animateProvider#classNameFilter\n\t *\n\t * @description\n\t * Sets and/or returns the CSS class regular expression that is checked when performing\n\t * an animation. Upon bootstrap the classNameFilter value is not set at all and will\n\t * therefore enable $animate to attempt to perform an animation on any element that is triggered.\n\t * When setting the `classNameFilter` value, animations will only be performed on elements\n\t * that successfully match the filter expression. This in turn can boost performance\n\t * for low-powered devices as well as applications containing a lot of structural operations.\n\t * @param {RegExp=} expression The className expression which will be checked against all animations\n\t * @return {RegExp} The current CSS className expression value. If null then there is no expression value\n\t */\n\t this.classNameFilter = function(expression) {\n\t if (arguments.length === 1) {\n\t this.$$classNameFilter = (expression instanceof RegExp) ? expression : null;\n\t if (this.$$classNameFilter) {\n\t var reservedRegex = new RegExp(\"(\\\\s+|\\\\/)\" + NG_ANIMATE_CLASSNAME + \"(\\\\s+|\\\\/)\");\n\t if (reservedRegex.test(this.$$classNameFilter.toString())) {\n\t throw $animateMinErr('nongcls','$animateProvider.classNameFilter(regex) prohibits accepting a regex value which matches/contains the \"{0}\" CSS class.', NG_ANIMATE_CLASSNAME);\n\t\n\t }\n\t }\n\t }\n\t return this.$$classNameFilter;\n\t };\n\t\n\t this.$get = ['$$animateQueue', function($$animateQueue) {\n\t function domInsert(element, parentElement, afterElement) {\n\t // if for some reason the previous element was removed\n\t // from the dom sometime before this code runs then let's\n\t // just stick to using the parent element as the anchor\n\t if (afterElement) {\n\t var afterNode = extractElementNode(afterElement);\n\t if (afterNode && !afterNode.parentNode && !afterNode.previousElementSibling) {\n\t afterElement = null;\n\t }\n\t }\n\t afterElement ? afterElement.after(element) : parentElement.prepend(element);\n\t }\n\t\n\t /**\n\t * @ngdoc service\n\t * @name $animate\n\t * @description The $animate service exposes a series of DOM utility methods that provide support\n\t * for animation hooks. The default behavior is the application of DOM operations, however,\n\t * when an animation is detected (and animations are enabled), $animate will do the heavy lifting\n\t * to ensure that animation runs with the triggered DOM operation.\n\t *\n\t * By default $animate doesn't trigger any animations. This is because the `ngAnimate` module isn't\n\t * included and only when it is active then the animation hooks that `$animate` triggers will be\n\t * functional. Once active then all structural `ng-` directives will trigger animations as they perform\n\t * their DOM-related operations (enter, leave and move). Other directives such as `ngClass`,\n\t * `ngShow`, `ngHide` and `ngMessages` also provide support for animations.\n\t *\n\t * It is recommended that the`$animate` service is always used when executing DOM-related procedures within directives.\n\t *\n\t * To learn more about enabling animation support, click here to visit the\n\t * {@link ngAnimate ngAnimate module page}.\n\t */\n\t return {\n\t // we don't call it directly since non-existant arguments may\n\t // be interpreted as null within the sub enabled function\n\t\n\t /**\n\t *\n\t * @ngdoc method\n\t * @name $animate#on\n\t * @kind function\n\t * @description Sets up an event listener to fire whenever the animation event (enter, leave, move, etc...)\n\t * has fired on the given element or among any of its children. Once the listener is fired, the provided callback\n\t * is fired with the following params:\n\t *\n\t * ```js\n\t * $animate.on('enter', container,\n\t * function callback(element, phase) {\n\t * // cool we detected an enter animation within the container\n\t * }\n\t * );\n\t * ```\n\t *\n\t * @param {string} event the animation event that will be captured (e.g. enter, leave, move, addClass, removeClass, etc...)\n\t * @param {DOMElement} container the container element that will capture each of the animation events that are fired on itself\n\t * as well as among its children\n\t * @param {Function} callback the callback function that will be fired when the listener is triggered\n\t *\n\t * The arguments present in the callback function are:\n\t * * `element` - The captured DOM element that the animation was fired on.\n\t * * `phase` - The phase of the animation. The two possible phases are **start** (when the animation starts) and **close** (when it ends).\n\t */\n\t on: $$animateQueue.on,\n\t\n\t /**\n\t *\n\t * @ngdoc method\n\t * @name $animate#off\n\t * @kind function\n\t * @description Deregisters an event listener based on the event which has been associated with the provided element. This method\n\t * can be used in three different ways depending on the arguments:\n\t *\n\t * ```js\n\t * // remove all the animation event listeners listening for `enter`\n\t * $animate.off('enter');\n\t *\n\t * // remove all the animation event listeners listening for `enter` on the given element and its children\n\t * $animate.off('enter', container);\n\t *\n\t * // remove the event listener function provided by `listenerFn` that is set\n\t * // to listen for `enter` on the given `element` as well as its children\n\t * $animate.off('enter', container, callback);\n\t * ```\n\t *\n\t * @param {string} event the animation event (e.g. enter, leave, move, addClass, removeClass, etc...)\n\t * @param {DOMElement=} container the container element the event listener was placed on\n\t * @param {Function=} callback the callback function that was registered as the listener\n\t */\n\t off: $$animateQueue.off,\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $animate#pin\n\t * @kind function\n\t * @description Associates the provided element with a host parent element to allow the element to be animated even if it exists\n\t * outside of the DOM structure of the Angular application. By doing so, any animation triggered via `$animate` can be issued on the\n\t * element despite being outside the realm of the application or within another application. Say for example if the application\n\t * was bootstrapped on an element that is somewhere inside of the `` tag, but we wanted to allow for an element to be situated\n\t * as a direct child of `document.body`, then this can be achieved by pinning the element via `$animate.pin(element)`. Keep in mind\n\t * that calling `$animate.pin(element, parentElement)` will not actually insert into the DOM anywhere; it will just create the association.\n\t *\n\t * Note that this feature is only active when the `ngAnimate` module is used.\n\t *\n\t * @param {DOMElement} element the external element that will be pinned\n\t * @param {DOMElement} parentElement the host parent element that will be associated with the external element\n\t */\n\t pin: $$animateQueue.pin,\n\t\n\t /**\n\t *\n\t * @ngdoc method\n\t * @name $animate#enabled\n\t * @kind function\n\t * @description Used to get and set whether animations are enabled or not on the entire application or on an element and its children. This\n\t * function can be called in four ways:\n\t *\n\t * ```js\n\t * // returns true or false\n\t * $animate.enabled();\n\t *\n\t * // changes the enabled state for all animations\n\t * $animate.enabled(false);\n\t * $animate.enabled(true);\n\t *\n\t * // returns true or false if animations are enabled for an element\n\t * $animate.enabled(element);\n\t *\n\t * // changes the enabled state for an element and its children\n\t * $animate.enabled(element, true);\n\t * $animate.enabled(element, false);\n\t * ```\n\t *\n\t * @param {DOMElement=} element the element that will be considered for checking/setting the enabled state\n\t * @param {boolean=} enabled whether or not the animations will be enabled for the element\n\t *\n\t * @return {boolean} whether or not animations are enabled\n\t */\n\t enabled: $$animateQueue.enabled,\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $animate#cancel\n\t * @kind function\n\t * @description Cancels the provided animation.\n\t *\n\t * @param {Promise} animationPromise The animation promise that is returned when an animation is started.\n\t */\n\t cancel: function(runner) {\n\t runner.end && runner.end();\n\t },\n\t\n\t /**\n\t *\n\t * @ngdoc method\n\t * @name $animate#enter\n\t * @kind function\n\t * @description Inserts the element into the DOM either after the `after` element (if provided) or\n\t * as the first child within the `parent` element and then triggers an animation.\n\t * A promise is returned that will be resolved during the next digest once the animation\n\t * has completed.\n\t *\n\t * @param {DOMElement} element the element which will be inserted into the DOM\n\t * @param {DOMElement} parent the parent element which will append the element as\n\t * a child (so long as the after element is not present)\n\t * @param {DOMElement=} after the sibling element after which the element will be appended\n\t * @param {object=} options an optional collection of options/styles that will be applied to the element\n\t *\n\t * @return {Promise} the animation callback promise\n\t */\n\t enter: function(element, parent, after, options) {\n\t parent = parent && jqLite(parent);\n\t after = after && jqLite(after);\n\t parent = parent || after.parent();\n\t domInsert(element, parent, after);\n\t return $$animateQueue.push(element, 'enter', prepareAnimateOptions(options));\n\t },\n\t\n\t /**\n\t *\n\t * @ngdoc method\n\t * @name $animate#move\n\t * @kind function\n\t * @description Inserts (moves) the element into its new position in the DOM either after\n\t * the `after` element (if provided) or as the first child within the `parent` element\n\t * and then triggers an animation. A promise is returned that will be resolved\n\t * during the next digest once the animation has completed.\n\t *\n\t * @param {DOMElement} element the element which will be moved into the new DOM position\n\t * @param {DOMElement} parent the parent element which will append the element as\n\t * a child (so long as the after element is not present)\n\t * @param {DOMElement=} after the sibling element after which the element will be appended\n\t * @param {object=} options an optional collection of options/styles that will be applied to the element\n\t *\n\t * @return {Promise} the animation callback promise\n\t */\n\t move: function(element, parent, after, options) {\n\t parent = parent && jqLite(parent);\n\t after = after && jqLite(after);\n\t parent = parent || after.parent();\n\t domInsert(element, parent, after);\n\t return $$animateQueue.push(element, 'move', prepareAnimateOptions(options));\n\t },\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $animate#leave\n\t * @kind function\n\t * @description Triggers an animation and then removes the element from the DOM.\n\t * When the function is called a promise is returned that will be resolved during the next\n\t * digest once the animation has completed.\n\t *\n\t * @param {DOMElement} element the element which will be removed from the DOM\n\t * @param {object=} options an optional collection of options/styles that will be applied to the element\n\t *\n\t * @return {Promise} the animation callback promise\n\t */\n\t leave: function(element, options) {\n\t return $$animateQueue.push(element, 'leave', prepareAnimateOptions(options), function() {\n\t element.remove();\n\t });\n\t },\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $animate#addClass\n\t * @kind function\n\t *\n\t * @description Triggers an addClass animation surrounding the addition of the provided CSS class(es). Upon\n\t * execution, the addClass operation will only be handled after the next digest and it will not trigger an\n\t * animation if element already contains the CSS class or if the class is removed at a later step.\n\t * Note that class-based animations are treated differently compared to structural animations\n\t * (like enter, move and leave) since the CSS classes may be added/removed at different points\n\t * depending if CSS or JavaScript animations are used.\n\t *\n\t * @param {DOMElement} element the element which the CSS classes will be applied to\n\t * @param {string} className the CSS class(es) that will be added (multiple classes are separated via spaces)\n\t * @param {object=} options an optional collection of options/styles that will be applied to the element\n\t *\n\t * @return {Promise} the animation callback promise\n\t */\n\t addClass: function(element, className, options) {\n\t options = prepareAnimateOptions(options);\n\t options.addClass = mergeClasses(options.addclass, className);\n\t return $$animateQueue.push(element, 'addClass', options);\n\t },\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $animate#removeClass\n\t * @kind function\n\t *\n\t * @description Triggers a removeClass animation surrounding the removal of the provided CSS class(es). Upon\n\t * execution, the removeClass operation will only be handled after the next digest and it will not trigger an\n\t * animation if element does not contain the CSS class or if the class is added at a later step.\n\t * Note that class-based animations are treated differently compared to structural animations\n\t * (like enter, move and leave) since the CSS classes may be added/removed at different points\n\t * depending if CSS or JavaScript animations are used.\n\t *\n\t * @param {DOMElement} element the element which the CSS classes will be applied to\n\t * @param {string} className the CSS class(es) that will be removed (multiple classes are separated via spaces)\n\t * @param {object=} options an optional collection of options/styles that will be applied to the element\n\t *\n\t * @return {Promise} the animation callback promise\n\t */\n\t removeClass: function(element, className, options) {\n\t options = prepareAnimateOptions(options);\n\t options.removeClass = mergeClasses(options.removeClass, className);\n\t return $$animateQueue.push(element, 'removeClass', options);\n\t },\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $animate#setClass\n\t * @kind function\n\t *\n\t * @description Performs both the addition and removal of a CSS classes on an element and (during the process)\n\t * triggers an animation surrounding the class addition/removal. Much like `$animate.addClass` and\n\t * `$animate.removeClass`, `setClass` will only evaluate the classes being added/removed once a digest has\n\t * passed. Note that class-based animations are treated differently compared to structural animations\n\t * (like enter, move and leave) since the CSS classes may be added/removed at different points\n\t * depending if CSS or JavaScript animations are used.\n\t *\n\t * @param {DOMElement} element the element which the CSS classes will be applied to\n\t * @param {string} add the CSS class(es) that will be added (multiple classes are separated via spaces)\n\t * @param {string} remove the CSS class(es) that will be removed (multiple classes are separated via spaces)\n\t * @param {object=} options an optional collection of options/styles that will be applied to the element\n\t *\n\t * @return {Promise} the animation callback promise\n\t */\n\t setClass: function(element, add, remove, options) {\n\t options = prepareAnimateOptions(options);\n\t options.addClass = mergeClasses(options.addClass, add);\n\t options.removeClass = mergeClasses(options.removeClass, remove);\n\t return $$animateQueue.push(element, 'setClass', options);\n\t },\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $animate#animate\n\t * @kind function\n\t *\n\t * @description Performs an inline animation on the element which applies the provided to and from CSS styles to the element.\n\t * If any detected CSS transition, keyframe or JavaScript matches the provided className value, then the animation will take\n\t * on the provided styles. For example, if a transition animation is set for the given className, then the provided `from` and\n\t * `to` styles will be applied alongside the given transition. If the CSS style provided in `from` does not have a corresponding\n\t * style in `to`, the style in `from` is applied immediately, and no animation is run.\n\t * If a JavaScript animation is detected then the provided styles will be given in as function parameters into the `animate`\n\t * method (or as part of the `options` parameter):\n\t *\n\t * ```js\n\t * ngModule.animation('.my-inline-animation', function() {\n\t * return {\n\t * animate : function(element, from, to, done, options) {\n\t * //animation\n\t * done();\n\t * }\n\t * }\n\t * });\n\t * ```\n\t *\n\t * @param {DOMElement} element the element which the CSS styles will be applied to\n\t * @param {object} from the from (starting) CSS styles that will be applied to the element and across the animation.\n\t * @param {object} to the to (destination) CSS styles that will be applied to the element and across the animation.\n\t * @param {string=} className an optional CSS class that will be applied to the element for the duration of the animation. If\n\t * this value is left as empty then a CSS class of `ng-inline-animate` will be applied to the element.\n\t * (Note that if no animation is detected then this value will not be appplied to the element.)\n\t * @param {object=} options an optional collection of options/styles that will be applied to the element\n\t *\n\t * @return {Promise} the animation callback promise\n\t */\n\t animate: function(element, from, to, className, options) {\n\t options = prepareAnimateOptions(options);\n\t options.from = options.from ? extend(options.from, from) : from;\n\t options.to = options.to ? extend(options.to, to) : to;\n\t\n\t className = className || 'ng-inline-animate';\n\t options.tempClasses = mergeClasses(options.tempClasses, className);\n\t return $$animateQueue.push(element, 'animate', options);\n\t }\n\t };\n\t }];\n\t}];\n\t\n\tvar $$AnimateAsyncRunFactoryProvider = function() {\n\t this.$get = ['$$rAF', function($$rAF) {\n\t var waitQueue = [];\n\t\n\t function waitForTick(fn) {\n\t waitQueue.push(fn);\n\t if (waitQueue.length > 1) return;\n\t $$rAF(function() {\n\t for (var i = 0; i < waitQueue.length; i++) {\n\t waitQueue[i]();\n\t }\n\t waitQueue = [];\n\t });\n\t }\n\t\n\t return function() {\n\t var passed = false;\n\t waitForTick(function() {\n\t passed = true;\n\t });\n\t return function(callback) {\n\t passed ? callback() : waitForTick(callback);\n\t };\n\t };\n\t }];\n\t};\n\t\n\tvar $$AnimateRunnerFactoryProvider = function() {\n\t this.$get = ['$q', '$sniffer', '$$animateAsyncRun', '$document', '$timeout',\n\t function($q, $sniffer, $$animateAsyncRun, $document, $timeout) {\n\t\n\t var INITIAL_STATE = 0;\n\t var DONE_PENDING_STATE = 1;\n\t var DONE_COMPLETE_STATE = 2;\n\t\n\t AnimateRunner.chain = function(chain, callback) {\n\t var index = 0;\n\t\n\t next();\n\t function next() {\n\t if (index === chain.length) {\n\t callback(true);\n\t return;\n\t }\n\t\n\t chain[index](function(response) {\n\t if (response === false) {\n\t callback(false);\n\t return;\n\t }\n\t index++;\n\t next();\n\t });\n\t }\n\t };\n\t\n\t AnimateRunner.all = function(runners, callback) {\n\t var count = 0;\n\t var status = true;\n\t forEach(runners, function(runner) {\n\t runner.done(onProgress);\n\t });\n\t\n\t function onProgress(response) {\n\t status = status && response;\n\t if (++count === runners.length) {\n\t callback(status);\n\t }\n\t }\n\t };\n\t\n\t function AnimateRunner(host) {\n\t this.setHost(host);\n\t\n\t var rafTick = $$animateAsyncRun();\n\t var timeoutTick = function(fn) {\n\t $timeout(fn, 0, false);\n\t };\n\t\n\t this._doneCallbacks = [];\n\t this._tick = function(fn) {\n\t var doc = $document[0];\n\t\n\t // the document may not be ready or attached\n\t // to the module for some internal tests\n\t if (doc && doc.hidden) {\n\t timeoutTick(fn);\n\t } else {\n\t rafTick(fn);\n\t }\n\t };\n\t this._state = 0;\n\t }\n\t\n\t AnimateRunner.prototype = {\n\t setHost: function(host) {\n\t this.host = host || {};\n\t },\n\t\n\t done: function(fn) {\n\t if (this._state === DONE_COMPLETE_STATE) {\n\t fn();\n\t } else {\n\t this._doneCallbacks.push(fn);\n\t }\n\t },\n\t\n\t progress: noop,\n\t\n\t getPromise: function() {\n\t if (!this.promise) {\n\t var self = this;\n\t this.promise = $q(function(resolve, reject) {\n\t self.done(function(status) {\n\t status === false ? reject() : resolve();\n\t });\n\t });\n\t }\n\t return this.promise;\n\t },\n\t\n\t then: function(resolveHandler, rejectHandler) {\n\t return this.getPromise().then(resolveHandler, rejectHandler);\n\t },\n\t\n\t 'catch': function(handler) {\n\t return this.getPromise()['catch'](handler);\n\t },\n\t\n\t 'finally': function(handler) {\n\t return this.getPromise()['finally'](handler);\n\t },\n\t\n\t pause: function() {\n\t if (this.host.pause) {\n\t this.host.pause();\n\t }\n\t },\n\t\n\t resume: function() {\n\t if (this.host.resume) {\n\t this.host.resume();\n\t }\n\t },\n\t\n\t end: function() {\n\t if (this.host.end) {\n\t this.host.end();\n\t }\n\t this._resolve(true);\n\t },\n\t\n\t cancel: function() {\n\t if (this.host.cancel) {\n\t this.host.cancel();\n\t }\n\t this._resolve(false);\n\t },\n\t\n\t complete: function(response) {\n\t var self = this;\n\t if (self._state === INITIAL_STATE) {\n\t self._state = DONE_PENDING_STATE;\n\t self._tick(function() {\n\t self._resolve(response);\n\t });\n\t }\n\t },\n\t\n\t _resolve: function(response) {\n\t if (this._state !== DONE_COMPLETE_STATE) {\n\t forEach(this._doneCallbacks, function(fn) {\n\t fn(response);\n\t });\n\t this._doneCallbacks.length = 0;\n\t this._state = DONE_COMPLETE_STATE;\n\t }\n\t }\n\t };\n\t\n\t return AnimateRunner;\n\t }];\n\t};\n\t\n\t/**\n\t * @ngdoc service\n\t * @name $animateCss\n\t * @kind object\n\t *\n\t * @description\n\t * This is the core version of `$animateCss`. By default, only when the `ngAnimate` is included,\n\t * then the `$animateCss` service will actually perform animations.\n\t *\n\t * Click here {@link ngAnimate.$animateCss to read the documentation for $animateCss}.\n\t */\n\tvar $CoreAnimateCssProvider = function() {\n\t this.$get = ['$$rAF', '$q', '$$AnimateRunner', function($$rAF, $q, $$AnimateRunner) {\n\t\n\t return function(element, initialOptions) {\n\t // all of the animation functions should create\n\t // a copy of the options data, however, if a\n\t // parent service has already created a copy then\n\t // we should stick to using that\n\t var options = initialOptions || {};\n\t if (!options.$$prepared) {\n\t options = copy(options);\n\t }\n\t\n\t // there is no point in applying the styles since\n\t // there is no animation that goes on at all in\n\t // this version of $animateCss.\n\t if (options.cleanupStyles) {\n\t options.from = options.to = null;\n\t }\n\t\n\t if (options.from) {\n\t element.css(options.from);\n\t options.from = null;\n\t }\n\t\n\t /* jshint newcap: false*/\n\t var closed, runner = new $$AnimateRunner();\n\t return {\n\t start: run,\n\t end: run\n\t };\n\t\n\t function run() {\n\t $$rAF(function() {\n\t applyAnimationContents();\n\t if (!closed) {\n\t runner.complete();\n\t }\n\t closed = true;\n\t });\n\t return runner;\n\t }\n\t\n\t function applyAnimationContents() {\n\t if (options.addClass) {\n\t element.addClass(options.addClass);\n\t options.addClass = null;\n\t }\n\t if (options.removeClass) {\n\t element.removeClass(options.removeClass);\n\t options.removeClass = null;\n\t }\n\t if (options.to) {\n\t element.css(options.to);\n\t options.to = null;\n\t }\n\t }\n\t };\n\t }];\n\t};\n\t\n\t/* global stripHash: true */\n\t\n\t/**\n\t * ! This is a private undocumented service !\n\t *\n\t * @name $browser\n\t * @requires $log\n\t * @description\n\t * This object has two goals:\n\t *\n\t * - hide all the global state in the browser caused by the window object\n\t * - abstract away all the browser specific features and inconsistencies\n\t *\n\t * For tests we provide {@link ngMock.$browser mock implementation} of the `$browser`\n\t * service, which can be used for convenient testing of the application without the interaction with\n\t * the real browser apis.\n\t */\n\t/**\n\t * @param {object} window The global window object.\n\t * @param {object} document jQuery wrapped document.\n\t * @param {object} $log window.console or an object with the same interface.\n\t * @param {object} $sniffer $sniffer service\n\t */\n\tfunction Browser(window, document, $log, $sniffer) {\n\t var self = this,\n\t rawDocument = document[0],\n\t location = window.location,\n\t history = window.history,\n\t setTimeout = window.setTimeout,\n\t clearTimeout = window.clearTimeout,\n\t pendingDeferIds = {};\n\t\n\t self.isMock = false;\n\t\n\t var outstandingRequestCount = 0;\n\t var outstandingRequestCallbacks = [];\n\t\n\t // TODO(vojta): remove this temporary api\n\t self.$$completeOutstandingRequest = completeOutstandingRequest;\n\t self.$$incOutstandingRequestCount = function() { outstandingRequestCount++; };\n\t\n\t /**\n\t * Executes the `fn` function(supports currying) and decrements the `outstandingRequestCallbacks`\n\t * counter. If the counter reaches 0, all the `outstandingRequestCallbacks` are executed.\n\t */\n\t function completeOutstandingRequest(fn) {\n\t try {\n\t fn.apply(null, sliceArgs(arguments, 1));\n\t } finally {\n\t outstandingRequestCount--;\n\t if (outstandingRequestCount === 0) {\n\t while (outstandingRequestCallbacks.length) {\n\t try {\n\t outstandingRequestCallbacks.pop()();\n\t } catch (e) {\n\t $log.error(e);\n\t }\n\t }\n\t }\n\t }\n\t }\n\t\n\t function getHash(url) {\n\t var index = url.indexOf('#');\n\t return index === -1 ? '' : url.substr(index);\n\t }\n\t\n\t /**\n\t * @private\n\t * Note: this method is used only by scenario runner\n\t * TODO(vojta): prefix this method with $$ ?\n\t * @param {function()} callback Function that will be called when no outstanding request\n\t */\n\t self.notifyWhenNoOutstandingRequests = function(callback) {\n\t if (outstandingRequestCount === 0) {\n\t callback();\n\t } else {\n\t outstandingRequestCallbacks.push(callback);\n\t }\n\t };\n\t\n\t //////////////////////////////////////////////////////////////\n\t // URL API\n\t //////////////////////////////////////////////////////////////\n\t\n\t var cachedState, lastHistoryState,\n\t lastBrowserUrl = location.href,\n\t baseElement = document.find('base'),\n\t pendingLocation = null;\n\t\n\t cacheState();\n\t lastHistoryState = cachedState;\n\t\n\t /**\n\t * @name $browser#url\n\t *\n\t * @description\n\t * GETTER:\n\t * Without any argument, this method just returns current value of location.href.\n\t *\n\t * SETTER:\n\t * With at least one argument, this method sets url to new value.\n\t * If html5 history api supported, pushState/replaceState is used, otherwise\n\t * location.href/location.replace is used.\n\t * Returns its own instance to allow chaining\n\t *\n\t * NOTE: this api is intended for use only by the $location service. Please use the\n\t * {@link ng.$location $location service} to change url.\n\t *\n\t * @param {string} url New url (when used as setter)\n\t * @param {boolean=} replace Should new url replace current history record?\n\t * @param {object=} state object to use with pushState/replaceState\n\t */\n\t self.url = function(url, replace, state) {\n\t // In modern browsers `history.state` is `null` by default; treating it separately\n\t // from `undefined` would cause `$browser.url('/foo')` to change `history.state`\n\t // to undefined via `pushState`. Instead, let's change `undefined` to `null` here.\n\t if (isUndefined(state)) {\n\t state = null;\n\t }\n\t\n\t // Android Browser BFCache causes location, history reference to become stale.\n\t if (location !== window.location) location = window.location;\n\t if (history !== window.history) history = window.history;\n\t\n\t // setter\n\t if (url) {\n\t var sameState = lastHistoryState === state;\n\t\n\t // Don't change anything if previous and current URLs and states match. This also prevents\n\t // IE<10 from getting into redirect loop when in LocationHashbangInHtml5Url mode.\n\t // See https://github.com/angular/angular.js/commit/ffb2701\n\t if (lastBrowserUrl === url && (!$sniffer.history || sameState)) {\n\t return self;\n\t }\n\t var sameBase = lastBrowserUrl && stripHash(lastBrowserUrl) === stripHash(url);\n\t lastBrowserUrl = url;\n\t lastHistoryState = state;\n\t // Don't use history API if only the hash changed\n\t // due to a bug in IE10/IE11 which leads\n\t // to not firing a `hashchange` nor `popstate` event\n\t // in some cases (see #9143).\n\t if ($sniffer.history && (!sameBase || !sameState)) {\n\t history[replace ? 'replaceState' : 'pushState'](state, '', url);\n\t cacheState();\n\t // Do the assignment again so that those two variables are referentially identical.\n\t lastHistoryState = cachedState;\n\t } else {\n\t if (!sameBase || pendingLocation) {\n\t pendingLocation = url;\n\t }\n\t if (replace) {\n\t location.replace(url);\n\t } else if (!sameBase) {\n\t location.href = url;\n\t } else {\n\t location.hash = getHash(url);\n\t }\n\t if (location.href !== url) {\n\t pendingLocation = url;\n\t }\n\t }\n\t return self;\n\t // getter\n\t } else {\n\t // - pendingLocation is needed as browsers don't allow to read out\n\t // the new location.href if a reload happened or if there is a bug like in iOS 9 (see\n\t // https://openradar.appspot.com/22186109).\n\t // - the replacement is a workaround for https://bugzilla.mozilla.org/show_bug.cgi?id=407172\n\t return pendingLocation || location.href.replace(/%27/g,\"'\");\n\t }\n\t };\n\t\n\t /**\n\t * @name $browser#state\n\t *\n\t * @description\n\t * This method is a getter.\n\t *\n\t * Return history.state or null if history.state is undefined.\n\t *\n\t * @returns {object} state\n\t */\n\t self.state = function() {\n\t return cachedState;\n\t };\n\t\n\t var urlChangeListeners = [],\n\t urlChangeInit = false;\n\t\n\t function cacheStateAndFireUrlChange() {\n\t pendingLocation = null;\n\t cacheState();\n\t fireUrlChange();\n\t }\n\t\n\t function getCurrentState() {\n\t try {\n\t return history.state;\n\t } catch (e) {\n\t // MSIE can reportedly throw when there is no state (UNCONFIRMED).\n\t }\n\t }\n\t\n\t // This variable should be used *only* inside the cacheState function.\n\t var lastCachedState = null;\n\t function cacheState() {\n\t // This should be the only place in $browser where `history.state` is read.\n\t cachedState = getCurrentState();\n\t cachedState = isUndefined(cachedState) ? null : cachedState;\n\t\n\t // Prevent callbacks fo fire twice if both hashchange & popstate were fired.\n\t if (equals(cachedState, lastCachedState)) {\n\t cachedState = lastCachedState;\n\t }\n\t lastCachedState = cachedState;\n\t }\n\t\n\t function fireUrlChange() {\n\t if (lastBrowserUrl === self.url() && lastHistoryState === cachedState) {\n\t return;\n\t }\n\t\n\t lastBrowserUrl = self.url();\n\t lastHistoryState = cachedState;\n\t forEach(urlChangeListeners, function(listener) {\n\t listener(self.url(), cachedState);\n\t });\n\t }\n\t\n\t /**\n\t * @name $browser#onUrlChange\n\t *\n\t * @description\n\t * Register callback function that will be called, when url changes.\n\t *\n\t * It's only called when the url is changed from outside of angular:\n\t * - user types different url into address bar\n\t * - user clicks on history (forward/back) button\n\t * - user clicks on a link\n\t *\n\t * It's not called when url is changed by $browser.url() method\n\t *\n\t * The listener gets called with new url as parameter.\n\t *\n\t * NOTE: this api is intended for use only by the $location service. Please use the\n\t * {@link ng.$location $location service} to monitor url changes in angular apps.\n\t *\n\t * @param {function(string)} listener Listener function to be called when url changes.\n\t * @return {function(string)} Returns the registered listener fn - handy if the fn is anonymous.\n\t */\n\t self.onUrlChange = function(callback) {\n\t // TODO(vojta): refactor to use node's syntax for events\n\t if (!urlChangeInit) {\n\t // We listen on both (hashchange/popstate) when available, as some browsers (e.g. Opera)\n\t // don't fire popstate when user change the address bar and don't fire hashchange when url\n\t // changed by push/replaceState\n\t\n\t // html5 history api - popstate event\n\t if ($sniffer.history) jqLite(window).on('popstate', cacheStateAndFireUrlChange);\n\t // hashchange event\n\t jqLite(window).on('hashchange', cacheStateAndFireUrlChange);\n\t\n\t urlChangeInit = true;\n\t }\n\t\n\t urlChangeListeners.push(callback);\n\t return callback;\n\t };\n\t\n\t /**\n\t * @private\n\t * Remove popstate and hashchange handler from window.\n\t *\n\t * NOTE: this api is intended for use only by $rootScope.\n\t */\n\t self.$$applicationDestroyed = function() {\n\t jqLite(window).off('hashchange popstate', cacheStateAndFireUrlChange);\n\t };\n\t\n\t /**\n\t * Checks whether the url has changed outside of Angular.\n\t * Needs to be exported to be able to check for changes that have been done in sync,\n\t * as hashchange/popstate events fire in async.\n\t */\n\t self.$$checkUrlChange = fireUrlChange;\n\t\n\t //////////////////////////////////////////////////////////////\n\t // Misc API\n\t //////////////////////////////////////////////////////////////\n\t\n\t /**\n\t * @name $browser#baseHref\n\t *\n\t * @description\n\t * Returns current \n\t * (always relative - without domain)\n\t *\n\t * @returns {string} The current base href\n\t */\n\t self.baseHref = function() {\n\t var href = baseElement.attr('href');\n\t return href ? href.replace(/^(https?\\:)?\\/\\/[^\\/]*/, '') : '';\n\t };\n\t\n\t /**\n\t * @name $browser#defer\n\t * @param {function()} fn A function, who's execution should be deferred.\n\t * @param {number=} [delay=0] of milliseconds to defer the function execution.\n\t * @returns {*} DeferId that can be used to cancel the task via `$browser.defer.cancel()`.\n\t *\n\t * @description\n\t * Executes a fn asynchronously via `setTimeout(fn, delay)`.\n\t *\n\t * Unlike when calling `setTimeout` directly, in test this function is mocked and instead of using\n\t * `setTimeout` in tests, the fns are queued in an array, which can be programmatically flushed\n\t * via `$browser.defer.flush()`.\n\t *\n\t */\n\t self.defer = function(fn, delay) {\n\t var timeoutId;\n\t outstandingRequestCount++;\n\t timeoutId = setTimeout(function() {\n\t delete pendingDeferIds[timeoutId];\n\t completeOutstandingRequest(fn);\n\t }, delay || 0);\n\t pendingDeferIds[timeoutId] = true;\n\t return timeoutId;\n\t };\n\t\n\t\n\t /**\n\t * @name $browser#defer.cancel\n\t *\n\t * @description\n\t * Cancels a deferred task identified with `deferId`.\n\t *\n\t * @param {*} deferId Token returned by the `$browser.defer` function.\n\t * @returns {boolean} Returns `true` if the task hasn't executed yet and was successfully\n\t * canceled.\n\t */\n\t self.defer.cancel = function(deferId) {\n\t if (pendingDeferIds[deferId]) {\n\t delete pendingDeferIds[deferId];\n\t clearTimeout(deferId);\n\t completeOutstandingRequest(noop);\n\t return true;\n\t }\n\t return false;\n\t };\n\t\n\t}\n\t\n\tfunction $BrowserProvider() {\n\t this.$get = ['$window', '$log', '$sniffer', '$document',\n\t function($window, $log, $sniffer, $document) {\n\t return new Browser($window, $document, $log, $sniffer);\n\t }];\n\t}\n\t\n\t/**\n\t * @ngdoc service\n\t * @name $cacheFactory\n\t *\n\t * @description\n\t * Factory that constructs {@link $cacheFactory.Cache Cache} objects and gives access to\n\t * them.\n\t *\n\t * ```js\n\t *\n\t * var cache = $cacheFactory('cacheId');\n\t * expect($cacheFactory.get('cacheId')).toBe(cache);\n\t * expect($cacheFactory.get('noSuchCacheId')).not.toBeDefined();\n\t *\n\t * cache.put(\"key\", \"value\");\n\t * cache.put(\"another key\", \"another value\");\n\t *\n\t * // We've specified no options on creation\n\t * expect(cache.info()).toEqual({id: 'cacheId', size: 2});\n\t *\n\t * ```\n\t *\n\t *\n\t * @param {string} cacheId Name or id of the newly created cache.\n\t * @param {object=} options Options object that specifies the cache behavior. Properties:\n\t *\n\t * - `{number=}` `capacity` — turns the cache into LRU cache.\n\t *\n\t * @returns {object} Newly created cache object with the following set of methods:\n\t *\n\t * - `{object}` `info()` — Returns id, size, and options of cache.\n\t * - `{{*}}` `put({string} key, {*} value)` — Puts a new key-value pair into the cache and returns\n\t * it.\n\t * - `{{*}}` `get({string} key)` — Returns cached value for `key` or undefined for cache miss.\n\t * - `{void}` `remove({string} key)` — Removes a key-value pair from the cache.\n\t * - `{void}` `removeAll()` — Removes all cached values.\n\t * - `{void}` `destroy()` — Removes references to this cache from $cacheFactory.\n\t *\n\t * @example\n\t \n\t \n\t
\n\t \n\t \n\t \n\t\n\t

Cached Values

\n\t
\n\t \n\t : \n\t \n\t
\n\t\n\t

Cache Info

\n\t
\n\t \n\t : \n\t \n\t
\n\t
\n\t
\n\t \n\t angular.module('cacheExampleApp', []).\n\t controller('CacheController', ['$scope', '$cacheFactory', function($scope, $cacheFactory) {\n\t $scope.keys = [];\n\t $scope.cache = $cacheFactory('cacheId');\n\t $scope.put = function(key, value) {\n\t if (angular.isUndefined($scope.cache.get(key))) {\n\t $scope.keys.push(key);\n\t }\n\t $scope.cache.put(key, angular.isUndefined(value) ? null : value);\n\t };\n\t }]);\n\t \n\t \n\t p {\n\t margin: 10px 0 3px;\n\t }\n\t \n\t
\n\t */\n\tfunction $CacheFactoryProvider() {\n\t\n\t this.$get = function() {\n\t var caches = {};\n\t\n\t function cacheFactory(cacheId, options) {\n\t if (cacheId in caches) {\n\t throw minErr('$cacheFactory')('iid', \"CacheId '{0}' is already taken!\", cacheId);\n\t }\n\t\n\t var size = 0,\n\t stats = extend({}, options, {id: cacheId}),\n\t data = createMap(),\n\t capacity = (options && options.capacity) || Number.MAX_VALUE,\n\t lruHash = createMap(),\n\t freshEnd = null,\n\t staleEnd = null;\n\t\n\t /**\n\t * @ngdoc type\n\t * @name $cacheFactory.Cache\n\t *\n\t * @description\n\t * A cache object used to store and retrieve data, primarily used by\n\t * {@link $http $http} and the {@link ng.directive:script script} directive to cache\n\t * templates and other data.\n\t *\n\t * ```js\n\t * angular.module('superCache')\n\t * .factory('superCache', ['$cacheFactory', function($cacheFactory) {\n\t * return $cacheFactory('super-cache');\n\t * }]);\n\t * ```\n\t *\n\t * Example test:\n\t *\n\t * ```js\n\t * it('should behave like a cache', inject(function(superCache) {\n\t * superCache.put('key', 'value');\n\t * superCache.put('another key', 'another value');\n\t *\n\t * expect(superCache.info()).toEqual({\n\t * id: 'super-cache',\n\t * size: 2\n\t * });\n\t *\n\t * superCache.remove('another key');\n\t * expect(superCache.get('another key')).toBeUndefined();\n\t *\n\t * superCache.removeAll();\n\t * expect(superCache.info()).toEqual({\n\t * id: 'super-cache',\n\t * size: 0\n\t * });\n\t * }));\n\t * ```\n\t */\n\t return caches[cacheId] = {\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $cacheFactory.Cache#put\n\t * @kind function\n\t *\n\t * @description\n\t * Inserts a named entry into the {@link $cacheFactory.Cache Cache} object to be\n\t * retrieved later, and incrementing the size of the cache if the key was not already\n\t * present in the cache. If behaving like an LRU cache, it will also remove stale\n\t * entries from the set.\n\t *\n\t * It will not insert undefined values into the cache.\n\t *\n\t * @param {string} key the key under which the cached data is stored.\n\t * @param {*} value the value to store alongside the key. If it is undefined, the key\n\t * will not be stored.\n\t * @returns {*} the value stored.\n\t */\n\t put: function(key, value) {\n\t if (isUndefined(value)) return;\n\t if (capacity < Number.MAX_VALUE) {\n\t var lruEntry = lruHash[key] || (lruHash[key] = {key: key});\n\t\n\t refresh(lruEntry);\n\t }\n\t\n\t if (!(key in data)) size++;\n\t data[key] = value;\n\t\n\t if (size > capacity) {\n\t this.remove(staleEnd.key);\n\t }\n\t\n\t return value;\n\t },\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $cacheFactory.Cache#get\n\t * @kind function\n\t *\n\t * @description\n\t * Retrieves named data stored in the {@link $cacheFactory.Cache Cache} object.\n\t *\n\t * @param {string} key the key of the data to be retrieved\n\t * @returns {*} the value stored.\n\t */\n\t get: function(key) {\n\t if (capacity < Number.MAX_VALUE) {\n\t var lruEntry = lruHash[key];\n\t\n\t if (!lruEntry) return;\n\t\n\t refresh(lruEntry);\n\t }\n\t\n\t return data[key];\n\t },\n\t\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $cacheFactory.Cache#remove\n\t * @kind function\n\t *\n\t * @description\n\t * Removes an entry from the {@link $cacheFactory.Cache Cache} object.\n\t *\n\t * @param {string} key the key of the entry to be removed\n\t */\n\t remove: function(key) {\n\t if (capacity < Number.MAX_VALUE) {\n\t var lruEntry = lruHash[key];\n\t\n\t if (!lruEntry) return;\n\t\n\t if (lruEntry == freshEnd) freshEnd = lruEntry.p;\n\t if (lruEntry == staleEnd) staleEnd = lruEntry.n;\n\t link(lruEntry.n,lruEntry.p);\n\t\n\t delete lruHash[key];\n\t }\n\t\n\t if (!(key in data)) return;\n\t\n\t delete data[key];\n\t size--;\n\t },\n\t\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $cacheFactory.Cache#removeAll\n\t * @kind function\n\t *\n\t * @description\n\t * Clears the cache object of any entries.\n\t */\n\t removeAll: function() {\n\t data = createMap();\n\t size = 0;\n\t lruHash = createMap();\n\t freshEnd = staleEnd = null;\n\t },\n\t\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $cacheFactory.Cache#destroy\n\t * @kind function\n\t *\n\t * @description\n\t * Destroys the {@link $cacheFactory.Cache Cache} object entirely,\n\t * removing it from the {@link $cacheFactory $cacheFactory} set.\n\t */\n\t destroy: function() {\n\t data = null;\n\t stats = null;\n\t lruHash = null;\n\t delete caches[cacheId];\n\t },\n\t\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $cacheFactory.Cache#info\n\t * @kind function\n\t *\n\t * @description\n\t * Retrieve information regarding a particular {@link $cacheFactory.Cache Cache}.\n\t *\n\t * @returns {object} an object with the following properties:\n\t *
    \n\t *
  • **id**: the id of the cache instance
  • \n\t *
  • **size**: the number of entries kept in the cache instance
  • \n\t *
  • **...**: any additional properties from the options object when creating the\n\t * cache.
  • \n\t *
\n\t */\n\t info: function() {\n\t return extend({}, stats, {size: size});\n\t }\n\t };\n\t\n\t\n\t /**\n\t * makes the `entry` the freshEnd of the LRU linked list\n\t */\n\t function refresh(entry) {\n\t if (entry != freshEnd) {\n\t if (!staleEnd) {\n\t staleEnd = entry;\n\t } else if (staleEnd == entry) {\n\t staleEnd = entry.n;\n\t }\n\t\n\t link(entry.n, entry.p);\n\t link(entry, freshEnd);\n\t freshEnd = entry;\n\t freshEnd.n = null;\n\t }\n\t }\n\t\n\t\n\t /**\n\t * bidirectionally links two entries of the LRU linked list\n\t */\n\t function link(nextEntry, prevEntry) {\n\t if (nextEntry != prevEntry) {\n\t if (nextEntry) nextEntry.p = prevEntry; //p stands for previous, 'prev' didn't minify\n\t if (prevEntry) prevEntry.n = nextEntry; //n stands for next, 'next' didn't minify\n\t }\n\t }\n\t }\n\t\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $cacheFactory#info\n\t *\n\t * @description\n\t * Get information about all the caches that have been created\n\t *\n\t * @returns {Object} - key-value map of `cacheId` to the result of calling `cache#info`\n\t */\n\t cacheFactory.info = function() {\n\t var info = {};\n\t forEach(caches, function(cache, cacheId) {\n\t info[cacheId] = cache.info();\n\t });\n\t return info;\n\t };\n\t\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $cacheFactory#get\n\t *\n\t * @description\n\t * Get access to a cache object by the `cacheId` used when it was created.\n\t *\n\t * @param {string} cacheId Name or id of a cache to access.\n\t * @returns {object} Cache object identified by the cacheId or undefined if no such cache.\n\t */\n\t cacheFactory.get = function(cacheId) {\n\t return caches[cacheId];\n\t };\n\t\n\t\n\t return cacheFactory;\n\t };\n\t}\n\t\n\t/**\n\t * @ngdoc service\n\t * @name $templateCache\n\t *\n\t * @description\n\t * The first time a template is used, it is loaded in the template cache for quick retrieval. You\n\t * can load templates directly into the cache in a `script` tag, or by consuming the\n\t * `$templateCache` service directly.\n\t *\n\t * Adding via the `script` tag:\n\t *\n\t * ```html\n\t * \n\t * ```\n\t *\n\t * **Note:** the `script` tag containing the template does not need to be included in the `head` of\n\t * the document, but it must be a descendent of the {@link ng.$rootElement $rootElement} (IE,\n\t * element with ng-app attribute), otherwise the template will be ignored.\n\t *\n\t * Adding via the `$templateCache` service:\n\t *\n\t * ```js\n\t * var myApp = angular.module('myApp', []);\n\t * myApp.run(function($templateCache) {\n\t * $templateCache.put('templateId.html', 'This is the content of the template');\n\t * });\n\t * ```\n\t *\n\t * To retrieve the template later, simply use it in your HTML:\n\t * ```html\n\t *
\n\t * ```\n\t *\n\t * or get it via Javascript:\n\t * ```js\n\t * $templateCache.get('templateId.html')\n\t * ```\n\t *\n\t * See {@link ng.$cacheFactory $cacheFactory}.\n\t *\n\t */\n\tfunction $TemplateCacheProvider() {\n\t this.$get = ['$cacheFactory', function($cacheFactory) {\n\t return $cacheFactory('templates');\n\t }];\n\t}\n\t\n\t/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *\n\t * Any commits to this file should be reviewed with security in mind. *\n\t * Changes to this file can potentially create security vulnerabilities. *\n\t * An approval from 2 Core members with history of modifying *\n\t * this file is required. *\n\t * *\n\t * Does the change somehow allow for arbitrary javascript to be executed? *\n\t * Or allows for someone to change the prototype of built-in objects? *\n\t * Or gives undesired access to variables likes document or window? *\n\t * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */\n\t\n\t/* ! VARIABLE/FUNCTION NAMING CONVENTIONS THAT APPLY TO THIS FILE!\n\t *\n\t * DOM-related variables:\n\t *\n\t * - \"node\" - DOM Node\n\t * - \"element\" - DOM Element or Node\n\t * - \"$node\" or \"$element\" - jqLite-wrapped node or element\n\t *\n\t *\n\t * Compiler related stuff:\n\t *\n\t * - \"linkFn\" - linking fn of a single directive\n\t * - \"nodeLinkFn\" - function that aggregates all linking fns for a particular node\n\t * - \"childLinkFn\" - function that aggregates all linking fns for child nodes of a particular node\n\t * - \"compositeLinkFn\" - function that aggregates all linking fns for a compilation root (nodeList)\n\t */\n\t\n\t\n\t/**\n\t * @ngdoc service\n\t * @name $compile\n\t * @kind function\n\t *\n\t * @description\n\t * Compiles an HTML string or DOM into a template and produces a template function, which\n\t * can then be used to link {@link ng.$rootScope.Scope `scope`} and the template together.\n\t *\n\t * The compilation is a process of walking the DOM tree and matching DOM elements to\n\t * {@link ng.$compileProvider#directive directives}.\n\t *\n\t *
\n\t * **Note:** This document is an in-depth reference of all directive options.\n\t * For a gentle introduction to directives with examples of common use cases,\n\t * see the {@link guide/directive directive guide}.\n\t *
\n\t *\n\t * ## Comprehensive Directive API\n\t *\n\t * There are many different options for a directive.\n\t *\n\t * The difference resides in the return value of the factory function.\n\t * You can either return a \"Directive Definition Object\" (see below) that defines the directive properties,\n\t * or just the `postLink` function (all other properties will have the default values).\n\t *\n\t *
\n\t * **Best Practice:** It's recommended to use the \"directive definition object\" form.\n\t *
\n\t *\n\t * Here's an example directive declared with a Directive Definition Object:\n\t *\n\t * ```js\n\t * var myModule = angular.module(...);\n\t *\n\t * myModule.directive('directiveName', function factory(injectables) {\n\t * var directiveDefinitionObject = {\n\t * priority: 0,\n\t * template: '
', // or // function(tElement, tAttrs) { ... },\n\t * // or\n\t * // templateUrl: 'directive.html', // or // function(tElement, tAttrs) { ... },\n\t * transclude: false,\n\t * restrict: 'A',\n\t * templateNamespace: 'html',\n\t * scope: false,\n\t * controller: function($scope, $element, $attrs, $transclude, otherInjectables) { ... },\n\t * controllerAs: 'stringIdentifier',\n\t * bindToController: false,\n\t * require: 'siblingDirectiveName', // or // ['^parentDirectiveName', '?optionalDirectiveName', '?^optionalParent'],\n\t * compile: function compile(tElement, tAttrs, transclude) {\n\t * return {\n\t * pre: function preLink(scope, iElement, iAttrs, controller) { ... },\n\t * post: function postLink(scope, iElement, iAttrs, controller) { ... }\n\t * }\n\t * // or\n\t * // return function postLink( ... ) { ... }\n\t * },\n\t * // or\n\t * // link: {\n\t * // pre: function preLink(scope, iElement, iAttrs, controller) { ... },\n\t * // post: function postLink(scope, iElement, iAttrs, controller) { ... }\n\t * // }\n\t * // or\n\t * // link: function postLink( ... ) { ... }\n\t * };\n\t * return directiveDefinitionObject;\n\t * });\n\t * ```\n\t *\n\t *
\n\t * **Note:** Any unspecified options will use the default value. You can see the default values below.\n\t *
\n\t *\n\t * Therefore the above can be simplified as:\n\t *\n\t * ```js\n\t * var myModule = angular.module(...);\n\t *\n\t * myModule.directive('directiveName', function factory(injectables) {\n\t * var directiveDefinitionObject = {\n\t * link: function postLink(scope, iElement, iAttrs) { ... }\n\t * };\n\t * return directiveDefinitionObject;\n\t * // or\n\t * // return function postLink(scope, iElement, iAttrs) { ... }\n\t * });\n\t * ```\n\t *\n\t *\n\t *\n\t * ### Directive Definition Object\n\t *\n\t * The directive definition object provides instructions to the {@link ng.$compile\n\t * compiler}. The attributes are:\n\t *\n\t * #### `multiElement`\n\t * When this property is set to true, the HTML compiler will collect DOM nodes between\n\t * nodes with the attributes `directive-name-start` and `directive-name-end`, and group them\n\t * together as the directive elements. It is recommended that this feature be used on directives\n\t * which are not strictly behavioural (such as {@link ngClick}), and which\n\t * do not manipulate or replace child nodes (such as {@link ngInclude}).\n\t *\n\t * #### `priority`\n\t * When there are multiple directives defined on a single DOM element, sometimes it\n\t * is necessary to specify the order in which the directives are applied. The `priority` is used\n\t * to sort the directives before their `compile` functions get called. Priority is defined as a\n\t * number. Directives with greater numerical `priority` are compiled first. Pre-link functions\n\t * are also run in priority order, but post-link functions are run in reverse order. The order\n\t * of directives with the same priority is undefined. The default priority is `0`.\n\t *\n\t * #### `terminal`\n\t * If set to true then the current `priority` will be the last set of directives\n\t * which will execute (any directives at the current priority will still execute\n\t * as the order of execution on same `priority` is undefined). Note that expressions\n\t * and other directives used in the directive's template will also be excluded from execution.\n\t *\n\t * #### `scope`\n\t * The scope property can be `true`, an object or a falsy value:\n\t *\n\t * * **falsy:** No scope will be created for the directive. The directive will use its parent's scope.\n\t *\n\t * * **`true`:** A new child scope that prototypically inherits from its parent will be created for\n\t * the directive's element. If multiple directives on the same element request a new scope,\n\t * only one new scope is created. The new scope rule does not apply for the root of the template\n\t * since the root of the template always gets a new scope.\n\t *\n\t * * **`{...}` (an object hash):** A new \"isolate\" scope is created for the directive's element. The\n\t * 'isolate' scope differs from normal scope in that it does not prototypically inherit from its parent\n\t * scope. This is useful when creating reusable components, which should not accidentally read or modify\n\t * data in the parent scope.\n\t *\n\t * The 'isolate' scope object hash defines a set of local scope properties derived from attributes on the\n\t * directive's element. These local properties are useful for aliasing values for templates. The keys in\n\t * the object hash map to the name of the property on the isolate scope; the values define how the property\n\t * is bound to the parent scope, via matching attributes on the directive's element:\n\t *\n\t * * `@` or `@attr` - bind a local scope property to the value of DOM attribute. The result is\n\t * always a string since DOM attributes are strings. If no `attr` name is specified then the\n\t * attribute name is assumed to be the same as the local name. Given `` and the isolate scope definition `scope: { localName:'@myAttr' }`,\n\t * the directive's scope property `localName` will reflect the interpolated value of `hello\n\t * {{name}}`. As the `name` attribute changes so will the `localName` property on the directive's\n\t * scope. The `name` is read from the parent scope (not the directive's scope).\n\t *\n\t * * `=` or `=attr` - set up a bidirectional binding between a local scope property and an expression\n\t * passed via the attribute `attr`. The expression is evaluated in the context of the parent scope.\n\t * If no `attr` name is specified then the attribute name is assumed to be the same as the local\n\t * name. Given `` and the isolate scope definition `scope: {\n\t * localModel: '=myAttr' }`, the property `localModel` on the directive's scope will reflect the\n\t * value of `parentModel` on the parent scope. Changes to `parentModel` will be reflected in\n\t * `localModel` and vice versa. Optional attributes should be marked as such with a question mark:\n\t * `=?` or `=?attr`. If the binding expression is non-assignable, or if the attribute isn't\n\t * optional and doesn't exist, an exception ({@link error/$compile/nonassign `$compile:nonassign`})\n\t * will be thrown upon discovering changes to the local value, since it will be impossible to sync\n\t * them back to the parent scope. By default, the {@link ng.$rootScope.Scope#$watch `$watch`}\n\t * method is used for tracking changes, and the equality check is based on object identity.\n\t * However, if an object literal or an array literal is passed as the binding expression, the\n\t * equality check is done by value (using the {@link angular.equals} function). It's also possible\n\t * to watch the evaluated value shallowly with {@link ng.$rootScope.Scope#$watchCollection\n\t * `$watchCollection`}: use `=*` or `=*attr` (`=*?` or `=*?attr` if the attribute is optional).\n\t *\n\t * * `&` or `&attr` - provides a way to execute an expression in the context of the parent scope. If\n\t * no `attr` name is specified then the attribute name is assumed to be the same as the local name.\n\t * Given `` and the isolate scope definition `scope: {\n\t * localFn:'&myAttr' }`, the isolate scope property `localFn` will point to a function wrapper for\n\t * the `count = count + value` expression. Often it's desirable to pass data from the isolated scope\n\t * via an expression to the parent scope. This can be done by passing a map of local variable names\n\t * and values into the expression wrapper fn. For example, if the expression is `increment(amount)`\n\t * then we can specify the amount value by calling the `localFn` as `localFn({amount: 22})`.\n\t *\n\t * In general it's possible to apply more than one directive to one element, but there might be limitations\n\t * depending on the type of scope required by the directives. The following points will help explain these limitations.\n\t * For simplicity only two directives are taken into account, but it is also applicable for several directives:\n\t *\n\t * * **no scope** + **no scope** => Two directives which don't require their own scope will use their parent's scope\n\t * * **child scope** + **no scope** => Both directives will share one single child scope\n\t * * **child scope** + **child scope** => Both directives will share one single child scope\n\t * * **isolated scope** + **no scope** => The isolated directive will use it's own created isolated scope. The other directive will use\n\t * its parent's scope\n\t * * **isolated scope** + **child scope** => **Won't work!** Only one scope can be related to one element. Therefore these directives cannot\n\t * be applied to the same element.\n\t * * **isolated scope** + **isolated scope** => **Won't work!** Only one scope can be related to one element. Therefore these directives\n\t * cannot be applied to the same element.\n\t *\n\t *\n\t * #### `bindToController`\n\t * This property is used to bind scope properties directly to the controller. It can be either\n\t * `true` or an object hash with the same format as the `scope` property. Additionally, a controller\n\t * alias must be set, either by using `controllerAs: 'myAlias'` or by specifying the alias in the controller\n\t * definition: `controller: 'myCtrl as myAlias'`.\n\t *\n\t * When an isolate scope is used for a directive (see above), `bindToController: true` will\n\t * allow a component to have its properties bound to the controller, rather than to scope. When the controller\n\t * is instantiated, the initial values of the isolate scope bindings are already available.\n\t *\n\t * It is also possible to set `bindToController` to an object hash with the same format as the `scope` property.\n\t * This will set up the scope bindings to the controller directly. Note that `scope` can still be used\n\t * to define which kind of scope is created. By default, no scope is created. Use `scope: {}` to create an isolate\n\t * scope (useful for component directives).\n\t *\n\t * If both `bindToController` and `scope` are defined and have object hashes, `bindToController` overrides `scope`.\n\t *\n\t *\n\t * #### `controller`\n\t * Controller constructor function. The controller is instantiated before the\n\t * pre-linking phase and can be accessed by other directives (see\n\t * `require` attribute). This allows the directives to communicate with each other and augment\n\t * each other's behavior. The controller is injectable (and supports bracket notation) with the following locals:\n\t *\n\t * * `$scope` - Current scope associated with the element\n\t * * `$element` - Current element\n\t * * `$attrs` - Current attributes object for the element\n\t * * `$transclude` - A transclude linking function pre-bound to the correct transclusion scope:\n\t * `function([scope], cloneLinkingFn, futureParentElement)`.\n\t * * `scope`: optional argument to override the scope.\n\t * * `cloneLinkingFn`: optional argument to create clones of the original transcluded content.\n\t * * `futureParentElement`:\n\t * * defines the parent to which the `cloneLinkingFn` will add the cloned elements.\n\t * * default: `$element.parent()` resp. `$element` for `transclude:'element'` resp. `transclude:true`.\n\t * * only needed for transcludes that are allowed to contain non html elements (e.g. SVG elements)\n\t * and when the `cloneLinkinFn` is passed,\n\t * as those elements need to created and cloned in a special way when they are defined outside their\n\t * usual containers (e.g. like ``).\n\t * * See also the `directive.templateNamespace` property.\n\t *\n\t *\n\t * #### `require`\n\t * Require another directive and inject its controller as the fourth argument to the linking function. The\n\t * `require` takes a string name (or array of strings) of the directive(s) to pass in. If an array is used, the\n\t * injected argument will be an array in corresponding order. If no such directive can be\n\t * found, or if the directive does not have a controller, then an error is raised (unless no link function\n\t * is specified, in which case error checking is skipped). The name can be prefixed with:\n\t *\n\t * * (no prefix) - Locate the required controller on the current element. Throw an error if not found.\n\t * * `?` - Attempt to locate the required controller or pass `null` to the `link` fn if not found.\n\t * * `^` - Locate the required controller by searching the element and its parents. Throw an error if not found.\n\t * * `^^` - Locate the required controller by searching the element's parents. Throw an error if not found.\n\t * * `?^` - Attempt to locate the required controller by searching the element and its parents or pass\n\t * `null` to the `link` fn if not found.\n\t * * `?^^` - Attempt to locate the required controller by searching the element's parents, or pass\n\t * `null` to the `link` fn if not found.\n\t *\n\t *\n\t * #### `controllerAs`\n\t * Identifier name for a reference to the controller in the directive's scope.\n\t * This allows the controller to be referenced from the directive template. This is especially\n\t * useful when a directive is used as component, i.e. with an `isolate` scope. It's also possible\n\t * to use it in a directive without an `isolate` / `new` scope, but you need to be aware that the\n\t * `controllerAs` reference might overwrite a property that already exists on the parent scope.\n\t *\n\t *\n\t * #### `restrict`\n\t * String of subset of `EACM` which restricts the directive to a specific directive\n\t * declaration style. If omitted, the defaults (elements and attributes) are used.\n\t *\n\t * * `E` - Element name (default): ``\n\t * * `A` - Attribute (default): `
`\n\t * * `C` - Class: `
`\n\t * * `M` - Comment: ``\n\t *\n\t *\n\t * #### `templateNamespace`\n\t * String representing the document type used by the markup in the template.\n\t * AngularJS needs this information as those elements need to be created and cloned\n\t * in a special way when they are defined outside their usual containers like `` and ``.\n\t *\n\t * * `html` - All root nodes in the template are HTML. Root nodes may also be\n\t * top-level elements such as `` or ``.\n\t * * `svg` - The root nodes in the template are SVG elements (excluding ``).\n\t * * `math` - The root nodes in the template are MathML elements (excluding ``).\n\t *\n\t * If no `templateNamespace` is specified, then the namespace is considered to be `html`.\n\t *\n\t * #### `template`\n\t * HTML markup that may:\n\t * * Replace the contents of the directive's element (default).\n\t * * Replace the directive's element itself (if `replace` is true - DEPRECATED).\n\t * * Wrap the contents of the directive's element (if `transclude` is true).\n\t *\n\t * Value may be:\n\t *\n\t * * A string. For example `
{{delete_str}}
`.\n\t * * A function which takes two arguments `tElement` and `tAttrs` (described in the `compile`\n\t * function api below) and returns a string value.\n\t *\n\t *\n\t * #### `templateUrl`\n\t * This is similar to `template` but the template is loaded from the specified URL, asynchronously.\n\t *\n\t * Because template loading is asynchronous the compiler will suspend compilation of directives on that element\n\t * for later when the template has been resolved. In the meantime it will continue to compile and link\n\t * sibling and parent elements as though this element had not contained any directives.\n\t *\n\t * The compiler does not suspend the entire compilation to wait for templates to be loaded because this\n\t * would result in the whole app \"stalling\" until all templates are loaded asynchronously - even in the\n\t * case when only one deeply nested directive has `templateUrl`.\n\t *\n\t * Template loading is asynchronous even if the template has been preloaded into the {@link $templateCache}\n\t *\n\t * You can specify `templateUrl` as a string representing the URL or as a function which takes two\n\t * arguments `tElement` and `tAttrs` (described in the `compile` function api below) and returns\n\t * a string value representing the url. In either case, the template URL is passed through {@link\n\t * $sce#getTrustedResourceUrl $sce.getTrustedResourceUrl}.\n\t *\n\t *\n\t * #### `replace` ([*DEPRECATED*!], will be removed in next major release - i.e. v2.0)\n\t * specify what the template should replace. Defaults to `false`.\n\t *\n\t * * `true` - the template will replace the directive's element.\n\t * * `false` - the template will replace the contents of the directive's element.\n\t *\n\t * The replacement process migrates all of the attributes / classes from the old element to the new\n\t * one. See the {@link guide/directive#template-expanding-directive\n\t * Directives Guide} for an example.\n\t *\n\t * There are very few scenarios where element replacement is required for the application function,\n\t * the main one being reusable custom components that are used within SVG contexts\n\t * (because SVG doesn't work with custom elements in the DOM tree).\n\t *\n\t * #### `transclude`\n\t * Extract the contents of the element where the directive appears and make it available to the directive.\n\t * The contents are compiled and provided to the directive as a **transclusion function**. See the\n\t * {@link $compile#transclusion Transclusion} section below.\n\t *\n\t * There are two kinds of transclusion depending upon whether you want to transclude just the contents of the\n\t * directive's element or the entire element:\n\t *\n\t * * `true` - transclude the content (i.e. the child nodes) of the directive's element.\n\t * * `'element'` - transclude the whole of the directive's element including any directives on this\n\t * element that defined at a lower priority than this directive. When used, the `template`\n\t * property is ignored.\n\t *\n\t *\n\t * #### `compile`\n\t *\n\t * ```js\n\t * function compile(tElement, tAttrs, transclude) { ... }\n\t * ```\n\t *\n\t * The compile function deals with transforming the template DOM. Since most directives do not do\n\t * template transformation, it is not used often. The compile function takes the following arguments:\n\t *\n\t * * `tElement` - template element - The element where the directive has been declared. It is\n\t * safe to do template transformation on the element and child elements only.\n\t *\n\t * * `tAttrs` - template attributes - Normalized list of attributes declared on this element shared\n\t * between all directive compile functions.\n\t *\n\t * * `transclude` - [*DEPRECATED*!] A transclude linking function: `function(scope, cloneLinkingFn)`\n\t *\n\t *
\n\t * **Note:** The template instance and the link instance may be different objects if the template has\n\t * been cloned. For this reason it is **not** safe to do anything other than DOM transformations that\n\t * apply to all cloned DOM nodes within the compile function. Specifically, DOM listener registration\n\t * should be done in a linking function rather than in a compile function.\n\t *
\n\t\n\t *
\n\t * **Note:** The compile function cannot handle directives that recursively use themselves in their\n\t * own templates or compile functions. Compiling these directives results in an infinite loop and\n\t * stack overflow errors.\n\t *\n\t * This can be avoided by manually using $compile in the postLink function to imperatively compile\n\t * a directive's template instead of relying on automatic template compilation via `template` or\n\t * `templateUrl` declaration or manual compilation inside the compile function.\n\t *
\n\t *\n\t *
\n\t * **Note:** The `transclude` function that is passed to the compile function is deprecated, as it\n\t * e.g. does not know about the right outer scope. Please use the transclude function that is passed\n\t * to the link function instead.\n\t *
\n\t\n\t * A compile function can have a return value which can be either a function or an object.\n\t *\n\t * * returning a (post-link) function - is equivalent to registering the linking function via the\n\t * `link` property of the config object when the compile function is empty.\n\t *\n\t * * returning an object with function(s) registered via `pre` and `post` properties - allows you to\n\t * control when a linking function should be called during the linking phase. See info about\n\t * pre-linking and post-linking functions below.\n\t *\n\t *\n\t * #### `link`\n\t * This property is used only if the `compile` property is not defined.\n\t *\n\t * ```js\n\t * function link(scope, iElement, iAttrs, controller, transcludeFn) { ... }\n\t * ```\n\t *\n\t * The link function is responsible for registering DOM listeners as well as updating the DOM. It is\n\t * executed after the template has been cloned. This is where most of the directive logic will be\n\t * put.\n\t *\n\t * * `scope` - {@link ng.$rootScope.Scope Scope} - The scope to be used by the\n\t * directive for registering {@link ng.$rootScope.Scope#$watch watches}.\n\t *\n\t * * `iElement` - instance element - The element where the directive is to be used. It is safe to\n\t * manipulate the children of the element only in `postLink` function since the children have\n\t * already been linked.\n\t *\n\t * * `iAttrs` - instance attributes - Normalized list of attributes declared on this element shared\n\t * between all directive linking functions.\n\t *\n\t * * `controller` - the directive's required controller instance(s) - Instances are shared\n\t * among all directives, which allows the directives to use the controllers as a communication\n\t * channel. The exact value depends on the directive's `require` property:\n\t * * no controller(s) required: the directive's own controller, or `undefined` if it doesn't have one\n\t * * `string`: the controller instance\n\t * * `array`: array of controller instances\n\t *\n\t * If a required controller cannot be found, and it is optional, the instance is `null`,\n\t * otherwise the {@link error:$compile:ctreq Missing Required Controller} error is thrown.\n\t *\n\t * Note that you can also require the directive's own controller - it will be made available like\n\t * any other controller.\n\t *\n\t * * `transcludeFn` - A transclude linking function pre-bound to the correct transclusion scope.\n\t * This is the same as the `$transclude`\n\t * parameter of directive controllers, see there for details.\n\t * `function([scope], cloneLinkingFn, futureParentElement)`.\n\t *\n\t * #### Pre-linking function\n\t *\n\t * Executed before the child elements are linked. Not safe to do DOM transformation since the\n\t * compiler linking function will fail to locate the correct elements for linking.\n\t *\n\t * #### Post-linking function\n\t *\n\t * Executed after the child elements are linked.\n\t *\n\t * Note that child elements that contain `templateUrl` directives will not have been compiled\n\t * and linked since they are waiting for their template to load asynchronously and their own\n\t * compilation and linking has been suspended until that occurs.\n\t *\n\t * It is safe to do DOM transformation in the post-linking function on elements that are not waiting\n\t * for their async templates to be resolved.\n\t *\n\t *\n\t * ### Transclusion\n\t *\n\t * Transclusion is the process of extracting a collection of DOM elements from one part of the DOM and\n\t * copying them to another part of the DOM, while maintaining their connection to the original AngularJS\n\t * scope from where they were taken.\n\t *\n\t * Transclusion is used (often with {@link ngTransclude}) to insert the\n\t * original contents of a directive's element into a specified place in the template of the directive.\n\t * The benefit of transclusion, over simply moving the DOM elements manually, is that the transcluded\n\t * content has access to the properties on the scope from which it was taken, even if the directive\n\t * has isolated scope.\n\t * See the {@link guide/directive#creating-a-directive-that-wraps-other-elements Directives Guide}.\n\t *\n\t * This makes it possible for the widget to have private state for its template, while the transcluded\n\t * content has access to its originating scope.\n\t *\n\t *
\n\t * **Note:** When testing an element transclude directive you must not place the directive at the root of the\n\t * DOM fragment that is being compiled. See {@link guide/unit-testing#testing-transclusion-directives\n\t * Testing Transclusion Directives}.\n\t *
\n\t *\n\t * #### Transclusion Functions\n\t *\n\t * When a directive requests transclusion, the compiler extracts its contents and provides a **transclusion\n\t * function** to the directive's `link` function and `controller`. This transclusion function is a special\n\t * **linking function** that will return the compiled contents linked to a new transclusion scope.\n\t *\n\t *
\n\t * If you are just using {@link ngTransclude} then you don't need to worry about this function, since\n\t * ngTransclude will deal with it for us.\n\t *
\n\t *\n\t * If you want to manually control the insertion and removal of the transcluded content in your directive\n\t * then you must use this transclude function. When you call a transclude function it returns a a jqLite/JQuery\n\t * object that contains the compiled DOM, which is linked to the correct transclusion scope.\n\t *\n\t * When you call a transclusion function you can pass in a **clone attach function**. This function accepts\n\t * two parameters, `function(clone, scope) { ... }`, where the `clone` is a fresh compiled copy of your transcluded\n\t * content and the `scope` is the newly created transclusion scope, to which the clone is bound.\n\t *\n\t *
\n\t * **Best Practice**: Always provide a `cloneFn` (clone attach function) when you call a translude function\n\t * since you then get a fresh clone of the original DOM and also have access to the new transclusion scope.\n\t *
\n\t *\n\t * It is normal practice to attach your transcluded content (`clone`) to the DOM inside your **clone\n\t * attach function**:\n\t *\n\t * ```js\n\t * var transcludedContent, transclusionScope;\n\t *\n\t * $transclude(function(clone, scope) {\n\t * element.append(clone);\n\t * transcludedContent = clone;\n\t * transclusionScope = scope;\n\t * });\n\t * ```\n\t *\n\t * Later, if you want to remove the transcluded content from your DOM then you should also destroy the\n\t * associated transclusion scope:\n\t *\n\t * ```js\n\t * transcludedContent.remove();\n\t * transclusionScope.$destroy();\n\t * ```\n\t *\n\t *
\n\t * **Best Practice**: if you intend to add and remove transcluded content manually in your directive\n\t * (by calling the transclude function to get the DOM and calling `element.remove()` to remove it),\n\t * then you are also responsible for calling `$destroy` on the transclusion scope.\n\t *
\n\t *\n\t * The built-in DOM manipulation directives, such as {@link ngIf}, {@link ngSwitch} and {@link ngRepeat}\n\t * automatically destroy their transluded clones as necessary so you do not need to worry about this if\n\t * you are simply using {@link ngTransclude} to inject the transclusion into your directive.\n\t *\n\t *\n\t * #### Transclusion Scopes\n\t *\n\t * When you call a transclude function it returns a DOM fragment that is pre-bound to a **transclusion\n\t * scope**. This scope is special, in that it is a child of the directive's scope (and so gets destroyed\n\t * when the directive's scope gets destroyed) but it inherits the properties of the scope from which it\n\t * was taken.\n\t *\n\t * For example consider a directive that uses transclusion and isolated scope. The DOM hierarchy might look\n\t * like this:\n\t *\n\t * ```html\n\t *
\n\t *
\n\t *
\n\t *
\n\t *
\n\t *
\n\t * ```\n\t *\n\t * The `$parent` scope hierarchy will look like this:\n\t *\n\t ```\n\t - $rootScope\n\t - isolate\n\t - transclusion\n\t ```\n\t *\n\t * but the scopes will inherit prototypically from different scopes to their `$parent`.\n\t *\n\t ```\n\t - $rootScope\n\t - transclusion\n\t - isolate\n\t ```\n\t *\n\t *\n\t * ### Attributes\n\t *\n\t * The {@link ng.$compile.directive.Attributes Attributes} object - passed as a parameter in the\n\t * `link()` or `compile()` functions. It has a variety of uses.\n\t *\n\t * * *Accessing normalized attribute names:* Directives like 'ngBind' can be expressed in many ways:\n\t * 'ng:bind', `data-ng-bind`, or 'x-ng-bind'. The attributes object allows for normalized access\n\t * to the attributes.\n\t *\n\t * * *Directive inter-communication:* All directives share the same instance of the attributes\n\t * object which allows the directives to use the attributes object as inter directive\n\t * communication.\n\t *\n\t * * *Supports interpolation:* Interpolation attributes are assigned to the attribute object\n\t * allowing other directives to read the interpolated value.\n\t *\n\t * * *Observing interpolated attributes:* Use `$observe` to observe the value changes of attributes\n\t * that contain interpolation (e.g. `src=\"{{bar}}\"`). Not only is this very efficient but it's also\n\t * the only way to easily get the actual value because during the linking phase the interpolation\n\t * hasn't been evaluated yet and so the value is at this time set to `undefined`.\n\t *\n\t * ```js\n\t * function linkingFn(scope, elm, attrs, ctrl) {\n\t * // get the attribute value\n\t * console.log(attrs.ngModel);\n\t *\n\t * // change the attribute\n\t * attrs.$set('ngModel', 'new value');\n\t *\n\t * // observe changes to interpolated attribute\n\t * attrs.$observe('ngModel', function(value) {\n\t * console.log('ngModel has changed value to ' + value);\n\t * });\n\t * }\n\t * ```\n\t *\n\t * ## Example\n\t *\n\t *
\n\t * **Note**: Typically directives are registered with `module.directive`. The example below is\n\t * to illustrate how `$compile` works.\n\t *
\n\t *\n\t \n\t \n\t \n\t
\n\t
\n\t
\n\t
\n\t
\n\t
\n\t \n\t it('should auto compile', function() {\n\t var textarea = $('textarea');\n\t var output = $('div[compile]');\n\t // The initial state reads 'Hello Angular'.\n\t expect(output.getText()).toBe('Hello Angular');\n\t textarea.clear();\n\t textarea.sendKeys('{{name}}!');\n\t expect(output.getText()).toBe('Angular!');\n\t });\n\t \n\t
\n\t\n\t *\n\t *\n\t * @param {string|DOMElement} element Element or HTML string to compile into a template function.\n\t * @param {function(angular.Scope, cloneAttachFn=)} transclude function available to directives - DEPRECATED.\n\t *\n\t *
\n\t * **Note:** Passing a `transclude` function to the $compile function is deprecated, as it\n\t * e.g. will not use the right outer scope. Please pass the transclude function as a\n\t * `parentBoundTranscludeFn` to the link function instead.\n\t *
\n\t *\n\t * @param {number} maxPriority only apply directives lower than given priority (Only effects the\n\t * root element(s), not their children)\n\t * @returns {function(scope, cloneAttachFn=, options=)} a link function which is used to bind template\n\t * (a DOM element/tree) to a scope. Where:\n\t *\n\t * * `scope` - A {@link ng.$rootScope.Scope Scope} to bind to.\n\t * * `cloneAttachFn` - If `cloneAttachFn` is provided, then the link function will clone the\n\t * `template` and call the `cloneAttachFn` function allowing the caller to attach the\n\t * cloned elements to the DOM document at the appropriate place. The `cloneAttachFn` is\n\t * called as:
`cloneAttachFn(clonedElement, scope)` where:\n\t *\n\t * * `clonedElement` - is a clone of the original `element` passed into the compiler.\n\t * * `scope` - is the current scope with which the linking function is working with.\n\t *\n\t * * `options` - An optional object hash with linking options. If `options` is provided, then the following\n\t * keys may be used to control linking behavior:\n\t *\n\t * * `parentBoundTranscludeFn` - the transclude function made available to\n\t * directives; if given, it will be passed through to the link functions of\n\t * directives found in `element` during compilation.\n\t * * `transcludeControllers` - an object hash with keys that map controller names\n\t * to a hash with the key `instance`, which maps to the controller instance;\n\t * if given, it will make the controllers available to directives on the compileNode:\n\t * ```\n\t * {\n\t * parent: {\n\t * instance: parentControllerInstance\n\t * }\n\t * }\n\t * ```\n\t * * `futureParentElement` - defines the parent to which the `cloneAttachFn` will add\n\t * the cloned elements; only needed for transcludes that are allowed to contain non html\n\t * elements (e.g. SVG elements). See also the directive.controller property.\n\t *\n\t * Calling the linking function returns the element of the template. It is either the original\n\t * element passed in, or the clone of the element if the `cloneAttachFn` is provided.\n\t *\n\t * After linking the view is not updated until after a call to $digest which typically is done by\n\t * Angular automatically.\n\t *\n\t * If you need access to the bound view, there are two ways to do it:\n\t *\n\t * - If you are not asking the linking function to clone the template, create the DOM element(s)\n\t * before you send them to the compiler and keep this reference around.\n\t * ```js\n\t * var element = $compile('

{{total}}

')(scope);\n\t * ```\n\t *\n\t * - if on the other hand, you need the element to be cloned, the view reference from the original\n\t * example would not point to the clone, but rather to the original template that was cloned. In\n\t * this case, you can access the clone via the cloneAttachFn:\n\t * ```js\n\t * var templateElement = angular.element('

{{total}}

'),\n\t * scope = ....;\n\t *\n\t * var clonedElement = $compile(templateElement)(scope, function(clonedElement, scope) {\n\t * //attach the clone to DOM document at the right place\n\t * });\n\t *\n\t * //now we have reference to the cloned DOM via `clonedElement`\n\t * ```\n\t *\n\t *\n\t * For information on how the compiler works, see the\n\t * {@link guide/compiler Angular HTML Compiler} section of the Developer Guide.\n\t */\n\t\n\tvar $compileMinErr = minErr('$compile');\n\t\n\t/**\n\t * @ngdoc provider\n\t * @name $compileProvider\n\t *\n\t * @description\n\t */\n\t$CompileProvider.$inject = ['$provide', '$$sanitizeUriProvider'];\n\tfunction $CompileProvider($provide, $$sanitizeUriProvider) {\n\t var hasDirectives = {},\n\t Suffix = 'Directive',\n\t COMMENT_DIRECTIVE_REGEXP = /^\\s*directive\\:\\s*([\\w\\-]+)\\s+(.*)$/,\n\t CLASS_DIRECTIVE_REGEXP = /(([\\w\\-]+)(?:\\:([^;]+))?;?)/,\n\t ALL_OR_NOTHING_ATTRS = makeMap('ngSrc,ngSrcset,src,srcset'),\n\t REQUIRE_PREFIX_REGEXP = /^(?:(\\^\\^?)?(\\?)?(\\^\\^?)?)?/;\n\t\n\t // Ref: http://developers.whatwg.org/webappapis.html#event-handler-idl-attributes\n\t // The assumption is that future DOM event attribute names will begin with\n\t // 'on' and be composed of only English letters.\n\t var EVENT_HANDLER_ATTR_REGEXP = /^(on[a-z]+|formaction)$/;\n\t var bindingCache = createMap();\n\t\n\t function parseIsolateBindings(scope, directiveName, isController) {\n\t var LOCAL_REGEXP = /^\\s*([@&]|=(\\*?))(\\??)\\s*(\\w*)\\s*$/;\n\t\n\t var bindings = createMap();\n\t\n\t forEach(scope, function(definition, scopeName) {\n\t if (definition in bindingCache) {\n\t bindings[scopeName] = bindingCache[definition];\n\t return;\n\t }\n\t var match = definition.match(LOCAL_REGEXP);\n\t\n\t if (!match) {\n\t throw $compileMinErr('iscp',\n\t \"Invalid {3} for directive '{0}'.\" +\n\t \" Definition: {... {1}: '{2}' ...}\",\n\t directiveName, scopeName, definition,\n\t (isController ? \"controller bindings definition\" :\n\t \"isolate scope definition\"));\n\t }\n\t\n\t bindings[scopeName] = {\n\t mode: match[1][0],\n\t collection: match[2] === '*',\n\t optional: match[3] === '?',\n\t attrName: match[4] || scopeName\n\t };\n\t if (match[4]) {\n\t bindingCache[definition] = bindings[scopeName];\n\t }\n\t });\n\t\n\t return bindings;\n\t }\n\t\n\t function parseDirectiveBindings(directive, directiveName) {\n\t var bindings = {\n\t isolateScope: null,\n\t bindToController: null\n\t };\n\t if (isObject(directive.scope)) {\n\t if (directive.bindToController === true) {\n\t bindings.bindToController = parseIsolateBindings(directive.scope,\n\t directiveName, true);\n\t bindings.isolateScope = {};\n\t } else {\n\t bindings.isolateScope = parseIsolateBindings(directive.scope,\n\t directiveName, false);\n\t }\n\t }\n\t if (isObject(directive.bindToController)) {\n\t bindings.bindToController =\n\t parseIsolateBindings(directive.bindToController, directiveName, true);\n\t }\n\t if (isObject(bindings.bindToController)) {\n\t var controller = directive.controller;\n\t var controllerAs = directive.controllerAs;\n\t if (!controller) {\n\t // There is no controller, there may or may not be a controllerAs property\n\t throw $compileMinErr('noctrl',\n\t \"Cannot bind to controller without directive '{0}'s controller.\",\n\t directiveName);\n\t } else if (!identifierForController(controller, controllerAs)) {\n\t // There is a controller, but no identifier or controllerAs property\n\t throw $compileMinErr('noident',\n\t \"Cannot bind to controller without identifier for directive '{0}'.\",\n\t directiveName);\n\t }\n\t }\n\t return bindings;\n\t }\n\t\n\t function assertValidDirectiveName(name) {\n\t var letter = name.charAt(0);\n\t if (!letter || letter !== lowercase(letter)) {\n\t throw $compileMinErr('baddir', \"Directive name '{0}' is invalid. The first character must be a lowercase letter\", name);\n\t }\n\t if (name !== name.trim()) {\n\t throw $compileMinErr('baddir',\n\t \"Directive name '{0}' is invalid. The name should not contain leading or trailing whitespaces\",\n\t name);\n\t }\n\t }\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $compileProvider#directive\n\t * @kind function\n\t *\n\t * @description\n\t * Register a new directive with the compiler.\n\t *\n\t * @param {string|Object} name Name of the directive in camel-case (i.e. ngBind which\n\t * will match as ng-bind), or an object map of directives where the keys are the\n\t * names and the values are the factories.\n\t * @param {Function|Array} directiveFactory An injectable directive factory function. See\n\t * {@link guide/directive} for more info.\n\t * @returns {ng.$compileProvider} Self for chaining.\n\t */\n\t this.directive = function registerDirective(name, directiveFactory) {\n\t assertNotHasOwnProperty(name, 'directive');\n\t if (isString(name)) {\n\t assertValidDirectiveName(name);\n\t assertArg(directiveFactory, 'directiveFactory');\n\t if (!hasDirectives.hasOwnProperty(name)) {\n\t hasDirectives[name] = [];\n\t $provide.factory(name + Suffix, ['$injector', '$exceptionHandler',\n\t function($injector, $exceptionHandler) {\n\t var directives = [];\n\t forEach(hasDirectives[name], function(directiveFactory, index) {\n\t try {\n\t var directive = $injector.invoke(directiveFactory);\n\t if (isFunction(directive)) {\n\t directive = { compile: valueFn(directive) };\n\t } else if (!directive.compile && directive.link) {\n\t directive.compile = valueFn(directive.link);\n\t }\n\t directive.priority = directive.priority || 0;\n\t directive.index = index;\n\t directive.name = directive.name || name;\n\t directive.require = directive.require || (directive.controller && directive.name);\n\t directive.restrict = directive.restrict || 'EA';\n\t directive.$$moduleName = directiveFactory.$$moduleName;\n\t directives.push(directive);\n\t } catch (e) {\n\t $exceptionHandler(e);\n\t }\n\t });\n\t return directives;\n\t }]);\n\t }\n\t hasDirectives[name].push(directiveFactory);\n\t } else {\n\t forEach(name, reverseParams(registerDirective));\n\t }\n\t return this;\n\t };\n\t\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $compileProvider#aHrefSanitizationWhitelist\n\t * @kind function\n\t *\n\t * @description\n\t * Retrieves or overrides the default regular expression that is used for whitelisting of safe\n\t * urls during a[href] sanitization.\n\t *\n\t * The sanitization is a security measure aimed at preventing XSS attacks via html links.\n\t *\n\t * Any url about to be assigned to a[href] via data-binding is first normalized and turned into\n\t * an absolute url. Afterwards, the url is matched against the `aHrefSanitizationWhitelist`\n\t * regular expression. If a match is found, the original url is written into the dom. Otherwise,\n\t * the absolute url is prefixed with `'unsafe:'` string and only then is it written into the DOM.\n\t *\n\t * @param {RegExp=} regexp New regexp to whitelist urls with.\n\t * @returns {RegExp|ng.$compileProvider} Current RegExp if called without value or self for\n\t * chaining otherwise.\n\t */\n\t this.aHrefSanitizationWhitelist = function(regexp) {\n\t if (isDefined(regexp)) {\n\t $$sanitizeUriProvider.aHrefSanitizationWhitelist(regexp);\n\t return this;\n\t } else {\n\t return $$sanitizeUriProvider.aHrefSanitizationWhitelist();\n\t }\n\t };\n\t\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $compileProvider#imgSrcSanitizationWhitelist\n\t * @kind function\n\t *\n\t * @description\n\t * Retrieves or overrides the default regular expression that is used for whitelisting of safe\n\t * urls during img[src] sanitization.\n\t *\n\t * The sanitization is a security measure aimed at prevent XSS attacks via html links.\n\t *\n\t * Any url about to be assigned to img[src] via data-binding is first normalized and turned into\n\t * an absolute url. Afterwards, the url is matched against the `imgSrcSanitizationWhitelist`\n\t * regular expression. If a match is found, the original url is written into the dom. Otherwise,\n\t * the absolute url is prefixed with `'unsafe:'` string and only then is it written into the DOM.\n\t *\n\t * @param {RegExp=} regexp New regexp to whitelist urls with.\n\t * @returns {RegExp|ng.$compileProvider} Current RegExp if called without value or self for\n\t * chaining otherwise.\n\t */\n\t this.imgSrcSanitizationWhitelist = function(regexp) {\n\t if (isDefined(regexp)) {\n\t $$sanitizeUriProvider.imgSrcSanitizationWhitelist(regexp);\n\t return this;\n\t } else {\n\t return $$sanitizeUriProvider.imgSrcSanitizationWhitelist();\n\t }\n\t };\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $compileProvider#debugInfoEnabled\n\t *\n\t * @param {boolean=} enabled update the debugInfoEnabled state if provided, otherwise just return the\n\t * current debugInfoEnabled state\n\t * @returns {*} current value if used as getter or itself (chaining) if used as setter\n\t *\n\t * @kind function\n\t *\n\t * @description\n\t * Call this method to enable/disable various debug runtime information in the compiler such as adding\n\t * binding information and a reference to the current scope on to DOM elements.\n\t * If enabled, the compiler will add the following to DOM elements that have been bound to the scope\n\t * * `ng-binding` CSS class\n\t * * `$binding` data property containing an array of the binding expressions\n\t *\n\t * You may want to disable this in production for a significant performance boost. See\n\t * {@link guide/production#disabling-debug-data Disabling Debug Data} for more.\n\t *\n\t * The default value is true.\n\t */\n\t var debugInfoEnabled = true;\n\t this.debugInfoEnabled = function(enabled) {\n\t if (isDefined(enabled)) {\n\t debugInfoEnabled = enabled;\n\t return this;\n\t }\n\t return debugInfoEnabled;\n\t };\n\t\n\t this.$get = [\n\t '$injector', '$interpolate', '$exceptionHandler', '$templateRequest', '$parse',\n\t '$controller', '$rootScope', '$sce', '$animate', '$$sanitizeUri',\n\t function($injector, $interpolate, $exceptionHandler, $templateRequest, $parse,\n\t $controller, $rootScope, $sce, $animate, $$sanitizeUri) {\n\t\n\t var Attributes = function(element, attributesToCopy) {\n\t if (attributesToCopy) {\n\t var keys = Object.keys(attributesToCopy);\n\t var i, l, key;\n\t\n\t for (i = 0, l = keys.length; i < l; i++) {\n\t key = keys[i];\n\t this[key] = attributesToCopy[key];\n\t }\n\t } else {\n\t this.$attr = {};\n\t }\n\t\n\t this.$$element = element;\n\t };\n\t\n\t Attributes.prototype = {\n\t /**\n\t * @ngdoc method\n\t * @name $compile.directive.Attributes#$normalize\n\t * @kind function\n\t *\n\t * @description\n\t * Converts an attribute name (e.g. dash/colon/underscore-delimited string, optionally prefixed with `x-` or\n\t * `data-`) to its normalized, camelCase form.\n\t *\n\t * Also there is special case for Moz prefix starting with upper case letter.\n\t *\n\t * For further information check out the guide on {@link guide/directive#matching-directives Matching Directives}\n\t *\n\t * @param {string} name Name to normalize\n\t */\n\t $normalize: directiveNormalize,\n\t\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $compile.directive.Attributes#$addClass\n\t * @kind function\n\t *\n\t * @description\n\t * Adds the CSS class value specified by the classVal parameter to the element. If animations\n\t * are enabled then an animation will be triggered for the class addition.\n\t *\n\t * @param {string} classVal The className value that will be added to the element\n\t */\n\t $addClass: function(classVal) {\n\t if (classVal && classVal.length > 0) {\n\t $animate.addClass(this.$$element, classVal);\n\t }\n\t },\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $compile.directive.Attributes#$removeClass\n\t * @kind function\n\t *\n\t * @description\n\t * Removes the CSS class value specified by the classVal parameter from the element. If\n\t * animations are enabled then an animation will be triggered for the class removal.\n\t *\n\t * @param {string} classVal The className value that will be removed from the element\n\t */\n\t $removeClass: function(classVal) {\n\t if (classVal && classVal.length > 0) {\n\t $animate.removeClass(this.$$element, classVal);\n\t }\n\t },\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $compile.directive.Attributes#$updateClass\n\t * @kind function\n\t *\n\t * @description\n\t * Adds and removes the appropriate CSS class values to the element based on the difference\n\t * between the new and old CSS class values (specified as newClasses and oldClasses).\n\t *\n\t * @param {string} newClasses The current CSS className value\n\t * @param {string} oldClasses The former CSS className value\n\t */\n\t $updateClass: function(newClasses, oldClasses) {\n\t var toAdd = tokenDifference(newClasses, oldClasses);\n\t if (toAdd && toAdd.length) {\n\t $animate.addClass(this.$$element, toAdd);\n\t }\n\t\n\t var toRemove = tokenDifference(oldClasses, newClasses);\n\t if (toRemove && toRemove.length) {\n\t $animate.removeClass(this.$$element, toRemove);\n\t }\n\t },\n\t\n\t /**\n\t * Set a normalized attribute on the element in a way such that all directives\n\t * can share the attribute. This function properly handles boolean attributes.\n\t * @param {string} key Normalized key. (ie ngAttribute)\n\t * @param {string|boolean} value The value to set. If `null` attribute will be deleted.\n\t * @param {boolean=} writeAttr If false, does not write the value to DOM element attribute.\n\t * Defaults to true.\n\t * @param {string=} attrName Optional none normalized name. Defaults to key.\n\t */\n\t $set: function(key, value, writeAttr, attrName) {\n\t // TODO: decide whether or not to throw an error if \"class\"\n\t //is set through this function since it may cause $updateClass to\n\t //become unstable.\n\t\n\t var node = this.$$element[0],\n\t booleanKey = getBooleanAttrName(node, key),\n\t aliasedKey = getAliasedAttrName(key),\n\t observer = key,\n\t nodeName;\n\t\n\t if (booleanKey) {\n\t this.$$element.prop(key, value);\n\t attrName = booleanKey;\n\t } else if (aliasedKey) {\n\t this[aliasedKey] = value;\n\t observer = aliasedKey;\n\t }\n\t\n\t this[key] = value;\n\t\n\t // translate normalized key to actual key\n\t if (attrName) {\n\t this.$attr[key] = attrName;\n\t } else {\n\t attrName = this.$attr[key];\n\t if (!attrName) {\n\t this.$attr[key] = attrName = snake_case(key, '-');\n\t }\n\t }\n\t\n\t nodeName = nodeName_(this.$$element);\n\t\n\t if ((nodeName === 'a' && key === 'href') ||\n\t (nodeName === 'img' && key === 'src')) {\n\t // sanitize a[href] and img[src] values\n\t this[key] = value = $$sanitizeUri(value, key === 'src');\n\t } else if (nodeName === 'img' && key === 'srcset' && isDefined(value)) {\n\t // sanitize img[srcset] values\n\t var result = \"\";\n\t\n\t // first check if there are spaces because it's not the same pattern\n\t var trimmedSrcset = trim(value);\n\t // ( 999x ,| 999w ,| ,|, )\n\t var srcPattern = /(\\s+\\d+x\\s*,|\\s+\\d+w\\s*,|\\s+,|,\\s+)/;\n\t var pattern = /\\s/.test(trimmedSrcset) ? srcPattern : /(,)/;\n\t\n\t // split srcset into tuple of uri and descriptor except for the last item\n\t var rawUris = trimmedSrcset.split(pattern);\n\t\n\t // for each tuples\n\t var nbrUrisWith2parts = Math.floor(rawUris.length / 2);\n\t for (var i = 0; i < nbrUrisWith2parts; i++) {\n\t var innerIdx = i * 2;\n\t // sanitize the uri\n\t result += $$sanitizeUri(trim(rawUris[innerIdx]), true);\n\t // add the descriptor\n\t result += (\" \" + trim(rawUris[innerIdx + 1]));\n\t }\n\t\n\t // split the last item into uri and descriptor\n\t var lastTuple = trim(rawUris[i * 2]).split(/\\s/);\n\t\n\t // sanitize the last uri\n\t result += $$sanitizeUri(trim(lastTuple[0]), true);\n\t\n\t // and add the last descriptor if any\n\t if (lastTuple.length === 2) {\n\t result += (\" \" + trim(lastTuple[1]));\n\t }\n\t this[key] = value = result;\n\t }\n\t\n\t if (writeAttr !== false) {\n\t if (value === null || isUndefined(value)) {\n\t this.$$element.removeAttr(attrName);\n\t } else {\n\t this.$$element.attr(attrName, value);\n\t }\n\t }\n\t\n\t // fire observers\n\t var $$observers = this.$$observers;\n\t $$observers && forEach($$observers[observer], function(fn) {\n\t try {\n\t fn(value);\n\t } catch (e) {\n\t $exceptionHandler(e);\n\t }\n\t });\n\t },\n\t\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $compile.directive.Attributes#$observe\n\t * @kind function\n\t *\n\t * @description\n\t * Observes an interpolated attribute.\n\t *\n\t * The observer function will be invoked once during the next `$digest` following\n\t * compilation. The observer is then invoked whenever the interpolated value\n\t * changes.\n\t *\n\t * @param {string} key Normalized key. (ie ngAttribute) .\n\t * @param {function(interpolatedValue)} fn Function that will be called whenever\n\t the interpolated value of the attribute changes.\n\t * See the {@link guide/interpolation#how-text-and-attribute-bindings-work Interpolation\n\t * guide} for more info.\n\t * @returns {function()} Returns a deregistration function for this observer.\n\t */\n\t $observe: function(key, fn) {\n\t var attrs = this,\n\t $$observers = (attrs.$$observers || (attrs.$$observers = createMap())),\n\t listeners = ($$observers[key] || ($$observers[key] = []));\n\t\n\t listeners.push(fn);\n\t $rootScope.$evalAsync(function() {\n\t if (!listeners.$$inter && attrs.hasOwnProperty(key) && !isUndefined(attrs[key])) {\n\t // no one registered attribute interpolation function, so lets call it manually\n\t fn(attrs[key]);\n\t }\n\t });\n\t\n\t return function() {\n\t arrayRemove(listeners, fn);\n\t };\n\t }\n\t };\n\t\n\t\n\t function safeAddClass($element, className) {\n\t try {\n\t $element.addClass(className);\n\t } catch (e) {\n\t // ignore, since it means that we are trying to set class on\n\t // SVG element, where class name is read-only.\n\t }\n\t }\n\t\n\t\n\t var startSymbol = $interpolate.startSymbol(),\n\t endSymbol = $interpolate.endSymbol(),\n\t denormalizeTemplate = (startSymbol == '{{' && endSymbol == '}}')\n\t ? identity\n\t : function denormalizeTemplate(template) {\n\t return template.replace(/\\{\\{/g, startSymbol).replace(/}}/g, endSymbol);\n\t },\n\t NG_ATTR_BINDING = /^ngAttr[A-Z]/;\n\t var MULTI_ELEMENT_DIR_RE = /^(.+)Start$/;\n\t\n\t compile.$$addBindingInfo = debugInfoEnabled ? function $$addBindingInfo($element, binding) {\n\t var bindings = $element.data('$binding') || [];\n\t\n\t if (isArray(binding)) {\n\t bindings = bindings.concat(binding);\n\t } else {\n\t bindings.push(binding);\n\t }\n\t\n\t $element.data('$binding', bindings);\n\t } : noop;\n\t\n\t compile.$$addBindingClass = debugInfoEnabled ? function $$addBindingClass($element) {\n\t safeAddClass($element, 'ng-binding');\n\t } : noop;\n\t\n\t compile.$$addScopeInfo = debugInfoEnabled ? function $$addScopeInfo($element, scope, isolated, noTemplate) {\n\t var dataName = isolated ? (noTemplate ? '$isolateScopeNoTemplate' : '$isolateScope') : '$scope';\n\t $element.data(dataName, scope);\n\t } : noop;\n\t\n\t compile.$$addScopeClass = debugInfoEnabled ? function $$addScopeClass($element, isolated) {\n\t safeAddClass($element, isolated ? 'ng-isolate-scope' : 'ng-scope');\n\t } : noop;\n\t\n\t return compile;\n\t\n\t //================================\n\t\n\t function compile($compileNodes, transcludeFn, maxPriority, ignoreDirective,\n\t previousCompileContext) {\n\t if (!($compileNodes instanceof jqLite)) {\n\t // jquery always rewraps, whereas we need to preserve the original selector so that we can\n\t // modify it.\n\t $compileNodes = jqLite($compileNodes);\n\t }\n\t\n\t var NOT_EMPTY = /\\S+/;\n\t\n\t // We can not compile top level text elements since text nodes can be merged and we will\n\t // not be able to attach scope data to them, so we will wrap them in \n\t for (var i = 0, len = $compileNodes.length; i < len; i++) {\n\t var domNode = $compileNodes[i];\n\t\n\t if (domNode.nodeType === NODE_TYPE_TEXT && domNode.nodeValue.match(NOT_EMPTY) /* non-empty */) {\n\t jqLiteWrapNode(domNode, $compileNodes[i] = document.createElement('span'));\n\t }\n\t }\n\t\n\t var compositeLinkFn =\n\t compileNodes($compileNodes, transcludeFn, $compileNodes,\n\t maxPriority, ignoreDirective, previousCompileContext);\n\t compile.$$addScopeClass($compileNodes);\n\t var namespace = null;\n\t return function publicLinkFn(scope, cloneConnectFn, options) {\n\t assertArg(scope, 'scope');\n\t\n\t if (previousCompileContext && previousCompileContext.needsNewScope) {\n\t // A parent directive did a replace and a directive on this element asked\n\t // for transclusion, which caused us to lose a layer of element on which\n\t // we could hold the new transclusion scope, so we will create it manually\n\t // here.\n\t scope = scope.$parent.$new();\n\t }\n\t\n\t options = options || {};\n\t var parentBoundTranscludeFn = options.parentBoundTranscludeFn,\n\t transcludeControllers = options.transcludeControllers,\n\t futureParentElement = options.futureParentElement;\n\t\n\t // When `parentBoundTranscludeFn` is passed, it is a\n\t // `controllersBoundTransclude` function (it was previously passed\n\t // as `transclude` to directive.link) so we must unwrap it to get\n\t // its `boundTranscludeFn`\n\t if (parentBoundTranscludeFn && parentBoundTranscludeFn.$$boundTransclude) {\n\t parentBoundTranscludeFn = parentBoundTranscludeFn.$$boundTransclude;\n\t }\n\t\n\t if (!namespace) {\n\t namespace = detectNamespaceForChildElements(futureParentElement);\n\t }\n\t var $linkNode;\n\t if (namespace !== 'html') {\n\t // When using a directive with replace:true and templateUrl the $compileNodes\n\t // (or a child element inside of them)\n\t // might change, so we need to recreate the namespace adapted compileNodes\n\t // for call to the link function.\n\t // Note: This will already clone the nodes...\n\t $linkNode = jqLite(\n\t wrapTemplate(namespace, jqLite('
').append($compileNodes).html())\n\t );\n\t } else if (cloneConnectFn) {\n\t // important!!: we must call our jqLite.clone() since the jQuery one is trying to be smart\n\t // and sometimes changes the structure of the DOM.\n\t $linkNode = JQLitePrototype.clone.call($compileNodes);\n\t } else {\n\t $linkNode = $compileNodes;\n\t }\n\t\n\t if (transcludeControllers) {\n\t for (var controllerName in transcludeControllers) {\n\t $linkNode.data('$' + controllerName + 'Controller', transcludeControllers[controllerName].instance);\n\t }\n\t }\n\t\n\t compile.$$addScopeInfo($linkNode, scope);\n\t\n\t if (cloneConnectFn) cloneConnectFn($linkNode, scope);\n\t if (compositeLinkFn) compositeLinkFn(scope, $linkNode, $linkNode, parentBoundTranscludeFn);\n\t return $linkNode;\n\t };\n\t }\n\t\n\t function detectNamespaceForChildElements(parentElement) {\n\t // TODO: Make this detect MathML as well...\n\t var node = parentElement && parentElement[0];\n\t if (!node) {\n\t return 'html';\n\t } else {\n\t return nodeName_(node) !== 'foreignobject' && node.toString().match(/SVG/) ? 'svg' : 'html';\n\t }\n\t }\n\t\n\t /**\n\t * Compile function matches each node in nodeList against the directives. Once all directives\n\t * for a particular node are collected their compile functions are executed. The compile\n\t * functions return values - the linking functions - are combined into a composite linking\n\t * function, which is the a linking function for the node.\n\t *\n\t * @param {NodeList} nodeList an array of nodes or NodeList to compile\n\t * @param {function(angular.Scope, cloneAttachFn=)} transcludeFn A linking function, where the\n\t * scope argument is auto-generated to the new child of the transcluded parent scope.\n\t * @param {DOMElement=} $rootElement If the nodeList is the root of the compilation tree then\n\t * the rootElement must be set the jqLite collection of the compile root. This is\n\t * needed so that the jqLite collection items can be replaced with widgets.\n\t * @param {number=} maxPriority Max directive priority.\n\t * @returns {Function} A composite linking function of all of the matched directives or null.\n\t */\n\t function compileNodes(nodeList, transcludeFn, $rootElement, maxPriority, ignoreDirective,\n\t previousCompileContext) {\n\t var linkFns = [],\n\t attrs, directives, nodeLinkFn, childNodes, childLinkFn, linkFnFound, nodeLinkFnFound;\n\t\n\t for (var i = 0; i < nodeList.length; i++) {\n\t attrs = new Attributes();\n\t\n\t // we must always refer to nodeList[i] since the nodes can be replaced underneath us.\n\t directives = collectDirectives(nodeList[i], [], attrs, i === 0 ? maxPriority : undefined,\n\t ignoreDirective);\n\t\n\t nodeLinkFn = (directives.length)\n\t ? applyDirectivesToNode(directives, nodeList[i], attrs, transcludeFn, $rootElement,\n\t null, [], [], previousCompileContext)\n\t : null;\n\t\n\t if (nodeLinkFn && nodeLinkFn.scope) {\n\t compile.$$addScopeClass(attrs.$$element);\n\t }\n\t\n\t childLinkFn = (nodeLinkFn && nodeLinkFn.terminal ||\n\t !(childNodes = nodeList[i].childNodes) ||\n\t !childNodes.length)\n\t ? null\n\t : compileNodes(childNodes,\n\t nodeLinkFn ? (\n\t (nodeLinkFn.transcludeOnThisElement || !nodeLinkFn.templateOnThisElement)\n\t && nodeLinkFn.transclude) : transcludeFn);\n\t\n\t if (nodeLinkFn || childLinkFn) {\n\t linkFns.push(i, nodeLinkFn, childLinkFn);\n\t linkFnFound = true;\n\t nodeLinkFnFound = nodeLinkFnFound || nodeLinkFn;\n\t }\n\t\n\t //use the previous context only for the first element in the virtual group\n\t previousCompileContext = null;\n\t }\n\t\n\t // return a linking function if we have found anything, null otherwise\n\t return linkFnFound ? compositeLinkFn : null;\n\t\n\t function compositeLinkFn(scope, nodeList, $rootElement, parentBoundTranscludeFn) {\n\t var nodeLinkFn, childLinkFn, node, childScope, i, ii, idx, childBoundTranscludeFn;\n\t var stableNodeList;\n\t\n\t\n\t if (nodeLinkFnFound) {\n\t // copy nodeList so that if a nodeLinkFn removes or adds an element at this DOM level our\n\t // offsets don't get screwed up\n\t var nodeListLength = nodeList.length;\n\t stableNodeList = new Array(nodeListLength);\n\t\n\t // create a sparse array by only copying the elements which have a linkFn\n\t for (i = 0; i < linkFns.length; i+=3) {\n\t idx = linkFns[i];\n\t stableNodeList[idx] = nodeList[idx];\n\t }\n\t } else {\n\t stableNodeList = nodeList;\n\t }\n\t\n\t for (i = 0, ii = linkFns.length; i < ii;) {\n\t node = stableNodeList[linkFns[i++]];\n\t nodeLinkFn = linkFns[i++];\n\t childLinkFn = linkFns[i++];\n\t\n\t if (nodeLinkFn) {\n\t if (nodeLinkFn.scope) {\n\t childScope = scope.$new();\n\t compile.$$addScopeInfo(jqLite(node), childScope);\n\t } else {\n\t childScope = scope;\n\t }\n\t\n\t if (nodeLinkFn.transcludeOnThisElement) {\n\t childBoundTranscludeFn = createBoundTranscludeFn(\n\t scope, nodeLinkFn.transclude, parentBoundTranscludeFn);\n\t\n\t } else if (!nodeLinkFn.templateOnThisElement && parentBoundTranscludeFn) {\n\t childBoundTranscludeFn = parentBoundTranscludeFn;\n\t\n\t } else if (!parentBoundTranscludeFn && transcludeFn) {\n\t childBoundTranscludeFn = createBoundTranscludeFn(scope, transcludeFn);\n\t\n\t } else {\n\t childBoundTranscludeFn = null;\n\t }\n\t\n\t nodeLinkFn(childLinkFn, childScope, node, $rootElement, childBoundTranscludeFn);\n\t\n\t } else if (childLinkFn) {\n\t childLinkFn(scope, node.childNodes, undefined, parentBoundTranscludeFn);\n\t }\n\t }\n\t }\n\t }\n\t\n\t function createBoundTranscludeFn(scope, transcludeFn, previousBoundTranscludeFn) {\n\t\n\t var boundTranscludeFn = function(transcludedScope, cloneFn, controllers, futureParentElement, containingScope) {\n\t\n\t if (!transcludedScope) {\n\t transcludedScope = scope.$new(false, containingScope);\n\t transcludedScope.$$transcluded = true;\n\t }\n\t\n\t return transcludeFn(transcludedScope, cloneFn, {\n\t parentBoundTranscludeFn: previousBoundTranscludeFn,\n\t transcludeControllers: controllers,\n\t futureParentElement: futureParentElement\n\t });\n\t };\n\t\n\t return boundTranscludeFn;\n\t }\n\t\n\t /**\n\t * Looks for directives on the given node and adds them to the directive collection which is\n\t * sorted.\n\t *\n\t * @param node Node to search.\n\t * @param directives An array to which the directives are added to. This array is sorted before\n\t * the function returns.\n\t * @param attrs The shared attrs object which is used to populate the normalized attributes.\n\t * @param {number=} maxPriority Max directive priority.\n\t */\n\t function collectDirectives(node, directives, attrs, maxPriority, ignoreDirective) {\n\t var nodeType = node.nodeType,\n\t attrsMap = attrs.$attr,\n\t match,\n\t nodeName,\n\t className;\n\t\n\t switch (nodeType) {\n\t case NODE_TYPE_ELEMENT: /* Element */\n\t\n\t nodeName = nodeName_(node);\n\t\n\t // use the node name: \n\t addDirective(directives,\n\t directiveNormalize(nodeName), 'E', maxPriority, ignoreDirective);\n\t\n\t // iterate over the attributes\n\t for (var attr, name, nName, ngAttrName, value, isNgAttr, nAttrs = node.attributes,\n\t j = 0, jj = nAttrs && nAttrs.length; j < jj; j++) {\n\t var attrStartName = false;\n\t var attrEndName = false;\n\t\n\t attr = nAttrs[j];\n\t name = attr.name;\n\t value = trim(attr.value);\n\t\n\t // support ngAttr attribute binding\n\t ngAttrName = directiveNormalize(name);\n\t if (isNgAttr = NG_ATTR_BINDING.test(ngAttrName)) {\n\t name = name.replace(PREFIX_REGEXP, '')\n\t .substr(8).replace(/_(.)/g, function(match, letter) {\n\t return letter.toUpperCase();\n\t });\n\t }\n\t\n\t var multiElementMatch = ngAttrName.match(MULTI_ELEMENT_DIR_RE);\n\t if (multiElementMatch && directiveIsMultiElement(multiElementMatch[1])) {\n\t attrStartName = name;\n\t attrEndName = name.substr(0, name.length - 5) + 'end';\n\t name = name.substr(0, name.length - 6);\n\t }\n\t\n\t nName = directiveNormalize(name.toLowerCase());\n\t attrsMap[nName] = name;\n\t if (isNgAttr || !attrs.hasOwnProperty(nName)) {\n\t attrs[nName] = value;\n\t if (getBooleanAttrName(node, nName)) {\n\t attrs[nName] = true; // presence means true\n\t }\n\t }\n\t addAttrInterpolateDirective(node, directives, value, nName, isNgAttr);\n\t addDirective(directives, nName, 'A', maxPriority, ignoreDirective, attrStartName,\n\t attrEndName);\n\t }\n\t\n\t if (nodeName === 'input' && node.getAttribute('type') === 'hidden') {\n\t // Hidden input elements can have strange behaviour when navigating back to the page\n\t // This tells the browser not to try to cache and reinstate previous values\n\t node.setAttribute('autocomplete', 'off');\n\t }\n\t\n\t // use class as directive\n\t className = node.className;\n\t if (isObject(className)) {\n\t // Maybe SVGAnimatedString\n\t className = className.animVal;\n\t }\n\t if (isString(className) && className !== '') {\n\t while (match = CLASS_DIRECTIVE_REGEXP.exec(className)) {\n\t nName = directiveNormalize(match[2]);\n\t if (addDirective(directives, nName, 'C', maxPriority, ignoreDirective)) {\n\t attrs[nName] = trim(match[3]);\n\t }\n\t className = className.substr(match.index + match[0].length);\n\t }\n\t }\n\t break;\n\t case NODE_TYPE_TEXT: /* Text Node */\n\t if (msie === 11) {\n\t // Workaround for #11781\n\t while (node.parentNode && node.nextSibling && node.nextSibling.nodeType === NODE_TYPE_TEXT) {\n\t node.nodeValue = node.nodeValue + node.nextSibling.nodeValue;\n\t node.parentNode.removeChild(node.nextSibling);\n\t }\n\t }\n\t addTextInterpolateDirective(directives, node.nodeValue);\n\t break;\n\t case NODE_TYPE_COMMENT: /* Comment */\n\t try {\n\t match = COMMENT_DIRECTIVE_REGEXP.exec(node.nodeValue);\n\t if (match) {\n\t nName = directiveNormalize(match[1]);\n\t if (addDirective(directives, nName, 'M', maxPriority, ignoreDirective)) {\n\t attrs[nName] = trim(match[2]);\n\t }\n\t }\n\t } catch (e) {\n\t // turns out that under some circumstances IE9 throws errors when one attempts to read\n\t // comment's node value.\n\t // Just ignore it and continue. (Can't seem to reproduce in test case.)\n\t }\n\t break;\n\t }\n\t\n\t directives.sort(byPriority);\n\t return directives;\n\t }\n\t\n\t /**\n\t * Given a node with an directive-start it collects all of the siblings until it finds\n\t * directive-end.\n\t * @param node\n\t * @param attrStart\n\t * @param attrEnd\n\t * @returns {*}\n\t */\n\t function groupScan(node, attrStart, attrEnd) {\n\t var nodes = [];\n\t var depth = 0;\n\t if (attrStart && node.hasAttribute && node.hasAttribute(attrStart)) {\n\t do {\n\t if (!node) {\n\t throw $compileMinErr('uterdir',\n\t \"Unterminated attribute, found '{0}' but no matching '{1}' found.\",\n\t attrStart, attrEnd);\n\t }\n\t if (node.nodeType == NODE_TYPE_ELEMENT) {\n\t if (node.hasAttribute(attrStart)) depth++;\n\t if (node.hasAttribute(attrEnd)) depth--;\n\t }\n\t nodes.push(node);\n\t node = node.nextSibling;\n\t } while (depth > 0);\n\t } else {\n\t nodes.push(node);\n\t }\n\t\n\t return jqLite(nodes);\n\t }\n\t\n\t /**\n\t * Wrapper for linking function which converts normal linking function into a grouped\n\t * linking function.\n\t * @param linkFn\n\t * @param attrStart\n\t * @param attrEnd\n\t * @returns {Function}\n\t */\n\t function groupElementsLinkFnWrapper(linkFn, attrStart, attrEnd) {\n\t return function(scope, element, attrs, controllers, transcludeFn) {\n\t element = groupScan(element[0], attrStart, attrEnd);\n\t return linkFn(scope, element, attrs, controllers, transcludeFn);\n\t };\n\t }\n\t\n\t /**\n\t * Once the directives have been collected, their compile functions are executed. This method\n\t * is responsible for inlining directive templates as well as terminating the application\n\t * of the directives if the terminal directive has been reached.\n\t *\n\t * @param {Array} directives Array of collected directives to execute their compile function.\n\t * this needs to be pre-sorted by priority order.\n\t * @param {Node} compileNode The raw DOM node to apply the compile functions to\n\t * @param {Object} templateAttrs The shared attribute function\n\t * @param {function(angular.Scope, cloneAttachFn=)} transcludeFn A linking function, where the\n\t * scope argument is auto-generated to the new\n\t * child of the transcluded parent scope.\n\t * @param {JQLite} jqCollection If we are working on the root of the compile tree then this\n\t * argument has the root jqLite array so that we can replace nodes\n\t * on it.\n\t * @param {Object=} originalReplaceDirective An optional directive that will be ignored when\n\t * compiling the transclusion.\n\t * @param {Array.} preLinkFns\n\t * @param {Array.} postLinkFns\n\t * @param {Object} previousCompileContext Context used for previous compilation of the current\n\t * node\n\t * @returns {Function} linkFn\n\t */\n\t function applyDirectivesToNode(directives, compileNode, templateAttrs, transcludeFn,\n\t jqCollection, originalReplaceDirective, preLinkFns, postLinkFns,\n\t previousCompileContext) {\n\t previousCompileContext = previousCompileContext || {};\n\t\n\t var terminalPriority = -Number.MAX_VALUE,\n\t newScopeDirective = previousCompileContext.newScopeDirective,\n\t controllerDirectives = previousCompileContext.controllerDirectives,\n\t newIsolateScopeDirective = previousCompileContext.newIsolateScopeDirective,\n\t templateDirective = previousCompileContext.templateDirective,\n\t nonTlbTranscludeDirective = previousCompileContext.nonTlbTranscludeDirective,\n\t hasTranscludeDirective = false,\n\t hasTemplate = false,\n\t hasElementTranscludeDirective = previousCompileContext.hasElementTranscludeDirective,\n\t $compileNode = templateAttrs.$$element = jqLite(compileNode),\n\t directive,\n\t directiveName,\n\t $template,\n\t replaceDirective = originalReplaceDirective,\n\t childTranscludeFn = transcludeFn,\n\t linkFn,\n\t directiveValue;\n\t\n\t // executes all directives on the current element\n\t for (var i = 0, ii = directives.length; i < ii; i++) {\n\t directive = directives[i];\n\t var attrStart = directive.$$start;\n\t var attrEnd = directive.$$end;\n\t\n\t // collect multiblock sections\n\t if (attrStart) {\n\t $compileNode = groupScan(compileNode, attrStart, attrEnd);\n\t }\n\t $template = undefined;\n\t\n\t if (terminalPriority > directive.priority) {\n\t break; // prevent further processing of directives\n\t }\n\t\n\t if (directiveValue = directive.scope) {\n\t\n\t // skip the check for directives with async templates, we'll check the derived sync\n\t // directive when the template arrives\n\t if (!directive.templateUrl) {\n\t if (isObject(directiveValue)) {\n\t // This directive is trying to add an isolated scope.\n\t // Check that there is no scope of any kind already\n\t assertNoDuplicate('new/isolated scope', newIsolateScopeDirective || newScopeDirective,\n\t directive, $compileNode);\n\t newIsolateScopeDirective = directive;\n\t } else {\n\t // This directive is trying to add a child scope.\n\t // Check that there is no isolated scope already\n\t assertNoDuplicate('new/isolated scope', newIsolateScopeDirective, directive,\n\t $compileNode);\n\t }\n\t }\n\t\n\t newScopeDirective = newScopeDirective || directive;\n\t }\n\t\n\t directiveName = directive.name;\n\t\n\t if (!directive.templateUrl && directive.controller) {\n\t directiveValue = directive.controller;\n\t controllerDirectives = controllerDirectives || createMap();\n\t assertNoDuplicate(\"'\" + directiveName + \"' controller\",\n\t controllerDirectives[directiveName], directive, $compileNode);\n\t controllerDirectives[directiveName] = directive;\n\t }\n\t\n\t if (directiveValue = directive.transclude) {\n\t hasTranscludeDirective = true;\n\t\n\t // Special case ngIf and ngRepeat so that we don't complain about duplicate transclusion.\n\t // This option should only be used by directives that know how to safely handle element transclusion,\n\t // where the transcluded nodes are added or replaced after linking.\n\t if (!directive.$$tlb) {\n\t assertNoDuplicate('transclusion', nonTlbTranscludeDirective, directive, $compileNode);\n\t nonTlbTranscludeDirective = directive;\n\t }\n\t\n\t if (directiveValue == 'element') {\n\t hasElementTranscludeDirective = true;\n\t terminalPriority = directive.priority;\n\t $template = $compileNode;\n\t $compileNode = templateAttrs.$$element =\n\t jqLite(document.createComment(' ' + directiveName + ': ' +\n\t templateAttrs[directiveName] + ' '));\n\t compileNode = $compileNode[0];\n\t replaceWith(jqCollection, sliceArgs($template), compileNode);\n\t\n\t childTranscludeFn = compile($template, transcludeFn, terminalPriority,\n\t replaceDirective && replaceDirective.name, {\n\t // Don't pass in:\n\t // - controllerDirectives - otherwise we'll create duplicates controllers\n\t // - newIsolateScopeDirective or templateDirective - combining templates with\n\t // element transclusion doesn't make sense.\n\t //\n\t // We need only nonTlbTranscludeDirective so that we prevent putting transclusion\n\t // on the same element more than once.\n\t nonTlbTranscludeDirective: nonTlbTranscludeDirective\n\t });\n\t } else {\n\t $template = jqLite(jqLiteClone(compileNode)).contents();\n\t $compileNode.empty(); // clear contents\n\t childTranscludeFn = compile($template, transcludeFn, undefined,\n\t undefined, { needsNewScope: directive.$$isolateScope || directive.$$newScope});\n\t }\n\t }\n\t\n\t if (directive.template) {\n\t hasTemplate = true;\n\t assertNoDuplicate('template', templateDirective, directive, $compileNode);\n\t templateDirective = directive;\n\t\n\t directiveValue = (isFunction(directive.template))\n\t ? directive.template($compileNode, templateAttrs)\n\t : directive.template;\n\t\n\t directiveValue = denormalizeTemplate(directiveValue);\n\t\n\t if (directive.replace) {\n\t replaceDirective = directive;\n\t if (jqLiteIsTextNode(directiveValue)) {\n\t $template = [];\n\t } else {\n\t $template = removeComments(wrapTemplate(directive.templateNamespace, trim(directiveValue)));\n\t }\n\t compileNode = $template[0];\n\t\n\t if ($template.length != 1 || compileNode.nodeType !== NODE_TYPE_ELEMENT) {\n\t throw $compileMinErr('tplrt',\n\t \"Template for directive '{0}' must have exactly one root element. {1}\",\n\t directiveName, '');\n\t }\n\t\n\t replaceWith(jqCollection, $compileNode, compileNode);\n\t\n\t var newTemplateAttrs = {$attr: {}};\n\t\n\t // combine directives from the original node and from the template:\n\t // - take the array of directives for this element\n\t // - split it into two parts, those that already applied (processed) and those that weren't (unprocessed)\n\t // - collect directives from the template and sort them by priority\n\t // - combine directives as: processed + template + unprocessed\n\t var templateDirectives = collectDirectives(compileNode, [], newTemplateAttrs);\n\t var unprocessedDirectives = directives.splice(i + 1, directives.length - (i + 1));\n\t\n\t if (newIsolateScopeDirective || newScopeDirective) {\n\t // The original directive caused the current element to be replaced but this element\n\t // also needs to have a new scope, so we need to tell the template directives\n\t // that they would need to get their scope from further up, if they require transclusion\n\t markDirectiveScope(templateDirectives, newIsolateScopeDirective, newScopeDirective);\n\t }\n\t directives = directives.concat(templateDirectives).concat(unprocessedDirectives);\n\t mergeTemplateAttributes(templateAttrs, newTemplateAttrs);\n\t\n\t ii = directives.length;\n\t } else {\n\t $compileNode.html(directiveValue);\n\t }\n\t }\n\t\n\t if (directive.templateUrl) {\n\t hasTemplate = true;\n\t assertNoDuplicate('template', templateDirective, directive, $compileNode);\n\t templateDirective = directive;\n\t\n\t if (directive.replace) {\n\t replaceDirective = directive;\n\t }\n\t\n\t nodeLinkFn = compileTemplateUrl(directives.splice(i, directives.length - i), $compileNode,\n\t templateAttrs, jqCollection, hasTranscludeDirective && childTranscludeFn, preLinkFns, postLinkFns, {\n\t controllerDirectives: controllerDirectives,\n\t newScopeDirective: (newScopeDirective !== directive) && newScopeDirective,\n\t newIsolateScopeDirective: newIsolateScopeDirective,\n\t templateDirective: templateDirective,\n\t nonTlbTranscludeDirective: nonTlbTranscludeDirective\n\t });\n\t ii = directives.length;\n\t } else if (directive.compile) {\n\t try {\n\t linkFn = directive.compile($compileNode, templateAttrs, childTranscludeFn);\n\t if (isFunction(linkFn)) {\n\t addLinkFns(null, linkFn, attrStart, attrEnd);\n\t } else if (linkFn) {\n\t addLinkFns(linkFn.pre, linkFn.post, attrStart, attrEnd);\n\t }\n\t } catch (e) {\n\t $exceptionHandler(e, startingTag($compileNode));\n\t }\n\t }\n\t\n\t if (directive.terminal) {\n\t nodeLinkFn.terminal = true;\n\t terminalPriority = Math.max(terminalPriority, directive.priority);\n\t }\n\t\n\t }\n\t\n\t nodeLinkFn.scope = newScopeDirective && newScopeDirective.scope === true;\n\t nodeLinkFn.transcludeOnThisElement = hasTranscludeDirective;\n\t nodeLinkFn.templateOnThisElement = hasTemplate;\n\t nodeLinkFn.transclude = childTranscludeFn;\n\t\n\t previousCompileContext.hasElementTranscludeDirective = hasElementTranscludeDirective;\n\t\n\t // might be normal or delayed nodeLinkFn depending on if templateUrl is present\n\t return nodeLinkFn;\n\t\n\t ////////////////////\n\t\n\t function addLinkFns(pre, post, attrStart, attrEnd) {\n\t if (pre) {\n\t if (attrStart) pre = groupElementsLinkFnWrapper(pre, attrStart, attrEnd);\n\t pre.require = directive.require;\n\t pre.directiveName = directiveName;\n\t if (newIsolateScopeDirective === directive || directive.$$isolateScope) {\n\t pre = cloneAndAnnotateFn(pre, {isolateScope: true});\n\t }\n\t preLinkFns.push(pre);\n\t }\n\t if (post) {\n\t if (attrStart) post = groupElementsLinkFnWrapper(post, attrStart, attrEnd);\n\t post.require = directive.require;\n\t post.directiveName = directiveName;\n\t if (newIsolateScopeDirective === directive || directive.$$isolateScope) {\n\t post = cloneAndAnnotateFn(post, {isolateScope: true});\n\t }\n\t postLinkFns.push(post);\n\t }\n\t }\n\t\n\t\n\t function getControllers(directiveName, require, $element, elementControllers) {\n\t var value;\n\t\n\t if (isString(require)) {\n\t var match = require.match(REQUIRE_PREFIX_REGEXP);\n\t var name = require.substring(match[0].length);\n\t var inheritType = match[1] || match[3];\n\t var optional = match[2] === '?';\n\t\n\t //If only parents then start at the parent element\n\t if (inheritType === '^^') {\n\t $element = $element.parent();\n\t //Otherwise attempt getting the controller from elementControllers in case\n\t //the element is transcluded (and has no data) and to avoid .data if possible\n\t } else {\n\t value = elementControllers && elementControllers[name];\n\t value = value && value.instance;\n\t }\n\t\n\t if (!value) {\n\t var dataName = '$' + name + 'Controller';\n\t value = inheritType ? $element.inheritedData(dataName) : $element.data(dataName);\n\t }\n\t\n\t if (!value && !optional) {\n\t throw $compileMinErr('ctreq',\n\t \"Controller '{0}', required by directive '{1}', can't be found!\",\n\t name, directiveName);\n\t }\n\t } else if (isArray(require)) {\n\t value = [];\n\t for (var i = 0, ii = require.length; i < ii; i++) {\n\t value[i] = getControllers(directiveName, require[i], $element, elementControllers);\n\t }\n\t }\n\t\n\t return value || null;\n\t }\n\t\n\t function setupControllers($element, attrs, transcludeFn, controllerDirectives, isolateScope, scope) {\n\t var elementControllers = createMap();\n\t for (var controllerKey in controllerDirectives) {\n\t var directive = controllerDirectives[controllerKey];\n\t var locals = {\n\t $scope: directive === newIsolateScopeDirective || directive.$$isolateScope ? isolateScope : scope,\n\t $element: $element,\n\t $attrs: attrs,\n\t $transclude: transcludeFn\n\t };\n\t\n\t var controller = directive.controller;\n\t if (controller == '@') {\n\t controller = attrs[directive.name];\n\t }\n\t\n\t var controllerInstance = $controller(controller, locals, true, directive.controllerAs);\n\t\n\t // For directives with element transclusion the element is a comment.\n\t // In this case .data will not attach any data.\n\t // Instead, we save the controllers for the element in a local hash and attach to .data\n\t // later, once we have the actual element.\n\t elementControllers[directive.name] = controllerInstance;\n\t $element.data('$' + directive.name + 'Controller', controllerInstance.instance);\n\t }\n\t return elementControllers;\n\t }\n\t\n\t function nodeLinkFn(childLinkFn, scope, linkNode, $rootElement, boundTranscludeFn) {\n\t var linkFn, isolateScope, controllerScope, elementControllers, transcludeFn, $element,\n\t attrs, removeScopeBindingWatches, removeControllerBindingWatches;\n\t\n\t if (compileNode === linkNode) {\n\t attrs = templateAttrs;\n\t $element = templateAttrs.$$element;\n\t } else {\n\t $element = jqLite(linkNode);\n\t attrs = new Attributes($element, templateAttrs);\n\t }\n\t\n\t controllerScope = scope;\n\t if (newIsolateScopeDirective) {\n\t isolateScope = scope.$new(true);\n\t } else if (newScopeDirective) {\n\t controllerScope = scope.$parent;\n\t }\n\t\n\t if (boundTranscludeFn) {\n\t // track `boundTranscludeFn` so it can be unwrapped if `transcludeFn`\n\t // is later passed as `parentBoundTranscludeFn` to `publicLinkFn`\n\t transcludeFn = controllersBoundTransclude;\n\t transcludeFn.$$boundTransclude = boundTranscludeFn;\n\t }\n\t\n\t if (controllerDirectives) {\n\t elementControllers = setupControllers($element, attrs, transcludeFn, controllerDirectives, isolateScope, scope);\n\t }\n\t\n\t if (newIsolateScopeDirective) {\n\t // Initialize isolate scope bindings for new isolate scope directive.\n\t compile.$$addScopeInfo($element, isolateScope, true, !(templateDirective && (templateDirective === newIsolateScopeDirective ||\n\t templateDirective === newIsolateScopeDirective.$$originalDirective)));\n\t compile.$$addScopeClass($element, true);\n\t isolateScope.$$isolateBindings =\n\t newIsolateScopeDirective.$$isolateBindings;\n\t removeScopeBindingWatches = initializeDirectiveBindings(scope, attrs, isolateScope,\n\t isolateScope.$$isolateBindings,\n\t newIsolateScopeDirective);\n\t if (removeScopeBindingWatches) {\n\t isolateScope.$on('$destroy', removeScopeBindingWatches);\n\t }\n\t }\n\t\n\t // Initialize bindToController bindings\n\t for (var name in elementControllers) {\n\t var controllerDirective = controllerDirectives[name];\n\t var controller = elementControllers[name];\n\t var bindings = controllerDirective.$$bindings.bindToController;\n\t\n\t if (controller.identifier && bindings) {\n\t removeControllerBindingWatches =\n\t initializeDirectiveBindings(controllerScope, attrs, controller.instance, bindings, controllerDirective);\n\t }\n\t\n\t var controllerResult = controller();\n\t if (controllerResult !== controller.instance) {\n\t // If the controller constructor has a return value, overwrite the instance\n\t // from setupControllers\n\t controller.instance = controllerResult;\n\t $element.data('$' + controllerDirective.name + 'Controller', controllerResult);\n\t removeControllerBindingWatches && removeControllerBindingWatches();\n\t removeControllerBindingWatches =\n\t initializeDirectiveBindings(controllerScope, attrs, controller.instance, bindings, controllerDirective);\n\t }\n\t }\n\t\n\t // PRELINKING\n\t for (i = 0, ii = preLinkFns.length; i < ii; i++) {\n\t linkFn = preLinkFns[i];\n\t invokeLinkFn(linkFn,\n\t linkFn.isolateScope ? isolateScope : scope,\n\t $element,\n\t attrs,\n\t linkFn.require && getControllers(linkFn.directiveName, linkFn.require, $element, elementControllers),\n\t transcludeFn\n\t );\n\t }\n\t\n\t // RECURSION\n\t // We only pass the isolate scope, if the isolate directive has a template,\n\t // otherwise the child elements do not belong to the isolate directive.\n\t var scopeToChild = scope;\n\t if (newIsolateScopeDirective && (newIsolateScopeDirective.template || newIsolateScopeDirective.templateUrl === null)) {\n\t scopeToChild = isolateScope;\n\t }\n\t childLinkFn && childLinkFn(scopeToChild, linkNode.childNodes, undefined, boundTranscludeFn);\n\t\n\t // POSTLINKING\n\t for (i = postLinkFns.length - 1; i >= 0; i--) {\n\t linkFn = postLinkFns[i];\n\t invokeLinkFn(linkFn,\n\t linkFn.isolateScope ? isolateScope : scope,\n\t $element,\n\t attrs,\n\t linkFn.require && getControllers(linkFn.directiveName, linkFn.require, $element, elementControllers),\n\t transcludeFn\n\t );\n\t }\n\t\n\t // This is the function that is injected as `$transclude`.\n\t // Note: all arguments are optional!\n\t function controllersBoundTransclude(scope, cloneAttachFn, futureParentElement) {\n\t var transcludeControllers;\n\t\n\t // No scope passed in:\n\t if (!isScope(scope)) {\n\t futureParentElement = cloneAttachFn;\n\t cloneAttachFn = scope;\n\t scope = undefined;\n\t }\n\t\n\t if (hasElementTranscludeDirective) {\n\t transcludeControllers = elementControllers;\n\t }\n\t if (!futureParentElement) {\n\t futureParentElement = hasElementTranscludeDirective ? $element.parent() : $element;\n\t }\n\t return boundTranscludeFn(scope, cloneAttachFn, transcludeControllers, futureParentElement, scopeToChild);\n\t }\n\t }\n\t }\n\t\n\t // Depending upon the context in which a directive finds itself it might need to have a new isolated\n\t // or child scope created. For instance:\n\t // * if the directive has been pulled into a template because another directive with a higher priority\n\t // asked for element transclusion\n\t // * if the directive itself asks for transclusion but it is at the root of a template and the original\n\t // element was replaced. See https://github.com/angular/angular.js/issues/12936\n\t function markDirectiveScope(directives, isolateScope, newScope) {\n\t for (var j = 0, jj = directives.length; j < jj; j++) {\n\t directives[j] = inherit(directives[j], {$$isolateScope: isolateScope, $$newScope: newScope});\n\t }\n\t }\n\t\n\t /**\n\t * looks up the directive and decorates it with exception handling and proper parameters. We\n\t * call this the boundDirective.\n\t *\n\t * @param {string} name name of the directive to look up.\n\t * @param {string} location The directive must be found in specific format.\n\t * String containing any of theses characters:\n\t *\n\t * * `E`: element name\n\t * * `A': attribute\n\t * * `C`: class\n\t * * `M`: comment\n\t * @returns {boolean} true if directive was added.\n\t */\n\t function addDirective(tDirectives, name, location, maxPriority, ignoreDirective, startAttrName,\n\t endAttrName) {\n\t if (name === ignoreDirective) return null;\n\t var match = null;\n\t if (hasDirectives.hasOwnProperty(name)) {\n\t for (var directive, directives = $injector.get(name + Suffix),\n\t i = 0, ii = directives.length; i < ii; i++) {\n\t try {\n\t directive = directives[i];\n\t if ((isUndefined(maxPriority) || maxPriority > directive.priority) &&\n\t directive.restrict.indexOf(location) != -1) {\n\t if (startAttrName) {\n\t directive = inherit(directive, {$$start: startAttrName, $$end: endAttrName});\n\t }\n\t if (!directive.$$bindings) {\n\t var bindings = directive.$$bindings =\n\t parseDirectiveBindings(directive, directive.name);\n\t if (isObject(bindings.isolateScope)) {\n\t directive.$$isolateBindings = bindings.isolateScope;\n\t }\n\t }\n\t tDirectives.push(directive);\n\t match = directive;\n\t }\n\t } catch (e) { $exceptionHandler(e); }\n\t }\n\t }\n\t return match;\n\t }\n\t\n\t\n\t /**\n\t * looks up the directive and returns true if it is a multi-element directive,\n\t * and therefore requires DOM nodes between -start and -end markers to be grouped\n\t * together.\n\t *\n\t * @param {string} name name of the directive to look up.\n\t * @returns true if directive was registered as multi-element.\n\t */\n\t function directiveIsMultiElement(name) {\n\t if (hasDirectives.hasOwnProperty(name)) {\n\t for (var directive, directives = $injector.get(name + Suffix),\n\t i = 0, ii = directives.length; i < ii; i++) {\n\t directive = directives[i];\n\t if (directive.multiElement) {\n\t return true;\n\t }\n\t }\n\t }\n\t return false;\n\t }\n\t\n\t /**\n\t * When the element is replaced with HTML template then the new attributes\n\t * on the template need to be merged with the existing attributes in the DOM.\n\t * The desired effect is to have both of the attributes present.\n\t *\n\t * @param {object} dst destination attributes (original DOM)\n\t * @param {object} src source attributes (from the directive template)\n\t */\n\t function mergeTemplateAttributes(dst, src) {\n\t var srcAttr = src.$attr,\n\t dstAttr = dst.$attr,\n\t $element = dst.$$element;\n\t\n\t // reapply the old attributes to the new element\n\t forEach(dst, function(value, key) {\n\t if (key.charAt(0) != '$') {\n\t if (src[key] && src[key] !== value) {\n\t value += (key === 'style' ? ';' : ' ') + src[key];\n\t }\n\t dst.$set(key, value, true, srcAttr[key]);\n\t }\n\t });\n\t\n\t // copy the new attributes on the old attrs object\n\t forEach(src, function(value, key) {\n\t if (key == 'class') {\n\t safeAddClass($element, value);\n\t dst['class'] = (dst['class'] ? dst['class'] + ' ' : '') + value;\n\t } else if (key == 'style') {\n\t $element.attr('style', $element.attr('style') + ';' + value);\n\t dst['style'] = (dst['style'] ? dst['style'] + ';' : '') + value;\n\t // `dst` will never contain hasOwnProperty as DOM parser won't let it.\n\t // You will get an \"InvalidCharacterError: DOM Exception 5\" error if you\n\t // have an attribute like \"has-own-property\" or \"data-has-own-property\", etc.\n\t } else if (key.charAt(0) != '$' && !dst.hasOwnProperty(key)) {\n\t dst[key] = value;\n\t dstAttr[key] = srcAttr[key];\n\t }\n\t });\n\t }\n\t\n\t\n\t function compileTemplateUrl(directives, $compileNode, tAttrs,\n\t $rootElement, childTranscludeFn, preLinkFns, postLinkFns, previousCompileContext) {\n\t var linkQueue = [],\n\t afterTemplateNodeLinkFn,\n\t afterTemplateChildLinkFn,\n\t beforeTemplateCompileNode = $compileNode[0],\n\t origAsyncDirective = directives.shift(),\n\t derivedSyncDirective = inherit(origAsyncDirective, {\n\t templateUrl: null, transclude: null, replace: null, $$originalDirective: origAsyncDirective\n\t }),\n\t templateUrl = (isFunction(origAsyncDirective.templateUrl))\n\t ? origAsyncDirective.templateUrl($compileNode, tAttrs)\n\t : origAsyncDirective.templateUrl,\n\t templateNamespace = origAsyncDirective.templateNamespace;\n\t\n\t $compileNode.empty();\n\t\n\t $templateRequest(templateUrl)\n\t .then(function(content) {\n\t var compileNode, tempTemplateAttrs, $template, childBoundTranscludeFn;\n\t\n\t content = denormalizeTemplate(content);\n\t\n\t if (origAsyncDirective.replace) {\n\t if (jqLiteIsTextNode(content)) {\n\t $template = [];\n\t } else {\n\t $template = removeComments(wrapTemplate(templateNamespace, trim(content)));\n\t }\n\t compileNode = $template[0];\n\t\n\t if ($template.length != 1 || compileNode.nodeType !== NODE_TYPE_ELEMENT) {\n\t throw $compileMinErr('tplrt',\n\t \"Template for directive '{0}' must have exactly one root element. {1}\",\n\t origAsyncDirective.name, templateUrl);\n\t }\n\t\n\t tempTemplateAttrs = {$attr: {}};\n\t replaceWith($rootElement, $compileNode, compileNode);\n\t var templateDirectives = collectDirectives(compileNode, [], tempTemplateAttrs);\n\t\n\t if (isObject(origAsyncDirective.scope)) {\n\t // the original directive that caused the template to be loaded async required\n\t // an isolate scope\n\t markDirectiveScope(templateDirectives, true);\n\t }\n\t directives = templateDirectives.concat(directives);\n\t mergeTemplateAttributes(tAttrs, tempTemplateAttrs);\n\t } else {\n\t compileNode = beforeTemplateCompileNode;\n\t $compileNode.html(content);\n\t }\n\t\n\t directives.unshift(derivedSyncDirective);\n\t\n\t afterTemplateNodeLinkFn = applyDirectivesToNode(directives, compileNode, tAttrs,\n\t childTranscludeFn, $compileNode, origAsyncDirective, preLinkFns, postLinkFns,\n\t previousCompileContext);\n\t forEach($rootElement, function(node, i) {\n\t if (node == compileNode) {\n\t $rootElement[i] = $compileNode[0];\n\t }\n\t });\n\t afterTemplateChildLinkFn = compileNodes($compileNode[0].childNodes, childTranscludeFn);\n\t\n\t while (linkQueue.length) {\n\t var scope = linkQueue.shift(),\n\t beforeTemplateLinkNode = linkQueue.shift(),\n\t linkRootElement = linkQueue.shift(),\n\t boundTranscludeFn = linkQueue.shift(),\n\t linkNode = $compileNode[0];\n\t\n\t if (scope.$$destroyed) continue;\n\t\n\t if (beforeTemplateLinkNode !== beforeTemplateCompileNode) {\n\t var oldClasses = beforeTemplateLinkNode.className;\n\t\n\t if (!(previousCompileContext.hasElementTranscludeDirective &&\n\t origAsyncDirective.replace)) {\n\t // it was cloned therefore we have to clone as well.\n\t linkNode = jqLiteClone(compileNode);\n\t }\n\t replaceWith(linkRootElement, jqLite(beforeTemplateLinkNode), linkNode);\n\t\n\t // Copy in CSS classes from original node\n\t safeAddClass(jqLite(linkNode), oldClasses);\n\t }\n\t if (afterTemplateNodeLinkFn.transcludeOnThisElement) {\n\t childBoundTranscludeFn = createBoundTranscludeFn(scope, afterTemplateNodeLinkFn.transclude, boundTranscludeFn);\n\t } else {\n\t childBoundTranscludeFn = boundTranscludeFn;\n\t }\n\t afterTemplateNodeLinkFn(afterTemplateChildLinkFn, scope, linkNode, $rootElement,\n\t childBoundTranscludeFn);\n\t }\n\t linkQueue = null;\n\t });\n\t\n\t return function delayedNodeLinkFn(ignoreChildLinkFn, scope, node, rootElement, boundTranscludeFn) {\n\t var childBoundTranscludeFn = boundTranscludeFn;\n\t if (scope.$$destroyed) return;\n\t if (linkQueue) {\n\t linkQueue.push(scope,\n\t node,\n\t rootElement,\n\t childBoundTranscludeFn);\n\t } else {\n\t if (afterTemplateNodeLinkFn.transcludeOnThisElement) {\n\t childBoundTranscludeFn = createBoundTranscludeFn(scope, afterTemplateNodeLinkFn.transclude, boundTranscludeFn);\n\t }\n\t afterTemplateNodeLinkFn(afterTemplateChildLinkFn, scope, node, rootElement, childBoundTranscludeFn);\n\t }\n\t };\n\t }\n\t\n\t\n\t /**\n\t * Sorting function for bound directives.\n\t */\n\t function byPriority(a, b) {\n\t var diff = b.priority - a.priority;\n\t if (diff !== 0) return diff;\n\t if (a.name !== b.name) return (a.name < b.name) ? -1 : 1;\n\t return a.index - b.index;\n\t }\n\t\n\t function assertNoDuplicate(what, previousDirective, directive, element) {\n\t\n\t function wrapModuleNameIfDefined(moduleName) {\n\t return moduleName ?\n\t (' (module: ' + moduleName + ')') :\n\t '';\n\t }\n\t\n\t if (previousDirective) {\n\t throw $compileMinErr('multidir', 'Multiple directives [{0}{1}, {2}{3}] asking for {4} on: {5}',\n\t previousDirective.name, wrapModuleNameIfDefined(previousDirective.$$moduleName),\n\t directive.name, wrapModuleNameIfDefined(directive.$$moduleName), what, startingTag(element));\n\t }\n\t }\n\t\n\t\n\t function addTextInterpolateDirective(directives, text) {\n\t var interpolateFn = $interpolate(text, true);\n\t if (interpolateFn) {\n\t directives.push({\n\t priority: 0,\n\t compile: function textInterpolateCompileFn(templateNode) {\n\t var templateNodeParent = templateNode.parent(),\n\t hasCompileParent = !!templateNodeParent.length;\n\t\n\t // When transcluding a template that has bindings in the root\n\t // we don't have a parent and thus need to add the class during linking fn.\n\t if (hasCompileParent) compile.$$addBindingClass(templateNodeParent);\n\t\n\t return function textInterpolateLinkFn(scope, node) {\n\t var parent = node.parent();\n\t if (!hasCompileParent) compile.$$addBindingClass(parent);\n\t compile.$$addBindingInfo(parent, interpolateFn.expressions);\n\t scope.$watch(interpolateFn, function interpolateFnWatchAction(value) {\n\t node[0].nodeValue = value;\n\t });\n\t };\n\t }\n\t });\n\t }\n\t }\n\t\n\t\n\t function wrapTemplate(type, template) {\n\t type = lowercase(type || 'html');\n\t switch (type) {\n\t case 'svg':\n\t case 'math':\n\t var wrapper = document.createElement('div');\n\t wrapper.innerHTML = '<' + type + '>' + template + '';\n\t return wrapper.childNodes[0].childNodes;\n\t default:\n\t return template;\n\t }\n\t }\n\t\n\t\n\t function getTrustedContext(node, attrNormalizedName) {\n\t if (attrNormalizedName == \"srcdoc\") {\n\t return $sce.HTML;\n\t }\n\t var tag = nodeName_(node);\n\t // maction[xlink:href] can source SVG. It's not limited to .\n\t if (attrNormalizedName == \"xlinkHref\" ||\n\t (tag == \"form\" && attrNormalizedName == \"action\") ||\n\t (tag != \"img\" && (attrNormalizedName == \"src\" ||\n\t attrNormalizedName == \"ngSrc\"))) {\n\t return $sce.RESOURCE_URL;\n\t }\n\t }\n\t\n\t\n\t function addAttrInterpolateDirective(node, directives, value, name, allOrNothing) {\n\t var trustedContext = getTrustedContext(node, name);\n\t allOrNothing = ALL_OR_NOTHING_ATTRS[name] || allOrNothing;\n\t\n\t var interpolateFn = $interpolate(value, true, trustedContext, allOrNothing);\n\t\n\t // no interpolation found -> ignore\n\t if (!interpolateFn) return;\n\t\n\t\n\t if (name === \"multiple\" && nodeName_(node) === \"select\") {\n\t throw $compileMinErr(\"selmulti\",\n\t \"Binding to the 'multiple' attribute is not supported. Element: {0}\",\n\t startingTag(node));\n\t }\n\t\n\t directives.push({\n\t priority: 100,\n\t compile: function() {\n\t return {\n\t pre: function attrInterpolatePreLinkFn(scope, element, attr) {\n\t var $$observers = (attr.$$observers || (attr.$$observers = createMap()));\n\t\n\t if (EVENT_HANDLER_ATTR_REGEXP.test(name)) {\n\t throw $compileMinErr('nodomevents',\n\t \"Interpolations for HTML DOM event attributes are disallowed. Please use the \" +\n\t \"ng- versions (such as ng-click instead of onclick) instead.\");\n\t }\n\t\n\t // If the attribute has changed since last $interpolate()ed\n\t var newValue = attr[name];\n\t if (newValue !== value) {\n\t // we need to interpolate again since the attribute value has been updated\n\t // (e.g. by another directive's compile function)\n\t // ensure unset/empty values make interpolateFn falsy\n\t interpolateFn = newValue && $interpolate(newValue, true, trustedContext, allOrNothing);\n\t value = newValue;\n\t }\n\t\n\t // if attribute was updated so that there is no interpolation going on we don't want to\n\t // register any observers\n\t if (!interpolateFn) return;\n\t\n\t // initialize attr object so that it's ready in case we need the value for isolate\n\t // scope initialization, otherwise the value would not be available from isolate\n\t // directive's linking fn during linking phase\n\t attr[name] = interpolateFn(scope);\n\t\n\t ($$observers[name] || ($$observers[name] = [])).$$inter = true;\n\t (attr.$$observers && attr.$$observers[name].$$scope || scope).\n\t $watch(interpolateFn, function interpolateFnWatchAction(newValue, oldValue) {\n\t //special case for class attribute addition + removal\n\t //so that class changes can tap into the animation\n\t //hooks provided by the $animate service. Be sure to\n\t //skip animations when the first digest occurs (when\n\t //both the new and the old values are the same) since\n\t //the CSS classes are the non-interpolated values\n\t if (name === 'class' && newValue != oldValue) {\n\t attr.$updateClass(newValue, oldValue);\n\t } else {\n\t attr.$set(name, newValue);\n\t }\n\t });\n\t }\n\t };\n\t }\n\t });\n\t }\n\t\n\t\n\t /**\n\t * This is a special jqLite.replaceWith, which can replace items which\n\t * have no parents, provided that the containing jqLite collection is provided.\n\t *\n\t * @param {JqLite=} $rootElement The root of the compile tree. Used so that we can replace nodes\n\t * in the root of the tree.\n\t * @param {JqLite} elementsToRemove The jqLite element which we are going to replace. We keep\n\t * the shell, but replace its DOM node reference.\n\t * @param {Node} newNode The new DOM node.\n\t */\n\t function replaceWith($rootElement, elementsToRemove, newNode) {\n\t var firstElementToRemove = elementsToRemove[0],\n\t removeCount = elementsToRemove.length,\n\t parent = firstElementToRemove.parentNode,\n\t i, ii;\n\t\n\t if ($rootElement) {\n\t for (i = 0, ii = $rootElement.length; i < ii; i++) {\n\t if ($rootElement[i] == firstElementToRemove) {\n\t $rootElement[i++] = newNode;\n\t for (var j = i, j2 = j + removeCount - 1,\n\t jj = $rootElement.length;\n\t j < jj; j++, j2++) {\n\t if (j2 < jj) {\n\t $rootElement[j] = $rootElement[j2];\n\t } else {\n\t delete $rootElement[j];\n\t }\n\t }\n\t $rootElement.length -= removeCount - 1;\n\t\n\t // If the replaced element is also the jQuery .context then replace it\n\t // .context is a deprecated jQuery api, so we should set it only when jQuery set it\n\t // http://api.jquery.com/context/\n\t if ($rootElement.context === firstElementToRemove) {\n\t $rootElement.context = newNode;\n\t }\n\t break;\n\t }\n\t }\n\t }\n\t\n\t if (parent) {\n\t parent.replaceChild(newNode, firstElementToRemove);\n\t }\n\t\n\t // TODO(perf): what's this document fragment for? is it needed? can we at least reuse it?\n\t var fragment = document.createDocumentFragment();\n\t fragment.appendChild(firstElementToRemove);\n\t\n\t if (jqLite.hasData(firstElementToRemove)) {\n\t // Copy over user data (that includes Angular's $scope etc.). Don't copy private\n\t // data here because there's no public interface in jQuery to do that and copying over\n\t // event listeners (which is the main use of private data) wouldn't work anyway.\n\t jqLite.data(newNode, jqLite.data(firstElementToRemove));\n\t\n\t // Remove data of the replaced element. We cannot just call .remove()\n\t // on the element it since that would deallocate scope that is needed\n\t // for the new node. Instead, remove the data \"manually\".\n\t if (!jQuery) {\n\t delete jqLite.cache[firstElementToRemove[jqLite.expando]];\n\t } else {\n\t // jQuery 2.x doesn't expose the data storage. Use jQuery.cleanData to clean up after\n\t // the replaced element. The cleanData version monkey-patched by Angular would cause\n\t // the scope to be trashed and we do need the very same scope to work with the new\n\t // element. However, we cannot just cache the non-patched version and use it here as\n\t // that would break if another library patches the method after Angular does (one\n\t // example is jQuery UI). Instead, set a flag indicating scope destroying should be\n\t // skipped this one time.\n\t skipDestroyOnNextJQueryCleanData = true;\n\t jQuery.cleanData([firstElementToRemove]);\n\t }\n\t }\n\t\n\t for (var k = 1, kk = elementsToRemove.length; k < kk; k++) {\n\t var element = elementsToRemove[k];\n\t jqLite(element).remove(); // must do this way to clean up expando\n\t fragment.appendChild(element);\n\t delete elementsToRemove[k];\n\t }\n\t\n\t elementsToRemove[0] = newNode;\n\t elementsToRemove.length = 1;\n\t }\n\t\n\t\n\t function cloneAndAnnotateFn(fn, annotation) {\n\t return extend(function() { return fn.apply(null, arguments); }, fn, annotation);\n\t }\n\t\n\t\n\t function invokeLinkFn(linkFn, scope, $element, attrs, controllers, transcludeFn) {\n\t try {\n\t linkFn(scope, $element, attrs, controllers, transcludeFn);\n\t } catch (e) {\n\t $exceptionHandler(e, startingTag($element));\n\t }\n\t }\n\t\n\t\n\t // Set up $watches for isolate scope and controller bindings. This process\n\t // only occurs for isolate scopes and new scopes with controllerAs.\n\t function initializeDirectiveBindings(scope, attrs, destination, bindings, directive) {\n\t var removeWatchCollection = [];\n\t forEach(bindings, function(definition, scopeName) {\n\t var attrName = definition.attrName,\n\t optional = definition.optional,\n\t mode = definition.mode, // @, =, or &\n\t lastValue,\n\t parentGet, parentSet, compare;\n\t\n\t switch (mode) {\n\t\n\t case '@':\n\t if (!optional && !hasOwnProperty.call(attrs, attrName)) {\n\t destination[scopeName] = attrs[attrName] = void 0;\n\t }\n\t attrs.$observe(attrName, function(value) {\n\t if (isString(value)) {\n\t destination[scopeName] = value;\n\t }\n\t });\n\t attrs.$$observers[attrName].$$scope = scope;\n\t lastValue = attrs[attrName];\n\t if (isString(lastValue)) {\n\t // If the attribute has been provided then we trigger an interpolation to ensure\n\t // the value is there for use in the link fn\n\t destination[scopeName] = $interpolate(lastValue)(scope);\n\t } else if (isBoolean(lastValue)) {\n\t // If the attributes is one of the BOOLEAN_ATTR then Angular will have converted\n\t // the value to boolean rather than a string, so we special case this situation\n\t destination[scopeName] = lastValue;\n\t }\n\t break;\n\t\n\t case '=':\n\t if (!hasOwnProperty.call(attrs, attrName)) {\n\t if (optional) break;\n\t attrs[attrName] = void 0;\n\t }\n\t if (optional && !attrs[attrName]) break;\n\t\n\t parentGet = $parse(attrs[attrName]);\n\t if (parentGet.literal) {\n\t compare = equals;\n\t } else {\n\t compare = function(a, b) { return a === b || (a !== a && b !== b); };\n\t }\n\t parentSet = parentGet.assign || function() {\n\t // reset the change, or we will throw this exception on every $digest\n\t lastValue = destination[scopeName] = parentGet(scope);\n\t throw $compileMinErr('nonassign',\n\t \"Expression '{0}' in attribute '{1}' used with directive '{2}' is non-assignable!\",\n\t attrs[attrName], attrName, directive.name);\n\t };\n\t lastValue = destination[scopeName] = parentGet(scope);\n\t var parentValueWatch = function parentValueWatch(parentValue) {\n\t if (!compare(parentValue, destination[scopeName])) {\n\t // we are out of sync and need to copy\n\t if (!compare(parentValue, lastValue)) {\n\t // parent changed and it has precedence\n\t destination[scopeName] = parentValue;\n\t } else {\n\t // if the parent can be assigned then do so\n\t parentSet(scope, parentValue = destination[scopeName]);\n\t }\n\t }\n\t return lastValue = parentValue;\n\t };\n\t parentValueWatch.$stateful = true;\n\t var removeWatch;\n\t if (definition.collection) {\n\t removeWatch = scope.$watchCollection(attrs[attrName], parentValueWatch);\n\t } else {\n\t removeWatch = scope.$watch($parse(attrs[attrName], parentValueWatch), null, parentGet.literal);\n\t }\n\t removeWatchCollection.push(removeWatch);\n\t break;\n\t\n\t case '&':\n\t // Don't assign Object.prototype method to scope\n\t parentGet = attrs.hasOwnProperty(attrName) ? $parse(attrs[attrName]) : noop;\n\t\n\t // Don't assign noop to destination if expression is not valid\n\t if (parentGet === noop && optional) break;\n\t\n\t destination[scopeName] = function(locals) {\n\t return parentGet(scope, locals);\n\t };\n\t break;\n\t }\n\t });\n\t\n\t return removeWatchCollection.length && function removeWatches() {\n\t for (var i = 0, ii = removeWatchCollection.length; i < ii; ++i) {\n\t removeWatchCollection[i]();\n\t }\n\t };\n\t }\n\t }];\n\t}\n\t\n\tvar PREFIX_REGEXP = /^((?:x|data)[\\:\\-_])/i;\n\t/**\n\t * Converts all accepted directives format into proper directive name.\n\t * @param name Name to normalize\n\t */\n\tfunction directiveNormalize(name) {\n\t return camelCase(name.replace(PREFIX_REGEXP, ''));\n\t}\n\t\n\t/**\n\t * @ngdoc type\n\t * @name $compile.directive.Attributes\n\t *\n\t * @description\n\t * A shared object between directive compile / linking functions which contains normalized DOM\n\t * element attributes. The values reflect current binding state `{{ }}`. The normalization is\n\t * needed since all of these are treated as equivalent in Angular:\n\t *\n\t * ```\n\t * \n\t * ```\n\t */\n\t\n\t/**\n\t * @ngdoc property\n\t * @name $compile.directive.Attributes#$attr\n\t *\n\t * @description\n\t * A map of DOM element attribute names to the normalized name. This is\n\t * needed to do reverse lookup from normalized name back to actual name.\n\t */\n\t\n\t\n\t/**\n\t * @ngdoc method\n\t * @name $compile.directive.Attributes#$set\n\t * @kind function\n\t *\n\t * @description\n\t * Set DOM element attribute value.\n\t *\n\t *\n\t * @param {string} name Normalized element attribute name of the property to modify. The name is\n\t * reverse-translated using the {@link ng.$compile.directive.Attributes#$attr $attr}\n\t * property to the original name.\n\t * @param {string} value Value to set the attribute to. The value can be an interpolated string.\n\t */\n\t\n\t\n\t\n\t/**\n\t * Closure compiler type information\n\t */\n\t\n\tfunction nodesetLinkingFn(\n\t /* angular.Scope */ scope,\n\t /* NodeList */ nodeList,\n\t /* Element */ rootElement,\n\t /* function(Function) */ boundTranscludeFn\n\t) {}\n\t\n\tfunction directiveLinkingFn(\n\t /* nodesetLinkingFn */ nodesetLinkingFn,\n\t /* angular.Scope */ scope,\n\t /* Node */ node,\n\t /* Element */ rootElement,\n\t /* function(Function) */ boundTranscludeFn\n\t) {}\n\t\n\tfunction tokenDifference(str1, str2) {\n\t var values = '',\n\t tokens1 = str1.split(/\\s+/),\n\t tokens2 = str2.split(/\\s+/);\n\t\n\t outer:\n\t for (var i = 0; i < tokens1.length; i++) {\n\t var token = tokens1[i];\n\t for (var j = 0; j < tokens2.length; j++) {\n\t if (token == tokens2[j]) continue outer;\n\t }\n\t values += (values.length > 0 ? ' ' : '') + token;\n\t }\n\t return values;\n\t}\n\t\n\tfunction removeComments(jqNodes) {\n\t jqNodes = jqLite(jqNodes);\n\t var i = jqNodes.length;\n\t\n\t if (i <= 1) {\n\t return jqNodes;\n\t }\n\t\n\t while (i--) {\n\t var node = jqNodes[i];\n\t if (node.nodeType === NODE_TYPE_COMMENT) {\n\t splice.call(jqNodes, i, 1);\n\t }\n\t }\n\t return jqNodes;\n\t}\n\t\n\tvar $controllerMinErr = minErr('$controller');\n\t\n\t\n\tvar CNTRL_REG = /^(\\S+)(\\s+as\\s+([\\w$]+))?$/;\n\tfunction identifierForController(controller, ident) {\n\t if (ident && isString(ident)) return ident;\n\t if (isString(controller)) {\n\t var match = CNTRL_REG.exec(controller);\n\t if (match) return match[3];\n\t }\n\t}\n\t\n\t\n\t/**\n\t * @ngdoc provider\n\t * @name $controllerProvider\n\t * @description\n\t * The {@link ng.$controller $controller service} is used by Angular to create new\n\t * controllers.\n\t *\n\t * This provider allows controller registration via the\n\t * {@link ng.$controllerProvider#register register} method.\n\t */\n\tfunction $ControllerProvider() {\n\t var controllers = {},\n\t globals = false;\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $controllerProvider#register\n\t * @param {string|Object} name Controller name, or an object map of controllers where the keys are\n\t * the names and the values are the constructors.\n\t * @param {Function|Array} constructor Controller constructor fn (optionally decorated with DI\n\t * annotations in the array notation).\n\t */\n\t this.register = function(name, constructor) {\n\t assertNotHasOwnProperty(name, 'controller');\n\t if (isObject(name)) {\n\t extend(controllers, name);\n\t } else {\n\t controllers[name] = constructor;\n\t }\n\t };\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $controllerProvider#allowGlobals\n\t * @description If called, allows `$controller` to find controller constructors on `window`\n\t */\n\t this.allowGlobals = function() {\n\t globals = true;\n\t };\n\t\n\t\n\t this.$get = ['$injector', '$window', function($injector, $window) {\n\t\n\t /**\n\t * @ngdoc service\n\t * @name $controller\n\t * @requires $injector\n\t *\n\t * @param {Function|string} constructor If called with a function then it's considered to be the\n\t * controller constructor function. Otherwise it's considered to be a string which is used\n\t * to retrieve the controller constructor using the following steps:\n\t *\n\t * * check if a controller with given name is registered via `$controllerProvider`\n\t * * check if evaluating the string on the current scope returns a constructor\n\t * * if $controllerProvider#allowGlobals, check `window[constructor]` on the global\n\t * `window` object (not recommended)\n\t *\n\t * The string can use the `controller as property` syntax, where the controller instance is published\n\t * as the specified property on the `scope`; the `scope` must be injected into `locals` param for this\n\t * to work correctly.\n\t *\n\t * @param {Object} locals Injection locals for Controller.\n\t * @return {Object} Instance of given controller.\n\t *\n\t * @description\n\t * `$controller` service is responsible for instantiating controllers.\n\t *\n\t * It's just a simple call to {@link auto.$injector $injector}, but extracted into\n\t * a service, so that one can override this service with [BC version](https://gist.github.com/1649788).\n\t */\n\t return function(expression, locals, later, ident) {\n\t // PRIVATE API:\n\t // param `later` --- indicates that the controller's constructor is invoked at a later time.\n\t // If true, $controller will allocate the object with the correct\n\t // prototype chain, but will not invoke the controller until a returned\n\t // callback is invoked.\n\t // param `ident` --- An optional label which overrides the label parsed from the controller\n\t // expression, if any.\n\t var instance, match, constructor, identifier;\n\t later = later === true;\n\t if (ident && isString(ident)) {\n\t identifier = ident;\n\t }\n\t\n\t if (isString(expression)) {\n\t match = expression.match(CNTRL_REG);\n\t if (!match) {\n\t throw $controllerMinErr('ctrlfmt',\n\t \"Badly formed controller string '{0}'. \" +\n\t \"Must match `__name__ as __id__` or `__name__`.\", expression);\n\t }\n\t constructor = match[1],\n\t identifier = identifier || match[3];\n\t expression = controllers.hasOwnProperty(constructor)\n\t ? controllers[constructor]\n\t : getter(locals.$scope, constructor, true) ||\n\t (globals ? getter($window, constructor, true) : undefined);\n\t\n\t assertArgFn(expression, constructor, true);\n\t }\n\t\n\t if (later) {\n\t // Instantiate controller later:\n\t // This machinery is used to create an instance of the object before calling the\n\t // controller's constructor itself.\n\t //\n\t // This allows properties to be added to the controller before the constructor is\n\t // invoked. Primarily, this is used for isolate scope bindings in $compile.\n\t //\n\t // This feature is not intended for use by applications, and is thus not documented\n\t // publicly.\n\t // Object creation: http://jsperf.com/create-constructor/2\n\t var controllerPrototype = (isArray(expression) ?\n\t expression[expression.length - 1] : expression).prototype;\n\t instance = Object.create(controllerPrototype || null);\n\t\n\t if (identifier) {\n\t addIdentifier(locals, identifier, instance, constructor || expression.name);\n\t }\n\t\n\t var instantiate;\n\t return instantiate = extend(function() {\n\t var result = $injector.invoke(expression, instance, locals, constructor);\n\t if (result !== instance && (isObject(result) || isFunction(result))) {\n\t instance = result;\n\t if (identifier) {\n\t // If result changed, re-assign controllerAs value to scope.\n\t addIdentifier(locals, identifier, instance, constructor || expression.name);\n\t }\n\t }\n\t return instance;\n\t }, {\n\t instance: instance,\n\t identifier: identifier\n\t });\n\t }\n\t\n\t instance = $injector.instantiate(expression, locals, constructor);\n\t\n\t if (identifier) {\n\t addIdentifier(locals, identifier, instance, constructor || expression.name);\n\t }\n\t\n\t return instance;\n\t };\n\t\n\t function addIdentifier(locals, identifier, instance, name) {\n\t if (!(locals && isObject(locals.$scope))) {\n\t throw minErr('$controller')('noscp',\n\t \"Cannot export controller '{0}' as '{1}'! No $scope object provided via `locals`.\",\n\t name, identifier);\n\t }\n\t\n\t locals.$scope[identifier] = instance;\n\t }\n\t }];\n\t}\n\t\n\t/**\n\t * @ngdoc service\n\t * @name $document\n\t * @requires $window\n\t *\n\t * @description\n\t * A {@link angular.element jQuery or jqLite} wrapper for the browser's `window.document` object.\n\t *\n\t * @example\n\t \n\t \n\t
\n\t

$document title:

\n\t

window.document title:

\n\t
\n\t
\n\t \n\t angular.module('documentExample', [])\n\t .controller('ExampleController', ['$scope', '$document', function($scope, $document) {\n\t $scope.title = $document[0].title;\n\t $scope.windowTitle = angular.element(window.document)[0].title;\n\t }]);\n\t \n\t
\n\t */\n\tfunction $DocumentProvider() {\n\t this.$get = ['$window', function(window) {\n\t return jqLite(window.document);\n\t }];\n\t}\n\t\n\t/**\n\t * @ngdoc service\n\t * @name $exceptionHandler\n\t * @requires ng.$log\n\t *\n\t * @description\n\t * Any uncaught exception in angular expressions is delegated to this service.\n\t * The default implementation simply delegates to `$log.error` which logs it into\n\t * the browser console.\n\t *\n\t * In unit tests, if `angular-mocks.js` is loaded, this service is overridden by\n\t * {@link ngMock.$exceptionHandler mock $exceptionHandler} which aids in testing.\n\t *\n\t * ## Example:\n\t *\n\t * ```js\n\t * angular.module('exceptionOverride', []).factory('$exceptionHandler', function() {\n\t * return function(exception, cause) {\n\t * exception.message += ' (caused by \"' + cause + '\")';\n\t * throw exception;\n\t * };\n\t * });\n\t * ```\n\t *\n\t * This example will override the normal action of `$exceptionHandler`, to make angular\n\t * exceptions fail hard when they happen, instead of just logging to the console.\n\t *\n\t *
\n\t * Note, that code executed in event-listeners (even those registered using jqLite's `on`/`bind`\n\t * methods) does not delegate exceptions to the {@link ng.$exceptionHandler $exceptionHandler}\n\t * (unless executed during a digest).\n\t *\n\t * If you wish, you can manually delegate exceptions, e.g.\n\t * `try { ... } catch(e) { $exceptionHandler(e); }`\n\t *\n\t * @param {Error} exception Exception associated with the error.\n\t * @param {string=} cause optional information about the context in which\n\t * the error was thrown.\n\t *\n\t */\n\tfunction $ExceptionHandlerProvider() {\n\t this.$get = ['$log', function($log) {\n\t return function(exception, cause) {\n\t $log.error.apply($log, arguments);\n\t };\n\t }];\n\t}\n\t\n\tvar $$ForceReflowProvider = function() {\n\t this.$get = ['$document', function($document) {\n\t return function(domNode) {\n\t //the line below will force the browser to perform a repaint so\n\t //that all the animated elements within the animation frame will\n\t //be properly updated and drawn on screen. This is required to\n\t //ensure that the preparation animation is properly flushed so that\n\t //the active state picks up from there. DO NOT REMOVE THIS LINE.\n\t //DO NOT OPTIMIZE THIS LINE. THE MINIFIER WILL REMOVE IT OTHERWISE WHICH\n\t //WILL RESULT IN AN UNPREDICTABLE BUG THAT IS VERY HARD TO TRACK DOWN AND\n\t //WILL TAKE YEARS AWAY FROM YOUR LIFE.\n\t if (domNode) {\n\t if (!domNode.nodeType && domNode instanceof jqLite) {\n\t domNode = domNode[0];\n\t }\n\t } else {\n\t domNode = $document[0].body;\n\t }\n\t return domNode.offsetWidth + 1;\n\t };\n\t }];\n\t};\n\t\n\tvar APPLICATION_JSON = 'application/json';\n\tvar CONTENT_TYPE_APPLICATION_JSON = {'Content-Type': APPLICATION_JSON + ';charset=utf-8'};\n\tvar JSON_START = /^\\[|^\\{(?!\\{)/;\n\tvar JSON_ENDS = {\n\t '[': /]$/,\n\t '{': /}$/\n\t};\n\tvar JSON_PROTECTION_PREFIX = /^\\)\\]\\}',?\\n/;\n\tvar $httpMinErr = minErr('$http');\n\tvar $httpMinErrLegacyFn = function(method) {\n\t return function() {\n\t throw $httpMinErr('legacy', 'The method `{0}` on the promise returned from `$http` has been disabled.', method);\n\t };\n\t};\n\t\n\tfunction serializeValue(v) {\n\t if (isObject(v)) {\n\t return isDate(v) ? v.toISOString() : toJson(v);\n\t }\n\t return v;\n\t}\n\t\n\t\n\tfunction $HttpParamSerializerProvider() {\n\t /**\n\t * @ngdoc service\n\t * @name $httpParamSerializer\n\t * @description\n\t *\n\t * Default {@link $http `$http`} params serializer that converts objects to strings\n\t * according to the following rules:\n\t *\n\t * * `{'foo': 'bar'}` results in `foo=bar`\n\t * * `{'foo': Date.now()}` results in `foo=2015-04-01T09%3A50%3A49.262Z` (`toISOString()` and encoded representation of a Date object)\n\t * * `{'foo': ['bar', 'baz']}` results in `foo=bar&foo=baz` (repeated key for each array element)\n\t * * `{'foo': {'bar':'baz'}}` results in `foo=%7B%22bar%22%3A%22baz%22%7D\"` (stringified and encoded representation of an object)\n\t *\n\t * Note that serializer will sort the request parameters alphabetically.\n\t * */\n\t\n\t this.$get = function() {\n\t return function ngParamSerializer(params) {\n\t if (!params) return '';\n\t var parts = [];\n\t forEachSorted(params, function(value, key) {\n\t if (value === null || isUndefined(value)) return;\n\t if (isArray(value)) {\n\t forEach(value, function(v, k) {\n\t parts.push(encodeUriQuery(key) + '=' + encodeUriQuery(serializeValue(v)));\n\t });\n\t } else {\n\t parts.push(encodeUriQuery(key) + '=' + encodeUriQuery(serializeValue(value)));\n\t }\n\t });\n\t\n\t return parts.join('&');\n\t };\n\t };\n\t}\n\t\n\tfunction $HttpParamSerializerJQLikeProvider() {\n\t /**\n\t * @ngdoc service\n\t * @name $httpParamSerializerJQLike\n\t * @description\n\t *\n\t * Alternative {@link $http `$http`} params serializer that follows\n\t * jQuery's [`param()`](http://api.jquery.com/jquery.param/) method logic.\n\t * The serializer will also sort the params alphabetically.\n\t *\n\t * To use it for serializing `$http` request parameters, set it as the `paramSerializer` property:\n\t *\n\t * ```js\n\t * $http({\n\t * url: myUrl,\n\t * method: 'GET',\n\t * params: myParams,\n\t * paramSerializer: '$httpParamSerializerJQLike'\n\t * });\n\t * ```\n\t *\n\t * It is also possible to set it as the default `paramSerializer` in the\n\t * {@link $httpProvider#defaults `$httpProvider`}.\n\t *\n\t * Additionally, you can inject the serializer and use it explicitly, for example to serialize\n\t * form data for submission:\n\t *\n\t * ```js\n\t * .controller(function($http, $httpParamSerializerJQLike) {\n\t * //...\n\t *\n\t * $http({\n\t * url: myUrl,\n\t * method: 'POST',\n\t * data: $httpParamSerializerJQLike(myData),\n\t * headers: {\n\t * 'Content-Type': 'application/x-www-form-urlencoded'\n\t * }\n\t * });\n\t *\n\t * });\n\t * ```\n\t *\n\t * */\n\t this.$get = function() {\n\t return function jQueryLikeParamSerializer(params) {\n\t if (!params) return '';\n\t var parts = [];\n\t serialize(params, '', true);\n\t return parts.join('&');\n\t\n\t function serialize(toSerialize, prefix, topLevel) {\n\t if (toSerialize === null || isUndefined(toSerialize)) return;\n\t if (isArray(toSerialize)) {\n\t forEach(toSerialize, function(value, index) {\n\t serialize(value, prefix + '[' + (isObject(value) ? index : '') + ']');\n\t });\n\t } else if (isObject(toSerialize) && !isDate(toSerialize)) {\n\t forEachSorted(toSerialize, function(value, key) {\n\t serialize(value, prefix +\n\t (topLevel ? '' : '[') +\n\t key +\n\t (topLevel ? '' : ']'));\n\t });\n\t } else {\n\t parts.push(encodeUriQuery(prefix) + '=' + encodeUriQuery(serializeValue(toSerialize)));\n\t }\n\t }\n\t };\n\t };\n\t}\n\t\n\tfunction defaultHttpResponseTransform(data, headers) {\n\t if (isString(data)) {\n\t // Strip json vulnerability protection prefix and trim whitespace\n\t var tempData = data.replace(JSON_PROTECTION_PREFIX, '').trim();\n\t\n\t if (tempData) {\n\t var contentType = headers('Content-Type');\n\t if ((contentType && (contentType.indexOf(APPLICATION_JSON) === 0)) || isJsonLike(tempData)) {\n\t data = fromJson(tempData);\n\t }\n\t }\n\t }\n\t\n\t return data;\n\t}\n\t\n\tfunction isJsonLike(str) {\n\t var jsonStart = str.match(JSON_START);\n\t return jsonStart && JSON_ENDS[jsonStart[0]].test(str);\n\t}\n\t\n\t/**\n\t * Parse headers into key value object\n\t *\n\t * @param {string} headers Raw headers as a string\n\t * @returns {Object} Parsed headers as key value object\n\t */\n\tfunction parseHeaders(headers) {\n\t var parsed = createMap(), i;\n\t\n\t function fillInParsed(key, val) {\n\t if (key) {\n\t parsed[key] = parsed[key] ? parsed[key] + ', ' + val : val;\n\t }\n\t }\n\t\n\t if (isString(headers)) {\n\t forEach(headers.split('\\n'), function(line) {\n\t i = line.indexOf(':');\n\t fillInParsed(lowercase(trim(line.substr(0, i))), trim(line.substr(i + 1)));\n\t });\n\t } else if (isObject(headers)) {\n\t forEach(headers, function(headerVal, headerKey) {\n\t fillInParsed(lowercase(headerKey), trim(headerVal));\n\t });\n\t }\n\t\n\t return parsed;\n\t}\n\t\n\t\n\t/**\n\t * Returns a function that provides access to parsed headers.\n\t *\n\t * Headers are lazy parsed when first requested.\n\t * @see parseHeaders\n\t *\n\t * @param {(string|Object)} headers Headers to provide access to.\n\t * @returns {function(string=)} Returns a getter function which if called with:\n\t *\n\t * - if called with single an argument returns a single header value or null\n\t * - if called with no arguments returns an object containing all headers.\n\t */\n\tfunction headersGetter(headers) {\n\t var headersObj;\n\t\n\t return function(name) {\n\t if (!headersObj) headersObj = parseHeaders(headers);\n\t\n\t if (name) {\n\t var value = headersObj[lowercase(name)];\n\t if (value === void 0) {\n\t value = null;\n\t }\n\t return value;\n\t }\n\t\n\t return headersObj;\n\t };\n\t}\n\t\n\t\n\t/**\n\t * Chain all given functions\n\t *\n\t * This function is used for both request and response transforming\n\t *\n\t * @param {*} data Data to transform.\n\t * @param {function(string=)} headers HTTP headers getter fn.\n\t * @param {number} status HTTP status code of the response.\n\t * @param {(Function|Array.)} fns Function or an array of functions.\n\t * @returns {*} Transformed data.\n\t */\n\tfunction transformData(data, headers, status, fns) {\n\t if (isFunction(fns)) {\n\t return fns(data, headers, status);\n\t }\n\t\n\t forEach(fns, function(fn) {\n\t data = fn(data, headers, status);\n\t });\n\t\n\t return data;\n\t}\n\t\n\t\n\tfunction isSuccess(status) {\n\t return 200 <= status && status < 300;\n\t}\n\t\n\t\n\t/**\n\t * @ngdoc provider\n\t * @name $httpProvider\n\t * @description\n\t * Use `$httpProvider` to change the default behavior of the {@link ng.$http $http} service.\n\t * */\n\tfunction $HttpProvider() {\n\t /**\n\t * @ngdoc property\n\t * @name $httpProvider#defaults\n\t * @description\n\t *\n\t * Object containing default values for all {@link ng.$http $http} requests.\n\t *\n\t * - **`defaults.cache`** - {boolean|Object} - A boolean value or object created with\n\t * {@link ng.$cacheFactory `$cacheFactory`} to enable or disable caching of HTTP responses\n\t * by default. See {@link $http#caching $http Caching} for more information.\n\t *\n\t * - **`defaults.xsrfCookieName`** - {string} - Name of cookie containing the XSRF token.\n\t * Defaults value is `'XSRF-TOKEN'`.\n\t *\n\t * - **`defaults.xsrfHeaderName`** - {string} - Name of HTTP header to populate with the\n\t * XSRF token. Defaults value is `'X-XSRF-TOKEN'`.\n\t *\n\t * - **`defaults.headers`** - {Object} - Default headers for all $http requests.\n\t * Refer to {@link ng.$http#setting-http-headers $http} for documentation on\n\t * setting default headers.\n\t * - **`defaults.headers.common`**\n\t * - **`defaults.headers.post`**\n\t * - **`defaults.headers.put`**\n\t * - **`defaults.headers.patch`**\n\t *\n\t *\n\t * - **`defaults.paramSerializer`** - `{string|function(Object):string}` - A function\n\t * used to the prepare string representation of request parameters (specified as an object).\n\t * If specified as string, it is interpreted as a function registered with the {@link auto.$injector $injector}.\n\t * Defaults to {@link ng.$httpParamSerializer $httpParamSerializer}.\n\t *\n\t **/\n\t var defaults = this.defaults = {\n\t // transform incoming response data\n\t transformResponse: [defaultHttpResponseTransform],\n\t\n\t // transform outgoing request data\n\t transformRequest: [function(d) {\n\t return isObject(d) && !isFile(d) && !isBlob(d) && !isFormData(d) ? toJson(d) : d;\n\t }],\n\t\n\t // default headers\n\t headers: {\n\t common: {\n\t 'Accept': 'application/json, text/plain, */*'\n\t },\n\t post: shallowCopy(CONTENT_TYPE_APPLICATION_JSON),\n\t put: shallowCopy(CONTENT_TYPE_APPLICATION_JSON),\n\t patch: shallowCopy(CONTENT_TYPE_APPLICATION_JSON)\n\t },\n\t\n\t xsrfCookieName: 'XSRF-TOKEN',\n\t xsrfHeaderName: 'X-XSRF-TOKEN',\n\t\n\t paramSerializer: '$httpParamSerializer'\n\t };\n\t\n\t var useApplyAsync = false;\n\t /**\n\t * @ngdoc method\n\t * @name $httpProvider#useApplyAsync\n\t * @description\n\t *\n\t * Configure $http service to combine processing of multiple http responses received at around\n\t * the same time via {@link ng.$rootScope.Scope#$applyAsync $rootScope.$applyAsync}. This can result in\n\t * significant performance improvement for bigger applications that make many HTTP requests\n\t * concurrently (common during application bootstrap).\n\t *\n\t * Defaults to false. If no value is specified, returns the current configured value.\n\t *\n\t * @param {boolean=} value If true, when requests are loaded, they will schedule a deferred\n\t * \"apply\" on the next tick, giving time for subsequent requests in a roughly ~10ms window\n\t * to load and share the same digest cycle.\n\t *\n\t * @returns {boolean|Object} If a value is specified, returns the $httpProvider for chaining.\n\t * otherwise, returns the current configured value.\n\t **/\n\t this.useApplyAsync = function(value) {\n\t if (isDefined(value)) {\n\t useApplyAsync = !!value;\n\t return this;\n\t }\n\t return useApplyAsync;\n\t };\n\t\n\t var useLegacyPromise = true;\n\t /**\n\t * @ngdoc method\n\t * @name $httpProvider#useLegacyPromiseExtensions\n\t * @description\n\t *\n\t * Configure `$http` service to return promises without the shorthand methods `success` and `error`.\n\t * This should be used to make sure that applications work without these methods.\n\t *\n\t * Defaults to true. If no value is specified, returns the current configured value.\n\t *\n\t * @param {boolean=} value If true, `$http` will return a promise with the deprecated legacy `success` and `error` methods.\n\t *\n\t * @returns {boolean|Object} If a value is specified, returns the $httpProvider for chaining.\n\t * otherwise, returns the current configured value.\n\t **/\n\t this.useLegacyPromiseExtensions = function(value) {\n\t if (isDefined(value)) {\n\t useLegacyPromise = !!value;\n\t return this;\n\t }\n\t return useLegacyPromise;\n\t };\n\t\n\t /**\n\t * @ngdoc property\n\t * @name $httpProvider#interceptors\n\t * @description\n\t *\n\t * Array containing service factories for all synchronous or asynchronous {@link ng.$http $http}\n\t * pre-processing of request or postprocessing of responses.\n\t *\n\t * These service factories are ordered by request, i.e. they are applied in the same order as the\n\t * array, on request, but reverse order, on response.\n\t *\n\t * {@link ng.$http#interceptors Interceptors detailed info}\n\t **/\n\t var interceptorFactories = this.interceptors = [];\n\t\n\t this.$get = ['$httpBackend', '$$cookieReader', '$cacheFactory', '$rootScope', '$q', '$injector',\n\t function($httpBackend, $$cookieReader, $cacheFactory, $rootScope, $q, $injector) {\n\t\n\t var defaultCache = $cacheFactory('$http');\n\t\n\t /**\n\t * Make sure that default param serializer is exposed as a function\n\t */\n\t defaults.paramSerializer = isString(defaults.paramSerializer) ?\n\t $injector.get(defaults.paramSerializer) : defaults.paramSerializer;\n\t\n\t /**\n\t * Interceptors stored in reverse order. Inner interceptors before outer interceptors.\n\t * The reversal is needed so that we can build up the interception chain around the\n\t * server request.\n\t */\n\t var reversedInterceptors = [];\n\t\n\t forEach(interceptorFactories, function(interceptorFactory) {\n\t reversedInterceptors.unshift(isString(interceptorFactory)\n\t ? $injector.get(interceptorFactory) : $injector.invoke(interceptorFactory));\n\t });\n\t\n\t /**\n\t * @ngdoc service\n\t * @kind function\n\t * @name $http\n\t * @requires ng.$httpBackend\n\t * @requires $cacheFactory\n\t * @requires $rootScope\n\t * @requires $q\n\t * @requires $injector\n\t *\n\t * @description\n\t * The `$http` service is a core Angular service that facilitates communication with the remote\n\t * HTTP servers via the browser's [XMLHttpRequest](https://developer.mozilla.org/en/xmlhttprequest)\n\t * object or via [JSONP](http://en.wikipedia.org/wiki/JSONP).\n\t *\n\t * For unit testing applications that use `$http` service, see\n\t * {@link ngMock.$httpBackend $httpBackend mock}.\n\t *\n\t * For a higher level of abstraction, please check out the {@link ngResource.$resource\n\t * $resource} service.\n\t *\n\t * The $http API is based on the {@link ng.$q deferred/promise APIs} exposed by\n\t * the $q service. While for simple usage patterns this doesn't matter much, for advanced usage\n\t * it is important to familiarize yourself with these APIs and the guarantees they provide.\n\t *\n\t *\n\t * ## General usage\n\t * The `$http` service is a function which takes a single argument — a {@link $http#usage configuration object} —\n\t * that is used to generate an HTTP request and returns a {@link ng.$q promise}.\n\t *\n\t * ```js\n\t * // Simple GET request example:\n\t * $http({\n\t * method: 'GET',\n\t * url: '/someUrl'\n\t * }).then(function successCallback(response) {\n\t * // this callback will be called asynchronously\n\t * // when the response is available\n\t * }, function errorCallback(response) {\n\t * // called asynchronously if an error occurs\n\t * // or server returns response with an error status.\n\t * });\n\t * ```\n\t *\n\t * The response object has these properties:\n\t *\n\t * - **data** – `{string|Object}` – The response body transformed with the transform\n\t * functions.\n\t * - **status** – `{number}` – HTTP status code of the response.\n\t * - **headers** – `{function([headerName])}` – Header getter function.\n\t * - **config** – `{Object}` – The configuration object that was used to generate the request.\n\t * - **statusText** – `{string}` – HTTP status text of the response.\n\t *\n\t * A response status code between 200 and 299 is considered a success status and\n\t * will result in the success callback being called. Note that if the response is a redirect,\n\t * XMLHttpRequest will transparently follow it, meaning that the error callback will not be\n\t * called for such responses.\n\t *\n\t *\n\t * ## Shortcut methods\n\t *\n\t * Shortcut methods are also available. All shortcut methods require passing in the URL, and\n\t * request data must be passed in for POST/PUT requests. An optional config can be passed as the\n\t * last argument.\n\t *\n\t * ```js\n\t * $http.get('/someUrl', config).then(successCallback, errorCallback);\n\t * $http.post('/someUrl', data, config).then(successCallback, errorCallback);\n\t * ```\n\t *\n\t * Complete list of shortcut methods:\n\t *\n\t * - {@link ng.$http#get $http.get}\n\t * - {@link ng.$http#head $http.head}\n\t * - {@link ng.$http#post $http.post}\n\t * - {@link ng.$http#put $http.put}\n\t * - {@link ng.$http#delete $http.delete}\n\t * - {@link ng.$http#jsonp $http.jsonp}\n\t * - {@link ng.$http#patch $http.patch}\n\t *\n\t *\n\t * ## Writing Unit Tests that use $http\n\t * When unit testing (using {@link ngMock ngMock}), it is necessary to call\n\t * {@link ngMock.$httpBackend#flush $httpBackend.flush()} to flush each pending\n\t * request using trained responses.\n\t *\n\t * ```\n\t * $httpBackend.expectGET(...);\n\t * $http.get(...);\n\t * $httpBackend.flush();\n\t * ```\n\t *\n\t * ## Deprecation Notice\n\t *
\n\t * The `$http` legacy promise methods `success` and `error` have been deprecated.\n\t * Use the standard `then` method instead.\n\t * If {@link $httpProvider#useLegacyPromiseExtensions `$httpProvider.useLegacyPromiseExtensions`} is set to\n\t * `false` then these methods will throw {@link $http:legacy `$http/legacy`} error.\n\t *
\n\t *\n\t * ## Setting HTTP Headers\n\t *\n\t * The $http service will automatically add certain HTTP headers to all requests. These defaults\n\t * can be fully configured by accessing the `$httpProvider.defaults.headers` configuration\n\t * object, which currently contains this default configuration:\n\t *\n\t * - `$httpProvider.defaults.headers.common` (headers that are common for all requests):\n\t * - `Accept: application/json, text/plain, * / *`\n\t * - `$httpProvider.defaults.headers.post`: (header defaults for POST requests)\n\t * - `Content-Type: application/json`\n\t * - `$httpProvider.defaults.headers.put` (header defaults for PUT requests)\n\t * - `Content-Type: application/json`\n\t *\n\t * To add or overwrite these defaults, simply add or remove a property from these configuration\n\t * objects. To add headers for an HTTP method other than POST or PUT, simply add a new object\n\t * with the lowercased HTTP method name as the key, e.g.\n\t * `$httpProvider.defaults.headers.get = { 'My-Header' : 'value' }`.\n\t *\n\t * The defaults can also be set at runtime via the `$http.defaults` object in the same\n\t * fashion. For example:\n\t *\n\t * ```\n\t * module.run(function($http) {\n\t * $http.defaults.headers.common.Authorization = 'Basic YmVlcDpib29w'\n\t * });\n\t * ```\n\t *\n\t * In addition, you can supply a `headers` property in the config object passed when\n\t * calling `$http(config)`, which overrides the defaults without changing them globally.\n\t *\n\t * To explicitly remove a header automatically added via $httpProvider.defaults.headers on a per request basis,\n\t * Use the `headers` property, setting the desired header to `undefined`. For example:\n\t *\n\t * ```js\n\t * var req = {\n\t * method: 'POST',\n\t * url: 'http://example.com',\n\t * headers: {\n\t * 'Content-Type': undefined\n\t * },\n\t * data: { test: 'test' }\n\t * }\n\t *\n\t * $http(req).then(function(){...}, function(){...});\n\t * ```\n\t *\n\t * ## Transforming Requests and Responses\n\t *\n\t * Both requests and responses can be transformed using transformation functions: `transformRequest`\n\t * and `transformResponse`. These properties can be a single function that returns\n\t * the transformed value (`function(data, headersGetter, status)`) or an array of such transformation functions,\n\t * which allows you to `push` or `unshift` a new transformation function into the transformation chain.\n\t *\n\t *
\n\t * **Note:** Angular does not make a copy of the `data` parameter before it is passed into the `transformRequest` pipeline.\n\t * That means changes to the properties of `data` are not local to the transform function (since Javascript passes objects by reference).\n\t * For example, when calling `$http.get(url, $scope.myObject)`, modifications to the object's properties in a transformRequest\n\t * function will be reflected on the scope and in any templates where the object is data-bound.\n\t * To prevent this, transform functions should have no side-effects.\n\t * If you need to modify properties, it is recommended to make a copy of the data, or create new object to return.\n\t *
\n\t *\n\t * ### Default Transformations\n\t *\n\t * The `$httpProvider` provider and `$http` service expose `defaults.transformRequest` and\n\t * `defaults.transformResponse` properties. If a request does not provide its own transformations\n\t * then these will be applied.\n\t *\n\t * You can augment or replace the default transformations by modifying these properties by adding to or\n\t * replacing the array.\n\t *\n\t * Angular provides the following default transformations:\n\t *\n\t * Request transformations (`$httpProvider.defaults.transformRequest` and `$http.defaults.transformRequest`):\n\t *\n\t * - If the `data` property of the request configuration object contains an object, serialize it\n\t * into JSON format.\n\t *\n\t * Response transformations (`$httpProvider.defaults.transformResponse` and `$http.defaults.transformResponse`):\n\t *\n\t * - If XSRF prefix is detected, strip it (see Security Considerations section below).\n\t * - If JSON response is detected, deserialize it using a JSON parser.\n\t *\n\t *\n\t * ### Overriding the Default Transformations Per Request\n\t *\n\t * If you wish override the request/response transformations only for a single request then provide\n\t * `transformRequest` and/or `transformResponse` properties on the configuration object passed\n\t * into `$http`.\n\t *\n\t * Note that if you provide these properties on the config object the default transformations will be\n\t * overwritten. If you wish to augment the default transformations then you must include them in your\n\t * local transformation array.\n\t *\n\t * The following code demonstrates adding a new response transformation to be run after the default response\n\t * transformations have been run.\n\t *\n\t * ```js\n\t * function appendTransform(defaults, transform) {\n\t *\n\t * // We can't guarantee that the default transformation is an array\n\t * defaults = angular.isArray(defaults) ? defaults : [defaults];\n\t *\n\t * // Append the new transformation to the defaults\n\t * return defaults.concat(transform);\n\t * }\n\t *\n\t * $http({\n\t * url: '...',\n\t * method: 'GET',\n\t * transformResponse: appendTransform($http.defaults.transformResponse, function(value) {\n\t * return doTransform(value);\n\t * })\n\t * });\n\t * ```\n\t *\n\t *\n\t * ## Caching\n\t *\n\t * {@link ng.$http `$http`} responses are not cached by default. To enable caching, you must\n\t * set the config.cache value or the default cache value to TRUE or to a cache object (created\n\t * with {@link ng.$cacheFactory `$cacheFactory`}). If defined, the value of config.cache takes\n\t * precedence over the default cache value.\n\t *\n\t * In order to:\n\t * * cache all responses - set the default cache value to TRUE or to a cache object\n\t * * cache a specific response - set config.cache value to TRUE or to a cache object\n\t *\n\t * If caching is enabled, but neither the default cache nor config.cache are set to a cache object,\n\t * then the default `$cacheFactory($http)` object is used.\n\t *\n\t * The default cache value can be set by updating the\n\t * {@link ng.$http#defaults `$http.defaults.cache`} property or the\n\t * {@link $httpProvider#defaults `$httpProvider.defaults.cache`} property.\n\t *\n\t * When caching is enabled, {@link ng.$http `$http`} stores the response from the server using\n\t * the relevant cache object. The next time the same request is made, the response is returned\n\t * from the cache without sending a request to the server.\n\t *\n\t * Take note that:\n\t *\n\t * * Only GET and JSONP requests are cached.\n\t * * The cache key is the request URL including search parameters; headers are not considered.\n\t * * Cached responses are returned asynchronously, in the same way as responses from the server.\n\t * * If multiple identical requests are made using the same cache, which is not yet populated,\n\t * one request will be made to the server and remaining requests will return the same response.\n\t * * A cache-control header on the response does not affect if or how responses are cached.\n\t *\n\t *\n\t * ## Interceptors\n\t *\n\t * Before you start creating interceptors, be sure to understand the\n\t * {@link ng.$q $q and deferred/promise APIs}.\n\t *\n\t * For purposes of global error handling, authentication, or any kind of synchronous or\n\t * asynchronous pre-processing of request or postprocessing of responses, it is desirable to be\n\t * able to intercept requests before they are handed to the server and\n\t * responses before they are handed over to the application code that\n\t * initiated these requests. The interceptors leverage the {@link ng.$q\n\t * promise APIs} to fulfill this need for both synchronous and asynchronous pre-processing.\n\t *\n\t * The interceptors are service factories that are registered with the `$httpProvider` by\n\t * adding them to the `$httpProvider.interceptors` array. The factory is called and\n\t * injected with dependencies (if specified) and returns the interceptor.\n\t *\n\t * There are two kinds of interceptors (and two kinds of rejection interceptors):\n\t *\n\t * * `request`: interceptors get called with a http {@link $http#usage config} object. The function is free to\n\t * modify the `config` object or create a new one. The function needs to return the `config`\n\t * object directly, or a promise containing the `config` or a new `config` object.\n\t * * `requestError`: interceptor gets called when a previous interceptor threw an error or\n\t * resolved with a rejection.\n\t * * `response`: interceptors get called with http `response` object. The function is free to\n\t * modify the `response` object or create a new one. The function needs to return the `response`\n\t * object directly, or as a promise containing the `response` or a new `response` object.\n\t * * `responseError`: interceptor gets called when a previous interceptor threw an error or\n\t * resolved with a rejection.\n\t *\n\t *\n\t * ```js\n\t * // register the interceptor as a service\n\t * $provide.factory('myHttpInterceptor', function($q, dependency1, dependency2) {\n\t * return {\n\t * // optional method\n\t * 'request': function(config) {\n\t * // do something on success\n\t * return config;\n\t * },\n\t *\n\t * // optional method\n\t * 'requestError': function(rejection) {\n\t * // do something on error\n\t * if (canRecover(rejection)) {\n\t * return responseOrNewPromise\n\t * }\n\t * return $q.reject(rejection);\n\t * },\n\t *\n\t *\n\t *\n\t * // optional method\n\t * 'response': function(response) {\n\t * // do something on success\n\t * return response;\n\t * },\n\t *\n\t * // optional method\n\t * 'responseError': function(rejection) {\n\t * // do something on error\n\t * if (canRecover(rejection)) {\n\t * return responseOrNewPromise\n\t * }\n\t * return $q.reject(rejection);\n\t * }\n\t * };\n\t * });\n\t *\n\t * $httpProvider.interceptors.push('myHttpInterceptor');\n\t *\n\t *\n\t * // alternatively, register the interceptor via an anonymous factory\n\t * $httpProvider.interceptors.push(function($q, dependency1, dependency2) {\n\t * return {\n\t * 'request': function(config) {\n\t * // same as above\n\t * },\n\t *\n\t * 'response': function(response) {\n\t * // same as above\n\t * }\n\t * };\n\t * });\n\t * ```\n\t *\n\t * ## Security Considerations\n\t *\n\t * When designing web applications, consider security threats from:\n\t *\n\t * - [JSON vulnerability](http://haacked.com/archive/2008/11/20/anatomy-of-a-subtle-json-vulnerability.aspx)\n\t * - [XSRF](http://en.wikipedia.org/wiki/Cross-site_request_forgery)\n\t *\n\t * Both server and the client must cooperate in order to eliminate these threats. Angular comes\n\t * pre-configured with strategies that address these issues, but for this to work backend server\n\t * cooperation is required.\n\t *\n\t * ### JSON Vulnerability Protection\n\t *\n\t * A [JSON vulnerability](http://haacked.com/archive/2008/11/20/anatomy-of-a-subtle-json-vulnerability.aspx)\n\t * allows third party website to turn your JSON resource URL into\n\t * [JSONP](http://en.wikipedia.org/wiki/JSONP) request under some conditions. To\n\t * counter this your server can prefix all JSON requests with following string `\")]}',\\n\"`.\n\t * Angular will automatically strip the prefix before processing it as JSON.\n\t *\n\t * For example if your server needs to return:\n\t * ```js\n\t * ['one','two']\n\t * ```\n\t *\n\t * which is vulnerable to attack, your server can return:\n\t * ```js\n\t * )]}',\n\t * ['one','two']\n\t * ```\n\t *\n\t * Angular will strip the prefix, before processing the JSON.\n\t *\n\t *\n\t * ### Cross Site Request Forgery (XSRF) Protection\n\t *\n\t * [XSRF](http://en.wikipedia.org/wiki/Cross-site_request_forgery) is an attack technique by\n\t * which the attacker can trick an authenticated user into unknowingly executing actions on your\n\t * website. Angular provides a mechanism to counter XSRF. When performing XHR requests, the\n\t * $http service reads a token from a cookie (by default, `XSRF-TOKEN`) and sets it as an HTTP\n\t * header (`X-XSRF-TOKEN`). Since only JavaScript that runs on your domain could read the\n\t * cookie, your server can be assured that the XHR came from JavaScript running on your domain.\n\t * The header will not be set for cross-domain requests.\n\t *\n\t * To take advantage of this, your server needs to set a token in a JavaScript readable session\n\t * cookie called `XSRF-TOKEN` on the first HTTP GET request. On subsequent XHR requests the\n\t * server can verify that the cookie matches `X-XSRF-TOKEN` HTTP header, and therefore be sure\n\t * that only JavaScript running on your domain could have sent the request. The token must be\n\t * unique for each user and must be verifiable by the server (to prevent the JavaScript from\n\t * making up its own tokens). We recommend that the token is a digest of your site's\n\t * authentication cookie with a [salt](https://en.wikipedia.org/wiki/Salt_(cryptography))\n\t * for added security.\n\t *\n\t * The name of the headers can be specified using the xsrfHeaderName and xsrfCookieName\n\t * properties of either $httpProvider.defaults at config-time, $http.defaults at run-time,\n\t * or the per-request config object.\n\t *\n\t * In order to prevent collisions in environments where multiple Angular apps share the\n\t * same domain or subdomain, we recommend that each application uses unique cookie name.\n\t *\n\t * @param {object} config Object describing the request to be made and how it should be\n\t * processed. The object has following properties:\n\t *\n\t * - **method** – `{string}` – HTTP method (e.g. 'GET', 'POST', etc)\n\t * - **url** – `{string}` – Absolute or relative URL of the resource that is being requested.\n\t * - **params** – `{Object.}` – Map of strings or objects which will be serialized\n\t * with the `paramSerializer` and appended as GET parameters.\n\t * - **data** – `{string|Object}` – Data to be sent as the request message data.\n\t * - **headers** – `{Object}` – Map of strings or functions which return strings representing\n\t * HTTP headers to send to the server. If the return value of a function is null, the\n\t * header will not be sent. Functions accept a config object as an argument.\n\t * - **xsrfHeaderName** – `{string}` – Name of HTTP header to populate with the XSRF token.\n\t * - **xsrfCookieName** – `{string}` – Name of cookie containing the XSRF token.\n\t * - **transformRequest** –\n\t * `{function(data, headersGetter)|Array.}` –\n\t * transform function or an array of such functions. The transform function takes the http\n\t * request body and headers and returns its transformed (typically serialized) version.\n\t * See {@link ng.$http#overriding-the-default-transformations-per-request\n\t * Overriding the Default Transformations}\n\t * - **transformResponse** –\n\t * `{function(data, headersGetter, status)|Array.}` –\n\t * transform function or an array of such functions. The transform function takes the http\n\t * response body, headers and status and returns its transformed (typically deserialized) version.\n\t * See {@link ng.$http#overriding-the-default-transformations-per-request\n\t * Overriding the Default Transformations}\n\t * - **paramSerializer** - `{string|function(Object):string}` - A function used to\n\t * prepare the string representation of request parameters (specified as an object).\n\t * If specified as string, it is interpreted as function registered with the\n\t * {@link $injector $injector}, which means you can create your own serializer\n\t * by registering it as a {@link auto.$provide#service service}.\n\t * The default serializer is the {@link $httpParamSerializer $httpParamSerializer};\n\t * alternatively, you can use the {@link $httpParamSerializerJQLike $httpParamSerializerJQLike}\n\t * - **cache** – `{boolean|Object}` – A boolean value or object created with\n\t * {@link ng.$cacheFactory `$cacheFactory`} to enable or disable caching of the HTTP response.\n\t * See {@link $http#caching $http Caching} for more information.\n\t * - **timeout** – `{number|Promise}` – timeout in milliseconds, or {@link ng.$q promise}\n\t * that should abort the request when resolved.\n\t * - **withCredentials** - `{boolean}` - whether to set the `withCredentials` flag on the\n\t * XHR object. See [requests with credentials](https://developer.mozilla.org/docs/Web/HTTP/Access_control_CORS#Requests_with_credentials)\n\t * for more information.\n\t * - **responseType** - `{string}` - see\n\t * [XMLHttpRequest.responseType](https://developer.mozilla.org/en-US/docs/Web/API/XMLHttpRequest#xmlhttprequest-responsetype).\n\t *\n\t * @returns {HttpPromise} Returns a {@link ng.$q `Promise}` that will be resolved to a response object\n\t * when the request succeeds or fails.\n\t *\n\t *\n\t * @property {Array.} pendingRequests Array of config objects for currently pending\n\t * requests. This is primarily meant to be used for debugging purposes.\n\t *\n\t *\n\t * @example\n\t\n\t\n\t
\n\t \n\t \n\t
\n\t \n\t \n\t \n\t
http status code: {{status}}
\n\t
http response data: {{data}}
\n\t
\n\t
\n\t\n\t angular.module('httpExample', [])\n\t .controller('FetchController', ['$scope', '$http', '$templateCache',\n\t function($scope, $http, $templateCache) {\n\t $scope.method = 'GET';\n\t $scope.url = 'http-hello.html';\n\t\n\t $scope.fetch = function() {\n\t $scope.code = null;\n\t $scope.response = null;\n\t\n\t $http({method: $scope.method, url: $scope.url, cache: $templateCache}).\n\t then(function(response) {\n\t $scope.status = response.status;\n\t $scope.data = response.data;\n\t }, function(response) {\n\t $scope.data = response.data || \"Request failed\";\n\t $scope.status = response.status;\n\t });\n\t };\n\t\n\t $scope.updateModel = function(method, url) {\n\t $scope.method = method;\n\t $scope.url = url;\n\t };\n\t }]);\n\t\n\t\n\t Hello, $http!\n\t\n\t\n\t var status = element(by.binding('status'));\n\t var data = element(by.binding('data'));\n\t var fetchBtn = element(by.id('fetchbtn'));\n\t var sampleGetBtn = element(by.id('samplegetbtn'));\n\t var sampleJsonpBtn = element(by.id('samplejsonpbtn'));\n\t var invalidJsonpBtn = element(by.id('invalidjsonpbtn'));\n\t\n\t it('should make an xhr GET request', function() {\n\t sampleGetBtn.click();\n\t fetchBtn.click();\n\t expect(status.getText()).toMatch('200');\n\t expect(data.getText()).toMatch(/Hello, \\$http!/);\n\t });\n\t\n\t// Commented out due to flakes. See https://github.com/angular/angular.js/issues/9185\n\t// it('should make a JSONP request to angularjs.org', function() {\n\t// sampleJsonpBtn.click();\n\t// fetchBtn.click();\n\t// expect(status.getText()).toMatch('200');\n\t// expect(data.getText()).toMatch(/Super Hero!/);\n\t// });\n\t\n\t it('should make JSONP request to invalid URL and invoke the error handler',\n\t function() {\n\t invalidJsonpBtn.click();\n\t fetchBtn.click();\n\t expect(status.getText()).toMatch('0');\n\t expect(data.getText()).toMatch('Request failed');\n\t });\n\t\n\t
\n\t */\n\t function $http(requestConfig) {\n\t\n\t if (!angular.isObject(requestConfig)) {\n\t throw minErr('$http')('badreq', 'Http request configuration must be an object. Received: {0}', requestConfig);\n\t }\n\t\n\t if (!isString(requestConfig.url)) {\n\t throw minErr('$http')('badreq', 'Http request configuration url must be a string. Received: {0}', requestConfig.url);\n\t }\n\t\n\t var config = extend({\n\t method: 'get',\n\t transformRequest: defaults.transformRequest,\n\t transformResponse: defaults.transformResponse,\n\t paramSerializer: defaults.paramSerializer\n\t }, requestConfig);\n\t\n\t config.headers = mergeHeaders(requestConfig);\n\t config.method = uppercase(config.method);\n\t config.paramSerializer = isString(config.paramSerializer) ?\n\t $injector.get(config.paramSerializer) : config.paramSerializer;\n\t\n\t var serverRequest = function(config) {\n\t var headers = config.headers;\n\t var reqData = transformData(config.data, headersGetter(headers), undefined, config.transformRequest);\n\t\n\t // strip content-type if data is undefined\n\t if (isUndefined(reqData)) {\n\t forEach(headers, function(value, header) {\n\t if (lowercase(header) === 'content-type') {\n\t delete headers[header];\n\t }\n\t });\n\t }\n\t\n\t if (isUndefined(config.withCredentials) && !isUndefined(defaults.withCredentials)) {\n\t config.withCredentials = defaults.withCredentials;\n\t }\n\t\n\t // send request\n\t return sendReq(config, reqData).then(transformResponse, transformResponse);\n\t };\n\t\n\t var chain = [serverRequest, undefined];\n\t var promise = $q.when(config);\n\t\n\t // apply interceptors\n\t forEach(reversedInterceptors, function(interceptor) {\n\t if (interceptor.request || interceptor.requestError) {\n\t chain.unshift(interceptor.request, interceptor.requestError);\n\t }\n\t if (interceptor.response || interceptor.responseError) {\n\t chain.push(interceptor.response, interceptor.responseError);\n\t }\n\t });\n\t\n\t while (chain.length) {\n\t var thenFn = chain.shift();\n\t var rejectFn = chain.shift();\n\t\n\t promise = promise.then(thenFn, rejectFn);\n\t }\n\t\n\t if (useLegacyPromise) {\n\t promise.success = function(fn) {\n\t assertArgFn(fn, 'fn');\n\t\n\t promise.then(function(response) {\n\t fn(response.data, response.status, response.headers, config);\n\t });\n\t return promise;\n\t };\n\t\n\t promise.error = function(fn) {\n\t assertArgFn(fn, 'fn');\n\t\n\t promise.then(null, function(response) {\n\t fn(response.data, response.status, response.headers, config);\n\t });\n\t return promise;\n\t };\n\t } else {\n\t promise.success = $httpMinErrLegacyFn('success');\n\t promise.error = $httpMinErrLegacyFn('error');\n\t }\n\t\n\t return promise;\n\t\n\t function transformResponse(response) {\n\t // make a copy since the response must be cacheable\n\t var resp = extend({}, response);\n\t resp.data = transformData(response.data, response.headers, response.status,\n\t config.transformResponse);\n\t return (isSuccess(response.status))\n\t ? resp\n\t : $q.reject(resp);\n\t }\n\t\n\t function executeHeaderFns(headers, config) {\n\t var headerContent, processedHeaders = {};\n\t\n\t forEach(headers, function(headerFn, header) {\n\t if (isFunction(headerFn)) {\n\t headerContent = headerFn(config);\n\t if (headerContent != null) {\n\t processedHeaders[header] = headerContent;\n\t }\n\t } else {\n\t processedHeaders[header] = headerFn;\n\t }\n\t });\n\t\n\t return processedHeaders;\n\t }\n\t\n\t function mergeHeaders(config) {\n\t var defHeaders = defaults.headers,\n\t reqHeaders = extend({}, config.headers),\n\t defHeaderName, lowercaseDefHeaderName, reqHeaderName;\n\t\n\t defHeaders = extend({}, defHeaders.common, defHeaders[lowercase(config.method)]);\n\t\n\t // using for-in instead of forEach to avoid unecessary iteration after header has been found\n\t defaultHeadersIteration:\n\t for (defHeaderName in defHeaders) {\n\t lowercaseDefHeaderName = lowercase(defHeaderName);\n\t\n\t for (reqHeaderName in reqHeaders) {\n\t if (lowercase(reqHeaderName) === lowercaseDefHeaderName) {\n\t continue defaultHeadersIteration;\n\t }\n\t }\n\t\n\t reqHeaders[defHeaderName] = defHeaders[defHeaderName];\n\t }\n\t\n\t // execute if header value is a function for merged headers\n\t return executeHeaderFns(reqHeaders, shallowCopy(config));\n\t }\n\t }\n\t\n\t $http.pendingRequests = [];\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $http#get\n\t *\n\t * @description\n\t * Shortcut method to perform `GET` request.\n\t *\n\t * @param {string} url Relative or absolute URL specifying the destination of the request\n\t * @param {Object=} config Optional configuration object\n\t * @returns {HttpPromise} Future object\n\t */\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $http#delete\n\t *\n\t * @description\n\t * Shortcut method to perform `DELETE` request.\n\t *\n\t * @param {string} url Relative or absolute URL specifying the destination of the request\n\t * @param {Object=} config Optional configuration object\n\t * @returns {HttpPromise} Future object\n\t */\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $http#head\n\t *\n\t * @description\n\t * Shortcut method to perform `HEAD` request.\n\t *\n\t * @param {string} url Relative or absolute URL specifying the destination of the request\n\t * @param {Object=} config Optional configuration object\n\t * @returns {HttpPromise} Future object\n\t */\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $http#jsonp\n\t *\n\t * @description\n\t * Shortcut method to perform `JSONP` request.\n\t *\n\t * @param {string} url Relative or absolute URL specifying the destination of the request.\n\t * The name of the callback should be the string `JSON_CALLBACK`.\n\t * @param {Object=} config Optional configuration object\n\t * @returns {HttpPromise} Future object\n\t */\n\t createShortMethods('get', 'delete', 'head', 'jsonp');\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $http#post\n\t *\n\t * @description\n\t * Shortcut method to perform `POST` request.\n\t *\n\t * @param {string} url Relative or absolute URL specifying the destination of the request\n\t * @param {*} data Request content\n\t * @param {Object=} config Optional configuration object\n\t * @returns {HttpPromise} Future object\n\t */\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $http#put\n\t *\n\t * @description\n\t * Shortcut method to perform `PUT` request.\n\t *\n\t * @param {string} url Relative or absolute URL specifying the destination of the request\n\t * @param {*} data Request content\n\t * @param {Object=} config Optional configuration object\n\t * @returns {HttpPromise} Future object\n\t */\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $http#patch\n\t *\n\t * @description\n\t * Shortcut method to perform `PATCH` request.\n\t *\n\t * @param {string} url Relative or absolute URL specifying the destination of the request\n\t * @param {*} data Request content\n\t * @param {Object=} config Optional configuration object\n\t * @returns {HttpPromise} Future object\n\t */\n\t createShortMethodsWithData('post', 'put', 'patch');\n\t\n\t /**\n\t * @ngdoc property\n\t * @name $http#defaults\n\t *\n\t * @description\n\t * Runtime equivalent of the `$httpProvider.defaults` property. Allows configuration of\n\t * default headers, withCredentials as well as request and response transformations.\n\t *\n\t * See \"Setting HTTP Headers\" and \"Transforming Requests and Responses\" sections above.\n\t */\n\t $http.defaults = defaults;\n\t\n\t\n\t return $http;\n\t\n\t\n\t function createShortMethods(names) {\n\t forEach(arguments, function(name) {\n\t $http[name] = function(url, config) {\n\t return $http(extend({}, config || {}, {\n\t method: name,\n\t url: url\n\t }));\n\t };\n\t });\n\t }\n\t\n\t\n\t function createShortMethodsWithData(name) {\n\t forEach(arguments, function(name) {\n\t $http[name] = function(url, data, config) {\n\t return $http(extend({}, config || {}, {\n\t method: name,\n\t url: url,\n\t data: data\n\t }));\n\t };\n\t });\n\t }\n\t\n\t\n\t /**\n\t * Makes the request.\n\t *\n\t * !!! ACCESSES CLOSURE VARS:\n\t * $httpBackend, defaults, $log, $rootScope, defaultCache, $http.pendingRequests\n\t */\n\t function sendReq(config, reqData) {\n\t var deferred = $q.defer(),\n\t promise = deferred.promise,\n\t cache,\n\t cachedResp,\n\t reqHeaders = config.headers,\n\t url = buildUrl(config.url, config.paramSerializer(config.params));\n\t\n\t $http.pendingRequests.push(config);\n\t promise.then(removePendingReq, removePendingReq);\n\t\n\t\n\t if ((config.cache || defaults.cache) && config.cache !== false &&\n\t (config.method === 'GET' || config.method === 'JSONP')) {\n\t cache = isObject(config.cache) ? config.cache\n\t : isObject(defaults.cache) ? defaults.cache\n\t : defaultCache;\n\t }\n\t\n\t if (cache) {\n\t cachedResp = cache.get(url);\n\t if (isDefined(cachedResp)) {\n\t if (isPromiseLike(cachedResp)) {\n\t // cached request has already been sent, but there is no response yet\n\t cachedResp.then(resolvePromiseWithResult, resolvePromiseWithResult);\n\t } else {\n\t // serving from cache\n\t if (isArray(cachedResp)) {\n\t resolvePromise(cachedResp[1], cachedResp[0], shallowCopy(cachedResp[2]), cachedResp[3]);\n\t } else {\n\t resolvePromise(cachedResp, 200, {}, 'OK');\n\t }\n\t }\n\t } else {\n\t // put the promise for the non-transformed response into cache as a placeholder\n\t cache.put(url, promise);\n\t }\n\t }\n\t\n\t\n\t // if we won't have the response in cache, set the xsrf headers and\n\t // send the request to the backend\n\t if (isUndefined(cachedResp)) {\n\t var xsrfValue = urlIsSameOrigin(config.url)\n\t ? $$cookieReader()[config.xsrfCookieName || defaults.xsrfCookieName]\n\t : undefined;\n\t if (xsrfValue) {\n\t reqHeaders[(config.xsrfHeaderName || defaults.xsrfHeaderName)] = xsrfValue;\n\t }\n\t\n\t $httpBackend(config.method, url, reqData, done, reqHeaders, config.timeout,\n\t config.withCredentials, config.responseType);\n\t }\n\t\n\t return promise;\n\t\n\t\n\t /**\n\t * Callback registered to $httpBackend():\n\t * - caches the response if desired\n\t * - resolves the raw $http promise\n\t * - calls $apply\n\t */\n\t function done(status, response, headersString, statusText) {\n\t if (cache) {\n\t if (isSuccess(status)) {\n\t cache.put(url, [status, response, parseHeaders(headersString), statusText]);\n\t } else {\n\t // remove promise from the cache\n\t cache.remove(url);\n\t }\n\t }\n\t\n\t function resolveHttpPromise() {\n\t resolvePromise(response, status, headersString, statusText);\n\t }\n\t\n\t if (useApplyAsync) {\n\t $rootScope.$applyAsync(resolveHttpPromise);\n\t } else {\n\t resolveHttpPromise();\n\t if (!$rootScope.$$phase) $rootScope.$apply();\n\t }\n\t }\n\t\n\t\n\t /**\n\t * Resolves the raw $http promise.\n\t */\n\t function resolvePromise(response, status, headers, statusText) {\n\t //status: HTTP response status code, 0, -1 (aborted by timeout / promise)\n\t status = status >= -1 ? status : 0;\n\t\n\t (isSuccess(status) ? deferred.resolve : deferred.reject)({\n\t data: response,\n\t status: status,\n\t headers: headersGetter(headers),\n\t config: config,\n\t statusText: statusText\n\t });\n\t }\n\t\n\t function resolvePromiseWithResult(result) {\n\t resolvePromise(result.data, result.status, shallowCopy(result.headers()), result.statusText);\n\t }\n\t\n\t function removePendingReq() {\n\t var idx = $http.pendingRequests.indexOf(config);\n\t if (idx !== -1) $http.pendingRequests.splice(idx, 1);\n\t }\n\t }\n\t\n\t\n\t function buildUrl(url, serializedParams) {\n\t if (serializedParams.length > 0) {\n\t url += ((url.indexOf('?') == -1) ? '?' : '&') + serializedParams;\n\t }\n\t return url;\n\t }\n\t }];\n\t}\n\t\n\t/**\n\t * @ngdoc service\n\t * @name $xhrFactory\n\t *\n\t * @description\n\t * Factory function used to create XMLHttpRequest objects.\n\t *\n\t * Replace or decorate this service to create your own custom XMLHttpRequest objects.\n\t *\n\t * ```\n\t * angular.module('myApp', [])\n\t * .factory('$xhrFactory', function() {\n\t * return function createXhr(method, url) {\n\t * return new window.XMLHttpRequest({mozSystem: true});\n\t * };\n\t * });\n\t * ```\n\t *\n\t * @param {string} method HTTP method of the request (GET, POST, PUT, ..)\n\t * @param {string} url URL of the request.\n\t */\n\tfunction $xhrFactoryProvider() {\n\t this.$get = function() {\n\t return function createXhr() {\n\t return new window.XMLHttpRequest();\n\t };\n\t };\n\t}\n\t\n\t/**\n\t * @ngdoc service\n\t * @name $httpBackend\n\t * @requires $window\n\t * @requires $document\n\t * @requires $xhrFactory\n\t *\n\t * @description\n\t * HTTP backend used by the {@link ng.$http service} that delegates to\n\t * XMLHttpRequest object or JSONP and deals with browser incompatibilities.\n\t *\n\t * You should never need to use this service directly, instead use the higher-level abstractions:\n\t * {@link ng.$http $http} or {@link ngResource.$resource $resource}.\n\t *\n\t * During testing this implementation is swapped with {@link ngMock.$httpBackend mock\n\t * $httpBackend} which can be trained with responses.\n\t */\n\tfunction $HttpBackendProvider() {\n\t this.$get = ['$browser', '$window', '$document', '$xhrFactory', function($browser, $window, $document, $xhrFactory) {\n\t return createHttpBackend($browser, $xhrFactory, $browser.defer, $window.angular.callbacks, $document[0]);\n\t }];\n\t}\n\t\n\tfunction createHttpBackend($browser, createXhr, $browserDefer, callbacks, rawDocument) {\n\t // TODO(vojta): fix the signature\n\t return function(method, url, post, callback, headers, timeout, withCredentials, responseType) {\n\t $browser.$$incOutstandingRequestCount();\n\t url = url || $browser.url();\n\t\n\t if (lowercase(method) == 'jsonp') {\n\t var callbackId = '_' + (callbacks.counter++).toString(36);\n\t callbacks[callbackId] = function(data) {\n\t callbacks[callbackId].data = data;\n\t callbacks[callbackId].called = true;\n\t };\n\t\n\t var jsonpDone = jsonpReq(url.replace('JSON_CALLBACK', 'angular.callbacks.' + callbackId),\n\t callbackId, function(status, text) {\n\t completeRequest(callback, status, callbacks[callbackId].data, \"\", text);\n\t callbacks[callbackId] = noop;\n\t });\n\t } else {\n\t\n\t var xhr = createXhr(method, url);\n\t\n\t xhr.open(method, url, true);\n\t forEach(headers, function(value, key) {\n\t if (isDefined(value)) {\n\t xhr.setRequestHeader(key, value);\n\t }\n\t });\n\t\n\t xhr.onload = function requestLoaded() {\n\t var statusText = xhr.statusText || '';\n\t\n\t // responseText is the old-school way of retrieving response (supported by IE9)\n\t // response/responseType properties were introduced in XHR Level2 spec (supported by IE10)\n\t var response = ('response' in xhr) ? xhr.response : xhr.responseText;\n\t\n\t // normalize IE9 bug (http://bugs.jquery.com/ticket/1450)\n\t var status = xhr.status === 1223 ? 204 : xhr.status;\n\t\n\t // fix status code when it is 0 (0 status is undocumented).\n\t // Occurs when accessing file resources or on Android 4.1 stock browser\n\t // while retrieving files from application cache.\n\t if (status === 0) {\n\t status = response ? 200 : urlResolve(url).protocol == 'file' ? 404 : 0;\n\t }\n\t\n\t completeRequest(callback,\n\t status,\n\t response,\n\t xhr.getAllResponseHeaders(),\n\t statusText);\n\t };\n\t\n\t var requestError = function() {\n\t // The response is always empty\n\t // See https://xhr.spec.whatwg.org/#request-error-steps and https://fetch.spec.whatwg.org/#concept-network-error\n\t completeRequest(callback, -1, null, null, '');\n\t };\n\t\n\t xhr.onerror = requestError;\n\t xhr.onabort = requestError;\n\t\n\t if (withCredentials) {\n\t xhr.withCredentials = true;\n\t }\n\t\n\t if (responseType) {\n\t try {\n\t xhr.responseType = responseType;\n\t } catch (e) {\n\t // WebKit added support for the json responseType value on 09/03/2013\n\t // https://bugs.webkit.org/show_bug.cgi?id=73648. Versions of Safari prior to 7 are\n\t // known to throw when setting the value \"json\" as the response type. Other older\n\t // browsers implementing the responseType\n\t //\n\t // The json response type can be ignored if not supported, because JSON payloads are\n\t // parsed on the client-side regardless.\n\t if (responseType !== 'json') {\n\t throw e;\n\t }\n\t }\n\t }\n\t\n\t xhr.send(isUndefined(post) ? null : post);\n\t }\n\t\n\t if (timeout > 0) {\n\t var timeoutId = $browserDefer(timeoutRequest, timeout);\n\t } else if (isPromiseLike(timeout)) {\n\t timeout.then(timeoutRequest);\n\t }\n\t\n\t\n\t function timeoutRequest() {\n\t jsonpDone && jsonpDone();\n\t xhr && xhr.abort();\n\t }\n\t\n\t function completeRequest(callback, status, response, headersString, statusText) {\n\t // cancel timeout and subsequent timeout promise resolution\n\t if (isDefined(timeoutId)) {\n\t $browserDefer.cancel(timeoutId);\n\t }\n\t jsonpDone = xhr = null;\n\t\n\t callback(status, response, headersString, statusText);\n\t $browser.$$completeOutstandingRequest(noop);\n\t }\n\t };\n\t\n\t function jsonpReq(url, callbackId, done) {\n\t // we can't use jQuery/jqLite here because jQuery does crazy stuff with script elements, e.g.:\n\t // - fetches local scripts via XHR and evals them\n\t // - adds and immediately removes script elements from the document\n\t var script = rawDocument.createElement('script'), callback = null;\n\t script.type = \"text/javascript\";\n\t script.src = url;\n\t script.async = true;\n\t\n\t callback = function(event) {\n\t removeEventListenerFn(script, \"load\", callback);\n\t removeEventListenerFn(script, \"error\", callback);\n\t rawDocument.body.removeChild(script);\n\t script = null;\n\t var status = -1;\n\t var text = \"unknown\";\n\t\n\t if (event) {\n\t if (event.type === \"load\" && !callbacks[callbackId].called) {\n\t event = { type: \"error\" };\n\t }\n\t text = event.type;\n\t status = event.type === \"error\" ? 404 : 200;\n\t }\n\t\n\t if (done) {\n\t done(status, text);\n\t }\n\t };\n\t\n\t addEventListenerFn(script, \"load\", callback);\n\t addEventListenerFn(script, \"error\", callback);\n\t rawDocument.body.appendChild(script);\n\t return callback;\n\t }\n\t}\n\t\n\tvar $interpolateMinErr = angular.$interpolateMinErr = minErr('$interpolate');\n\t$interpolateMinErr.throwNoconcat = function(text) {\n\t throw $interpolateMinErr('noconcat',\n\t \"Error while interpolating: {0}\\nStrict Contextual Escaping disallows \" +\n\t \"interpolations that concatenate multiple expressions when a trusted value is \" +\n\t \"required. See http://docs.angularjs.org/api/ng.$sce\", text);\n\t};\n\t\n\t$interpolateMinErr.interr = function(text, err) {\n\t return $interpolateMinErr('interr', \"Can't interpolate: {0}\\n{1}\", text, err.toString());\n\t};\n\t\n\t/**\n\t * @ngdoc provider\n\t * @name $interpolateProvider\n\t *\n\t * @description\n\t *\n\t * Used for configuring the interpolation markup. Defaults to `{{` and `}}`.\n\t *\n\t * @example\n\t\n\t\n\t\n\t
\n\t //demo.label//\n\t
\n\t
\n\t\n\t it('should interpolate binding with custom symbols', function() {\n\t expect(element(by.binding('demo.label')).getText()).toBe('This binding is brought you by // interpolation symbols.');\n\t });\n\t\n\t
\n\t */\n\tfunction $InterpolateProvider() {\n\t var startSymbol = '{{';\n\t var endSymbol = '}}';\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $interpolateProvider#startSymbol\n\t * @description\n\t * Symbol to denote start of expression in the interpolated string. Defaults to `{{`.\n\t *\n\t * @param {string=} value new value to set the starting symbol to.\n\t * @returns {string|self} Returns the symbol when used as getter and self if used as setter.\n\t */\n\t this.startSymbol = function(value) {\n\t if (value) {\n\t startSymbol = value;\n\t return this;\n\t } else {\n\t return startSymbol;\n\t }\n\t };\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $interpolateProvider#endSymbol\n\t * @description\n\t * Symbol to denote the end of expression in the interpolated string. Defaults to `}}`.\n\t *\n\t * @param {string=} value new value to set the ending symbol to.\n\t * @returns {string|self} Returns the symbol when used as getter and self if used as setter.\n\t */\n\t this.endSymbol = function(value) {\n\t if (value) {\n\t endSymbol = value;\n\t return this;\n\t } else {\n\t return endSymbol;\n\t }\n\t };\n\t\n\t\n\t this.$get = ['$parse', '$exceptionHandler', '$sce', function($parse, $exceptionHandler, $sce) {\n\t var startSymbolLength = startSymbol.length,\n\t endSymbolLength = endSymbol.length,\n\t escapedStartRegexp = new RegExp(startSymbol.replace(/./g, escape), 'g'),\n\t escapedEndRegexp = new RegExp(endSymbol.replace(/./g, escape), 'g');\n\t\n\t function escape(ch) {\n\t return '\\\\\\\\\\\\' + ch;\n\t }\n\t\n\t function unescapeText(text) {\n\t return text.replace(escapedStartRegexp, startSymbol).\n\t replace(escapedEndRegexp, endSymbol);\n\t }\n\t\n\t function stringify(value) {\n\t if (value == null) { // null || undefined\n\t return '';\n\t }\n\t switch (typeof value) {\n\t case 'string':\n\t break;\n\t case 'number':\n\t value = '' + value;\n\t break;\n\t default:\n\t value = toJson(value);\n\t }\n\t\n\t return value;\n\t }\n\t\n\t /**\n\t * @ngdoc service\n\t * @name $interpolate\n\t * @kind function\n\t *\n\t * @requires $parse\n\t * @requires $sce\n\t *\n\t * @description\n\t *\n\t * Compiles a string with markup into an interpolation function. This service is used by the\n\t * HTML {@link ng.$compile $compile} service for data binding. See\n\t * {@link ng.$interpolateProvider $interpolateProvider} for configuring the\n\t * interpolation markup.\n\t *\n\t *\n\t * ```js\n\t * var $interpolate = ...; // injected\n\t * var exp = $interpolate('Hello {{name | uppercase}}!');\n\t * expect(exp({name:'Angular'})).toEqual('Hello ANGULAR!');\n\t * ```\n\t *\n\t * `$interpolate` takes an optional fourth argument, `allOrNothing`. If `allOrNothing` is\n\t * `true`, the interpolation function will return `undefined` unless all embedded expressions\n\t * evaluate to a value other than `undefined`.\n\t *\n\t * ```js\n\t * var $interpolate = ...; // injected\n\t * var context = {greeting: 'Hello', name: undefined };\n\t *\n\t * // default \"forgiving\" mode\n\t * var exp = $interpolate('{{greeting}} {{name}}!');\n\t * expect(exp(context)).toEqual('Hello !');\n\t *\n\t * // \"allOrNothing\" mode\n\t * exp = $interpolate('{{greeting}} {{name}}!', false, null, true);\n\t * expect(exp(context)).toBeUndefined();\n\t * context.name = 'Angular';\n\t * expect(exp(context)).toEqual('Hello Angular!');\n\t * ```\n\t *\n\t * `allOrNothing` is useful for interpolating URLs. `ngSrc` and `ngSrcset` use this behavior.\n\t *\n\t * ####Escaped Interpolation\n\t * $interpolate provides a mechanism for escaping interpolation markers. Start and end markers\n\t * can be escaped by preceding each of their characters with a REVERSE SOLIDUS U+005C (backslash).\n\t * It will be rendered as a regular start/end marker, and will not be interpreted as an expression\n\t * or binding.\n\t *\n\t * This enables web-servers to prevent script injection attacks and defacing attacks, to some\n\t * degree, while also enabling code examples to work without relying on the\n\t * {@link ng.directive:ngNonBindable ngNonBindable} directive.\n\t *\n\t * **For security purposes, it is strongly encouraged that web servers escape user-supplied data,\n\t * replacing angle brackets (<, >) with &lt; and &gt; respectively, and replacing all\n\t * interpolation start/end markers with their escaped counterparts.**\n\t *\n\t * Escaped interpolation markers are only replaced with the actual interpolation markers in rendered\n\t * output when the $interpolate service processes the text. So, for HTML elements interpolated\n\t * by {@link ng.$compile $compile}, or otherwise interpolated with the `mustHaveExpression` parameter\n\t * set to `true`, the interpolated text must contain an unescaped interpolation expression. As such,\n\t * this is typically useful only when user-data is used in rendering a template from the server, or\n\t * when otherwise untrusted data is used by a directive.\n\t *\n\t * \n\t * \n\t *
\n\t *

{{apptitle}}: \\{\\{ username = \"defaced value\"; \\}\\}\n\t *

\n\t *

{{username}} attempts to inject code which will deface the\n\t * application, but fails to accomplish their task, because the server has correctly\n\t * escaped the interpolation start/end markers with REVERSE SOLIDUS U+005C (backslash)\n\t * characters.

\n\t *

Instead, the result of the attempted script injection is visible, and can be removed\n\t * from the database by an administrator.

\n\t *
\n\t *
\n\t *
\n\t *\n\t * @knownIssue\n\t * It is currently not possible for an interpolated expression to contain the interpolation end\n\t * symbol. For example, `{{ '}}' }}` will be incorrectly interpreted as `{{ ' }}` + `' }}`, i.e.\n\t * an interpolated expression consisting of a single-quote (`'`) and the `' }}` string.\n\t *\n\t * @param {string} text The text with markup to interpolate.\n\t * @param {boolean=} mustHaveExpression if set to true then the interpolation string must have\n\t * embedded expression in order to return an interpolation function. Strings with no\n\t * embedded expression will return null for the interpolation function.\n\t * @param {string=} trustedContext when provided, the returned function passes the interpolated\n\t * result through {@link ng.$sce#getTrusted $sce.getTrusted(interpolatedResult,\n\t * trustedContext)} before returning it. Refer to the {@link ng.$sce $sce} service that\n\t * provides Strict Contextual Escaping for details.\n\t * @param {boolean=} allOrNothing if `true`, then the returned function returns undefined\n\t * unless all embedded expressions evaluate to a value other than `undefined`.\n\t * @returns {function(context)} an interpolation function which is used to compute the\n\t * interpolated string. The function has these parameters:\n\t *\n\t * - `context`: evaluation context for all expressions embedded in the interpolated text\n\t */\n\t function $interpolate(text, mustHaveExpression, trustedContext, allOrNothing) {\n\t allOrNothing = !!allOrNothing;\n\t var startIndex,\n\t endIndex,\n\t index = 0,\n\t expressions = [],\n\t parseFns = [],\n\t textLength = text.length,\n\t exp,\n\t concat = [],\n\t expressionPositions = [];\n\t\n\t while (index < textLength) {\n\t if (((startIndex = text.indexOf(startSymbol, index)) != -1) &&\n\t ((endIndex = text.indexOf(endSymbol, startIndex + startSymbolLength)) != -1)) {\n\t if (index !== startIndex) {\n\t concat.push(unescapeText(text.substring(index, startIndex)));\n\t }\n\t exp = text.substring(startIndex + startSymbolLength, endIndex);\n\t expressions.push(exp);\n\t parseFns.push($parse(exp, parseStringifyInterceptor));\n\t index = endIndex + endSymbolLength;\n\t expressionPositions.push(concat.length);\n\t concat.push('');\n\t } else {\n\t // we did not find an interpolation, so we have to add the remainder to the separators array\n\t if (index !== textLength) {\n\t concat.push(unescapeText(text.substring(index)));\n\t }\n\t break;\n\t }\n\t }\n\t\n\t // Concatenating expressions makes it hard to reason about whether some combination of\n\t // concatenated values are unsafe to use and could easily lead to XSS. By requiring that a\n\t // single expression be used for iframe[src], object[src], etc., we ensure that the value\n\t // that's used is assigned or constructed by some JS code somewhere that is more testable or\n\t // make it obvious that you bound the value to some user controlled value. This helps reduce\n\t // the load when auditing for XSS issues.\n\t if (trustedContext && concat.length > 1) {\n\t $interpolateMinErr.throwNoconcat(text);\n\t }\n\t\n\t if (!mustHaveExpression || expressions.length) {\n\t var compute = function(values) {\n\t for (var i = 0, ii = expressions.length; i < ii; i++) {\n\t if (allOrNothing && isUndefined(values[i])) return;\n\t concat[expressionPositions[i]] = values[i];\n\t }\n\t return concat.join('');\n\t };\n\t\n\t var getValue = function(value) {\n\t return trustedContext ?\n\t $sce.getTrusted(trustedContext, value) :\n\t $sce.valueOf(value);\n\t };\n\t\n\t return extend(function interpolationFn(context) {\n\t var i = 0;\n\t var ii = expressions.length;\n\t var values = new Array(ii);\n\t\n\t try {\n\t for (; i < ii; i++) {\n\t values[i] = parseFns[i](context);\n\t }\n\t\n\t return compute(values);\n\t } catch (err) {\n\t $exceptionHandler($interpolateMinErr.interr(text, err));\n\t }\n\t\n\t }, {\n\t // all of these properties are undocumented for now\n\t exp: text, //just for compatibility with regular watchers created via $watch\n\t expressions: expressions,\n\t $$watchDelegate: function(scope, listener) {\n\t var lastValue;\n\t return scope.$watchGroup(parseFns, function interpolateFnWatcher(values, oldValues) {\n\t var currValue = compute(values);\n\t if (isFunction(listener)) {\n\t listener.call(this, currValue, values !== oldValues ? lastValue : currValue, scope);\n\t }\n\t lastValue = currValue;\n\t });\n\t }\n\t });\n\t }\n\t\n\t function parseStringifyInterceptor(value) {\n\t try {\n\t value = getValue(value);\n\t return allOrNothing && !isDefined(value) ? value : stringify(value);\n\t } catch (err) {\n\t $exceptionHandler($interpolateMinErr.interr(text, err));\n\t }\n\t }\n\t }\n\t\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $interpolate#startSymbol\n\t * @description\n\t * Symbol to denote the start of expression in the interpolated string. Defaults to `{{`.\n\t *\n\t * Use {@link ng.$interpolateProvider#startSymbol `$interpolateProvider.startSymbol`} to change\n\t * the symbol.\n\t *\n\t * @returns {string} start symbol.\n\t */\n\t $interpolate.startSymbol = function() {\n\t return startSymbol;\n\t };\n\t\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $interpolate#endSymbol\n\t * @description\n\t * Symbol to denote the end of expression in the interpolated string. Defaults to `}}`.\n\t *\n\t * Use {@link ng.$interpolateProvider#endSymbol `$interpolateProvider.endSymbol`} to change\n\t * the symbol.\n\t *\n\t * @returns {string} end symbol.\n\t */\n\t $interpolate.endSymbol = function() {\n\t return endSymbol;\n\t };\n\t\n\t return $interpolate;\n\t }];\n\t}\n\t\n\tfunction $IntervalProvider() {\n\t this.$get = ['$rootScope', '$window', '$q', '$$q',\n\t function($rootScope, $window, $q, $$q) {\n\t var intervals = {};\n\t\n\t\n\t /**\n\t * @ngdoc service\n\t * @name $interval\n\t *\n\t * @description\n\t * Angular's wrapper for `window.setInterval`. The `fn` function is executed every `delay`\n\t * milliseconds.\n\t *\n\t * The return value of registering an interval function is a promise. This promise will be\n\t * notified upon each tick of the interval, and will be resolved after `count` iterations, or\n\t * run indefinitely if `count` is not defined. The value of the notification will be the\n\t * number of iterations that have run.\n\t * To cancel an interval, call `$interval.cancel(promise)`.\n\t *\n\t * In tests you can use {@link ngMock.$interval#flush `$interval.flush(millis)`} to\n\t * move forward by `millis` milliseconds and trigger any functions scheduled to run in that\n\t * time.\n\t *\n\t *
\n\t * **Note**: Intervals created by this service must be explicitly destroyed when you are finished\n\t * with them. In particular they are not automatically destroyed when a controller's scope or a\n\t * directive's element are destroyed.\n\t * You should take this into consideration and make sure to always cancel the interval at the\n\t * appropriate moment. See the example below for more details on how and when to do this.\n\t *
\n\t *\n\t * @param {function()} fn A function that should be called repeatedly.\n\t * @param {number} delay Number of milliseconds between each function call.\n\t * @param {number=} [count=0] Number of times to repeat. If not set, or 0, will repeat\n\t * indefinitely.\n\t * @param {boolean=} [invokeApply=true] If set to `false` skips model dirty checking, otherwise\n\t * will invoke `fn` within the {@link ng.$rootScope.Scope#$apply $apply} block.\n\t * @param {...*=} Pass additional parameters to the executed function.\n\t * @returns {promise} A promise which will be notified on each iteration.\n\t *\n\t * @example\n\t * \n\t * \n\t * \n\t *\n\t *
\n\t *
\n\t *
\n\t * Current time is: \n\t *
\n\t * Blood 1 : {{blood_1}}\n\t * Blood 2 : {{blood_2}}\n\t * \n\t * \n\t * \n\t *
\n\t *
\n\t *\n\t *
\n\t *
\n\t */\n\t function interval(fn, delay, count, invokeApply) {\n\t var hasParams = arguments.length > 4,\n\t args = hasParams ? sliceArgs(arguments, 4) : [],\n\t setInterval = $window.setInterval,\n\t clearInterval = $window.clearInterval,\n\t iteration = 0,\n\t skipApply = (isDefined(invokeApply) && !invokeApply),\n\t deferred = (skipApply ? $$q : $q).defer(),\n\t promise = deferred.promise;\n\t\n\t count = isDefined(count) ? count : 0;\n\t\n\t promise.then(null, null, (!hasParams) ? fn : function() {\n\t fn.apply(null, args);\n\t });\n\t\n\t promise.$$intervalId = setInterval(function tick() {\n\t deferred.notify(iteration++);\n\t\n\t if (count > 0 && iteration >= count) {\n\t deferred.resolve(iteration);\n\t clearInterval(promise.$$intervalId);\n\t delete intervals[promise.$$intervalId];\n\t }\n\t\n\t if (!skipApply) $rootScope.$apply();\n\t\n\t }, delay);\n\t\n\t intervals[promise.$$intervalId] = deferred;\n\t\n\t return promise;\n\t }\n\t\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $interval#cancel\n\t *\n\t * @description\n\t * Cancels a task associated with the `promise`.\n\t *\n\t * @param {Promise=} promise returned by the `$interval` function.\n\t * @returns {boolean} Returns `true` if the task was successfully canceled.\n\t */\n\t interval.cancel = function(promise) {\n\t if (promise && promise.$$intervalId in intervals) {\n\t intervals[promise.$$intervalId].reject('canceled');\n\t $window.clearInterval(promise.$$intervalId);\n\t delete intervals[promise.$$intervalId];\n\t return true;\n\t }\n\t return false;\n\t };\n\t\n\t return interval;\n\t }];\n\t}\n\t\n\t/**\n\t * @ngdoc service\n\t * @name $locale\n\t *\n\t * @description\n\t * $locale service provides localization rules for various Angular components. As of right now the\n\t * only public api is:\n\t *\n\t * * `id` – `{string}` – locale id formatted as `languageId-countryId` (e.g. `en-us`)\n\t */\n\t\n\tvar PATH_MATCH = /^([^\\?#]*)(\\?([^#]*))?(#(.*))?$/,\n\t DEFAULT_PORTS = {'http': 80, 'https': 443, 'ftp': 21};\n\tvar $locationMinErr = minErr('$location');\n\t\n\t\n\t/**\n\t * Encode path using encodeUriSegment, ignoring forward slashes\n\t *\n\t * @param {string} path Path to encode\n\t * @returns {string}\n\t */\n\tfunction encodePath(path) {\n\t var segments = path.split('/'),\n\t i = segments.length;\n\t\n\t while (i--) {\n\t segments[i] = encodeUriSegment(segments[i]);\n\t }\n\t\n\t return segments.join('/');\n\t}\n\t\n\tfunction parseAbsoluteUrl(absoluteUrl, locationObj) {\n\t var parsedUrl = urlResolve(absoluteUrl);\n\t\n\t locationObj.$$protocol = parsedUrl.protocol;\n\t locationObj.$$host = parsedUrl.hostname;\n\t locationObj.$$port = toInt(parsedUrl.port) || DEFAULT_PORTS[parsedUrl.protocol] || null;\n\t}\n\t\n\t\n\tfunction parseAppUrl(relativeUrl, locationObj) {\n\t var prefixed = (relativeUrl.charAt(0) !== '/');\n\t if (prefixed) {\n\t relativeUrl = '/' + relativeUrl;\n\t }\n\t var match = urlResolve(relativeUrl);\n\t locationObj.$$path = decodeURIComponent(prefixed && match.pathname.charAt(0) === '/' ?\n\t match.pathname.substring(1) : match.pathname);\n\t locationObj.$$search = parseKeyValue(match.search);\n\t locationObj.$$hash = decodeURIComponent(match.hash);\n\t\n\t // make sure path starts with '/';\n\t if (locationObj.$$path && locationObj.$$path.charAt(0) != '/') {\n\t locationObj.$$path = '/' + locationObj.$$path;\n\t }\n\t}\n\t\n\t\n\t/**\n\t *\n\t * @param {string} begin\n\t * @param {string} whole\n\t * @returns {string} returns text from whole after begin or undefined if it does not begin with\n\t * expected string.\n\t */\n\tfunction beginsWith(begin, whole) {\n\t if (whole.indexOf(begin) === 0) {\n\t return whole.substr(begin.length);\n\t }\n\t}\n\t\n\t\n\tfunction stripHash(url) {\n\t var index = url.indexOf('#');\n\t return index == -1 ? url : url.substr(0, index);\n\t}\n\t\n\tfunction trimEmptyHash(url) {\n\t return url.replace(/(#.+)|#$/, '$1');\n\t}\n\t\n\t\n\tfunction stripFile(url) {\n\t return url.substr(0, stripHash(url).lastIndexOf('/') + 1);\n\t}\n\t\n\t/* return the server only (scheme://host:port) */\n\tfunction serverBase(url) {\n\t return url.substring(0, url.indexOf('/', url.indexOf('//') + 2));\n\t}\n\t\n\t\n\t/**\n\t * LocationHtml5Url represents an url\n\t * This object is exposed as $location service when HTML5 mode is enabled and supported\n\t *\n\t * @constructor\n\t * @param {string} appBase application base URL\n\t * @param {string} appBaseNoFile application base URL stripped of any filename\n\t * @param {string} basePrefix url path prefix\n\t */\n\tfunction LocationHtml5Url(appBase, appBaseNoFile, basePrefix) {\n\t this.$$html5 = true;\n\t basePrefix = basePrefix || '';\n\t parseAbsoluteUrl(appBase, this);\n\t\n\t\n\t /**\n\t * Parse given html5 (regular) url string into properties\n\t * @param {string} url HTML5 url\n\t * @private\n\t */\n\t this.$$parse = function(url) {\n\t var pathUrl = beginsWith(appBaseNoFile, url);\n\t if (!isString(pathUrl)) {\n\t throw $locationMinErr('ipthprfx', 'Invalid url \"{0}\", missing path prefix \"{1}\".', url,\n\t appBaseNoFile);\n\t }\n\t\n\t parseAppUrl(pathUrl, this);\n\t\n\t if (!this.$$path) {\n\t this.$$path = '/';\n\t }\n\t\n\t this.$$compose();\n\t };\n\t\n\t /**\n\t * Compose url and update `absUrl` property\n\t * @private\n\t */\n\t this.$$compose = function() {\n\t var search = toKeyValue(this.$$search),\n\t hash = this.$$hash ? '#' + encodeUriSegment(this.$$hash) : '';\n\t\n\t this.$$url = encodePath(this.$$path) + (search ? '?' + search : '') + hash;\n\t this.$$absUrl = appBaseNoFile + this.$$url.substr(1); // first char is always '/'\n\t };\n\t\n\t this.$$parseLinkUrl = function(url, relHref) {\n\t if (relHref && relHref[0] === '#') {\n\t // special case for links to hash fragments:\n\t // keep the old url and only replace the hash fragment\n\t this.hash(relHref.slice(1));\n\t return true;\n\t }\n\t var appUrl, prevAppUrl;\n\t var rewrittenUrl;\n\t\n\t if (isDefined(appUrl = beginsWith(appBase, url))) {\n\t prevAppUrl = appUrl;\n\t if (isDefined(appUrl = beginsWith(basePrefix, appUrl))) {\n\t rewrittenUrl = appBaseNoFile + (beginsWith('/', appUrl) || appUrl);\n\t } else {\n\t rewrittenUrl = appBase + prevAppUrl;\n\t }\n\t } else if (isDefined(appUrl = beginsWith(appBaseNoFile, url))) {\n\t rewrittenUrl = appBaseNoFile + appUrl;\n\t } else if (appBaseNoFile == url + '/') {\n\t rewrittenUrl = appBaseNoFile;\n\t }\n\t if (rewrittenUrl) {\n\t this.$$parse(rewrittenUrl);\n\t }\n\t return !!rewrittenUrl;\n\t };\n\t}\n\t\n\t\n\t/**\n\t * LocationHashbangUrl represents url\n\t * This object is exposed as $location service when developer doesn't opt into html5 mode.\n\t * It also serves as the base class for html5 mode fallback on legacy browsers.\n\t *\n\t * @constructor\n\t * @param {string} appBase application base URL\n\t * @param {string} appBaseNoFile application base URL stripped of any filename\n\t * @param {string} hashPrefix hashbang prefix\n\t */\n\tfunction LocationHashbangUrl(appBase, appBaseNoFile, hashPrefix) {\n\t\n\t parseAbsoluteUrl(appBase, this);\n\t\n\t\n\t /**\n\t * Parse given hashbang url into properties\n\t * @param {string} url Hashbang url\n\t * @private\n\t */\n\t this.$$parse = function(url) {\n\t var withoutBaseUrl = beginsWith(appBase, url) || beginsWith(appBaseNoFile, url);\n\t var withoutHashUrl;\n\t\n\t if (!isUndefined(withoutBaseUrl) && withoutBaseUrl.charAt(0) === '#') {\n\t\n\t // The rest of the url starts with a hash so we have\n\t // got either a hashbang path or a plain hash fragment\n\t withoutHashUrl = beginsWith(hashPrefix, withoutBaseUrl);\n\t if (isUndefined(withoutHashUrl)) {\n\t // There was no hashbang prefix so we just have a hash fragment\n\t withoutHashUrl = withoutBaseUrl;\n\t }\n\t\n\t } else {\n\t // There was no hashbang path nor hash fragment:\n\t // If we are in HTML5 mode we use what is left as the path;\n\t // Otherwise we ignore what is left\n\t if (this.$$html5) {\n\t withoutHashUrl = withoutBaseUrl;\n\t } else {\n\t withoutHashUrl = '';\n\t if (isUndefined(withoutBaseUrl)) {\n\t appBase = url;\n\t this.replace();\n\t }\n\t }\n\t }\n\t\n\t parseAppUrl(withoutHashUrl, this);\n\t\n\t this.$$path = removeWindowsDriveName(this.$$path, withoutHashUrl, appBase);\n\t\n\t this.$$compose();\n\t\n\t /*\n\t * In Windows, on an anchor node on documents loaded from\n\t * the filesystem, the browser will return a pathname\n\t * prefixed with the drive name ('/C:/path') when a\n\t * pathname without a drive is set:\n\t * * a.setAttribute('href', '/foo')\n\t * * a.pathname === '/C:/foo' //true\n\t *\n\t * Inside of Angular, we're always using pathnames that\n\t * do not include drive names for routing.\n\t */\n\t function removeWindowsDriveName(path, url, base) {\n\t /*\n\t Matches paths for file protocol on windows,\n\t such as /C:/foo/bar, and captures only /foo/bar.\n\t */\n\t var windowsFilePathExp = /^\\/[A-Z]:(\\/.*)/;\n\t\n\t var firstPathSegmentMatch;\n\t\n\t //Get the relative path from the input URL.\n\t if (url.indexOf(base) === 0) {\n\t url = url.replace(base, '');\n\t }\n\t\n\t // The input URL intentionally contains a first path segment that ends with a colon.\n\t if (windowsFilePathExp.exec(url)) {\n\t return path;\n\t }\n\t\n\t firstPathSegmentMatch = windowsFilePathExp.exec(path);\n\t return firstPathSegmentMatch ? firstPathSegmentMatch[1] : path;\n\t }\n\t };\n\t\n\t /**\n\t * Compose hashbang url and update `absUrl` property\n\t * @private\n\t */\n\t this.$$compose = function() {\n\t var search = toKeyValue(this.$$search),\n\t hash = this.$$hash ? '#' + encodeUriSegment(this.$$hash) : '';\n\t\n\t this.$$url = encodePath(this.$$path) + (search ? '?' + search : '') + hash;\n\t this.$$absUrl = appBase + (this.$$url ? hashPrefix + this.$$url : '');\n\t };\n\t\n\t this.$$parseLinkUrl = function(url, relHref) {\n\t if (stripHash(appBase) == stripHash(url)) {\n\t this.$$parse(url);\n\t return true;\n\t }\n\t return false;\n\t };\n\t}\n\t\n\t\n\t/**\n\t * LocationHashbangUrl represents url\n\t * This object is exposed as $location service when html5 history api is enabled but the browser\n\t * does not support it.\n\t *\n\t * @constructor\n\t * @param {string} appBase application base URL\n\t * @param {string} appBaseNoFile application base URL stripped of any filename\n\t * @param {string} hashPrefix hashbang prefix\n\t */\n\tfunction LocationHashbangInHtml5Url(appBase, appBaseNoFile, hashPrefix) {\n\t this.$$html5 = true;\n\t LocationHashbangUrl.apply(this, arguments);\n\t\n\t this.$$parseLinkUrl = function(url, relHref) {\n\t if (relHref && relHref[0] === '#') {\n\t // special case for links to hash fragments:\n\t // keep the old url and only replace the hash fragment\n\t this.hash(relHref.slice(1));\n\t return true;\n\t }\n\t\n\t var rewrittenUrl;\n\t var appUrl;\n\t\n\t if (appBase == stripHash(url)) {\n\t rewrittenUrl = url;\n\t } else if ((appUrl = beginsWith(appBaseNoFile, url))) {\n\t rewrittenUrl = appBase + hashPrefix + appUrl;\n\t } else if (appBaseNoFile === url + '/') {\n\t rewrittenUrl = appBaseNoFile;\n\t }\n\t if (rewrittenUrl) {\n\t this.$$parse(rewrittenUrl);\n\t }\n\t return !!rewrittenUrl;\n\t };\n\t\n\t this.$$compose = function() {\n\t var search = toKeyValue(this.$$search),\n\t hash = this.$$hash ? '#' + encodeUriSegment(this.$$hash) : '';\n\t\n\t this.$$url = encodePath(this.$$path) + (search ? '?' + search : '') + hash;\n\t // include hashPrefix in $$absUrl when $$url is empty so IE9 does not reload page because of removal of '#'\n\t this.$$absUrl = appBase + hashPrefix + this.$$url;\n\t };\n\t\n\t}\n\t\n\t\n\tvar locationPrototype = {\n\t\n\t /**\n\t * Are we in html5 mode?\n\t * @private\n\t */\n\t $$html5: false,\n\t\n\t /**\n\t * Has any change been replacing?\n\t * @private\n\t */\n\t $$replace: false,\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $location#absUrl\n\t *\n\t * @description\n\t * This method is getter only.\n\t *\n\t * Return full url representation with all segments encoded according to rules specified in\n\t * [RFC 3986](http://www.ietf.org/rfc/rfc3986.txt).\n\t *\n\t *\n\t * ```js\n\t * // given url http://example.com/#/some/path?foo=bar&baz=xoxo\n\t * var absUrl = $location.absUrl();\n\t * // => \"http://example.com/#/some/path?foo=bar&baz=xoxo\"\n\t * ```\n\t *\n\t * @return {string} full url\n\t */\n\t absUrl: locationGetter('$$absUrl'),\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $location#url\n\t *\n\t * @description\n\t * This method is getter / setter.\n\t *\n\t * Return url (e.g. `/path?a=b#hash`) when called without any parameter.\n\t *\n\t * Change path, search and hash, when called with parameter and return `$location`.\n\t *\n\t *\n\t * ```js\n\t * // given url http://example.com/#/some/path?foo=bar&baz=xoxo\n\t * var url = $location.url();\n\t * // => \"/some/path?foo=bar&baz=xoxo\"\n\t * ```\n\t *\n\t * @param {string=} url New url without base prefix (e.g. `/path?a=b#hash`)\n\t * @return {string} url\n\t */\n\t url: function(url) {\n\t if (isUndefined(url)) {\n\t return this.$$url;\n\t }\n\t\n\t var match = PATH_MATCH.exec(url);\n\t if (match[1] || url === '') this.path(decodeURIComponent(match[1]));\n\t if (match[2] || match[1] || url === '') this.search(match[3] || '');\n\t this.hash(match[5] || '');\n\t\n\t return this;\n\t },\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $location#protocol\n\t *\n\t * @description\n\t * This method is getter only.\n\t *\n\t * Return protocol of current url.\n\t *\n\t *\n\t * ```js\n\t * // given url http://example.com/#/some/path?foo=bar&baz=xoxo\n\t * var protocol = $location.protocol();\n\t * // => \"http\"\n\t * ```\n\t *\n\t * @return {string} protocol of current url\n\t */\n\t protocol: locationGetter('$$protocol'),\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $location#host\n\t *\n\t * @description\n\t * This method is getter only.\n\t *\n\t * Return host of current url.\n\t *\n\t * Note: compared to the non-angular version `location.host` which returns `hostname:port`, this returns the `hostname` portion only.\n\t *\n\t *\n\t * ```js\n\t * // given url http://example.com/#/some/path?foo=bar&baz=xoxo\n\t * var host = $location.host();\n\t * // => \"example.com\"\n\t *\n\t * // given url http://user:password@example.com:8080/#/some/path?foo=bar&baz=xoxo\n\t * host = $location.host();\n\t * // => \"example.com\"\n\t * host = location.host;\n\t * // => \"example.com:8080\"\n\t * ```\n\t *\n\t * @return {string} host of current url.\n\t */\n\t host: locationGetter('$$host'),\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $location#port\n\t *\n\t * @description\n\t * This method is getter only.\n\t *\n\t * Return port of current url.\n\t *\n\t *\n\t * ```js\n\t * // given url http://example.com/#/some/path?foo=bar&baz=xoxo\n\t * var port = $location.port();\n\t * // => 80\n\t * ```\n\t *\n\t * @return {Number} port\n\t */\n\t port: locationGetter('$$port'),\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $location#path\n\t *\n\t * @description\n\t * This method is getter / setter.\n\t *\n\t * Return path of current url when called without any parameter.\n\t *\n\t * Change path when called with parameter and return `$location`.\n\t *\n\t * Note: Path should always begin with forward slash (/), this method will add the forward slash\n\t * if it is missing.\n\t *\n\t *\n\t * ```js\n\t * // given url http://example.com/#/some/path?foo=bar&baz=xoxo\n\t * var path = $location.path();\n\t * // => \"/some/path\"\n\t * ```\n\t *\n\t * @param {(string|number)=} path New path\n\t * @return {(string|object)} path if called with no parameters, or `$location` if called with a parameter\n\t */\n\t path: locationGetterSetter('$$path', function(path) {\n\t path = path !== null ? path.toString() : '';\n\t return path.charAt(0) == '/' ? path : '/' + path;\n\t }),\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $location#search\n\t *\n\t * @description\n\t * This method is getter / setter.\n\t *\n\t * Return search part (as object) of current url when called without any parameter.\n\t *\n\t * Change search part when called with parameter and return `$location`.\n\t *\n\t *\n\t * ```js\n\t * // given url http://example.com/#/some/path?foo=bar&baz=xoxo\n\t * var searchObject = $location.search();\n\t * // => {foo: 'bar', baz: 'xoxo'}\n\t *\n\t * // set foo to 'yipee'\n\t * $location.search('foo', 'yipee');\n\t * // $location.search() => {foo: 'yipee', baz: 'xoxo'}\n\t * ```\n\t *\n\t * @param {string|Object.|Object.>} search New search params - string or\n\t * hash object.\n\t *\n\t * When called with a single argument the method acts as a setter, setting the `search` component\n\t * of `$location` to the specified value.\n\t *\n\t * If the argument is a hash object containing an array of values, these values will be encoded\n\t * as duplicate search parameters in the url.\n\t *\n\t * @param {(string|Number|Array|boolean)=} paramValue If `search` is a string or number, then `paramValue`\n\t * will override only a single search property.\n\t *\n\t * If `paramValue` is an array, it will override the property of the `search` component of\n\t * `$location` specified via the first argument.\n\t *\n\t * If `paramValue` is `null`, the property specified via the first argument will be deleted.\n\t *\n\t * If `paramValue` is `true`, the property specified via the first argument will be added with no\n\t * value nor trailing equal sign.\n\t *\n\t * @return {Object} If called with no arguments returns the parsed `search` object. If called with\n\t * one or more arguments returns `$location` object itself.\n\t */\n\t search: function(search, paramValue) {\n\t switch (arguments.length) {\n\t case 0:\n\t return this.$$search;\n\t case 1:\n\t if (isString(search) || isNumber(search)) {\n\t search = search.toString();\n\t this.$$search = parseKeyValue(search);\n\t } else if (isObject(search)) {\n\t search = copy(search, {});\n\t // remove object undefined or null properties\n\t forEach(search, function(value, key) {\n\t if (value == null) delete search[key];\n\t });\n\t\n\t this.$$search = search;\n\t } else {\n\t throw $locationMinErr('isrcharg',\n\t 'The first argument of the `$location#search()` call must be a string or an object.');\n\t }\n\t break;\n\t default:\n\t if (isUndefined(paramValue) || paramValue === null) {\n\t delete this.$$search[search];\n\t } else {\n\t this.$$search[search] = paramValue;\n\t }\n\t }\n\t\n\t this.$$compose();\n\t return this;\n\t },\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $location#hash\n\t *\n\t * @description\n\t * This method is getter / setter.\n\t *\n\t * Returns the hash fragment when called without any parameters.\n\t *\n\t * Changes the hash fragment when called with a parameter and returns `$location`.\n\t *\n\t *\n\t * ```js\n\t * // given url http://example.com/#/some/path?foo=bar&baz=xoxo#hashValue\n\t * var hash = $location.hash();\n\t * // => \"hashValue\"\n\t * ```\n\t *\n\t * @param {(string|number)=} hash New hash fragment\n\t * @return {string} hash\n\t */\n\t hash: locationGetterSetter('$$hash', function(hash) {\n\t return hash !== null ? hash.toString() : '';\n\t }),\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $location#replace\n\t *\n\t * @description\n\t * If called, all changes to $location during the current `$digest` will replace the current history\n\t * record, instead of adding a new one.\n\t */\n\t replace: function() {\n\t this.$$replace = true;\n\t return this;\n\t }\n\t};\n\t\n\tforEach([LocationHashbangInHtml5Url, LocationHashbangUrl, LocationHtml5Url], function(Location) {\n\t Location.prototype = Object.create(locationPrototype);\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $location#state\n\t *\n\t * @description\n\t * This method is getter / setter.\n\t *\n\t * Return the history state object when called without any parameter.\n\t *\n\t * Change the history state object when called with one parameter and return `$location`.\n\t * The state object is later passed to `pushState` or `replaceState`.\n\t *\n\t * NOTE: This method is supported only in HTML5 mode and only in browsers supporting\n\t * the HTML5 History API (i.e. methods `pushState` and `replaceState`). If you need to support\n\t * older browsers (like IE9 or Android < 4.0), don't use this method.\n\t *\n\t * @param {object=} state State object for pushState or replaceState\n\t * @return {object} state\n\t */\n\t Location.prototype.state = function(state) {\n\t if (!arguments.length) {\n\t return this.$$state;\n\t }\n\t\n\t if (Location !== LocationHtml5Url || !this.$$html5) {\n\t throw $locationMinErr('nostate', 'History API state support is available only ' +\n\t 'in HTML5 mode and only in browsers supporting HTML5 History API');\n\t }\n\t // The user might modify `stateObject` after invoking `$location.state(stateObject)`\n\t // but we're changing the $$state reference to $browser.state() during the $digest\n\t // so the modification window is narrow.\n\t this.$$state = isUndefined(state) ? null : state;\n\t\n\t return this;\n\t };\n\t});\n\t\n\t\n\tfunction locationGetter(property) {\n\t return function() {\n\t return this[property];\n\t };\n\t}\n\t\n\t\n\tfunction locationGetterSetter(property, preprocess) {\n\t return function(value) {\n\t if (isUndefined(value)) {\n\t return this[property];\n\t }\n\t\n\t this[property] = preprocess(value);\n\t this.$$compose();\n\t\n\t return this;\n\t };\n\t}\n\t\n\t\n\t/**\n\t * @ngdoc service\n\t * @name $location\n\t *\n\t * @requires $rootElement\n\t *\n\t * @description\n\t * The $location service parses the URL in the browser address bar (based on the\n\t * [window.location](https://developer.mozilla.org/en/window.location)) and makes the URL\n\t * available to your application. Changes to the URL in the address bar are reflected into\n\t * $location service and changes to $location are reflected into the browser address bar.\n\t *\n\t * **The $location service:**\n\t *\n\t * - Exposes the current URL in the browser address bar, so you can\n\t * - Watch and observe the URL.\n\t * - Change the URL.\n\t * - Synchronizes the URL with the browser when the user\n\t * - Changes the address bar.\n\t * - Clicks the back or forward button (or clicks a History link).\n\t * - Clicks on a link.\n\t * - Represents the URL object as a set of methods (protocol, host, port, path, search, hash).\n\t *\n\t * For more information see {@link guide/$location Developer Guide: Using $location}\n\t */\n\t\n\t/**\n\t * @ngdoc provider\n\t * @name $locationProvider\n\t * @description\n\t * Use the `$locationProvider` to configure how the application deep linking paths are stored.\n\t */\n\tfunction $LocationProvider() {\n\t var hashPrefix = '',\n\t html5Mode = {\n\t enabled: false,\n\t requireBase: true,\n\t rewriteLinks: true\n\t };\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $locationProvider#hashPrefix\n\t * @description\n\t * @param {string=} prefix Prefix for hash part (containing path and search)\n\t * @returns {*} current value if used as getter or itself (chaining) if used as setter\n\t */\n\t this.hashPrefix = function(prefix) {\n\t if (isDefined(prefix)) {\n\t hashPrefix = prefix;\n\t return this;\n\t } else {\n\t return hashPrefix;\n\t }\n\t };\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $locationProvider#html5Mode\n\t * @description\n\t * @param {(boolean|Object)=} mode If boolean, sets `html5Mode.enabled` to value.\n\t * If object, sets `enabled`, `requireBase` and `rewriteLinks` to respective values. Supported\n\t * properties:\n\t * - **enabled** – `{boolean}` – (default: false) If true, will rely on `history.pushState` to\n\t * change urls where supported. Will fall back to hash-prefixed paths in browsers that do not\n\t * support `pushState`.\n\t * - **requireBase** - `{boolean}` - (default: `true`) When html5Mode is enabled, specifies\n\t * whether or not a tag is required to be present. If `enabled` and `requireBase` are\n\t * true, and a base tag is not present, an error will be thrown when `$location` is injected.\n\t * See the {@link guide/$location $location guide for more information}\n\t * - **rewriteLinks** - `{boolean}` - (default: `true`) When html5Mode is enabled,\n\t * enables/disables url rewriting for relative links.\n\t *\n\t * @returns {Object} html5Mode object if used as getter or itself (chaining) if used as setter\n\t */\n\t this.html5Mode = function(mode) {\n\t if (isBoolean(mode)) {\n\t html5Mode.enabled = mode;\n\t return this;\n\t } else if (isObject(mode)) {\n\t\n\t if (isBoolean(mode.enabled)) {\n\t html5Mode.enabled = mode.enabled;\n\t }\n\t\n\t if (isBoolean(mode.requireBase)) {\n\t html5Mode.requireBase = mode.requireBase;\n\t }\n\t\n\t if (isBoolean(mode.rewriteLinks)) {\n\t html5Mode.rewriteLinks = mode.rewriteLinks;\n\t }\n\t\n\t return this;\n\t } else {\n\t return html5Mode;\n\t }\n\t };\n\t\n\t /**\n\t * @ngdoc event\n\t * @name $location#$locationChangeStart\n\t * @eventType broadcast on root scope\n\t * @description\n\t * Broadcasted before a URL will change.\n\t *\n\t * This change can be prevented by calling\n\t * `preventDefault` method of the event. See {@link ng.$rootScope.Scope#$on} for more\n\t * details about event object. Upon successful change\n\t * {@link ng.$location#$locationChangeSuccess $locationChangeSuccess} is fired.\n\t *\n\t * The `newState` and `oldState` parameters may be defined only in HTML5 mode and when\n\t * the browser supports the HTML5 History API.\n\t *\n\t * @param {Object} angularEvent Synthetic event object.\n\t * @param {string} newUrl New URL\n\t * @param {string=} oldUrl URL that was before it was changed.\n\t * @param {string=} newState New history state object\n\t * @param {string=} oldState History state object that was before it was changed.\n\t */\n\t\n\t /**\n\t * @ngdoc event\n\t * @name $location#$locationChangeSuccess\n\t * @eventType broadcast on root scope\n\t * @description\n\t * Broadcasted after a URL was changed.\n\t *\n\t * The `newState` and `oldState` parameters may be defined only in HTML5 mode and when\n\t * the browser supports the HTML5 History API.\n\t *\n\t * @param {Object} angularEvent Synthetic event object.\n\t * @param {string} newUrl New URL\n\t * @param {string=} oldUrl URL that was before it was changed.\n\t * @param {string=} newState New history state object\n\t * @param {string=} oldState History state object that was before it was changed.\n\t */\n\t\n\t this.$get = ['$rootScope', '$browser', '$sniffer', '$rootElement', '$window',\n\t function($rootScope, $browser, $sniffer, $rootElement, $window) {\n\t var $location,\n\t LocationMode,\n\t baseHref = $browser.baseHref(), // if base[href] is undefined, it defaults to ''\n\t initialUrl = $browser.url(),\n\t appBase;\n\t\n\t if (html5Mode.enabled) {\n\t if (!baseHref && html5Mode.requireBase) {\n\t throw $locationMinErr('nobase',\n\t \"$location in HTML5 mode requires a tag to be present!\");\n\t }\n\t appBase = serverBase(initialUrl) + (baseHref || '/');\n\t LocationMode = $sniffer.history ? LocationHtml5Url : LocationHashbangInHtml5Url;\n\t } else {\n\t appBase = stripHash(initialUrl);\n\t LocationMode = LocationHashbangUrl;\n\t }\n\t var appBaseNoFile = stripFile(appBase);\n\t\n\t $location = new LocationMode(appBase, appBaseNoFile, '#' + hashPrefix);\n\t $location.$$parseLinkUrl(initialUrl, initialUrl);\n\t\n\t $location.$$state = $browser.state();\n\t\n\t var IGNORE_URI_REGEXP = /^\\s*(javascript|mailto):/i;\n\t\n\t function setBrowserUrlWithFallback(url, replace, state) {\n\t var oldUrl = $location.url();\n\t var oldState = $location.$$state;\n\t try {\n\t $browser.url(url, replace, state);\n\t\n\t // Make sure $location.state() returns referentially identical (not just deeply equal)\n\t // state object; this makes possible quick checking if the state changed in the digest\n\t // loop. Checking deep equality would be too expensive.\n\t $location.$$state = $browser.state();\n\t } catch (e) {\n\t // Restore old values if pushState fails\n\t $location.url(oldUrl);\n\t $location.$$state = oldState;\n\t\n\t throw e;\n\t }\n\t }\n\t\n\t $rootElement.on('click', function(event) {\n\t // TODO(vojta): rewrite link when opening in new tab/window (in legacy browser)\n\t // currently we open nice url link and redirect then\n\t\n\t if (!html5Mode.rewriteLinks || event.ctrlKey || event.metaKey || event.shiftKey || event.which == 2 || event.button == 2) return;\n\t\n\t var elm = jqLite(event.target);\n\t\n\t // traverse the DOM up to find first A tag\n\t while (nodeName_(elm[0]) !== 'a') {\n\t // ignore rewriting if no A tag (reached root element, or no parent - removed from document)\n\t if (elm[0] === $rootElement[0] || !(elm = elm.parent())[0]) return;\n\t }\n\t\n\t var absHref = elm.prop('href');\n\t // get the actual href attribute - see\n\t // http://msdn.microsoft.com/en-us/library/ie/dd347148(v=vs.85).aspx\n\t var relHref = elm.attr('href') || elm.attr('xlink:href');\n\t\n\t if (isObject(absHref) && absHref.toString() === '[object SVGAnimatedString]') {\n\t // SVGAnimatedString.animVal should be identical to SVGAnimatedString.baseVal, unless during\n\t // an animation.\n\t absHref = urlResolve(absHref.animVal).href;\n\t }\n\t\n\t // Ignore when url is started with javascript: or mailto:\n\t if (IGNORE_URI_REGEXP.test(absHref)) return;\n\t\n\t if (absHref && !elm.attr('target') && !event.isDefaultPrevented()) {\n\t if ($location.$$parseLinkUrl(absHref, relHref)) {\n\t // We do a preventDefault for all urls that are part of the angular application,\n\t // in html5mode and also without, so that we are able to abort navigation without\n\t // getting double entries in the location history.\n\t event.preventDefault();\n\t // update location manually\n\t if ($location.absUrl() != $browser.url()) {\n\t $rootScope.$apply();\n\t // hack to work around FF6 bug 684208 when scenario runner clicks on links\n\t $window.angular['ff-684208-preventDefault'] = true;\n\t }\n\t }\n\t }\n\t });\n\t\n\t\n\t // rewrite hashbang url <> html5 url\n\t if (trimEmptyHash($location.absUrl()) != trimEmptyHash(initialUrl)) {\n\t $browser.url($location.absUrl(), true);\n\t }\n\t\n\t var initializing = true;\n\t\n\t // update $location when $browser url changes\n\t $browser.onUrlChange(function(newUrl, newState) {\n\t\n\t if (isUndefined(beginsWith(appBaseNoFile, newUrl))) {\n\t // If we are navigating outside of the app then force a reload\n\t $window.location.href = newUrl;\n\t return;\n\t }\n\t\n\t $rootScope.$evalAsync(function() {\n\t var oldUrl = $location.absUrl();\n\t var oldState = $location.$$state;\n\t var defaultPrevented;\n\t newUrl = trimEmptyHash(newUrl);\n\t $location.$$parse(newUrl);\n\t $location.$$state = newState;\n\t\n\t defaultPrevented = $rootScope.$broadcast('$locationChangeStart', newUrl, oldUrl,\n\t newState, oldState).defaultPrevented;\n\t\n\t // if the location was changed by a `$locationChangeStart` handler then stop\n\t // processing this location change\n\t if ($location.absUrl() !== newUrl) return;\n\t\n\t if (defaultPrevented) {\n\t $location.$$parse(oldUrl);\n\t $location.$$state = oldState;\n\t setBrowserUrlWithFallback(oldUrl, false, oldState);\n\t } else {\n\t initializing = false;\n\t afterLocationChange(oldUrl, oldState);\n\t }\n\t });\n\t if (!$rootScope.$$phase) $rootScope.$digest();\n\t });\n\t\n\t // update browser\n\t $rootScope.$watch(function $locationWatch() {\n\t var oldUrl = trimEmptyHash($browser.url());\n\t var newUrl = trimEmptyHash($location.absUrl());\n\t var oldState = $browser.state();\n\t var currentReplace = $location.$$replace;\n\t var urlOrStateChanged = oldUrl !== newUrl ||\n\t ($location.$$html5 && $sniffer.history && oldState !== $location.$$state);\n\t\n\t if (initializing || urlOrStateChanged) {\n\t initializing = false;\n\t\n\t $rootScope.$evalAsync(function() {\n\t var newUrl = $location.absUrl();\n\t var defaultPrevented = $rootScope.$broadcast('$locationChangeStart', newUrl, oldUrl,\n\t $location.$$state, oldState).defaultPrevented;\n\t\n\t // if the location was changed by a `$locationChangeStart` handler then stop\n\t // processing this location change\n\t if ($location.absUrl() !== newUrl) return;\n\t\n\t if (defaultPrevented) {\n\t $location.$$parse(oldUrl);\n\t $location.$$state = oldState;\n\t } else {\n\t if (urlOrStateChanged) {\n\t setBrowserUrlWithFallback(newUrl, currentReplace,\n\t oldState === $location.$$state ? null : $location.$$state);\n\t }\n\t afterLocationChange(oldUrl, oldState);\n\t }\n\t });\n\t }\n\t\n\t $location.$$replace = false;\n\t\n\t // we don't need to return anything because $evalAsync will make the digest loop dirty when\n\t // there is a change\n\t });\n\t\n\t return $location;\n\t\n\t function afterLocationChange(oldUrl, oldState) {\n\t $rootScope.$broadcast('$locationChangeSuccess', $location.absUrl(), oldUrl,\n\t $location.$$state, oldState);\n\t }\n\t}];\n\t}\n\t\n\t/**\n\t * @ngdoc service\n\t * @name $log\n\t * @requires $window\n\t *\n\t * @description\n\t * Simple service for logging. Default implementation safely writes the message\n\t * into the browser's console (if present).\n\t *\n\t * The main purpose of this service is to simplify debugging and troubleshooting.\n\t *\n\t * The default is to log `debug` messages. You can use\n\t * {@link ng.$logProvider ng.$logProvider#debugEnabled} to change this.\n\t *\n\t * @example\n\t \n\t \n\t angular.module('logExample', [])\n\t .controller('LogController', ['$scope', '$log', function($scope, $log) {\n\t $scope.$log = $log;\n\t $scope.message = 'Hello World!';\n\t }]);\n\t \n\t \n\t
\n\t

Reload this page with open console, enter text and hit the log button...

\n\t \n\t \n\t \n\t \n\t \n\t \n\t
\n\t
\n\t
\n\t */\n\t\n\t/**\n\t * @ngdoc provider\n\t * @name $logProvider\n\t * @description\n\t * Use the `$logProvider` to configure how the application logs messages\n\t */\n\tfunction $LogProvider() {\n\t var debug = true,\n\t self = this;\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $logProvider#debugEnabled\n\t * @description\n\t * @param {boolean=} flag enable or disable debug level messages\n\t * @returns {*} current value if used as getter or itself (chaining) if used as setter\n\t */\n\t this.debugEnabled = function(flag) {\n\t if (isDefined(flag)) {\n\t debug = flag;\n\t return this;\n\t } else {\n\t return debug;\n\t }\n\t };\n\t\n\t this.$get = ['$window', function($window) {\n\t return {\n\t /**\n\t * @ngdoc method\n\t * @name $log#log\n\t *\n\t * @description\n\t * Write a log message\n\t */\n\t log: consoleLog('log'),\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $log#info\n\t *\n\t * @description\n\t * Write an information message\n\t */\n\t info: consoleLog('info'),\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $log#warn\n\t *\n\t * @description\n\t * Write a warning message\n\t */\n\t warn: consoleLog('warn'),\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $log#error\n\t *\n\t * @description\n\t * Write an error message\n\t */\n\t error: consoleLog('error'),\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $log#debug\n\t *\n\t * @description\n\t * Write a debug message\n\t */\n\t debug: (function() {\n\t var fn = consoleLog('debug');\n\t\n\t return function() {\n\t if (debug) {\n\t fn.apply(self, arguments);\n\t }\n\t };\n\t }())\n\t };\n\t\n\t function formatError(arg) {\n\t if (arg instanceof Error) {\n\t if (arg.stack) {\n\t arg = (arg.message && arg.stack.indexOf(arg.message) === -1)\n\t ? 'Error: ' + arg.message + '\\n' + arg.stack\n\t : arg.stack;\n\t } else if (arg.sourceURL) {\n\t arg = arg.message + '\\n' + arg.sourceURL + ':' + arg.line;\n\t }\n\t }\n\t return arg;\n\t }\n\t\n\t function consoleLog(type) {\n\t var console = $window.console || {},\n\t logFn = console[type] || console.log || noop,\n\t hasApply = false;\n\t\n\t // Note: reading logFn.apply throws an error in IE11 in IE8 document mode.\n\t // The reason behind this is that console.log has type \"object\" in IE8...\n\t try {\n\t hasApply = !!logFn.apply;\n\t } catch (e) {}\n\t\n\t if (hasApply) {\n\t return function() {\n\t var args = [];\n\t forEach(arguments, function(arg) {\n\t args.push(formatError(arg));\n\t });\n\t return logFn.apply(console, args);\n\t };\n\t }\n\t\n\t // we are IE which either doesn't have window.console => this is noop and we do nothing,\n\t // or we are IE where console.log doesn't have apply so we log at least first 2 args\n\t return function(arg1, arg2) {\n\t logFn(arg1, arg2 == null ? '' : arg2);\n\t };\n\t }\n\t }];\n\t}\n\t\n\t/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *\n\t * Any commits to this file should be reviewed with security in mind. *\n\t * Changes to this file can potentially create security vulnerabilities. *\n\t * An approval from 2 Core members with history of modifying *\n\t * this file is required. *\n\t * *\n\t * Does the change somehow allow for arbitrary javascript to be executed? *\n\t * Or allows for someone to change the prototype of built-in objects? *\n\t * Or gives undesired access to variables likes document or window? *\n\t * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */\n\t\n\tvar $parseMinErr = minErr('$parse');\n\t\n\t// Sandboxing Angular Expressions\n\t// ------------------------------\n\t// Angular expressions are generally considered safe because these expressions only have direct\n\t// access to `$scope` and locals. However, one can obtain the ability to execute arbitrary JS code by\n\t// obtaining a reference to native JS functions such as the Function constructor.\n\t//\n\t// As an example, consider the following Angular expression:\n\t//\n\t// {}.toString.constructor('alert(\"evil JS code\")')\n\t//\n\t// This sandboxing technique is not perfect and doesn't aim to be. The goal is to prevent exploits\n\t// against the expression language, but not to prevent exploits that were enabled by exposing\n\t// sensitive JavaScript or browser APIs on Scope. Exposing such objects on a Scope is never a good\n\t// practice and therefore we are not even trying to protect against interaction with an object\n\t// explicitly exposed in this way.\n\t//\n\t// In general, it is not possible to access a Window object from an angular expression unless a\n\t// window or some DOM object that has a reference to window is published onto a Scope.\n\t// Similarly we prevent invocations of function known to be dangerous, as well as assignments to\n\t// native objects.\n\t//\n\t// See https://docs.angularjs.org/guide/security\n\t\n\t\n\tfunction ensureSafeMemberName(name, fullExpression) {\n\t if (name === \"__defineGetter__\" || name === \"__defineSetter__\"\n\t || name === \"__lookupGetter__\" || name === \"__lookupSetter__\"\n\t || name === \"__proto__\") {\n\t throw $parseMinErr('isecfld',\n\t 'Attempting to access a disallowed field in Angular expressions! '\n\t + 'Expression: {0}', fullExpression);\n\t }\n\t return name;\n\t}\n\t\n\tfunction getStringValue(name, fullExpression) {\n\t // From the JavaScript docs:\n\t // Property names must be strings. This means that non-string objects cannot be used\n\t // as keys in an object. Any non-string object, including a number, is typecasted\n\t // into a string via the toString method.\n\t //\n\t // So, to ensure that we are checking the same `name` that JavaScript would use,\n\t // we cast it to a string, if possible.\n\t // Doing `name + ''` can cause a repl error if the result to `toString` is not a string,\n\t // this is, this will handle objects that misbehave.\n\t name = name + '';\n\t if (!isString(name)) {\n\t throw $parseMinErr('iseccst',\n\t 'Cannot convert object to primitive value! '\n\t + 'Expression: {0}', fullExpression);\n\t }\n\t return name;\n\t}\n\t\n\tfunction ensureSafeObject(obj, fullExpression) {\n\t // nifty check if obj is Function that is fast and works across iframes and other contexts\n\t if (obj) {\n\t if (obj.constructor === obj) {\n\t throw $parseMinErr('isecfn',\n\t 'Referencing Function in Angular expressions is disallowed! Expression: {0}',\n\t fullExpression);\n\t } else if (// isWindow(obj)\n\t obj.window === obj) {\n\t throw $parseMinErr('isecwindow',\n\t 'Referencing the Window in Angular expressions is disallowed! Expression: {0}',\n\t fullExpression);\n\t } else if (// isElement(obj)\n\t obj.children && (obj.nodeName || (obj.prop && obj.attr && obj.find))) {\n\t throw $parseMinErr('isecdom',\n\t 'Referencing DOM nodes in Angular expressions is disallowed! Expression: {0}',\n\t fullExpression);\n\t } else if (// block Object so that we can't get hold of dangerous Object.* methods\n\t obj === Object) {\n\t throw $parseMinErr('isecobj',\n\t 'Referencing Object in Angular expressions is disallowed! Expression: {0}',\n\t fullExpression);\n\t }\n\t }\n\t return obj;\n\t}\n\t\n\tvar CALL = Function.prototype.call;\n\tvar APPLY = Function.prototype.apply;\n\tvar BIND = Function.prototype.bind;\n\t\n\tfunction ensureSafeFunction(obj, fullExpression) {\n\t if (obj) {\n\t if (obj.constructor === obj) {\n\t throw $parseMinErr('isecfn',\n\t 'Referencing Function in Angular expressions is disallowed! Expression: {0}',\n\t fullExpression);\n\t } else if (obj === CALL || obj === APPLY || obj === BIND) {\n\t throw $parseMinErr('isecff',\n\t 'Referencing call, apply or bind in Angular expressions is disallowed! Expression: {0}',\n\t fullExpression);\n\t }\n\t }\n\t}\n\t\n\tfunction ensureSafeAssignContext(obj, fullExpression) {\n\t if (obj) {\n\t if (obj === (0).constructor || obj === (false).constructor || obj === ''.constructor ||\n\t obj === {}.constructor || obj === [].constructor || obj === Function.constructor) {\n\t throw $parseMinErr('isecaf',\n\t 'Assigning to a constructor is disallowed! Expression: {0}', fullExpression);\n\t }\n\t }\n\t}\n\t\n\tvar OPERATORS = createMap();\n\tforEach('+ - * / % === !== == != < > <= >= && || ! = |'.split(' '), function(operator) { OPERATORS[operator] = true; });\n\tvar ESCAPE = {\"n\":\"\\n\", \"f\":\"\\f\", \"r\":\"\\r\", \"t\":\"\\t\", \"v\":\"\\v\", \"'\":\"'\", '\"':'\"'};\n\t\n\t\n\t/////////////////////////////////////////\n\t\n\t\n\t/**\n\t * @constructor\n\t */\n\tvar Lexer = function(options) {\n\t this.options = options;\n\t};\n\t\n\tLexer.prototype = {\n\t constructor: Lexer,\n\t\n\t lex: function(text) {\n\t this.text = text;\n\t this.index = 0;\n\t this.tokens = [];\n\t\n\t while (this.index < this.text.length) {\n\t var ch = this.text.charAt(this.index);\n\t if (ch === '\"' || ch === \"'\") {\n\t this.readString(ch);\n\t } else if (this.isNumber(ch) || ch === '.' && this.isNumber(this.peek())) {\n\t this.readNumber();\n\t } else if (this.isIdent(ch)) {\n\t this.readIdent();\n\t } else if (this.is(ch, '(){}[].,;:?')) {\n\t this.tokens.push({index: this.index, text: ch});\n\t this.index++;\n\t } else if (this.isWhitespace(ch)) {\n\t this.index++;\n\t } else {\n\t var ch2 = ch + this.peek();\n\t var ch3 = ch2 + this.peek(2);\n\t var op1 = OPERATORS[ch];\n\t var op2 = OPERATORS[ch2];\n\t var op3 = OPERATORS[ch3];\n\t if (op1 || op2 || op3) {\n\t var token = op3 ? ch3 : (op2 ? ch2 : ch);\n\t this.tokens.push({index: this.index, text: token, operator: true});\n\t this.index += token.length;\n\t } else {\n\t this.throwError('Unexpected next character ', this.index, this.index + 1);\n\t }\n\t }\n\t }\n\t return this.tokens;\n\t },\n\t\n\t is: function(ch, chars) {\n\t return chars.indexOf(ch) !== -1;\n\t },\n\t\n\t peek: function(i) {\n\t var num = i || 1;\n\t return (this.index + num < this.text.length) ? this.text.charAt(this.index + num) : false;\n\t },\n\t\n\t isNumber: function(ch) {\n\t return ('0' <= ch && ch <= '9') && typeof ch === \"string\";\n\t },\n\t\n\t isWhitespace: function(ch) {\n\t // IE treats non-breaking space as \\u00A0\n\t return (ch === ' ' || ch === '\\r' || ch === '\\t' ||\n\t ch === '\\n' || ch === '\\v' || ch === '\\u00A0');\n\t },\n\t\n\t isIdent: function(ch) {\n\t return ('a' <= ch && ch <= 'z' ||\n\t 'A' <= ch && ch <= 'Z' ||\n\t '_' === ch || ch === '$');\n\t },\n\t\n\t isExpOperator: function(ch) {\n\t return (ch === '-' || ch === '+' || this.isNumber(ch));\n\t },\n\t\n\t throwError: function(error, start, end) {\n\t end = end || this.index;\n\t var colStr = (isDefined(start)\n\t ? 's ' + start + '-' + this.index + ' [' + this.text.substring(start, end) + ']'\n\t : ' ' + end);\n\t throw $parseMinErr('lexerr', 'Lexer Error: {0} at column{1} in expression [{2}].',\n\t error, colStr, this.text);\n\t },\n\t\n\t readNumber: function() {\n\t var number = '';\n\t var start = this.index;\n\t while (this.index < this.text.length) {\n\t var ch = lowercase(this.text.charAt(this.index));\n\t if (ch == '.' || this.isNumber(ch)) {\n\t number += ch;\n\t } else {\n\t var peekCh = this.peek();\n\t if (ch == 'e' && this.isExpOperator(peekCh)) {\n\t number += ch;\n\t } else if (this.isExpOperator(ch) &&\n\t peekCh && this.isNumber(peekCh) &&\n\t number.charAt(number.length - 1) == 'e') {\n\t number += ch;\n\t } else if (this.isExpOperator(ch) &&\n\t (!peekCh || !this.isNumber(peekCh)) &&\n\t number.charAt(number.length - 1) == 'e') {\n\t this.throwError('Invalid exponent');\n\t } else {\n\t break;\n\t }\n\t }\n\t this.index++;\n\t }\n\t this.tokens.push({\n\t index: start,\n\t text: number,\n\t constant: true,\n\t value: Number(number)\n\t });\n\t },\n\t\n\t readIdent: function() {\n\t var start = this.index;\n\t while (this.index < this.text.length) {\n\t var ch = this.text.charAt(this.index);\n\t if (!(this.isIdent(ch) || this.isNumber(ch))) {\n\t break;\n\t }\n\t this.index++;\n\t }\n\t this.tokens.push({\n\t index: start,\n\t text: this.text.slice(start, this.index),\n\t identifier: true\n\t });\n\t },\n\t\n\t readString: function(quote) {\n\t var start = this.index;\n\t this.index++;\n\t var string = '';\n\t var rawString = quote;\n\t var escape = false;\n\t while (this.index < this.text.length) {\n\t var ch = this.text.charAt(this.index);\n\t rawString += ch;\n\t if (escape) {\n\t if (ch === 'u') {\n\t var hex = this.text.substring(this.index + 1, this.index + 5);\n\t if (!hex.match(/[\\da-f]{4}/i)) {\n\t this.throwError('Invalid unicode escape [\\\\u' + hex + ']');\n\t }\n\t this.index += 4;\n\t string += String.fromCharCode(parseInt(hex, 16));\n\t } else {\n\t var rep = ESCAPE[ch];\n\t string = string + (rep || ch);\n\t }\n\t escape = false;\n\t } else if (ch === '\\\\') {\n\t escape = true;\n\t } else if (ch === quote) {\n\t this.index++;\n\t this.tokens.push({\n\t index: start,\n\t text: rawString,\n\t constant: true,\n\t value: string\n\t });\n\t return;\n\t } else {\n\t string += ch;\n\t }\n\t this.index++;\n\t }\n\t this.throwError('Unterminated quote', start);\n\t }\n\t};\n\t\n\tvar AST = function(lexer, options) {\n\t this.lexer = lexer;\n\t this.options = options;\n\t};\n\t\n\tAST.Program = 'Program';\n\tAST.ExpressionStatement = 'ExpressionStatement';\n\tAST.AssignmentExpression = 'AssignmentExpression';\n\tAST.ConditionalExpression = 'ConditionalExpression';\n\tAST.LogicalExpression = 'LogicalExpression';\n\tAST.BinaryExpression = 'BinaryExpression';\n\tAST.UnaryExpression = 'UnaryExpression';\n\tAST.CallExpression = 'CallExpression';\n\tAST.MemberExpression = 'MemberExpression';\n\tAST.Identifier = 'Identifier';\n\tAST.Literal = 'Literal';\n\tAST.ArrayExpression = 'ArrayExpression';\n\tAST.Property = 'Property';\n\tAST.ObjectExpression = 'ObjectExpression';\n\tAST.ThisExpression = 'ThisExpression';\n\t\n\t// Internal use only\n\tAST.NGValueParameter = 'NGValueParameter';\n\t\n\tAST.prototype = {\n\t ast: function(text) {\n\t this.text = text;\n\t this.tokens = this.lexer.lex(text);\n\t\n\t var value = this.program();\n\t\n\t if (this.tokens.length !== 0) {\n\t this.throwError('is an unexpected token', this.tokens[0]);\n\t }\n\t\n\t return value;\n\t },\n\t\n\t program: function() {\n\t var body = [];\n\t while (true) {\n\t if (this.tokens.length > 0 && !this.peek('}', ')', ';', ']'))\n\t body.push(this.expressionStatement());\n\t if (!this.expect(';')) {\n\t return { type: AST.Program, body: body};\n\t }\n\t }\n\t },\n\t\n\t expressionStatement: function() {\n\t return { type: AST.ExpressionStatement, expression: this.filterChain() };\n\t },\n\t\n\t filterChain: function() {\n\t var left = this.expression();\n\t var token;\n\t while ((token = this.expect('|'))) {\n\t left = this.filter(left);\n\t }\n\t return left;\n\t },\n\t\n\t expression: function() {\n\t return this.assignment();\n\t },\n\t\n\t assignment: function() {\n\t var result = this.ternary();\n\t if (this.expect('=')) {\n\t result = { type: AST.AssignmentExpression, left: result, right: this.assignment(), operator: '='};\n\t }\n\t return result;\n\t },\n\t\n\t ternary: function() {\n\t var test = this.logicalOR();\n\t var alternate;\n\t var consequent;\n\t if (this.expect('?')) {\n\t alternate = this.expression();\n\t if (this.consume(':')) {\n\t consequent = this.expression();\n\t return { type: AST.ConditionalExpression, test: test, alternate: alternate, consequent: consequent};\n\t }\n\t }\n\t return test;\n\t },\n\t\n\t logicalOR: function() {\n\t var left = this.logicalAND();\n\t while (this.expect('||')) {\n\t left = { type: AST.LogicalExpression, operator: '||', left: left, right: this.logicalAND() };\n\t }\n\t return left;\n\t },\n\t\n\t logicalAND: function() {\n\t var left = this.equality();\n\t while (this.expect('&&')) {\n\t left = { type: AST.LogicalExpression, operator: '&&', left: left, right: this.equality()};\n\t }\n\t return left;\n\t },\n\t\n\t equality: function() {\n\t var left = this.relational();\n\t var token;\n\t while ((token = this.expect('==','!=','===','!=='))) {\n\t left = { type: AST.BinaryExpression, operator: token.text, left: left, right: this.relational() };\n\t }\n\t return left;\n\t },\n\t\n\t relational: function() {\n\t var left = this.additive();\n\t var token;\n\t while ((token = this.expect('<', '>', '<=', '>='))) {\n\t left = { type: AST.BinaryExpression, operator: token.text, left: left, right: this.additive() };\n\t }\n\t return left;\n\t },\n\t\n\t additive: function() {\n\t var left = this.multiplicative();\n\t var token;\n\t while ((token = this.expect('+','-'))) {\n\t left = { type: AST.BinaryExpression, operator: token.text, left: left, right: this.multiplicative() };\n\t }\n\t return left;\n\t },\n\t\n\t multiplicative: function() {\n\t var left = this.unary();\n\t var token;\n\t while ((token = this.expect('*','/','%'))) {\n\t left = { type: AST.BinaryExpression, operator: token.text, left: left, right: this.unary() };\n\t }\n\t return left;\n\t },\n\t\n\t unary: function() {\n\t var token;\n\t if ((token = this.expect('+', '-', '!'))) {\n\t return { type: AST.UnaryExpression, operator: token.text, prefix: true, argument: this.unary() };\n\t } else {\n\t return this.primary();\n\t }\n\t },\n\t\n\t primary: function() {\n\t var primary;\n\t if (this.expect('(')) {\n\t primary = this.filterChain();\n\t this.consume(')');\n\t } else if (this.expect('[')) {\n\t primary = this.arrayDeclaration();\n\t } else if (this.expect('{')) {\n\t primary = this.object();\n\t } else if (this.constants.hasOwnProperty(this.peek().text)) {\n\t primary = copy(this.constants[this.consume().text]);\n\t } else if (this.peek().identifier) {\n\t primary = this.identifier();\n\t } else if (this.peek().constant) {\n\t primary = this.constant();\n\t } else {\n\t this.throwError('not a primary expression', this.peek());\n\t }\n\t\n\t var next;\n\t while ((next = this.expect('(', '[', '.'))) {\n\t if (next.text === '(') {\n\t primary = {type: AST.CallExpression, callee: primary, arguments: this.parseArguments() };\n\t this.consume(')');\n\t } else if (next.text === '[') {\n\t primary = { type: AST.MemberExpression, object: primary, property: this.expression(), computed: true };\n\t this.consume(']');\n\t } else if (next.text === '.') {\n\t primary = { type: AST.MemberExpression, object: primary, property: this.identifier(), computed: false };\n\t } else {\n\t this.throwError('IMPOSSIBLE');\n\t }\n\t }\n\t return primary;\n\t },\n\t\n\t filter: function(baseExpression) {\n\t var args = [baseExpression];\n\t var result = {type: AST.CallExpression, callee: this.identifier(), arguments: args, filter: true};\n\t\n\t while (this.expect(':')) {\n\t args.push(this.expression());\n\t }\n\t\n\t return result;\n\t },\n\t\n\t parseArguments: function() {\n\t var args = [];\n\t if (this.peekToken().text !== ')') {\n\t do {\n\t args.push(this.expression());\n\t } while (this.expect(','));\n\t }\n\t return args;\n\t },\n\t\n\t identifier: function() {\n\t var token = this.consume();\n\t if (!token.identifier) {\n\t this.throwError('is not a valid identifier', token);\n\t }\n\t return { type: AST.Identifier, name: token.text };\n\t },\n\t\n\t constant: function() {\n\t // TODO check that it is a constant\n\t return { type: AST.Literal, value: this.consume().value };\n\t },\n\t\n\t arrayDeclaration: function() {\n\t var elements = [];\n\t if (this.peekToken().text !== ']') {\n\t do {\n\t if (this.peek(']')) {\n\t // Support trailing commas per ES5.1.\n\t break;\n\t }\n\t elements.push(this.expression());\n\t } while (this.expect(','));\n\t }\n\t this.consume(']');\n\t\n\t return { type: AST.ArrayExpression, elements: elements };\n\t },\n\t\n\t object: function() {\n\t var properties = [], property;\n\t if (this.peekToken().text !== '}') {\n\t do {\n\t if (this.peek('}')) {\n\t // Support trailing commas per ES5.1.\n\t break;\n\t }\n\t property = {type: AST.Property, kind: 'init'};\n\t if (this.peek().constant) {\n\t property.key = this.constant();\n\t } else if (this.peek().identifier) {\n\t property.key = this.identifier();\n\t } else {\n\t this.throwError(\"invalid key\", this.peek());\n\t }\n\t this.consume(':');\n\t property.value = this.expression();\n\t properties.push(property);\n\t } while (this.expect(','));\n\t }\n\t this.consume('}');\n\t\n\t return {type: AST.ObjectExpression, properties: properties };\n\t },\n\t\n\t throwError: function(msg, token) {\n\t throw $parseMinErr('syntax',\n\t 'Syntax Error: Token \\'{0}\\' {1} at column {2} of the expression [{3}] starting at [{4}].',\n\t token.text, msg, (token.index + 1), this.text, this.text.substring(token.index));\n\t },\n\t\n\t consume: function(e1) {\n\t if (this.tokens.length === 0) {\n\t throw $parseMinErr('ueoe', 'Unexpected end of expression: {0}', this.text);\n\t }\n\t\n\t var token = this.expect(e1);\n\t if (!token) {\n\t this.throwError('is unexpected, expecting [' + e1 + ']', this.peek());\n\t }\n\t return token;\n\t },\n\t\n\t peekToken: function() {\n\t if (this.tokens.length === 0) {\n\t throw $parseMinErr('ueoe', 'Unexpected end of expression: {0}', this.text);\n\t }\n\t return this.tokens[0];\n\t },\n\t\n\t peek: function(e1, e2, e3, e4) {\n\t return this.peekAhead(0, e1, e2, e3, e4);\n\t },\n\t\n\t peekAhead: function(i, e1, e2, e3, e4) {\n\t if (this.tokens.length > i) {\n\t var token = this.tokens[i];\n\t var t = token.text;\n\t if (t === e1 || t === e2 || t === e3 || t === e4 ||\n\t (!e1 && !e2 && !e3 && !e4)) {\n\t return token;\n\t }\n\t }\n\t return false;\n\t },\n\t\n\t expect: function(e1, e2, e3, e4) {\n\t var token = this.peek(e1, e2, e3, e4);\n\t if (token) {\n\t this.tokens.shift();\n\t return token;\n\t }\n\t return false;\n\t },\n\t\n\t\n\t /* `undefined` is not a constant, it is an identifier,\n\t * but using it as an identifier is not supported\n\t */\n\t constants: {\n\t 'true': { type: AST.Literal, value: true },\n\t 'false': { type: AST.Literal, value: false },\n\t 'null': { type: AST.Literal, value: null },\n\t 'undefined': {type: AST.Literal, value: undefined },\n\t 'this': {type: AST.ThisExpression }\n\t }\n\t};\n\t\n\tfunction ifDefined(v, d) {\n\t return typeof v !== 'undefined' ? v : d;\n\t}\n\t\n\tfunction plusFn(l, r) {\n\t if (typeof l === 'undefined') return r;\n\t if (typeof r === 'undefined') return l;\n\t return l + r;\n\t}\n\t\n\tfunction isStateless($filter, filterName) {\n\t var fn = $filter(filterName);\n\t return !fn.$stateful;\n\t}\n\t\n\tfunction findConstantAndWatchExpressions(ast, $filter) {\n\t var allConstants;\n\t var argsToWatch;\n\t switch (ast.type) {\n\t case AST.Program:\n\t allConstants = true;\n\t forEach(ast.body, function(expr) {\n\t findConstantAndWatchExpressions(expr.expression, $filter);\n\t allConstants = allConstants && expr.expression.constant;\n\t });\n\t ast.constant = allConstants;\n\t break;\n\t case AST.Literal:\n\t ast.constant = true;\n\t ast.toWatch = [];\n\t break;\n\t case AST.UnaryExpression:\n\t findConstantAndWatchExpressions(ast.argument, $filter);\n\t ast.constant = ast.argument.constant;\n\t ast.toWatch = ast.argument.toWatch;\n\t break;\n\t case AST.BinaryExpression:\n\t findConstantAndWatchExpressions(ast.left, $filter);\n\t findConstantAndWatchExpressions(ast.right, $filter);\n\t ast.constant = ast.left.constant && ast.right.constant;\n\t ast.toWatch = ast.left.toWatch.concat(ast.right.toWatch);\n\t break;\n\t case AST.LogicalExpression:\n\t findConstantAndWatchExpressions(ast.left, $filter);\n\t findConstantAndWatchExpressions(ast.right, $filter);\n\t ast.constant = ast.left.constant && ast.right.constant;\n\t ast.toWatch = ast.constant ? [] : [ast];\n\t break;\n\t case AST.ConditionalExpression:\n\t findConstantAndWatchExpressions(ast.test, $filter);\n\t findConstantAndWatchExpressions(ast.alternate, $filter);\n\t findConstantAndWatchExpressions(ast.consequent, $filter);\n\t ast.constant = ast.test.constant && ast.alternate.constant && ast.consequent.constant;\n\t ast.toWatch = ast.constant ? [] : [ast];\n\t break;\n\t case AST.Identifier:\n\t ast.constant = false;\n\t ast.toWatch = [ast];\n\t break;\n\t case AST.MemberExpression:\n\t findConstantAndWatchExpressions(ast.object, $filter);\n\t if (ast.computed) {\n\t findConstantAndWatchExpressions(ast.property, $filter);\n\t }\n\t ast.constant = ast.object.constant && (!ast.computed || ast.property.constant);\n\t ast.toWatch = [ast];\n\t break;\n\t case AST.CallExpression:\n\t allConstants = ast.filter ? isStateless($filter, ast.callee.name) : false;\n\t argsToWatch = [];\n\t forEach(ast.arguments, function(expr) {\n\t findConstantAndWatchExpressions(expr, $filter);\n\t allConstants = allConstants && expr.constant;\n\t if (!expr.constant) {\n\t argsToWatch.push.apply(argsToWatch, expr.toWatch);\n\t }\n\t });\n\t ast.constant = allConstants;\n\t ast.toWatch = ast.filter && isStateless($filter, ast.callee.name) ? argsToWatch : [ast];\n\t break;\n\t case AST.AssignmentExpression:\n\t findConstantAndWatchExpressions(ast.left, $filter);\n\t findConstantAndWatchExpressions(ast.right, $filter);\n\t ast.constant = ast.left.constant && ast.right.constant;\n\t ast.toWatch = [ast];\n\t break;\n\t case AST.ArrayExpression:\n\t allConstants = true;\n\t argsToWatch = [];\n\t forEach(ast.elements, function(expr) {\n\t findConstantAndWatchExpressions(expr, $filter);\n\t allConstants = allConstants && expr.constant;\n\t if (!expr.constant) {\n\t argsToWatch.push.apply(argsToWatch, expr.toWatch);\n\t }\n\t });\n\t ast.constant = allConstants;\n\t ast.toWatch = argsToWatch;\n\t break;\n\t case AST.ObjectExpression:\n\t allConstants = true;\n\t argsToWatch = [];\n\t forEach(ast.properties, function(property) {\n\t findConstantAndWatchExpressions(property.value, $filter);\n\t allConstants = allConstants && property.value.constant;\n\t if (!property.value.constant) {\n\t argsToWatch.push.apply(argsToWatch, property.value.toWatch);\n\t }\n\t });\n\t ast.constant = allConstants;\n\t ast.toWatch = argsToWatch;\n\t break;\n\t case AST.ThisExpression:\n\t ast.constant = false;\n\t ast.toWatch = [];\n\t break;\n\t }\n\t}\n\t\n\tfunction getInputs(body) {\n\t if (body.length != 1) return;\n\t var lastExpression = body[0].expression;\n\t var candidate = lastExpression.toWatch;\n\t if (candidate.length !== 1) return candidate;\n\t return candidate[0] !== lastExpression ? candidate : undefined;\n\t}\n\t\n\tfunction isAssignable(ast) {\n\t return ast.type === AST.Identifier || ast.type === AST.MemberExpression;\n\t}\n\t\n\tfunction assignableAST(ast) {\n\t if (ast.body.length === 1 && isAssignable(ast.body[0].expression)) {\n\t return {type: AST.AssignmentExpression, left: ast.body[0].expression, right: {type: AST.NGValueParameter}, operator: '='};\n\t }\n\t}\n\t\n\tfunction isLiteral(ast) {\n\t return ast.body.length === 0 ||\n\t ast.body.length === 1 && (\n\t ast.body[0].expression.type === AST.Literal ||\n\t ast.body[0].expression.type === AST.ArrayExpression ||\n\t ast.body[0].expression.type === AST.ObjectExpression);\n\t}\n\t\n\tfunction isConstant(ast) {\n\t return ast.constant;\n\t}\n\t\n\tfunction ASTCompiler(astBuilder, $filter) {\n\t this.astBuilder = astBuilder;\n\t this.$filter = $filter;\n\t}\n\t\n\tASTCompiler.prototype = {\n\t compile: function(expression, expensiveChecks) {\n\t var self = this;\n\t var ast = this.astBuilder.ast(expression);\n\t this.state = {\n\t nextId: 0,\n\t filters: {},\n\t expensiveChecks: expensiveChecks,\n\t fn: {vars: [], body: [], own: {}},\n\t assign: {vars: [], body: [], own: {}},\n\t inputs: []\n\t };\n\t findConstantAndWatchExpressions(ast, self.$filter);\n\t var extra = '';\n\t var assignable;\n\t this.stage = 'assign';\n\t if ((assignable = assignableAST(ast))) {\n\t this.state.computing = 'assign';\n\t var result = this.nextId();\n\t this.recurse(assignable, result);\n\t this.return_(result);\n\t extra = 'fn.assign=' + this.generateFunction('assign', 's,v,l');\n\t }\n\t var toWatch = getInputs(ast.body);\n\t self.stage = 'inputs';\n\t forEach(toWatch, function(watch, key) {\n\t var fnKey = 'fn' + key;\n\t self.state[fnKey] = {vars: [], body: [], own: {}};\n\t self.state.computing = fnKey;\n\t var intoId = self.nextId();\n\t self.recurse(watch, intoId);\n\t self.return_(intoId);\n\t self.state.inputs.push(fnKey);\n\t watch.watchId = key;\n\t });\n\t this.state.computing = 'fn';\n\t this.stage = 'main';\n\t this.recurse(ast);\n\t var fnString =\n\t // The build and minification steps remove the string \"use strict\" from the code, but this is done using a regex.\n\t // This is a workaround for this until we do a better job at only removing the prefix only when we should.\n\t '\"' + this.USE + ' ' + this.STRICT + '\";\\n' +\n\t this.filterPrefix() +\n\t 'var fn=' + this.generateFunction('fn', 's,l,a,i') +\n\t extra +\n\t this.watchFns() +\n\t 'return fn;';\n\t\n\t /* jshint -W054 */\n\t var fn = (new Function('$filter',\n\t 'ensureSafeMemberName',\n\t 'ensureSafeObject',\n\t 'ensureSafeFunction',\n\t 'getStringValue',\n\t 'ensureSafeAssignContext',\n\t 'ifDefined',\n\t 'plus',\n\t 'text',\n\t fnString))(\n\t this.$filter,\n\t ensureSafeMemberName,\n\t ensureSafeObject,\n\t ensureSafeFunction,\n\t getStringValue,\n\t ensureSafeAssignContext,\n\t ifDefined,\n\t plusFn,\n\t expression);\n\t /* jshint +W054 */\n\t this.state = this.stage = undefined;\n\t fn.literal = isLiteral(ast);\n\t fn.constant = isConstant(ast);\n\t return fn;\n\t },\n\t\n\t USE: 'use',\n\t\n\t STRICT: 'strict',\n\t\n\t watchFns: function() {\n\t var result = [];\n\t var fns = this.state.inputs;\n\t var self = this;\n\t forEach(fns, function(name) {\n\t result.push('var ' + name + '=' + self.generateFunction(name, 's'));\n\t });\n\t if (fns.length) {\n\t result.push('fn.inputs=[' + fns.join(',') + '];');\n\t }\n\t return result.join('');\n\t },\n\t\n\t generateFunction: function(name, params) {\n\t return 'function(' + params + '){' +\n\t this.varsPrefix(name) +\n\t this.body(name) +\n\t '};';\n\t },\n\t\n\t filterPrefix: function() {\n\t var parts = [];\n\t var self = this;\n\t forEach(this.state.filters, function(id, filter) {\n\t parts.push(id + '=$filter(' + self.escape(filter) + ')');\n\t });\n\t if (parts.length) return 'var ' + parts.join(',') + ';';\n\t return '';\n\t },\n\t\n\t varsPrefix: function(section) {\n\t return this.state[section].vars.length ? 'var ' + this.state[section].vars.join(',') + ';' : '';\n\t },\n\t\n\t body: function(section) {\n\t return this.state[section].body.join('');\n\t },\n\t\n\t recurse: function(ast, intoId, nameId, recursionFn, create, skipWatchIdCheck) {\n\t var left, right, self = this, args, expression;\n\t recursionFn = recursionFn || noop;\n\t if (!skipWatchIdCheck && isDefined(ast.watchId)) {\n\t intoId = intoId || this.nextId();\n\t this.if_('i',\n\t this.lazyAssign(intoId, this.computedMember('i', ast.watchId)),\n\t this.lazyRecurse(ast, intoId, nameId, recursionFn, create, true)\n\t );\n\t return;\n\t }\n\t switch (ast.type) {\n\t case AST.Program:\n\t forEach(ast.body, function(expression, pos) {\n\t self.recurse(expression.expression, undefined, undefined, function(expr) { right = expr; });\n\t if (pos !== ast.body.length - 1) {\n\t self.current().body.push(right, ';');\n\t } else {\n\t self.return_(right);\n\t }\n\t });\n\t break;\n\t case AST.Literal:\n\t expression = this.escape(ast.value);\n\t this.assign(intoId, expression);\n\t recursionFn(expression);\n\t break;\n\t case AST.UnaryExpression:\n\t this.recurse(ast.argument, undefined, undefined, function(expr) { right = expr; });\n\t expression = ast.operator + '(' + this.ifDefined(right, 0) + ')';\n\t this.assign(intoId, expression);\n\t recursionFn(expression);\n\t break;\n\t case AST.BinaryExpression:\n\t this.recurse(ast.left, undefined, undefined, function(expr) { left = expr; });\n\t this.recurse(ast.right, undefined, undefined, function(expr) { right = expr; });\n\t if (ast.operator === '+') {\n\t expression = this.plus(left, right);\n\t } else if (ast.operator === '-') {\n\t expression = this.ifDefined(left, 0) + ast.operator + this.ifDefined(right, 0);\n\t } else {\n\t expression = '(' + left + ')' + ast.operator + '(' + right + ')';\n\t }\n\t this.assign(intoId, expression);\n\t recursionFn(expression);\n\t break;\n\t case AST.LogicalExpression:\n\t intoId = intoId || this.nextId();\n\t self.recurse(ast.left, intoId);\n\t self.if_(ast.operator === '&&' ? intoId : self.not(intoId), self.lazyRecurse(ast.right, intoId));\n\t recursionFn(intoId);\n\t break;\n\t case AST.ConditionalExpression:\n\t intoId = intoId || this.nextId();\n\t self.recurse(ast.test, intoId);\n\t self.if_(intoId, self.lazyRecurse(ast.alternate, intoId), self.lazyRecurse(ast.consequent, intoId));\n\t recursionFn(intoId);\n\t break;\n\t case AST.Identifier:\n\t intoId = intoId || this.nextId();\n\t if (nameId) {\n\t nameId.context = self.stage === 'inputs' ? 's' : this.assign(this.nextId(), this.getHasOwnProperty('l', ast.name) + '?l:s');\n\t nameId.computed = false;\n\t nameId.name = ast.name;\n\t }\n\t ensureSafeMemberName(ast.name);\n\t self.if_(self.stage === 'inputs' || self.not(self.getHasOwnProperty('l', ast.name)),\n\t function() {\n\t self.if_(self.stage === 'inputs' || 's', function() {\n\t if (create && create !== 1) {\n\t self.if_(\n\t self.not(self.nonComputedMember('s', ast.name)),\n\t self.lazyAssign(self.nonComputedMember('s', ast.name), '{}'));\n\t }\n\t self.assign(intoId, self.nonComputedMember('s', ast.name));\n\t });\n\t }, intoId && self.lazyAssign(intoId, self.nonComputedMember('l', ast.name))\n\t );\n\t if (self.state.expensiveChecks || isPossiblyDangerousMemberName(ast.name)) {\n\t self.addEnsureSafeObject(intoId);\n\t }\n\t recursionFn(intoId);\n\t break;\n\t case AST.MemberExpression:\n\t left = nameId && (nameId.context = this.nextId()) || this.nextId();\n\t intoId = intoId || this.nextId();\n\t self.recurse(ast.object, left, undefined, function() {\n\t self.if_(self.notNull(left), function() {\n\t if (create && create !== 1) {\n\t self.addEnsureSafeAssignContext(left);\n\t }\n\t if (ast.computed) {\n\t right = self.nextId();\n\t self.recurse(ast.property, right);\n\t self.getStringValue(right);\n\t self.addEnsureSafeMemberName(right);\n\t if (create && create !== 1) {\n\t self.if_(self.not(self.computedMember(left, right)), self.lazyAssign(self.computedMember(left, right), '{}'));\n\t }\n\t expression = self.ensureSafeObject(self.computedMember(left, right));\n\t self.assign(intoId, expression);\n\t if (nameId) {\n\t nameId.computed = true;\n\t nameId.name = right;\n\t }\n\t } else {\n\t ensureSafeMemberName(ast.property.name);\n\t if (create && create !== 1) {\n\t self.if_(self.not(self.nonComputedMember(left, ast.property.name)), self.lazyAssign(self.nonComputedMember(left, ast.property.name), '{}'));\n\t }\n\t expression = self.nonComputedMember(left, ast.property.name);\n\t if (self.state.expensiveChecks || isPossiblyDangerousMemberName(ast.property.name)) {\n\t expression = self.ensureSafeObject(expression);\n\t }\n\t self.assign(intoId, expression);\n\t if (nameId) {\n\t nameId.computed = false;\n\t nameId.name = ast.property.name;\n\t }\n\t }\n\t }, function() {\n\t self.assign(intoId, 'undefined');\n\t });\n\t recursionFn(intoId);\n\t }, !!create);\n\t break;\n\t case AST.CallExpression:\n\t intoId = intoId || this.nextId();\n\t if (ast.filter) {\n\t right = self.filter(ast.callee.name);\n\t args = [];\n\t forEach(ast.arguments, function(expr) {\n\t var argument = self.nextId();\n\t self.recurse(expr, argument);\n\t args.push(argument);\n\t });\n\t expression = right + '(' + args.join(',') + ')';\n\t self.assign(intoId, expression);\n\t recursionFn(intoId);\n\t } else {\n\t right = self.nextId();\n\t left = {};\n\t args = [];\n\t self.recurse(ast.callee, right, left, function() {\n\t self.if_(self.notNull(right), function() {\n\t self.addEnsureSafeFunction(right);\n\t forEach(ast.arguments, function(expr) {\n\t self.recurse(expr, self.nextId(), undefined, function(argument) {\n\t args.push(self.ensureSafeObject(argument));\n\t });\n\t });\n\t if (left.name) {\n\t if (!self.state.expensiveChecks) {\n\t self.addEnsureSafeObject(left.context);\n\t }\n\t expression = self.member(left.context, left.name, left.computed) + '(' + args.join(',') + ')';\n\t } else {\n\t expression = right + '(' + args.join(',') + ')';\n\t }\n\t expression = self.ensureSafeObject(expression);\n\t self.assign(intoId, expression);\n\t }, function() {\n\t self.assign(intoId, 'undefined');\n\t });\n\t recursionFn(intoId);\n\t });\n\t }\n\t break;\n\t case AST.AssignmentExpression:\n\t right = this.nextId();\n\t left = {};\n\t if (!isAssignable(ast.left)) {\n\t throw $parseMinErr('lval', 'Trying to assign a value to a non l-value');\n\t }\n\t this.recurse(ast.left, undefined, left, function() {\n\t self.if_(self.notNull(left.context), function() {\n\t self.recurse(ast.right, right);\n\t self.addEnsureSafeObject(self.member(left.context, left.name, left.computed));\n\t self.addEnsureSafeAssignContext(left.context);\n\t expression = self.member(left.context, left.name, left.computed) + ast.operator + right;\n\t self.assign(intoId, expression);\n\t recursionFn(intoId || expression);\n\t });\n\t }, 1);\n\t break;\n\t case AST.ArrayExpression:\n\t args = [];\n\t forEach(ast.elements, function(expr) {\n\t self.recurse(expr, self.nextId(), undefined, function(argument) {\n\t args.push(argument);\n\t });\n\t });\n\t expression = '[' + args.join(',') + ']';\n\t this.assign(intoId, expression);\n\t recursionFn(expression);\n\t break;\n\t case AST.ObjectExpression:\n\t args = [];\n\t forEach(ast.properties, function(property) {\n\t self.recurse(property.value, self.nextId(), undefined, function(expr) {\n\t args.push(self.escape(\n\t property.key.type === AST.Identifier ? property.key.name :\n\t ('' + property.key.value)) +\n\t ':' + expr);\n\t });\n\t });\n\t expression = '{' + args.join(',') + '}';\n\t this.assign(intoId, expression);\n\t recursionFn(expression);\n\t break;\n\t case AST.ThisExpression:\n\t this.assign(intoId, 's');\n\t recursionFn('s');\n\t break;\n\t case AST.NGValueParameter:\n\t this.assign(intoId, 'v');\n\t recursionFn('v');\n\t break;\n\t }\n\t },\n\t\n\t getHasOwnProperty: function(element, property) {\n\t var key = element + '.' + property;\n\t var own = this.current().own;\n\t if (!own.hasOwnProperty(key)) {\n\t own[key] = this.nextId(false, element + '&&(' + this.escape(property) + ' in ' + element + ')');\n\t }\n\t return own[key];\n\t },\n\t\n\t assign: function(id, value) {\n\t if (!id) return;\n\t this.current().body.push(id, '=', value, ';');\n\t return id;\n\t },\n\t\n\t filter: function(filterName) {\n\t if (!this.state.filters.hasOwnProperty(filterName)) {\n\t this.state.filters[filterName] = this.nextId(true);\n\t }\n\t return this.state.filters[filterName];\n\t },\n\t\n\t ifDefined: function(id, defaultValue) {\n\t return 'ifDefined(' + id + ',' + this.escape(defaultValue) + ')';\n\t },\n\t\n\t plus: function(left, right) {\n\t return 'plus(' + left + ',' + right + ')';\n\t },\n\t\n\t return_: function(id) {\n\t this.current().body.push('return ', id, ';');\n\t },\n\t\n\t if_: function(test, alternate, consequent) {\n\t if (test === true) {\n\t alternate();\n\t } else {\n\t var body = this.current().body;\n\t body.push('if(', test, '){');\n\t alternate();\n\t body.push('}');\n\t if (consequent) {\n\t body.push('else{');\n\t consequent();\n\t body.push('}');\n\t }\n\t }\n\t },\n\t\n\t not: function(expression) {\n\t return '!(' + expression + ')';\n\t },\n\t\n\t notNull: function(expression) {\n\t return expression + '!=null';\n\t },\n\t\n\t nonComputedMember: function(left, right) {\n\t return left + '.' + right;\n\t },\n\t\n\t computedMember: function(left, right) {\n\t return left + '[' + right + ']';\n\t },\n\t\n\t member: function(left, right, computed) {\n\t if (computed) return this.computedMember(left, right);\n\t return this.nonComputedMember(left, right);\n\t },\n\t\n\t addEnsureSafeObject: function(item) {\n\t this.current().body.push(this.ensureSafeObject(item), ';');\n\t },\n\t\n\t addEnsureSafeMemberName: function(item) {\n\t this.current().body.push(this.ensureSafeMemberName(item), ';');\n\t },\n\t\n\t addEnsureSafeFunction: function(item) {\n\t this.current().body.push(this.ensureSafeFunction(item), ';');\n\t },\n\t\n\t addEnsureSafeAssignContext: function(item) {\n\t this.current().body.push(this.ensureSafeAssignContext(item), ';');\n\t },\n\t\n\t ensureSafeObject: function(item) {\n\t return 'ensureSafeObject(' + item + ',text)';\n\t },\n\t\n\t ensureSafeMemberName: function(item) {\n\t return 'ensureSafeMemberName(' + item + ',text)';\n\t },\n\t\n\t ensureSafeFunction: function(item) {\n\t return 'ensureSafeFunction(' + item + ',text)';\n\t },\n\t\n\t getStringValue: function(item) {\n\t this.assign(item, 'getStringValue(' + item + ',text)');\n\t },\n\t\n\t ensureSafeAssignContext: function(item) {\n\t return 'ensureSafeAssignContext(' + item + ',text)';\n\t },\n\t\n\t lazyRecurse: function(ast, intoId, nameId, recursionFn, create, skipWatchIdCheck) {\n\t var self = this;\n\t return function() {\n\t self.recurse(ast, intoId, nameId, recursionFn, create, skipWatchIdCheck);\n\t };\n\t },\n\t\n\t lazyAssign: function(id, value) {\n\t var self = this;\n\t return function() {\n\t self.assign(id, value);\n\t };\n\t },\n\t\n\t stringEscapeRegex: /[^ a-zA-Z0-9]/g,\n\t\n\t stringEscapeFn: function(c) {\n\t return '\\\\u' + ('0000' + c.charCodeAt(0).toString(16)).slice(-4);\n\t },\n\t\n\t escape: function(value) {\n\t if (isString(value)) return \"'\" + value.replace(this.stringEscapeRegex, this.stringEscapeFn) + \"'\";\n\t if (isNumber(value)) return value.toString();\n\t if (value === true) return 'true';\n\t if (value === false) return 'false';\n\t if (value === null) return 'null';\n\t if (typeof value === 'undefined') return 'undefined';\n\t\n\t throw $parseMinErr('esc', 'IMPOSSIBLE');\n\t },\n\t\n\t nextId: function(skip, init) {\n\t var id = 'v' + (this.state.nextId++);\n\t if (!skip) {\n\t this.current().vars.push(id + (init ? '=' + init : ''));\n\t }\n\t return id;\n\t },\n\t\n\t current: function() {\n\t return this.state[this.state.computing];\n\t }\n\t};\n\t\n\t\n\tfunction ASTInterpreter(astBuilder, $filter) {\n\t this.astBuilder = astBuilder;\n\t this.$filter = $filter;\n\t}\n\t\n\tASTInterpreter.prototype = {\n\t compile: function(expression, expensiveChecks) {\n\t var self = this;\n\t var ast = this.astBuilder.ast(expression);\n\t this.expression = expression;\n\t this.expensiveChecks = expensiveChecks;\n\t findConstantAndWatchExpressions(ast, self.$filter);\n\t var assignable;\n\t var assign;\n\t if ((assignable = assignableAST(ast))) {\n\t assign = this.recurse(assignable);\n\t }\n\t var toWatch = getInputs(ast.body);\n\t var inputs;\n\t if (toWatch) {\n\t inputs = [];\n\t forEach(toWatch, function(watch, key) {\n\t var input = self.recurse(watch);\n\t watch.input = input;\n\t inputs.push(input);\n\t watch.watchId = key;\n\t });\n\t }\n\t var expressions = [];\n\t forEach(ast.body, function(expression) {\n\t expressions.push(self.recurse(expression.expression));\n\t });\n\t var fn = ast.body.length === 0 ? function() {} :\n\t ast.body.length === 1 ? expressions[0] :\n\t function(scope, locals) {\n\t var lastValue;\n\t forEach(expressions, function(exp) {\n\t lastValue = exp(scope, locals);\n\t });\n\t return lastValue;\n\t };\n\t if (assign) {\n\t fn.assign = function(scope, value, locals) {\n\t return assign(scope, locals, value);\n\t };\n\t }\n\t if (inputs) {\n\t fn.inputs = inputs;\n\t }\n\t fn.literal = isLiteral(ast);\n\t fn.constant = isConstant(ast);\n\t return fn;\n\t },\n\t\n\t recurse: function(ast, context, create) {\n\t var left, right, self = this, args, expression;\n\t if (ast.input) {\n\t return this.inputs(ast.input, ast.watchId);\n\t }\n\t switch (ast.type) {\n\t case AST.Literal:\n\t return this.value(ast.value, context);\n\t case AST.UnaryExpression:\n\t right = this.recurse(ast.argument);\n\t return this['unary' + ast.operator](right, context);\n\t case AST.BinaryExpression:\n\t left = this.recurse(ast.left);\n\t right = this.recurse(ast.right);\n\t return this['binary' + ast.operator](left, right, context);\n\t case AST.LogicalExpression:\n\t left = this.recurse(ast.left);\n\t right = this.recurse(ast.right);\n\t return this['binary' + ast.operator](left, right, context);\n\t case AST.ConditionalExpression:\n\t return this['ternary?:'](\n\t this.recurse(ast.test),\n\t this.recurse(ast.alternate),\n\t this.recurse(ast.consequent),\n\t context\n\t );\n\t case AST.Identifier:\n\t ensureSafeMemberName(ast.name, self.expression);\n\t return self.identifier(ast.name,\n\t self.expensiveChecks || isPossiblyDangerousMemberName(ast.name),\n\t context, create, self.expression);\n\t case AST.MemberExpression:\n\t left = this.recurse(ast.object, false, !!create);\n\t if (!ast.computed) {\n\t ensureSafeMemberName(ast.property.name, self.expression);\n\t right = ast.property.name;\n\t }\n\t if (ast.computed) right = this.recurse(ast.property);\n\t return ast.computed ?\n\t this.computedMember(left, right, context, create, self.expression) :\n\t this.nonComputedMember(left, right, self.expensiveChecks, context, create, self.expression);\n\t case AST.CallExpression:\n\t args = [];\n\t forEach(ast.arguments, function(expr) {\n\t args.push(self.recurse(expr));\n\t });\n\t if (ast.filter) right = this.$filter(ast.callee.name);\n\t if (!ast.filter) right = this.recurse(ast.callee, true);\n\t return ast.filter ?\n\t function(scope, locals, assign, inputs) {\n\t var values = [];\n\t for (var i = 0; i < args.length; ++i) {\n\t values.push(args[i](scope, locals, assign, inputs));\n\t }\n\t var value = right.apply(undefined, values, inputs);\n\t return context ? {context: undefined, name: undefined, value: value} : value;\n\t } :\n\t function(scope, locals, assign, inputs) {\n\t var rhs = right(scope, locals, assign, inputs);\n\t var value;\n\t if (rhs.value != null) {\n\t ensureSafeObject(rhs.context, self.expression);\n\t ensureSafeFunction(rhs.value, self.expression);\n\t var values = [];\n\t for (var i = 0; i < args.length; ++i) {\n\t values.push(ensureSafeObject(args[i](scope, locals, assign, inputs), self.expression));\n\t }\n\t value = ensureSafeObject(rhs.value.apply(rhs.context, values), self.expression);\n\t }\n\t return context ? {value: value} : value;\n\t };\n\t case AST.AssignmentExpression:\n\t left = this.recurse(ast.left, true, 1);\n\t right = this.recurse(ast.right);\n\t return function(scope, locals, assign, inputs) {\n\t var lhs = left(scope, locals, assign, inputs);\n\t var rhs = right(scope, locals, assign, inputs);\n\t ensureSafeObject(lhs.value, self.expression);\n\t ensureSafeAssignContext(lhs.context);\n\t lhs.context[lhs.name] = rhs;\n\t return context ? {value: rhs} : rhs;\n\t };\n\t case AST.ArrayExpression:\n\t args = [];\n\t forEach(ast.elements, function(expr) {\n\t args.push(self.recurse(expr));\n\t });\n\t return function(scope, locals, assign, inputs) {\n\t var value = [];\n\t for (var i = 0; i < args.length; ++i) {\n\t value.push(args[i](scope, locals, assign, inputs));\n\t }\n\t return context ? {value: value} : value;\n\t };\n\t case AST.ObjectExpression:\n\t args = [];\n\t forEach(ast.properties, function(property) {\n\t args.push({key: property.key.type === AST.Identifier ?\n\t property.key.name :\n\t ('' + property.key.value),\n\t value: self.recurse(property.value)\n\t });\n\t });\n\t return function(scope, locals, assign, inputs) {\n\t var value = {};\n\t for (var i = 0; i < args.length; ++i) {\n\t value[args[i].key] = args[i].value(scope, locals, assign, inputs);\n\t }\n\t return context ? {value: value} : value;\n\t };\n\t case AST.ThisExpression:\n\t return function(scope) {\n\t return context ? {value: scope} : scope;\n\t };\n\t case AST.NGValueParameter:\n\t return function(scope, locals, assign, inputs) {\n\t return context ? {value: assign} : assign;\n\t };\n\t }\n\t },\n\t\n\t 'unary+': function(argument, context) {\n\t return function(scope, locals, assign, inputs) {\n\t var arg = argument(scope, locals, assign, inputs);\n\t if (isDefined(arg)) {\n\t arg = +arg;\n\t } else {\n\t arg = 0;\n\t }\n\t return context ? {value: arg} : arg;\n\t };\n\t },\n\t 'unary-': function(argument, context) {\n\t return function(scope, locals, assign, inputs) {\n\t var arg = argument(scope, locals, assign, inputs);\n\t if (isDefined(arg)) {\n\t arg = -arg;\n\t } else {\n\t arg = 0;\n\t }\n\t return context ? {value: arg} : arg;\n\t };\n\t },\n\t 'unary!': function(argument, context) {\n\t return function(scope, locals, assign, inputs) {\n\t var arg = !argument(scope, locals, assign, inputs);\n\t return context ? {value: arg} : arg;\n\t };\n\t },\n\t 'binary+': function(left, right, context) {\n\t return function(scope, locals, assign, inputs) {\n\t var lhs = left(scope, locals, assign, inputs);\n\t var rhs = right(scope, locals, assign, inputs);\n\t var arg = plusFn(lhs, rhs);\n\t return context ? {value: arg} : arg;\n\t };\n\t },\n\t 'binary-': function(left, right, context) {\n\t return function(scope, locals, assign, inputs) {\n\t var lhs = left(scope, locals, assign, inputs);\n\t var rhs = right(scope, locals, assign, inputs);\n\t var arg = (isDefined(lhs) ? lhs : 0) - (isDefined(rhs) ? rhs : 0);\n\t return context ? {value: arg} : arg;\n\t };\n\t },\n\t 'binary*': function(left, right, context) {\n\t return function(scope, locals, assign, inputs) {\n\t var arg = left(scope, locals, assign, inputs) * right(scope, locals, assign, inputs);\n\t return context ? {value: arg} : arg;\n\t };\n\t },\n\t 'binary/': function(left, right, context) {\n\t return function(scope, locals, assign, inputs) {\n\t var arg = left(scope, locals, assign, inputs) / right(scope, locals, assign, inputs);\n\t return context ? {value: arg} : arg;\n\t };\n\t },\n\t 'binary%': function(left, right, context) {\n\t return function(scope, locals, assign, inputs) {\n\t var arg = left(scope, locals, assign, inputs) % right(scope, locals, assign, inputs);\n\t return context ? {value: arg} : arg;\n\t };\n\t },\n\t 'binary===': function(left, right, context) {\n\t return function(scope, locals, assign, inputs) {\n\t var arg = left(scope, locals, assign, inputs) === right(scope, locals, assign, inputs);\n\t return context ? {value: arg} : arg;\n\t };\n\t },\n\t 'binary!==': function(left, right, context) {\n\t return function(scope, locals, assign, inputs) {\n\t var arg = left(scope, locals, assign, inputs) !== right(scope, locals, assign, inputs);\n\t return context ? {value: arg} : arg;\n\t };\n\t },\n\t 'binary==': function(left, right, context) {\n\t return function(scope, locals, assign, inputs) {\n\t var arg = left(scope, locals, assign, inputs) == right(scope, locals, assign, inputs);\n\t return context ? {value: arg} : arg;\n\t };\n\t },\n\t 'binary!=': function(left, right, context) {\n\t return function(scope, locals, assign, inputs) {\n\t var arg = left(scope, locals, assign, inputs) != right(scope, locals, assign, inputs);\n\t return context ? {value: arg} : arg;\n\t };\n\t },\n\t 'binary<': function(left, right, context) {\n\t return function(scope, locals, assign, inputs) {\n\t var arg = left(scope, locals, assign, inputs) < right(scope, locals, assign, inputs);\n\t return context ? {value: arg} : arg;\n\t };\n\t },\n\t 'binary>': function(left, right, context) {\n\t return function(scope, locals, assign, inputs) {\n\t var arg = left(scope, locals, assign, inputs) > right(scope, locals, assign, inputs);\n\t return context ? {value: arg} : arg;\n\t };\n\t },\n\t 'binary<=': function(left, right, context) {\n\t return function(scope, locals, assign, inputs) {\n\t var arg = left(scope, locals, assign, inputs) <= right(scope, locals, assign, inputs);\n\t return context ? {value: arg} : arg;\n\t };\n\t },\n\t 'binary>=': function(left, right, context) {\n\t return function(scope, locals, assign, inputs) {\n\t var arg = left(scope, locals, assign, inputs) >= right(scope, locals, assign, inputs);\n\t return context ? {value: arg} : arg;\n\t };\n\t },\n\t 'binary&&': function(left, right, context) {\n\t return function(scope, locals, assign, inputs) {\n\t var arg = left(scope, locals, assign, inputs) && right(scope, locals, assign, inputs);\n\t return context ? {value: arg} : arg;\n\t };\n\t },\n\t 'binary||': function(left, right, context) {\n\t return function(scope, locals, assign, inputs) {\n\t var arg = left(scope, locals, assign, inputs) || right(scope, locals, assign, inputs);\n\t return context ? {value: arg} : arg;\n\t };\n\t },\n\t 'ternary?:': function(test, alternate, consequent, context) {\n\t return function(scope, locals, assign, inputs) {\n\t var arg = test(scope, locals, assign, inputs) ? alternate(scope, locals, assign, inputs) : consequent(scope, locals, assign, inputs);\n\t return context ? {value: arg} : arg;\n\t };\n\t },\n\t value: function(value, context) {\n\t return function() { return context ? {context: undefined, name: undefined, value: value} : value; };\n\t },\n\t identifier: function(name, expensiveChecks, context, create, expression) {\n\t return function(scope, locals, assign, inputs) {\n\t var base = locals && (name in locals) ? locals : scope;\n\t if (create && create !== 1 && base && !(base[name])) {\n\t base[name] = {};\n\t }\n\t var value = base ? base[name] : undefined;\n\t if (expensiveChecks) {\n\t ensureSafeObject(value, expression);\n\t }\n\t if (context) {\n\t return {context: base, name: name, value: value};\n\t } else {\n\t return value;\n\t }\n\t };\n\t },\n\t computedMember: function(left, right, context, create, expression) {\n\t return function(scope, locals, assign, inputs) {\n\t var lhs = left(scope, locals, assign, inputs);\n\t var rhs;\n\t var value;\n\t if (lhs != null) {\n\t rhs = right(scope, locals, assign, inputs);\n\t rhs = getStringValue(rhs);\n\t ensureSafeMemberName(rhs, expression);\n\t if (create && create !== 1) {\n\t ensureSafeAssignContext(lhs);\n\t if (lhs && !(lhs[rhs])) {\n\t lhs[rhs] = {};\n\t }\n\t }\n\t value = lhs[rhs];\n\t ensureSafeObject(value, expression);\n\t }\n\t if (context) {\n\t return {context: lhs, name: rhs, value: value};\n\t } else {\n\t return value;\n\t }\n\t };\n\t },\n\t nonComputedMember: function(left, right, expensiveChecks, context, create, expression) {\n\t return function(scope, locals, assign, inputs) {\n\t var lhs = left(scope, locals, assign, inputs);\n\t if (create && create !== 1) {\n\t ensureSafeAssignContext(lhs);\n\t if (lhs && !(lhs[right])) {\n\t lhs[right] = {};\n\t }\n\t }\n\t var value = lhs != null ? lhs[right] : undefined;\n\t if (expensiveChecks || isPossiblyDangerousMemberName(right)) {\n\t ensureSafeObject(value, expression);\n\t }\n\t if (context) {\n\t return {context: lhs, name: right, value: value};\n\t } else {\n\t return value;\n\t }\n\t };\n\t },\n\t inputs: function(input, watchId) {\n\t return function(scope, value, locals, inputs) {\n\t if (inputs) return inputs[watchId];\n\t return input(scope, value, locals);\n\t };\n\t }\n\t};\n\t\n\t/**\n\t * @constructor\n\t */\n\tvar Parser = function(lexer, $filter, options) {\n\t this.lexer = lexer;\n\t this.$filter = $filter;\n\t this.options = options;\n\t this.ast = new AST(this.lexer);\n\t this.astCompiler = options.csp ? new ASTInterpreter(this.ast, $filter) :\n\t new ASTCompiler(this.ast, $filter);\n\t};\n\t\n\tParser.prototype = {\n\t constructor: Parser,\n\t\n\t parse: function(text) {\n\t return this.astCompiler.compile(text, this.options.expensiveChecks);\n\t }\n\t};\n\t\n\tfunction isPossiblyDangerousMemberName(name) {\n\t return name == 'constructor';\n\t}\n\t\n\tvar objectValueOf = Object.prototype.valueOf;\n\t\n\tfunction getValueOf(value) {\n\t return isFunction(value.valueOf) ? value.valueOf() : objectValueOf.call(value);\n\t}\n\t\n\t///////////////////////////////////\n\t\n\t/**\n\t * @ngdoc service\n\t * @name $parse\n\t * @kind function\n\t *\n\t * @description\n\t *\n\t * Converts Angular {@link guide/expression expression} into a function.\n\t *\n\t * ```js\n\t * var getter = $parse('user.name');\n\t * var setter = getter.assign;\n\t * var context = {user:{name:'angular'}};\n\t * var locals = {user:{name:'local'}};\n\t *\n\t * expect(getter(context)).toEqual('angular');\n\t * setter(context, 'newValue');\n\t * expect(context.user.name).toEqual('newValue');\n\t * expect(getter(context, locals)).toEqual('local');\n\t * ```\n\t *\n\t *\n\t * @param {string} expression String expression to compile.\n\t * @returns {function(context, locals)} a function which represents the compiled expression:\n\t *\n\t * * `context` – `{object}` – an object against which any expressions embedded in the strings\n\t * are evaluated against (typically a scope object).\n\t * * `locals` – `{object=}` – local variables context object, useful for overriding values in\n\t * `context`.\n\t *\n\t * The returned function also has the following properties:\n\t * * `literal` – `{boolean}` – whether the expression's top-level node is a JavaScript\n\t * literal.\n\t * * `constant` – `{boolean}` – whether the expression is made entirely of JavaScript\n\t * constant literals.\n\t * * `assign` – `{?function(context, value)}` – if the expression is assignable, this will be\n\t * set to a function to change its value on the given context.\n\t *\n\t */\n\t\n\t\n\t/**\n\t * @ngdoc provider\n\t * @name $parseProvider\n\t *\n\t * @description\n\t * `$parseProvider` can be used for configuring the default behavior of the {@link ng.$parse $parse}\n\t * service.\n\t */\n\tfunction $ParseProvider() {\n\t var cacheDefault = createMap();\n\t var cacheExpensive = createMap();\n\t\n\t this.$get = ['$filter', function($filter) {\n\t var noUnsafeEval = csp().noUnsafeEval;\n\t var $parseOptions = {\n\t csp: noUnsafeEval,\n\t expensiveChecks: false\n\t },\n\t $parseOptionsExpensive = {\n\t csp: noUnsafeEval,\n\t expensiveChecks: true\n\t };\n\t var runningChecksEnabled = false;\n\t\n\t $parse.$$runningExpensiveChecks = function() {\n\t return runningChecksEnabled;\n\t };\n\t\n\t return $parse;\n\t\n\t function $parse(exp, interceptorFn, expensiveChecks) {\n\t var parsedExpression, oneTime, cacheKey;\n\t\n\t expensiveChecks = expensiveChecks || runningChecksEnabled;\n\t\n\t switch (typeof exp) {\n\t case 'string':\n\t exp = exp.trim();\n\t cacheKey = exp;\n\t\n\t var cache = (expensiveChecks ? cacheExpensive : cacheDefault);\n\t parsedExpression = cache[cacheKey];\n\t\n\t if (!parsedExpression) {\n\t if (exp.charAt(0) === ':' && exp.charAt(1) === ':') {\n\t oneTime = true;\n\t exp = exp.substring(2);\n\t }\n\t var parseOptions = expensiveChecks ? $parseOptionsExpensive : $parseOptions;\n\t var lexer = new Lexer(parseOptions);\n\t var parser = new Parser(lexer, $filter, parseOptions);\n\t parsedExpression = parser.parse(exp);\n\t if (parsedExpression.constant) {\n\t parsedExpression.$$watchDelegate = constantWatchDelegate;\n\t } else if (oneTime) {\n\t parsedExpression.$$watchDelegate = parsedExpression.literal ?\n\t oneTimeLiteralWatchDelegate : oneTimeWatchDelegate;\n\t } else if (parsedExpression.inputs) {\n\t parsedExpression.$$watchDelegate = inputsWatchDelegate;\n\t }\n\t if (expensiveChecks) {\n\t parsedExpression = expensiveChecksInterceptor(parsedExpression);\n\t }\n\t cache[cacheKey] = parsedExpression;\n\t }\n\t return addInterceptor(parsedExpression, interceptorFn);\n\t\n\t case 'function':\n\t return addInterceptor(exp, interceptorFn);\n\t\n\t default:\n\t return addInterceptor(noop, interceptorFn);\n\t }\n\t }\n\t\n\t function expensiveChecksInterceptor(fn) {\n\t if (!fn) return fn;\n\t expensiveCheckFn.$$watchDelegate = fn.$$watchDelegate;\n\t expensiveCheckFn.assign = expensiveChecksInterceptor(fn.assign);\n\t expensiveCheckFn.constant = fn.constant;\n\t expensiveCheckFn.literal = fn.literal;\n\t for (var i = 0; fn.inputs && i < fn.inputs.length; ++i) {\n\t fn.inputs[i] = expensiveChecksInterceptor(fn.inputs[i]);\n\t }\n\t expensiveCheckFn.inputs = fn.inputs;\n\t\n\t return expensiveCheckFn;\n\t\n\t function expensiveCheckFn(scope, locals, assign, inputs) {\n\t var expensiveCheckOldValue = runningChecksEnabled;\n\t runningChecksEnabled = true;\n\t try {\n\t return fn(scope, locals, assign, inputs);\n\t } finally {\n\t runningChecksEnabled = expensiveCheckOldValue;\n\t }\n\t }\n\t }\n\t\n\t function expressionInputDirtyCheck(newValue, oldValueOfValue) {\n\t\n\t if (newValue == null || oldValueOfValue == null) { // null/undefined\n\t return newValue === oldValueOfValue;\n\t }\n\t\n\t if (typeof newValue === 'object') {\n\t\n\t // attempt to convert the value to a primitive type\n\t // TODO(docs): add a note to docs that by implementing valueOf even objects and arrays can\n\t // be cheaply dirty-checked\n\t newValue = getValueOf(newValue);\n\t\n\t if (typeof newValue === 'object') {\n\t // objects/arrays are not supported - deep-watching them would be too expensive\n\t return false;\n\t }\n\t\n\t // fall-through to the primitive equality check\n\t }\n\t\n\t //Primitive or NaN\n\t return newValue === oldValueOfValue || (newValue !== newValue && oldValueOfValue !== oldValueOfValue);\n\t }\n\t\n\t function inputsWatchDelegate(scope, listener, objectEquality, parsedExpression, prettyPrintExpression) {\n\t var inputExpressions = parsedExpression.inputs;\n\t var lastResult;\n\t\n\t if (inputExpressions.length === 1) {\n\t var oldInputValueOf = expressionInputDirtyCheck; // init to something unique so that equals check fails\n\t inputExpressions = inputExpressions[0];\n\t return scope.$watch(function expressionInputWatch(scope) {\n\t var newInputValue = inputExpressions(scope);\n\t if (!expressionInputDirtyCheck(newInputValue, oldInputValueOf)) {\n\t lastResult = parsedExpression(scope, undefined, undefined, [newInputValue]);\n\t oldInputValueOf = newInputValue && getValueOf(newInputValue);\n\t }\n\t return lastResult;\n\t }, listener, objectEquality, prettyPrintExpression);\n\t }\n\t\n\t var oldInputValueOfValues = [];\n\t var oldInputValues = [];\n\t for (var i = 0, ii = inputExpressions.length; i < ii; i++) {\n\t oldInputValueOfValues[i] = expressionInputDirtyCheck; // init to something unique so that equals check fails\n\t oldInputValues[i] = null;\n\t }\n\t\n\t return scope.$watch(function expressionInputsWatch(scope) {\n\t var changed = false;\n\t\n\t for (var i = 0, ii = inputExpressions.length; i < ii; i++) {\n\t var newInputValue = inputExpressions[i](scope);\n\t if (changed || (changed = !expressionInputDirtyCheck(newInputValue, oldInputValueOfValues[i]))) {\n\t oldInputValues[i] = newInputValue;\n\t oldInputValueOfValues[i] = newInputValue && getValueOf(newInputValue);\n\t }\n\t }\n\t\n\t if (changed) {\n\t lastResult = parsedExpression(scope, undefined, undefined, oldInputValues);\n\t }\n\t\n\t return lastResult;\n\t }, listener, objectEquality, prettyPrintExpression);\n\t }\n\t\n\t function oneTimeWatchDelegate(scope, listener, objectEquality, parsedExpression) {\n\t var unwatch, lastValue;\n\t return unwatch = scope.$watch(function oneTimeWatch(scope) {\n\t return parsedExpression(scope);\n\t }, function oneTimeListener(value, old, scope) {\n\t lastValue = value;\n\t if (isFunction(listener)) {\n\t listener.apply(this, arguments);\n\t }\n\t if (isDefined(value)) {\n\t scope.$$postDigest(function() {\n\t if (isDefined(lastValue)) {\n\t unwatch();\n\t }\n\t });\n\t }\n\t }, objectEquality);\n\t }\n\t\n\t function oneTimeLiteralWatchDelegate(scope, listener, objectEquality, parsedExpression) {\n\t var unwatch, lastValue;\n\t return unwatch = scope.$watch(function oneTimeWatch(scope) {\n\t return parsedExpression(scope);\n\t }, function oneTimeListener(value, old, scope) {\n\t lastValue = value;\n\t if (isFunction(listener)) {\n\t listener.call(this, value, old, scope);\n\t }\n\t if (isAllDefined(value)) {\n\t scope.$$postDigest(function() {\n\t if (isAllDefined(lastValue)) unwatch();\n\t });\n\t }\n\t }, objectEquality);\n\t\n\t function isAllDefined(value) {\n\t var allDefined = true;\n\t forEach(value, function(val) {\n\t if (!isDefined(val)) allDefined = false;\n\t });\n\t return allDefined;\n\t }\n\t }\n\t\n\t function constantWatchDelegate(scope, listener, objectEquality, parsedExpression) {\n\t var unwatch;\n\t return unwatch = scope.$watch(function constantWatch(scope) {\n\t return parsedExpression(scope);\n\t }, function constantListener(value, old, scope) {\n\t if (isFunction(listener)) {\n\t listener.apply(this, arguments);\n\t }\n\t unwatch();\n\t }, objectEquality);\n\t }\n\t\n\t function addInterceptor(parsedExpression, interceptorFn) {\n\t if (!interceptorFn) return parsedExpression;\n\t var watchDelegate = parsedExpression.$$watchDelegate;\n\t var useInputs = false;\n\t\n\t var regularWatch =\n\t watchDelegate !== oneTimeLiteralWatchDelegate &&\n\t watchDelegate !== oneTimeWatchDelegate;\n\t\n\t var fn = regularWatch ? function regularInterceptedExpression(scope, locals, assign, inputs) {\n\t var value = useInputs && inputs ? inputs[0] : parsedExpression(scope, locals, assign, inputs);\n\t return interceptorFn(value, scope, locals);\n\t } : function oneTimeInterceptedExpression(scope, locals, assign, inputs) {\n\t var value = parsedExpression(scope, locals, assign, inputs);\n\t var result = interceptorFn(value, scope, locals);\n\t // we only return the interceptor's result if the\n\t // initial value is defined (for bind-once)\n\t return isDefined(value) ? result : value;\n\t };\n\t\n\t // Propagate $$watchDelegates other then inputsWatchDelegate\n\t if (parsedExpression.$$watchDelegate &&\n\t parsedExpression.$$watchDelegate !== inputsWatchDelegate) {\n\t fn.$$watchDelegate = parsedExpression.$$watchDelegate;\n\t } else if (!interceptorFn.$stateful) {\n\t // If there is an interceptor, but no watchDelegate then treat the interceptor like\n\t // we treat filters - it is assumed to be a pure function unless flagged with $stateful\n\t fn.$$watchDelegate = inputsWatchDelegate;\n\t useInputs = !parsedExpression.inputs;\n\t fn.inputs = parsedExpression.inputs ? parsedExpression.inputs : [parsedExpression];\n\t }\n\t\n\t return fn;\n\t }\n\t }];\n\t}\n\t\n\t/**\n\t * @ngdoc service\n\t * @name $q\n\t * @requires $rootScope\n\t *\n\t * @description\n\t * A service that helps you run functions asynchronously, and use their return values (or exceptions)\n\t * when they are done processing.\n\t *\n\t * This is an implementation of promises/deferred objects inspired by\n\t * [Kris Kowal's Q](https://github.com/kriskowal/q).\n\t *\n\t * $q can be used in two fashions --- one which is more similar to Kris Kowal's Q or jQuery's Deferred\n\t * implementations, and the other which resembles ES6 (ES2015) promises to some degree.\n\t *\n\t * # $q constructor\n\t *\n\t * The streamlined ES6 style promise is essentially just using $q as a constructor which takes a `resolver`\n\t * function as the first argument. This is similar to the native Promise implementation from ES6,\n\t * see [MDN](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise).\n\t *\n\t * While the constructor-style use is supported, not all of the supporting methods from ES6 promises are\n\t * available yet.\n\t *\n\t * It can be used like so:\n\t *\n\t * ```js\n\t * // for the purpose of this example let's assume that variables `$q` and `okToGreet`\n\t * // are available in the current lexical scope (they could have been injected or passed in).\n\t *\n\t * function asyncGreet(name) {\n\t * // perform some asynchronous operation, resolve or reject the promise when appropriate.\n\t * return $q(function(resolve, reject) {\n\t * setTimeout(function() {\n\t * if (okToGreet(name)) {\n\t * resolve('Hello, ' + name + '!');\n\t * } else {\n\t * reject('Greeting ' + name + ' is not allowed.');\n\t * }\n\t * }, 1000);\n\t * });\n\t * }\n\t *\n\t * var promise = asyncGreet('Robin Hood');\n\t * promise.then(function(greeting) {\n\t * alert('Success: ' + greeting);\n\t * }, function(reason) {\n\t * alert('Failed: ' + reason);\n\t * });\n\t * ```\n\t *\n\t * Note: progress/notify callbacks are not currently supported via the ES6-style interface.\n\t *\n\t * Note: unlike ES6 behaviour, an exception thrown in the constructor function will NOT implicitly reject the promise.\n\t *\n\t * However, the more traditional CommonJS-style usage is still available, and documented below.\n\t *\n\t * [The CommonJS Promise proposal](http://wiki.commonjs.org/wiki/Promises) describes a promise as an\n\t * interface for interacting with an object that represents the result of an action that is\n\t * performed asynchronously, and may or may not be finished at any given point in time.\n\t *\n\t * From the perspective of dealing with error handling, deferred and promise APIs are to\n\t * asynchronous programming what `try`, `catch` and `throw` keywords are to synchronous programming.\n\t *\n\t * ```js\n\t * // for the purpose of this example let's assume that variables `$q` and `okToGreet`\n\t * // are available in the current lexical scope (they could have been injected or passed in).\n\t *\n\t * function asyncGreet(name) {\n\t * var deferred = $q.defer();\n\t *\n\t * setTimeout(function() {\n\t * deferred.notify('About to greet ' + name + '.');\n\t *\n\t * if (okToGreet(name)) {\n\t * deferred.resolve('Hello, ' + name + '!');\n\t * } else {\n\t * deferred.reject('Greeting ' + name + ' is not allowed.');\n\t * }\n\t * }, 1000);\n\t *\n\t * return deferred.promise;\n\t * }\n\t *\n\t * var promise = asyncGreet('Robin Hood');\n\t * promise.then(function(greeting) {\n\t * alert('Success: ' + greeting);\n\t * }, function(reason) {\n\t * alert('Failed: ' + reason);\n\t * }, function(update) {\n\t * alert('Got notification: ' + update);\n\t * });\n\t * ```\n\t *\n\t * At first it might not be obvious why this extra complexity is worth the trouble. The payoff\n\t * comes in the way of guarantees that promise and deferred APIs make, see\n\t * https://github.com/kriskowal/uncommonjs/blob/master/promises/specification.md.\n\t *\n\t * Additionally the promise api allows for composition that is very hard to do with the\n\t * traditional callback ([CPS](http://en.wikipedia.org/wiki/Continuation-passing_style)) approach.\n\t * For more on this please see the [Q documentation](https://github.com/kriskowal/q) especially the\n\t * section on serial or parallel joining of promises.\n\t *\n\t * # The Deferred API\n\t *\n\t * A new instance of deferred is constructed by calling `$q.defer()`.\n\t *\n\t * The purpose of the deferred object is to expose the associated Promise instance as well as APIs\n\t * that can be used for signaling the successful or unsuccessful completion, as well as the status\n\t * of the task.\n\t *\n\t * **Methods**\n\t *\n\t * - `resolve(value)` – resolves the derived promise with the `value`. If the value is a rejection\n\t * constructed via `$q.reject`, the promise will be rejected instead.\n\t * - `reject(reason)` – rejects the derived promise with the `reason`. This is equivalent to\n\t * resolving it with a rejection constructed via `$q.reject`.\n\t * - `notify(value)` - provides updates on the status of the promise's execution. This may be called\n\t * multiple times before the promise is either resolved or rejected.\n\t *\n\t * **Properties**\n\t *\n\t * - promise – `{Promise}` – promise object associated with this deferred.\n\t *\n\t *\n\t * # The Promise API\n\t *\n\t * A new promise instance is created when a deferred instance is created and can be retrieved by\n\t * calling `deferred.promise`.\n\t *\n\t * The purpose of the promise object is to allow for interested parties to get access to the result\n\t * of the deferred task when it completes.\n\t *\n\t * **Methods**\n\t *\n\t * - `then(successCallback, errorCallback, notifyCallback)` – regardless of when the promise was or\n\t * will be resolved or rejected, `then` calls one of the success or error callbacks asynchronously\n\t * as soon as the result is available. The callbacks are called with a single argument: the result\n\t * or rejection reason. Additionally, the notify callback may be called zero or more times to\n\t * provide a progress indication, before the promise is resolved or rejected.\n\t *\n\t * This method *returns a new promise* which is resolved or rejected via the return value of the\n\t * `successCallback`, `errorCallback` (unless that value is a promise, in which case it is resolved\n\t * with the value which is resolved in that promise using\n\t * [promise chaining](http://www.html5rocks.com/en/tutorials/es6/promises/#toc-promises-queues)).\n\t * It also notifies via the return value of the `notifyCallback` method. The promise cannot be\n\t * resolved or rejected from the notifyCallback method.\n\t *\n\t * - `catch(errorCallback)` – shorthand for `promise.then(null, errorCallback)`\n\t *\n\t * - `finally(callback, notifyCallback)` – allows you to observe either the fulfillment or rejection of a promise,\n\t * but to do so without modifying the final value. This is useful to release resources or do some\n\t * clean-up that needs to be done whether the promise was rejected or resolved. See the [full\n\t * specification](https://github.com/kriskowal/q/wiki/API-Reference#promisefinallycallback) for\n\t * more information.\n\t *\n\t * # Chaining promises\n\t *\n\t * Because calling the `then` method of a promise returns a new derived promise, it is easily\n\t * possible to create a chain of promises:\n\t *\n\t * ```js\n\t * promiseB = promiseA.then(function(result) {\n\t * return result + 1;\n\t * });\n\t *\n\t * // promiseB will be resolved immediately after promiseA is resolved and its value\n\t * // will be the result of promiseA incremented by 1\n\t * ```\n\t *\n\t * It is possible to create chains of any length and since a promise can be resolved with another\n\t * promise (which will defer its resolution further), it is possible to pause/defer resolution of\n\t * the promises at any point in the chain. This makes it possible to implement powerful APIs like\n\t * $http's response interceptors.\n\t *\n\t *\n\t * # Differences between Kris Kowal's Q and $q\n\t *\n\t * There are two main differences:\n\t *\n\t * - $q is integrated with the {@link ng.$rootScope.Scope} Scope model observation\n\t * mechanism in angular, which means faster propagation of resolution or rejection into your\n\t * models and avoiding unnecessary browser repaints, which would result in flickering UI.\n\t * - Q has many more features than $q, but that comes at a cost of bytes. $q is tiny, but contains\n\t * all the important functionality needed for common async tasks.\n\t *\n\t * # Testing\n\t *\n\t * ```js\n\t * it('should simulate promise', inject(function($q, $rootScope) {\n\t * var deferred = $q.defer();\n\t * var promise = deferred.promise;\n\t * var resolvedValue;\n\t *\n\t * promise.then(function(value) { resolvedValue = value; });\n\t * expect(resolvedValue).toBeUndefined();\n\t *\n\t * // Simulate resolving of promise\n\t * deferred.resolve(123);\n\t * // Note that the 'then' function does not get called synchronously.\n\t * // This is because we want the promise API to always be async, whether or not\n\t * // it got called synchronously or asynchronously.\n\t * expect(resolvedValue).toBeUndefined();\n\t *\n\t * // Propagate promise resolution to 'then' functions using $apply().\n\t * $rootScope.$apply();\n\t * expect(resolvedValue).toEqual(123);\n\t * }));\n\t * ```\n\t *\n\t * @param {function(function, function)} resolver Function which is responsible for resolving or\n\t * rejecting the newly created promise. The first parameter is a function which resolves the\n\t * promise, the second parameter is a function which rejects the promise.\n\t *\n\t * @returns {Promise} The newly created promise.\n\t */\n\tfunction $QProvider() {\n\t\n\t this.$get = ['$rootScope', '$exceptionHandler', function($rootScope, $exceptionHandler) {\n\t return qFactory(function(callback) {\n\t $rootScope.$evalAsync(callback);\n\t }, $exceptionHandler);\n\t }];\n\t}\n\t\n\tfunction $$QProvider() {\n\t this.$get = ['$browser', '$exceptionHandler', function($browser, $exceptionHandler) {\n\t return qFactory(function(callback) {\n\t $browser.defer(callback);\n\t }, $exceptionHandler);\n\t }];\n\t}\n\t\n\t/**\n\t * Constructs a promise manager.\n\t *\n\t * @param {function(function)} nextTick Function for executing functions in the next turn.\n\t * @param {function(...*)} exceptionHandler Function into which unexpected exceptions are passed for\n\t * debugging purposes.\n\t * @returns {object} Promise manager.\n\t */\n\tfunction qFactory(nextTick, exceptionHandler) {\n\t var $qMinErr = minErr('$q', TypeError);\n\t function callOnce(self, resolveFn, rejectFn) {\n\t var called = false;\n\t function wrap(fn) {\n\t return function(value) {\n\t if (called) return;\n\t called = true;\n\t fn.call(self, value);\n\t };\n\t }\n\t\n\t return [wrap(resolveFn), wrap(rejectFn)];\n\t }\n\t\n\t /**\n\t * @ngdoc method\n\t * @name ng.$q#defer\n\t * @kind function\n\t *\n\t * @description\n\t * Creates a `Deferred` object which represents a task which will finish in the future.\n\t *\n\t * @returns {Deferred} Returns a new instance of deferred.\n\t */\n\t var defer = function() {\n\t return new Deferred();\n\t };\n\t\n\t function Promise() {\n\t this.$$state = { status: 0 };\n\t }\n\t\n\t extend(Promise.prototype, {\n\t then: function(onFulfilled, onRejected, progressBack) {\n\t if (isUndefined(onFulfilled) && isUndefined(onRejected) && isUndefined(progressBack)) {\n\t return this;\n\t }\n\t var result = new Deferred();\n\t\n\t this.$$state.pending = this.$$state.pending || [];\n\t this.$$state.pending.push([result, onFulfilled, onRejected, progressBack]);\n\t if (this.$$state.status > 0) scheduleProcessQueue(this.$$state);\n\t\n\t return result.promise;\n\t },\n\t\n\t \"catch\": function(callback) {\n\t return this.then(null, callback);\n\t },\n\t\n\t \"finally\": function(callback, progressBack) {\n\t return this.then(function(value) {\n\t return handleCallback(value, true, callback);\n\t }, function(error) {\n\t return handleCallback(error, false, callback);\n\t }, progressBack);\n\t }\n\t });\n\t\n\t //Faster, more basic than angular.bind http://jsperf.com/angular-bind-vs-custom-vs-native\n\t function simpleBind(context, fn) {\n\t return function(value) {\n\t fn.call(context, value);\n\t };\n\t }\n\t\n\t function processQueue(state) {\n\t var fn, deferred, pending;\n\t\n\t pending = state.pending;\n\t state.processScheduled = false;\n\t state.pending = undefined;\n\t for (var i = 0, ii = pending.length; i < ii; ++i) {\n\t deferred = pending[i][0];\n\t fn = pending[i][state.status];\n\t try {\n\t if (isFunction(fn)) {\n\t deferred.resolve(fn(state.value));\n\t } else if (state.status === 1) {\n\t deferred.resolve(state.value);\n\t } else {\n\t deferred.reject(state.value);\n\t }\n\t } catch (e) {\n\t deferred.reject(e);\n\t exceptionHandler(e);\n\t }\n\t }\n\t }\n\t\n\t function scheduleProcessQueue(state) {\n\t if (state.processScheduled || !state.pending) return;\n\t state.processScheduled = true;\n\t nextTick(function() { processQueue(state); });\n\t }\n\t\n\t function Deferred() {\n\t this.promise = new Promise();\n\t //Necessary to support unbound execution :/\n\t this.resolve = simpleBind(this, this.resolve);\n\t this.reject = simpleBind(this, this.reject);\n\t this.notify = simpleBind(this, this.notify);\n\t }\n\t\n\t extend(Deferred.prototype, {\n\t resolve: function(val) {\n\t if (this.promise.$$state.status) return;\n\t if (val === this.promise) {\n\t this.$$reject($qMinErr(\n\t 'qcycle',\n\t \"Expected promise to be resolved with value other than itself '{0}'\",\n\t val));\n\t } else {\n\t this.$$resolve(val);\n\t }\n\t\n\t },\n\t\n\t $$resolve: function(val) {\n\t var then, fns;\n\t\n\t fns = callOnce(this, this.$$resolve, this.$$reject);\n\t try {\n\t if ((isObject(val) || isFunction(val))) then = val && val.then;\n\t if (isFunction(then)) {\n\t this.promise.$$state.status = -1;\n\t then.call(val, fns[0], fns[1], this.notify);\n\t } else {\n\t this.promise.$$state.value = val;\n\t this.promise.$$state.status = 1;\n\t scheduleProcessQueue(this.promise.$$state);\n\t }\n\t } catch (e) {\n\t fns[1](e);\n\t exceptionHandler(e);\n\t }\n\t },\n\t\n\t reject: function(reason) {\n\t if (this.promise.$$state.status) return;\n\t this.$$reject(reason);\n\t },\n\t\n\t $$reject: function(reason) {\n\t this.promise.$$state.value = reason;\n\t this.promise.$$state.status = 2;\n\t scheduleProcessQueue(this.promise.$$state);\n\t },\n\t\n\t notify: function(progress) {\n\t var callbacks = this.promise.$$state.pending;\n\t\n\t if ((this.promise.$$state.status <= 0) && callbacks && callbacks.length) {\n\t nextTick(function() {\n\t var callback, result;\n\t for (var i = 0, ii = callbacks.length; i < ii; i++) {\n\t result = callbacks[i][0];\n\t callback = callbacks[i][3];\n\t try {\n\t result.notify(isFunction(callback) ? callback(progress) : progress);\n\t } catch (e) {\n\t exceptionHandler(e);\n\t }\n\t }\n\t });\n\t }\n\t }\n\t });\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $q#reject\n\t * @kind function\n\t *\n\t * @description\n\t * Creates a promise that is resolved as rejected with the specified `reason`. This api should be\n\t * used to forward rejection in a chain of promises. If you are dealing with the last promise in\n\t * a promise chain, you don't need to worry about it.\n\t *\n\t * When comparing deferreds/promises to the familiar behavior of try/catch/throw, think of\n\t * `reject` as the `throw` keyword in JavaScript. This also means that if you \"catch\" an error via\n\t * a promise error callback and you want to forward the error to the promise derived from the\n\t * current promise, you have to \"rethrow\" the error by returning a rejection constructed via\n\t * `reject`.\n\t *\n\t * ```js\n\t * promiseB = promiseA.then(function(result) {\n\t * // success: do something and resolve promiseB\n\t * // with the old or a new result\n\t * return result;\n\t * }, function(reason) {\n\t * // error: handle the error if possible and\n\t * // resolve promiseB with newPromiseOrValue,\n\t * // otherwise forward the rejection to promiseB\n\t * if (canHandle(reason)) {\n\t * // handle the error and recover\n\t * return newPromiseOrValue;\n\t * }\n\t * return $q.reject(reason);\n\t * });\n\t * ```\n\t *\n\t * @param {*} reason Constant, message, exception or an object representing the rejection reason.\n\t * @returns {Promise} Returns a promise that was already resolved as rejected with the `reason`.\n\t */\n\t var reject = function(reason) {\n\t var result = new Deferred();\n\t result.reject(reason);\n\t return result.promise;\n\t };\n\t\n\t var makePromise = function makePromise(value, resolved) {\n\t var result = new Deferred();\n\t if (resolved) {\n\t result.resolve(value);\n\t } else {\n\t result.reject(value);\n\t }\n\t return result.promise;\n\t };\n\t\n\t var handleCallback = function handleCallback(value, isResolved, callback) {\n\t var callbackOutput = null;\n\t try {\n\t if (isFunction(callback)) callbackOutput = callback();\n\t } catch (e) {\n\t return makePromise(e, false);\n\t }\n\t if (isPromiseLike(callbackOutput)) {\n\t return callbackOutput.then(function() {\n\t return makePromise(value, isResolved);\n\t }, function(error) {\n\t return makePromise(error, false);\n\t });\n\t } else {\n\t return makePromise(value, isResolved);\n\t }\n\t };\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $q#when\n\t * @kind function\n\t *\n\t * @description\n\t * Wraps an object that might be a value or a (3rd party) then-able promise into a $q promise.\n\t * This is useful when you are dealing with an object that might or might not be a promise, or if\n\t * the promise comes from a source that can't be trusted.\n\t *\n\t * @param {*} value Value or a promise\n\t * @param {Function=} successCallback\n\t * @param {Function=} errorCallback\n\t * @param {Function=} progressCallback\n\t * @returns {Promise} Returns a promise of the passed value or promise\n\t */\n\t\n\t\n\t var when = function(value, callback, errback, progressBack) {\n\t var result = new Deferred();\n\t result.resolve(value);\n\t return result.promise.then(callback, errback, progressBack);\n\t };\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $q#resolve\n\t * @kind function\n\t *\n\t * @description\n\t * Alias of {@link ng.$q#when when} to maintain naming consistency with ES6.\n\t *\n\t * @param {*} value Value or a promise\n\t * @param {Function=} successCallback\n\t * @param {Function=} errorCallback\n\t * @param {Function=} progressCallback\n\t * @returns {Promise} Returns a promise of the passed value or promise\n\t */\n\t var resolve = when;\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $q#all\n\t * @kind function\n\t *\n\t * @description\n\t * Combines multiple promises into a single promise that is resolved when all of the input\n\t * promises are resolved.\n\t *\n\t * @param {Array.|Object.} promises An array or hash of promises.\n\t * @returns {Promise} Returns a single promise that will be resolved with an array/hash of values,\n\t * each value corresponding to the promise at the same index/key in the `promises` array/hash.\n\t * If any of the promises is resolved with a rejection, this resulting promise will be rejected\n\t * with the same rejection value.\n\t */\n\t\n\t function all(promises) {\n\t var deferred = new Deferred(),\n\t counter = 0,\n\t results = isArray(promises) ? [] : {};\n\t\n\t forEach(promises, function(promise, key) {\n\t counter++;\n\t when(promise).then(function(value) {\n\t if (results.hasOwnProperty(key)) return;\n\t results[key] = value;\n\t if (!(--counter)) deferred.resolve(results);\n\t }, function(reason) {\n\t if (results.hasOwnProperty(key)) return;\n\t deferred.reject(reason);\n\t });\n\t });\n\t\n\t if (counter === 0) {\n\t deferred.resolve(results);\n\t }\n\t\n\t return deferred.promise;\n\t }\n\t\n\t var $Q = function Q(resolver) {\n\t if (!isFunction(resolver)) {\n\t throw $qMinErr('norslvr', \"Expected resolverFn, got '{0}'\", resolver);\n\t }\n\t\n\t if (!(this instanceof Q)) {\n\t // More useful when $Q is the Promise itself.\n\t return new Q(resolver);\n\t }\n\t\n\t var deferred = new Deferred();\n\t\n\t function resolveFn(value) {\n\t deferred.resolve(value);\n\t }\n\t\n\t function rejectFn(reason) {\n\t deferred.reject(reason);\n\t }\n\t\n\t resolver(resolveFn, rejectFn);\n\t\n\t return deferred.promise;\n\t };\n\t\n\t $Q.defer = defer;\n\t $Q.reject = reject;\n\t $Q.when = when;\n\t $Q.resolve = resolve;\n\t $Q.all = all;\n\t\n\t return $Q;\n\t}\n\t\n\tfunction $$RAFProvider() { //rAF\n\t this.$get = ['$window', '$timeout', function($window, $timeout) {\n\t var requestAnimationFrame = $window.requestAnimationFrame ||\n\t $window.webkitRequestAnimationFrame;\n\t\n\t var cancelAnimationFrame = $window.cancelAnimationFrame ||\n\t $window.webkitCancelAnimationFrame ||\n\t $window.webkitCancelRequestAnimationFrame;\n\t\n\t var rafSupported = !!requestAnimationFrame;\n\t var raf = rafSupported\n\t ? function(fn) {\n\t var id = requestAnimationFrame(fn);\n\t return function() {\n\t cancelAnimationFrame(id);\n\t };\n\t }\n\t : function(fn) {\n\t var timer = $timeout(fn, 16.66, false); // 1000 / 60 = 16.666\n\t return function() {\n\t $timeout.cancel(timer);\n\t };\n\t };\n\t\n\t raf.supported = rafSupported;\n\t\n\t return raf;\n\t }];\n\t}\n\t\n\t/**\n\t * DESIGN NOTES\n\t *\n\t * The design decisions behind the scope are heavily favored for speed and memory consumption.\n\t *\n\t * The typical use of scope is to watch the expressions, which most of the time return the same\n\t * value as last time so we optimize the operation.\n\t *\n\t * Closures construction is expensive in terms of speed as well as memory:\n\t * - No closures, instead use prototypical inheritance for API\n\t * - Internal state needs to be stored on scope directly, which means that private state is\n\t * exposed as $$____ properties\n\t *\n\t * Loop operations are optimized by using while(count--) { ... }\n\t * - This means that in order to keep the same order of execution as addition we have to add\n\t * items to the array at the beginning (unshift) instead of at the end (push)\n\t *\n\t * Child scopes are created and removed often\n\t * - Using an array would be slow since inserts in the middle are expensive; so we use linked lists\n\t *\n\t * There are fewer watches than observers. This is why you don't want the observer to be implemented\n\t * in the same way as watch. Watch requires return of the initialization function which is expensive\n\t * to construct.\n\t */\n\t\n\t\n\t/**\n\t * @ngdoc provider\n\t * @name $rootScopeProvider\n\t * @description\n\t *\n\t * Provider for the $rootScope service.\n\t */\n\t\n\t/**\n\t * @ngdoc method\n\t * @name $rootScopeProvider#digestTtl\n\t * @description\n\t *\n\t * Sets the number of `$digest` iterations the scope should attempt to execute before giving up and\n\t * assuming that the model is unstable.\n\t *\n\t * The current default is 10 iterations.\n\t *\n\t * In complex applications it's possible that the dependencies between `$watch`s will result in\n\t * several digest iterations. However if an application needs more than the default 10 digest\n\t * iterations for its model to stabilize then you should investigate what is causing the model to\n\t * continuously change during the digest.\n\t *\n\t * Increasing the TTL could have performance implications, so you should not change it without\n\t * proper justification.\n\t *\n\t * @param {number} limit The number of digest iterations.\n\t */\n\t\n\t\n\t/**\n\t * @ngdoc service\n\t * @name $rootScope\n\t * @description\n\t *\n\t * Every application has a single root {@link ng.$rootScope.Scope scope}.\n\t * All other scopes are descendant scopes of the root scope. Scopes provide separation\n\t * between the model and the view, via a mechanism for watching the model for changes.\n\t * They also provide event emission/broadcast and subscription facility. See the\n\t * {@link guide/scope developer guide on scopes}.\n\t */\n\tfunction $RootScopeProvider() {\n\t var TTL = 10;\n\t var $rootScopeMinErr = minErr('$rootScope');\n\t var lastDirtyWatch = null;\n\t var applyAsyncId = null;\n\t\n\t this.digestTtl = function(value) {\n\t if (arguments.length) {\n\t TTL = value;\n\t }\n\t return TTL;\n\t };\n\t\n\t function createChildScopeClass(parent) {\n\t function ChildScope() {\n\t this.$$watchers = this.$$nextSibling =\n\t this.$$childHead = this.$$childTail = null;\n\t this.$$listeners = {};\n\t this.$$listenerCount = {};\n\t this.$$watchersCount = 0;\n\t this.$id = nextUid();\n\t this.$$ChildScope = null;\n\t }\n\t ChildScope.prototype = parent;\n\t return ChildScope;\n\t }\n\t\n\t this.$get = ['$injector', '$exceptionHandler', '$parse', '$browser',\n\t function($injector, $exceptionHandler, $parse, $browser) {\n\t\n\t function destroyChildScope($event) {\n\t $event.currentScope.$$destroyed = true;\n\t }\n\t\n\t function cleanUpScope($scope) {\n\t\n\t if (msie === 9) {\n\t // There is a memory leak in IE9 if all child scopes are not disconnected\n\t // completely when a scope is destroyed. So this code will recurse up through\n\t // all this scopes children\n\t //\n\t // See issue https://github.com/angular/angular.js/issues/10706\n\t $scope.$$childHead && cleanUpScope($scope.$$childHead);\n\t $scope.$$nextSibling && cleanUpScope($scope.$$nextSibling);\n\t }\n\t\n\t // The code below works around IE9 and V8's memory leaks\n\t //\n\t // See:\n\t // - https://code.google.com/p/v8/issues/detail?id=2073#c26\n\t // - https://github.com/angular/angular.js/issues/6794#issuecomment-38648909\n\t // - https://github.com/angular/angular.js/issues/1313#issuecomment-10378451\n\t\n\t $scope.$parent = $scope.$$nextSibling = $scope.$$prevSibling = $scope.$$childHead =\n\t $scope.$$childTail = $scope.$root = $scope.$$watchers = null;\n\t }\n\t\n\t /**\n\t * @ngdoc type\n\t * @name $rootScope.Scope\n\t *\n\t * @description\n\t * A root scope can be retrieved using the {@link ng.$rootScope $rootScope} key from the\n\t * {@link auto.$injector $injector}. Child scopes are created using the\n\t * {@link ng.$rootScope.Scope#$new $new()} method. (Most scopes are created automatically when\n\t * compiled HTML template is executed.) See also the {@link guide/scope Scopes guide} for\n\t * an in-depth introduction and usage examples.\n\t *\n\t *\n\t * # Inheritance\n\t * A scope can inherit from a parent scope, as in this example:\n\t * ```js\n\t var parent = $rootScope;\n\t var child = parent.$new();\n\t\n\t parent.salutation = \"Hello\";\n\t expect(child.salutation).toEqual('Hello');\n\t\n\t child.salutation = \"Welcome\";\n\t expect(child.salutation).toEqual('Welcome');\n\t expect(parent.salutation).toEqual('Hello');\n\t * ```\n\t *\n\t * When interacting with `Scope` in tests, additional helper methods are available on the\n\t * instances of `Scope` type. See {@link ngMock.$rootScope.Scope ngMock Scope} for additional\n\t * details.\n\t *\n\t *\n\t * @param {Object.=} providers Map of service factory which need to be\n\t * provided for the current scope. Defaults to {@link ng}.\n\t * @param {Object.=} instanceCache Provides pre-instantiated services which should\n\t * append/override services provided by `providers`. This is handy\n\t * when unit-testing and having the need to override a default\n\t * service.\n\t * @returns {Object} Newly created scope.\n\t *\n\t */\n\t function Scope() {\n\t this.$id = nextUid();\n\t this.$$phase = this.$parent = this.$$watchers =\n\t this.$$nextSibling = this.$$prevSibling =\n\t this.$$childHead = this.$$childTail = null;\n\t this.$root = this;\n\t this.$$destroyed = false;\n\t this.$$listeners = {};\n\t this.$$listenerCount = {};\n\t this.$$watchersCount = 0;\n\t this.$$isolateBindings = null;\n\t }\n\t\n\t /**\n\t * @ngdoc property\n\t * @name $rootScope.Scope#$id\n\t *\n\t * @description\n\t * Unique scope ID (monotonically increasing) useful for debugging.\n\t */\n\t\n\t /**\n\t * @ngdoc property\n\t * @name $rootScope.Scope#$parent\n\t *\n\t * @description\n\t * Reference to the parent scope.\n\t */\n\t\n\t /**\n\t * @ngdoc property\n\t * @name $rootScope.Scope#$root\n\t *\n\t * @description\n\t * Reference to the root scope.\n\t */\n\t\n\t Scope.prototype = {\n\t constructor: Scope,\n\t /**\n\t * @ngdoc method\n\t * @name $rootScope.Scope#$new\n\t * @kind function\n\t *\n\t * @description\n\t * Creates a new child {@link ng.$rootScope.Scope scope}.\n\t *\n\t * The parent scope will propagate the {@link ng.$rootScope.Scope#$digest $digest()} event.\n\t * The scope can be removed from the scope hierarchy using {@link ng.$rootScope.Scope#$destroy $destroy()}.\n\t *\n\t * {@link ng.$rootScope.Scope#$destroy $destroy()} must be called on a scope when it is\n\t * desired for the scope and its child scopes to be permanently detached from the parent and\n\t * thus stop participating in model change detection and listener notification by invoking.\n\t *\n\t * @param {boolean} isolate If true, then the scope does not prototypically inherit from the\n\t * parent scope. The scope is isolated, as it can not see parent scope properties.\n\t * When creating widgets, it is useful for the widget to not accidentally read parent\n\t * state.\n\t *\n\t * @param {Scope} [parent=this] The {@link ng.$rootScope.Scope `Scope`} that will be the `$parent`\n\t * of the newly created scope. Defaults to `this` scope if not provided.\n\t * This is used when creating a transclude scope to correctly place it\n\t * in the scope hierarchy while maintaining the correct prototypical\n\t * inheritance.\n\t *\n\t * @returns {Object} The newly created child scope.\n\t *\n\t */\n\t $new: function(isolate, parent) {\n\t var child;\n\t\n\t parent = parent || this;\n\t\n\t if (isolate) {\n\t child = new Scope();\n\t child.$root = this.$root;\n\t } else {\n\t // Only create a child scope class if somebody asks for one,\n\t // but cache it to allow the VM to optimize lookups.\n\t if (!this.$$ChildScope) {\n\t this.$$ChildScope = createChildScopeClass(this);\n\t }\n\t child = new this.$$ChildScope();\n\t }\n\t child.$parent = parent;\n\t child.$$prevSibling = parent.$$childTail;\n\t if (parent.$$childHead) {\n\t parent.$$childTail.$$nextSibling = child;\n\t parent.$$childTail = child;\n\t } else {\n\t parent.$$childHead = parent.$$childTail = child;\n\t }\n\t\n\t // When the new scope is not isolated or we inherit from `this`, and\n\t // the parent scope is destroyed, the property `$$destroyed` is inherited\n\t // prototypically. In all other cases, this property needs to be set\n\t // when the parent scope is destroyed.\n\t // The listener needs to be added after the parent is set\n\t if (isolate || parent != this) child.$on('$destroy', destroyChildScope);\n\t\n\t return child;\n\t },\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $rootScope.Scope#$watch\n\t * @kind function\n\t *\n\t * @description\n\t * Registers a `listener` callback to be executed whenever the `watchExpression` changes.\n\t *\n\t * - The `watchExpression` is called on every call to {@link ng.$rootScope.Scope#$digest\n\t * $digest()} and should return the value that will be watched. (`watchExpression` should not change\n\t * its value when executed multiple times with the same input because it may be executed multiple\n\t * times by {@link ng.$rootScope.Scope#$digest $digest()}. That is, `watchExpression` should be\n\t * [idempotent](http://en.wikipedia.org/wiki/Idempotence).\n\t * - The `listener` is called only when the value from the current `watchExpression` and the\n\t * previous call to `watchExpression` are not equal (with the exception of the initial run,\n\t * see below). Inequality is determined according to reference inequality,\n\t * [strict comparison](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Comparison_Operators)\n\t * via the `!==` Javascript operator, unless `objectEquality == true`\n\t * (see next point)\n\t * - When `objectEquality == true`, inequality of the `watchExpression` is determined\n\t * according to the {@link angular.equals} function. To save the value of the object for\n\t * later comparison, the {@link angular.copy} function is used. This therefore means that\n\t * watching complex objects will have adverse memory and performance implications.\n\t * - The watch `listener` may change the model, which may trigger other `listener`s to fire.\n\t * This is achieved by rerunning the watchers until no changes are detected. The rerun\n\t * iteration limit is 10 to prevent an infinite loop deadlock.\n\t *\n\t *\n\t * If you want to be notified whenever {@link ng.$rootScope.Scope#$digest $digest} is called,\n\t * you can register a `watchExpression` function with no `listener`. (Be prepared for\n\t * multiple calls to your `watchExpression` because it will execute multiple times in a\n\t * single {@link ng.$rootScope.Scope#$digest $digest} cycle if a change is detected.)\n\t *\n\t * After a watcher is registered with the scope, the `listener` fn is called asynchronously\n\t * (via {@link ng.$rootScope.Scope#$evalAsync $evalAsync}) to initialize the\n\t * watcher. In rare cases, this is undesirable because the listener is called when the result\n\t * of `watchExpression` didn't change. To detect this scenario within the `listener` fn, you\n\t * can compare the `newVal` and `oldVal`. If these two values are identical (`===`) then the\n\t * listener was called due to initialization.\n\t *\n\t *\n\t *\n\t * # Example\n\t * ```js\n\t // let's assume that scope was dependency injected as the $rootScope\n\t var scope = $rootScope;\n\t scope.name = 'misko';\n\t scope.counter = 0;\n\t\n\t expect(scope.counter).toEqual(0);\n\t scope.$watch('name', function(newValue, oldValue) {\n\t scope.counter = scope.counter + 1;\n\t });\n\t expect(scope.counter).toEqual(0);\n\t\n\t scope.$digest();\n\t // the listener is always called during the first $digest loop after it was registered\n\t expect(scope.counter).toEqual(1);\n\t\n\t scope.$digest();\n\t // but now it will not be called unless the value changes\n\t expect(scope.counter).toEqual(1);\n\t\n\t scope.name = 'adam';\n\t scope.$digest();\n\t expect(scope.counter).toEqual(2);\n\t\n\t\n\t\n\t // Using a function as a watchExpression\n\t var food;\n\t scope.foodCounter = 0;\n\t expect(scope.foodCounter).toEqual(0);\n\t scope.$watch(\n\t // This function returns the value being watched. It is called for each turn of the $digest loop\n\t function() { return food; },\n\t // This is the change listener, called when the value returned from the above function changes\n\t function(newValue, oldValue) {\n\t if ( newValue !== oldValue ) {\n\t // Only increment the counter if the value changed\n\t scope.foodCounter = scope.foodCounter + 1;\n\t }\n\t }\n\t );\n\t // No digest has been run so the counter will be zero\n\t expect(scope.foodCounter).toEqual(0);\n\t\n\t // Run the digest but since food has not changed count will still be zero\n\t scope.$digest();\n\t expect(scope.foodCounter).toEqual(0);\n\t\n\t // Update food and run digest. Now the counter will increment\n\t food = 'cheeseburger';\n\t scope.$digest();\n\t expect(scope.foodCounter).toEqual(1);\n\t\n\t * ```\n\t *\n\t *\n\t *\n\t * @param {(function()|string)} watchExpression Expression that is evaluated on each\n\t * {@link ng.$rootScope.Scope#$digest $digest} cycle. A change in the return value triggers\n\t * a call to the `listener`.\n\t *\n\t * - `string`: Evaluated as {@link guide/expression expression}\n\t * - `function(scope)`: called with current `scope` as a parameter.\n\t * @param {function(newVal, oldVal, scope)} listener Callback called whenever the value\n\t * of `watchExpression` changes.\n\t *\n\t * - `newVal` contains the current value of the `watchExpression`\n\t * - `oldVal` contains the previous value of the `watchExpression`\n\t * - `scope` refers to the current scope\n\t * @param {boolean=} objectEquality Compare for object equality using {@link angular.equals} instead of\n\t * comparing for reference equality.\n\t * @returns {function()} Returns a deregistration function for this listener.\n\t */\n\t $watch: function(watchExp, listener, objectEquality, prettyPrintExpression) {\n\t var get = $parse(watchExp);\n\t\n\t if (get.$$watchDelegate) {\n\t return get.$$watchDelegate(this, listener, objectEquality, get, watchExp);\n\t }\n\t var scope = this,\n\t array = scope.$$watchers,\n\t watcher = {\n\t fn: listener,\n\t last: initWatchVal,\n\t get: get,\n\t exp: prettyPrintExpression || watchExp,\n\t eq: !!objectEquality\n\t };\n\t\n\t lastDirtyWatch = null;\n\t\n\t if (!isFunction(listener)) {\n\t watcher.fn = noop;\n\t }\n\t\n\t if (!array) {\n\t array = scope.$$watchers = [];\n\t }\n\t // we use unshift since we use a while loop in $digest for speed.\n\t // the while loop reads in reverse order.\n\t array.unshift(watcher);\n\t incrementWatchersCount(this, 1);\n\t\n\t return function deregisterWatch() {\n\t if (arrayRemove(array, watcher) >= 0) {\n\t incrementWatchersCount(scope, -1);\n\t }\n\t lastDirtyWatch = null;\n\t };\n\t },\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $rootScope.Scope#$watchGroup\n\t * @kind function\n\t *\n\t * @description\n\t * A variant of {@link ng.$rootScope.Scope#$watch $watch()} where it watches an array of `watchExpressions`.\n\t * If any one expression in the collection changes the `listener` is executed.\n\t *\n\t * - The items in the `watchExpressions` array are observed via standard $watch operation and are examined on every\n\t * call to $digest() to see if any items changes.\n\t * - The `listener` is called whenever any expression in the `watchExpressions` array changes.\n\t *\n\t * @param {Array.} watchExpressions Array of expressions that will be individually\n\t * watched using {@link ng.$rootScope.Scope#$watch $watch()}\n\t *\n\t * @param {function(newValues, oldValues, scope)} listener Callback called whenever the return value of any\n\t * expression in `watchExpressions` changes\n\t * The `newValues` array contains the current values of the `watchExpressions`, with the indexes matching\n\t * those of `watchExpression`\n\t * and the `oldValues` array contains the previous values of the `watchExpressions`, with the indexes matching\n\t * those of `watchExpression`\n\t * The `scope` refers to the current scope.\n\t * @returns {function()} Returns a de-registration function for all listeners.\n\t */\n\t $watchGroup: function(watchExpressions, listener) {\n\t var oldValues = new Array(watchExpressions.length);\n\t var newValues = new Array(watchExpressions.length);\n\t var deregisterFns = [];\n\t var self = this;\n\t var changeReactionScheduled = false;\n\t var firstRun = true;\n\t\n\t if (!watchExpressions.length) {\n\t // No expressions means we call the listener ASAP\n\t var shouldCall = true;\n\t self.$evalAsync(function() {\n\t if (shouldCall) listener(newValues, newValues, self);\n\t });\n\t return function deregisterWatchGroup() {\n\t shouldCall = false;\n\t };\n\t }\n\t\n\t if (watchExpressions.length === 1) {\n\t // Special case size of one\n\t return this.$watch(watchExpressions[0], function watchGroupAction(value, oldValue, scope) {\n\t newValues[0] = value;\n\t oldValues[0] = oldValue;\n\t listener(newValues, (value === oldValue) ? newValues : oldValues, scope);\n\t });\n\t }\n\t\n\t forEach(watchExpressions, function(expr, i) {\n\t var unwatchFn = self.$watch(expr, function watchGroupSubAction(value, oldValue) {\n\t newValues[i] = value;\n\t oldValues[i] = oldValue;\n\t if (!changeReactionScheduled) {\n\t changeReactionScheduled = true;\n\t self.$evalAsync(watchGroupAction);\n\t }\n\t });\n\t deregisterFns.push(unwatchFn);\n\t });\n\t\n\t function watchGroupAction() {\n\t changeReactionScheduled = false;\n\t\n\t if (firstRun) {\n\t firstRun = false;\n\t listener(newValues, newValues, self);\n\t } else {\n\t listener(newValues, oldValues, self);\n\t }\n\t }\n\t\n\t return function deregisterWatchGroup() {\n\t while (deregisterFns.length) {\n\t deregisterFns.shift()();\n\t }\n\t };\n\t },\n\t\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $rootScope.Scope#$watchCollection\n\t * @kind function\n\t *\n\t * @description\n\t * Shallow watches the properties of an object and fires whenever any of the properties change\n\t * (for arrays, this implies watching the array items; for object maps, this implies watching\n\t * the properties). If a change is detected, the `listener` callback is fired.\n\t *\n\t * - The `obj` collection is observed via standard $watch operation and is examined on every\n\t * call to $digest() to see if any items have been added, removed, or moved.\n\t * - The `listener` is called whenever anything within the `obj` has changed. Examples include\n\t * adding, removing, and moving items belonging to an object or array.\n\t *\n\t *\n\t * # Example\n\t * ```js\n\t $scope.names = ['igor', 'matias', 'misko', 'james'];\n\t $scope.dataCount = 4;\n\t\n\t $scope.$watchCollection('names', function(newNames, oldNames) {\n\t $scope.dataCount = newNames.length;\n\t });\n\t\n\t expect($scope.dataCount).toEqual(4);\n\t $scope.$digest();\n\t\n\t //still at 4 ... no changes\n\t expect($scope.dataCount).toEqual(4);\n\t\n\t $scope.names.pop();\n\t $scope.$digest();\n\t\n\t //now there's been a change\n\t expect($scope.dataCount).toEqual(3);\n\t * ```\n\t *\n\t *\n\t * @param {string|function(scope)} obj Evaluated as {@link guide/expression expression}. The\n\t * expression value should evaluate to an object or an array which is observed on each\n\t * {@link ng.$rootScope.Scope#$digest $digest} cycle. Any shallow change within the\n\t * collection will trigger a call to the `listener`.\n\t *\n\t * @param {function(newCollection, oldCollection, scope)} listener a callback function called\n\t * when a change is detected.\n\t * - The `newCollection` object is the newly modified data obtained from the `obj` expression\n\t * - The `oldCollection` object is a copy of the former collection data.\n\t * Due to performance considerations, the`oldCollection` value is computed only if the\n\t * `listener` function declares two or more arguments.\n\t * - The `scope` argument refers to the current scope.\n\t *\n\t * @returns {function()} Returns a de-registration function for this listener. When the\n\t * de-registration function is executed, the internal watch operation is terminated.\n\t */\n\t $watchCollection: function(obj, listener) {\n\t $watchCollectionInterceptor.$stateful = true;\n\t\n\t var self = this;\n\t // the current value, updated on each dirty-check run\n\t var newValue;\n\t // a shallow copy of the newValue from the last dirty-check run,\n\t // updated to match newValue during dirty-check run\n\t var oldValue;\n\t // a shallow copy of the newValue from when the last change happened\n\t var veryOldValue;\n\t // only track veryOldValue if the listener is asking for it\n\t var trackVeryOldValue = (listener.length > 1);\n\t var changeDetected = 0;\n\t var changeDetector = $parse(obj, $watchCollectionInterceptor);\n\t var internalArray = [];\n\t var internalObject = {};\n\t var initRun = true;\n\t var oldLength = 0;\n\t\n\t function $watchCollectionInterceptor(_value) {\n\t newValue = _value;\n\t var newLength, key, bothNaN, newItem, oldItem;\n\t\n\t // If the new value is undefined, then return undefined as the watch may be a one-time watch\n\t if (isUndefined(newValue)) return;\n\t\n\t if (!isObject(newValue)) { // if primitive\n\t if (oldValue !== newValue) {\n\t oldValue = newValue;\n\t changeDetected++;\n\t }\n\t } else if (isArrayLike(newValue)) {\n\t if (oldValue !== internalArray) {\n\t // we are transitioning from something which was not an array into array.\n\t oldValue = internalArray;\n\t oldLength = oldValue.length = 0;\n\t changeDetected++;\n\t }\n\t\n\t newLength = newValue.length;\n\t\n\t if (oldLength !== newLength) {\n\t // if lengths do not match we need to trigger change notification\n\t changeDetected++;\n\t oldValue.length = oldLength = newLength;\n\t }\n\t // copy the items to oldValue and look for changes.\n\t for (var i = 0; i < newLength; i++) {\n\t oldItem = oldValue[i];\n\t newItem = newValue[i];\n\t\n\t bothNaN = (oldItem !== oldItem) && (newItem !== newItem);\n\t if (!bothNaN && (oldItem !== newItem)) {\n\t changeDetected++;\n\t oldValue[i] = newItem;\n\t }\n\t }\n\t } else {\n\t if (oldValue !== internalObject) {\n\t // we are transitioning from something which was not an object into object.\n\t oldValue = internalObject = {};\n\t oldLength = 0;\n\t changeDetected++;\n\t }\n\t // copy the items to oldValue and look for changes.\n\t newLength = 0;\n\t for (key in newValue) {\n\t if (hasOwnProperty.call(newValue, key)) {\n\t newLength++;\n\t newItem = newValue[key];\n\t oldItem = oldValue[key];\n\t\n\t if (key in oldValue) {\n\t bothNaN = (oldItem !== oldItem) && (newItem !== newItem);\n\t if (!bothNaN && (oldItem !== newItem)) {\n\t changeDetected++;\n\t oldValue[key] = newItem;\n\t }\n\t } else {\n\t oldLength++;\n\t oldValue[key] = newItem;\n\t changeDetected++;\n\t }\n\t }\n\t }\n\t if (oldLength > newLength) {\n\t // we used to have more keys, need to find them and destroy them.\n\t changeDetected++;\n\t for (key in oldValue) {\n\t if (!hasOwnProperty.call(newValue, key)) {\n\t oldLength--;\n\t delete oldValue[key];\n\t }\n\t }\n\t }\n\t }\n\t return changeDetected;\n\t }\n\t\n\t function $watchCollectionAction() {\n\t if (initRun) {\n\t initRun = false;\n\t listener(newValue, newValue, self);\n\t } else {\n\t listener(newValue, veryOldValue, self);\n\t }\n\t\n\t // make a copy for the next time a collection is changed\n\t if (trackVeryOldValue) {\n\t if (!isObject(newValue)) {\n\t //primitive\n\t veryOldValue = newValue;\n\t } else if (isArrayLike(newValue)) {\n\t veryOldValue = new Array(newValue.length);\n\t for (var i = 0; i < newValue.length; i++) {\n\t veryOldValue[i] = newValue[i];\n\t }\n\t } else { // if object\n\t veryOldValue = {};\n\t for (var key in newValue) {\n\t if (hasOwnProperty.call(newValue, key)) {\n\t veryOldValue[key] = newValue[key];\n\t }\n\t }\n\t }\n\t }\n\t }\n\t\n\t return this.$watch(changeDetector, $watchCollectionAction);\n\t },\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $rootScope.Scope#$digest\n\t * @kind function\n\t *\n\t * @description\n\t * Processes all of the {@link ng.$rootScope.Scope#$watch watchers} of the current scope and\n\t * its children. Because a {@link ng.$rootScope.Scope#$watch watcher}'s listener can change\n\t * the model, the `$digest()` keeps calling the {@link ng.$rootScope.Scope#$watch watchers}\n\t * until no more listeners are firing. This means that it is possible to get into an infinite\n\t * loop. This function will throw `'Maximum iteration limit exceeded.'` if the number of\n\t * iterations exceeds 10.\n\t *\n\t * Usually, you don't call `$digest()` directly in\n\t * {@link ng.directive:ngController controllers} or in\n\t * {@link ng.$compileProvider#directive directives}.\n\t * Instead, you should call {@link ng.$rootScope.Scope#$apply $apply()} (typically from within\n\t * a {@link ng.$compileProvider#directive directive}), which will force a `$digest()`.\n\t *\n\t * If you want to be notified whenever `$digest()` is called,\n\t * you can register a `watchExpression` function with\n\t * {@link ng.$rootScope.Scope#$watch $watch()} with no `listener`.\n\t *\n\t * In unit tests, you may need to call `$digest()` to simulate the scope life cycle.\n\t *\n\t * # Example\n\t * ```js\n\t var scope = ...;\n\t scope.name = 'misko';\n\t scope.counter = 0;\n\t\n\t expect(scope.counter).toEqual(0);\n\t scope.$watch('name', function(newValue, oldValue) {\n\t scope.counter = scope.counter + 1;\n\t });\n\t expect(scope.counter).toEqual(0);\n\t\n\t scope.$digest();\n\t // the listener is always called during the first $digest loop after it was registered\n\t expect(scope.counter).toEqual(1);\n\t\n\t scope.$digest();\n\t // but now it will not be called unless the value changes\n\t expect(scope.counter).toEqual(1);\n\t\n\t scope.name = 'adam';\n\t scope.$digest();\n\t expect(scope.counter).toEqual(2);\n\t * ```\n\t *\n\t */\n\t $digest: function() {\n\t var watch, value, last, fn, get,\n\t watchers,\n\t length,\n\t dirty, ttl = TTL,\n\t next, current, target = this,\n\t watchLog = [],\n\t logIdx, logMsg, asyncTask;\n\t\n\t beginPhase('$digest');\n\t // Check for changes to browser url that happened in sync before the call to $digest\n\t $browser.$$checkUrlChange();\n\t\n\t if (this === $rootScope && applyAsyncId !== null) {\n\t // If this is the root scope, and $applyAsync has scheduled a deferred $apply(), then\n\t // cancel the scheduled $apply and flush the queue of expressions to be evaluated.\n\t $browser.defer.cancel(applyAsyncId);\n\t flushApplyAsync();\n\t }\n\t\n\t lastDirtyWatch = null;\n\t\n\t do { // \"while dirty\" loop\n\t dirty = false;\n\t current = target;\n\t\n\t while (asyncQueue.length) {\n\t try {\n\t asyncTask = asyncQueue.shift();\n\t asyncTask.scope.$eval(asyncTask.expression, asyncTask.locals);\n\t } catch (e) {\n\t $exceptionHandler(e);\n\t }\n\t lastDirtyWatch = null;\n\t }\n\t\n\t traverseScopesLoop:\n\t do { // \"traverse the scopes\" loop\n\t if ((watchers = current.$$watchers)) {\n\t // process our watches\n\t length = watchers.length;\n\t while (length--) {\n\t try {\n\t watch = watchers[length];\n\t // Most common watches are on primitives, in which case we can short\n\t // circuit it with === operator, only when === fails do we use .equals\n\t if (watch) {\n\t get = watch.get;\n\t if ((value = get(current)) !== (last = watch.last) &&\n\t !(watch.eq\n\t ? equals(value, last)\n\t : (typeof value === 'number' && typeof last === 'number'\n\t && isNaN(value) && isNaN(last)))) {\n\t dirty = true;\n\t lastDirtyWatch = watch;\n\t watch.last = watch.eq ? copy(value, null) : value;\n\t fn = watch.fn;\n\t fn(value, ((last === initWatchVal) ? value : last), current);\n\t if (ttl < 5) {\n\t logIdx = 4 - ttl;\n\t if (!watchLog[logIdx]) watchLog[logIdx] = [];\n\t watchLog[logIdx].push({\n\t msg: isFunction(watch.exp) ? 'fn: ' + (watch.exp.name || watch.exp.toString()) : watch.exp,\n\t newVal: value,\n\t oldVal: last\n\t });\n\t }\n\t } else if (watch === lastDirtyWatch) {\n\t // If the most recently dirty watcher is now clean, short circuit since the remaining watchers\n\t // have already been tested.\n\t dirty = false;\n\t break traverseScopesLoop;\n\t }\n\t }\n\t } catch (e) {\n\t $exceptionHandler(e);\n\t }\n\t }\n\t }\n\t\n\t // Insanity Warning: scope depth-first traversal\n\t // yes, this code is a bit crazy, but it works and we have tests to prove it!\n\t // this piece should be kept in sync with the traversal in $broadcast\n\t if (!(next = ((current.$$watchersCount && current.$$childHead) ||\n\t (current !== target && current.$$nextSibling)))) {\n\t while (current !== target && !(next = current.$$nextSibling)) {\n\t current = current.$parent;\n\t }\n\t }\n\t } while ((current = next));\n\t\n\t // `break traverseScopesLoop;` takes us to here\n\t\n\t if ((dirty || asyncQueue.length) && !(ttl--)) {\n\t clearPhase();\n\t throw $rootScopeMinErr('infdig',\n\t '{0} $digest() iterations reached. Aborting!\\n' +\n\t 'Watchers fired in the last 5 iterations: {1}',\n\t TTL, watchLog);\n\t }\n\t\n\t } while (dirty || asyncQueue.length);\n\t\n\t clearPhase();\n\t\n\t while (postDigestQueue.length) {\n\t try {\n\t postDigestQueue.shift()();\n\t } catch (e) {\n\t $exceptionHandler(e);\n\t }\n\t }\n\t },\n\t\n\t\n\t /**\n\t * @ngdoc event\n\t * @name $rootScope.Scope#$destroy\n\t * @eventType broadcast on scope being destroyed\n\t *\n\t * @description\n\t * Broadcasted when a scope and its children are being destroyed.\n\t *\n\t * Note that, in AngularJS, there is also a `$destroy` jQuery event, which can be used to\n\t * clean up DOM bindings before an element is removed from the DOM.\n\t */\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $rootScope.Scope#$destroy\n\t * @kind function\n\t *\n\t * @description\n\t * Removes the current scope (and all of its children) from the parent scope. Removal implies\n\t * that calls to {@link ng.$rootScope.Scope#$digest $digest()} will no longer\n\t * propagate to the current scope and its children. Removal also implies that the current\n\t * scope is eligible for garbage collection.\n\t *\n\t * The `$destroy()` is usually used by directives such as\n\t * {@link ng.directive:ngRepeat ngRepeat} for managing the\n\t * unrolling of the loop.\n\t *\n\t * Just before a scope is destroyed, a `$destroy` event is broadcasted on this scope.\n\t * Application code can register a `$destroy` event handler that will give it a chance to\n\t * perform any necessary cleanup.\n\t *\n\t * Note that, in AngularJS, there is also a `$destroy` jQuery event, which can be used to\n\t * clean up DOM bindings before an element is removed from the DOM.\n\t */\n\t $destroy: function() {\n\t // We can't destroy a scope that has been already destroyed.\n\t if (this.$$destroyed) return;\n\t var parent = this.$parent;\n\t\n\t this.$broadcast('$destroy');\n\t this.$$destroyed = true;\n\t\n\t if (this === $rootScope) {\n\t //Remove handlers attached to window when $rootScope is removed\n\t $browser.$$applicationDestroyed();\n\t }\n\t\n\t incrementWatchersCount(this, -this.$$watchersCount);\n\t for (var eventName in this.$$listenerCount) {\n\t decrementListenerCount(this, this.$$listenerCount[eventName], eventName);\n\t }\n\t\n\t // sever all the references to parent scopes (after this cleanup, the current scope should\n\t // not be retained by any of our references and should be eligible for garbage collection)\n\t if (parent && parent.$$childHead == this) parent.$$childHead = this.$$nextSibling;\n\t if (parent && parent.$$childTail == this) parent.$$childTail = this.$$prevSibling;\n\t if (this.$$prevSibling) this.$$prevSibling.$$nextSibling = this.$$nextSibling;\n\t if (this.$$nextSibling) this.$$nextSibling.$$prevSibling = this.$$prevSibling;\n\t\n\t // Disable listeners, watchers and apply/digest methods\n\t this.$destroy = this.$digest = this.$apply = this.$evalAsync = this.$applyAsync = noop;\n\t this.$on = this.$watch = this.$watchGroup = function() { return noop; };\n\t this.$$listeners = {};\n\t\n\t // Disconnect the next sibling to prevent `cleanUpScope` destroying those too\n\t this.$$nextSibling = null;\n\t cleanUpScope(this);\n\t },\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $rootScope.Scope#$eval\n\t * @kind function\n\t *\n\t * @description\n\t * Executes the `expression` on the current scope and returns the result. Any exceptions in\n\t * the expression are propagated (uncaught). This is useful when evaluating Angular\n\t * expressions.\n\t *\n\t * # Example\n\t * ```js\n\t var scope = ng.$rootScope.Scope();\n\t scope.a = 1;\n\t scope.b = 2;\n\t\n\t expect(scope.$eval('a+b')).toEqual(3);\n\t expect(scope.$eval(function(scope){ return scope.a + scope.b; })).toEqual(3);\n\t * ```\n\t *\n\t * @param {(string|function())=} expression An angular expression to be executed.\n\t *\n\t * - `string`: execute using the rules as defined in {@link guide/expression expression}.\n\t * - `function(scope)`: execute the function with the current `scope` parameter.\n\t *\n\t * @param {(object)=} locals Local variables object, useful for overriding values in scope.\n\t * @returns {*} The result of evaluating the expression.\n\t */\n\t $eval: function(expr, locals) {\n\t return $parse(expr)(this, locals);\n\t },\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $rootScope.Scope#$evalAsync\n\t * @kind function\n\t *\n\t * @description\n\t * Executes the expression on the current scope at a later point in time.\n\t *\n\t * The `$evalAsync` makes no guarantees as to when the `expression` will be executed, only\n\t * that:\n\t *\n\t * - it will execute after the function that scheduled the evaluation (preferably before DOM\n\t * rendering).\n\t * - at least one {@link ng.$rootScope.Scope#$digest $digest cycle} will be performed after\n\t * `expression` execution.\n\t *\n\t * Any exceptions from the execution of the expression are forwarded to the\n\t * {@link ng.$exceptionHandler $exceptionHandler} service.\n\t *\n\t * __Note:__ if this function is called outside of a `$digest` cycle, a new `$digest` cycle\n\t * will be scheduled. However, it is encouraged to always call code that changes the model\n\t * from within an `$apply` call. That includes code evaluated via `$evalAsync`.\n\t *\n\t * @param {(string|function())=} expression An angular expression to be executed.\n\t *\n\t * - `string`: execute using the rules as defined in {@link guide/expression expression}.\n\t * - `function(scope)`: execute the function with the current `scope` parameter.\n\t *\n\t * @param {(object)=} locals Local variables object, useful for overriding values in scope.\n\t */\n\t $evalAsync: function(expr, locals) {\n\t // if we are outside of an $digest loop and this is the first time we are scheduling async\n\t // task also schedule async auto-flush\n\t if (!$rootScope.$$phase && !asyncQueue.length) {\n\t $browser.defer(function() {\n\t if (asyncQueue.length) {\n\t $rootScope.$digest();\n\t }\n\t });\n\t }\n\t\n\t asyncQueue.push({scope: this, expression: $parse(expr), locals: locals});\n\t },\n\t\n\t $$postDigest: function(fn) {\n\t postDigestQueue.push(fn);\n\t },\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $rootScope.Scope#$apply\n\t * @kind function\n\t *\n\t * @description\n\t * `$apply()` is used to execute an expression in angular from outside of the angular\n\t * framework. (For example from browser DOM events, setTimeout, XHR or third party libraries).\n\t * Because we are calling into the angular framework we need to perform proper scope life\n\t * cycle of {@link ng.$exceptionHandler exception handling},\n\t * {@link ng.$rootScope.Scope#$digest executing watches}.\n\t *\n\t * ## Life cycle\n\t *\n\t * # Pseudo-Code of `$apply()`\n\t * ```js\n\t function $apply(expr) {\n\t try {\n\t return $eval(expr);\n\t } catch (e) {\n\t $exceptionHandler(e);\n\t } finally {\n\t $root.$digest();\n\t }\n\t }\n\t * ```\n\t *\n\t *\n\t * Scope's `$apply()` method transitions through the following stages:\n\t *\n\t * 1. The {@link guide/expression expression} is executed using the\n\t * {@link ng.$rootScope.Scope#$eval $eval()} method.\n\t * 2. Any exceptions from the execution of the expression are forwarded to the\n\t * {@link ng.$exceptionHandler $exceptionHandler} service.\n\t * 3. The {@link ng.$rootScope.Scope#$watch watch} listeners are fired immediately after the\n\t * expression was executed using the {@link ng.$rootScope.Scope#$digest $digest()} method.\n\t *\n\t *\n\t * @param {(string|function())=} exp An angular expression to be executed.\n\t *\n\t * - `string`: execute using the rules as defined in {@link guide/expression expression}.\n\t * - `function(scope)`: execute the function with current `scope` parameter.\n\t *\n\t * @returns {*} The result of evaluating the expression.\n\t */\n\t $apply: function(expr) {\n\t try {\n\t beginPhase('$apply');\n\t try {\n\t return this.$eval(expr);\n\t } finally {\n\t clearPhase();\n\t }\n\t } catch (e) {\n\t $exceptionHandler(e);\n\t } finally {\n\t try {\n\t $rootScope.$digest();\n\t } catch (e) {\n\t $exceptionHandler(e);\n\t throw e;\n\t }\n\t }\n\t },\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $rootScope.Scope#$applyAsync\n\t * @kind function\n\t *\n\t * @description\n\t * Schedule the invocation of $apply to occur at a later time. The actual time difference\n\t * varies across browsers, but is typically around ~10 milliseconds.\n\t *\n\t * This can be used to queue up multiple expressions which need to be evaluated in the same\n\t * digest.\n\t *\n\t * @param {(string|function())=} exp An angular expression to be executed.\n\t *\n\t * - `string`: execute using the rules as defined in {@link guide/expression expression}.\n\t * - `function(scope)`: execute the function with current `scope` parameter.\n\t */\n\t $applyAsync: function(expr) {\n\t var scope = this;\n\t expr && applyAsyncQueue.push($applyAsyncExpression);\n\t expr = $parse(expr);\n\t scheduleApplyAsync();\n\t\n\t function $applyAsyncExpression() {\n\t scope.$eval(expr);\n\t }\n\t },\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $rootScope.Scope#$on\n\t * @kind function\n\t *\n\t * @description\n\t * Listens on events of a given type. See {@link ng.$rootScope.Scope#$emit $emit} for\n\t * discussion of event life cycle.\n\t *\n\t * The event listener function format is: `function(event, args...)`. The `event` object\n\t * passed into the listener has the following attributes:\n\t *\n\t * - `targetScope` - `{Scope}`: the scope on which the event was `$emit`-ed or\n\t * `$broadcast`-ed.\n\t * - `currentScope` - `{Scope}`: the scope that is currently handling the event. Once the\n\t * event propagates through the scope hierarchy, this property is set to null.\n\t * - `name` - `{string}`: name of the event.\n\t * - `stopPropagation` - `{function=}`: calling `stopPropagation` function will cancel\n\t * further event propagation (available only for events that were `$emit`-ed).\n\t * - `preventDefault` - `{function}`: calling `preventDefault` sets `defaultPrevented` flag\n\t * to true.\n\t * - `defaultPrevented` - `{boolean}`: true if `preventDefault` was called.\n\t *\n\t * @param {string} name Event name to listen on.\n\t * @param {function(event, ...args)} listener Function to call when the event is emitted.\n\t * @returns {function()} Returns a deregistration function for this listener.\n\t */\n\t $on: function(name, listener) {\n\t var namedListeners = this.$$listeners[name];\n\t if (!namedListeners) {\n\t this.$$listeners[name] = namedListeners = [];\n\t }\n\t namedListeners.push(listener);\n\t\n\t var current = this;\n\t do {\n\t if (!current.$$listenerCount[name]) {\n\t current.$$listenerCount[name] = 0;\n\t }\n\t current.$$listenerCount[name]++;\n\t } while ((current = current.$parent));\n\t\n\t var self = this;\n\t return function() {\n\t var indexOfListener = namedListeners.indexOf(listener);\n\t if (indexOfListener !== -1) {\n\t namedListeners[indexOfListener] = null;\n\t decrementListenerCount(self, 1, name);\n\t }\n\t };\n\t },\n\t\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $rootScope.Scope#$emit\n\t * @kind function\n\t *\n\t * @description\n\t * Dispatches an event `name` upwards through the scope hierarchy notifying the\n\t * registered {@link ng.$rootScope.Scope#$on} listeners.\n\t *\n\t * The event life cycle starts at the scope on which `$emit` was called. All\n\t * {@link ng.$rootScope.Scope#$on listeners} listening for `name` event on this scope get\n\t * notified. Afterwards, the event traverses upwards toward the root scope and calls all\n\t * registered listeners along the way. The event will stop propagating if one of the listeners\n\t * cancels it.\n\t *\n\t * Any exception emitted from the {@link ng.$rootScope.Scope#$on listeners} will be passed\n\t * onto the {@link ng.$exceptionHandler $exceptionHandler} service.\n\t *\n\t * @param {string} name Event name to emit.\n\t * @param {...*} args Optional one or more arguments which will be passed onto the event listeners.\n\t * @return {Object} Event object (see {@link ng.$rootScope.Scope#$on}).\n\t */\n\t $emit: function(name, args) {\n\t var empty = [],\n\t namedListeners,\n\t scope = this,\n\t stopPropagation = false,\n\t event = {\n\t name: name,\n\t targetScope: scope,\n\t stopPropagation: function() {stopPropagation = true;},\n\t preventDefault: function() {\n\t event.defaultPrevented = true;\n\t },\n\t defaultPrevented: false\n\t },\n\t listenerArgs = concat([event], arguments, 1),\n\t i, length;\n\t\n\t do {\n\t namedListeners = scope.$$listeners[name] || empty;\n\t event.currentScope = scope;\n\t for (i = 0, length = namedListeners.length; i < length; i++) {\n\t\n\t // if listeners were deregistered, defragment the array\n\t if (!namedListeners[i]) {\n\t namedListeners.splice(i, 1);\n\t i--;\n\t length--;\n\t continue;\n\t }\n\t try {\n\t //allow all listeners attached to the current scope to run\n\t namedListeners[i].apply(null, listenerArgs);\n\t } catch (e) {\n\t $exceptionHandler(e);\n\t }\n\t }\n\t //if any listener on the current scope stops propagation, prevent bubbling\n\t if (stopPropagation) {\n\t event.currentScope = null;\n\t return event;\n\t }\n\t //traverse upwards\n\t scope = scope.$parent;\n\t } while (scope);\n\t\n\t event.currentScope = null;\n\t\n\t return event;\n\t },\n\t\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $rootScope.Scope#$broadcast\n\t * @kind function\n\t *\n\t * @description\n\t * Dispatches an event `name` downwards to all child scopes (and their children) notifying the\n\t * registered {@link ng.$rootScope.Scope#$on} listeners.\n\t *\n\t * The event life cycle starts at the scope on which `$broadcast` was called. All\n\t * {@link ng.$rootScope.Scope#$on listeners} listening for `name` event on this scope get\n\t * notified. Afterwards, the event propagates to all direct and indirect scopes of the current\n\t * scope and calls all registered listeners along the way. The event cannot be canceled.\n\t *\n\t * Any exception emitted from the {@link ng.$rootScope.Scope#$on listeners} will be passed\n\t * onto the {@link ng.$exceptionHandler $exceptionHandler} service.\n\t *\n\t * @param {string} name Event name to broadcast.\n\t * @param {...*} args Optional one or more arguments which will be passed onto the event listeners.\n\t * @return {Object} Event object, see {@link ng.$rootScope.Scope#$on}\n\t */\n\t $broadcast: function(name, args) {\n\t var target = this,\n\t current = target,\n\t next = target,\n\t event = {\n\t name: name,\n\t targetScope: target,\n\t preventDefault: function() {\n\t event.defaultPrevented = true;\n\t },\n\t defaultPrevented: false\n\t };\n\t\n\t if (!target.$$listenerCount[name]) return event;\n\t\n\t var listenerArgs = concat([event], arguments, 1),\n\t listeners, i, length;\n\t\n\t //down while you can, then up and next sibling or up and next sibling until back at root\n\t while ((current = next)) {\n\t event.currentScope = current;\n\t listeners = current.$$listeners[name] || [];\n\t for (i = 0, length = listeners.length; i < length; i++) {\n\t // if listeners were deregistered, defragment the array\n\t if (!listeners[i]) {\n\t listeners.splice(i, 1);\n\t i--;\n\t length--;\n\t continue;\n\t }\n\t\n\t try {\n\t listeners[i].apply(null, listenerArgs);\n\t } catch (e) {\n\t $exceptionHandler(e);\n\t }\n\t }\n\t\n\t // Insanity Warning: scope depth-first traversal\n\t // yes, this code is a bit crazy, but it works and we have tests to prove it!\n\t // this piece should be kept in sync with the traversal in $digest\n\t // (though it differs due to having the extra check for $$listenerCount)\n\t if (!(next = ((current.$$listenerCount[name] && current.$$childHead) ||\n\t (current !== target && current.$$nextSibling)))) {\n\t while (current !== target && !(next = current.$$nextSibling)) {\n\t current = current.$parent;\n\t }\n\t }\n\t }\n\t\n\t event.currentScope = null;\n\t return event;\n\t }\n\t };\n\t\n\t var $rootScope = new Scope();\n\t\n\t //The internal queues. Expose them on the $rootScope for debugging/testing purposes.\n\t var asyncQueue = $rootScope.$$asyncQueue = [];\n\t var postDigestQueue = $rootScope.$$postDigestQueue = [];\n\t var applyAsyncQueue = $rootScope.$$applyAsyncQueue = [];\n\t\n\t return $rootScope;\n\t\n\t\n\t function beginPhase(phase) {\n\t if ($rootScope.$$phase) {\n\t throw $rootScopeMinErr('inprog', '{0} already in progress', $rootScope.$$phase);\n\t }\n\t\n\t $rootScope.$$phase = phase;\n\t }\n\t\n\t function clearPhase() {\n\t $rootScope.$$phase = null;\n\t }\n\t\n\t function incrementWatchersCount(current, count) {\n\t do {\n\t current.$$watchersCount += count;\n\t } while ((current = current.$parent));\n\t }\n\t\n\t function decrementListenerCount(current, count, name) {\n\t do {\n\t current.$$listenerCount[name] -= count;\n\t\n\t if (current.$$listenerCount[name] === 0) {\n\t delete current.$$listenerCount[name];\n\t }\n\t } while ((current = current.$parent));\n\t }\n\t\n\t /**\n\t * function used as an initial value for watchers.\n\t * because it's unique we can easily tell it apart from other values\n\t */\n\t function initWatchVal() {}\n\t\n\t function flushApplyAsync() {\n\t while (applyAsyncQueue.length) {\n\t try {\n\t applyAsyncQueue.shift()();\n\t } catch (e) {\n\t $exceptionHandler(e);\n\t }\n\t }\n\t applyAsyncId = null;\n\t }\n\t\n\t function scheduleApplyAsync() {\n\t if (applyAsyncId === null) {\n\t applyAsyncId = $browser.defer(function() {\n\t $rootScope.$apply(flushApplyAsync);\n\t });\n\t }\n\t }\n\t }];\n\t}\n\t\n\t/**\n\t * @ngdoc service\n\t * @name $rootElement\n\t *\n\t * @description\n\t * The root element of Angular application. This is either the element where {@link\n\t * ng.directive:ngApp ngApp} was declared or the element passed into\n\t * {@link angular.bootstrap}. The element represents the root element of application. It is also the\n\t * location where the application's {@link auto.$injector $injector} service gets\n\t * published, and can be retrieved using `$rootElement.injector()`.\n\t */\n\t\n\t\n\t// the implementation is in angular.bootstrap\n\t\n\t/**\n\t * @description\n\t * Private service to sanitize uris for links and images. Used by $compile and $sanitize.\n\t */\n\tfunction $$SanitizeUriProvider() {\n\t var aHrefSanitizationWhitelist = /^\\s*(https?|ftp|mailto|tel|file):/,\n\t imgSrcSanitizationWhitelist = /^\\s*((https?|ftp|file|blob):|data:image\\/)/;\n\t\n\t /**\n\t * @description\n\t * Retrieves or overrides the default regular expression that is used for whitelisting of safe\n\t * urls during a[href] sanitization.\n\t *\n\t * The sanitization is a security measure aimed at prevent XSS attacks via html links.\n\t *\n\t * Any url about to be assigned to a[href] via data-binding is first normalized and turned into\n\t * an absolute url. Afterwards, the url is matched against the `aHrefSanitizationWhitelist`\n\t * regular expression. If a match is found, the original url is written into the dom. Otherwise,\n\t * the absolute url is prefixed with `'unsafe:'` string and only then is it written into the DOM.\n\t *\n\t * @param {RegExp=} regexp New regexp to whitelist urls with.\n\t * @returns {RegExp|ng.$compileProvider} Current RegExp if called without value or self for\n\t * chaining otherwise.\n\t */\n\t this.aHrefSanitizationWhitelist = function(regexp) {\n\t if (isDefined(regexp)) {\n\t aHrefSanitizationWhitelist = regexp;\n\t return this;\n\t }\n\t return aHrefSanitizationWhitelist;\n\t };\n\t\n\t\n\t /**\n\t * @description\n\t * Retrieves or overrides the default regular expression that is used for whitelisting of safe\n\t * urls during img[src] sanitization.\n\t *\n\t * The sanitization is a security measure aimed at prevent XSS attacks via html links.\n\t *\n\t * Any url about to be assigned to img[src] via data-binding is first normalized and turned into\n\t * an absolute url. Afterwards, the url is matched against the `imgSrcSanitizationWhitelist`\n\t * regular expression. If a match is found, the original url is written into the dom. Otherwise,\n\t * the absolute url is prefixed with `'unsafe:'` string and only then is it written into the DOM.\n\t *\n\t * @param {RegExp=} regexp New regexp to whitelist urls with.\n\t * @returns {RegExp|ng.$compileProvider} Current RegExp if called without value or self for\n\t * chaining otherwise.\n\t */\n\t this.imgSrcSanitizationWhitelist = function(regexp) {\n\t if (isDefined(regexp)) {\n\t imgSrcSanitizationWhitelist = regexp;\n\t return this;\n\t }\n\t return imgSrcSanitizationWhitelist;\n\t };\n\t\n\t this.$get = function() {\n\t return function sanitizeUri(uri, isImage) {\n\t var regex = isImage ? imgSrcSanitizationWhitelist : aHrefSanitizationWhitelist;\n\t var normalizedVal;\n\t normalizedVal = urlResolve(uri).href;\n\t if (normalizedVal !== '' && !normalizedVal.match(regex)) {\n\t return 'unsafe:' + normalizedVal;\n\t }\n\t return uri;\n\t };\n\t };\n\t}\n\t\n\t/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *\n\t * Any commits to this file should be reviewed with security in mind. *\n\t * Changes to this file can potentially create security vulnerabilities. *\n\t * An approval from 2 Core members with history of modifying *\n\t * this file is required. *\n\t * *\n\t * Does the change somehow allow for arbitrary javascript to be executed? *\n\t * Or allows for someone to change the prototype of built-in objects? *\n\t * Or gives undesired access to variables likes document or window? *\n\t * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */\n\t\n\tvar $sceMinErr = minErr('$sce');\n\t\n\tvar SCE_CONTEXTS = {\n\t HTML: 'html',\n\t CSS: 'css',\n\t URL: 'url',\n\t // RESOURCE_URL is a subtype of URL used in contexts where a privileged resource is sourced from a\n\t // url. (e.g. ng-include, script src, templateUrl)\n\t RESOURCE_URL: 'resourceUrl',\n\t JS: 'js'\n\t};\n\t\n\t// Helper functions follow.\n\t\n\tfunction adjustMatcher(matcher) {\n\t if (matcher === 'self') {\n\t return matcher;\n\t } else if (isString(matcher)) {\n\t // Strings match exactly except for 2 wildcards - '*' and '**'.\n\t // '*' matches any character except those from the set ':/.?&'.\n\t // '**' matches any character (like .* in a RegExp).\n\t // More than 2 *'s raises an error as it's ill defined.\n\t if (matcher.indexOf('***') > -1) {\n\t throw $sceMinErr('iwcard',\n\t 'Illegal sequence *** in string matcher. String: {0}', matcher);\n\t }\n\t matcher = escapeForRegexp(matcher).\n\t replace('\\\\*\\\\*', '.*').\n\t replace('\\\\*', '[^:/.?&;]*');\n\t return new RegExp('^' + matcher + '$');\n\t } else if (isRegExp(matcher)) {\n\t // The only other type of matcher allowed is a Regexp.\n\t // Match entire URL / disallow partial matches.\n\t // Flags are reset (i.e. no global, ignoreCase or multiline)\n\t return new RegExp('^' + matcher.source + '$');\n\t } else {\n\t throw $sceMinErr('imatcher',\n\t 'Matchers may only be \"self\", string patterns or RegExp objects');\n\t }\n\t}\n\t\n\t\n\tfunction adjustMatchers(matchers) {\n\t var adjustedMatchers = [];\n\t if (isDefined(matchers)) {\n\t forEach(matchers, function(matcher) {\n\t adjustedMatchers.push(adjustMatcher(matcher));\n\t });\n\t }\n\t return adjustedMatchers;\n\t}\n\t\n\t\n\t/**\n\t * @ngdoc service\n\t * @name $sceDelegate\n\t * @kind function\n\t *\n\t * @description\n\t *\n\t * `$sceDelegate` is a service that is used by the `$sce` service to provide {@link ng.$sce Strict\n\t * Contextual Escaping (SCE)} services to AngularJS.\n\t *\n\t * Typically, you would configure or override the {@link ng.$sceDelegate $sceDelegate} instead of\n\t * the `$sce` service to customize the way Strict Contextual Escaping works in AngularJS. This is\n\t * because, while the `$sce` provides numerous shorthand methods, etc., you really only need to\n\t * override 3 core functions (`trustAs`, `getTrusted` and `valueOf`) to replace the way things\n\t * work because `$sce` delegates to `$sceDelegate` for these operations.\n\t *\n\t * Refer {@link ng.$sceDelegateProvider $sceDelegateProvider} to configure this service.\n\t *\n\t * The default instance of `$sceDelegate` should work out of the box with little pain. While you\n\t * can override it completely to change the behavior of `$sce`, the common case would\n\t * involve configuring the {@link ng.$sceDelegateProvider $sceDelegateProvider} instead by setting\n\t * your own whitelists and blacklists for trusting URLs used for loading AngularJS resources such as\n\t * templates. Refer {@link ng.$sceDelegateProvider#resourceUrlWhitelist\n\t * $sceDelegateProvider.resourceUrlWhitelist} and {@link\n\t * ng.$sceDelegateProvider#resourceUrlBlacklist $sceDelegateProvider.resourceUrlBlacklist}\n\t */\n\t\n\t/**\n\t * @ngdoc provider\n\t * @name $sceDelegateProvider\n\t * @description\n\t *\n\t * The `$sceDelegateProvider` provider allows developers to configure the {@link ng.$sceDelegate\n\t * $sceDelegate} service. This allows one to get/set the whitelists and blacklists used to ensure\n\t * that the URLs used for sourcing Angular templates are safe. Refer {@link\n\t * ng.$sceDelegateProvider#resourceUrlWhitelist $sceDelegateProvider.resourceUrlWhitelist} and\n\t * {@link ng.$sceDelegateProvider#resourceUrlBlacklist $sceDelegateProvider.resourceUrlBlacklist}\n\t *\n\t * For the general details about this service in Angular, read the main page for {@link ng.$sce\n\t * Strict Contextual Escaping (SCE)}.\n\t *\n\t * **Example**: Consider the following case. \n\t *\n\t * - your app is hosted at url `http://myapp.example.com/`\n\t * - but some of your templates are hosted on other domains you control such as\n\t * `http://srv01.assets.example.com/`,  `http://srv02.assets.example.com/`, etc.\n\t * - and you have an open redirect at `http://myapp.example.com/clickThru?...`.\n\t *\n\t * Here is what a secure configuration for this scenario might look like:\n\t *\n\t * ```\n\t * angular.module('myApp', []).config(function($sceDelegateProvider) {\n\t * $sceDelegateProvider.resourceUrlWhitelist([\n\t * // Allow same origin resource loads.\n\t * 'self',\n\t * // Allow loading from our assets domain. Notice the difference between * and **.\n\t * 'http://srv*.assets.example.com/**'\n\t * ]);\n\t *\n\t * // The blacklist overrides the whitelist so the open redirect here is blocked.\n\t * $sceDelegateProvider.resourceUrlBlacklist([\n\t * 'http://myapp.example.com/clickThru**'\n\t * ]);\n\t * });\n\t * ```\n\t */\n\t\n\tfunction $SceDelegateProvider() {\n\t this.SCE_CONTEXTS = SCE_CONTEXTS;\n\t\n\t // Resource URLs can also be trusted by policy.\n\t var resourceUrlWhitelist = ['self'],\n\t resourceUrlBlacklist = [];\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $sceDelegateProvider#resourceUrlWhitelist\n\t * @kind function\n\t *\n\t * @param {Array=} whitelist When provided, replaces the resourceUrlWhitelist with the value\n\t * provided. This must be an array or null. A snapshot of this array is used so further\n\t * changes to the array are ignored.\n\t *\n\t * Follow {@link ng.$sce#resourceUrlPatternItem this link} for a description of the items\n\t * allowed in this array.\n\t *\n\t *
\n\t * **Note:** an empty whitelist array will block all URLs!\n\t *
\n\t *\n\t * @return {Array} the currently set whitelist array.\n\t *\n\t * The **default value** when no whitelist has been explicitly set is `['self']` allowing only\n\t * same origin resource requests.\n\t *\n\t * @description\n\t * Sets/Gets the whitelist of trusted resource URLs.\n\t */\n\t this.resourceUrlWhitelist = function(value) {\n\t if (arguments.length) {\n\t resourceUrlWhitelist = adjustMatchers(value);\n\t }\n\t return resourceUrlWhitelist;\n\t };\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $sceDelegateProvider#resourceUrlBlacklist\n\t * @kind function\n\t *\n\t * @param {Array=} blacklist When provided, replaces the resourceUrlBlacklist with the value\n\t * provided. This must be an array or null. A snapshot of this array is used so further\n\t * changes to the array are ignored.\n\t *\n\t * Follow {@link ng.$sce#resourceUrlPatternItem this link} for a description of the items\n\t * allowed in this array.\n\t *\n\t * The typical usage for the blacklist is to **block\n\t * [open redirects](http://cwe.mitre.org/data/definitions/601.html)** served by your domain as\n\t * these would otherwise be trusted but actually return content from the redirected domain.\n\t *\n\t * Finally, **the blacklist overrides the whitelist** and has the final say.\n\t *\n\t * @return {Array} the currently set blacklist array.\n\t *\n\t * The **default value** when no whitelist has been explicitly set is the empty array (i.e. there\n\t * is no blacklist.)\n\t *\n\t * @description\n\t * Sets/Gets the blacklist of trusted resource URLs.\n\t */\n\t\n\t this.resourceUrlBlacklist = function(value) {\n\t if (arguments.length) {\n\t resourceUrlBlacklist = adjustMatchers(value);\n\t }\n\t return resourceUrlBlacklist;\n\t };\n\t\n\t this.$get = ['$injector', function($injector) {\n\t\n\t var htmlSanitizer = function htmlSanitizer(html) {\n\t throw $sceMinErr('unsafe', 'Attempting to use an unsafe value in a safe context.');\n\t };\n\t\n\t if ($injector.has('$sanitize')) {\n\t htmlSanitizer = $injector.get('$sanitize');\n\t }\n\t\n\t\n\t function matchUrl(matcher, parsedUrl) {\n\t if (matcher === 'self') {\n\t return urlIsSameOrigin(parsedUrl);\n\t } else {\n\t // definitely a regex. See adjustMatchers()\n\t return !!matcher.exec(parsedUrl.href);\n\t }\n\t }\n\t\n\t function isResourceUrlAllowedByPolicy(url) {\n\t var parsedUrl = urlResolve(url.toString());\n\t var i, n, allowed = false;\n\t // Ensure that at least one item from the whitelist allows this url.\n\t for (i = 0, n = resourceUrlWhitelist.length; i < n; i++) {\n\t if (matchUrl(resourceUrlWhitelist[i], parsedUrl)) {\n\t allowed = true;\n\t break;\n\t }\n\t }\n\t if (allowed) {\n\t // Ensure that no item from the blacklist blocked this url.\n\t for (i = 0, n = resourceUrlBlacklist.length; i < n; i++) {\n\t if (matchUrl(resourceUrlBlacklist[i], parsedUrl)) {\n\t allowed = false;\n\t break;\n\t }\n\t }\n\t }\n\t return allowed;\n\t }\n\t\n\t function generateHolderType(Base) {\n\t var holderType = function TrustedValueHolderType(trustedValue) {\n\t this.$$unwrapTrustedValue = function() {\n\t return trustedValue;\n\t };\n\t };\n\t if (Base) {\n\t holderType.prototype = new Base();\n\t }\n\t holderType.prototype.valueOf = function sceValueOf() {\n\t return this.$$unwrapTrustedValue();\n\t };\n\t holderType.prototype.toString = function sceToString() {\n\t return this.$$unwrapTrustedValue().toString();\n\t };\n\t return holderType;\n\t }\n\t\n\t var trustedValueHolderBase = generateHolderType(),\n\t byType = {};\n\t\n\t byType[SCE_CONTEXTS.HTML] = generateHolderType(trustedValueHolderBase);\n\t byType[SCE_CONTEXTS.CSS] = generateHolderType(trustedValueHolderBase);\n\t byType[SCE_CONTEXTS.URL] = generateHolderType(trustedValueHolderBase);\n\t byType[SCE_CONTEXTS.JS] = generateHolderType(trustedValueHolderBase);\n\t byType[SCE_CONTEXTS.RESOURCE_URL] = generateHolderType(byType[SCE_CONTEXTS.URL]);\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $sceDelegate#trustAs\n\t *\n\t * @description\n\t * Returns an object that is trusted by angular for use in specified strict\n\t * contextual escaping contexts (such as ng-bind-html, ng-include, any src\n\t * attribute interpolation, any dom event binding attribute interpolation\n\t * such as for onclick, etc.) that uses the provided value.\n\t * See {@link ng.$sce $sce} for enabling strict contextual escaping.\n\t *\n\t * @param {string} type The kind of context in which this value is safe for use. e.g. url,\n\t * resourceUrl, html, js and css.\n\t * @param {*} value The value that that should be considered trusted/safe.\n\t * @returns {*} A value that can be used to stand in for the provided `value` in places\n\t * where Angular expects a $sce.trustAs() return value.\n\t */\n\t function trustAs(type, trustedValue) {\n\t var Constructor = (byType.hasOwnProperty(type) ? byType[type] : null);\n\t if (!Constructor) {\n\t throw $sceMinErr('icontext',\n\t 'Attempted to trust a value in invalid context. Context: {0}; Value: {1}',\n\t type, trustedValue);\n\t }\n\t if (trustedValue === null || isUndefined(trustedValue) || trustedValue === '') {\n\t return trustedValue;\n\t }\n\t // All the current contexts in SCE_CONTEXTS happen to be strings. In order to avoid trusting\n\t // mutable objects, we ensure here that the value passed in is actually a string.\n\t if (typeof trustedValue !== 'string') {\n\t throw $sceMinErr('itype',\n\t 'Attempted to trust a non-string value in a content requiring a string: Context: {0}',\n\t type);\n\t }\n\t return new Constructor(trustedValue);\n\t }\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $sceDelegate#valueOf\n\t *\n\t * @description\n\t * If the passed parameter had been returned by a prior call to {@link ng.$sceDelegate#trustAs\n\t * `$sceDelegate.trustAs`}, returns the value that had been passed to {@link\n\t * ng.$sceDelegate#trustAs `$sceDelegate.trustAs`}.\n\t *\n\t * If the passed parameter is not a value that had been returned by {@link\n\t * ng.$sceDelegate#trustAs `$sceDelegate.trustAs`}, returns it as-is.\n\t *\n\t * @param {*} value The result of a prior {@link ng.$sceDelegate#trustAs `$sceDelegate.trustAs`}\n\t * call or anything else.\n\t * @returns {*} The `value` that was originally provided to {@link ng.$sceDelegate#trustAs\n\t * `$sceDelegate.trustAs`} if `value` is the result of such a call. Otherwise, returns\n\t * `value` unchanged.\n\t */\n\t function valueOf(maybeTrusted) {\n\t if (maybeTrusted instanceof trustedValueHolderBase) {\n\t return maybeTrusted.$$unwrapTrustedValue();\n\t } else {\n\t return maybeTrusted;\n\t }\n\t }\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $sceDelegate#getTrusted\n\t *\n\t * @description\n\t * Takes the result of a {@link ng.$sceDelegate#trustAs `$sceDelegate.trustAs`} call and\n\t * returns the originally supplied value if the queried context type is a supertype of the\n\t * created type. If this condition isn't satisfied, throws an exception.\n\t *\n\t * @param {string} type The kind of context in which this value is to be used.\n\t * @param {*} maybeTrusted The result of a prior {@link ng.$sceDelegate#trustAs\n\t * `$sceDelegate.trustAs`} call.\n\t * @returns {*} The value the was originally provided to {@link ng.$sceDelegate#trustAs\n\t * `$sceDelegate.trustAs`} if valid in this context. Otherwise, throws an exception.\n\t */\n\t function getTrusted(type, maybeTrusted) {\n\t if (maybeTrusted === null || isUndefined(maybeTrusted) || maybeTrusted === '') {\n\t return maybeTrusted;\n\t }\n\t var constructor = (byType.hasOwnProperty(type) ? byType[type] : null);\n\t if (constructor && maybeTrusted instanceof constructor) {\n\t return maybeTrusted.$$unwrapTrustedValue();\n\t }\n\t // If we get here, then we may only take one of two actions.\n\t // 1. sanitize the value for the requested type, or\n\t // 2. throw an exception.\n\t if (type === SCE_CONTEXTS.RESOURCE_URL) {\n\t if (isResourceUrlAllowedByPolicy(maybeTrusted)) {\n\t return maybeTrusted;\n\t } else {\n\t throw $sceMinErr('insecurl',\n\t 'Blocked loading resource from url not allowed by $sceDelegate policy. URL: {0}',\n\t maybeTrusted.toString());\n\t }\n\t } else if (type === SCE_CONTEXTS.HTML) {\n\t return htmlSanitizer(maybeTrusted);\n\t }\n\t throw $sceMinErr('unsafe', 'Attempting to use an unsafe value in a safe context.');\n\t }\n\t\n\t return { trustAs: trustAs,\n\t getTrusted: getTrusted,\n\t valueOf: valueOf };\n\t }];\n\t}\n\t\n\t\n\t/**\n\t * @ngdoc provider\n\t * @name $sceProvider\n\t * @description\n\t *\n\t * The $sceProvider provider allows developers to configure the {@link ng.$sce $sce} service.\n\t * - enable/disable Strict Contextual Escaping (SCE) in a module\n\t * - override the default implementation with a custom delegate\n\t *\n\t * Read more about {@link ng.$sce Strict Contextual Escaping (SCE)}.\n\t */\n\t\n\t/* jshint maxlen: false*/\n\t\n\t/**\n\t * @ngdoc service\n\t * @name $sce\n\t * @kind function\n\t *\n\t * @description\n\t *\n\t * `$sce` is a service that provides Strict Contextual Escaping services to AngularJS.\n\t *\n\t * # Strict Contextual Escaping\n\t *\n\t * Strict Contextual Escaping (SCE) is a mode in which AngularJS requires bindings in certain\n\t * contexts to result in a value that is marked as safe to use for that context. One example of\n\t * such a context is binding arbitrary html controlled by the user via `ng-bind-html`. We refer\n\t * to these contexts as privileged or SCE contexts.\n\t *\n\t * As of version 1.2, Angular ships with SCE enabled by default.\n\t *\n\t * Note: When enabled (the default), IE<11 in quirks mode is not supported. In this mode, IE<11 allow\n\t * one to execute arbitrary javascript by the use of the expression() syntax. Refer\n\t * to learn more about them.\n\t * You can ensure your document is in standards mode and not quirks mode by adding ``\n\t * to the top of your HTML document.\n\t *\n\t * SCE assists in writing code in way that (a) is secure by default and (b) makes auditing for\n\t * security vulnerabilities such as XSS, clickjacking, etc. a lot easier.\n\t *\n\t * Here's an example of a binding in a privileged context:\n\t *\n\t * ```\n\t * \n\t *
\n\t * ```\n\t *\n\t * Notice that `ng-bind-html` is bound to `userHtml` controlled by the user. With SCE\n\t * disabled, this application allows the user to render arbitrary HTML into the DIV.\n\t * In a more realistic example, one may be rendering user comments, blog articles, etc. via\n\t * bindings. (HTML is just one example of a context where rendering user controlled input creates\n\t * security vulnerabilities.)\n\t *\n\t * For the case of HTML, you might use a library, either on the client side, or on the server side,\n\t * to sanitize unsafe HTML before binding to the value and rendering it in the document.\n\t *\n\t * How would you ensure that every place that used these types of bindings was bound to a value that\n\t * was sanitized by your library (or returned as safe for rendering by your server?) How can you\n\t * ensure that you didn't accidentally delete the line that sanitized the value, or renamed some\n\t * properties/fields and forgot to update the binding to the sanitized value?\n\t *\n\t * To be secure by default, you want to ensure that any such bindings are disallowed unless you can\n\t * determine that something explicitly says it's safe to use a value for binding in that\n\t * context. You can then audit your code (a simple grep would do) to ensure that this is only done\n\t * for those values that you can easily tell are safe - because they were received from your server,\n\t * sanitized by your library, etc. You can organize your codebase to help with this - perhaps\n\t * allowing only the files in a specific directory to do this. Ensuring that the internal API\n\t * exposed by that code doesn't markup arbitrary values as safe then becomes a more manageable task.\n\t *\n\t * In the case of AngularJS' SCE service, one uses {@link ng.$sce#trustAs $sce.trustAs}\n\t * (and shorthand methods such as {@link ng.$sce#trustAsHtml $sce.trustAsHtml}, etc.) to\n\t * obtain values that will be accepted by SCE / privileged contexts.\n\t *\n\t *\n\t * ## How does it work?\n\t *\n\t * In privileged contexts, directives and code will bind to the result of {@link ng.$sce#getTrusted\n\t * $sce.getTrusted(context, value)} rather than to the value directly. Directives use {@link\n\t * ng.$sce#parseAs $sce.parseAs} rather than `$parse` to watch attribute bindings, which performs the\n\t * {@link ng.$sce#getTrusted $sce.getTrusted} behind the scenes on non-constant literals.\n\t *\n\t * As an example, {@link ng.directive:ngBindHtml ngBindHtml} uses {@link\n\t * ng.$sce#parseAsHtml $sce.parseAsHtml(binding expression)}. Here's the actual code (slightly\n\t * simplified):\n\t *\n\t * ```\n\t * var ngBindHtmlDirective = ['$sce', function($sce) {\n\t * return function(scope, element, attr) {\n\t * scope.$watch($sce.parseAsHtml(attr.ngBindHtml), function(value) {\n\t * element.html(value || '');\n\t * });\n\t * };\n\t * }];\n\t * ```\n\t *\n\t * ## Impact on loading templates\n\t *\n\t * This applies both to the {@link ng.directive:ngInclude `ng-include`} directive as well as\n\t * `templateUrl`'s specified by {@link guide/directive directives}.\n\t *\n\t * By default, Angular only loads templates from the same domain and protocol as the application\n\t * document. This is done by calling {@link ng.$sce#getTrustedResourceUrl\n\t * $sce.getTrustedResourceUrl} on the template URL. To load templates from other domains and/or\n\t * protocols, you may either {@link ng.$sceDelegateProvider#resourceUrlWhitelist whitelist\n\t * them} or {@link ng.$sce#trustAsResourceUrl wrap it} into a trusted value.\n\t *\n\t * *Please note*:\n\t * The browser's\n\t * [Same Origin Policy](https://code.google.com/p/browsersec/wiki/Part2#Same-origin_policy_for_XMLHttpRequest)\n\t * and [Cross-Origin Resource Sharing (CORS)](http://www.w3.org/TR/cors/)\n\t * policy apply in addition to this and may further restrict whether the template is successfully\n\t * loaded. This means that without the right CORS policy, loading templates from a different domain\n\t * won't work on all browsers. Also, loading templates from `file://` URL does not work on some\n\t * browsers.\n\t *\n\t * ## This feels like too much overhead\n\t *\n\t * It's important to remember that SCE only applies to interpolation expressions.\n\t *\n\t * If your expressions are constant literals, they're automatically trusted and you don't need to\n\t * call `$sce.trustAs` on them (remember to include the `ngSanitize` module) (e.g.\n\t * `
implicitly trusted'\">
`) just works.\n\t *\n\t * Additionally, `a[href]` and `img[src]` automatically sanitize their URLs and do not pass them\n\t * through {@link ng.$sce#getTrusted $sce.getTrusted}. SCE doesn't play a role here.\n\t *\n\t * The included {@link ng.$sceDelegate $sceDelegate} comes with sane defaults to allow you to load\n\t * templates in `ng-include` from your application's domain without having to even know about SCE.\n\t * It blocks loading templates from other domains or loading templates over http from an https\n\t * served document. You can change these by setting your own custom {@link\n\t * ng.$sceDelegateProvider#resourceUrlWhitelist whitelists} and {@link\n\t * ng.$sceDelegateProvider#resourceUrlBlacklist blacklists} for matching such URLs.\n\t *\n\t * This significantly reduces the overhead. It is far easier to pay the small overhead and have an\n\t * application that's secure and can be audited to verify that with much more ease than bolting\n\t * security onto an application later.\n\t *\n\t * \n\t * ## What trusted context types are supported?\n\t *\n\t * | Context | Notes |\n\t * |---------------------|----------------|\n\t * | `$sce.HTML` | For HTML that's safe to source into the application. The {@link ng.directive:ngBindHtml ngBindHtml} directive uses this context for bindings. If an unsafe value is encountered and the {@link ngSanitize $sanitize} module is present this will sanitize the value instead of throwing an error. |\n\t * | `$sce.CSS` | For CSS that's safe to source into the application. Currently unused. Feel free to use it in your own directives. |\n\t * | `$sce.URL` | For URLs that are safe to follow as links. Currently unused (`
Note that `$sce.RESOURCE_URL` makes a stronger statement about the URL than `$sce.URL` does and therefore contexts requiring values trusted for `$sce.RESOURCE_URL` can be used anywhere that values trusted for `$sce.URL` are required. |\n\t * | `$sce.JS` | For JavaScript that is safe to execute in your application's context. Currently unused. Feel free to use it in your own directives. |\n\t *\n\t * ## Format of items in {@link ng.$sceDelegateProvider#resourceUrlWhitelist resourceUrlWhitelist}/{@link ng.$sceDelegateProvider#resourceUrlBlacklist Blacklist}
\n\t *\n\t * Each element in these arrays must be one of the following:\n\t *\n\t * - **'self'**\n\t * - The special **string**, `'self'`, can be used to match against all URLs of the **same\n\t * domain** as the application document using the **same protocol**.\n\t * - **String** (except the special value `'self'`)\n\t * - The string is matched against the full *normalized / absolute URL* of the resource\n\t * being tested (substring matches are not good enough.)\n\t * - There are exactly **two wildcard sequences** - `*` and `**`. All other characters\n\t * match themselves.\n\t * - `*`: matches zero or more occurrences of any character other than one of the following 6\n\t * characters: '`:`', '`/`', '`.`', '`?`', '`&`' and '`;`'. It's a useful wildcard for use\n\t * in a whitelist.\n\t * - `**`: matches zero or more occurrences of *any* character. As such, it's not\n\t * appropriate for use in a scheme, domain, etc. as it would match too much. (e.g.\n\t * http://**.example.com/ would match http://evil.com/?ignore=.example.com/ and that might\n\t * not have been the intention.) Its usage at the very end of the path is ok. (e.g.\n\t * http://foo.example.com/templates/**).\n\t * - **RegExp** (*see caveat below*)\n\t * - *Caveat*: While regular expressions are powerful and offer great flexibility, their syntax\n\t * (and all the inevitable escaping) makes them *harder to maintain*. It's easy to\n\t * accidentally introduce a bug when one updates a complex expression (imho, all regexes should\n\t * have good test coverage). For instance, the use of `.` in the regex is correct only in a\n\t * small number of cases. A `.` character in the regex used when matching the scheme or a\n\t * subdomain could be matched against a `:` or literal `.` that was likely not intended. It\n\t * is highly recommended to use the string patterns and only fall back to regular expressions\n\t * as a last resort.\n\t * - The regular expression must be an instance of RegExp (i.e. not a string.) It is\n\t * matched against the **entire** *normalized / absolute URL* of the resource being tested\n\t * (even when the RegExp did not have the `^` and `$` codes.) In addition, any flags\n\t * present on the RegExp (such as multiline, global, ignoreCase) are ignored.\n\t * - If you are generating your JavaScript from some other templating engine (not\n\t * recommended, e.g. in issue [#4006](https://github.com/angular/angular.js/issues/4006)),\n\t * remember to escape your regular expression (and be aware that you might need more than\n\t * one level of escaping depending on your templating engine and the way you interpolated\n\t * the value.) Do make use of your platform's escaping mechanism as it might be good\n\t * enough before coding your own. E.g. Ruby has\n\t * [Regexp.escape(str)](http://www.ruby-doc.org/core-2.0.0/Regexp.html#method-c-escape)\n\t * and Python has [re.escape](http://docs.python.org/library/re.html#re.escape).\n\t * Javascript lacks a similar built in function for escaping. Take a look at Google\n\t * Closure library's [goog.string.regExpEscape(s)](\n\t * http://docs.closure-library.googlecode.com/git/closure_goog_string_string.js.source.html#line962).\n\t *\n\t * Refer {@link ng.$sceDelegateProvider $sceDelegateProvider} for an example.\n\t *\n\t * ## Show me an example using SCE.\n\t *\n\t * \n\t * \n\t *
\n\t *

\n\t * User comments
\n\t * By default, HTML that isn't explicitly trusted (e.g. Alice's comment) is sanitized when\n\t * $sanitize is available. If $sanitize isn't available, this results in an error instead of an\n\t * exploit.\n\t *
\n\t *
\n\t * {{userComment.name}}:\n\t * \n\t *
\n\t *
\n\t *
\n\t *
\n\t *
\n\t *\n\t * \n\t * angular.module('mySceApp', ['ngSanitize'])\n\t * .controller('AppController', ['$http', '$templateCache', '$sce',\n\t * function($http, $templateCache, $sce) {\n\t * var self = this;\n\t * $http.get(\"test_data.json\", {cache: $templateCache}).success(function(userComments) {\n\t * self.userComments = userComments;\n\t * });\n\t * self.explicitlyTrustedHtml = $sce.trustAsHtml(\n\t * 'Hover over this text.');\n\t * }]);\n\t * \n\t *\n\t * \n\t * [\n\t * { \"name\": \"Alice\",\n\t * \"htmlComment\":\n\t * \"Is anyone reading this?\"\n\t * },\n\t * { \"name\": \"Bob\",\n\t * \"htmlComment\": \"Yes! Am I the only other one?\"\n\t * }\n\t * ]\n\t * \n\t *\n\t * \n\t * describe('SCE doc demo', function() {\n\t * it('should sanitize untrusted values', function() {\n\t * expect(element.all(by.css('.htmlComment')).first().getInnerHtml())\n\t * .toBe('Is anyone reading this?');\n\t * });\n\t *\n\t * it('should NOT sanitize explicitly trusted values', function() {\n\t * expect(element(by.id('explicitlyTrustedHtml')).getInnerHtml()).toBe(\n\t * 'Hover over this text.');\n\t * });\n\t * });\n\t * \n\t *
\n\t *\n\t *\n\t *\n\t * ## Can I disable SCE completely?\n\t *\n\t * Yes, you can. However, this is strongly discouraged. SCE gives you a lot of security benefits\n\t * for little coding overhead. It will be much harder to take an SCE disabled application and\n\t * either secure it on your own or enable SCE at a later stage. It might make sense to disable SCE\n\t * for cases where you have a lot of existing code that was written before SCE was introduced and\n\t * you're migrating them a module at a time.\n\t *\n\t * That said, here's how you can completely disable SCE:\n\t *\n\t * ```\n\t * angular.module('myAppWithSceDisabledmyApp', []).config(function($sceProvider) {\n\t * // Completely disable SCE. For demonstration purposes only!\n\t * // Do not use in new projects.\n\t * $sceProvider.enabled(false);\n\t * });\n\t * ```\n\t *\n\t */\n\t/* jshint maxlen: 100 */\n\t\n\tfunction $SceProvider() {\n\t var enabled = true;\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $sceProvider#enabled\n\t * @kind function\n\t *\n\t * @param {boolean=} value If provided, then enables/disables SCE.\n\t * @return {boolean} true if SCE is enabled, false otherwise.\n\t *\n\t * @description\n\t * Enables/disables SCE and returns the current value.\n\t */\n\t this.enabled = function(value) {\n\t if (arguments.length) {\n\t enabled = !!value;\n\t }\n\t return enabled;\n\t };\n\t\n\t\n\t /* Design notes on the default implementation for SCE.\n\t *\n\t * The API contract for the SCE delegate\n\t * -------------------------------------\n\t * The SCE delegate object must provide the following 3 methods:\n\t *\n\t * - trustAs(contextEnum, value)\n\t * This method is used to tell the SCE service that the provided value is OK to use in the\n\t * contexts specified by contextEnum. It must return an object that will be accepted by\n\t * getTrusted() for a compatible contextEnum and return this value.\n\t *\n\t * - valueOf(value)\n\t * For values that were not produced by trustAs(), return them as is. For values that were\n\t * produced by trustAs(), return the corresponding input value to trustAs. Basically, if\n\t * trustAs is wrapping the given values into some type, this operation unwraps it when given\n\t * such a value.\n\t *\n\t * - getTrusted(contextEnum, value)\n\t * This function should return the a value that is safe to use in the context specified by\n\t * contextEnum or throw and exception otherwise.\n\t *\n\t * NOTE: This contract deliberately does NOT state that values returned by trustAs() must be\n\t * opaque or wrapped in some holder object. That happens to be an implementation detail. For\n\t * instance, an implementation could maintain a registry of all trusted objects by context. In\n\t * such a case, trustAs() would return the same object that was passed in. getTrusted() would\n\t * return the same object passed in if it was found in the registry under a compatible context or\n\t * throw an exception otherwise. An implementation might only wrap values some of the time based\n\t * on some criteria. getTrusted() might return a value and not throw an exception for special\n\t * constants or objects even if not wrapped. All such implementations fulfill this contract.\n\t *\n\t *\n\t * A note on the inheritance model for SCE contexts\n\t * ------------------------------------------------\n\t * I've used inheritance and made RESOURCE_URL wrapped types a subtype of URL wrapped types. This\n\t * is purely an implementation details.\n\t *\n\t * The contract is simply this:\n\t *\n\t * getTrusted($sce.RESOURCE_URL, value) succeeding implies that getTrusted($sce.URL, value)\n\t * will also succeed.\n\t *\n\t * Inheritance happens to capture this in a natural way. In some future, we\n\t * may not use inheritance anymore. That is OK because no code outside of\n\t * sce.js and sceSpecs.js would need to be aware of this detail.\n\t */\n\t\n\t this.$get = ['$parse', '$sceDelegate', function(\n\t $parse, $sceDelegate) {\n\t // Prereq: Ensure that we're not running in IE<11 quirks mode. In that mode, IE < 11 allow\n\t // the \"expression(javascript expression)\" syntax which is insecure.\n\t if (enabled && msie < 8) {\n\t throw $sceMinErr('iequirks',\n\t 'Strict Contextual Escaping does not support Internet Explorer version < 11 in quirks ' +\n\t 'mode. You can fix this by adding the text to the top of your HTML ' +\n\t 'document. See http://docs.angularjs.org/api/ng.$sce for more information.');\n\t }\n\t\n\t var sce = shallowCopy(SCE_CONTEXTS);\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $sce#isEnabled\n\t * @kind function\n\t *\n\t * @return {Boolean} true if SCE is enabled, false otherwise. If you want to set the value, you\n\t * have to do it at module config time on {@link ng.$sceProvider $sceProvider}.\n\t *\n\t * @description\n\t * Returns a boolean indicating if SCE is enabled.\n\t */\n\t sce.isEnabled = function() {\n\t return enabled;\n\t };\n\t sce.trustAs = $sceDelegate.trustAs;\n\t sce.getTrusted = $sceDelegate.getTrusted;\n\t sce.valueOf = $sceDelegate.valueOf;\n\t\n\t if (!enabled) {\n\t sce.trustAs = sce.getTrusted = function(type, value) { return value; };\n\t sce.valueOf = identity;\n\t }\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $sce#parseAs\n\t *\n\t * @description\n\t * Converts Angular {@link guide/expression expression} into a function. This is like {@link\n\t * ng.$parse $parse} and is identical when the expression is a literal constant. Otherwise, it\n\t * wraps the expression in a call to {@link ng.$sce#getTrusted $sce.getTrusted(*type*,\n\t * *result*)}\n\t *\n\t * @param {string} type The kind of SCE context in which this result will be used.\n\t * @param {string} expression String expression to compile.\n\t * @returns {function(context, locals)} a function which represents the compiled expression:\n\t *\n\t * * `context` – `{object}` – an object against which any expressions embedded in the strings\n\t * are evaluated against (typically a scope object).\n\t * * `locals` – `{object=}` – local variables context object, useful for overriding values in\n\t * `context`.\n\t */\n\t sce.parseAs = function sceParseAs(type, expr) {\n\t var parsed = $parse(expr);\n\t if (parsed.literal && parsed.constant) {\n\t return parsed;\n\t } else {\n\t return $parse(expr, function(value) {\n\t return sce.getTrusted(type, value);\n\t });\n\t }\n\t };\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $sce#trustAs\n\t *\n\t * @description\n\t * Delegates to {@link ng.$sceDelegate#trustAs `$sceDelegate.trustAs`}. As such,\n\t * returns an object that is trusted by angular for use in specified strict contextual\n\t * escaping contexts (such as ng-bind-html, ng-include, any src attribute\n\t * interpolation, any dom event binding attribute interpolation such as for onclick, etc.)\n\t * that uses the provided value. See * {@link ng.$sce $sce} for enabling strict contextual\n\t * escaping.\n\t *\n\t * @param {string} type The kind of context in which this value is safe for use. e.g. url,\n\t * resourceUrl, html, js and css.\n\t * @param {*} value The value that that should be considered trusted/safe.\n\t * @returns {*} A value that can be used to stand in for the provided `value` in places\n\t * where Angular expects a $sce.trustAs() return value.\n\t */\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $sce#trustAsHtml\n\t *\n\t * @description\n\t * Shorthand method. `$sce.trustAsHtml(value)` →\n\t * {@link ng.$sceDelegate#trustAs `$sceDelegate.trustAs($sce.HTML, value)`}\n\t *\n\t * @param {*} value The value to trustAs.\n\t * @returns {*} An object that can be passed to {@link ng.$sce#getTrustedHtml\n\t * $sce.getTrustedHtml(value)} to obtain the original value. (privileged directives\n\t * only accept expressions that are either literal constants or are the\n\t * return value of {@link ng.$sce#trustAs $sce.trustAs}.)\n\t */\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $sce#trustAsUrl\n\t *\n\t * @description\n\t * Shorthand method. `$sce.trustAsUrl(value)` →\n\t * {@link ng.$sceDelegate#trustAs `$sceDelegate.trustAs($sce.URL, value)`}\n\t *\n\t * @param {*} value The value to trustAs.\n\t * @returns {*} An object that can be passed to {@link ng.$sce#getTrustedUrl\n\t * $sce.getTrustedUrl(value)} to obtain the original value. (privileged directives\n\t * only accept expressions that are either literal constants or are the\n\t * return value of {@link ng.$sce#trustAs $sce.trustAs}.)\n\t */\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $sce#trustAsResourceUrl\n\t *\n\t * @description\n\t * Shorthand method. `$sce.trustAsResourceUrl(value)` →\n\t * {@link ng.$sceDelegate#trustAs `$sceDelegate.trustAs($sce.RESOURCE_URL, value)`}\n\t *\n\t * @param {*} value The value to trustAs.\n\t * @returns {*} An object that can be passed to {@link ng.$sce#getTrustedResourceUrl\n\t * $sce.getTrustedResourceUrl(value)} to obtain the original value. (privileged directives\n\t * only accept expressions that are either literal constants or are the return\n\t * value of {@link ng.$sce#trustAs $sce.trustAs}.)\n\t */\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $sce#trustAsJs\n\t *\n\t * @description\n\t * Shorthand method. `$sce.trustAsJs(value)` →\n\t * {@link ng.$sceDelegate#trustAs `$sceDelegate.trustAs($sce.JS, value)`}\n\t *\n\t * @param {*} value The value to trustAs.\n\t * @returns {*} An object that can be passed to {@link ng.$sce#getTrustedJs\n\t * $sce.getTrustedJs(value)} to obtain the original value. (privileged directives\n\t * only accept expressions that are either literal constants or are the\n\t * return value of {@link ng.$sce#trustAs $sce.trustAs}.)\n\t */\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $sce#getTrusted\n\t *\n\t * @description\n\t * Delegates to {@link ng.$sceDelegate#getTrusted `$sceDelegate.getTrusted`}. As such,\n\t * takes the result of a {@link ng.$sce#trustAs `$sce.trustAs`}() call and returns the\n\t * originally supplied value if the queried context type is a supertype of the created type.\n\t * If this condition isn't satisfied, throws an exception.\n\t *\n\t * @param {string} type The kind of context in which this value is to be used.\n\t * @param {*} maybeTrusted The result of a prior {@link ng.$sce#trustAs `$sce.trustAs`}\n\t * call.\n\t * @returns {*} The value the was originally provided to\n\t * {@link ng.$sce#trustAs `$sce.trustAs`} if valid in this context.\n\t * Otherwise, throws an exception.\n\t */\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $sce#getTrustedHtml\n\t *\n\t * @description\n\t * Shorthand method. `$sce.getTrustedHtml(value)` →\n\t * {@link ng.$sceDelegate#getTrusted `$sceDelegate.getTrusted($sce.HTML, value)`}\n\t *\n\t * @param {*} value The value to pass to `$sce.getTrusted`.\n\t * @returns {*} The return value of `$sce.getTrusted($sce.HTML, value)`\n\t */\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $sce#getTrustedCss\n\t *\n\t * @description\n\t * Shorthand method. `$sce.getTrustedCss(value)` →\n\t * {@link ng.$sceDelegate#getTrusted `$sceDelegate.getTrusted($sce.CSS, value)`}\n\t *\n\t * @param {*} value The value to pass to `$sce.getTrusted`.\n\t * @returns {*} The return value of `$sce.getTrusted($sce.CSS, value)`\n\t */\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $sce#getTrustedUrl\n\t *\n\t * @description\n\t * Shorthand method. `$sce.getTrustedUrl(value)` →\n\t * {@link ng.$sceDelegate#getTrusted `$sceDelegate.getTrusted($sce.URL, value)`}\n\t *\n\t * @param {*} value The value to pass to `$sce.getTrusted`.\n\t * @returns {*} The return value of `$sce.getTrusted($sce.URL, value)`\n\t */\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $sce#getTrustedResourceUrl\n\t *\n\t * @description\n\t * Shorthand method. `$sce.getTrustedResourceUrl(value)` →\n\t * {@link ng.$sceDelegate#getTrusted `$sceDelegate.getTrusted($sce.RESOURCE_URL, value)`}\n\t *\n\t * @param {*} value The value to pass to `$sceDelegate.getTrusted`.\n\t * @returns {*} The return value of `$sce.getTrusted($sce.RESOURCE_URL, value)`\n\t */\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $sce#getTrustedJs\n\t *\n\t * @description\n\t * Shorthand method. `$sce.getTrustedJs(value)` →\n\t * {@link ng.$sceDelegate#getTrusted `$sceDelegate.getTrusted($sce.JS, value)`}\n\t *\n\t * @param {*} value The value to pass to `$sce.getTrusted`.\n\t * @returns {*} The return value of `$sce.getTrusted($sce.JS, value)`\n\t */\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $sce#parseAsHtml\n\t *\n\t * @description\n\t * Shorthand method. `$sce.parseAsHtml(expression string)` →\n\t * {@link ng.$sce#parseAs `$sce.parseAs($sce.HTML, value)`}\n\t *\n\t * @param {string} expression String expression to compile.\n\t * @returns {function(context, locals)} a function which represents the compiled expression:\n\t *\n\t * * `context` – `{object}` – an object against which any expressions embedded in the strings\n\t * are evaluated against (typically a scope object).\n\t * * `locals` – `{object=}` – local variables context object, useful for overriding values in\n\t * `context`.\n\t */\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $sce#parseAsCss\n\t *\n\t * @description\n\t * Shorthand method. `$sce.parseAsCss(value)` →\n\t * {@link ng.$sce#parseAs `$sce.parseAs($sce.CSS, value)`}\n\t *\n\t * @param {string} expression String expression to compile.\n\t * @returns {function(context, locals)} a function which represents the compiled expression:\n\t *\n\t * * `context` – `{object}` – an object against which any expressions embedded in the strings\n\t * are evaluated against (typically a scope object).\n\t * * `locals` – `{object=}` – local variables context object, useful for overriding values in\n\t * `context`.\n\t */\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $sce#parseAsUrl\n\t *\n\t * @description\n\t * Shorthand method. `$sce.parseAsUrl(value)` →\n\t * {@link ng.$sce#parseAs `$sce.parseAs($sce.URL, value)`}\n\t *\n\t * @param {string} expression String expression to compile.\n\t * @returns {function(context, locals)} a function which represents the compiled expression:\n\t *\n\t * * `context` – `{object}` – an object against which any expressions embedded in the strings\n\t * are evaluated against (typically a scope object).\n\t * * `locals` – `{object=}` – local variables context object, useful for overriding values in\n\t * `context`.\n\t */\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $sce#parseAsResourceUrl\n\t *\n\t * @description\n\t * Shorthand method. `$sce.parseAsResourceUrl(value)` →\n\t * {@link ng.$sce#parseAs `$sce.parseAs($sce.RESOURCE_URL, value)`}\n\t *\n\t * @param {string} expression String expression to compile.\n\t * @returns {function(context, locals)} a function which represents the compiled expression:\n\t *\n\t * * `context` – `{object}` – an object against which any expressions embedded in the strings\n\t * are evaluated against (typically a scope object).\n\t * * `locals` – `{object=}` – local variables context object, useful for overriding values in\n\t * `context`.\n\t */\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $sce#parseAsJs\n\t *\n\t * @description\n\t * Shorthand method. `$sce.parseAsJs(value)` →\n\t * {@link ng.$sce#parseAs `$sce.parseAs($sce.JS, value)`}\n\t *\n\t * @param {string} expression String expression to compile.\n\t * @returns {function(context, locals)} a function which represents the compiled expression:\n\t *\n\t * * `context` – `{object}` – an object against which any expressions embedded in the strings\n\t * are evaluated against (typically a scope object).\n\t * * `locals` – `{object=}` – local variables context object, useful for overriding values in\n\t * `context`.\n\t */\n\t\n\t // Shorthand delegations.\n\t var parse = sce.parseAs,\n\t getTrusted = sce.getTrusted,\n\t trustAs = sce.trustAs;\n\t\n\t forEach(SCE_CONTEXTS, function(enumValue, name) {\n\t var lName = lowercase(name);\n\t sce[camelCase(\"parse_as_\" + lName)] = function(expr) {\n\t return parse(enumValue, expr);\n\t };\n\t sce[camelCase(\"get_trusted_\" + lName)] = function(value) {\n\t return getTrusted(enumValue, value);\n\t };\n\t sce[camelCase(\"trust_as_\" + lName)] = function(value) {\n\t return trustAs(enumValue, value);\n\t };\n\t });\n\t\n\t return sce;\n\t }];\n\t}\n\t\n\t/**\n\t * !!! This is an undocumented \"private\" service !!!\n\t *\n\t * @name $sniffer\n\t * @requires $window\n\t * @requires $document\n\t *\n\t * @property {boolean} history Does the browser support html5 history api ?\n\t * @property {boolean} transitions Does the browser support CSS transition events ?\n\t * @property {boolean} animations Does the browser support CSS animation events ?\n\t *\n\t * @description\n\t * This is very simple implementation of testing browser's features.\n\t */\n\tfunction $SnifferProvider() {\n\t this.$get = ['$window', '$document', function($window, $document) {\n\t var eventSupport = {},\n\t android =\n\t toInt((/android (\\d+)/.exec(lowercase(($window.navigator || {}).userAgent)) || [])[1]),\n\t boxee = /Boxee/i.test(($window.navigator || {}).userAgent),\n\t document = $document[0] || {},\n\t vendorPrefix,\n\t vendorRegex = /^(Moz|webkit|ms)(?=[A-Z])/,\n\t bodyStyle = document.body && document.body.style,\n\t transitions = false,\n\t animations = false,\n\t match;\n\t\n\t if (bodyStyle) {\n\t for (var prop in bodyStyle) {\n\t if (match = vendorRegex.exec(prop)) {\n\t vendorPrefix = match[0];\n\t vendorPrefix = vendorPrefix.substr(0, 1).toUpperCase() + vendorPrefix.substr(1);\n\t break;\n\t }\n\t }\n\t\n\t if (!vendorPrefix) {\n\t vendorPrefix = ('WebkitOpacity' in bodyStyle) && 'webkit';\n\t }\n\t\n\t transitions = !!(('transition' in bodyStyle) || (vendorPrefix + 'Transition' in bodyStyle));\n\t animations = !!(('animation' in bodyStyle) || (vendorPrefix + 'Animation' in bodyStyle));\n\t\n\t if (android && (!transitions || !animations)) {\n\t transitions = isString(bodyStyle.webkitTransition);\n\t animations = isString(bodyStyle.webkitAnimation);\n\t }\n\t }\n\t\n\t\n\t return {\n\t // Android has history.pushState, but it does not update location correctly\n\t // so let's not use the history API at all.\n\t // http://code.google.com/p/android/issues/detail?id=17471\n\t // https://github.com/angular/angular.js/issues/904\n\t\n\t // older webkit browser (533.9) on Boxee box has exactly the same problem as Android has\n\t // so let's not use the history API also\n\t // We are purposefully using `!(android < 4)` to cover the case when `android` is undefined\n\t // jshint -W018\n\t history: !!($window.history && $window.history.pushState && !(android < 4) && !boxee),\n\t // jshint +W018\n\t hasEvent: function(event) {\n\t // IE9 implements 'input' event it's so fubared that we rather pretend that it doesn't have\n\t // it. In particular the event is not fired when backspace or delete key are pressed or\n\t // when cut operation is performed.\n\t // IE10+ implements 'input' event but it erroneously fires under various situations,\n\t // e.g. when placeholder changes, or a form is focused.\n\t if (event === 'input' && msie <= 11) return false;\n\t\n\t if (isUndefined(eventSupport[event])) {\n\t var divElm = document.createElement('div');\n\t eventSupport[event] = 'on' + event in divElm;\n\t }\n\t\n\t return eventSupport[event];\n\t },\n\t csp: csp(),\n\t vendorPrefix: vendorPrefix,\n\t transitions: transitions,\n\t animations: animations,\n\t android: android\n\t };\n\t }];\n\t}\n\t\n\tvar $compileMinErr = minErr('$compile');\n\t\n\t/**\n\t * @ngdoc service\n\t * @name $templateRequest\n\t *\n\t * @description\n\t * The `$templateRequest` service runs security checks then downloads the provided template using\n\t * `$http` and, upon success, stores the contents inside of `$templateCache`. If the HTTP request\n\t * fails or the response data of the HTTP request is empty, a `$compile` error will be thrown (the\n\t * exception can be thwarted by setting the 2nd parameter of the function to true). Note that the\n\t * contents of `$templateCache` are trusted, so the call to `$sce.getTrustedUrl(tpl)` is omitted\n\t * when `tpl` is of type string and `$templateCache` has the matching entry.\n\t *\n\t * @param {string|TrustedResourceUrl} tpl The HTTP request template URL\n\t * @param {boolean=} ignoreRequestError Whether or not to ignore the exception when the request fails or the template is empty\n\t *\n\t * @return {Promise} a promise for the HTTP response data of the given URL.\n\t *\n\t * @property {number} totalPendingRequests total amount of pending template requests being downloaded.\n\t */\n\tfunction $TemplateRequestProvider() {\n\t this.$get = ['$templateCache', '$http', '$q', '$sce', function($templateCache, $http, $q, $sce) {\n\t function handleRequestFn(tpl, ignoreRequestError) {\n\t handleRequestFn.totalPendingRequests++;\n\t\n\t // We consider the template cache holds only trusted templates, so\n\t // there's no need to go through whitelisting again for keys that already\n\t // are included in there. This also makes Angular accept any script\n\t // directive, no matter its name. However, we still need to unwrap trusted\n\t // types.\n\t if (!isString(tpl) || isUndefined($templateCache.get(tpl))) {\n\t tpl = $sce.getTrustedResourceUrl(tpl);\n\t }\n\t\n\t var transformResponse = $http.defaults && $http.defaults.transformResponse;\n\t\n\t if (isArray(transformResponse)) {\n\t transformResponse = transformResponse.filter(function(transformer) {\n\t return transformer !== defaultHttpResponseTransform;\n\t });\n\t } else if (transformResponse === defaultHttpResponseTransform) {\n\t transformResponse = null;\n\t }\n\t\n\t var httpOptions = {\n\t cache: $templateCache,\n\t transformResponse: transformResponse\n\t };\n\t\n\t return $http.get(tpl, httpOptions)\n\t ['finally'](function() {\n\t handleRequestFn.totalPendingRequests--;\n\t })\n\t .then(function(response) {\n\t $templateCache.put(tpl, response.data);\n\t return response.data;\n\t }, handleError);\n\t\n\t function handleError(resp) {\n\t if (!ignoreRequestError) {\n\t throw $compileMinErr('tpload', 'Failed to load template: {0} (HTTP status: {1} {2})',\n\t tpl, resp.status, resp.statusText);\n\t }\n\t return $q.reject(resp);\n\t }\n\t }\n\t\n\t handleRequestFn.totalPendingRequests = 0;\n\t\n\t return handleRequestFn;\n\t }];\n\t}\n\t\n\tfunction $$TestabilityProvider() {\n\t this.$get = ['$rootScope', '$browser', '$location',\n\t function($rootScope, $browser, $location) {\n\t\n\t /**\n\t * @name $testability\n\t *\n\t * @description\n\t * The private $$testability service provides a collection of methods for use when debugging\n\t * or by automated test and debugging tools.\n\t */\n\t var testability = {};\n\t\n\t /**\n\t * @name $$testability#findBindings\n\t *\n\t * @description\n\t * Returns an array of elements that are bound (via ng-bind or {{}})\n\t * to expressions matching the input.\n\t *\n\t * @param {Element} element The element root to search from.\n\t * @param {string} expression The binding expression to match.\n\t * @param {boolean} opt_exactMatch If true, only returns exact matches\n\t * for the expression. Filters and whitespace are ignored.\n\t */\n\t testability.findBindings = function(element, expression, opt_exactMatch) {\n\t var bindings = element.getElementsByClassName('ng-binding');\n\t var matches = [];\n\t forEach(bindings, function(binding) {\n\t var dataBinding = angular.element(binding).data('$binding');\n\t if (dataBinding) {\n\t forEach(dataBinding, function(bindingName) {\n\t if (opt_exactMatch) {\n\t var matcher = new RegExp('(^|\\\\s)' + escapeForRegexp(expression) + '(\\\\s|\\\\||$)');\n\t if (matcher.test(bindingName)) {\n\t matches.push(binding);\n\t }\n\t } else {\n\t if (bindingName.indexOf(expression) != -1) {\n\t matches.push(binding);\n\t }\n\t }\n\t });\n\t }\n\t });\n\t return matches;\n\t };\n\t\n\t /**\n\t * @name $$testability#findModels\n\t *\n\t * @description\n\t * Returns an array of elements that are two-way found via ng-model to\n\t * expressions matching the input.\n\t *\n\t * @param {Element} element The element root to search from.\n\t * @param {string} expression The model expression to match.\n\t * @param {boolean} opt_exactMatch If true, only returns exact matches\n\t * for the expression.\n\t */\n\t testability.findModels = function(element, expression, opt_exactMatch) {\n\t var prefixes = ['ng-', 'data-ng-', 'ng\\\\:'];\n\t for (var p = 0; p < prefixes.length; ++p) {\n\t var attributeEquals = opt_exactMatch ? '=' : '*=';\n\t var selector = '[' + prefixes[p] + 'model' + attributeEquals + '\"' + expression + '\"]';\n\t var elements = element.querySelectorAll(selector);\n\t if (elements.length) {\n\t return elements;\n\t }\n\t }\n\t };\n\t\n\t /**\n\t * @name $$testability#getLocation\n\t *\n\t * @description\n\t * Shortcut for getting the location in a browser agnostic way. Returns\n\t * the path, search, and hash. (e.g. /path?a=b#hash)\n\t */\n\t testability.getLocation = function() {\n\t return $location.url();\n\t };\n\t\n\t /**\n\t * @name $$testability#setLocation\n\t *\n\t * @description\n\t * Shortcut for navigating to a location without doing a full page reload.\n\t *\n\t * @param {string} url The location url (path, search and hash,\n\t * e.g. /path?a=b#hash) to go to.\n\t */\n\t testability.setLocation = function(url) {\n\t if (url !== $location.url()) {\n\t $location.url(url);\n\t $rootScope.$digest();\n\t }\n\t };\n\t\n\t /**\n\t * @name $$testability#whenStable\n\t *\n\t * @description\n\t * Calls the callback when $timeout and $http requests are completed.\n\t *\n\t * @param {function} callback\n\t */\n\t testability.whenStable = function(callback) {\n\t $browser.notifyWhenNoOutstandingRequests(callback);\n\t };\n\t\n\t return testability;\n\t }];\n\t}\n\t\n\tfunction $TimeoutProvider() {\n\t this.$get = ['$rootScope', '$browser', '$q', '$$q', '$exceptionHandler',\n\t function($rootScope, $browser, $q, $$q, $exceptionHandler) {\n\t\n\t var deferreds = {};\n\t\n\t\n\t /**\n\t * @ngdoc service\n\t * @name $timeout\n\t *\n\t * @description\n\t * Angular's wrapper for `window.setTimeout`. The `fn` function is wrapped into a try/catch\n\t * block and delegates any exceptions to\n\t * {@link ng.$exceptionHandler $exceptionHandler} service.\n\t *\n\t * The return value of calling `$timeout` is a promise, which will be resolved when\n\t * the delay has passed and the timeout function, if provided, is executed.\n\t *\n\t * To cancel a timeout request, call `$timeout.cancel(promise)`.\n\t *\n\t * In tests you can use {@link ngMock.$timeout `$timeout.flush()`} to\n\t * synchronously flush the queue of deferred functions.\n\t *\n\t * If you only want a promise that will be resolved after some specified delay\n\t * then you can call `$timeout` without the `fn` function.\n\t *\n\t * @param {function()=} fn A function, whose execution should be delayed.\n\t * @param {number=} [delay=0] Delay in milliseconds.\n\t * @param {boolean=} [invokeApply=true] If set to `false` skips model dirty checking, otherwise\n\t * will invoke `fn` within the {@link ng.$rootScope.Scope#$apply $apply} block.\n\t * @param {...*=} Pass additional parameters to the executed function.\n\t * @returns {Promise} Promise that will be resolved when the timeout is reached. The promise\n\t * will be resolved with the return value of the `fn` function.\n\t *\n\t */\n\t function timeout(fn, delay, invokeApply) {\n\t if (!isFunction(fn)) {\n\t invokeApply = delay;\n\t delay = fn;\n\t fn = noop;\n\t }\n\t\n\t var args = sliceArgs(arguments, 3),\n\t skipApply = (isDefined(invokeApply) && !invokeApply),\n\t deferred = (skipApply ? $$q : $q).defer(),\n\t promise = deferred.promise,\n\t timeoutId;\n\t\n\t timeoutId = $browser.defer(function() {\n\t try {\n\t deferred.resolve(fn.apply(null, args));\n\t } catch (e) {\n\t deferred.reject(e);\n\t $exceptionHandler(e);\n\t }\n\t finally {\n\t delete deferreds[promise.$$timeoutId];\n\t }\n\t\n\t if (!skipApply) $rootScope.$apply();\n\t }, delay);\n\t\n\t promise.$$timeoutId = timeoutId;\n\t deferreds[timeoutId] = deferred;\n\t\n\t return promise;\n\t }\n\t\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $timeout#cancel\n\t *\n\t * @description\n\t * Cancels a task associated with the `promise`. As a result of this, the promise will be\n\t * resolved with a rejection.\n\t *\n\t * @param {Promise=} promise Promise returned by the `$timeout` function.\n\t * @returns {boolean} Returns `true` if the task hasn't executed yet and was successfully\n\t * canceled.\n\t */\n\t timeout.cancel = function(promise) {\n\t if (promise && promise.$$timeoutId in deferreds) {\n\t deferreds[promise.$$timeoutId].reject('canceled');\n\t delete deferreds[promise.$$timeoutId];\n\t return $browser.defer.cancel(promise.$$timeoutId);\n\t }\n\t return false;\n\t };\n\t\n\t return timeout;\n\t }];\n\t}\n\t\n\t// NOTE: The usage of window and document instead of $window and $document here is\n\t// deliberate. This service depends on the specific behavior of anchor nodes created by the\n\t// browser (resolving and parsing URLs) that is unlikely to be provided by mock objects and\n\t// cause us to break tests. In addition, when the browser resolves a URL for XHR, it\n\t// doesn't know about mocked locations and resolves URLs to the real document - which is\n\t// exactly the behavior needed here. There is little value is mocking these out for this\n\t// service.\n\tvar urlParsingNode = document.createElement(\"a\");\n\tvar originUrl = urlResolve(window.location.href);\n\t\n\t\n\t/**\n\t *\n\t * Implementation Notes for non-IE browsers\n\t * ----------------------------------------\n\t * Assigning a URL to the href property of an anchor DOM node, even one attached to the DOM,\n\t * results both in the normalizing and parsing of the URL. Normalizing means that a relative\n\t * URL will be resolved into an absolute URL in the context of the application document.\n\t * Parsing means that the anchor node's host, hostname, protocol, port, pathname and related\n\t * properties are all populated to reflect the normalized URL. This approach has wide\n\t * compatibility - Safari 1+, Mozilla 1+, Opera 7+,e etc. See\n\t * http://www.aptana.com/reference/html/api/HTMLAnchorElement.html\n\t *\n\t * Implementation Notes for IE\n\t * ---------------------------\n\t * IE <= 10 normalizes the URL when assigned to the anchor node similar to the other\n\t * browsers. However, the parsed components will not be set if the URL assigned did not specify\n\t * them. (e.g. if you assign a.href = \"foo\", then a.protocol, a.host, etc. will be empty.) We\n\t * work around that by performing the parsing in a 2nd step by taking a previously normalized\n\t * URL (e.g. by assigning to a.href) and assigning it a.href again. This correctly populates the\n\t * properties such as protocol, hostname, port, etc.\n\t *\n\t * References:\n\t * http://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement\n\t * http://www.aptana.com/reference/html/api/HTMLAnchorElement.html\n\t * http://url.spec.whatwg.org/#urlutils\n\t * https://github.com/angular/angular.js/pull/2902\n\t * http://james.padolsey.com/javascript/parsing-urls-with-the-dom/\n\t *\n\t * @kind function\n\t * @param {string} url The URL to be parsed.\n\t * @description Normalizes and parses a URL.\n\t * @returns {object} Returns the normalized URL as a dictionary.\n\t *\n\t * | member name | Description |\n\t * |---------------|----------------|\n\t * | href | A normalized version of the provided URL if it was not an absolute URL |\n\t * | protocol | The protocol including the trailing colon |\n\t * | host | The host and port (if the port is non-default) of the normalizedUrl |\n\t * | search | The search params, minus the question mark |\n\t * | hash | The hash string, minus the hash symbol\n\t * | hostname | The hostname\n\t * | port | The port, without \":\"\n\t * | pathname | The pathname, beginning with \"/\"\n\t *\n\t */\n\tfunction urlResolve(url) {\n\t var href = url;\n\t\n\t if (msie) {\n\t // Normalize before parse. Refer Implementation Notes on why this is\n\t // done in two steps on IE.\n\t urlParsingNode.setAttribute(\"href\", href);\n\t href = urlParsingNode.href;\n\t }\n\t\n\t urlParsingNode.setAttribute('href', href);\n\t\n\t // urlParsingNode provides the UrlUtils interface - http://url.spec.whatwg.org/#urlutils\n\t return {\n\t href: urlParsingNode.href,\n\t protocol: urlParsingNode.protocol ? urlParsingNode.protocol.replace(/:$/, '') : '',\n\t host: urlParsingNode.host,\n\t search: urlParsingNode.search ? urlParsingNode.search.replace(/^\\?/, '') : '',\n\t hash: urlParsingNode.hash ? urlParsingNode.hash.replace(/^#/, '') : '',\n\t hostname: urlParsingNode.hostname,\n\t port: urlParsingNode.port,\n\t pathname: (urlParsingNode.pathname.charAt(0) === '/')\n\t ? urlParsingNode.pathname\n\t : '/' + urlParsingNode.pathname\n\t };\n\t}\n\t\n\t/**\n\t * Parse a request URL and determine whether this is a same-origin request as the application document.\n\t *\n\t * @param {string|object} requestUrl The url of the request as a string that will be resolved\n\t * or a parsed URL object.\n\t * @returns {boolean} Whether the request is for the same origin as the application document.\n\t */\n\tfunction urlIsSameOrigin(requestUrl) {\n\t var parsed = (isString(requestUrl)) ? urlResolve(requestUrl) : requestUrl;\n\t return (parsed.protocol === originUrl.protocol &&\n\t parsed.host === originUrl.host);\n\t}\n\t\n\t/**\n\t * @ngdoc service\n\t * @name $window\n\t *\n\t * @description\n\t * A reference to the browser's `window` object. While `window`\n\t * is globally available in JavaScript, it causes testability problems, because\n\t * it is a global variable. In angular we always refer to it through the\n\t * `$window` service, so it may be overridden, removed or mocked for testing.\n\t *\n\t * Expressions, like the one defined for the `ngClick` directive in the example\n\t * below, are evaluated with respect to the current scope. Therefore, there is\n\t * no risk of inadvertently coding in a dependency on a global value in such an\n\t * expression.\n\t *\n\t * @example\n\t \n\t \n\t \n\t
\n\t \n\t \n\t
\n\t
\n\t \n\t it('should display the greeting in the input box', function() {\n\t element(by.model('greeting')).sendKeys('Hello, E2E Tests');\n\t // If we click the button it will block the test runner\n\t // element(':button').click();\n\t });\n\t \n\t
\n\t */\n\tfunction $WindowProvider() {\n\t this.$get = valueFn(window);\n\t}\n\t\n\t/**\n\t * @name $$cookieReader\n\t * @requires $document\n\t *\n\t * @description\n\t * This is a private service for reading cookies used by $http and ngCookies\n\t *\n\t * @return {Object} a key/value map of the current cookies\n\t */\n\tfunction $$CookieReader($document) {\n\t var rawDocument = $document[0] || {};\n\t var lastCookies = {};\n\t var lastCookieString = '';\n\t\n\t function safeDecodeURIComponent(str) {\n\t try {\n\t return decodeURIComponent(str);\n\t } catch (e) {\n\t return str;\n\t }\n\t }\n\t\n\t return function() {\n\t var cookieArray, cookie, i, index, name;\n\t var currentCookieString = rawDocument.cookie || '';\n\t\n\t if (currentCookieString !== lastCookieString) {\n\t lastCookieString = currentCookieString;\n\t cookieArray = lastCookieString.split('; ');\n\t lastCookies = {};\n\t\n\t for (i = 0; i < cookieArray.length; i++) {\n\t cookie = cookieArray[i];\n\t index = cookie.indexOf('=');\n\t if (index > 0) { //ignore nameless cookies\n\t name = safeDecodeURIComponent(cookie.substring(0, index));\n\t // the first value that is seen for a cookie is the most\n\t // specific one. values for the same cookie name that\n\t // follow are for less specific paths.\n\t if (isUndefined(lastCookies[name])) {\n\t lastCookies[name] = safeDecodeURIComponent(cookie.substring(index + 1));\n\t }\n\t }\n\t }\n\t }\n\t return lastCookies;\n\t };\n\t}\n\t\n\t$$CookieReader.$inject = ['$document'];\n\t\n\tfunction $$CookieReaderProvider() {\n\t this.$get = $$CookieReader;\n\t}\n\t\n\t/* global currencyFilter: true,\n\t dateFilter: true,\n\t filterFilter: true,\n\t jsonFilter: true,\n\t limitToFilter: true,\n\t lowercaseFilter: true,\n\t numberFilter: true,\n\t orderByFilter: true,\n\t uppercaseFilter: true,\n\t */\n\t\n\t/**\n\t * @ngdoc provider\n\t * @name $filterProvider\n\t * @description\n\t *\n\t * Filters are just functions which transform input to an output. However filters need to be\n\t * Dependency Injected. To achieve this a filter definition consists of a factory function which is\n\t * annotated with dependencies and is responsible for creating a filter function.\n\t *\n\t *
\n\t * **Note:** Filter names must be valid angular {@link expression} identifiers, such as `uppercase` or `orderBy`.\n\t * Names with special characters, such as hyphens and dots, are not allowed. If you wish to namespace\n\t * your filters, then you can use capitalization (`myappSubsectionFilterx`) or underscores\n\t * (`myapp_subsection_filterx`).\n\t *
\n\t *\n\t * ```js\n\t * // Filter registration\n\t * function MyModule($provide, $filterProvider) {\n\t * // create a service to demonstrate injection (not always needed)\n\t * $provide.value('greet', function(name){\n\t * return 'Hello ' + name + '!';\n\t * });\n\t *\n\t * // register a filter factory which uses the\n\t * // greet service to demonstrate DI.\n\t * $filterProvider.register('greet', function(greet){\n\t * // return the filter function which uses the greet service\n\t * // to generate salutation\n\t * return function(text) {\n\t * // filters need to be forgiving so check input validity\n\t * return text && greet(text) || text;\n\t * };\n\t * });\n\t * }\n\t * ```\n\t *\n\t * The filter function is registered with the `$injector` under the filter name suffix with\n\t * `Filter`.\n\t *\n\t * ```js\n\t * it('should be the same instance', inject(\n\t * function($filterProvider) {\n\t * $filterProvider.register('reverse', function(){\n\t * return ...;\n\t * });\n\t * },\n\t * function($filter, reverseFilter) {\n\t * expect($filter('reverse')).toBe(reverseFilter);\n\t * });\n\t * ```\n\t *\n\t *\n\t * For more information about how angular filters work, and how to create your own filters, see\n\t * {@link guide/filter Filters} in the Angular Developer Guide.\n\t */\n\t\n\t/**\n\t * @ngdoc service\n\t * @name $filter\n\t * @kind function\n\t * @description\n\t * Filters are used for formatting data displayed to the user.\n\t *\n\t * The general syntax in templates is as follows:\n\t *\n\t * {{ expression [| filter_name[:parameter_value] ... ] }}\n\t *\n\t * @param {String} name Name of the filter function to retrieve\n\t * @return {Function} the filter function\n\t * @example\n\t \n\t \n\t
\n\t

{{ originalText }}

\n\t

{{ filteredText }}

\n\t
\n\t
\n\t\n\t \n\t angular.module('filterExample', [])\n\t .controller('MainCtrl', function($scope, $filter) {\n\t $scope.originalText = 'hello';\n\t $scope.filteredText = $filter('uppercase')($scope.originalText);\n\t });\n\t \n\t
\n\t */\n\t$FilterProvider.$inject = ['$provide'];\n\tfunction $FilterProvider($provide) {\n\t var suffix = 'Filter';\n\t\n\t /**\n\t * @ngdoc method\n\t * @name $filterProvider#register\n\t * @param {string|Object} name Name of the filter function, or an object map of filters where\n\t * the keys are the filter names and the values are the filter factories.\n\t *\n\t *
\n\t * **Note:** Filter names must be valid angular {@link expression} identifiers, such as `uppercase` or `orderBy`.\n\t * Names with special characters, such as hyphens and dots, are not allowed. If you wish to namespace\n\t * your filters, then you can use capitalization (`myappSubsectionFilterx`) or underscores\n\t * (`myapp_subsection_filterx`).\n\t *
\n\t * @param {Function} factory If the first argument was a string, a factory function for the filter to be registered.\n\t * @returns {Object} Registered filter instance, or if a map of filters was provided then a map\n\t * of the registered filter instances.\n\t */\n\t function register(name, factory) {\n\t if (isObject(name)) {\n\t var filters = {};\n\t forEach(name, function(filter, key) {\n\t filters[key] = register(key, filter);\n\t });\n\t return filters;\n\t } else {\n\t return $provide.factory(name + suffix, factory);\n\t }\n\t }\n\t this.register = register;\n\t\n\t this.$get = ['$injector', function($injector) {\n\t return function(name) {\n\t return $injector.get(name + suffix);\n\t };\n\t }];\n\t\n\t ////////////////////////////////////////\n\t\n\t /* global\n\t currencyFilter: false,\n\t dateFilter: false,\n\t filterFilter: false,\n\t jsonFilter: false,\n\t limitToFilter: false,\n\t lowercaseFilter: false,\n\t numberFilter: false,\n\t orderByFilter: false,\n\t uppercaseFilter: false,\n\t */\n\t\n\t register('currency', currencyFilter);\n\t register('date', dateFilter);\n\t register('filter', filterFilter);\n\t register('json', jsonFilter);\n\t register('limitTo', limitToFilter);\n\t register('lowercase', lowercaseFilter);\n\t register('number', numberFilter);\n\t register('orderBy', orderByFilter);\n\t register('uppercase', uppercaseFilter);\n\t}\n\t\n\t/**\n\t * @ngdoc filter\n\t * @name filter\n\t * @kind function\n\t *\n\t * @description\n\t * Selects a subset of items from `array` and returns it as a new array.\n\t *\n\t * @param {Array} array The source array.\n\t * @param {string|Object|function()} expression The predicate to be used for selecting items from\n\t * `array`.\n\t *\n\t * Can be one of:\n\t *\n\t * - `string`: The string is used for matching against the contents of the `array`. All strings or\n\t * objects with string properties in `array` that match this string will be returned. This also\n\t * applies to nested object properties.\n\t * The predicate can be negated by prefixing the string with `!`.\n\t *\n\t * - `Object`: A pattern object can be used to filter specific properties on objects contained\n\t * by `array`. For example `{name:\"M\", phone:\"1\"}` predicate will return an array of items\n\t * which have property `name` containing \"M\" and property `phone` containing \"1\". A special\n\t * property name `$` can be used (as in `{$:\"text\"}`) to accept a match against any\n\t * property of the object or its nested object properties. That's equivalent to the simple\n\t * substring match with a `string` as described above. The predicate can be negated by prefixing\n\t * the string with `!`.\n\t * For example `{name: \"!M\"}` predicate will return an array of items which have property `name`\n\t * not containing \"M\".\n\t *\n\t * Note that a named property will match properties on the same level only, while the special\n\t * `$` property will match properties on the same level or deeper. E.g. an array item like\n\t * `{name: {first: 'John', last: 'Doe'}}` will **not** be matched by `{name: 'John'}`, but\n\t * **will** be matched by `{$: 'John'}`.\n\t *\n\t * - `function(value, index, array)`: A predicate function can be used to write arbitrary filters.\n\t * The function is called for each element of the array, with the element, its index, and\n\t * the entire array itself as arguments.\n\t *\n\t * The final result is an array of those elements that the predicate returned true for.\n\t *\n\t * @param {function(actual, expected)|true|undefined} comparator Comparator which is used in\n\t * determining if the expected value (from the filter expression) and actual value (from\n\t * the object in the array) should be considered a match.\n\t *\n\t * Can be one of:\n\t *\n\t * - `function(actual, expected)`:\n\t * The function will be given the object value and the predicate value to compare and\n\t * should return true if both values should be considered equal.\n\t *\n\t * - `true`: A shorthand for `function(actual, expected) { return angular.equals(actual, expected)}`.\n\t * This is essentially strict comparison of expected and actual.\n\t *\n\t * - `false|undefined`: A short hand for a function which will look for a substring match in case\n\t * insensitive way.\n\t *\n\t * Primitive values are converted to strings. Objects are not compared against primitives,\n\t * unless they have a custom `toString` method (e.g. `Date` objects).\n\t *\n\t * @example\n\t \n\t \n\t
\n\t\n\t \n\t \n\t \n\t \n\t \n\t \n\t \n\t
NamePhone
{{friend.name}}{{friend.phone}}
\n\t
\n\t
\n\t
\n\t
\n\t
\n\t \n\t \n\t \n\t \n\t \n\t \n\t
NamePhone
{{friendObj.name}}{{friendObj.phone}}
\n\t
\n\t \n\t var expectFriendNames = function(expectedNames, key) {\n\t element.all(by.repeater(key + ' in friends').column(key + '.name')).then(function(arr) {\n\t arr.forEach(function(wd, i) {\n\t expect(wd.getText()).toMatch(expectedNames[i]);\n\t });\n\t });\n\t };\n\t\n\t it('should search across all fields when filtering with a string', function() {\n\t var searchText = element(by.model('searchText'));\n\t searchText.clear();\n\t searchText.sendKeys('m');\n\t expectFriendNames(['Mary', 'Mike', 'Adam'], 'friend');\n\t\n\t searchText.clear();\n\t searchText.sendKeys('76');\n\t expectFriendNames(['John', 'Julie'], 'friend');\n\t });\n\t\n\t it('should search in specific fields when filtering with a predicate object', function() {\n\t var searchAny = element(by.model('search.$'));\n\t searchAny.clear();\n\t searchAny.sendKeys('i');\n\t expectFriendNames(['Mary', 'Mike', 'Julie', 'Juliette'], 'friendObj');\n\t });\n\t it('should use a equal comparison when comparator is true', function() {\n\t var searchName = element(by.model('search.name'));\n\t var strict = element(by.model('strict'));\n\t searchName.clear();\n\t searchName.sendKeys('Julie');\n\t strict.click();\n\t expectFriendNames(['Julie'], 'friendObj');\n\t });\n\t \n\t
\n\t */\n\tfunction filterFilter() {\n\t return function(array, expression, comparator) {\n\t if (!isArrayLike(array)) {\n\t if (array == null) {\n\t return array;\n\t } else {\n\t throw minErr('filter')('notarray', 'Expected array but received: {0}', array);\n\t }\n\t }\n\t\n\t var expressionType = getTypeForFilter(expression);\n\t var predicateFn;\n\t var matchAgainstAnyProp;\n\t\n\t switch (expressionType) {\n\t case 'function':\n\t predicateFn = expression;\n\t break;\n\t case 'boolean':\n\t case 'null':\n\t case 'number':\n\t case 'string':\n\t matchAgainstAnyProp = true;\n\t //jshint -W086\n\t case 'object':\n\t //jshint +W086\n\t predicateFn = createPredicateFn(expression, comparator, matchAgainstAnyProp);\n\t break;\n\t default:\n\t return array;\n\t }\n\t\n\t return Array.prototype.filter.call(array, predicateFn);\n\t };\n\t}\n\t\n\t// Helper functions for `filterFilter`\n\tfunction createPredicateFn(expression, comparator, matchAgainstAnyProp) {\n\t var shouldMatchPrimitives = isObject(expression) && ('$' in expression);\n\t var predicateFn;\n\t\n\t if (comparator === true) {\n\t comparator = equals;\n\t } else if (!isFunction(comparator)) {\n\t comparator = function(actual, expected) {\n\t if (isUndefined(actual)) {\n\t // No substring matching against `undefined`\n\t return false;\n\t }\n\t if ((actual === null) || (expected === null)) {\n\t // No substring matching against `null`; only match against `null`\n\t return actual === expected;\n\t }\n\t if (isObject(expected) || (isObject(actual) && !hasCustomToString(actual))) {\n\t // Should not compare primitives against objects, unless they have custom `toString` method\n\t return false;\n\t }\n\t\n\t actual = lowercase('' + actual);\n\t expected = lowercase('' + expected);\n\t return actual.indexOf(expected) !== -1;\n\t };\n\t }\n\t\n\t predicateFn = function(item) {\n\t if (shouldMatchPrimitives && !isObject(item)) {\n\t return deepCompare(item, expression.$, comparator, false);\n\t }\n\t return deepCompare(item, expression, comparator, matchAgainstAnyProp);\n\t };\n\t\n\t return predicateFn;\n\t}\n\t\n\tfunction deepCompare(actual, expected, comparator, matchAgainstAnyProp, dontMatchWholeObject) {\n\t var actualType = getTypeForFilter(actual);\n\t var expectedType = getTypeForFilter(expected);\n\t\n\t if ((expectedType === 'string') && (expected.charAt(0) === '!')) {\n\t return !deepCompare(actual, expected.substring(1), comparator, matchAgainstAnyProp);\n\t } else if (isArray(actual)) {\n\t // In case `actual` is an array, consider it a match\n\t // if ANY of it's items matches `expected`\n\t return actual.some(function(item) {\n\t return deepCompare(item, expected, comparator, matchAgainstAnyProp);\n\t });\n\t }\n\t\n\t switch (actualType) {\n\t case 'object':\n\t var key;\n\t if (matchAgainstAnyProp) {\n\t for (key in actual) {\n\t if ((key.charAt(0) !== '$') && deepCompare(actual[key], expected, comparator, true)) {\n\t return true;\n\t }\n\t }\n\t return dontMatchWholeObject ? false : deepCompare(actual, expected, comparator, false);\n\t } else if (expectedType === 'object') {\n\t for (key in expected) {\n\t var expectedVal = expected[key];\n\t if (isFunction(expectedVal) || isUndefined(expectedVal)) {\n\t continue;\n\t }\n\t\n\t var matchAnyProperty = key === '$';\n\t var actualVal = matchAnyProperty ? actual : actual[key];\n\t if (!deepCompare(actualVal, expectedVal, comparator, matchAnyProperty, matchAnyProperty)) {\n\t return false;\n\t }\n\t }\n\t return true;\n\t } else {\n\t return comparator(actual, expected);\n\t }\n\t break;\n\t case 'function':\n\t return false;\n\t default:\n\t return comparator(actual, expected);\n\t }\n\t}\n\t\n\t// Used for easily differentiating between `null` and actual `object`\n\tfunction getTypeForFilter(val) {\n\t return (val === null) ? 'null' : typeof val;\n\t}\n\t\n\tvar MAX_DIGITS = 22;\n\tvar DECIMAL_SEP = '.';\n\tvar ZERO_CHAR = '0';\n\t\n\t/**\n\t * @ngdoc filter\n\t * @name currency\n\t * @kind function\n\t *\n\t * @description\n\t * Formats a number as a currency (ie $1,234.56). When no currency symbol is provided, default\n\t * symbol for current locale is used.\n\t *\n\t * @param {number} amount Input to filter.\n\t * @param {string=} symbol Currency symbol or identifier to be displayed.\n\t * @param {number=} fractionSize Number of decimal places to round the amount to, defaults to default max fraction size for current locale\n\t * @returns {string} Formatted number.\n\t *\n\t *\n\t * @example\n\t \n\t \n\t \n\t
\n\t
\n\t default currency symbol ($): {{amount | currency}}
\n\t custom currency identifier (USD$): {{amount | currency:\"USD$\"}}\n\t no fractions (0): {{amount | currency:\"USD$\":0}}\n\t
\n\t
\n\t \n\t it('should init with 1234.56', function() {\n\t expect(element(by.id('currency-default')).getText()).toBe('$1,234.56');\n\t expect(element(by.id('currency-custom')).getText()).toBe('USD$1,234.56');\n\t expect(element(by.id('currency-no-fractions')).getText()).toBe('USD$1,235');\n\t });\n\t it('should update', function() {\n\t if (browser.params.browser == 'safari') {\n\t // Safari does not understand the minus key. See\n\t // https://github.com/angular/protractor/issues/481\n\t return;\n\t }\n\t element(by.model('amount')).clear();\n\t element(by.model('amount')).sendKeys('-1234');\n\t expect(element(by.id('currency-default')).getText()).toBe('-$1,234.00');\n\t expect(element(by.id('currency-custom')).getText()).toBe('-USD$1,234.00');\n\t expect(element(by.id('currency-no-fractions')).getText()).toBe('-USD$1,234');\n\t });\n\t \n\t
\n\t */\n\tcurrencyFilter.$inject = ['$locale'];\n\tfunction currencyFilter($locale) {\n\t var formats = $locale.NUMBER_FORMATS;\n\t return function(amount, currencySymbol, fractionSize) {\n\t if (isUndefined(currencySymbol)) {\n\t currencySymbol = formats.CURRENCY_SYM;\n\t }\n\t\n\t if (isUndefined(fractionSize)) {\n\t fractionSize = formats.PATTERNS[1].maxFrac;\n\t }\n\t\n\t // if null or undefined pass it through\n\t return (amount == null)\n\t ? amount\n\t : formatNumber(amount, formats.PATTERNS[1], formats.GROUP_SEP, formats.DECIMAL_SEP, fractionSize).\n\t replace(/\\u00A4/g, currencySymbol);\n\t };\n\t}\n\t\n\t/**\n\t * @ngdoc filter\n\t * @name number\n\t * @kind function\n\t *\n\t * @description\n\t * Formats a number as text.\n\t *\n\t * If the input is null or undefined, it will just be returned.\n\t * If the input is infinite (Infinity or -Infinity), the Infinity symbol '∞' or '-∞' is returned, respectively.\n\t * If the input is not a number an empty string is returned.\n\t *\n\t *\n\t * @param {number|string} number Number to format.\n\t * @param {(number|string)=} fractionSize Number of decimal places to round the number to.\n\t * If this is not provided then the fraction size is computed from the current locale's number\n\t * formatting pattern. In the case of the default locale, it will be 3.\n\t * @returns {string} Number rounded to `fractionSize` appropriately formatted based on the current\n\t * locale (e.g., in the en_US locale it will have \".\" as the decimal separator and\n\t * include \",\" group separators after each third digit).\n\t *\n\t * @example\n\t \n\t \n\t \n\t
\n\t
\n\t Default formatting: {{val | number}}
\n\t No fractions: {{val | number:0}}
\n\t Negative number: {{-val | number:4}}\n\t
\n\t
\n\t \n\t it('should format numbers', function() {\n\t expect(element(by.id('number-default')).getText()).toBe('1,234.568');\n\t expect(element(by.binding('val | number:0')).getText()).toBe('1,235');\n\t expect(element(by.binding('-val | number:4')).getText()).toBe('-1,234.5679');\n\t });\n\t\n\t it('should update', function() {\n\t element(by.model('val')).clear();\n\t element(by.model('val')).sendKeys('3374.333');\n\t expect(element(by.id('number-default')).getText()).toBe('3,374.333');\n\t expect(element(by.binding('val | number:0')).getText()).toBe('3,374');\n\t expect(element(by.binding('-val | number:4')).getText()).toBe('-3,374.3330');\n\t });\n\t \n\t
\n\t */\n\tnumberFilter.$inject = ['$locale'];\n\tfunction numberFilter($locale) {\n\t var formats = $locale.NUMBER_FORMATS;\n\t return function(number, fractionSize) {\n\t\n\t // if null or undefined pass it through\n\t return (number == null)\n\t ? number\n\t : formatNumber(number, formats.PATTERNS[0], formats.GROUP_SEP, formats.DECIMAL_SEP,\n\t fractionSize);\n\t };\n\t}\n\t\n\t/**\n\t * Parse a number (as a string) into three components that can be used\n\t * for formatting the number.\n\t *\n\t * (Significant bits of this parse algorithm came from https://github.com/MikeMcl/big.js/)\n\t *\n\t * @param {string} numStr The number to parse\n\t * @return {object} An object describing this number, containing the following keys:\n\t * - d : an array of digits containing leading zeros as necessary\n\t * - i : the number of the digits in `d` that are to the left of the decimal point\n\t * - e : the exponent for numbers that would need more than `MAX_DIGITS` digits in `d`\n\t *\n\t */\n\tfunction parse(numStr) {\n\t var exponent = 0, digits, numberOfIntegerDigits;\n\t var i, j, zeros;\n\t\n\t // Decimal point?\n\t if ((numberOfIntegerDigits = numStr.indexOf(DECIMAL_SEP)) > -1) {\n\t numStr = numStr.replace(DECIMAL_SEP, '');\n\t }\n\t\n\t // Exponential form?\n\t if ((i = numStr.search(/e/i)) > 0) {\n\t // Work out the exponent.\n\t if (numberOfIntegerDigits < 0) numberOfIntegerDigits = i;\n\t numberOfIntegerDigits += +numStr.slice(i + 1);\n\t numStr = numStr.substring(0, i);\n\t } else if (numberOfIntegerDigits < 0) {\n\t // There was no decimal point or exponent so it is an integer.\n\t numberOfIntegerDigits = numStr.length;\n\t }\n\t\n\t // Count the number of leading zeros.\n\t for (i = 0; numStr.charAt(i) == ZERO_CHAR; i++) {/* jshint noempty: false */}\n\t\n\t if (i == (zeros = numStr.length)) {\n\t // The digits are all zero.\n\t digits = [0];\n\t numberOfIntegerDigits = 1;\n\t } else {\n\t // Count the number of trailing zeros\n\t zeros--;\n\t while (numStr.charAt(zeros) == ZERO_CHAR) zeros--;\n\t\n\t // Trailing zeros are insignificant so ignore them\n\t numberOfIntegerDigits -= i;\n\t digits = [];\n\t // Convert string to array of digits without leading/trailing zeros.\n\t for (j = 0; i <= zeros; i++, j++) {\n\t digits[j] = +numStr.charAt(i);\n\t }\n\t }\n\t\n\t // If the number overflows the maximum allowed digits then use an exponent.\n\t if (numberOfIntegerDigits > MAX_DIGITS) {\n\t digits = digits.splice(0, MAX_DIGITS - 1);\n\t exponent = numberOfIntegerDigits - 1;\n\t numberOfIntegerDigits = 1;\n\t }\n\t\n\t return { d: digits, e: exponent, i: numberOfIntegerDigits };\n\t}\n\t\n\t/**\n\t * Round the parsed number to the specified number of decimal places\n\t * This function changed the parsedNumber in-place\n\t */\n\tfunction roundNumber(parsedNumber, fractionSize, minFrac, maxFrac) {\n\t var digits = parsedNumber.d;\n\t var fractionLen = digits.length - parsedNumber.i;\n\t\n\t // determine fractionSize if it is not specified; `+fractionSize` converts it to a number\n\t fractionSize = (isUndefined(fractionSize)) ? Math.min(Math.max(minFrac, fractionLen), maxFrac) : +fractionSize;\n\t\n\t // The index of the digit to where rounding is to occur\n\t var roundAt = fractionSize + parsedNumber.i;\n\t var digit = digits[roundAt];\n\t\n\t if (roundAt > 0) {\n\t digits.splice(roundAt);\n\t } else {\n\t // We rounded to zero so reset the parsedNumber\n\t parsedNumber.i = 1;\n\t digits.length = roundAt = fractionSize + 1;\n\t for (var i=0; i < roundAt; i++) digits[i] = 0;\n\t }\n\t\n\t if (digit >= 5) digits[roundAt - 1]++;\n\t\n\t // Pad out with zeros to get the required fraction length\n\t for (; fractionLen < fractionSize; fractionLen++) digits.push(0);\n\t\n\t\n\t // Do any carrying, e.g. a digit was rounded up to 10\n\t var carry = digits.reduceRight(function(carry, d, i, digits) {\n\t d = d + carry;\n\t digits[i] = d % 10;\n\t return Math.floor(d / 10);\n\t }, 0);\n\t if (carry) {\n\t digits.unshift(carry);\n\t parsedNumber.i++;\n\t }\n\t}\n\t\n\t/**\n\t * Format a number into a string\n\t * @param {number} number The number to format\n\t * @param {{\n\t * minFrac, // the minimum number of digits required in the fraction part of the number\n\t * maxFrac, // the maximum number of digits required in the fraction part of the number\n\t * gSize, // number of digits in each group of separated digits\n\t * lgSize, // number of digits in the last group of digits before the decimal separator\n\t * negPre, // the string to go in front of a negative number (e.g. `-` or `(`))\n\t * posPre, // the string to go in front of a positive number\n\t * negSuf, // the string to go after a negative number (e.g. `)`)\n\t * posSuf // the string to go after a positive number\n\t * }} pattern\n\t * @param {string} groupSep The string to separate groups of number (e.g. `,`)\n\t * @param {string} decimalSep The string to act as the decimal separator (e.g. `.`)\n\t * @param {[type]} fractionSize The size of the fractional part of the number\n\t * @return {string} The number formatted as a string\n\t */\n\tfunction formatNumber(number, pattern, groupSep, decimalSep, fractionSize) {\n\t\n\t if (!(isString(number) || isNumber(number)) || isNaN(number)) return '';\n\t\n\t var isInfinity = !isFinite(number);\n\t var isZero = false;\n\t var numStr = Math.abs(number) + '',\n\t formattedText = '',\n\t parsedNumber;\n\t\n\t if (isInfinity) {\n\t formattedText = '\\u221e';\n\t } else {\n\t parsedNumber = parse(numStr);\n\t\n\t roundNumber(parsedNumber, fractionSize, pattern.minFrac, pattern.maxFrac);\n\t\n\t var digits = parsedNumber.d;\n\t var integerLen = parsedNumber.i;\n\t var exponent = parsedNumber.e;\n\t var decimals = [];\n\t isZero = digits.reduce(function(isZero, d) { return isZero && !d; }, true);\n\t\n\t // pad zeros for small numbers\n\t while (integerLen < 0) {\n\t digits.unshift(0);\n\t integerLen++;\n\t }\n\t\n\t // extract decimals digits\n\t if (integerLen > 0) {\n\t decimals = digits.splice(integerLen, digits.length);\n\t } else {\n\t decimals = digits;\n\t digits = [0];\n\t }\n\t\n\t // format the integer digits with grouping separators\n\t var groups = [];\n\t if (digits.length >= pattern.lgSize) {\n\t groups.unshift(digits.splice(-pattern.lgSize, digits.length).join(''));\n\t }\n\t while (digits.length > pattern.gSize) {\n\t groups.unshift(digits.splice(-pattern.gSize, digits.length).join(''));\n\t }\n\t if (digits.length) {\n\t groups.unshift(digits.join(''));\n\t }\n\t formattedText = groups.join(groupSep);\n\t\n\t // append the decimal digits\n\t if (decimals.length) {\n\t formattedText += decimalSep + decimals.join('');\n\t }\n\t\n\t if (exponent) {\n\t formattedText += 'e+' + exponent;\n\t }\n\t }\n\t if (number < 0 && !isZero) {\n\t return pattern.negPre + formattedText + pattern.negSuf;\n\t } else {\n\t return pattern.posPre + formattedText + pattern.posSuf;\n\t }\n\t}\n\t\n\tfunction padNumber(num, digits, trim) {\n\t var neg = '';\n\t if (num < 0) {\n\t neg = '-';\n\t num = -num;\n\t }\n\t num = '' + num;\n\t while (num.length < digits) num = ZERO_CHAR + num;\n\t if (trim) {\n\t num = num.substr(num.length - digits);\n\t }\n\t return neg + num;\n\t}\n\t\n\t\n\tfunction dateGetter(name, size, offset, trim) {\n\t offset = offset || 0;\n\t return function(date) {\n\t var value = date['get' + name]();\n\t if (offset > 0 || value > -offset) {\n\t value += offset;\n\t }\n\t if (value === 0 && offset == -12) value = 12;\n\t return padNumber(value, size, trim);\n\t };\n\t}\n\t\n\tfunction dateStrGetter(name, shortForm) {\n\t return function(date, formats) {\n\t var value = date['get' + name]();\n\t var get = uppercase(shortForm ? ('SHORT' + name) : name);\n\t\n\t return formats[get][value];\n\t };\n\t}\n\t\n\tfunction timeZoneGetter(date, formats, offset) {\n\t var zone = -1 * offset;\n\t var paddedZone = (zone >= 0) ? \"+\" : \"\";\n\t\n\t paddedZone += padNumber(Math[zone > 0 ? 'floor' : 'ceil'](zone / 60), 2) +\n\t padNumber(Math.abs(zone % 60), 2);\n\t\n\t return paddedZone;\n\t}\n\t\n\tfunction getFirstThursdayOfYear(year) {\n\t // 0 = index of January\n\t var dayOfWeekOnFirst = (new Date(year, 0, 1)).getDay();\n\t // 4 = index of Thursday (+1 to account for 1st = 5)\n\t // 11 = index of *next* Thursday (+1 account for 1st = 12)\n\t return new Date(year, 0, ((dayOfWeekOnFirst <= 4) ? 5 : 12) - dayOfWeekOnFirst);\n\t}\n\t\n\tfunction getThursdayThisWeek(datetime) {\n\t return new Date(datetime.getFullYear(), datetime.getMonth(),\n\t // 4 = index of Thursday\n\t datetime.getDate() + (4 - datetime.getDay()));\n\t}\n\t\n\tfunction weekGetter(size) {\n\t return function(date) {\n\t var firstThurs = getFirstThursdayOfYear(date.getFullYear()),\n\t thisThurs = getThursdayThisWeek(date);\n\t\n\t var diff = +thisThurs - +firstThurs,\n\t result = 1 + Math.round(diff / 6.048e8); // 6.048e8 ms per week\n\t\n\t return padNumber(result, size);\n\t };\n\t}\n\t\n\tfunction ampmGetter(date, formats) {\n\t return date.getHours() < 12 ? formats.AMPMS[0] : formats.AMPMS[1];\n\t}\n\t\n\tfunction eraGetter(date, formats) {\n\t return date.getFullYear() <= 0 ? formats.ERAS[0] : formats.ERAS[1];\n\t}\n\t\n\tfunction longEraGetter(date, formats) {\n\t return date.getFullYear() <= 0 ? formats.ERANAMES[0] : formats.ERANAMES[1];\n\t}\n\t\n\tvar DATE_FORMATS = {\n\t yyyy: dateGetter('FullYear', 4),\n\t yy: dateGetter('FullYear', 2, 0, true),\n\t y: dateGetter('FullYear', 1),\n\t MMMM: dateStrGetter('Month'),\n\t MMM: dateStrGetter('Month', true),\n\t MM: dateGetter('Month', 2, 1),\n\t M: dateGetter('Month', 1, 1),\n\t dd: dateGetter('Date', 2),\n\t d: dateGetter('Date', 1),\n\t HH: dateGetter('Hours', 2),\n\t H: dateGetter('Hours', 1),\n\t hh: dateGetter('Hours', 2, -12),\n\t h: dateGetter('Hours', 1, -12),\n\t mm: dateGetter('Minutes', 2),\n\t m: dateGetter('Minutes', 1),\n\t ss: dateGetter('Seconds', 2),\n\t s: dateGetter('Seconds', 1),\n\t // while ISO 8601 requires fractions to be prefixed with `.` or `,`\n\t // we can be just safely rely on using `sss` since we currently don't support single or two digit fractions\n\t sss: dateGetter('Milliseconds', 3),\n\t EEEE: dateStrGetter('Day'),\n\t EEE: dateStrGetter('Day', true),\n\t a: ampmGetter,\n\t Z: timeZoneGetter,\n\t ww: weekGetter(2),\n\t w: weekGetter(1),\n\t G: eraGetter,\n\t GG: eraGetter,\n\t GGG: eraGetter,\n\t GGGG: longEraGetter\n\t};\n\t\n\tvar DATE_FORMATS_SPLIT = /((?:[^yMdHhmsaZEwG']+)|(?:'(?:[^']|'')*')|(?:E+|y+|M+|d+|H+|h+|m+|s+|a|Z|G+|w+))(.*)/,\n\t NUMBER_STRING = /^\\-?\\d+$/;\n\t\n\t/**\n\t * @ngdoc filter\n\t * @name date\n\t * @kind function\n\t *\n\t * @description\n\t * Formats `date` to a string based on the requested `format`.\n\t *\n\t * `format` string can be composed of the following elements:\n\t *\n\t * * `'yyyy'`: 4 digit representation of year (e.g. AD 1 => 0001, AD 2010 => 2010)\n\t * * `'yy'`: 2 digit representation of year, padded (00-99). (e.g. AD 2001 => 01, AD 2010 => 10)\n\t * * `'y'`: 1 digit representation of year, e.g. (AD 1 => 1, AD 199 => 199)\n\t * * `'MMMM'`: Month in year (January-December)\n\t * * `'MMM'`: Month in year (Jan-Dec)\n\t * * `'MM'`: Month in year, padded (01-12)\n\t * * `'M'`: Month in year (1-12)\n\t * * `'dd'`: Day in month, padded (01-31)\n\t * * `'d'`: Day in month (1-31)\n\t * * `'EEEE'`: Day in Week,(Sunday-Saturday)\n\t * * `'EEE'`: Day in Week, (Sun-Sat)\n\t * * `'HH'`: Hour in day, padded (00-23)\n\t * * `'H'`: Hour in day (0-23)\n\t * * `'hh'`: Hour in AM/PM, padded (01-12)\n\t * * `'h'`: Hour in AM/PM, (1-12)\n\t * * `'mm'`: Minute in hour, padded (00-59)\n\t * * `'m'`: Minute in hour (0-59)\n\t * * `'ss'`: Second in minute, padded (00-59)\n\t * * `'s'`: Second in minute (0-59)\n\t * * `'sss'`: Millisecond in second, padded (000-999)\n\t * * `'a'`: AM/PM marker\n\t * * `'Z'`: 4 digit (+sign) representation of the timezone offset (-1200-+1200)\n\t * * `'ww'`: Week of year, padded (00-53). Week 01 is the week with the first Thursday of the year\n\t * * `'w'`: Week of year (0-53). Week 1 is the week with the first Thursday of the year\n\t * * `'G'`, `'GG'`, `'GGG'`: The abbreviated form of the era string (e.g. 'AD')\n\t * * `'GGGG'`: The long form of the era string (e.g. 'Anno Domini')\n\t *\n\t * `format` string can also be one of the following predefined\n\t * {@link guide/i18n localizable formats}:\n\t *\n\t * * `'medium'`: equivalent to `'MMM d, y h:mm:ss a'` for en_US locale\n\t * (e.g. Sep 3, 2010 12:05:08 PM)\n\t * * `'short'`: equivalent to `'M/d/yy h:mm a'` for en_US locale (e.g. 9/3/10 12:05 PM)\n\t * * `'fullDate'`: equivalent to `'EEEE, MMMM d, y'` for en_US locale\n\t * (e.g. Friday, September 3, 2010)\n\t * * `'longDate'`: equivalent to `'MMMM d, y'` for en_US locale (e.g. September 3, 2010)\n\t * * `'mediumDate'`: equivalent to `'MMM d, y'` for en_US locale (e.g. Sep 3, 2010)\n\t * * `'shortDate'`: equivalent to `'M/d/yy'` for en_US locale (e.g. 9/3/10)\n\t * * `'mediumTime'`: equivalent to `'h:mm:ss a'` for en_US locale (e.g. 12:05:08 PM)\n\t * * `'shortTime'`: equivalent to `'h:mm a'` for en_US locale (e.g. 12:05 PM)\n\t *\n\t * `format` string can contain literal values. These need to be escaped by surrounding with single quotes (e.g.\n\t * `\"h 'in the morning'\"`). In order to output a single quote, escape it - i.e., two single quotes in a sequence\n\t * (e.g. `\"h 'o''clock'\"`).\n\t *\n\t * @param {(Date|number|string)} date Date to format either as Date object, milliseconds (string or\n\t * number) or various ISO 8601 datetime string formats (e.g. yyyy-MM-ddTHH:mm:ss.sssZ and its\n\t * shorter versions like yyyy-MM-ddTHH:mmZ, yyyy-MM-dd or yyyyMMddTHHmmssZ). If no timezone is\n\t * specified in the string input, the time is considered to be in the local timezone.\n\t * @param {string=} format Formatting rules (see Description). If not specified,\n\t * `mediumDate` is used.\n\t * @param {string=} timezone Timezone to be used for formatting. It understands UTC/GMT and the\n\t * continental US time zone abbreviations, but for general use, use a time zone offset, for\n\t * example, `'+0430'` (4 hours, 30 minutes east of the Greenwich meridian)\n\t * If not specified, the timezone of the browser will be used.\n\t * @returns {string} Formatted string or the input if input is not recognized as date/millis.\n\t *\n\t * @example\n\t \n\t \n\t {{1288323623006 | date:'medium'}}:\n\t {{1288323623006 | date:'medium'}}
\n\t {{1288323623006 | date:'yyyy-MM-dd HH:mm:ss Z'}}:\n\t {{1288323623006 | date:'yyyy-MM-dd HH:mm:ss Z'}}
\n\t {{1288323623006 | date:'MM/dd/yyyy @ h:mma'}}:\n\t {{'1288323623006' | date:'MM/dd/yyyy @ h:mma'}}
\n\t {{1288323623006 | date:\"MM/dd/yyyy 'at' h:mma\"}}:\n\t {{'1288323623006' | date:\"MM/dd/yyyy 'at' h:mma\"}}
\n\t
\n\t \n\t it('should format date', function() {\n\t expect(element(by.binding(\"1288323623006 | date:'medium'\")).getText()).\n\t toMatch(/Oct 2\\d, 2010 \\d{1,2}:\\d{2}:\\d{2} (AM|PM)/);\n\t expect(element(by.binding(\"1288323623006 | date:'yyyy-MM-dd HH:mm:ss Z'\")).getText()).\n\t toMatch(/2010\\-10\\-2\\d \\d{2}:\\d{2}:\\d{2} (\\-|\\+)?\\d{4}/);\n\t expect(element(by.binding(\"'1288323623006' | date:'MM/dd/yyyy @ h:mma'\")).getText()).\n\t toMatch(/10\\/2\\d\\/2010 @ \\d{1,2}:\\d{2}(AM|PM)/);\n\t expect(element(by.binding(\"'1288323623006' | date:\\\"MM/dd/yyyy 'at' h:mma\\\"\")).getText()).\n\t toMatch(/10\\/2\\d\\/2010 at \\d{1,2}:\\d{2}(AM|PM)/);\n\t });\n\t \n\t
\n\t */\n\tdateFilter.$inject = ['$locale'];\n\tfunction dateFilter($locale) {\n\t\n\t\n\t var R_ISO8601_STR = /^(\\d{4})-?(\\d\\d)-?(\\d\\d)(?:T(\\d\\d)(?::?(\\d\\d)(?::?(\\d\\d)(?:\\.(\\d+))?)?)?(Z|([+-])(\\d\\d):?(\\d\\d))?)?$/;\n\t // 1 2 3 4 5 6 7 8 9 10 11\n\t function jsonStringToDate(string) {\n\t var match;\n\t if (match = string.match(R_ISO8601_STR)) {\n\t var date = new Date(0),\n\t tzHour = 0,\n\t tzMin = 0,\n\t dateSetter = match[8] ? date.setUTCFullYear : date.setFullYear,\n\t timeSetter = match[8] ? date.setUTCHours : date.setHours;\n\t\n\t if (match[9]) {\n\t tzHour = toInt(match[9] + match[10]);\n\t tzMin = toInt(match[9] + match[11]);\n\t }\n\t dateSetter.call(date, toInt(match[1]), toInt(match[2]) - 1, toInt(match[3]));\n\t var h = toInt(match[4] || 0) - tzHour;\n\t var m = toInt(match[5] || 0) - tzMin;\n\t var s = toInt(match[6] || 0);\n\t var ms = Math.round(parseFloat('0.' + (match[7] || 0)) * 1000);\n\t timeSetter.call(date, h, m, s, ms);\n\t return date;\n\t }\n\t return string;\n\t }\n\t\n\t\n\t return function(date, format, timezone) {\n\t var text = '',\n\t parts = [],\n\t fn, match;\n\t\n\t format = format || 'mediumDate';\n\t format = $locale.DATETIME_FORMATS[format] || format;\n\t if (isString(date)) {\n\t date = NUMBER_STRING.test(date) ? toInt(date) : jsonStringToDate(date);\n\t }\n\t\n\t if (isNumber(date)) {\n\t date = new Date(date);\n\t }\n\t\n\t if (!isDate(date) || !isFinite(date.getTime())) {\n\t return date;\n\t }\n\t\n\t while (format) {\n\t match = DATE_FORMATS_SPLIT.exec(format);\n\t if (match) {\n\t parts = concat(parts, match, 1);\n\t format = parts.pop();\n\t } else {\n\t parts.push(format);\n\t format = null;\n\t }\n\t }\n\t\n\t var dateTimezoneOffset = date.getTimezoneOffset();\n\t if (timezone) {\n\t dateTimezoneOffset = timezoneToOffset(timezone, dateTimezoneOffset);\n\t date = convertTimezoneToLocal(date, timezone, true);\n\t }\n\t forEach(parts, function(value) {\n\t fn = DATE_FORMATS[value];\n\t text += fn ? fn(date, $locale.DATETIME_FORMATS, dateTimezoneOffset)\n\t : value === \"''\" ? \"'\" : value.replace(/(^'|'$)/g, '').replace(/''/g, \"'\");\n\t });\n\t\n\t return text;\n\t };\n\t}\n\t\n\t\n\t/**\n\t * @ngdoc filter\n\t * @name json\n\t * @kind function\n\t *\n\t * @description\n\t * Allows you to convert a JavaScript object into JSON string.\n\t *\n\t * This filter is mostly useful for debugging. When using the double curly {{value}} notation\n\t * the binding is automatically converted to JSON.\n\t *\n\t * @param {*} object Any JavaScript object (including arrays and primitive types) to filter.\n\t * @param {number=} spacing The number of spaces to use per indentation, defaults to 2.\n\t * @returns {string} JSON string.\n\t *\n\t *\n\t * @example\n\t \n\t \n\t
{{ {'name':'value'} | json }}
\n\t
{{ {'name':'value'} | json:4 }}
\n\t
\n\t \n\t it('should jsonify filtered objects', function() {\n\t expect(element(by.id('default-spacing')).getText()).toMatch(/\\{\\n \"name\": ?\"value\"\\n}/);\n\t expect(element(by.id('custom-spacing')).getText()).toMatch(/\\{\\n \"name\": ?\"value\"\\n}/);\n\t });\n\t \n\t
\n\t *\n\t */\n\tfunction jsonFilter() {\n\t return function(object, spacing) {\n\t if (isUndefined(spacing)) {\n\t spacing = 2;\n\t }\n\t return toJson(object, spacing);\n\t };\n\t}\n\t\n\t\n\t/**\n\t * @ngdoc filter\n\t * @name lowercase\n\t * @kind function\n\t * @description\n\t * Converts string to lowercase.\n\t * @see angular.lowercase\n\t */\n\tvar lowercaseFilter = valueFn(lowercase);\n\t\n\t\n\t/**\n\t * @ngdoc filter\n\t * @name uppercase\n\t * @kind function\n\t * @description\n\t * Converts string to uppercase.\n\t * @see angular.uppercase\n\t */\n\tvar uppercaseFilter = valueFn(uppercase);\n\t\n\t/**\n\t * @ngdoc filter\n\t * @name limitTo\n\t * @kind function\n\t *\n\t * @description\n\t * Creates a new array or string containing only a specified number of elements. The elements\n\t * are taken from either the beginning or the end of the source array, string or number, as specified by\n\t * the value and sign (positive or negative) of `limit`. If a number is used as input, it is\n\t * converted to a string.\n\t *\n\t * @param {Array|string|number} input Source array, string or number to be limited.\n\t * @param {string|number} limit The length of the returned array or string. If the `limit` number\n\t * is positive, `limit` number of items from the beginning of the source array/string are copied.\n\t * If the number is negative, `limit` number of items from the end of the source array/string\n\t * are copied. The `limit` will be trimmed if it exceeds `array.length`. If `limit` is undefined,\n\t * the input will be returned unchanged.\n\t * @param {(string|number)=} begin Index at which to begin limitation. As a negative index, `begin`\n\t * indicates an offset from the end of `input`. Defaults to `0`.\n\t * @returns {Array|string} A new sub-array or substring of length `limit` or less if input array\n\t * had less than `limit` elements.\n\t *\n\t * @example\n\t \n\t \n\t \n\t
\n\t \n\t

Output numbers: {{ numbers | limitTo:numLimit }}

\n\t \n\t

Output letters: {{ letters | limitTo:letterLimit }}

\n\t \n\t

Output long number: {{ longNumber | limitTo:longNumberLimit }}

\n\t
\n\t
\n\t \n\t var numLimitInput = element(by.model('numLimit'));\n\t var letterLimitInput = element(by.model('letterLimit'));\n\t var longNumberLimitInput = element(by.model('longNumberLimit'));\n\t var limitedNumbers = element(by.binding('numbers | limitTo:numLimit'));\n\t var limitedLetters = element(by.binding('letters | limitTo:letterLimit'));\n\t var limitedLongNumber = element(by.binding('longNumber | limitTo:longNumberLimit'));\n\t\n\t it('should limit the number array to first three items', function() {\n\t expect(numLimitInput.getAttribute('value')).toBe('3');\n\t expect(letterLimitInput.getAttribute('value')).toBe('3');\n\t expect(longNumberLimitInput.getAttribute('value')).toBe('3');\n\t expect(limitedNumbers.getText()).toEqual('Output numbers: [1,2,3]');\n\t expect(limitedLetters.getText()).toEqual('Output letters: abc');\n\t expect(limitedLongNumber.getText()).toEqual('Output long number: 234');\n\t });\n\t\n\t // There is a bug in safari and protractor that doesn't like the minus key\n\t // it('should update the output when -3 is entered', function() {\n\t // numLimitInput.clear();\n\t // numLimitInput.sendKeys('-3');\n\t // letterLimitInput.clear();\n\t // letterLimitInput.sendKeys('-3');\n\t // longNumberLimitInput.clear();\n\t // longNumberLimitInput.sendKeys('-3');\n\t // expect(limitedNumbers.getText()).toEqual('Output numbers: [7,8,9]');\n\t // expect(limitedLetters.getText()).toEqual('Output letters: ghi');\n\t // expect(limitedLongNumber.getText()).toEqual('Output long number: 342');\n\t // });\n\t\n\t it('should not exceed the maximum size of input array', function() {\n\t numLimitInput.clear();\n\t numLimitInput.sendKeys('100');\n\t letterLimitInput.clear();\n\t letterLimitInput.sendKeys('100');\n\t longNumberLimitInput.clear();\n\t longNumberLimitInput.sendKeys('100');\n\t expect(limitedNumbers.getText()).toEqual('Output numbers: [1,2,3,4,5,6,7,8,9]');\n\t expect(limitedLetters.getText()).toEqual('Output letters: abcdefghi');\n\t expect(limitedLongNumber.getText()).toEqual('Output long number: 2345432342');\n\t });\n\t \n\t
\n\t*/\n\tfunction limitToFilter() {\n\t return function(input, limit, begin) {\n\t if (Math.abs(Number(limit)) === Infinity) {\n\t limit = Number(limit);\n\t } else {\n\t limit = toInt(limit);\n\t }\n\t if (isNaN(limit)) return input;\n\t\n\t if (isNumber(input)) input = input.toString();\n\t if (!isArray(input) && !isString(input)) return input;\n\t\n\t begin = (!begin || isNaN(begin)) ? 0 : toInt(begin);\n\t begin = (begin < 0) ? Math.max(0, input.length + begin) : begin;\n\t\n\t if (limit >= 0) {\n\t return input.slice(begin, begin + limit);\n\t } else {\n\t if (begin === 0) {\n\t return input.slice(limit, input.length);\n\t } else {\n\t return input.slice(Math.max(0, begin + limit), begin);\n\t }\n\t }\n\t };\n\t}\n\t\n\t/**\n\t * @ngdoc filter\n\t * @name orderBy\n\t * @kind function\n\t *\n\t * @description\n\t * Orders a specified `array` by the `expression` predicate. It is ordered alphabetically\n\t * for strings and numerically for numbers. Note: if you notice numbers are not being sorted\n\t * as expected, make sure they are actually being saved as numbers and not strings.\n\t *\n\t * @param {Array} array The array to sort.\n\t * @param {function(*)|string|Array.<(function(*)|string)>=} expression A predicate to be\n\t * used by the comparator to determine the order of elements.\n\t *\n\t * Can be one of:\n\t *\n\t * - `function`: Getter function. The result of this function will be sorted using the\n\t * `<`, `===`, `>` operator.\n\t * - `string`: An Angular expression. The result of this expression is used to compare elements\n\t * (for example `name` to sort by a property called `name` or `name.substr(0, 3)` to sort by\n\t * 3 first characters of a property called `name`). The result of a constant expression\n\t * is interpreted as a property name to be used in comparisons (for example `\"special name\"`\n\t * to sort object by the value of their `special name` property). An expression can be\n\t * optionally prefixed with `+` or `-` to control ascending or descending sort order\n\t * (for example, `+name` or `-name`). If no property is provided, (e.g. `'+'`) then the array\n\t * element itself is used to compare where sorting.\n\t * - `Array`: An array of function or string predicates. The first predicate in the array\n\t * is used for sorting, but when two items are equivalent, the next predicate is used.\n\t *\n\t * If the predicate is missing or empty then it defaults to `'+'`.\n\t *\n\t * @param {boolean=} reverse Reverse the order of the array.\n\t * @returns {Array} Sorted copy of the source array.\n\t *\n\t *\n\t * @example\n\t * The example below demonstrates a simple ngRepeat, where the data is sorted\n\t * by age in descending order (predicate is set to `'-age'`).\n\t * `reverse` is not set, which means it defaults to `false`.\n\t \n\t \n\t
\n\t \n\t \n\t \n\t \n\t \n\t \n\t \n\t \n\t \n\t \n\t \n\t
NamePhone NumberAge
{{friend.name}}{{friend.phone}}{{friend.age}}
\n\t
\n\t
\n\t \n\t angular.module('orderByExample', [])\n\t .controller('ExampleController', ['$scope', function($scope) {\n\t $scope.friends =\n\t [{name:'John', phone:'555-1212', age:10},\n\t {name:'Mary', phone:'555-9876', age:19},\n\t {name:'Mike', phone:'555-4321', age:21},\n\t {name:'Adam', phone:'555-5678', age:35},\n\t {name:'Julie', phone:'555-8765', age:29}];\n\t }]);\n\t \n\t
\n\t *\n\t * The predicate and reverse parameters can be controlled dynamically through scope properties,\n\t * as shown in the next example.\n\t * @example\n\t \n\t \n\t
\n\t
Sorting predicate = {{predicate}}; reverse = {{reverse}}
\n\t
\n\t \n\t \n\t \n\t \n\t \n\t \n\t \n\t \n\t \n\t \n\t \n\t \n\t
\n\t \n\t \n\t \n\t \n\t \n\t \n\t \n\t \n\t
{{friend.name}}{{friend.phone}}{{friend.age}}
\n\t
\n\t
\n\t \n\t angular.module('orderByExample', [])\n\t .controller('ExampleController', ['$scope', function($scope) {\n\t $scope.friends =\n\t [{name:'John', phone:'555-1212', age:10},\n\t {name:'Mary', phone:'555-9876', age:19},\n\t {name:'Mike', phone:'555-4321', age:21},\n\t {name:'Adam', phone:'555-5678', age:35},\n\t {name:'Julie', phone:'555-8765', age:29}];\n\t $scope.predicate = 'age';\n\t $scope.reverse = true;\n\t $scope.order = function(predicate) {\n\t $scope.reverse = ($scope.predicate === predicate) ? !$scope.reverse : false;\n\t $scope.predicate = predicate;\n\t };\n\t }]);\n\t \n\t \n\t .sortorder:after {\n\t content: '\\25b2';\n\t }\n\t .sortorder.reverse:after {\n\t content: '\\25bc';\n\t }\n\t \n\t
\n\t *\n\t * It's also possible to call the orderBy filter manually, by injecting `$filter`, retrieving the\n\t * filter routine with `$filter('orderBy')`, and calling the returned filter routine with the\n\t * desired parameters.\n\t *\n\t * Example:\n\t *\n\t * @example\n\t \n\t \n\t
\n\t
Sorting predicate = {{predicate}}; reverse = {{reverse}}
\n\t \n\t \n\t \n\t \n\t \n\t \n\t \n\t \n\t \n\t \n\t \n\t
\n\t \n\t \n\t \n\t \n\t \n\t \n\t \n\t \n\t
{{friend.name}}{{friend.phone}}{{friend.age}}
\n\t
\n\t
\n\t\n\t \n\t angular.module('orderByExample', [])\n\t .controller('ExampleController', ['$scope', '$filter', function($scope, $filter) {\n\t var orderBy = $filter('orderBy');\n\t $scope.friends = [\n\t { name: 'John', phone: '555-1212', age: 10 },\n\t { name: 'Mary', phone: '555-9876', age: 19 },\n\t { name: 'Mike', phone: '555-4321', age: 21 },\n\t { name: 'Adam', phone: '555-5678', age: 35 },\n\t { name: 'Julie', phone: '555-8765', age: 29 }\n\t ];\n\t $scope.order = function(predicate) {\n\t $scope.predicate = predicate;\n\t $scope.reverse = ($scope.predicate === predicate) ? !$scope.reverse : false;\n\t $scope.friends = orderBy($scope.friends, predicate, $scope.reverse);\n\t };\n\t $scope.order('age', true);\n\t }]);\n\t \n\t\n\t \n\t .sortorder:after {\n\t content: '\\25b2';\n\t }\n\t .sortorder.reverse:after {\n\t content: '\\25bc';\n\t }\n\t \n\t
\n\t */\n\torderByFilter.$inject = ['$parse'];\n\tfunction orderByFilter($parse) {\n\t return function(array, sortPredicate, reverseOrder) {\n\t\n\t if (!(isArrayLike(array))) return array;\n\t\n\t if (!isArray(sortPredicate)) { sortPredicate = [sortPredicate]; }\n\t if (sortPredicate.length === 0) { sortPredicate = ['+']; }\n\t\n\t var predicates = processPredicates(sortPredicate, reverseOrder);\n\t // Add a predicate at the end that evaluates to the element index. This makes the\n\t // sort stable as it works as a tie-breaker when all the input predicates cannot\n\t // distinguish between two elements.\n\t predicates.push({ get: function() { return {}; }, descending: reverseOrder ? -1 : 1});\n\t\n\t // The next three lines are a version of a Swartzian Transform idiom from Perl\n\t // (sometimes called the Decorate-Sort-Undecorate idiom)\n\t // See https://en.wikipedia.org/wiki/Schwartzian_transform\n\t var compareValues = Array.prototype.map.call(array, getComparisonObject);\n\t compareValues.sort(doComparison);\n\t array = compareValues.map(function(item) { return item.value; });\n\t\n\t return array;\n\t\n\t function getComparisonObject(value, index) {\n\t return {\n\t value: value,\n\t predicateValues: predicates.map(function(predicate) {\n\t return getPredicateValue(predicate.get(value), index);\n\t })\n\t };\n\t }\n\t\n\t function doComparison(v1, v2) {\n\t var result = 0;\n\t for (var index=0, length = predicates.length; index < length; ++index) {\n\t result = compare(v1.predicateValues[index], v2.predicateValues[index]) * predicates[index].descending;\n\t if (result) break;\n\t }\n\t return result;\n\t }\n\t };\n\t\n\t function processPredicates(sortPredicate, reverseOrder) {\n\t reverseOrder = reverseOrder ? -1 : 1;\n\t return sortPredicate.map(function(predicate) {\n\t var descending = 1, get = identity;\n\t\n\t if (isFunction(predicate)) {\n\t get = predicate;\n\t } else if (isString(predicate)) {\n\t if ((predicate.charAt(0) == '+' || predicate.charAt(0) == '-')) {\n\t descending = predicate.charAt(0) == '-' ? -1 : 1;\n\t predicate = predicate.substring(1);\n\t }\n\t if (predicate !== '') {\n\t get = $parse(predicate);\n\t if (get.constant) {\n\t var key = get();\n\t get = function(value) { return value[key]; };\n\t }\n\t }\n\t }\n\t return { get: get, descending: descending * reverseOrder };\n\t });\n\t }\n\t\n\t function isPrimitive(value) {\n\t switch (typeof value) {\n\t case 'number': /* falls through */\n\t case 'boolean': /* falls through */\n\t case 'string':\n\t return true;\n\t default:\n\t return false;\n\t }\n\t }\n\t\n\t function objectValue(value, index) {\n\t // If `valueOf` is a valid function use that\n\t if (typeof value.valueOf === 'function') {\n\t value = value.valueOf();\n\t if (isPrimitive(value)) return value;\n\t }\n\t // If `toString` is a valid function and not the one from `Object.prototype` use that\n\t if (hasCustomToString(value)) {\n\t value = value.toString();\n\t if (isPrimitive(value)) return value;\n\t }\n\t // We have a basic object so we use the position of the object in the collection\n\t return index;\n\t }\n\t\n\t function getPredicateValue(value, index) {\n\t var type = typeof value;\n\t if (value === null) {\n\t type = 'string';\n\t value = 'null';\n\t } else if (type === 'string') {\n\t value = value.toLowerCase();\n\t } else if (type === 'object') {\n\t value = objectValue(value, index);\n\t }\n\t return { value: value, type: type };\n\t }\n\t\n\t function compare(v1, v2) {\n\t var result = 0;\n\t if (v1.type === v2.type) {\n\t if (v1.value !== v2.value) {\n\t result = v1.value < v2.value ? -1 : 1;\n\t }\n\t } else {\n\t result = v1.type < v2.type ? -1 : 1;\n\t }\n\t return result;\n\t }\n\t}\n\t\n\tfunction ngDirective(directive) {\n\t if (isFunction(directive)) {\n\t directive = {\n\t link: directive\n\t };\n\t }\n\t directive.restrict = directive.restrict || 'AC';\n\t return valueFn(directive);\n\t}\n\t\n\t/**\n\t * @ngdoc directive\n\t * @name a\n\t * @restrict E\n\t *\n\t * @description\n\t * Modifies the default behavior of the html A tag so that the default action is prevented when\n\t * the href attribute is empty.\n\t *\n\t * This change permits the easy creation of action links with the `ngClick` directive\n\t * without changing the location or causing page reloads, e.g.:\n\t * `Add Item`\n\t */\n\tvar htmlAnchorDirective = valueFn({\n\t restrict: 'E',\n\t compile: function(element, attr) {\n\t if (!attr.href && !attr.xlinkHref) {\n\t return function(scope, element) {\n\t // If the linked element is not an anchor tag anymore, do nothing\n\t if (element[0].nodeName.toLowerCase() !== 'a') return;\n\t\n\t // SVGAElement does not use the href attribute, but rather the 'xlinkHref' attribute.\n\t var href = toString.call(element.prop('href')) === '[object SVGAnimatedString]' ?\n\t 'xlink:href' : 'href';\n\t element.on('click', function(event) {\n\t // if we have no href url, then don't navigate anywhere.\n\t if (!element.attr(href)) {\n\t event.preventDefault();\n\t }\n\t });\n\t };\n\t }\n\t }\n\t});\n\t\n\t/**\n\t * @ngdoc directive\n\t * @name ngHref\n\t * @restrict A\n\t * @priority 99\n\t *\n\t * @description\n\t * Using Angular markup like `{{hash}}` in an href attribute will\n\t * make the link go to the wrong URL if the user clicks it before\n\t * Angular has a chance to replace the `{{hash}}` markup with its\n\t * value. Until Angular replaces the markup the link will be broken\n\t * and will most likely return a 404 error. The `ngHref` directive\n\t * solves this problem.\n\t *\n\t * The wrong way to write it:\n\t * ```html\n\t * link1\n\t * ```\n\t *\n\t * The correct way to write it:\n\t * ```html\n\t * link1\n\t * ```\n\t *\n\t * @element A\n\t * @param {template} ngHref any string which can contain `{{}}` markup.\n\t *\n\t * @example\n\t * This example shows various combinations of `href`, `ng-href` and `ng-click` attributes\n\t * in links and their different behaviors:\n\t \n\t \n\t
\n\t link 1 (link, don't reload)
\n\t link 2 (link, don't reload)
\n\t link 3 (link, reload!)
\n\t anchor (link, don't reload)
\n\t anchor (no link)
\n\t link (link, change location)\n\t
\n\t \n\t it('should execute ng-click but not reload when href without value', function() {\n\t element(by.id('link-1')).click();\n\t expect(element(by.model('value')).getAttribute('value')).toEqual('1');\n\t expect(element(by.id('link-1')).getAttribute('href')).toBe('');\n\t });\n\t\n\t it('should execute ng-click but not reload when href empty string', function() {\n\t element(by.id('link-2')).click();\n\t expect(element(by.model('value')).getAttribute('value')).toEqual('2');\n\t expect(element(by.id('link-2')).getAttribute('href')).toBe('');\n\t });\n\t\n\t it('should execute ng-click and change url when ng-href specified', function() {\n\t expect(element(by.id('link-3')).getAttribute('href')).toMatch(/\\/123$/);\n\t\n\t element(by.id('link-3')).click();\n\t\n\t // At this point, we navigate away from an Angular page, so we need\n\t // to use browser.driver to get the base webdriver.\n\t\n\t browser.wait(function() {\n\t return browser.driver.getCurrentUrl().then(function(url) {\n\t return url.match(/\\/123$/);\n\t });\n\t }, 5000, 'page should navigate to /123');\n\t });\n\t\n\t it('should execute ng-click but not reload when href empty string and name specified', function() {\n\t element(by.id('link-4')).click();\n\t expect(element(by.model('value')).getAttribute('value')).toEqual('4');\n\t expect(element(by.id('link-4')).getAttribute('href')).toBe('');\n\t });\n\t\n\t it('should execute ng-click but not reload when no href but name specified', function() {\n\t element(by.id('link-5')).click();\n\t expect(element(by.model('value')).getAttribute('value')).toEqual('5');\n\t expect(element(by.id('link-5')).getAttribute('href')).toBe(null);\n\t });\n\t\n\t it('should only change url when only ng-href', function() {\n\t element(by.model('value')).clear();\n\t element(by.model('value')).sendKeys('6');\n\t expect(element(by.id('link-6')).getAttribute('href')).toMatch(/\\/6$/);\n\t\n\t element(by.id('link-6')).click();\n\t\n\t // At this point, we navigate away from an Angular page, so we need\n\t // to use browser.driver to get the base webdriver.\n\t browser.wait(function() {\n\t return browser.driver.getCurrentUrl().then(function(url) {\n\t return url.match(/\\/6$/);\n\t });\n\t }, 5000, 'page should navigate to /6');\n\t });\n\t \n\t
\n\t */\n\t\n\t/**\n\t * @ngdoc directive\n\t * @name ngSrc\n\t * @restrict A\n\t * @priority 99\n\t *\n\t * @description\n\t * Using Angular markup like `{{hash}}` in a `src` attribute doesn't\n\t * work right: The browser will fetch from the URL with the literal\n\t * text `{{hash}}` until Angular replaces the expression inside\n\t * `{{hash}}`. The `ngSrc` directive solves this problem.\n\t *\n\t * The buggy way to write it:\n\t * ```html\n\t * \"Description\"/\n\t * ```\n\t *\n\t * The correct way to write it:\n\t * ```html\n\t * \"Description\"\n\t * ```\n\t *\n\t * @element IMG\n\t * @param {template} ngSrc any string which can contain `{{}}` markup.\n\t */\n\t\n\t/**\n\t * @ngdoc directive\n\t * @name ngSrcset\n\t * @restrict A\n\t * @priority 99\n\t *\n\t * @description\n\t * Using Angular markup like `{{hash}}` in a `srcset` attribute doesn't\n\t * work right: The browser will fetch from the URL with the literal\n\t * text `{{hash}}` until Angular replaces the expression inside\n\t * `{{hash}}`. The `ngSrcset` directive solves this problem.\n\t *\n\t * The buggy way to write it:\n\t * ```html\n\t * \"Description\"/\n\t * ```\n\t *\n\t * The correct way to write it:\n\t * ```html\n\t * \"Description\"\n\t * ```\n\t *\n\t * @element IMG\n\t * @param {template} ngSrcset any string which can contain `{{}}` markup.\n\t */\n\t\n\t/**\n\t * @ngdoc directive\n\t * @name ngDisabled\n\t * @restrict A\n\t * @priority 100\n\t *\n\t * @description\n\t *\n\t * This directive sets the `disabled` attribute on the element if the\n\t * {@link guide/expression expression} inside `ngDisabled` evaluates to truthy.\n\t *\n\t * A special directive is necessary because we cannot use interpolation inside the `disabled`\n\t * attribute. See the {@link guide/interpolation interpolation guide} for more info.\n\t *\n\t * @example\n\t \n\t \n\t
\n\t \n\t
\n\t \n\t it('should toggle button', function() {\n\t expect(element(by.css('button')).getAttribute('disabled')).toBeFalsy();\n\t element(by.model('checked')).click();\n\t expect(element(by.css('button')).getAttribute('disabled')).toBeTruthy();\n\t });\n\t \n\t
\n\t *\n\t * @element INPUT\n\t * @param {expression} ngDisabled If the {@link guide/expression expression} is truthy,\n\t * then the `disabled` attribute will be set on the element\n\t */\n\t\n\t\n\t/**\n\t * @ngdoc directive\n\t * @name ngChecked\n\t * @restrict A\n\t * @priority 100\n\t *\n\t * @description\n\t * Sets the `checked` attribute on the element, if the expression inside `ngChecked` is truthy.\n\t *\n\t * Note that this directive should not be used together with {@link ngModel `ngModel`},\n\t * as this can lead to unexpected behavior.\n\t *\n\t * A special directive is necessary because we cannot use interpolation inside the `checked`\n\t * attribute. See the {@link guide/interpolation interpolation guide} for more info.\n\t *\n\t * @example\n\t \n\t \n\t
\n\t \n\t
\n\t \n\t it('should check both checkBoxes', function() {\n\t expect(element(by.id('checkSlave')).getAttribute('checked')).toBeFalsy();\n\t element(by.model('master')).click();\n\t expect(element(by.id('checkSlave')).getAttribute('checked')).toBeTruthy();\n\t });\n\t \n\t
\n\t *\n\t * @element INPUT\n\t * @param {expression} ngChecked If the {@link guide/expression expression} is truthy,\n\t * then the `checked` attribute will be set on the element\n\t */\n\t\n\t\n\t/**\n\t * @ngdoc directive\n\t * @name ngReadonly\n\t * @restrict A\n\t * @priority 100\n\t *\n\t * @description\n\t *\n\t * Sets the `readOnly` attribute on the element, if the expression inside `ngReadonly` is truthy.\n\t *\n\t * A special directive is necessary because we cannot use interpolation inside the `readOnly`\n\t * attribute. See the {@link guide/interpolation interpolation guide} for more info.\n\t *\n\t * @example\n\t \n\t \n\t
\n\t \n\t
\n\t \n\t it('should toggle readonly attr', function() {\n\t expect(element(by.css('[type=\"text\"]')).getAttribute('readonly')).toBeFalsy();\n\t element(by.model('checked')).click();\n\t expect(element(by.css('[type=\"text\"]')).getAttribute('readonly')).toBeTruthy();\n\t });\n\t \n\t
\n\t *\n\t * @element INPUT\n\t * @param {expression} ngReadonly If the {@link guide/expression expression} is truthy,\n\t * then special attribute \"readonly\" will be set on the element\n\t */\n\t\n\t\n\t/**\n\t * @ngdoc directive\n\t * @name ngSelected\n\t * @restrict A\n\t * @priority 100\n\t *\n\t * @description\n\t *\n\t * Sets the `selected` attribute on the element, if the expression inside `ngSelected` is truthy.\n\t *\n\t * A special directive is necessary because we cannot use interpolation inside the `selected`\n\t * attribute. See the {@link guide/interpolation interpolation guide} for more info.\n\t *\n\t * @example\n\t \n\t \n\t
\n\t \n\t
\n\t \n\t it('should select Greetings!', function() {\n\t expect(element(by.id('greet')).getAttribute('selected')).toBeFalsy();\n\t element(by.model('selected')).click();\n\t expect(element(by.id('greet')).getAttribute('selected')).toBeTruthy();\n\t });\n\t \n\t
\n\t *\n\t * @element OPTION\n\t * @param {expression} ngSelected If the {@link guide/expression expression} is truthy,\n\t * then special attribute \"selected\" will be set on the element\n\t */\n\t\n\t/**\n\t * @ngdoc directive\n\t * @name ngOpen\n\t * @restrict A\n\t * @priority 100\n\t *\n\t * @description\n\t *\n\t * Sets the `open` attribute on the element, if the expression inside `ngOpen` is truthy.\n\t *\n\t * A special directive is necessary because we cannot use interpolation inside the `open`\n\t * attribute. See the {@link guide/interpolation interpolation guide} for more info.\n\t *\n\t * @example\n\t \n\t \n\t
\n\t
\n\t Show/Hide me\n\t
\n\t
\n\t \n\t it('should toggle open', function() {\n\t expect(element(by.id('details')).getAttribute('open')).toBeFalsy();\n\t element(by.model('open')).click();\n\t expect(element(by.id('details')).getAttribute('open')).toBeTruthy();\n\t });\n\t \n\t
\n\t *\n\t * @element DETAILS\n\t * @param {expression} ngOpen If the {@link guide/expression expression} is truthy,\n\t * then special attribute \"open\" will be set on the element\n\t */\n\t\n\tvar ngAttributeAliasDirectives = {};\n\t\n\t// boolean attrs are evaluated\n\tforEach(BOOLEAN_ATTR, function(propName, attrName) {\n\t // binding to multiple is not supported\n\t if (propName == \"multiple\") return;\n\t\n\t function defaultLinkFn(scope, element, attr) {\n\t scope.$watch(attr[normalized], function ngBooleanAttrWatchAction(value) {\n\t attr.$set(attrName, !!value);\n\t });\n\t }\n\t\n\t var normalized = directiveNormalize('ng-' + attrName);\n\t var linkFn = defaultLinkFn;\n\t\n\t if (propName === 'checked') {\n\t linkFn = function(scope, element, attr) {\n\t // ensuring ngChecked doesn't interfere with ngModel when both are set on the same input\n\t if (attr.ngModel !== attr[normalized]) {\n\t defaultLinkFn(scope, element, attr);\n\t }\n\t };\n\t }\n\t\n\t ngAttributeAliasDirectives[normalized] = function() {\n\t return {\n\t restrict: 'A',\n\t priority: 100,\n\t link: linkFn\n\t };\n\t };\n\t});\n\t\n\t// aliased input attrs are evaluated\n\tforEach(ALIASED_ATTR, function(htmlAttr, ngAttr) {\n\t ngAttributeAliasDirectives[ngAttr] = function() {\n\t return {\n\t priority: 100,\n\t link: function(scope, element, attr) {\n\t //special case ngPattern when a literal regular expression value\n\t //is used as the expression (this way we don't have to watch anything).\n\t if (ngAttr === \"ngPattern\" && attr.ngPattern.charAt(0) == \"/\") {\n\t var match = attr.ngPattern.match(REGEX_STRING_REGEXP);\n\t if (match) {\n\t attr.$set(\"ngPattern\", new RegExp(match[1], match[2]));\n\t return;\n\t }\n\t }\n\t\n\t scope.$watch(attr[ngAttr], function ngAttrAliasWatchAction(value) {\n\t attr.$set(ngAttr, value);\n\t });\n\t }\n\t };\n\t };\n\t});\n\t\n\t// ng-src, ng-srcset, ng-href are interpolated\n\tforEach(['src', 'srcset', 'href'], function(attrName) {\n\t var normalized = directiveNormalize('ng-' + attrName);\n\t ngAttributeAliasDirectives[normalized] = function() {\n\t return {\n\t priority: 99, // it needs to run after the attributes are interpolated\n\t link: function(scope, element, attr) {\n\t var propName = attrName,\n\t name = attrName;\n\t\n\t if (attrName === 'href' &&\n\t toString.call(element.prop('href')) === '[object SVGAnimatedString]') {\n\t name = 'xlinkHref';\n\t attr.$attr[name] = 'xlink:href';\n\t propName = null;\n\t }\n\t\n\t attr.$observe(normalized, function(value) {\n\t if (!value) {\n\t if (attrName === 'href') {\n\t attr.$set(name, null);\n\t }\n\t return;\n\t }\n\t\n\t attr.$set(name, value);\n\t\n\t // on IE, if \"ng:src\" directive declaration is used and \"src\" attribute doesn't exist\n\t // then calling element.setAttribute('src', 'foo') doesn't do anything, so we need\n\t // to set the property as well to achieve the desired effect.\n\t // we use attr[attrName] value since $set can sanitize the url.\n\t if (msie && propName) element.prop(propName, attr[name]);\n\t });\n\t }\n\t };\n\t };\n\t});\n\t\n\t/* global -nullFormCtrl, -SUBMITTED_CLASS, addSetValidityMethod: true\n\t */\n\tvar nullFormCtrl = {\n\t $addControl: noop,\n\t $$renameControl: nullFormRenameControl,\n\t $removeControl: noop,\n\t $setValidity: noop,\n\t $setDirty: noop,\n\t $setPristine: noop,\n\t $setSubmitted: noop\n\t},\n\tSUBMITTED_CLASS = 'ng-submitted';\n\t\n\tfunction nullFormRenameControl(control, name) {\n\t control.$name = name;\n\t}\n\t\n\t/**\n\t * @ngdoc type\n\t * @name form.FormController\n\t *\n\t * @property {boolean} $pristine True if user has not interacted with the form yet.\n\t * @property {boolean} $dirty True if user has already interacted with the form.\n\t * @property {boolean} $valid True if all of the containing forms and controls are valid.\n\t * @property {boolean} $invalid True if at least one containing control or form is invalid.\n\t * @property {boolean} $pending True if at least one containing control or form is pending.\n\t * @property {boolean} $submitted True if user has submitted the form even if its invalid.\n\t *\n\t * @property {Object} $error Is an object hash, containing references to controls or\n\t * forms with failing validators, where:\n\t *\n\t * - keys are validation tokens (error names),\n\t * - values are arrays of controls or forms that have a failing validator for given error name.\n\t *\n\t * Built-in validation tokens:\n\t *\n\t * - `email`\n\t * - `max`\n\t * - `maxlength`\n\t * - `min`\n\t * - `minlength`\n\t * - `number`\n\t * - `pattern`\n\t * - `required`\n\t * - `url`\n\t * - `date`\n\t * - `datetimelocal`\n\t * - `time`\n\t * - `week`\n\t * - `month`\n\t *\n\t * @description\n\t * `FormController` keeps track of all its controls and nested forms as well as the state of them,\n\t * such as being valid/invalid or dirty/pristine.\n\t *\n\t * Each {@link ng.directive:form form} directive creates an instance\n\t * of `FormController`.\n\t *\n\t */\n\t//asks for $scope to fool the BC controller module\n\tFormController.$inject = ['$element', '$attrs', '$scope', '$animate', '$interpolate'];\n\tfunction FormController(element, attrs, $scope, $animate, $interpolate) {\n\t var form = this,\n\t controls = [];\n\t\n\t // init state\n\t form.$error = {};\n\t form.$$success = {};\n\t form.$pending = undefined;\n\t form.$name = $interpolate(attrs.name || attrs.ngForm || '')($scope);\n\t form.$dirty = false;\n\t form.$pristine = true;\n\t form.$valid = true;\n\t form.$invalid = false;\n\t form.$submitted = false;\n\t form.$$parentForm = nullFormCtrl;\n\t\n\t /**\n\t * @ngdoc method\n\t * @name form.FormController#$rollbackViewValue\n\t *\n\t * @description\n\t * Rollback all form controls pending updates to the `$modelValue`.\n\t *\n\t * Updates may be pending by a debounced event or because the input is waiting for a some future\n\t * event defined in `ng-model-options`. This method is typically needed by the reset button of\n\t * a form that uses `ng-model-options` to pend updates.\n\t */\n\t form.$rollbackViewValue = function() {\n\t forEach(controls, function(control) {\n\t control.$rollbackViewValue();\n\t });\n\t };\n\t\n\t /**\n\t * @ngdoc method\n\t * @name form.FormController#$commitViewValue\n\t *\n\t * @description\n\t * Commit all form controls pending updates to the `$modelValue`.\n\t *\n\t * Updates may be pending by a debounced event or because the input is waiting for a some future\n\t * event defined in `ng-model-options`. This method is rarely needed as `NgModelController`\n\t * usually handles calling this in response to input events.\n\t */\n\t form.$commitViewValue = function() {\n\t forEach(controls, function(control) {\n\t control.$commitViewValue();\n\t });\n\t };\n\t\n\t /**\n\t * @ngdoc method\n\t * @name form.FormController#$addControl\n\t * @param {object} control control object, either a {@link form.FormController} or an\n\t * {@link ngModel.NgModelController}\n\t *\n\t * @description\n\t * Register a control with the form. Input elements using ngModelController do this automatically\n\t * when they are linked.\n\t *\n\t * Note that the current state of the control will not be reflected on the new parent form. This\n\t * is not an issue with normal use, as freshly compiled and linked controls are in a `$pristine`\n\t * state.\n\t *\n\t * However, if the method is used programmatically, for example by adding dynamically created controls,\n\t * or controls that have been previously removed without destroying their corresponding DOM element,\n\t * it's the developers responsiblity to make sure the current state propagates to the parent form.\n\t *\n\t * For example, if an input control is added that is already `$dirty` and has `$error` properties,\n\t * calling `$setDirty()` and `$validate()` afterwards will propagate the state to the parent form.\n\t */\n\t form.$addControl = function(control) {\n\t // Breaking change - before, inputs whose name was \"hasOwnProperty\" were quietly ignored\n\t // and not added to the scope. Now we throw an error.\n\t assertNotHasOwnProperty(control.$name, 'input');\n\t controls.push(control);\n\t\n\t if (control.$name) {\n\t form[control.$name] = control;\n\t }\n\t\n\t control.$$parentForm = form;\n\t };\n\t\n\t // Private API: rename a form control\n\t form.$$renameControl = function(control, newName) {\n\t var oldName = control.$name;\n\t\n\t if (form[oldName] === control) {\n\t delete form[oldName];\n\t }\n\t form[newName] = control;\n\t control.$name = newName;\n\t };\n\t\n\t /**\n\t * @ngdoc method\n\t * @name form.FormController#$removeControl\n\t * @param {object} control control object, either a {@link form.FormController} or an\n\t * {@link ngModel.NgModelController}\n\t *\n\t * @description\n\t * Deregister a control from the form.\n\t *\n\t * Input elements using ngModelController do this automatically when they are destroyed.\n\t *\n\t * Note that only the removed control's validation state (`$errors`etc.) will be removed from the\n\t * form. `$dirty`, `$submitted` states will not be changed, because the expected behavior can be\n\t * different from case to case. For example, removing the only `$dirty` control from a form may or\n\t * may not mean that the form is still `$dirty`.\n\t */\n\t form.$removeControl = function(control) {\n\t if (control.$name && form[control.$name] === control) {\n\t delete form[control.$name];\n\t }\n\t forEach(form.$pending, function(value, name) {\n\t form.$setValidity(name, null, control);\n\t });\n\t forEach(form.$error, function(value, name) {\n\t form.$setValidity(name, null, control);\n\t });\n\t forEach(form.$$success, function(value, name) {\n\t form.$setValidity(name, null, control);\n\t });\n\t\n\t arrayRemove(controls, control);\n\t control.$$parentForm = nullFormCtrl;\n\t };\n\t\n\t\n\t /**\n\t * @ngdoc method\n\t * @name form.FormController#$setValidity\n\t *\n\t * @description\n\t * Sets the validity of a form control.\n\t *\n\t * This method will also propagate to parent forms.\n\t */\n\t addSetValidityMethod({\n\t ctrl: this,\n\t $element: element,\n\t set: function(object, property, controller) {\n\t var list = object[property];\n\t if (!list) {\n\t object[property] = [controller];\n\t } else {\n\t var index = list.indexOf(controller);\n\t if (index === -1) {\n\t list.push(controller);\n\t }\n\t }\n\t },\n\t unset: function(object, property, controller) {\n\t var list = object[property];\n\t if (!list) {\n\t return;\n\t }\n\t arrayRemove(list, controller);\n\t if (list.length === 0) {\n\t delete object[property];\n\t }\n\t },\n\t $animate: $animate\n\t });\n\t\n\t /**\n\t * @ngdoc method\n\t * @name form.FormController#$setDirty\n\t *\n\t * @description\n\t * Sets the form to a dirty state.\n\t *\n\t * This method can be called to add the 'ng-dirty' class and set the form to a dirty\n\t * state (ng-dirty class). This method will also propagate to parent forms.\n\t */\n\t form.$setDirty = function() {\n\t $animate.removeClass(element, PRISTINE_CLASS);\n\t $animate.addClass(element, DIRTY_CLASS);\n\t form.$dirty = true;\n\t form.$pristine = false;\n\t form.$$parentForm.$setDirty();\n\t };\n\t\n\t /**\n\t * @ngdoc method\n\t * @name form.FormController#$setPristine\n\t *\n\t * @description\n\t * Sets the form to its pristine state.\n\t *\n\t * This method can be called to remove the 'ng-dirty' class and set the form to its pristine\n\t * state (ng-pristine class). This method will also propagate to all the controls contained\n\t * in this form.\n\t *\n\t * Setting a form back to a pristine state is often useful when we want to 'reuse' a form after\n\t * saving or resetting it.\n\t */\n\t form.$setPristine = function() {\n\t $animate.setClass(element, PRISTINE_CLASS, DIRTY_CLASS + ' ' + SUBMITTED_CLASS);\n\t form.$dirty = false;\n\t form.$pristine = true;\n\t form.$submitted = false;\n\t forEach(controls, function(control) {\n\t control.$setPristine();\n\t });\n\t };\n\t\n\t /**\n\t * @ngdoc method\n\t * @name form.FormController#$setUntouched\n\t *\n\t * @description\n\t * Sets the form to its untouched state.\n\t *\n\t * This method can be called to remove the 'ng-touched' class and set the form controls to their\n\t * untouched state (ng-untouched class).\n\t *\n\t * Setting a form controls back to their untouched state is often useful when setting the form\n\t * back to its pristine state.\n\t */\n\t form.$setUntouched = function() {\n\t forEach(controls, function(control) {\n\t control.$setUntouched();\n\t });\n\t };\n\t\n\t /**\n\t * @ngdoc method\n\t * @name form.FormController#$setSubmitted\n\t *\n\t * @description\n\t * Sets the form to its submitted state.\n\t */\n\t form.$setSubmitted = function() {\n\t $animate.addClass(element, SUBMITTED_CLASS);\n\t form.$submitted = true;\n\t form.$$parentForm.$setSubmitted();\n\t };\n\t}\n\t\n\t/**\n\t * @ngdoc directive\n\t * @name ngForm\n\t * @restrict EAC\n\t *\n\t * @description\n\t * Nestable alias of {@link ng.directive:form `form`} directive. HTML\n\t * does not allow nesting of form elements. It is useful to nest forms, for example if the validity of a\n\t * sub-group of controls needs to be determined.\n\t *\n\t * Note: the purpose of `ngForm` is to group controls,\n\t * but not to be a replacement for the `
` tag with all of its capabilities\n\t * (e.g. posting to the server, ...).\n\t *\n\t * @param {string=} ngForm|name Name of the form. If specified, the form controller will be published into\n\t * related scope, under this name.\n\t *\n\t */\n\t\n\t /**\n\t * @ngdoc directive\n\t * @name form\n\t * @restrict E\n\t *\n\t * @description\n\t * Directive that instantiates\n\t * {@link form.FormController FormController}.\n\t *\n\t * If the `name` attribute is specified, the form controller is published onto the current scope under\n\t * this name.\n\t *\n\t * # Alias: {@link ng.directive:ngForm `ngForm`}\n\t *\n\t * In Angular, forms can be nested. This means that the outer form is valid when all of the child\n\t * forms are valid as well. However, browsers do not allow nesting of `` elements, so\n\t * Angular provides the {@link ng.directive:ngForm `ngForm`} directive, which behaves identically to\n\t * `form` but can be nested. Nested forms can be useful, for example, if the validity of a sub-group\n\t * of controls needs to be determined.\n\t *\n\t * # CSS classes\n\t * - `ng-valid` is set if the form is valid.\n\t * - `ng-invalid` is set if the form is invalid.\n\t * - `ng-pending` is set if the form is pending.\n\t * - `ng-pristine` is set if the form is pristine.\n\t * - `ng-dirty` is set if the form is dirty.\n\t * - `ng-submitted` is set if the form was submitted.\n\t *\n\t * Keep in mind that ngAnimate can detect each of these classes when added and removed.\n\t *\n\t *\n\t * # Submitting a form and preventing the default action\n\t *\n\t * Since the role of forms in client-side Angular applications is different than in classical\n\t * roundtrip apps, it is desirable for the browser not to translate the form submission into a full\n\t * page reload that sends the data to the server. Instead some javascript logic should be triggered\n\t * to handle the form submission in an application-specific way.\n\t *\n\t * For this reason, Angular prevents the default action (form submission to the server) unless the\n\t * `` element has an `action` attribute specified.\n\t *\n\t * You can use one of the following two ways to specify what javascript method should be called when\n\t * a form is submitted:\n\t *\n\t * - {@link ng.directive:ngSubmit ngSubmit} directive on the form element\n\t * - {@link ng.directive:ngClick ngClick} directive on the first\n\t * button or input field of type submit (input[type=submit])\n\t *\n\t * To prevent double execution of the handler, use only one of the {@link ng.directive:ngSubmit ngSubmit}\n\t * or {@link ng.directive:ngClick ngClick} directives.\n\t * This is because of the following form submission rules in the HTML specification:\n\t *\n\t * - If a form has only one input field then hitting enter in this field triggers form submit\n\t * (`ngSubmit`)\n\t * - if a form has 2+ input fields and no buttons or input[type=submit] then hitting enter\n\t * doesn't trigger submit\n\t * - if a form has one or more input fields and one or more buttons or input[type=submit] then\n\t * hitting enter in any of the input fields will trigger the click handler on the *first* button or\n\t * input[type=submit] (`ngClick`) *and* a submit handler on the enclosing form (`ngSubmit`)\n\t *\n\t * Any pending `ngModelOptions` changes will take place immediately when an enclosing form is\n\t * submitted. Note that `ngClick` events will occur before the model is updated. Use `ngSubmit`\n\t * to have access to the updated model.\n\t *\n\t * ## Animation Hooks\n\t *\n\t * Animations in ngForm are triggered when any of the associated CSS classes are added and removed.\n\t * These classes are: `.ng-pristine`, `.ng-dirty`, `.ng-invalid` and `.ng-valid` as well as any\n\t * other validations that are performed within the form. Animations in ngForm are similar to how\n\t * they work in ngClass and animations can be hooked into using CSS transitions, keyframes as well\n\t * as JS animations.\n\t *\n\t * The following example shows a simple way to utilize CSS transitions to style a form element\n\t * that has been rendered as invalid after it has been validated:\n\t *\n\t *
\n\t * //be sure to include ngAnimate as a module to hook into more\n\t * //advanced animations\n\t * .my-form {\n\t *   transition:0.5s linear all;\n\t *   background: white;\n\t * }\n\t * .my-form.ng-invalid {\n\t *   background: red;\n\t *   color:white;\n\t * }\n\t * 
\n\t *\n\t * @example\n\t \n\t \n\t \n\t \n\t \n\t userType: \n\t Required!
\n\t userType = {{userType}}
\n\t myForm.input.$valid = {{myForm.input.$valid}}
\n\t myForm.input.$error = {{myForm.input.$error}}
\n\t myForm.$valid = {{myForm.$valid}}
\n\t myForm.$error.required = {{!!myForm.$error.required}}
\n\t \n\t
\n\t \n\t it('should initialize to model', function() {\n\t var userType = element(by.binding('userType'));\n\t var valid = element(by.binding('myForm.input.$valid'));\n\t\n\t expect(userType.getText()).toContain('guest');\n\t expect(valid.getText()).toContain('true');\n\t });\n\t\n\t it('should be invalid if empty', function() {\n\t var userType = element(by.binding('userType'));\n\t var valid = element(by.binding('myForm.input.$valid'));\n\t var userInput = element(by.model('userType'));\n\t\n\t userInput.clear();\n\t userInput.sendKeys('');\n\t\n\t expect(userType.getText()).toEqual('userType =');\n\t expect(valid.getText()).toContain('false');\n\t });\n\t \n\t
\n\t *\n\t * @param {string=} name Name of the form. If specified, the form controller will be published into\n\t * related scope, under this name.\n\t */\n\tvar formDirectiveFactory = function(isNgForm) {\n\t return ['$timeout', '$parse', function($timeout, $parse) {\n\t var formDirective = {\n\t name: 'form',\n\t restrict: isNgForm ? 'EAC' : 'E',\n\t require: ['form', '^^?form'], //first is the form's own ctrl, second is an optional parent form\n\t controller: FormController,\n\t compile: function ngFormCompile(formElement, attr) {\n\t // Setup initial state of the control\n\t formElement.addClass(PRISTINE_CLASS).addClass(VALID_CLASS);\n\t\n\t var nameAttr = attr.name ? 'name' : (isNgForm && attr.ngForm ? 'ngForm' : false);\n\t\n\t return {\n\t pre: function ngFormPreLink(scope, formElement, attr, ctrls) {\n\t var controller = ctrls[0];\n\t\n\t // if `action` attr is not present on the form, prevent the default action (submission)\n\t if (!('action' in attr)) {\n\t // we can't use jq events because if a form is destroyed during submission the default\n\t // action is not prevented. see #1238\n\t //\n\t // IE 9 is not affected because it doesn't fire a submit event and try to do a full\n\t // page reload if the form was destroyed by submission of the form via a click handler\n\t // on a button in the form. Looks like an IE9 specific bug.\n\t var handleFormSubmission = function(event) {\n\t scope.$apply(function() {\n\t controller.$commitViewValue();\n\t controller.$setSubmitted();\n\t });\n\t\n\t event.preventDefault();\n\t };\n\t\n\t addEventListenerFn(formElement[0], 'submit', handleFormSubmission);\n\t\n\t // unregister the preventDefault listener so that we don't not leak memory but in a\n\t // way that will achieve the prevention of the default action.\n\t formElement.on('$destroy', function() {\n\t $timeout(function() {\n\t removeEventListenerFn(formElement[0], 'submit', handleFormSubmission);\n\t }, 0, false);\n\t });\n\t }\n\t\n\t var parentFormCtrl = ctrls[1] || controller.$$parentForm;\n\t parentFormCtrl.$addControl(controller);\n\t\n\t var setter = nameAttr ? getSetter(controller.$name) : noop;\n\t\n\t if (nameAttr) {\n\t setter(scope, controller);\n\t attr.$observe(nameAttr, function(newValue) {\n\t if (controller.$name === newValue) return;\n\t setter(scope, undefined);\n\t controller.$$parentForm.$$renameControl(controller, newValue);\n\t setter = getSetter(controller.$name);\n\t setter(scope, controller);\n\t });\n\t }\n\t formElement.on('$destroy', function() {\n\t controller.$$parentForm.$removeControl(controller);\n\t setter(scope, undefined);\n\t extend(controller, nullFormCtrl); //stop propagating child destruction handlers upwards\n\t });\n\t }\n\t };\n\t }\n\t };\n\t\n\t return formDirective;\n\t\n\t function getSetter(expression) {\n\t if (expression === '') {\n\t //create an assignable expression, so forms with an empty name can be renamed later\n\t return $parse('this[\"\"]').assign;\n\t }\n\t return $parse(expression).assign || noop;\n\t }\n\t }];\n\t};\n\t\n\tvar formDirective = formDirectiveFactory();\n\tvar ngFormDirective = formDirectiveFactory(true);\n\t\n\t/* global VALID_CLASS: false,\n\t INVALID_CLASS: false,\n\t PRISTINE_CLASS: false,\n\t DIRTY_CLASS: false,\n\t UNTOUCHED_CLASS: false,\n\t TOUCHED_CLASS: false,\n\t ngModelMinErr: false,\n\t*/\n\t\n\t// Regex code is obtained from SO: https://stackoverflow.com/questions/3143070/javascript-regex-iso-datetime#answer-3143231\n\tvar ISO_DATE_REGEXP = /\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d\\.\\d+([+-][0-2]\\d:[0-5]\\d|Z)/;\n\t// See valid URLs in RFC3987 (http://tools.ietf.org/html/rfc3987)\n\t// Note: We are being more lenient, because browsers are too.\n\t// 1. Scheme\n\t// 2. Slashes\n\t// 3. Username\n\t// 4. Password\n\t// 5. Hostname\n\t// 6. Port\n\t// 7. Path\n\t// 8. Query\n\t// 9. Fragment\n\t// 1111111111111111 222 333333 44444 555555555555555555555555 666 77777777 8888888 999\n\tvar URL_REGEXP = /^[a-z][a-z\\d.+-]*:\\/*(?:[^:@]+(?::[^@]+)?@)?(?:[^\\s:/?#]+|\\[[a-f\\d:]+\\])(?::\\d+)?(?:\\/[^?#]*)?(?:\\?[^#]*)?(?:#.*)?$/i;\n\tvar EMAIL_REGEXP = /^[a-z0-9!#$%&'*+\\/=?^_`{|}~.-]+@[a-z0-9]([a-z0-9-]*[a-z0-9])?(\\.[a-z0-9]([a-z0-9-]*[a-z0-9])?)*$/i;\n\tvar NUMBER_REGEXP = /^\\s*(\\-|\\+)?(\\d+|(\\d*(\\.\\d*)))([eE][+-]?\\d+)?\\s*$/;\n\tvar DATE_REGEXP = /^(\\d{4})-(\\d{2})-(\\d{2})$/;\n\tvar DATETIMELOCAL_REGEXP = /^(\\d{4})-(\\d\\d)-(\\d\\d)T(\\d\\d):(\\d\\d)(?::(\\d\\d)(\\.\\d{1,3})?)?$/;\n\tvar WEEK_REGEXP = /^(\\d{4})-W(\\d\\d)$/;\n\tvar MONTH_REGEXP = /^(\\d{4})-(\\d\\d)$/;\n\tvar TIME_REGEXP = /^(\\d\\d):(\\d\\d)(?::(\\d\\d)(\\.\\d{1,3})?)?$/;\n\t\n\tvar PARTIAL_VALIDATION_EVENTS = 'keydown wheel mousedown';\n\tvar PARTIAL_VALIDATION_TYPES = createMap();\n\tforEach('date,datetime-local,month,time,week'.split(','), function(type) {\n\t PARTIAL_VALIDATION_TYPES[type] = true;\n\t});\n\t\n\tvar inputType = {\n\t\n\t /**\n\t * @ngdoc input\n\t * @name input[text]\n\t *\n\t * @description\n\t * Standard HTML text input with angular data binding, inherited by most of the `input` elements.\n\t *\n\t *\n\t * @param {string} ngModel Assignable angular expression to data-bind to.\n\t * @param {string=} name Property name of the form under which the control is published.\n\t * @param {string=} required Adds `required` validation error key if the value is not entered.\n\t * @param {string=} ngRequired Adds `required` attribute and `required` validation constraint to\n\t * the element when the ngRequired expression evaluates to true. Use `ngRequired` instead of\n\t * `required` when you want to data-bind to the `required` attribute.\n\t * @param {number=} ngMinlength Sets `minlength` validation error key if the value is shorter than\n\t * minlength.\n\t * @param {number=} ngMaxlength Sets `maxlength` validation error key if the value is longer than\n\t * maxlength. Setting the attribute to a negative or non-numeric value, allows view values of\n\t * any length.\n\t * @param {string=} pattern Similar to `ngPattern` except that the attribute value is the actual string\n\t * that contains the regular expression body that will be converted to a regular expression\n\t * as in the ngPattern directive.\n\t * @param {string=} ngPattern Sets `pattern` validation error key if the ngModel value does not match\n\t * a RegExp found by evaluating the Angular expression given in the attribute value.\n\t * If the expression evaluates to a RegExp object, then this is used directly.\n\t * If the expression evaluates to a string, then it will be converted to a RegExp\n\t * after wrapping it in `^` and `$` characters. For instance, `\"abc\"` will be converted to\n\t * `new RegExp('^abc$')`.
\n\t * **Note:** Avoid using the `g` flag on the RegExp, as it will cause each successive search to\n\t * start at the index of the last search's match, thus not taking the whole input value into\n\t * account.\n\t * @param {string=} ngChange Angular expression to be executed when input changes due to user\n\t * interaction with the input element.\n\t * @param {boolean=} [ngTrim=true] If set to false Angular will not automatically trim the input.\n\t * This parameter is ignored for input[type=password] controls, which will never trim the\n\t * input.\n\t *\n\t * @example\n\t \n\t \n\t \n\t
\n\t \n\t
\n\t \n\t Required!\n\t \n\t Single word only!\n\t
\n\t text = {{example.text}}
\n\t myForm.input.$valid = {{myForm.input.$valid}}
\n\t myForm.input.$error = {{myForm.input.$error}}
\n\t myForm.$valid = {{myForm.$valid}}
\n\t myForm.$error.required = {{!!myForm.$error.required}}
\n\t
\n\t
\n\t \n\t var text = element(by.binding('example.text'));\n\t var valid = element(by.binding('myForm.input.$valid'));\n\t var input = element(by.model('example.text'));\n\t\n\t it('should initialize to model', function() {\n\t expect(text.getText()).toContain('guest');\n\t expect(valid.getText()).toContain('true');\n\t });\n\t\n\t it('should be invalid if empty', function() {\n\t input.clear();\n\t input.sendKeys('');\n\t\n\t expect(text.getText()).toEqual('text =');\n\t expect(valid.getText()).toContain('false');\n\t });\n\t\n\t it('should be invalid if multi word', function() {\n\t input.clear();\n\t input.sendKeys('hello world');\n\t\n\t expect(valid.getText()).toContain('false');\n\t });\n\t \n\t
\n\t */\n\t 'text': textInputType,\n\t\n\t /**\n\t * @ngdoc input\n\t * @name input[date]\n\t *\n\t * @description\n\t * Input with date validation and transformation. In browsers that do not yet support\n\t * the HTML5 date input, a text element will be used. In that case, text must be entered in a valid ISO-8601\n\t * date format (yyyy-MM-dd), for example: `2009-01-06`. Since many\n\t * modern browsers do not yet support this input type, it is important to provide cues to users on the\n\t * expected input format via a placeholder or label.\n\t *\n\t * The model must always be a Date object, otherwise Angular will throw an error.\n\t * Invalid `Date` objects (dates whose `getTime()` is `NaN`) will be rendered as an empty string.\n\t *\n\t * The timezone to be used to read/write the `Date` instance in the model can be defined using\n\t * {@link ng.directive:ngModelOptions ngModelOptions}. By default, this is the timezone of the browser.\n\t *\n\t * @param {string} ngModel Assignable angular expression to data-bind to.\n\t * @param {string=} name Property name of the form under which the control is published.\n\t * @param {string=} min Sets the `min` validation error key if the value entered is less than `min`. This must be a\n\t * valid ISO date string (yyyy-MM-dd). You can also use interpolation inside this attribute\n\t * (e.g. `min=\"{{minDate | date:'yyyy-MM-dd'}}\"`). Note that `min` will also add native HTML5\n\t * constraint validation.\n\t * @param {string=} max Sets the `max` validation error key if the value entered is greater than `max`. This must be\n\t * a valid ISO date string (yyyy-MM-dd). You can also use interpolation inside this attribute\n\t * (e.g. `max=\"{{maxDate | date:'yyyy-MM-dd'}}\"`). Note that `max` will also add native HTML5\n\t * constraint validation.\n\t * @param {(date|string)=} ngMin Sets the `min` validation constraint to the Date / ISO date string\n\t * the `ngMin` expression evaluates to. Note that it does not set the `min` attribute.\n\t * @param {(date|string)=} ngMax Sets the `max` validation constraint to the Date / ISO date string\n\t * the `ngMax` expression evaluates to. Note that it does not set the `max` attribute.\n\t * @param {string=} required Sets `required` validation error key if the value is not entered.\n\t * @param {string=} ngRequired Adds `required` attribute and `required` validation constraint to\n\t * the element when the ngRequired expression evaluates to true. Use `ngRequired` instead of\n\t * `required` when you want to data-bind to the `required` attribute.\n\t * @param {string=} ngChange Angular expression to be executed when input changes due to user\n\t * interaction with the input element.\n\t *\n\t * @example\n\t \n\t \n\t \n\t
\n\t \n\t \n\t
\n\t \n\t Required!\n\t \n\t Not a valid date!\n\t
\n\t value = {{example.value | date: \"yyyy-MM-dd\"}}
\n\t myForm.input.$valid = {{myForm.input.$valid}}
\n\t myForm.input.$error = {{myForm.input.$error}}
\n\t myForm.$valid = {{myForm.$valid}}
\n\t myForm.$error.required = {{!!myForm.$error.required}}
\n\t
\n\t
\n\t \n\t var value = element(by.binding('example.value | date: \"yyyy-MM-dd\"'));\n\t var valid = element(by.binding('myForm.input.$valid'));\n\t var input = element(by.model('example.value'));\n\t\n\t // currently protractor/webdriver does not support\n\t // sending keys to all known HTML5 input controls\n\t // for various browsers (see https://github.com/angular/protractor/issues/562).\n\t function setInput(val) {\n\t // set the value of the element and force validation.\n\t var scr = \"var ipt = document.getElementById('exampleInput'); \" +\n\t \"ipt.value = '\" + val + \"';\" +\n\t \"angular.element(ipt).scope().$apply(function(s) { s.myForm[ipt.name].$setViewValue('\" + val + \"'); });\";\n\t browser.executeScript(scr);\n\t }\n\t\n\t it('should initialize to model', function() {\n\t expect(value.getText()).toContain('2013-10-22');\n\t expect(valid.getText()).toContain('myForm.input.$valid = true');\n\t });\n\t\n\t it('should be invalid if empty', function() {\n\t setInput('');\n\t expect(value.getText()).toEqual('value =');\n\t expect(valid.getText()).toContain('myForm.input.$valid = false');\n\t });\n\t\n\t it('should be invalid if over max', function() {\n\t setInput('2015-01-01');\n\t expect(value.getText()).toContain('');\n\t expect(valid.getText()).toContain('myForm.input.$valid = false');\n\t });\n\t \n\t
\n\t */\n\t 'date': createDateInputType('date', DATE_REGEXP,\n\t createDateParser(DATE_REGEXP, ['yyyy', 'MM', 'dd']),\n\t 'yyyy-MM-dd'),\n\t\n\t /**\n\t * @ngdoc input\n\t * @name input[datetime-local]\n\t *\n\t * @description\n\t * Input with datetime validation and transformation. In browsers that do not yet support\n\t * the HTML5 date input, a text element will be used. In that case, the text must be entered in a valid ISO-8601\n\t * local datetime format (yyyy-MM-ddTHH:mm:ss), for example: `2010-12-28T14:57:00`.\n\t *\n\t * The model must always be a Date object, otherwise Angular will throw an error.\n\t * Invalid `Date` objects (dates whose `getTime()` is `NaN`) will be rendered as an empty string.\n\t *\n\t * The timezone to be used to read/write the `Date` instance in the model can be defined using\n\t * {@link ng.directive:ngModelOptions ngModelOptions}. By default, this is the timezone of the browser.\n\t *\n\t * @param {string} ngModel Assignable angular expression to data-bind to.\n\t * @param {string=} name Property name of the form under which the control is published.\n\t * @param {string=} min Sets the `min` validation error key if the value entered is less than `min`.\n\t * This must be a valid ISO datetime format (yyyy-MM-ddTHH:mm:ss). You can also use interpolation\n\t * inside this attribute (e.g. `min=\"{{minDatetimeLocal | date:'yyyy-MM-ddTHH:mm:ss'}}\"`).\n\t * Note that `min` will also add native HTML5 constraint validation.\n\t * @param {string=} max Sets the `max` validation error key if the value entered is greater than `max`.\n\t * This must be a valid ISO datetime format (yyyy-MM-ddTHH:mm:ss). You can also use interpolation\n\t * inside this attribute (e.g. `max=\"{{maxDatetimeLocal | date:'yyyy-MM-ddTHH:mm:ss'}}\"`).\n\t * Note that `max` will also add native HTML5 constraint validation.\n\t * @param {(date|string)=} ngMin Sets the `min` validation error key to the Date / ISO datetime string\n\t * the `ngMin` expression evaluates to. Note that it does not set the `min` attribute.\n\t * @param {(date|string)=} ngMax Sets the `max` validation error key to the Date / ISO datetime string\n\t * the `ngMax` expression evaluates to. Note that it does not set the `max` attribute.\n\t * @param {string=} required Sets `required` validation error key if the value is not entered.\n\t * @param {string=} ngRequired Adds `required` attribute and `required` validation constraint to\n\t * the element when the ngRequired expression evaluates to true. Use `ngRequired` instead of\n\t * `required` when you want to data-bind to the `required` attribute.\n\t * @param {string=} ngChange Angular expression to be executed when input changes due to user\n\t * interaction with the input element.\n\t *\n\t * @example\n\t \n\t \n\t \n\t
\n\t \n\t \n\t
\n\t \n\t Required!\n\t \n\t Not a valid date!\n\t
\n\t value = {{example.value | date: \"yyyy-MM-ddTHH:mm:ss\"}}
\n\t myForm.input.$valid = {{myForm.input.$valid}}
\n\t myForm.input.$error = {{myForm.input.$error}}
\n\t myForm.$valid = {{myForm.$valid}}
\n\t myForm.$error.required = {{!!myForm.$error.required}}
\n\t
\n\t
\n\t \n\t var value = element(by.binding('example.value | date: \"yyyy-MM-ddTHH:mm:ss\"'));\n\t var valid = element(by.binding('myForm.input.$valid'));\n\t var input = element(by.model('example.value'));\n\t\n\t // currently protractor/webdriver does not support\n\t // sending keys to all known HTML5 input controls\n\t // for various browsers (https://github.com/angular/protractor/issues/562).\n\t function setInput(val) {\n\t // set the value of the element and force validation.\n\t var scr = \"var ipt = document.getElementById('exampleInput'); \" +\n\t \"ipt.value = '\" + val + \"';\" +\n\t \"angular.element(ipt).scope().$apply(function(s) { s.myForm[ipt.name].$setViewValue('\" + val + \"'); });\";\n\t browser.executeScript(scr);\n\t }\n\t\n\t it('should initialize to model', function() {\n\t expect(value.getText()).toContain('2010-12-28T14:57:00');\n\t expect(valid.getText()).toContain('myForm.input.$valid = true');\n\t });\n\t\n\t it('should be invalid if empty', function() {\n\t setInput('');\n\t expect(value.getText()).toEqual('value =');\n\t expect(valid.getText()).toContain('myForm.input.$valid = false');\n\t });\n\t\n\t it('should be invalid if over max', function() {\n\t setInput('2015-01-01T23:59:00');\n\t expect(value.getText()).toContain('');\n\t expect(valid.getText()).toContain('myForm.input.$valid = false');\n\t });\n\t \n\t
\n\t */\n\t 'datetime-local': createDateInputType('datetimelocal', DATETIMELOCAL_REGEXP,\n\t createDateParser(DATETIMELOCAL_REGEXP, ['yyyy', 'MM', 'dd', 'HH', 'mm', 'ss', 'sss']),\n\t 'yyyy-MM-ddTHH:mm:ss.sss'),\n\t\n\t /**\n\t * @ngdoc input\n\t * @name input[time]\n\t *\n\t * @description\n\t * Input with time validation and transformation. In browsers that do not yet support\n\t * the HTML5 date input, a text element will be used. In that case, the text must be entered in a valid ISO-8601\n\t * local time format (HH:mm:ss), for example: `14:57:00`. Model must be a Date object. This binding will always output a\n\t * Date object to the model of January 1, 1970, or local date `new Date(1970, 0, 1, HH, mm, ss)`.\n\t *\n\t * The model must always be a Date object, otherwise Angular will throw an error.\n\t * Invalid `Date` objects (dates whose `getTime()` is `NaN`) will be rendered as an empty string.\n\t *\n\t * The timezone to be used to read/write the `Date` instance in the model can be defined using\n\t * {@link ng.directive:ngModelOptions ngModelOptions}. By default, this is the timezone of the browser.\n\t *\n\t * @param {string} ngModel Assignable angular expression to data-bind to.\n\t * @param {string=} name Property name of the form under which the control is published.\n\t * @param {string=} min Sets the `min` validation error key if the value entered is less than `min`.\n\t * This must be a valid ISO time format (HH:mm:ss). You can also use interpolation inside this\n\t * attribute (e.g. `min=\"{{minTime | date:'HH:mm:ss'}}\"`). Note that `min` will also add\n\t * native HTML5 constraint validation.\n\t * @param {string=} max Sets the `max` validation error key if the value entered is greater than `max`.\n\t * This must be a valid ISO time format (HH:mm:ss). You can also use interpolation inside this\n\t * attribute (e.g. `max=\"{{maxTime | date:'HH:mm:ss'}}\"`). Note that `max` will also add\n\t * native HTML5 constraint validation.\n\t * @param {(date|string)=} ngMin Sets the `min` validation constraint to the Date / ISO time string the\n\t * `ngMin` expression evaluates to. Note that it does not set the `min` attribute.\n\t * @param {(date|string)=} ngMax Sets the `max` validation constraint to the Date / ISO time string the\n\t * `ngMax` expression evaluates to. Note that it does not set the `max` attribute.\n\t * @param {string=} required Sets `required` validation error key if the value is not entered.\n\t * @param {string=} ngRequired Adds `required` attribute and `required` validation constraint to\n\t * the element when the ngRequired expression evaluates to true. Use `ngRequired` instead of\n\t * `required` when you want to data-bind to the `required` attribute.\n\t * @param {string=} ngChange Angular expression to be executed when input changes due to user\n\t * interaction with the input element.\n\t *\n\t * @example\n\t \n\t \n\t \n\t
\n\t \n\t \n\t
\n\t \n\t Required!\n\t \n\t Not a valid date!\n\t
\n\t value = {{example.value | date: \"HH:mm:ss\"}}
\n\t myForm.input.$valid = {{myForm.input.$valid}}
\n\t myForm.input.$error = {{myForm.input.$error}}
\n\t myForm.$valid = {{myForm.$valid}}
\n\t myForm.$error.required = {{!!myForm.$error.required}}
\n\t
\n\t
\n\t \n\t var value = element(by.binding('example.value | date: \"HH:mm:ss\"'));\n\t var valid = element(by.binding('myForm.input.$valid'));\n\t var input = element(by.model('example.value'));\n\t\n\t // currently protractor/webdriver does not support\n\t // sending keys to all known HTML5 input controls\n\t // for various browsers (https://github.com/angular/protractor/issues/562).\n\t function setInput(val) {\n\t // set the value of the element and force validation.\n\t var scr = \"var ipt = document.getElementById('exampleInput'); \" +\n\t \"ipt.value = '\" + val + \"';\" +\n\t \"angular.element(ipt).scope().$apply(function(s) { s.myForm[ipt.name].$setViewValue('\" + val + \"'); });\";\n\t browser.executeScript(scr);\n\t }\n\t\n\t it('should initialize to model', function() {\n\t expect(value.getText()).toContain('14:57:00');\n\t expect(valid.getText()).toContain('myForm.input.$valid = true');\n\t });\n\t\n\t it('should be invalid if empty', function() {\n\t setInput('');\n\t expect(value.getText()).toEqual('value =');\n\t expect(valid.getText()).toContain('myForm.input.$valid = false');\n\t });\n\t\n\t it('should be invalid if over max', function() {\n\t setInput('23:59:00');\n\t expect(value.getText()).toContain('');\n\t expect(valid.getText()).toContain('myForm.input.$valid = false');\n\t });\n\t \n\t
\n\t */\n\t 'time': createDateInputType('time', TIME_REGEXP,\n\t createDateParser(TIME_REGEXP, ['HH', 'mm', 'ss', 'sss']),\n\t 'HH:mm:ss.sss'),\n\t\n\t /**\n\t * @ngdoc input\n\t * @name input[week]\n\t *\n\t * @description\n\t * Input with week-of-the-year validation and transformation to Date. In browsers that do not yet support\n\t * the HTML5 week input, a text element will be used. In that case, the text must be entered in a valid ISO-8601\n\t * week format (yyyy-W##), for example: `2013-W02`.\n\t *\n\t * The model must always be a Date object, otherwise Angular will throw an error.\n\t * Invalid `Date` objects (dates whose `getTime()` is `NaN`) will be rendered as an empty string.\n\t *\n\t * The timezone to be used to read/write the `Date` instance in the model can be defined using\n\t * {@link ng.directive:ngModelOptions ngModelOptions}. By default, this is the timezone of the browser.\n\t *\n\t * @param {string} ngModel Assignable angular expression to data-bind to.\n\t * @param {string=} name Property name of the form under which the control is published.\n\t * @param {string=} min Sets the `min` validation error key if the value entered is less than `min`.\n\t * This must be a valid ISO week format (yyyy-W##). You can also use interpolation inside this\n\t * attribute (e.g. `min=\"{{minWeek | date:'yyyy-Www'}}\"`). Note that `min` will also add\n\t * native HTML5 constraint validation.\n\t * @param {string=} max Sets the `max` validation error key if the value entered is greater than `max`.\n\t * This must be a valid ISO week format (yyyy-W##). You can also use interpolation inside this\n\t * attribute (e.g. `max=\"{{maxWeek | date:'yyyy-Www'}}\"`). Note that `max` will also add\n\t * native HTML5 constraint validation.\n\t * @param {(date|string)=} ngMin Sets the `min` validation constraint to the Date / ISO week string\n\t * the `ngMin` expression evaluates to. Note that it does not set the `min` attribute.\n\t * @param {(date|string)=} ngMax Sets the `max` validation constraint to the Date / ISO week string\n\t * the `ngMax` expression evaluates to. Note that it does not set the `max` attribute.\n\t * @param {string=} required Sets `required` validation error key if the value is not entered.\n\t * @param {string=} ngRequired Adds `required` attribute and `required` validation constraint to\n\t * the element when the ngRequired expression evaluates to true. Use `ngRequired` instead of\n\t * `required` when you want to data-bind to the `required` attribute.\n\t * @param {string=} ngChange Angular expression to be executed when input changes due to user\n\t * interaction with the input element.\n\t *\n\t * @example\n\t \n\t \n\t \n\t
\n\t \n\t
\n\t \n\t Required!\n\t \n\t Not a valid date!\n\t
\n\t value = {{example.value | date: \"yyyy-Www\"}}
\n\t myForm.input.$valid = {{myForm.input.$valid}}
\n\t myForm.input.$error = {{myForm.input.$error}}
\n\t myForm.$valid = {{myForm.$valid}}
\n\t myForm.$error.required = {{!!myForm.$error.required}}
\n\t
\n\t
\n\t \n\t var value = element(by.binding('example.value | date: \"yyyy-Www\"'));\n\t var valid = element(by.binding('myForm.input.$valid'));\n\t var input = element(by.model('example.value'));\n\t\n\t // currently protractor/webdriver does not support\n\t // sending keys to all known HTML5 input controls\n\t // for various browsers (https://github.com/angular/protractor/issues/562).\n\t function setInput(val) {\n\t // set the value of the element and force validation.\n\t var scr = \"var ipt = document.getElementById('exampleInput'); \" +\n\t \"ipt.value = '\" + val + \"';\" +\n\t \"angular.element(ipt).scope().$apply(function(s) { s.myForm[ipt.name].$setViewValue('\" + val + \"'); });\";\n\t browser.executeScript(scr);\n\t }\n\t\n\t it('should initialize to model', function() {\n\t expect(value.getText()).toContain('2013-W01');\n\t expect(valid.getText()).toContain('myForm.input.$valid = true');\n\t });\n\t\n\t it('should be invalid if empty', function() {\n\t setInput('');\n\t expect(value.getText()).toEqual('value =');\n\t expect(valid.getText()).toContain('myForm.input.$valid = false');\n\t });\n\t\n\t it('should be invalid if over max', function() {\n\t setInput('2015-W01');\n\t expect(value.getText()).toContain('');\n\t expect(valid.getText()).toContain('myForm.input.$valid = false');\n\t });\n\t \n\t
\n\t */\n\t 'week': createDateInputType('week', WEEK_REGEXP, weekParser, 'yyyy-Www'),\n\t\n\t /**\n\t * @ngdoc input\n\t * @name input[month]\n\t *\n\t * @description\n\t * Input with month validation and transformation. In browsers that do not yet support\n\t * the HTML5 month input, a text element will be used. In that case, the text must be entered in a valid ISO-8601\n\t * month format (yyyy-MM), for example: `2009-01`.\n\t *\n\t * The model must always be a Date object, otherwise Angular will throw an error.\n\t * Invalid `Date` objects (dates whose `getTime()` is `NaN`) will be rendered as an empty string.\n\t * If the model is not set to the first of the month, the next view to model update will set it\n\t * to the first of the month.\n\t *\n\t * The timezone to be used to read/write the `Date` instance in the model can be defined using\n\t * {@link ng.directive:ngModelOptions ngModelOptions}. By default, this is the timezone of the browser.\n\t *\n\t * @param {string} ngModel Assignable angular expression to data-bind to.\n\t * @param {string=} name Property name of the form under which the control is published.\n\t * @param {string=} min Sets the `min` validation error key if the value entered is less than `min`.\n\t * This must be a valid ISO month format (yyyy-MM). You can also use interpolation inside this\n\t * attribute (e.g. `min=\"{{minMonth | date:'yyyy-MM'}}\"`). Note that `min` will also add\n\t * native HTML5 constraint validation.\n\t * @param {string=} max Sets the `max` validation error key if the value entered is greater than `max`.\n\t * This must be a valid ISO month format (yyyy-MM). You can also use interpolation inside this\n\t * attribute (e.g. `max=\"{{maxMonth | date:'yyyy-MM'}}\"`). Note that `max` will also add\n\t * native HTML5 constraint validation.\n\t * @param {(date|string)=} ngMin Sets the `min` validation constraint to the Date / ISO week string\n\t * the `ngMin` expression evaluates to. Note that it does not set the `min` attribute.\n\t * @param {(date|string)=} ngMax Sets the `max` validation constraint to the Date / ISO week string\n\t * the `ngMax` expression evaluates to. Note that it does not set the `max` attribute.\n\t\n\t * @param {string=} required Sets `required` validation error key if the value is not entered.\n\t * @param {string=} ngRequired Adds `required` attribute and `required` validation constraint to\n\t * the element when the ngRequired expression evaluates to true. Use `ngRequired` instead of\n\t * `required` when you want to data-bind to the `required` attribute.\n\t * @param {string=} ngChange Angular expression to be executed when input changes due to user\n\t * interaction with the input element.\n\t *\n\t * @example\n\t \n\t \n\t \n\t
\n\t \n\t \n\t
\n\t \n\t Required!\n\t \n\t Not a valid month!\n\t
\n\t value = {{example.value | date: \"yyyy-MM\"}}
\n\t myForm.input.$valid = {{myForm.input.$valid}}
\n\t myForm.input.$error = {{myForm.input.$error}}
\n\t myForm.$valid = {{myForm.$valid}}
\n\t myForm.$error.required = {{!!myForm.$error.required}}
\n\t
\n\t
\n\t \n\t var value = element(by.binding('example.value | date: \"yyyy-MM\"'));\n\t var valid = element(by.binding('myForm.input.$valid'));\n\t var input = element(by.model('example.value'));\n\t\n\t // currently protractor/webdriver does not support\n\t // sending keys to all known HTML5 input controls\n\t // for various browsers (https://github.com/angular/protractor/issues/562).\n\t function setInput(val) {\n\t // set the value of the element and force validation.\n\t var scr = \"var ipt = document.getElementById('exampleInput'); \" +\n\t \"ipt.value = '\" + val + \"';\" +\n\t \"angular.element(ipt).scope().$apply(function(s) { s.myForm[ipt.name].$setViewValue('\" + val + \"'); });\";\n\t browser.executeScript(scr);\n\t }\n\t\n\t it('should initialize to model', function() {\n\t expect(value.getText()).toContain('2013-10');\n\t expect(valid.getText()).toContain('myForm.input.$valid = true');\n\t });\n\t\n\t it('should be invalid if empty', function() {\n\t setInput('');\n\t expect(value.getText()).toEqual('value =');\n\t expect(valid.getText()).toContain('myForm.input.$valid = false');\n\t });\n\t\n\t it('should be invalid if over max', function() {\n\t setInput('2015-01');\n\t expect(value.getText()).toContain('');\n\t expect(valid.getText()).toContain('myForm.input.$valid = false');\n\t });\n\t \n\t
\n\t */\n\t 'month': createDateInputType('month', MONTH_REGEXP,\n\t createDateParser(MONTH_REGEXP, ['yyyy', 'MM']),\n\t 'yyyy-MM'),\n\t\n\t /**\n\t * @ngdoc input\n\t * @name input[number]\n\t *\n\t * @description\n\t * Text input with number validation and transformation. Sets the `number` validation\n\t * error if not a valid number.\n\t *\n\t *
\n\t * The model must always be of type `number` otherwise Angular will throw an error.\n\t * Be aware that a string containing a number is not enough. See the {@link ngModel:numfmt}\n\t * error docs for more information and an example of how to convert your model if necessary.\n\t *
\n\t *\n\t * ## Issues with HTML5 constraint validation\n\t *\n\t * In browsers that follow the\n\t * [HTML5 specification](https://html.spec.whatwg.org/multipage/forms.html#number-state-%28type=number%29),\n\t * `input[number]` does not work as expected with {@link ngModelOptions `ngModelOptions.allowInvalid`}.\n\t * If a non-number is entered in the input, the browser will report the value as an empty string,\n\t * which means the view / model values in `ngModel` and subsequently the scope value\n\t * will also be an empty string.\n\t *\n\t *\n\t * @param {string} ngModel Assignable angular expression to data-bind to.\n\t * @param {string=} name Property name of the form under which the control is published.\n\t * @param {string=} min Sets the `min` validation error key if the value entered is less than `min`.\n\t * @param {string=} max Sets the `max` validation error key if the value entered is greater than `max`.\n\t * @param {string=} required Sets `required` validation error key if the value is not entered.\n\t * @param {string=} ngRequired Adds `required` attribute and `required` validation constraint to\n\t * the element when the ngRequired expression evaluates to true. Use `ngRequired` instead of\n\t * `required` when you want to data-bind to the `required` attribute.\n\t * @param {number=} ngMinlength Sets `minlength` validation error key if the value is shorter than\n\t * minlength.\n\t * @param {number=} ngMaxlength Sets `maxlength` validation error key if the value is longer than\n\t * maxlength. Setting the attribute to a negative or non-numeric value, allows view values of\n\t * any length.\n\t * @param {string=} pattern Similar to `ngPattern` except that the attribute value is the actual string\n\t * that contains the regular expression body that will be converted to a regular expression\n\t * as in the ngPattern directive.\n\t * @param {string=} ngPattern Sets `pattern` validation error key if the ngModel value does not match\n\t * a RegExp found by evaluating the Angular expression given in the attribute value.\n\t * If the expression evaluates to a RegExp object, then this is used directly.\n\t * If the expression evaluates to a string, then it will be converted to a RegExp\n\t * after wrapping it in `^` and `$` characters. For instance, `\"abc\"` will be converted to\n\t * `new RegExp('^abc$')`.
\n\t * **Note:** Avoid using the `g` flag on the RegExp, as it will cause each successive search to\n\t * start at the index of the last search's match, thus not taking the whole input value into\n\t * account.\n\t * @param {string=} ngChange Angular expression to be executed when input changes due to user\n\t * interaction with the input element.\n\t *\n\t * @example\n\t \n\t \n\t \n\t
\n\t \n\t
\n\t \n\t Required!\n\t \n\t Not valid number!\n\t
\n\t value = {{example.value}}
\n\t myForm.input.$valid = {{myForm.input.$valid}}
\n\t myForm.input.$error = {{myForm.input.$error}}
\n\t myForm.$valid = {{myForm.$valid}}
\n\t myForm.$error.required = {{!!myForm.$error.required}}
\n\t
\n\t
\n\t \n\t var value = element(by.binding('example.value'));\n\t var valid = element(by.binding('myForm.input.$valid'));\n\t var input = element(by.model('example.value'));\n\t\n\t it('should initialize to model', function() {\n\t expect(value.getText()).toContain('12');\n\t expect(valid.getText()).toContain('true');\n\t });\n\t\n\t it('should be invalid if empty', function() {\n\t input.clear();\n\t input.sendKeys('');\n\t expect(value.getText()).toEqual('value =');\n\t expect(valid.getText()).toContain('false');\n\t });\n\t\n\t it('should be invalid if over max', function() {\n\t input.clear();\n\t input.sendKeys('123');\n\t expect(value.getText()).toEqual('value =');\n\t expect(valid.getText()).toContain('false');\n\t });\n\t \n\t
\n\t */\n\t 'number': numberInputType,\n\t\n\t\n\t /**\n\t * @ngdoc input\n\t * @name input[url]\n\t *\n\t * @description\n\t * Text input with URL validation. Sets the `url` validation error key if the content is not a\n\t * valid URL.\n\t *\n\t *
\n\t * **Note:** `input[url]` uses a regex to validate urls that is derived from the regex\n\t * used in Chromium. If you need stricter validation, you can use `ng-pattern` or modify\n\t * the built-in validators (see the {@link guide/forms Forms guide})\n\t *
\n\t *\n\t * @param {string} ngModel Assignable angular expression to data-bind to.\n\t * @param {string=} name Property name of the form under which the control is published.\n\t * @param {string=} required Sets `required` validation error key if the value is not entered.\n\t * @param {string=} ngRequired Adds `required` attribute and `required` validation constraint to\n\t * the element when the ngRequired expression evaluates to true. Use `ngRequired` instead of\n\t * `required` when you want to data-bind to the `required` attribute.\n\t * @param {number=} ngMinlength Sets `minlength` validation error key if the value is shorter than\n\t * minlength.\n\t * @param {number=} ngMaxlength Sets `maxlength` validation error key if the value is longer than\n\t * maxlength. Setting the attribute to a negative or non-numeric value, allows view values of\n\t * any length.\n\t * @param {string=} pattern Similar to `ngPattern` except that the attribute value is the actual string\n\t * that contains the regular expression body that will be converted to a regular expression\n\t * as in the ngPattern directive.\n\t * @param {string=} ngPattern Sets `pattern` validation error key if the ngModel value does not match\n\t * a RegExp found by evaluating the Angular expression given in the attribute value.\n\t * If the expression evaluates to a RegExp object, then this is used directly.\n\t * If the expression evaluates to a string, then it will be converted to a RegExp\n\t * after wrapping it in `^` and `$` characters. For instance, `\"abc\"` will be converted to\n\t * `new RegExp('^abc$')`.
\n\t * **Note:** Avoid using the `g` flag on the RegExp, as it will cause each successive search to\n\t * start at the index of the last search's match, thus not taking the whole input value into\n\t * account.\n\t * @param {string=} ngChange Angular expression to be executed when input changes due to user\n\t * interaction with the input element.\n\t *\n\t * @example\n\t \n\t \n\t \n\t
\n\t
\n\t \n\t var text = element(by.binding('url.text'));\n\t var valid = element(by.binding('myForm.input.$valid'));\n\t var input = element(by.model('url.text'));\n\t\n\t it('should initialize to model', function() {\n\t expect(text.getText()).toContain('http://google.com');\n\t expect(valid.getText()).toContain('true');\n\t });\n\t\n\t it('should be invalid if empty', function() {\n\t input.clear();\n\t input.sendKeys('');\n\t\n\t expect(text.getText()).toEqual('text =');\n\t expect(valid.getText()).toContain('false');\n\t });\n\t\n\t it('should be invalid if not url', function() {\n\t input.clear();\n\t input.sendKeys('box');\n\t\n\t expect(valid.getText()).toContain('false');\n\t });\n\t \n\t
\n\t */\n\t 'url': urlInputType,\n\t\n\t\n\t /**\n\t * @ngdoc input\n\t * @name input[email]\n\t *\n\t * @description\n\t * Text input with email validation. Sets the `email` validation error key if not a valid email\n\t * address.\n\t *\n\t *
\n\t * **Note:** `input[email]` uses a regex to validate email addresses that is derived from the regex\n\t * used in Chromium. If you need stricter validation (e.g. requiring a top-level domain), you can\n\t * use `ng-pattern` or modify the built-in validators (see the {@link guide/forms Forms guide})\n\t *
\n\t *\n\t * @param {string} ngModel Assignable angular expression to data-bind to.\n\t * @param {string=} name Property name of the form under which the control is published.\n\t * @param {string=} required Sets `required` validation error key if the value is not entered.\n\t * @param {string=} ngRequired Adds `required` attribute and `required` validation constraint to\n\t * the element when the ngRequired expression evaluates to true. Use `ngRequired` instead of\n\t * `required` when you want to data-bind to the `required` attribute.\n\t * @param {number=} ngMinlength Sets `minlength` validation error key if the value is shorter than\n\t * minlength.\n\t * @param {number=} ngMaxlength Sets `maxlength` validation error key if the value is longer than\n\t * maxlength. Setting the attribute to a negative or non-numeric value, allows view values of\n\t * any length.\n\t * @param {string=} pattern Similar to `ngPattern` except that the attribute value is the actual string\n\t * that contains the regular expression body that will be converted to a regular expression\n\t * as in the ngPattern directive.\n\t * @param {string=} ngPattern Sets `pattern` validation error key if the ngModel value does not match\n\t * a RegExp found by evaluating the Angular expression given in the attribute value.\n\t * If the expression evaluates to a RegExp object, then this is used directly.\n\t * If the expression evaluates to a string, then it will be converted to a RegExp\n\t * after wrapping it in `^` and `$` characters. For instance, `\"abc\"` will be converted to\n\t * `new RegExp('^abc$')`.
\n\t * **Note:** Avoid using the `g` flag on the RegExp, as it will cause each successive search to\n\t * start at the index of the last search's match, thus not taking the whole input value into\n\t * account.\n\t * @param {string=} ngChange Angular expression to be executed when input changes due to user\n\t * interaction with the input element.\n\t *\n\t * @example\n\t \n\t \n\t \n\t
\n\t \n\t
\n\t \n\t Required!\n\t \n\t Not valid email!\n\t
\n\t text = {{email.text}}
\n\t myForm.input.$valid = {{myForm.input.$valid}}
\n\t myForm.input.$error = {{myForm.input.$error}}
\n\t myForm.$valid = {{myForm.$valid}}
\n\t myForm.$error.required = {{!!myForm.$error.required}}
\n\t myForm.$error.email = {{!!myForm.$error.email}}
\n\t
\n\t
\n\t \n\t var text = element(by.binding('email.text'));\n\t var valid = element(by.binding('myForm.input.$valid'));\n\t var input = element(by.model('email.text'));\n\t\n\t it('should initialize to model', function() {\n\t expect(text.getText()).toContain('me@example.com');\n\t expect(valid.getText()).toContain('true');\n\t });\n\t\n\t it('should be invalid if empty', function() {\n\t input.clear();\n\t input.sendKeys('');\n\t expect(text.getText()).toEqual('text =');\n\t expect(valid.getText()).toContain('false');\n\t });\n\t\n\t it('should be invalid if not email', function() {\n\t input.clear();\n\t input.sendKeys('xxx');\n\t\n\t expect(valid.getText()).toContain('false');\n\t });\n\t \n\t
\n\t */\n\t 'email': emailInputType,\n\t\n\t\n\t /**\n\t * @ngdoc input\n\t * @name input[radio]\n\t *\n\t * @description\n\t * HTML radio button.\n\t *\n\t * @param {string} ngModel Assignable angular expression to data-bind to.\n\t * @param {string} value The value to which the `ngModel` expression should be set when selected.\n\t * Note that `value` only supports `string` values, i.e. the scope model needs to be a string,\n\t * too. Use `ngValue` if you need complex models (`number`, `object`, ...).\n\t * @param {string=} name Property name of the form under which the control is published.\n\t * @param {string=} ngChange Angular expression to be executed when input changes due to user\n\t * interaction with the input element.\n\t * @param {string} ngValue Angular expression to which `ngModel` will be be set when the radio\n\t * is selected. Should be used instead of the `value` attribute if you need\n\t * a non-string `ngModel` (`boolean`, `array`, ...).\n\t *\n\t * @example\n\t \n\t \n\t \n\t
\n\t
\n\t
\n\t
\n\t color = {{color.name | json}}
\n\t
\n\t Note that `ng-value=\"specialValue\"` sets radio item's value to be the value of `$scope.specialValue`.\n\t
\n\t \n\t it('should change state', function() {\n\t var color = element(by.binding('color.name'));\n\t\n\t expect(color.getText()).toContain('blue');\n\t\n\t element.all(by.model('color.name')).get(0).click();\n\t\n\t expect(color.getText()).toContain('red');\n\t });\n\t \n\t
\n\t */\n\t 'radio': radioInputType,\n\t\n\t\n\t /**\n\t * @ngdoc input\n\t * @name input[checkbox]\n\t *\n\t * @description\n\t * HTML checkbox.\n\t *\n\t * @param {string} ngModel Assignable angular expression to data-bind to.\n\t * @param {string=} name Property name of the form under which the control is published.\n\t * @param {expression=} ngTrueValue The value to which the expression should be set when selected.\n\t * @param {expression=} ngFalseValue The value to which the expression should be set when not selected.\n\t * @param {string=} ngChange Angular expression to be executed when input changes due to user\n\t * interaction with the input element.\n\t *\n\t * @example\n\t \n\t \n\t \n\t
\n\t
\n\t
\n\t value1 = {{checkboxModel.value1}}
\n\t value2 = {{checkboxModel.value2}}
\n\t
\n\t
\n\t \n\t it('should change state', function() {\n\t var value1 = element(by.binding('checkboxModel.value1'));\n\t var value2 = element(by.binding('checkboxModel.value2'));\n\t\n\t expect(value1.getText()).toContain('true');\n\t expect(value2.getText()).toContain('YES');\n\t\n\t element(by.model('checkboxModel.value1')).click();\n\t element(by.model('checkboxModel.value2')).click();\n\t\n\t expect(value1.getText()).toContain('false');\n\t expect(value2.getText()).toContain('NO');\n\t });\n\t \n\t
\n\t */\n\t 'checkbox': checkboxInputType,\n\t\n\t 'hidden': noop,\n\t 'button': noop,\n\t 'submit': noop,\n\t 'reset': noop,\n\t 'file': noop\n\t};\n\t\n\tfunction stringBasedInputType(ctrl) {\n\t ctrl.$formatters.push(function(value) {\n\t return ctrl.$isEmpty(value) ? value : value.toString();\n\t });\n\t}\n\t\n\tfunction textInputType(scope, element, attr, ctrl, $sniffer, $browser) {\n\t baseInputType(scope, element, attr, ctrl, $sniffer, $browser);\n\t stringBasedInputType(ctrl);\n\t}\n\t\n\tfunction baseInputType(scope, element, attr, ctrl, $sniffer, $browser) {\n\t var type = lowercase(element[0].type);\n\t\n\t // In composition mode, users are still inputing intermediate text buffer,\n\t // hold the listener until composition is done.\n\t // More about composition events: https://developer.mozilla.org/en-US/docs/Web/API/CompositionEvent\n\t if (!$sniffer.android) {\n\t var composing = false;\n\t\n\t element.on('compositionstart', function(data) {\n\t composing = true;\n\t });\n\t\n\t element.on('compositionend', function() {\n\t composing = false;\n\t listener();\n\t });\n\t }\n\t\n\t var timeout;\n\t\n\t var listener = function(ev) {\n\t if (timeout) {\n\t $browser.defer.cancel(timeout);\n\t timeout = null;\n\t }\n\t if (composing) return;\n\t var value = element.val(),\n\t event = ev && ev.type;\n\t\n\t // By default we will trim the value\n\t // If the attribute ng-trim exists we will avoid trimming\n\t // If input type is 'password', the value is never trimmed\n\t if (type !== 'password' && (!attr.ngTrim || attr.ngTrim !== 'false')) {\n\t value = trim(value);\n\t }\n\t\n\t // If a control is suffering from bad input (due to native validators), browsers discard its\n\t // value, so it may be necessary to revalidate (by calling $setViewValue again) even if the\n\t // control's value is the same empty value twice in a row.\n\t if (ctrl.$viewValue !== value || (value === '' && ctrl.$$hasNativeValidators)) {\n\t ctrl.$setViewValue(value, event);\n\t }\n\t };\n\t\n\t // if the browser does support \"input\" event, we are fine - except on IE9 which doesn't fire the\n\t // input event on backspace, delete or cut\n\t if ($sniffer.hasEvent('input')) {\n\t element.on('input', listener);\n\t } else {\n\t var deferListener = function(ev, input, origValue) {\n\t if (!timeout) {\n\t timeout = $browser.defer(function() {\n\t timeout = null;\n\t if (!input || input.value !== origValue) {\n\t listener(ev);\n\t }\n\t });\n\t }\n\t };\n\t\n\t element.on('keydown', function(event) {\n\t var key = event.keyCode;\n\t\n\t // ignore\n\t // command modifiers arrows\n\t if (key === 91 || (15 < key && key < 19) || (37 <= key && key <= 40)) return;\n\t\n\t deferListener(event, this, this.value);\n\t });\n\t\n\t // if user modifies input value using context menu in IE, we need \"paste\" and \"cut\" events to catch it\n\t if ($sniffer.hasEvent('paste')) {\n\t element.on('paste cut', deferListener);\n\t }\n\t }\n\t\n\t // if user paste into input using mouse on older browser\n\t // or form autocomplete on newer browser, we need \"change\" event to catch it\n\t element.on('change', listener);\n\t\n\t // Some native input types (date-family) have the ability to change validity without\n\t // firing any input/change events.\n\t // For these event types, when native validators are present and the browser supports the type,\n\t // check for validity changes on various DOM events.\n\t if (PARTIAL_VALIDATION_TYPES[type] && ctrl.$$hasNativeValidators && type === attr.type) {\n\t element.on(PARTIAL_VALIDATION_EVENTS, function(ev) {\n\t if (!timeout) {\n\t var validity = this[VALIDITY_STATE_PROPERTY];\n\t var origBadInput = validity.badInput;\n\t var origTypeMismatch = validity.typeMismatch;\n\t timeout = $browser.defer(function() {\n\t timeout = null;\n\t if (validity.badInput !== origBadInput || validity.typeMismatch !== origTypeMismatch) {\n\t listener(ev);\n\t }\n\t });\n\t }\n\t });\n\t }\n\t\n\t ctrl.$render = function() {\n\t // Workaround for Firefox validation #12102.\n\t var value = ctrl.$isEmpty(ctrl.$viewValue) ? '' : ctrl.$viewValue;\n\t if (element.val() !== value) {\n\t element.val(value);\n\t }\n\t };\n\t}\n\t\n\tfunction weekParser(isoWeek, existingDate) {\n\t if (isDate(isoWeek)) {\n\t return isoWeek;\n\t }\n\t\n\t if (isString(isoWeek)) {\n\t WEEK_REGEXP.lastIndex = 0;\n\t var parts = WEEK_REGEXP.exec(isoWeek);\n\t if (parts) {\n\t var year = +parts[1],\n\t week = +parts[2],\n\t hours = 0,\n\t minutes = 0,\n\t seconds = 0,\n\t milliseconds = 0,\n\t firstThurs = getFirstThursdayOfYear(year),\n\t addDays = (week - 1) * 7;\n\t\n\t if (existingDate) {\n\t hours = existingDate.getHours();\n\t minutes = existingDate.getMinutes();\n\t seconds = existingDate.getSeconds();\n\t milliseconds = existingDate.getMilliseconds();\n\t }\n\t\n\t return new Date(year, 0, firstThurs.getDate() + addDays, hours, minutes, seconds, milliseconds);\n\t }\n\t }\n\t\n\t return NaN;\n\t}\n\t\n\tfunction createDateParser(regexp, mapping) {\n\t return function(iso, date) {\n\t var parts, map;\n\t\n\t if (isDate(iso)) {\n\t return iso;\n\t }\n\t\n\t if (isString(iso)) {\n\t // When a date is JSON'ified to wraps itself inside of an extra\n\t // set of double quotes. This makes the date parsing code unable\n\t // to match the date string and parse it as a date.\n\t if (iso.charAt(0) == '\"' && iso.charAt(iso.length - 1) == '\"') {\n\t iso = iso.substring(1, iso.length - 1);\n\t }\n\t if (ISO_DATE_REGEXP.test(iso)) {\n\t return new Date(iso);\n\t }\n\t regexp.lastIndex = 0;\n\t parts = regexp.exec(iso);\n\t\n\t if (parts) {\n\t parts.shift();\n\t if (date) {\n\t map = {\n\t yyyy: date.getFullYear(),\n\t MM: date.getMonth() + 1,\n\t dd: date.getDate(),\n\t HH: date.getHours(),\n\t mm: date.getMinutes(),\n\t ss: date.getSeconds(),\n\t sss: date.getMilliseconds() / 1000\n\t };\n\t } else {\n\t map = { yyyy: 1970, MM: 1, dd: 1, HH: 0, mm: 0, ss: 0, sss: 0 };\n\t }\n\t\n\t forEach(parts, function(part, index) {\n\t if (index < mapping.length) {\n\t map[mapping[index]] = +part;\n\t }\n\t });\n\t return new Date(map.yyyy, map.MM - 1, map.dd, map.HH, map.mm, map.ss || 0, map.sss * 1000 || 0);\n\t }\n\t }\n\t\n\t return NaN;\n\t };\n\t}\n\t\n\tfunction createDateInputType(type, regexp, parseDate, format) {\n\t return function dynamicDateInputType(scope, element, attr, ctrl, $sniffer, $browser, $filter) {\n\t badInputChecker(scope, element, attr, ctrl);\n\t baseInputType(scope, element, attr, ctrl, $sniffer, $browser);\n\t var timezone = ctrl && ctrl.$options && ctrl.$options.timezone;\n\t var previousDate;\n\t\n\t ctrl.$$parserName = type;\n\t ctrl.$parsers.push(function(value) {\n\t if (ctrl.$isEmpty(value)) return null;\n\t if (regexp.test(value)) {\n\t // Note: We cannot read ctrl.$modelValue, as there might be a different\n\t // parser/formatter in the processing chain so that the model\n\t // contains some different data format!\n\t var parsedDate = parseDate(value, previousDate);\n\t if (timezone) {\n\t parsedDate = convertTimezoneToLocal(parsedDate, timezone);\n\t }\n\t return parsedDate;\n\t }\n\t return undefined;\n\t });\n\t\n\t ctrl.$formatters.push(function(value) {\n\t if (value && !isDate(value)) {\n\t throw ngModelMinErr('datefmt', 'Expected `{0}` to be a date', value);\n\t }\n\t if (isValidDate(value)) {\n\t previousDate = value;\n\t if (previousDate && timezone) {\n\t previousDate = convertTimezoneToLocal(previousDate, timezone, true);\n\t }\n\t return $filter('date')(value, format, timezone);\n\t } else {\n\t previousDate = null;\n\t return '';\n\t }\n\t });\n\t\n\t if (isDefined(attr.min) || attr.ngMin) {\n\t var minVal;\n\t ctrl.$validators.min = function(value) {\n\t return !isValidDate(value) || isUndefined(minVal) || parseDate(value) >= minVal;\n\t };\n\t attr.$observe('min', function(val) {\n\t minVal = parseObservedDateValue(val);\n\t ctrl.$validate();\n\t });\n\t }\n\t\n\t if (isDefined(attr.max) || attr.ngMax) {\n\t var maxVal;\n\t ctrl.$validators.max = function(value) {\n\t return !isValidDate(value) || isUndefined(maxVal) || parseDate(value) <= maxVal;\n\t };\n\t attr.$observe('max', function(val) {\n\t maxVal = parseObservedDateValue(val);\n\t ctrl.$validate();\n\t });\n\t }\n\t\n\t function isValidDate(value) {\n\t // Invalid Date: getTime() returns NaN\n\t return value && !(value.getTime && value.getTime() !== value.getTime());\n\t }\n\t\n\t function parseObservedDateValue(val) {\n\t return isDefined(val) && !isDate(val) ? parseDate(val) || undefined : val;\n\t }\n\t };\n\t}\n\t\n\tfunction badInputChecker(scope, element, attr, ctrl) {\n\t var node = element[0];\n\t var nativeValidation = ctrl.$$hasNativeValidators = isObject(node.validity);\n\t if (nativeValidation) {\n\t ctrl.$parsers.push(function(value) {\n\t var validity = element.prop(VALIDITY_STATE_PROPERTY) || {};\n\t // Detect bug in FF35 for input[email] (https://bugzilla.mozilla.org/show_bug.cgi?id=1064430):\n\t // - also sets validity.badInput (should only be validity.typeMismatch).\n\t // - see http://www.whatwg.org/specs/web-apps/current-work/multipage/forms.html#e-mail-state-(type=email)\n\t // - can ignore this case as we can still read out the erroneous email...\n\t return validity.badInput && !validity.typeMismatch ? undefined : value;\n\t });\n\t }\n\t}\n\t\n\tfunction numberInputType(scope, element, attr, ctrl, $sniffer, $browser) {\n\t badInputChecker(scope, element, attr, ctrl);\n\t baseInputType(scope, element, attr, ctrl, $sniffer, $browser);\n\t\n\t ctrl.$$parserName = 'number';\n\t ctrl.$parsers.push(function(value) {\n\t if (ctrl.$isEmpty(value)) return null;\n\t if (NUMBER_REGEXP.test(value)) return parseFloat(value);\n\t return undefined;\n\t });\n\t\n\t ctrl.$formatters.push(function(value) {\n\t if (!ctrl.$isEmpty(value)) {\n\t if (!isNumber(value)) {\n\t throw ngModelMinErr('numfmt', 'Expected `{0}` to be a number', value);\n\t }\n\t value = value.toString();\n\t }\n\t return value;\n\t });\n\t\n\t if (isDefined(attr.min) || attr.ngMin) {\n\t var minVal;\n\t ctrl.$validators.min = function(value) {\n\t return ctrl.$isEmpty(value) || isUndefined(minVal) || value >= minVal;\n\t };\n\t\n\t attr.$observe('min', function(val) {\n\t if (isDefined(val) && !isNumber(val)) {\n\t val = parseFloat(val, 10);\n\t }\n\t minVal = isNumber(val) && !isNaN(val) ? val : undefined;\n\t // TODO(matsko): implement validateLater to reduce number of validations\n\t ctrl.$validate();\n\t });\n\t }\n\t\n\t if (isDefined(attr.max) || attr.ngMax) {\n\t var maxVal;\n\t ctrl.$validators.max = function(value) {\n\t return ctrl.$isEmpty(value) || isUndefined(maxVal) || value <= maxVal;\n\t };\n\t\n\t attr.$observe('max', function(val) {\n\t if (isDefined(val) && !isNumber(val)) {\n\t val = parseFloat(val, 10);\n\t }\n\t maxVal = isNumber(val) && !isNaN(val) ? val : undefined;\n\t // TODO(matsko): implement validateLater to reduce number of validations\n\t ctrl.$validate();\n\t });\n\t }\n\t}\n\t\n\tfunction urlInputType(scope, element, attr, ctrl, $sniffer, $browser) {\n\t // Note: no badInputChecker here by purpose as `url` is only a validation\n\t // in browsers, i.e. we can always read out input.value even if it is not valid!\n\t baseInputType(scope, element, attr, ctrl, $sniffer, $browser);\n\t stringBasedInputType(ctrl);\n\t\n\t ctrl.$$parserName = 'url';\n\t ctrl.$validators.url = function(modelValue, viewValue) {\n\t var value = modelValue || viewValue;\n\t return ctrl.$isEmpty(value) || URL_REGEXP.test(value);\n\t };\n\t}\n\t\n\tfunction emailInputType(scope, element, attr, ctrl, $sniffer, $browser) {\n\t // Note: no badInputChecker here by purpose as `url` is only a validation\n\t // in browsers, i.e. we can always read out input.value even if it is not valid!\n\t baseInputType(scope, element, attr, ctrl, $sniffer, $browser);\n\t stringBasedInputType(ctrl);\n\t\n\t ctrl.$$parserName = 'email';\n\t ctrl.$validators.email = function(modelValue, viewValue) {\n\t var value = modelValue || viewValue;\n\t return ctrl.$isEmpty(value) || EMAIL_REGEXP.test(value);\n\t };\n\t}\n\t\n\tfunction radioInputType(scope, element, attr, ctrl) {\n\t // make the name unique, if not defined\n\t if (isUndefined(attr.name)) {\n\t element.attr('name', nextUid());\n\t }\n\t\n\t var listener = function(ev) {\n\t if (element[0].checked) {\n\t ctrl.$setViewValue(attr.value, ev && ev.type);\n\t }\n\t };\n\t\n\t element.on('click', listener);\n\t\n\t ctrl.$render = function() {\n\t var value = attr.value;\n\t element[0].checked = (value == ctrl.$viewValue);\n\t };\n\t\n\t attr.$observe('value', ctrl.$render);\n\t}\n\t\n\tfunction parseConstantExpr($parse, context, name, expression, fallback) {\n\t var parseFn;\n\t if (isDefined(expression)) {\n\t parseFn = $parse(expression);\n\t if (!parseFn.constant) {\n\t throw ngModelMinErr('constexpr', 'Expected constant expression for `{0}`, but saw ' +\n\t '`{1}`.', name, expression);\n\t }\n\t return parseFn(context);\n\t }\n\t return fallback;\n\t}\n\t\n\tfunction checkboxInputType(scope, element, attr, ctrl, $sniffer, $browser, $filter, $parse) {\n\t var trueValue = parseConstantExpr($parse, scope, 'ngTrueValue', attr.ngTrueValue, true);\n\t var falseValue = parseConstantExpr($parse, scope, 'ngFalseValue', attr.ngFalseValue, false);\n\t\n\t var listener = function(ev) {\n\t ctrl.$setViewValue(element[0].checked, ev && ev.type);\n\t };\n\t\n\t element.on('click', listener);\n\t\n\t ctrl.$render = function() {\n\t element[0].checked = ctrl.$viewValue;\n\t };\n\t\n\t // Override the standard `$isEmpty` because the $viewValue of an empty checkbox is always set to `false`\n\t // This is because of the parser below, which compares the `$modelValue` with `trueValue` to convert\n\t // it to a boolean.\n\t ctrl.$isEmpty = function(value) {\n\t return value === false;\n\t };\n\t\n\t ctrl.$formatters.push(function(value) {\n\t return equals(value, trueValue);\n\t });\n\t\n\t ctrl.$parsers.push(function(value) {\n\t return value ? trueValue : falseValue;\n\t });\n\t}\n\t\n\t\n\t/**\n\t * @ngdoc directive\n\t * @name textarea\n\t * @restrict E\n\t *\n\t * @description\n\t * HTML textarea element control with angular data-binding. The data-binding and validation\n\t * properties of this element are exactly the same as those of the\n\t * {@link ng.directive:input input element}.\n\t *\n\t * @param {string} ngModel Assignable angular expression to data-bind to.\n\t * @param {string=} name Property name of the form under which the control is published.\n\t * @param {string=} required Sets `required` validation error key if the value is not entered.\n\t * @param {string=} ngRequired Adds `required` attribute and `required` validation constraint to\n\t * the element when the ngRequired expression evaluates to true. Use `ngRequired` instead of\n\t * `required` when you want to data-bind to the `required` attribute.\n\t * @param {number=} ngMinlength Sets `minlength` validation error key if the value is shorter than\n\t * minlength.\n\t * @param {number=} ngMaxlength Sets `maxlength` validation error key if the value is longer than\n\t * maxlength. Setting the attribute to a negative or non-numeric value, allows view values of any\n\t * length.\n\t * @param {string=} ngPattern Sets `pattern` validation error key if the ngModel value does not match\n\t * a RegExp found by evaluating the Angular expression given in the attribute value.\n\t * If the expression evaluates to a RegExp object, then this is used directly.\n\t * If the expression evaluates to a string, then it will be converted to a RegExp\n\t * after wrapping it in `^` and `$` characters. For instance, `\"abc\"` will be converted to\n\t * `new RegExp('^abc$')`.
\n\t * **Note:** Avoid using the `g` flag on the RegExp, as it will cause each successive search to\n\t * start at the index of the last search's match, thus not taking the whole input value into\n\t * account.\n\t * @param {string=} ngChange Angular expression to be executed when input changes due to user\n\t * interaction with the input element.\n\t * @param {boolean=} [ngTrim=true] If set to false Angular will not automatically trim the input.\n\t */\n\t\n\t\n\t/**\n\t * @ngdoc directive\n\t * @name input\n\t * @restrict E\n\t *\n\t * @description\n\t * HTML input element control. When used together with {@link ngModel `ngModel`}, it provides data-binding,\n\t * input state control, and validation.\n\t * Input control follows HTML5 input types and polyfills the HTML5 validation behavior for older browsers.\n\t *\n\t *
\n\t * **Note:** Not every feature offered is available for all input types.\n\t * Specifically, data binding and event handling via `ng-model` is unsupported for `input[file]`.\n\t *
\n\t *\n\t * @param {string} ngModel Assignable angular expression to data-bind to.\n\t * @param {string=} name Property name of the form under which the control is published.\n\t * @param {string=} required Sets `required` validation error key if the value is not entered.\n\t * @param {boolean=} ngRequired Sets `required` attribute if set to true\n\t * @param {number=} ngMinlength Sets `minlength` validation error key if the value is shorter than\n\t * minlength.\n\t * @param {number=} ngMaxlength Sets `maxlength` validation error key if the value is longer than\n\t * maxlength. Setting the attribute to a negative or non-numeric value, allows view values of any\n\t * length.\n\t * @param {string=} ngPattern Sets `pattern` validation error key if the ngModel value does not match\n\t * a RegExp found by evaluating the Angular expression given in the attribute value.\n\t * If the expression evaluates to a RegExp object, then this is used directly.\n\t * If the expression evaluates to a string, then it will be converted to a RegExp\n\t * after wrapping it in `^` and `$` characters. For instance, `\"abc\"` will be converted to\n\t * `new RegExp('^abc$')`.
\n\t * **Note:** Avoid using the `g` flag on the RegExp, as it will cause each successive search to\n\t * start at the index of the last search's match, thus not taking the whole input value into\n\t * account.\n\t * @param {string=} ngChange Angular expression to be executed when input changes due to user\n\t * interaction with the input element.\n\t * @param {boolean=} [ngTrim=true] If set to false Angular will not automatically trim the input.\n\t * This parameter is ignored for input[type=password] controls, which will never trim the\n\t * input.\n\t *\n\t * @example\n\t \n\t \n\t \n\t
\n\t
\n\t \n\t
\n\t \n\t Required!\n\t
\n\t \n\t
\n\t \n\t Too short!\n\t \n\t Too long!\n\t
\n\t
\n\t
\n\t user = {{user}}
\n\t myForm.userName.$valid = {{myForm.userName.$valid}}
\n\t myForm.userName.$error = {{myForm.userName.$error}}
\n\t myForm.lastName.$valid = {{myForm.lastName.$valid}}
\n\t myForm.lastName.$error = {{myForm.lastName.$error}}
\n\t myForm.$valid = {{myForm.$valid}}
\n\t myForm.$error.required = {{!!myForm.$error.required}}
\n\t myForm.$error.minlength = {{!!myForm.$error.minlength}}
\n\t myForm.$error.maxlength = {{!!myForm.$error.maxlength}}
\n\t
\n\t
\n\t \n\t var user = element(by.exactBinding('user'));\n\t var userNameValid = element(by.binding('myForm.userName.$valid'));\n\t var lastNameValid = element(by.binding('myForm.lastName.$valid'));\n\t var lastNameError = element(by.binding('myForm.lastName.$error'));\n\t var formValid = element(by.binding('myForm.$valid'));\n\t var userNameInput = element(by.model('user.name'));\n\t var userLastInput = element(by.model('user.last'));\n\t\n\t it('should initialize to model', function() {\n\t expect(user.getText()).toContain('{\"name\":\"guest\",\"last\":\"visitor\"}');\n\t expect(userNameValid.getText()).toContain('true');\n\t expect(formValid.getText()).toContain('true');\n\t });\n\t\n\t it('should be invalid if empty when required', function() {\n\t userNameInput.clear();\n\t userNameInput.sendKeys('');\n\t\n\t expect(user.getText()).toContain('{\"last\":\"visitor\"}');\n\t expect(userNameValid.getText()).toContain('false');\n\t expect(formValid.getText()).toContain('false');\n\t });\n\t\n\t it('should be valid if empty when min length is set', function() {\n\t userLastInput.clear();\n\t userLastInput.sendKeys('');\n\t\n\t expect(user.getText()).toContain('{\"name\":\"guest\",\"last\":\"\"}');\n\t expect(lastNameValid.getText()).toContain('true');\n\t expect(formValid.getText()).toContain('true');\n\t });\n\t\n\t it('should be invalid if less than required min length', function() {\n\t userLastInput.clear();\n\t userLastInput.sendKeys('xx');\n\t\n\t expect(user.getText()).toContain('{\"name\":\"guest\"}');\n\t expect(lastNameValid.getText()).toContain('false');\n\t expect(lastNameError.getText()).toContain('minlength');\n\t expect(formValid.getText()).toContain('false');\n\t });\n\t\n\t it('should be invalid if longer than max length', function() {\n\t userLastInput.clear();\n\t userLastInput.sendKeys('some ridiculously long name');\n\t\n\t expect(user.getText()).toContain('{\"name\":\"guest\"}');\n\t expect(lastNameValid.getText()).toContain('false');\n\t expect(lastNameError.getText()).toContain('maxlength');\n\t expect(formValid.getText()).toContain('false');\n\t });\n\t \n\t
\n\t */\n\tvar inputDirective = ['$browser', '$sniffer', '$filter', '$parse',\n\t function($browser, $sniffer, $filter, $parse) {\n\t return {\n\t restrict: 'E',\n\t require: ['?ngModel'],\n\t link: {\n\t pre: function(scope, element, attr, ctrls) {\n\t if (ctrls[0]) {\n\t (inputType[lowercase(attr.type)] || inputType.text)(scope, element, attr, ctrls[0], $sniffer,\n\t $browser, $filter, $parse);\n\t }\n\t }\n\t }\n\t };\n\t}];\n\t\n\t\n\t\n\tvar CONSTANT_VALUE_REGEXP = /^(true|false|\\d+)$/;\n\t/**\n\t * @ngdoc directive\n\t * @name ngValue\n\t *\n\t * @description\n\t * Binds the given expression to the value of `