PageRenderTime 29ms CodeModel.GetById 21ms RepoModel.GetById 0ms app.codeStats 1ms

/files/clappr/0.0.105/clappr.js

https://gitlab.com/Mirros/jsdelivr
JavaScript | 1583 lines | 638 code | 144 blank | 801 comment | 280 complexity | 0e2e9094d780e6fbf5a59d21dfaf603b MD5 | raw file
  1. require=(function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
  2. "use strict";
  3. // Copyright 2014 Globo.com Player authors. All rights reserved.
  4. // Use of this source code is governed by a BSD-style
  5. // license that can be found in the LICENSE file.
  6. var Player = require("./components/player");
  7. var Mediator = require("mediator");
  8. var Events = require("events");
  9. window.DEBUG = false;
  10. window.Clappr = { Player: Player, Mediator: Mediator, Events: Events };
  11. window.Clappr.version = "0.0.104";
  12. module.exports = window.Clappr;
  13. },{"./components/player":78,"events":"events","mediator":"mediator"}],2:[function(require,module,exports){
  14. /**
  15. * lodash 3.0.0 (Custom Build) <https://lodash.com/>
  16. * Build: `lodash modern modularize exports="npm" -o ./`
  17. * Copyright 2012-2015 The Dojo Foundation <http://dojofoundation.org/>
  18. * Based on Underscore.js 1.7.0 <http://underscorejs.org/LICENSE>
  19. * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
  20. * Available under MIT license <https://lodash.com/license>
  21. */
  22. var baseAssign = require('lodash._baseassign'),
  23. createAssigner = require('lodash._createassigner');
  24. /**
  25. * Assigns own enumerable properties of source object(s) to the destination
  26. * object. Subsequent sources overwrite property assignments of previous sources.
  27. * If `customizer` is provided it is invoked to produce the assigned values.
  28. * The `customizer` is bound to `thisArg` and invoked with five arguments;
  29. * (objectValue, sourceValue, key, object, source).
  30. *
  31. * @static
  32. * @memberOf _
  33. * @alias extend
  34. * @category Object
  35. * @param {Object} object The destination object.
  36. * @param {...Object} [sources] The source objects.
  37. * @param {Function} [customizer] The function to customize assigning values.
  38. * @param {*} [thisArg] The `this` binding of `customizer`.
  39. * @returns {Object} Returns `object`.
  40. * @example
  41. *
  42. * _.assign({ 'user': 'barney' }, { 'age': 40 }, { 'user': 'fred' });
  43. * // => { 'user': 'fred', 'age': 40 }
  44. *
  45. * // using a customizer callback
  46. * var defaults = _.partialRight(_.assign, function(value, other) {
  47. * return typeof value == 'undefined' ? other : value;
  48. * });
  49. *
  50. * defaults({ 'user': 'barney' }, { 'age': 36 }, { 'user': 'fred' });
  51. * // => { 'user': 'barney', 'age': 36 }
  52. */
  53. var assign = createAssigner(baseAssign);
  54. module.exports = assign;
  55. },{"lodash._baseassign":3,"lodash._createassigner":9}],3:[function(require,module,exports){
  56. /**
  57. * lodash 3.0.1 (Custom Build) <https://lodash.com/>
  58. * Build: `lodash modern modularize exports="npm" -o ./`
  59. * Copyright 2012-2015 The Dojo Foundation <http://dojofoundation.org/>
  60. * Based on Underscore.js 1.7.0 <http://underscorejs.org/LICENSE>
  61. * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
  62. * Available under MIT license <https://lodash.com/license>
  63. */
  64. var baseCopy = require('lodash._basecopy'),
  65. keys = require('lodash.keys');
  66. /**
  67. * The base implementation of `_.assign` without support for argument juggling,
  68. * multiple sources, and `this` binding `customizer` functions.
  69. *
  70. * @private
  71. * @param {Object} object The destination object.
  72. * @param {Object} source The source object.
  73. * @param {Function} [customizer] The function to customize assigning values.
  74. * @returns {Object} Returns the destination object.
  75. */
  76. function baseAssign(object, source, customizer) {
  77. var props = keys(source);
  78. if (!customizer) {
  79. return baseCopy(source, object, props);
  80. }
  81. var index = -1,
  82. length = props.length;
  83. while (++index < length) {
  84. var key = props[index],
  85. value = object[key],
  86. result = customizer(value, source[key], key, object, source);
  87. if ((result === result ? result !== value : value === value) ||
  88. (typeof value == 'undefined' && !(key in object))) {
  89. object[key] = result;
  90. }
  91. }
  92. return object;
  93. }
  94. module.exports = baseAssign;
  95. },{"lodash._basecopy":4,"lodash.keys":5}],4:[function(require,module,exports){
  96. /**
  97. * lodash 3.0.0 (Custom Build) <https://lodash.com/>
  98. * Build: `lodash modern modularize exports="npm" -o ./`
  99. * Copyright 2012-2015 The Dojo Foundation <http://dojofoundation.org/>
  100. * Based on Underscore.js 1.7.0 <http://underscorejs.org/LICENSE>
  101. * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
  102. * Available under MIT license <https://lodash.com/license>
  103. */
  104. /**
  105. * Copies the properties of `source` to `object`.
  106. *
  107. * @private
  108. * @param {Object} source The object to copy properties from.
  109. * @param {Object} [object={}] The object to copy properties to.
  110. * @param {Array} props The property names to copy.
  111. * @returns {Object} Returns `object`.
  112. */
  113. function baseCopy(source, object, props) {
  114. if (!props) {
  115. props = object;
  116. object = {};
  117. }
  118. var index = -1,
  119. length = props.length;
  120. while (++index < length) {
  121. var key = props[index];
  122. object[key] = source[key];
  123. }
  124. return object;
  125. }
  126. module.exports = baseCopy;
  127. },{}],5:[function(require,module,exports){
  128. /**
  129. * lodash 3.0.3 (Custom Build) <https://lodash.com/>
  130. * Build: `lodash modern modularize exports="npm" -o ./`
  131. * Copyright 2012-2015 The Dojo Foundation <http://dojofoundation.org/>
  132. * Based on Underscore.js 1.7.0 <http://underscorejs.org/LICENSE>
  133. * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
  134. * Available under MIT license <https://lodash.com/license>
  135. */
  136. var isArguments = require('lodash.isarguments'),
  137. isArray = require('lodash.isarray'),
  138. isNative = require('lodash.isnative');
  139. /** Used for native method references. */
  140. var objectProto = Object.prototype;
  141. /** Used to check objects for own properties. */
  142. var hasOwnProperty = objectProto.hasOwnProperty;
  143. /** Native method references. */
  144. var propertyIsEnumerable = objectProto.propertyIsEnumerable;
  145. /* Native method references for those with the same name as other `lodash` methods. */
  146. var nativeKeys = isNative(nativeKeys = Object.keys) && nativeKeys;
  147. /**
  148. * Used as the maximum length of an array-like value.
  149. * See the [ES spec](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-number.max_safe_integer)
  150. * for more details.
  151. */
  152. var MAX_SAFE_INTEGER = Math.pow(2, 53) - 1;
  153. /**
  154. * An object environment feature flags.
  155. *
  156. * @static
  157. * @memberOf _
  158. * @type Object
  159. */
  160. var support = {};
  161. (function(x) {
  162. /**
  163. * Detect if `arguments` object indexes are non-enumerable.
  164. *
  165. * In Firefox < 4, IE < 9, PhantomJS, and Safari < 5.1 `arguments` object
  166. * indexes are non-enumerable. Chrome < 25 and Node.js < 0.11.0 treat
  167. * `arguments` object indexes as non-enumerable and fail `hasOwnProperty`
  168. * checks for indexes that exceed their function's formal parameters with
  169. * associated values of `0`.
  170. *
  171. * @memberOf _.support
  172. * @type boolean
  173. */
  174. try {
  175. support.nonEnumArgs = !propertyIsEnumerable.call(arguments, 1);
  176. } catch(e) {
  177. support.nonEnumArgs = true;
  178. }
  179. }(0, 0));
  180. /**
  181. * Checks if `value` is a valid array-like index.
  182. *
  183. * @private
  184. * @param {*} value The value to check.
  185. * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index.
  186. * @returns {boolean} Returns `true` if `value` is a valid index, else `false`.
  187. */
  188. function isIndex(value, length) {
  189. value = +value;
  190. length = length == null ? MAX_SAFE_INTEGER : length;
  191. return value > -1 && value % 1 == 0 && value < length;
  192. }
  193. /**
  194. * Checks if `value` is a valid array-like length.
  195. *
  196. * **Note:** This function is based on ES `ToLength`. See the
  197. * [ES spec](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-tolength)
  198. * for more details.
  199. *
  200. * @private
  201. * @param {*} value The value to check.
  202. * @returns {boolean} Returns `true` if `value` is a valid length, else `false`.
  203. */
  204. function isLength(value) {
  205. return typeof value == 'number' && value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;
  206. }
  207. /**
  208. * A fallback implementation of `Object.keys` which creates an array of the
  209. * own enumerable property names of `object`.
  210. *
  211. * @private
  212. * @param {Object} object The object to inspect.
  213. * @returns {Array} Returns the array of property names.
  214. */
  215. function shimKeys(object) {
  216. var props = keysIn(object),
  217. propsLength = props.length,
  218. length = propsLength && object.length;
  219. var allowIndexes = length && isLength(length) &&
  220. (isArray(object) || (support.nonEnumArgs && isArguments(object)));
  221. var index = -1,
  222. result = [];
  223. while (++index < propsLength) {
  224. var key = props[index];
  225. if ((allowIndexes && isIndex(key, length)) || hasOwnProperty.call(object, key)) {
  226. result.push(key);
  227. }
  228. }
  229. return result;
  230. }
  231. /**
  232. * Checks if `value` is the language type of `Object`.
  233. * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)
  234. *
  235. * **Note:** See the [ES5 spec](https://es5.github.io/#x8) for more details.
  236. *
  237. * @static
  238. * @memberOf _
  239. * @category Lang
  240. * @param {*} value The value to check.
  241. * @returns {boolean} Returns `true` if `value` is an object, else `false`.
  242. * @example
  243. *
  244. * _.isObject({});
  245. * // => true
  246. *
  247. * _.isObject([1, 2, 3]);
  248. * // => true
  249. *
  250. * _.isObject(1);
  251. * // => false
  252. */
  253. function isObject(value) {
  254. // Avoid a V8 JIT bug in Chrome 19-20.
  255. // See https://code.google.com/p/v8/issues/detail?id=2291 for more details.
  256. var type = typeof value;
  257. return type == 'function' || (value && type == 'object') || false;
  258. }
  259. /**
  260. * Creates an array of the own enumerable property names of `object`.
  261. *
  262. * **Note:** Non-object values are coerced to objects. See the
  263. * [ES spec](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-object.keys)
  264. * for more details.
  265. *
  266. * @static
  267. * @memberOf _
  268. * @category Object
  269. * @param {Object} object The object to inspect.
  270. * @returns {Array} Returns the array of property names.
  271. * @example
  272. *
  273. * function Foo() {
  274. * this.a = 1;
  275. * this.b = 2;
  276. * }
  277. *
  278. * Foo.prototype.c = 3;
  279. *
  280. * _.keys(new Foo);
  281. * // => ['a', 'b'] (iteration order is not guaranteed)
  282. *
  283. * _.keys('hi');
  284. * // => ['0', '1']
  285. */
  286. var keys = !nativeKeys ? shimKeys : function(object) {
  287. if (object) {
  288. var Ctor = object.constructor,
  289. length = object.length;
  290. }
  291. if ((typeof Ctor == 'function' && Ctor.prototype === object) ||
  292. (typeof object != 'function' && (length && isLength(length)))) {
  293. return shimKeys(object);
  294. }
  295. return isObject(object) ? nativeKeys(object) : [];
  296. };
  297. /**
  298. * Creates an array of the own and inherited enumerable property names of `object`.
  299. *
  300. * **Note:** Non-object values are coerced to objects.
  301. *
  302. * @static
  303. * @memberOf _
  304. * @category Object
  305. * @param {Object} object The object to inspect.
  306. * @returns {Array} Returns the array of property names.
  307. * @example
  308. *
  309. * function Foo() {
  310. * this.a = 1;
  311. * this.b = 2;
  312. * }
  313. *
  314. * Foo.prototype.c = 3;
  315. *
  316. * _.keysIn(new Foo);
  317. * // => ['a', 'b', 'c'] (iteration order is not guaranteed)
  318. */
  319. function keysIn(object) {
  320. if (object == null) {
  321. return [];
  322. }
  323. if (!isObject(object)) {
  324. object = Object(object);
  325. }
  326. var length = object.length;
  327. length = (length && isLength(length) &&
  328. (isArray(object) || (support.nonEnumArgs && isArguments(object))) && length) || 0;
  329. var Ctor = object.constructor,
  330. index = -1,
  331. isProto = typeof Ctor == 'function' && Ctor.prototype === object,
  332. result = Array(length),
  333. skipIndexes = length > 0;
  334. while (++index < length) {
  335. result[index] = (index + '');
  336. }
  337. for (var key in object) {
  338. if (!(skipIndexes && isIndex(key, length)) &&
  339. !(key == 'constructor' && (isProto || !hasOwnProperty.call(object, key)))) {
  340. result.push(key);
  341. }
  342. }
  343. return result;
  344. }
  345. module.exports = keys;
  346. },{"lodash.isarguments":6,"lodash.isarray":7,"lodash.isnative":8}],6:[function(require,module,exports){
  347. /**
  348. * lodash 3.0.0 (Custom Build) <https://lodash.com/>
  349. * Build: `lodash modern modularize exports="npm" -o ./`
  350. * Copyright 2012-2015 The Dojo Foundation <http://dojofoundation.org/>
  351. * Based on Underscore.js 1.7.0 <http://underscorejs.org/LICENSE>
  352. * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
  353. * Available under MIT license <https://lodash.com/license>
  354. */
  355. /** `Object#toString` result references. */
  356. var argsTag = '[object Arguments]';
  357. /**
  358. * Checks if `value` is object-like.
  359. *
  360. * @private
  361. * @param {*} value The value to check.
  362. * @returns {boolean} Returns `true` if `value` is object-like, else `false`.
  363. */
  364. function isObjectLike(value) {
  365. return (value && typeof value == 'object') || false;
  366. }
  367. /** Used for native method references. */
  368. var objectProto = Object.prototype;
  369. /**
  370. * Used to resolve the `toStringTag` of values.
  371. * See the [ES spec](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-object.prototype.tostring)
  372. * for more details.
  373. */
  374. var objToString = objectProto.toString;
  375. /**
  376. * Used as the maximum length of an array-like value.
  377. * See the [ES spec](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-tolength)
  378. * for more details.
  379. */
  380. var MAX_SAFE_INTEGER = Math.pow(2, 53) - 1;
  381. /**
  382. * Checks if `value` is a valid array-like length.
  383. *
  384. * @private
  385. * @param {*} value The value to check.
  386. * @returns {boolean} Returns `true` if `value` is a valid length, else `false`.
  387. */
  388. function isLength(value) {
  389. return typeof value == 'number' && value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;
  390. }
  391. /**
  392. * Checks if `value` is classified as an `arguments` object.
  393. *
  394. * @static
  395. * @memberOf _
  396. * @category Lang
  397. * @param {*} value The value to check.
  398. * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`.
  399. * @example
  400. *
  401. * (function() { return _.isArguments(arguments); })();
  402. * // => true
  403. *
  404. * _.isArguments([1, 2, 3]);
  405. * // => false
  406. */
  407. function isArguments(value) {
  408. var length = isObjectLike(value) ? value.length : undefined;
  409. return (isLength(length) && objToString.call(value) == argsTag) || false;
  410. }
  411. module.exports = isArguments;
  412. },{}],7:[function(require,module,exports){
  413. /**
  414. * lodash 3.0.0 (Custom Build) <https://lodash.com/>
  415. * Build: `lodash modern modularize exports="npm" -o ./`
  416. * Copyright 2012-2015 The Dojo Foundation <http://dojofoundation.org/>
  417. * Based on Underscore.js 1.7.0 <http://underscorejs.org/LICENSE>
  418. * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
  419. * Available under MIT license <https://lodash.com/license>
  420. */
  421. /** `Object#toString` result references. */
  422. var arrayTag = '[object Array]',
  423. funcTag = '[object Function]';
  424. /** Used to detect host constructors (Safari > 5). */
  425. var reHostCtor = /^\[object .+?Constructor\]$/;
  426. /**
  427. * Used to match `RegExp` special characters.
  428. * See this [article on `RegExp` characters](http://www.regular-expressions.info/characters.html#special)
  429. * for more details.
  430. */
  431. var reRegExpChars = /[.*+?^${}()|[\]\/\\]/g,
  432. reHasRegExpChars = RegExp(reRegExpChars.source);
  433. /**
  434. * Converts `value` to a string if it is not one. An empty string is returned
  435. * for `null` or `undefined` values.
  436. *
  437. * @private
  438. * @param {*} value The value to process.
  439. * @returns {string} Returns the string.
  440. */
  441. function baseToString(value) {
  442. if (typeof value == 'string') {
  443. return value;
  444. }
  445. return value == null ? '' : (value + '');
  446. }
  447. /**
  448. * Checks if `value` is object-like.
  449. *
  450. * @private
  451. * @param {*} value The value to check.
  452. * @returns {boolean} Returns `true` if `value` is object-like, else `false`.
  453. */
  454. function isObjectLike(value) {
  455. return (value && typeof value == 'object') || false;
  456. }
  457. /** Used for native method references. */
  458. var objectProto = Object.prototype;
  459. /** Used to resolve the decompiled source of functions. */
  460. var fnToString = Function.prototype.toString;
  461. /**
  462. * Used to resolve the `toStringTag` of values.
  463. * See the [ES spec](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-object.prototype.tostring)
  464. * for more details.
  465. */
  466. var objToString = objectProto.toString;
  467. /** Used to detect if a method is native. */
  468. var reNative = RegExp('^' +
  469. escapeRegExp(objToString)
  470. .replace(/toString|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$'
  471. );
  472. /* Native method references for those with the same name as other `lodash` methods. */
  473. var nativeIsArray = isNative(nativeIsArray = Array.isArray) && nativeIsArray;
  474. /**
  475. * Used as the maximum length of an array-like value.
  476. * See the [ES spec](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-tolength)
  477. * for more details.
  478. */
  479. var MAX_SAFE_INTEGER = Math.pow(2, 53) - 1;
  480. /**
  481. * Checks if `value` is a valid array-like length.
  482. *
  483. * @private
  484. * @param {*} value The value to check.
  485. * @returns {boolean} Returns `true` if `value` is a valid length, else `false`.
  486. */
  487. function isLength(value) {
  488. return typeof value == 'number' && value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;
  489. }
  490. /**
  491. * Checks if `value` is classified as an `Array` object.
  492. *
  493. * @static
  494. * @memberOf _
  495. * @category Lang
  496. * @param {*} value The value to check.
  497. * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`.
  498. * @example
  499. *
  500. * _.isArray([1, 2, 3]);
  501. * // => true
  502. *
  503. * (function() { return _.isArray(arguments); })();
  504. * // => false
  505. */
  506. var isArray = nativeIsArray || function(value) {
  507. return (isObjectLike(value) && isLength(value.length) && objToString.call(value) == arrayTag) || false;
  508. };
  509. /**
  510. * Checks if `value` is a native function.
  511. *
  512. * @static
  513. * @memberOf _
  514. * @category Lang
  515. * @param {*} value The value to check.
  516. * @returns {boolean} Returns `true` if `value` is a native function, else `false`.
  517. * @example
  518. *
  519. * _.isNative(Array.prototype.push);
  520. * // => true
  521. *
  522. * _.isNative(_);
  523. * // => false
  524. */
  525. function isNative(value) {
  526. if (value == null) {
  527. return false;
  528. }
  529. if (objToString.call(value) == funcTag) {
  530. return reNative.test(fnToString.call(value));
  531. }
  532. return (isObjectLike(value) && reHostCtor.test(value)) || false;
  533. }
  534. /**
  535. * Escapes the `RegExp` special characters "\", "^", "$", ".", "|", "?", "*",
  536. * "+", "(", ")", "[", "]", "{" and "}" in `string`.
  537. *
  538. * @static
  539. * @memberOf _
  540. * @category String
  541. * @param {string} [string=''] The string to escape.
  542. * @returns {string} Returns the escaped string.
  543. * @example
  544. *
  545. * _.escapeRegExp('[lodash](https://lodash.com/)');
  546. * // => '\[lodash\]\(https://lodash\.com/\)'
  547. */
  548. function escapeRegExp(string) {
  549. string = baseToString(string);
  550. return (string && reHasRegExpChars.test(string))
  551. ? string.replace(reRegExpChars, '\\$&')
  552. : string;
  553. }
  554. module.exports = isArray;
  555. },{}],8:[function(require,module,exports){
  556. /**
  557. * lodash 3.0.0 (Custom Build) <https://lodash.com/>
  558. * Build: `lodash modern modularize exports="npm" -o ./`
  559. * Copyright 2012-2015 The Dojo Foundation <http://dojofoundation.org/>
  560. * Based on Underscore.js 1.7.0 <http://underscorejs.org/LICENSE>
  561. * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
  562. * Available under MIT license <https://lodash.com/license>
  563. */
  564. /** `Object#toString` result references. */
  565. var funcTag = '[object Function]';
  566. /** Used to detect host constructors (Safari > 5). */
  567. var reHostCtor = /^\[object .+?Constructor\]$/;
  568. /**
  569. * Used to match `RegExp` special characters.
  570. * See this [article on `RegExp` characters](http://www.regular-expressions.info/characters.html#special)
  571. * for more details.
  572. */
  573. var reRegExpChars = /[.*+?^${}()|[\]\/\\]/g,
  574. reHasRegExpChars = RegExp(reRegExpChars.source);
  575. /**
  576. * Converts `value` to a string if it is not one. An empty string is returned
  577. * for `null` or `undefined` values.
  578. *
  579. * @private
  580. * @param {*} value The value to process.
  581. * @returns {string} Returns the string.
  582. */
  583. function baseToString(value) {
  584. if (typeof value == 'string') {
  585. return value;
  586. }
  587. return value == null ? '' : (value + '');
  588. }
  589. /**
  590. * Checks if `value` is object-like.
  591. *
  592. * @private
  593. * @param {*} value The value to check.
  594. * @returns {boolean} Returns `true` if `value` is object-like, else `false`.
  595. */
  596. function isObjectLike(value) {
  597. return (value && typeof value == 'object') || false;
  598. }
  599. /** Used for native method references. */
  600. var objectProto = Object.prototype;
  601. /** Used to resolve the decompiled source of functions. */
  602. var fnToString = Function.prototype.toString;
  603. /**
  604. * Used to resolve the `toStringTag` of values.
  605. * See the [ES spec](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-object.prototype.tostring)
  606. * for more details.
  607. */
  608. var objToString = objectProto.toString;
  609. /** Used to detect if a method is native. */
  610. var reNative = RegExp('^' +
  611. escapeRegExp(objToString)
  612. .replace(/toString|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$'
  613. );
  614. /**
  615. * Checks if `value` is a native function.
  616. *
  617. * @static
  618. * @memberOf _
  619. * @category Lang
  620. * @param {*} value The value to check.
  621. * @returns {boolean} Returns `true` if `value` is a native function, else `false`.
  622. * @example
  623. *
  624. * _.isNative(Array.prototype.push);
  625. * // => true
  626. *
  627. * _.isNative(_);
  628. * // => false
  629. */
  630. function isNative(value) {
  631. if (value == null) {
  632. return false;
  633. }
  634. if (objToString.call(value) == funcTag) {
  635. return reNative.test(fnToString.call(value));
  636. }
  637. return (isObjectLike(value) && reHostCtor.test(value)) || false;
  638. }
  639. /**
  640. * Escapes the `RegExp` special characters "\", "^", "$", ".", "|", "?", "*",
  641. * "+", "(", ")", "[", "]", "{" and "}" in `string`.
  642. *
  643. * @static
  644. * @memberOf _
  645. * @category String
  646. * @param {string} [string=''] The string to escape.
  647. * @returns {string} Returns the escaped string.
  648. * @example
  649. *
  650. * _.escapeRegExp('[lodash](https://lodash.com/)');
  651. * // => '\[lodash\]\(https://lodash\.com/\)'
  652. */
  653. function escapeRegExp(string) {
  654. string = baseToString(string);
  655. return (string && reHasRegExpChars.test(string))
  656. ? string.replace(reRegExpChars, '\\$&')
  657. : string;
  658. }
  659. module.exports = isNative;
  660. },{}],9:[function(require,module,exports){
  661. /**
  662. * lodash 3.0.0 (Custom Build) <https://lodash.com/>
  663. * Build: `lodash modern modularize exports="npm" -o ./`
  664. * Copyright 2012-2015 The Dojo Foundation <http://dojofoundation.org/>
  665. * Based on Underscore.js 1.7.0 <http://underscorejs.org/LICENSE>
  666. * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
  667. * Available under MIT license <https://lodash.com/license>
  668. */
  669. var bindCallback = require('lodash._bindcallback'),
  670. isIterateeCall = require('lodash._isiterateecall');
  671. /**
  672. * Creates a function that assigns properties of source object(s) to a given
  673. * destination object.
  674. *
  675. * @private
  676. * @param {Function} assigner The function to assign values.
  677. * @returns {Function} Returns the new assigner function.
  678. */
  679. function createAssigner(assigner) {
  680. return function() {
  681. var length = arguments.length,
  682. object = arguments[0];
  683. if (length < 2 || object == null) {
  684. return object;
  685. }
  686. if (length > 3 && isIterateeCall(arguments[1], arguments[2], arguments[3])) {
  687. length = 2;
  688. }
  689. // Juggle arguments.
  690. if (length > 3 && typeof arguments[length - 2] == 'function') {
  691. var customizer = bindCallback(arguments[--length - 1], arguments[length--], 5);
  692. } else if (length > 2 && typeof arguments[length - 1] == 'function') {
  693. customizer = arguments[--length];
  694. }
  695. var index = 0;
  696. while (++index < length) {
  697. var source = arguments[index];
  698. if (source) {
  699. assigner(object, source, customizer);
  700. }
  701. }
  702. return object;
  703. };
  704. }
  705. module.exports = createAssigner;
  706. },{"lodash._bindcallback":10,"lodash._isiterateecall":11}],10:[function(require,module,exports){
  707. /**
  708. * lodash 3.0.0 (Custom Build) <https://lodash.com/>
  709. * Build: `lodash modern modularize exports="npm" -o ./`
  710. * Copyright 2012-2015 The Dojo Foundation <http://dojofoundation.org/>
  711. * Based on Underscore.js 1.7.0 <http://underscorejs.org/LICENSE>
  712. * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
  713. * Available under MIT license <https://lodash.com/license>
  714. */
  715. /**
  716. * A specialized version of `baseCallback` which only supports `this` binding
  717. * and specifying the number of arguments to provide to `func`.
  718. *
  719. * @private
  720. * @param {Function} func The function to bind.
  721. * @param {*} thisArg The `this` binding of `func`.
  722. * @param {number} [argCount] The number of arguments to provide to `func`.
  723. * @returns {Function} Returns the callback.
  724. */
  725. function bindCallback(func, thisArg, argCount) {
  726. if (typeof func != 'function') {
  727. return identity;
  728. }
  729. if (typeof thisArg == 'undefined') {
  730. return func;
  731. }
  732. switch (argCount) {
  733. case 1: return function(value) {
  734. return func.call(thisArg, value);
  735. };
  736. case 3: return function(value, index, collection) {
  737. return func.call(thisArg, value, index, collection);
  738. };
  739. case 4: return function(accumulator, value, index, collection) {
  740. return func.call(thisArg, accumulator, value, index, collection);
  741. };
  742. case 5: return function(value, other, key, object, source) {
  743. return func.call(thisArg, value, other, key, object, source);
  744. };
  745. }
  746. return function() {
  747. return func.apply(thisArg, arguments);
  748. };
  749. }
  750. /**
  751. * This method returns the first argument provided to it.
  752. *
  753. * @static
  754. * @memberOf _
  755. * @category Utility
  756. * @param {*} value Any value.
  757. * @returns {*} Returns `value`.
  758. * @example
  759. *
  760. * var object = { 'user': 'fred' };
  761. * _.identity(object) === object;
  762. * // => true
  763. */
  764. function identity(value) {
  765. return value;
  766. }
  767. module.exports = bindCallback;
  768. },{}],11:[function(require,module,exports){
  769. /**
  770. * lodash 3.0.3 (Custom Build) <https://lodash.com/>
  771. * Build: `lodash modern modularize exports="npm" -o ./`
  772. * Copyright 2012-2015 The Dojo Foundation <http://dojofoundation.org/>
  773. * Based on Underscore.js 1.8.2 <http://underscorejs.org/LICENSE>
  774. * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
  775. * Available under MIT license <https://lodash.com/license>
  776. */
  777. /**
  778. * Used as the maximum length of an array-like value.
  779. * See the [ES spec](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-number.max_safe_integer)
  780. * for more details.
  781. */
  782. var MAX_SAFE_INTEGER = Math.pow(2, 53) - 1;
  783. /**
  784. * Checks if `value` is a valid array-like index.
  785. *
  786. * @private
  787. * @param {*} value The value to check.
  788. * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index.
  789. * @returns {boolean} Returns `true` if `value` is a valid index, else `false`.
  790. */
  791. function isIndex(value, length) {
  792. value = +value;
  793. length = length == null ? MAX_SAFE_INTEGER : length;
  794. return value > -1 && value % 1 == 0 && value < length;
  795. }
  796. /**
  797. * Checks if the provided arguments are from an iteratee call.
  798. *
  799. * @private
  800. * @param {*} value The potential iteratee value argument.
  801. * @param {*} index The potential iteratee index or key argument.
  802. * @param {*} object The potential iteratee object argument.
  803. * @returns {boolean} Returns `true` if the arguments are from an iteratee call, else `false`.
  804. */
  805. function isIterateeCall(value, index, object) {
  806. if (!isObject(object)) {
  807. return false;
  808. }
  809. var type = typeof index;
  810. if (type == 'number') {
  811. var length = object.length,
  812. prereq = isLength(length) && isIndex(index, length);
  813. } else {
  814. prereq = type == 'string' && index in object;
  815. }
  816. if (prereq) {
  817. var other = object[index];
  818. return value === value ? value === other : other !== other;
  819. }
  820. return false;
  821. }
  822. /**
  823. * Checks if `value` is a valid array-like length.
  824. *
  825. * **Note:** This function is based on ES `ToLength`. See the
  826. * [ES spec](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-tolength)
  827. * for more details.
  828. *
  829. * @private
  830. * @param {*} value The value to check.
  831. * @returns {boolean} Returns `true` if `value` is a valid length, else `false`.
  832. */
  833. function isLength(value) {
  834. return typeof value == 'number' && value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;
  835. }
  836. /**
  837. * Checks if `value` is the language type of `Object`.
  838. * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)
  839. *
  840. * **Note:** See the [ES5 spec](https://es5.github.io/#x8) for more details.
  841. *
  842. * @static
  843. * @memberOf _
  844. * @category Lang
  845. * @param {*} value The value to check.
  846. * @returns {boolean} Returns `true` if `value` is an object, else `false`.
  847. * @example
  848. *
  849. * _.isObject({});
  850. * // => true
  851. *
  852. * _.isObject([1, 2, 3]);
  853. * // => true
  854. *
  855. * _.isObject(1);
  856. * // => false
  857. */
  858. function isObject(value) {
  859. // Avoid a V8 JIT bug in Chrome 19-20.
  860. // See https://code.google.com/p/v8/issues/detail?id=2291 for more details.
  861. var type = typeof value;
  862. return type == 'function' || (value && type == 'object') || false;
  863. }
  864. module.exports = isIterateeCall;
  865. },{}],12:[function(require,module,exports){
  866. /**
  867. * lodash 3.0.0 (Custom Build) <https://lodash.com/>
  868. * Build: `lodash modern modularize exports="npm" -o ./`
  869. * Copyright 2012-2015 The Dojo Foundation <http://dojofoundation.org/>
  870. * Based on Underscore.js 1.7.0 <http://underscorejs.org/LICENSE>
  871. * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
  872. * Available under MIT license <https://lodash.com/license>
  873. */
  874. var baseCallback = require('lodash._basecallback'),
  875. baseEach = require('lodash._baseeach'),
  876. baseFind = require('lodash._basefind'),
  877. findIndex = require('lodash.findindex'),
  878. isArray = require('lodash.isarray');
  879. /**
  880. * Iterates over elements of `collection`, returning the first element
  881. * `predicate` returns truthy for. The predicate is bound to `thisArg` and
  882. * invoked with three arguments; (value, index|key, collection).
  883. *
  884. * If a property name is provided for `predicate` the created "_.property"
  885. * style callback returns the property value of the given element.
  886. *
  887. * If an object is provided for `predicate` the created "_.matches" style
  888. * callback returns `true` for elements that have the properties of the given
  889. * object, else `false`.
  890. *
  891. * @static
  892. * @memberOf _
  893. * @alias detect
  894. * @category Collection
  895. * @param {Array|Object|string} collection The collection to search.
  896. * @param {Function|Object|string} [predicate=_.identity] The function invoked
  897. * per iteration. If a property name or object is provided it is used to
  898. * create a "_.property" or "_.matches" style callback respectively.
  899. * @param {*} [thisArg] The `this` binding of `predicate`.
  900. * @returns {*} Returns the matched element, else `undefined`.
  901. * @example
  902. *
  903. * var users = [
  904. * { 'user': 'barney', 'age': 36, 'active': false },
  905. * { 'user': 'fred', 'age': 40, 'active': true },
  906. * { 'user': 'pebbles', 'age': 1, 'active': false }
  907. * ];
  908. *
  909. * _.result(_.find(users, function(chr) { return chr.age < 40; }), 'user');
  910. * // => 'barney'
  911. *
  912. * // using the "_.matches" callback shorthand
  913. * _.result(_.find(users, { 'age': 1 }), 'user');
  914. * // => 'pebbles'
  915. *
  916. * // using the "_.property" callback shorthand
  917. * _.result(_.find(users, 'active'), 'user');
  918. * // => 'fred'
  919. */
  920. function find(collection, predicate, thisArg) {
  921. if (isArray(collection)) {
  922. var index = findIndex(collection, predicate, thisArg);
  923. return index > -1 ? collection[index] : undefined;
  924. }
  925. predicate = baseCallback(predicate, thisArg, 3);
  926. return baseFind(collection, predicate, baseEach);
  927. }
  928. module.exports = find;
  929. },{"lodash._basecallback":13,"lodash._baseeach":20,"lodash._basefind":24,"lodash.findindex":25,"lodash.isarray":26}],13:[function(require,module,exports){
  930. /**
  931. * lodash 3.1.2 (Custom Build) <https://lodash.com/>
  932. * Build: `lodash modern modularize exports="npm" -o ./`
  933. * Copyright 2012-2015 The Dojo Foundation <http://dojofoundation.org/>
  934. * Based on Underscore.js 1.7.0 <http://underscorejs.org/LICENSE>
  935. * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
  936. * Available under MIT license <https://lodash.com/license>
  937. */
  938. var baseIsEqual = require('lodash._baseisequal'),
  939. bindCallback = require('lodash._bindcallback'),
  940. keys = require('lodash.keys');
  941. /** Used for native method references. */
  942. var objectProto = Object.prototype;
  943. /** Used to check objects for own properties. */
  944. var hasOwnProperty = objectProto.hasOwnProperty;
  945. /**
  946. * The base implementation of `_.callback` which supports specifying the
  947. * number of arguments to provide to `func`.
  948. *
  949. * @private
  950. * @param {*} [func=_.identity] The value to convert to a callback.
  951. * @param {*} [thisArg] The `this` binding of `func`.
  952. * @param {number} [argCount] The number of arguments to provide to `func`.
  953. * @returns {Function} Returns the callback.
  954. */
  955. function baseCallback(func, thisArg, argCount) {
  956. var type = typeof func;
  957. if (type == 'function') {
  958. return (typeof thisArg != 'undefined')
  959. ? bindCallback(func, thisArg, argCount)
  960. : func;
  961. }
  962. if (func == null) {
  963. return identity;
  964. }
  965. if (type == 'object') {
  966. return baseMatches(func);
  967. }
  968. return typeof thisArg == 'undefined'
  969. ? baseProperty(func + '')
  970. : baseMatchesProperty(func + '', thisArg);
  971. }
  972. /**
  973. * The base implementation of `_.isMatch` without support for callback
  974. * shorthands or `this` binding.
  975. *
  976. * @private
  977. * @param {Object} object The object to inspect.
  978. * @param {Array} props The source property names to match.
  979. * @param {Array} values The source values to match.
  980. * @param {Array} strictCompareFlags Strict comparison flags for source values.
  981. * @param {Function} [customizer] The function to customize comparing objects.
  982. * @returns {boolean} Returns `true` if `object` is a match, else `false`.
  983. */
  984. function baseIsMatch(object, props, values, strictCompareFlags, customizer) {
  985. var length = props.length;
  986. if (object == null) {
  987. return !length;
  988. }
  989. var index = -1,
  990. noCustomizer = !customizer;
  991. while (++index < length) {
  992. if ((noCustomizer && strictCompareFlags[index])
  993. ? values[index] !== object[props[index]]
  994. : !hasOwnProperty.call(object, props[index])
  995. ) {
  996. return false;
  997. }
  998. }
  999. index = -1;
  1000. while (++index < length) {
  1001. var key = props[index];
  1002. if (noCustomizer && strictCompareFlags[index]) {
  1003. var result = hasOwnProperty.call(object, key);
  1004. } else {
  1005. var objValue = object[key],
  1006. srcValue = values[index];
  1007. result = customizer ? customizer(objValue, srcValue, key) : undefined;
  1008. if (typeof result == 'undefined') {
  1009. result = baseIsEqual(srcValue, objValue, customizer, true);
  1010. }
  1011. }
  1012. if (!result) {
  1013. return false;
  1014. }
  1015. }
  1016. return true;
  1017. }
  1018. /**
  1019. * The base implementation of `_.matches` which does not clone `source`.
  1020. *
  1021. * @private
  1022. * @param {Object} source The object of property values to match.
  1023. * @returns {Function} Returns the new function.
  1024. */
  1025. function baseMatches(source) {
  1026. var props = keys(source),
  1027. length = props.length;
  1028. if (length == 1) {
  1029. var key = props[0],
  1030. value = source[key];
  1031. if (isStrictComparable(value)) {
  1032. return function(object) {
  1033. return object != null && object[key] === value && hasOwnProperty.call(object, key);
  1034. };
  1035. }
  1036. }
  1037. var values = Array(length),
  1038. strictCompareFlags = Array(length);
  1039. while (length--) {
  1040. value = source[props[length]];
  1041. values[length] = value;
  1042. strictCompareFlags[length] = isStrictComparable(value);
  1043. }
  1044. return function(object) {
  1045. return baseIsMatch(object, props, values, strictCompareFlags);
  1046. };
  1047. }
  1048. /**
  1049. * The base implementation of `_.matchesProperty` which does not coerce `key`
  1050. * to a string.
  1051. *
  1052. * @private
  1053. * @param {string} key The key of the property to get.
  1054. * @param {*} value The value to compare.
  1055. * @returns {Function} Returns the new function.
  1056. */
  1057. function baseMatchesProperty(key, value) {
  1058. if (isStrictComparable(value)) {
  1059. return function(object) {
  1060. return object != null && object[key] === value;
  1061. };
  1062. }
  1063. return function(object) {
  1064. return object != null && baseIsEqual(value, object[key], null, true);
  1065. };
  1066. }
  1067. /**
  1068. * The base implementation of `_.property` which does not coerce `key` to a string.
  1069. *
  1070. * @private
  1071. * @param {string} key The key of the property to get.
  1072. * @returns {Function} Returns the new function.
  1073. */
  1074. function baseProperty(key) {
  1075. return function(object) {
  1076. return object == null ? undefined : object[key];
  1077. };
  1078. }
  1079. /**
  1080. * Checks if `value` is suitable for strict equality comparisons, i.e. `===`.
  1081. *
  1082. * @private
  1083. * @param {*} value The value to check.
  1084. * @returns {boolean} Returns `true` if `value` if suitable for strict
  1085. * equality comparisons, else `false`.
  1086. */
  1087. function isStrictComparable(value) {
  1088. return value === value && (value === 0 ? ((1 / value) > 0) : !isObject(value));
  1089. }
  1090. /**
  1091. * Checks if `value` is the language type of `Object`.
  1092. * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)
  1093. *
  1094. * **Note:** See the [ES5 spec](https://es5.github.io/#x8) for more details.
  1095. *
  1096. * @static
  1097. * @memberOf _
  1098. * @category Lang
  1099. * @param {*} value The value to check.
  1100. * @returns {boolean} Returns `true` if `value` is an object, else `false`.
  1101. * @example
  1102. *
  1103. * _.isObject({});
  1104. * // => true
  1105. *
  1106. * _.isObject([1, 2, 3]);
  1107. * // => true
  1108. *
  1109. * _.isObject(1);
  1110. * // => false
  1111. */
  1112. function isObject(value) {
  1113. // Avoid a V8 JIT bug in Chrome 19-20.
  1114. // See https://code.google.com/p/v8/issues/detail?id=2291 for more details.
  1115. var type = typeof value;
  1116. return type == 'function' || (value && type == 'object') || false;
  1117. }
  1118. /**
  1119. * This method returns the first argument provided to it.
  1120. *
  1121. * @static
  1122. * @memberOf _
  1123. * @category Utility
  1124. * @param {*} value Any value.
  1125. * @returns {*} Returns `value`.
  1126. * @example
  1127. *
  1128. * var object = { 'user': 'fred' };
  1129. * _.identity(object) === object;
  1130. * // => true
  1131. */
  1132. function identity(value) {
  1133. return value;
  1134. }
  1135. module.exports = baseCallback;
  1136. },{"lodash._baseisequal":14,"lodash._bindcallback":16,"lodash.keys":17}],14:[function(require,module,exports){
  1137. /**
  1138. * lodash 3.0.0 (Custom Build) <https://lodash.com/>
  1139. * Build: `lodash modern modularize exports="npm" -o ./`
  1140. * Copyright 2012-2015 The Dojo Foundation <http://dojofoundation.org/>
  1141. * Based on Underscore.js 1.7.0 <http://underscorejs.org/LICENSE>
  1142. * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
  1143. * Available under MIT license <https://lodash.com/license>
  1144. */
  1145. var isArray = require('lodash.isarray'),
  1146. isTypedArray = require('lodash.istypedarray'),
  1147. keys = require('lodash.keys');
  1148. /** `Object#toString` result references. */
  1149. var argsTag = '[object Arguments]',
  1150. arrayTag = '[object Array]',
  1151. boolTag = '[object Boolean]',
  1152. dateTag = '[object Date]',
  1153. errorTag = '[object Error]',
  1154. numberTag = '[object Number]',
  1155. objectTag = '[object Object]',
  1156. regexpTag = '[object RegExp]',
  1157. stringTag = '[object String]';
  1158. /** Used for native method references. */
  1159. var objectProto = Object.prototype;
  1160. /** Used to check objects for own properties. */
  1161. var hasOwnProperty = objectProto.hasOwnProperty;
  1162. /**
  1163. * Used to resolve the `toStringTag` of values.
  1164. * See the [ES spec](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-object.prototype.tostring)
  1165. * for more details.
  1166. */
  1167. var objToString = objectProto.toString;
  1168. /**
  1169. * The base implementation of `_.isEqual` without support for `this` binding
  1170. * `customizer` functions.
  1171. *
  1172. * @private
  1173. * @param {*} value The value to compare.
  1174. * @param {*} other The other value to compare.
  1175. * @param {Function} [customizer] The function to customize comparing values.
  1176. * @param {boolean} [isWhere] Specify performing partial comparisons.
  1177. * @param {Array} [stackA] Tracks traversed `value` objects.
  1178. * @param {Array} [stackB] Tracks traversed `other` objects.
  1179. * @returns {boolean} Returns `true` if the values are equivalent, else `false`.
  1180. */
  1181. function baseIsEqual(value, other, customizer, isWhere, stackA, stackB) {
  1182. // Exit early for identical values.
  1183. if (value === other) {
  1184. // Treat `+0` vs. `-0` as not equal.
  1185. return value !== 0 || (1 / value == 1 / other);
  1186. }
  1187. var valType = typeof value,
  1188. othType = typeof other;
  1189. // Exit early for unlike primitive values.
  1190. if ((valType != 'function' && valType != 'object' && othType != 'function' && othType != 'object') ||
  1191. value == null || other == null) {
  1192. // Return `false` unless both values are `NaN`.
  1193. return value !== value && other !== other;
  1194. }
  1195. return baseIsEqualDeep(value, other, baseIsEqual, customizer, isWhere, stackA, stackB);
  1196. }
  1197. /**
  1198. * A specialized version of `baseIsEqual` for arrays and objects which performs
  1199. * deep comparisons and tracks traversed objects enabling objects with circular
  1200. * references to be compared.
  1201. *
  1202. * @private
  1203. * @param {Object} object The object to compare.
  1204. * @param {Object} other The other object to compare.
  1205. * @param {Function} equalFunc The function to determine equivalents of values.
  1206. * @param {Function} [customizer] The function to customize comparing objects.
  1207. * @param {boolean} [isWhere] Specify performing partial comparisons.
  1208. * @param {Array} [stackA=[]] Tracks traversed `value` objects.
  1209. * @param {Array} [stackB=[]] Tracks traversed `other` objects.
  1210. * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.
  1211. */
  1212. function baseIsEqualDeep(object, other, equalFunc, customizer, isWhere, stackA, stackB) {
  1213. var objIsArr = isArray(object),
  1214. othIsArr = isArray(other),
  1215. objTag = arrayTag,
  1216. othTag = arrayTag;
  1217. if (!objIsArr) {
  1218. objTag = objToString.call(object);
  1219. if (objTag == argsTag) {
  1220. objTag = objectTag;
  1221. } else if (objTag != objectTag) {
  1222. objIsArr = isTypedArray(object);
  1223. }
  1224. }
  1225. if (!othIsArr) {
  1226. othTag = objToString.call(other);
  1227. if (othTag == argsTag) {
  1228. othTag = objectTag;
  1229. } else if (othTag != objectTag) {
  1230. othIsArr = isTypedArray(other);
  1231. }
  1232. }
  1233. var objIsObj = objTag == objectTag,
  1234. othIsObj = othTag == objectTag,
  1235. isSameTag = objTag == othTag;
  1236. if (isSameTag && !(objIsArr || objIsObj)) {
  1237. return equalByTag(object, other, objTag);
  1238. }
  1239. var valWrapped = objIsObj && hasOwnProperty.call(object, '__wrapped__'),
  1240. othWrapped = othIsObj && hasOwnProperty.call(other, '__wrapped__');
  1241. if (valWrapped || othWrapped) {
  1242. return equalFunc(valWrapped ? object.value() : object, othWrapped ? other.value() : other, customizer, isWhere, stackA, stackB);
  1243. }
  1244. if (!isSameTag) {
  1245. return false;
  1246. }
  1247. // Assume cyclic values are equal.
  1248. // For more information on detecting circular references see https://es5.github.io/#JO.
  1249. stackA || (stackA = []);
  1250. stackB || (stackB = []);
  1251. var length = stackA.length;
  1252. while (length--) {
  1253. if (stackA[length] == object) {
  1254. return stackB[length] == other;
  1255. }
  1256. }
  1257. // Add `object` and `other` to the stack of traversed objects.
  1258. stackA.push(object);
  1259. stackB.push(other);
  1260. var result = (objIsArr ? equalArrays : equalObjects)(object, other, equalFunc, customizer, isWhere, stackA, stackB);
  1261. stackA.pop();
  1262. stackB.pop();
  1263. return result;
  1264. }
  1265. /**
  1266. * A specialized version of `baseIsEqualDeep` for arrays with support for
  1267. * partial deep comparisons.
  1268. *
  1269. * @private
  1270. * @param {Array} array The array to compare.
  1271. * @param {Array} other The other array to compare.
  1272. * @param {Function} equalFunc The function to determine equivalents of values.
  1273. * @param {Function} [customizer] The function to customize comparing arrays.
  1274. * @param {boolean} [isWhere] Specify performing partial comparisons.
  1275. * @param {Array} [stackA] Tracks traversed `value` objects.
  1276. * @param {Array} [stackB] Tracks traversed `other` objects.
  1277. * @returns {boolean} Returns `true` if the arrays are equivalent, else `false`.
  1278. */
  1279. function equalArrays(array, other, equalFunc, customizer, isWhere, stackA, stackB) {
  1280. var index = -1,
  1281. arrLength = array.length,
  1282. othLength = other.length,
  1283. result = true;
  1284. if (arrLength != othLength && !(isWhere && othLength > arrLength)) {
  1285. return false;
  1286. }
  1287. // Deep compare the contents, ignoring non-numeric properties.
  1288. while (result && ++index < arrLength) {
  1289. var arrValue = array[index],
  1290. othValue = other[index];
  1291. result = undefined;
  1292. if (customizer) {
  1293. result = isWhere
  1294. ? customizer(othValue, arrValue, index)
  1295. : customizer(arrValue, othValue, index);
  1296. }
  1297. if (typeof result == 'undefined') {
  1298. // Recursively compare arrays (susceptible to call stack limits).
  1299. if (isWhere) {
  1300. var othIndex = othLength;
  1301. while (othIndex--) {
  1302. othValue = other[othIndex];
  1303. result = (arrValue && arrValue === othValue) || equalFunc(arrValue, othValue, customizer, isWhere, stackA, stackB);
  1304. if (result) {
  1305. break;
  1306. }
  1307. }
  1308. } else {
  1309. result = (arrValue && arrValue === othValue) || equalFunc(arrValue, othValue, customizer, isWhere, stackA, stackB);
  1310. }
  1311. }
  1312. }
  1313. return !!result;
  1314. }
  1315. /**
  1316. * A specialized version of `baseIsEqualDeep` for comparing objects of
  1317. * the same `toStringTag`.
  1318. *
  1319. * **Note:** This function only supports comparing values with tags of
  1320. * `Boolean`, `Date`, `Error`, `Number`, `RegExp`, or `String`.
  1321. *
  1322. * @private
  1323. * @param {Object} value The object to compare.
  1324. * @param {Object} other The other object to compare.
  1325. * @param {string} tag The `toStringTag` of the objects to compare.
  1326. * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.
  1327. */
  1328. function equalByTag(object, other, tag) {
  1329. switch (tag) {
  1330. case boolTag:
  1331. case dateTag:
  1332. // Coerce dates and booleans to numbers, dates to milliseconds and booleans
  1333. // to `1` or `0` treating invalid dates coerced to `NaN` as not equal.
  1334. return +object == +other;
  1335. case errorTag:
  1336. return object.name == other.name && object.message == other.message;
  1337. case numberTag:
  1338. // Treat `NaN` vs. `NaN` as equal.
  1339. return (object != +object)
  1340. ? other != +other
  1341. // But, treat `-0` vs. `+0` as not equal.
  1342. : (object == 0 ? ((1 / object) == (1 / other)) : object == +other);
  1343. case regexpTag:
  1344. case stringTag:
  1345. // Coerce regexes to strings and treat strings primitives and string
  1346. // objects as equal. See https://es5.github.io/#x15.10.6.4 for more details.
  1347. return object == (other + '');
  1348. }
  1349. return false;
  1350. }
  1351. /**
  1352. * A specialized version of `baseIsEqualDeep` for objects with support for
  1353. * partial deep comparisons.
  1354. *
  1355. * @private
  1356. * @param {Object} object The object to compare.
  1357. * @param {Object} other The other object to compare.
  1358. * @param {Function} equalFunc The function to determine equivalents of values.
  1359. * @param {Function} [customizer] The function to customize comparing values.
  1360. * @param {boolean} [isWhere] Specify performing partial comparisons.
  1361. * @param {Array} [stackA] Tracks traversed `value` objects.
  1362. * @param {Array} [stackB] Tracks traversed `other` objects.
  1363. * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.
  1364. */
  1365. function equalObjects(object, other, equalFunc, customizer, isWhere, stackA, stackB) {
  1366. var objProps = keys(object),
  1367. objLength = objProps.length,
  1368. othProps = keys(other),
  1369. othLength = othProps.length;
  1370. if (objLength != othLength && !isWhere) {
  1371. return false;
  1372. }
  1373. var hasCtor,
  1374. index = -1;
  1375. while (++index < objLength) {
  1376. var key = objProps[index],
  1377. result = hasOwnProperty.call(other, key);
  1378. if (result) {
  1379. var objValue = object[key],
  1380. othValue = other[key];
  1381. result = undefined;
  1382. if (customizer) {
  1383. result = isWhere
  1384. ? customizer(othValue, objValue, key)
  1385. : customizer(objValue, othValue, key);
  1386. }
  1387. if (typeof result == 'undefined') {
  1388. // Recursively compare objects (susceptible to call stack limits).
  1389. result = (objValue && objValue === othValue) || equalFunc(objValue, othValue, customizer, isWhere, stackA, stackB);
  1390. }
  1391. }
  1392. if (!result) {
  1393. return false;
  1394. }
  1395. hasCtor || (hasCtor = key == 'constructor');
  1396. }
  1397. if (!hasCtor) {
  1398. var objCtor = object.constructor,
  1399. othCtor = other.constructor;
  1400. // Non `Object` object instances with different constructors are not equal.
  1401. if (objCtor != othCtor && ('constructor' in object && 'constructor' in other) &&
  1402. !(typeof objCtor == 'function' && objCtor instanceof objCtor && typeof othCtor == 'function' && othCtor instanceof othCtor)) {
  1403. return false;
  1404. }
  1405. }
  1406. return true;
  1407. }
  1408. module.exports = baseIsEqual;
  1409. },{"lodash.isarray":26,"lodash.istypedarray":15,"lodash.keys":17}],15:[function(require,module,exports){
  1410. /**
  1411. * lodash 3.0.0 (Custom Build) <https://lodash.com/>
  1412. * Build: `lodash modern modularize exports="npm" -o ./`
  1413. * Copyright 2012-2015 The Dojo Foundation <http://dojofoundation.org/>
  1414. * Based on Underscore.js 1.7.0 <http://underscorejs.org/LICENSE>
  1415. * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
  1416. * Available under MIT license <https://lodash.com/license>
  1417. */
  1418. /** `Object#toString` result references. */
  1419. var argsTag = '[object Arguments]',
  1420. arrayTag = '[object Array]',
  1421. boolTag = '[object Boolean]',
  1422. dateTag = '[object Date]',
  1423. errorTag = '[object Error]',
  1424. funcTag = '[object Function]',
  1425. mapTag = '[object Map]',
  1426. numberTag = '[object Number]',
  1427. objectTag = '[object Object]',
  1428. regexpTag = '[object RegExp]',
  1429. setTag = '[object Set]',
  1430. stringTag = '[object String]',
  1431. weakMapTag = '[object WeakMap]';
  1432. var arrayBufferTag = '[object ArrayBuffer]',
  1433. float32Tag = '[object Float32Array]',
  1434. float64Tag = '[object Float64Array]',
  1435. int8Tag = '[object Int8Array]',
  1436. int16Tag = '[object Int16Array]',
  1437. int32Tag = '[object Int32Array]',
  1438. uint8Tag = '[object Uint8Array]',
  1439. uint8ClampedTag