diff --git a/mopidy_iris/static/app/app.js b/mopidy_iris/static/app/app.js index 03e305f0..12f45751 100644 --- a/mopidy_iris/static/app/app.js +++ b/mopidy_iris/static/app/app.js @@ -60,7 +60,7 @@ /******/ __webpack_require__.p = ""; /******/ /******/ // Load entry module and return exports -/******/ return __webpack_require__(__webpack_require__.s = 115); +/******/ return __webpack_require__(__webpack_require__.s = 94); /******/ }) /************************************************************************/ /******/ ([ @@ -71,12 +71,12 @@ /* WEBPACK VAR INJECTION */(function(process) { if (process.env.NODE_ENV === 'production') { - module.exports = __webpack_require__(116); + module.exports = __webpack_require__(95); } else { - module.exports = __webpack_require__(117); + module.exports = __webpack_require__(96); } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(6))) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(10))) /***/ }), /* 1 */ @@ -2027,7 +2027,7 @@ Object.defineProperty(__webpack_exports__, "__esModule", { value: true }); /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "applyMiddleware", function() { return applyMiddleware; }); /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "compose", function() { return compose; }); /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "__DO_NOT_USE__ActionTypes", function() { return ActionTypes; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_symbol_observable__ = __webpack_require__(142); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_symbol_observable__ = __webpack_require__(114); /** @@ -2665,7 +2665,7 @@ if (process.env.NODE_ENV !== 'production' && typeof isCrushed.name === 'string' -/* WEBPACK VAR INJECTION */}.call(__webpack_exports__, __webpack_require__(6))) +/* WEBPACK VAR INJECTION */}.call(__webpack_exports__, __webpack_require__(10))) /***/ }), /* 3 */ @@ -3024,10 +3024,10 @@ function processFinished(key) { "use strict"; Object.defineProperty(__webpack_exports__, "__esModule", { value: true }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__components_Provider__ = __webpack_require__(129); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__components_connectAdvanced__ = __webpack_require__(86); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__components_Context__ = __webpack_require__(60); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__connect_connect__ = __webpack_require__(139); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__components_Provider__ = __webpack_require__(104); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__components_connectAdvanced__ = __webpack_require__(69); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__components_Context__ = __webpack_require__(54); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__connect_connect__ = __webpack_require__(111); /* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "Provider", function() { return __WEBPACK_IMPORTED_MODULE_0__components_Provider__["a"]; }); /* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "connectAdvanced", function() { return __WEBPACK_IMPORTED_MODULE_1__components_connectAdvanced__["a"]; }); /* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "ReactReduxContext", function() { return __WEBPACK_IMPORTED_MODULE_2__components_Context__["a"]; }); @@ -3055,7 +3055,7 @@ var _react = __webpack_require__(0); var _react2 = _interopRequireDefault(_react); -var _reactFontawesome = __webpack_require__(240); +var _reactFontawesome = __webpack_require__(188); var _reactFontawesome2 = _interopRequireDefault(_reactFontawesome); @@ -3140,196 +3140,6 @@ exports.default = Icon; /***/ }), /* 6 */ -/***/ (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; }; - - -/***/ }), -/* 7 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -3945,7 +3755,7 @@ function getQueueHistory() { } /***/ }), -/* 8 */ +/* 7 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -3961,9 +3771,9 @@ var _react = __webpack_require__(0); var _react2 = _interopRequireDefault(_react); -var _reactRouter = __webpack_require__(38); +var _reactRouter = __webpack_require__(35); -var _reactRouterDom = __webpack_require__(32); +var _reactRouterDom = __webpack_require__(30); var _helpers = __webpack_require__(1); @@ -4046,6 +3856,14 @@ var CustomLink = function (_React$Component) { className += this.props.className; } + if (!this.props.to) { + return _react2.default.createElement( + 'span', + { className: className }, + this.props.children + ); + } + // We have an active detector method // This is used almost solely by the Sidebar navigation if (this.props.history !== undefined) { @@ -4080,7 +3898,7 @@ var CustomLink = function (_React$Component) { exports.default = (0, _reactRouter.withRouter)(CustomLink); /***/ }), -/* 9 */ +/* 8 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -4146,10 +3964,10 @@ exports.getLibraryAlbumsProcessor = getLibraryAlbumsProcessor; function _toConsumableArray(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } else { return Array.from(arr); } } -var coreActions = __webpack_require__(10); +var coreActions = __webpack_require__(9); var uiActions = __webpack_require__(3); -var mopidyActions = __webpack_require__(7); -var lastfmActions = __webpack_require__(16); +var mopidyActions = __webpack_require__(6); +var lastfmActions = __webpack_require__(17); var helpers = __webpack_require__(1); /** @@ -5542,9 +5360,33 @@ function getAllPlaylistTracksProcessor(data) { // Add on our new batch of loaded tracks var uris = []; var new_uris = []; - for (var i = 0; i < response.items.length; i++) { - new_uris.push(response.items[i].track.uri); + var _iteratorNormalCompletion3 = true; + var _didIteratorError3 = false; + var _iteratorError3 = undefined; + + try { + for (var _iterator3 = response.items[Symbol.iterator](), _step3; !(_iteratorNormalCompletion3 = (_step3 = _iterator3.next()).done); _iteratorNormalCompletion3 = true) { + var item = _step3.value; + + if (item.track) { + new_uris.push(item.track.uri); + } + } + } catch (err) { + _didIteratorError3 = true; + _iteratorError3 = err; + } finally { + try { + if (!_iteratorNormalCompletion3 && _iterator3.return) { + _iterator3.return(); + } + } finally { + if (_didIteratorError3) { + throw _iteratorError3; + } + } } + if (data.uris) { uris = [].concat(_toConsumableArray(data.uris), new_uris); } else { @@ -5834,10 +5676,10 @@ function getLibraryAlbumsProcessor(data) { }); }; } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(17))) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(18))) /***/ }), -/* 10 */ +/* 9 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -5888,8 +5730,8 @@ var helpers = _interopRequireWildcard(_helpers); function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } } -var spotifyActions = __webpack_require__(9); -var mopidyActions = __webpack_require__(7); +var spotifyActions = __webpack_require__(8); +var mopidyActions = __webpack_require__(6); function getBroadcasts() { return function (dispatch, getState) { @@ -6278,7 +6120,197 @@ function getLibraryArtists() { type: 'GET_LIBRARY_ARTISTS' }; } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(17))) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(18))) + +/***/ }), +/* 10 */ +/***/ (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; }; + /***/ }), /* 11 */ @@ -6301,7 +6333,7 @@ var _reactRedux = __webpack_require__(4); var _redux = __webpack_require__(2); -var _Link = __webpack_require__(8); +var _Link = __webpack_require__(7); var _Link2 = _interopRequireDefault(_Link); @@ -6420,6 +6452,32 @@ exports.default = (0, _reactRedux.connect)(mapStateToProps, mapDispatchToProps)( /* 12 */ /***/ (function(module, exports, __webpack_require__) { +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright (c) 2013-present, Facebook, Inc. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */ + +if (process.env.NODE_ENV !== 'production') { + var ReactIs = __webpack_require__(44); + + // By explicitly using `prop-types` you are opting into new development behavior. + // http://fb.me/prop-types-in-prod + var throwOnDirectAccess = true; + module.exports = __webpack_require__(107)(ReactIs.isElement, throwOnDirectAccess); +} else { + // By explicitly using `prop-types` you are opting into new production behavior. + // http://fb.me/prop-types-in-prod + module.exports = __webpack_require__(108)(); +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(10))) + +/***/ }), +/* 13 */ +/***/ (function(module, exports, __webpack_require__) { + "use strict"; @@ -6712,7 +6770,7 @@ function commandsUpdated(commands) { } /***/ }), -/* 13 */ +/* 14 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -6834,7 +6892,7 @@ var Header = function (_React$Component) { exports.default = Header; /***/ }), -/* 14 */ +/* 15 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; @@ -6852,14 +6910,14 @@ Object.defineProperty(__webpack_exports__, "__esModule", { value: true }); /* harmony export (immutable) */ __webpack_exports__["outboundLink"] = outboundLink; /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "OutboundLink", function() { return OutboundLink; }); /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "testModeAPI", function() { return testModeAPI; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__utils_format__ = __webpack_require__(187); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__utils_removeLeadingSlash__ = __webpack_require__(190); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__utils_trim__ = __webpack_require__(98); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__utils_loadGA__ = __webpack_require__(191); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__utils_console_warn__ = __webpack_require__(68); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__utils_console_log__ = __webpack_require__(192); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__utils_testModeAPI__ = __webpack_require__(193); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__components_OutboundLink__ = __webpack_require__(194); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__utils_format__ = __webpack_require__(151); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__utils_removeLeadingSlash__ = __webpack_require__(154); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__utils_trim__ = __webpack_require__(82); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__utils_loadGA__ = __webpack_require__(155); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__utils_console_warn__ = __webpack_require__(59); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__utils_console_log__ = __webpack_require__(156); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__utils_testModeAPI__ = __webpack_require__(157); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__components_OutboundLink__ = __webpack_require__(158); function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; } function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; } @@ -7474,7 +7532,7 @@ var testModeAPI = __WEBPACK_IMPORTED_MODULE_6__utils_testModeAPI__["a" /* defaul }); /***/ }), -/* 15 */ +/* 16 */ /***/ (function(module, exports) { module.exports = function() { @@ -7483,7 +7541,7 @@ module.exports = function() { /***/ }), -/* 16 */ +/* 17 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -7505,7 +7563,7 @@ exports.loveTrack = loveTrack; exports.unloveTrack = unloveTrack; exports.scrobble = scrobble; -var coreActions = __webpack_require__(10); +var coreActions = __webpack_require__(9); var uiActions = __webpack_require__(3); var helpers = __webpack_require__(1); @@ -7905,10 +7963,10 @@ function scrobble(track) { }); }; } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(17))) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(18))) /***/ }), -/* 17 */ +/* 18 */ /***/ (function(module, exports, __webpack_require__) { var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*! @@ -18279,7 +18337,7 @@ return jQuery; /***/ }), -/* 18 */ +/* 19 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -18295,7 +18353,7 @@ var _react = __webpack_require__(0); var _react2 = _interopRequireDefault(_react); -var _Link = __webpack_require__(8); +var _Link = __webpack_require__(7); var _Link2 = _interopRequireDefault(_Link); @@ -18399,7 +18457,7 @@ var URILink = function (_React$Component) { exports.default = URILink; /***/ }), -/* 19 */ +/* 20 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -18419,7 +18477,7 @@ var _reactRedux = __webpack_require__(4); var _redux = __webpack_require__(2); -var _Track = __webpack_require__(248); +var _Track = __webpack_require__(196); var _Track2 = _interopRequireDefault(_Track); @@ -18431,7 +18489,7 @@ var _helpers = __webpack_require__(1); var helpers = _interopRequireWildcard(_helpers); -var _actions = __webpack_require__(7); +var _actions = __webpack_require__(6); var mopidyActions = _interopRequireWildcard(_actions); @@ -18955,42 +19013,7 @@ var mapDispatchToProps = function mapDispatchToProps(dispatch) { }; exports.default = (0, _reactRedux.connect)(mapStateToProps, mapDispatchToProps)(TrackList); -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(17))) - -/***/ }), -/* 20 */ -/***/ (function(module, exports, __webpack_require__) { - -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright (c) 2013-present, Facebook, Inc. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */ - -if (process.env.NODE_ENV !== 'production') { - var REACT_ELEMENT_TYPE = (typeof Symbol === 'function' && - Symbol.for && - Symbol.for('react.element')) || - 0xeac7; - - var isValidElement = function(object) { - return typeof object === 'object' && - object !== null && - object.$$typeof === REACT_ELEMENT_TYPE; - }; - - // By explicitly using `prop-types` you are opting into new development behavior. - // http://fb.me/prop-types-in-prod - var throwOnDirectAccess = true; - module.exports = __webpack_require__(151)(isValidElement, throwOnDirectAccess); -} else { - // By explicitly using `prop-types` you are opting into new production behavior. - // http://fb.me/prop-types-in-prod - module.exports = __webpack_require__(153)(); -} - -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(6))) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(18))) /***/ }), /* 21 */ @@ -19009,7 +19032,7 @@ var _react = __webpack_require__(0); var _react2 = _interopRequireDefault(_react); -var _URILink = __webpack_require__(18); +var _URILink = __webpack_require__(19); var _URILink2 = _interopRequireDefault(_URILink); @@ -19390,69 +19413,12 @@ var mapDispatchToProps = function mapDispatchToProps(dispatch) { }; exports.default = (0, _reactRedux.connect)(mapStateToProps, mapDispatchToProps)(Modal); -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(17))) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(18))) /***/ }), /* 25 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright (c) 2013-present, Facebook, Inc. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */ - - - -/** - * Use invariant() to assert state which your program assumes to be true. - * - * Provide sprintf-style format (only %s is supported) and arguments - * to provide information about what broke and what you were - * expecting. - * - * The invariant message will be stripped in production, but the invariant - * will remain to ensure logic does not differ in production. - */ - -var invariant = function(condition, format, a, b, c, d, e, f) { - if (process.env.NODE_ENV !== 'production') { - if (format === undefined) { - throw new Error('invariant requires an error message argument'); - } - } - - if (!condition) { - var error; - if (format === undefined) { - error = new Error( - 'Minified exception occurred; use the non-minified dev environment ' + - 'for the full error message and additional helpful warnings.' - ); - } else { - var args = [a, b, c, d, e, f]; - var argIndex = 0; - error = new Error( - format.replace(/%s/g, function() { return args[argIndex++]; }) - ); - error.name = 'Invariant Violation'; - } - - error.framesToPop = 1; // we don't care about invariant's own frame - throw error; - } -}; - -module.exports = invariant; - -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(6))) - -/***/ }), -/* 26 */ -/***/ (function(module, exports, __webpack_require__) { - "use strict"; @@ -19628,7 +19594,7 @@ var Dater = function (_React$Component) { exports.default = Dater; /***/ }), -/* 27 */ +/* 26 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -19840,7 +19806,64 @@ var DropdownField = function (_React$Component) { }(_react2.default.Component); exports.default = DropdownField; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(17))) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(18))) + +/***/ }), +/* 27 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright (c) 2013-present, Facebook, Inc. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */ + + + +/** + * Use invariant() to assert state which your program assumes to be true. + * + * Provide sprintf-style format (only %s is supported) and arguments + * to provide information about what broke and what you were + * expecting. + * + * The invariant message will be stripped in production, but the invariant + * will remain to ensure logic does not differ in production. + */ + +var invariant = function(condition, format, a, b, c, d, e, f) { + if (process.env.NODE_ENV !== 'production') { + if (format === undefined) { + throw new Error('invariant requires an error message argument'); + } + } + + if (!condition) { + var error; + if (format === undefined) { + error = new Error( + 'Minified exception occurred; use the non-minified dev environment ' + + 'for the full error message and additional helpful warnings.' + ); + } else { + var args = [a, b, c, d, e, f]; + var argIndex = 0; + error = new Error( + format.replace(/%s/g, function() { return args[argIndex++]; }) + ); + error.name = 'Invariant Violation'; + } + + error.framesToPop = 1; // we don't care about invariant's own frame + throw error; + } +}; + +module.exports = invariant; + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(10))) /***/ }), /* 28 */ @@ -19870,9 +19893,9 @@ var warning = function() {}; if (__DEV__) { var printWarning = function printWarning(format, args) { var len = arguments.length; - args = new Array(len > 2 ? len - 2 : 0); - for (var key = 2; key < len; key++) { - args[key - 2] = arguments[key]; + args = new Array(len > 1 ? len - 1 : 0); + for (var key = 1; key < len; key++) { + args[key - 1] = arguments[key]; } var argIndex = 0; var message = 'Warning: ' + @@ -19910,47 +19933,12 @@ if (__DEV__) { module.exports = warning; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(6))) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(10))) /***/ }), /* 29 */ /***/ (function(module, exports, __webpack_require__) { -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright (c) 2013-present, Facebook, Inc. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */ - -if (process.env.NODE_ENV !== 'production') { - var REACT_ELEMENT_TYPE = (typeof Symbol === 'function' && - Symbol.for && - Symbol.for('react.element')) || - 0xeac7; - - var isValidElement = function(object) { - return typeof object === 'object' && - object !== null && - object.$$typeof === REACT_ELEMENT_TYPE; - }; - - // By explicitly using `prop-types` you are opting into new development behavior. - // http://fb.me/prop-types-in-prod - var throwOnDirectAccess = true; - module.exports = __webpack_require__(228)(isValidElement, throwOnDirectAccess); -} else { - // By explicitly using `prop-types` you are opting into new production behavior. - // http://fb.me/prop-types-in-prod - module.exports = __webpack_require__(230)(); -} - -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(6))) - -/***/ }), -/* 30 */ -/***/ (function(module, exports, __webpack_require__) { - "use strict"; @@ -20076,135 +20064,38 @@ var Parallax = function (_React$Component) { exports.default = Parallax; /***/ }), -/* 31 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/* -object-assign -(c) Sindre Sorhus -@license MIT -*/ - - -/* eslint-disable no-unused-vars */ -var getOwnPropertySymbols = Object.getOwnPropertySymbols; -var hasOwnProperty = Object.prototype.hasOwnProperty; -var propIsEnumerable = Object.prototype.propertyIsEnumerable; - -function toObject(val) { - if (val === null || val === undefined) { - throw new TypeError('Object.assign cannot be called with null or undefined'); - } - - return Object(val); -} - -function shouldUseNative() { - try { - if (!Object.assign) { - return false; - } - - // Detect buggy property enumeration order in older V8 versions. - - // https://bugs.chromium.org/p/v8/issues/detail?id=4118 - var test1 = new String('abc'); // eslint-disable-line no-new-wrappers - test1[5] = 'de'; - if (Object.getOwnPropertyNames(test1)[0] === '5') { - return false; - } - - // https://bugs.chromium.org/p/v8/issues/detail?id=3056 - var test2 = {}; - for (var i = 0; i < 10; i++) { - test2['_' + String.fromCharCode(i)] = i; - } - var order2 = Object.getOwnPropertyNames(test2).map(function (n) { - return test2[n]; - }); - if (order2.join('') !== '0123456789') { - return false; - } - - // https://bugs.chromium.org/p/v8/issues/detail?id=3056 - var test3 = {}; - 'abcdefghijklmnopqrst'.split('').forEach(function (letter) { - test3[letter] = letter; - }); - if (Object.keys(Object.assign({}, test3)).join('') !== - 'abcdefghijklmnopqrst') { - return false; - } - - return true; - } catch (err) { - // We don't expect any of the above to throw, but better to be safe. - return false; - } -} - -module.exports = shouldUseNative() ? Object.assign : function (target, source) { - var from; - var to = toObject(target); - var symbols; - - for (var s = 1; s < arguments.length; s++) { - from = Object(arguments[s]); - - for (var key in from) { - if (hasOwnProperty.call(from, key)) { - to[key] = from[key]; - } - } - - if (getOwnPropertySymbols) { - symbols = getOwnPropertySymbols(from); - for (var i = 0; i < symbols.length; i++) { - if (propIsEnumerable.call(from, symbols[i])) { - to[symbols[i]] = from[symbols[i]]; - } - } - } - } - - return to; -}; - - -/***/ }), -/* 32 */ +/* 30 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; Object.defineProperty(__webpack_exports__, "__esModule", { value: true }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__BrowserRouter__ = __webpack_require__(150); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__BrowserRouter__ = __webpack_require__(122); /* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "BrowserRouter", function() { return __WEBPACK_IMPORTED_MODULE_0__BrowserRouter__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__HashRouter__ = __webpack_require__(157); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__HashRouter__ = __webpack_require__(127); /* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "HashRouter", function() { return __WEBPACK_IMPORTED_MODULE_1__HashRouter__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__Link__ = __webpack_require__(94); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__Link__ = __webpack_require__(73); /* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "Link", function() { return __WEBPACK_IMPORTED_MODULE_2__Link__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__MemoryRouter__ = __webpack_require__(158); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__MemoryRouter__ = __webpack_require__(128); /* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "MemoryRouter", function() { return __WEBPACK_IMPORTED_MODULE_3__MemoryRouter__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__NavLink__ = __webpack_require__(160); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__NavLink__ = __webpack_require__(129); /* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "NavLink", function() { return __WEBPACK_IMPORTED_MODULE_4__NavLink__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__Prompt__ = __webpack_require__(162); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__Prompt__ = __webpack_require__(131); /* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "Prompt", function() { return __WEBPACK_IMPORTED_MODULE_5__Prompt__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__Redirect__ = __webpack_require__(164); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__Redirect__ = __webpack_require__(132); /* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "Redirect", function() { return __WEBPACK_IMPORTED_MODULE_6__Redirect__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__Route__ = __webpack_require__(95); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__Route__ = __webpack_require__(75); /* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "Route", function() { return __WEBPACK_IMPORTED_MODULE_7__Route__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__Router__ = __webpack_require__(65); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__Router__ = __webpack_require__(56); /* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "Router", function() { return __WEBPACK_IMPORTED_MODULE_8__Router__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__StaticRouter__ = __webpack_require__(166); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__StaticRouter__ = __webpack_require__(133); /* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "StaticRouter", function() { return __WEBPACK_IMPORTED_MODULE_9__StaticRouter__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10__Switch__ = __webpack_require__(168); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10__Switch__ = __webpack_require__(134); /* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "Switch", function() { return __WEBPACK_IMPORTED_MODULE_10__Switch__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11__generatePath__ = __webpack_require__(170); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11__generatePath__ = __webpack_require__(135); /* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "generatePath", function() { return __WEBPACK_IMPORTED_MODULE_11__generatePath__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12__matchPath__ = __webpack_require__(171); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12__matchPath__ = __webpack_require__(136); /* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "matchPath", function() { return __WEBPACK_IMPORTED_MODULE_12__matchPath__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13__withRouter__ = __webpack_require__(172); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13__withRouter__ = __webpack_require__(137); /* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "withRouter", function() { return __WEBPACK_IMPORTED_MODULE_13__withRouter__["a"]; }); @@ -20236,44 +20127,7 @@ Object.defineProperty(__webpack_exports__, "__esModule", { value: true }); /***/ }), -/* 33 */ -/***/ (function(module, exports, __webpack_require__) { - -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - */ - -if (process.env.NODE_ENV !== 'production') { - var REACT_ELEMENT_TYPE = (typeof Symbol === 'function' && - Symbol.for && - Symbol.for('react.element')) || - 0xeac7; - - var isValidElement = function(object) { - return typeof object === 'object' && - object !== null && - object.$$typeof === REACT_ELEMENT_TYPE; - }; - - // By explicitly using `prop-types` you are opting into new development behavior. - // http://fb.me/prop-types-in-prod - var throwOnDirectAccess = true; - module.exports = __webpack_require__(195)(isValidElement, throwOnDirectAccess); -} else { - // By explicitly using `prop-types` you are opting into new production behavior. - // http://fb.me/prop-types-in-prod - module.exports = __webpack_require__(197)(); -} - -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(6))) - -/***/ }), -/* 34 */ +/* 31 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -20337,34 +20191,931 @@ var ErrorMessage = function (_React$Component) { exports.default = ErrorMessage; /***/ }), -/* 35 */ +/* 32 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__createBrowserHistory__ = __webpack_require__(154); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return __WEBPACK_IMPORTED_MODULE_0__createBrowserHistory__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__createHashHistory__ = __webpack_require__(155); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return __WEBPACK_IMPORTED_MODULE_1__createHashHistory__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__createMemoryHistory__ = __webpack_require__(156); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "d", function() { return __WEBPACK_IMPORTED_MODULE_2__createMemoryHistory__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__LocationUtils__ = __webpack_require__(51); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return __WEBPACK_IMPORTED_MODULE_3__LocationUtils__["a"]; }); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "f", function() { return __WEBPACK_IMPORTED_MODULE_3__LocationUtils__["b"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__PathUtils__ = __webpack_require__(43); -/* unused harmony reexport parsePath */ -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "e", function() { return __WEBPACK_IMPORTED_MODULE_4__PathUtils__["b"]; }); +/* WEBPACK VAR INJECTION */(function(process) {/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return createBrowserHistory; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return createHashHistory; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "d", function() { return createMemoryHistory; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return createLocation; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "f", function() { return locationsAreEqual; }); +/* unused harmony export parsePath */ +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "e", function() { return createPath; }); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__babel_runtime_helpers_esm_extends__ = __webpack_require__(45); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_resolve_pathname__ = __webpack_require__(123); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_value_equal__ = __webpack_require__(124); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_tiny_warning__ = __webpack_require__(125); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_tiny_invariant__ = __webpack_require__(126); +function addLeadingSlash(path) { + return path.charAt(0) === '/' ? path : '/' + path; +} +function stripLeadingSlash(path) { + return path.charAt(0) === '/' ? path.substr(1) : path; +} +function hasBasename(path, prefix) { + return new RegExp('^' + prefix + '(\\/|\\?|#|$)', 'i').test(path); +} +function stripBasename(path, prefix) { + return hasBasename(path, prefix) ? path.substr(prefix.length) : path; +} +function stripTrailingSlash(path) { + return path.charAt(path.length - 1) === '/' ? path.slice(0, -1) : path; +} +function parsePath(path) { + var pathname = path || '/'; + var search = ''; + var hash = ''; + var hashIndex = pathname.indexOf('#'); + + if (hashIndex !== -1) { + hash = pathname.substr(hashIndex); + pathname = pathname.substr(0, hashIndex); + } + + var searchIndex = pathname.indexOf('?'); + + if (searchIndex !== -1) { + search = pathname.substr(searchIndex); + pathname = pathname.substr(0, searchIndex); + } + + return { + pathname: pathname, + search: search === '?' ? '' : search, + hash: hash === '#' ? '' : hash + }; +} +function createPath(location) { + var pathname = location.pathname, + search = location.search, + hash = location.hash; + var path = pathname || '/'; + if (search && search !== '?') path += search.charAt(0) === '?' ? search : "?" + search; + if (hash && hash !== '#') path += hash.charAt(0) === '#' ? hash : "#" + hash; + return path; +} + +function createLocation(path, state, key, currentLocation) { + var location; + + if (typeof path === 'string') { + // Two-arg form: push(path, state) + location = parsePath(path); + location.state = state; + } else { + // One-arg form: push(location) + location = Object(__WEBPACK_IMPORTED_MODULE_0__babel_runtime_helpers_esm_extends__["a" /* default */])({}, path); + if (location.pathname === undefined) location.pathname = ''; + + if (location.search) { + if (location.search.charAt(0) !== '?') location.search = '?' + location.search; + } else { + location.search = ''; + } + + if (location.hash) { + if (location.hash.charAt(0) !== '#') location.hash = '#' + location.hash; + } else { + location.hash = ''; + } + + if (state !== undefined && location.state === undefined) location.state = state; + } + + try { + location.pathname = decodeURI(location.pathname); + } catch (e) { + if (e instanceof URIError) { + throw new URIError('Pathname "' + location.pathname + '" could not be decoded. ' + 'This is likely caused by an invalid percent-encoding.'); + } else { + throw e; + } + } + + if (key) location.key = key; + + if (currentLocation) { + // Resolve incomplete/relative pathname relative to current location. + if (!location.pathname) { + location.pathname = currentLocation.pathname; + } else if (location.pathname.charAt(0) !== '/') { + location.pathname = Object(__WEBPACK_IMPORTED_MODULE_1_resolve_pathname__["a" /* default */])(location.pathname, currentLocation.pathname); + } + } else { + // When there is no prior location and pathname is empty, set it to / + if (!location.pathname) { + location.pathname = '/'; + } + } + + return location; +} +function locationsAreEqual(a, b) { + return a.pathname === b.pathname && a.search === b.search && a.hash === b.hash && a.key === b.key && Object(__WEBPACK_IMPORTED_MODULE_2_value_equal__["a" /* default */])(a.state, b.state); +} + +function createTransitionManager() { + var prompt = null; + + function setPrompt(nextPrompt) { + process.env.NODE_ENV !== "production" ? Object(__WEBPACK_IMPORTED_MODULE_3_tiny_warning__["a" /* default */])(prompt == null, 'A history supports only one prompt at a time') : void 0; + prompt = nextPrompt; + return function () { + if (prompt === nextPrompt) prompt = null; + }; + } + + function confirmTransitionTo(location, action, getUserConfirmation, callback) { + // TODO: If another transition starts while we're still confirming + // the previous one, we may end up in a weird state. Figure out the + // best way to handle this. + if (prompt != null) { + var result = typeof prompt === 'function' ? prompt(location, action) : prompt; + + if (typeof result === 'string') { + if (typeof getUserConfirmation === 'function') { + getUserConfirmation(result, callback); + } else { + process.env.NODE_ENV !== "production" ? Object(__WEBPACK_IMPORTED_MODULE_3_tiny_warning__["a" /* default */])(false, 'A history needs a getUserConfirmation function in order to use a prompt message') : void 0; + callback(true); + } + } else { + // Return false from a transition hook to cancel the transition. + callback(result !== false); + } + } else { + callback(true); + } + } + + var listeners = []; + + function appendListener(fn) { + var isActive = true; + + function listener() { + if (isActive) fn.apply(void 0, arguments); + } + + listeners.push(listener); + return function () { + isActive = false; + listeners = listeners.filter(function (item) { + return item !== listener; + }); + }; + } + + function notifyListeners() { + for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) { + args[_key] = arguments[_key]; + } + + listeners.forEach(function (listener) { + return listener.apply(void 0, args); + }); + } + + return { + setPrompt: setPrompt, + confirmTransitionTo: confirmTransitionTo, + appendListener: appendListener, + notifyListeners: notifyListeners + }; +} + +var canUseDOM = !!(typeof window !== 'undefined' && window.document && window.document.createElement); +function getConfirmation(message, callback) { + callback(window.confirm(message)); // eslint-disable-line no-alert +} +/** + * Returns true if the HTML5 history API is supported. Taken from Modernizr. + * + * https://github.com/Modernizr/Modernizr/blob/master/LICENSE + * https://github.com/Modernizr/Modernizr/blob/master/feature-detects/history.js + * changed to avoid false negatives for Windows Phones: https://github.com/reactjs/react-router/issues/586 + */ + +function supportsHistory() { + var ua = window.navigator.userAgent; + if ((ua.indexOf('Android 2.') !== -1 || ua.indexOf('Android 4.0') !== -1) && ua.indexOf('Mobile Safari') !== -1 && ua.indexOf('Chrome') === -1 && ua.indexOf('Windows Phone') === -1) return false; + return window.history && 'pushState' in window.history; +} +/** + * Returns true if browser fires popstate on hash change. + * IE10 and IE11 do not. + */ + +function supportsPopStateOnHashChange() { + return window.navigator.userAgent.indexOf('Trident') === -1; +} +/** + * Returns false if using go(n) with hash history causes a full page reload. + */ + +function supportsGoWithoutReloadUsingHash() { + return window.navigator.userAgent.indexOf('Firefox') === -1; +} +/** + * Returns true if a given popstate event is an extraneous WebKit event. + * Accounts for the fact that Chrome on iOS fires real popstate events + * containing undefined state when pressing the back button. + */ + +function isExtraneousPopstateEvent(event) { + event.state === undefined && navigator.userAgent.indexOf('CriOS') === -1; +} + +var PopStateEvent = 'popstate'; +var HashChangeEvent = 'hashchange'; + +function getHistoryState() { + try { + return window.history.state || {}; + } catch (e) { + // IE 11 sometimes throws when accessing window.history.state + // See https://github.com/ReactTraining/history/pull/289 + return {}; + } +} +/** + * Creates a history object that uses the HTML5 history API including + * pushState, replaceState, and the popstate event. + */ + + +function createBrowserHistory(props) { + if (props === void 0) { + props = {}; + } + + !canUseDOM ? process.env.NODE_ENV !== "production" ? Object(__WEBPACK_IMPORTED_MODULE_4_tiny_invariant__["a" /* default */])(false, 'Browser history needs a DOM') : Object(__WEBPACK_IMPORTED_MODULE_4_tiny_invariant__["a" /* default */])(false) : void 0; + var globalHistory = window.history; + var canUseHistory = supportsHistory(); + var needsHashChangeListener = !supportsPopStateOnHashChange(); + var _props = props, + _props$forceRefresh = _props.forceRefresh, + forceRefresh = _props$forceRefresh === void 0 ? false : _props$forceRefresh, + _props$getUserConfirm = _props.getUserConfirmation, + getUserConfirmation = _props$getUserConfirm === void 0 ? getConfirmation : _props$getUserConfirm, + _props$keyLength = _props.keyLength, + keyLength = _props$keyLength === void 0 ? 6 : _props$keyLength; + var basename = props.basename ? stripTrailingSlash(addLeadingSlash(props.basename)) : ''; + + function getDOMLocation(historyState) { + var _ref = historyState || {}, + key = _ref.key, + state = _ref.state; + + var _window$location = window.location, + pathname = _window$location.pathname, + search = _window$location.search, + hash = _window$location.hash; + var path = pathname + search + hash; + process.env.NODE_ENV !== "production" ? Object(__WEBPACK_IMPORTED_MODULE_3_tiny_warning__["a" /* default */])(!basename || hasBasename(path, basename), 'You are attempting to use a basename on a page whose URL path does not begin ' + 'with the basename. Expected path "' + path + '" to begin with "' + basename + '".') : void 0; + if (basename) path = stripBasename(path, basename); + return createLocation(path, state, key); + } + + function createKey() { + return Math.random().toString(36).substr(2, keyLength); + } + + var transitionManager = createTransitionManager(); + + function setState(nextState) { + Object(__WEBPACK_IMPORTED_MODULE_0__babel_runtime_helpers_esm_extends__["a" /* default */])(history, nextState); + + history.length = globalHistory.length; + transitionManager.notifyListeners(history.location, history.action); + } + + function handlePopState(event) { + // Ignore extraneous popstate events in WebKit. + if (isExtraneousPopstateEvent(event)) return; + handlePop(getDOMLocation(event.state)); + } + + function handleHashChange() { + handlePop(getDOMLocation(getHistoryState())); + } + + var forceNextPop = false; + + function handlePop(location) { + if (forceNextPop) { + forceNextPop = false; + setState(); + } else { + var action = 'POP'; + transitionManager.confirmTransitionTo(location, action, getUserConfirmation, function (ok) { + if (ok) { + setState({ + action: action, + location: location + }); + } else { + revertPop(location); + } + }); + } + } + + function revertPop(fromLocation) { + var toLocation = history.location; // TODO: We could probably make this more reliable by + // keeping a list of keys we've seen in sessionStorage. + // Instead, we just default to 0 for keys we don't know. + + var toIndex = allKeys.indexOf(toLocation.key); + if (toIndex === -1) toIndex = 0; + var fromIndex = allKeys.indexOf(fromLocation.key); + if (fromIndex === -1) fromIndex = 0; + var delta = toIndex - fromIndex; + + if (delta) { + forceNextPop = true; + go(delta); + } + } + + var initialLocation = getDOMLocation(getHistoryState()); + var allKeys = [initialLocation.key]; // Public interface + + function createHref(location) { + return basename + createPath(location); + } + + function push(path, state) { + process.env.NODE_ENV !== "production" ? Object(__WEBPACK_IMPORTED_MODULE_3_tiny_warning__["a" /* default */])(!(typeof path === 'object' && path.state !== undefined && state !== undefined), 'You should avoid providing a 2nd state argument to push when the 1st ' + 'argument is a location-like object that already has state; it is ignored') : void 0; + var action = 'PUSH'; + var location = createLocation(path, state, createKey(), history.location); + transitionManager.confirmTransitionTo(location, action, getUserConfirmation, function (ok) { + if (!ok) return; + var href = createHref(location); + var key = location.key, + state = location.state; + + if (canUseHistory) { + globalHistory.pushState({ + key: key, + state: state + }, null, href); + + if (forceRefresh) { + window.location.href = href; + } else { + var prevIndex = allKeys.indexOf(history.location.key); + var nextKeys = allKeys.slice(0, prevIndex === -1 ? 0 : prevIndex + 1); + nextKeys.push(location.key); + allKeys = nextKeys; + setState({ + action: action, + location: location + }); + } + } else { + process.env.NODE_ENV !== "production" ? Object(__WEBPACK_IMPORTED_MODULE_3_tiny_warning__["a" /* default */])(state === undefined, 'Browser history cannot push state in browsers that do not support HTML5 history') : void 0; + window.location.href = href; + } + }); + } + + function replace(path, state) { + process.env.NODE_ENV !== "production" ? Object(__WEBPACK_IMPORTED_MODULE_3_tiny_warning__["a" /* default */])(!(typeof path === 'object' && path.state !== undefined && state !== undefined), 'You should avoid providing a 2nd state argument to replace when the 1st ' + 'argument is a location-like object that already has state; it is ignored') : void 0; + var action = 'REPLACE'; + var location = createLocation(path, state, createKey(), history.location); + transitionManager.confirmTransitionTo(location, action, getUserConfirmation, function (ok) { + if (!ok) return; + var href = createHref(location); + var key = location.key, + state = location.state; + + if (canUseHistory) { + globalHistory.replaceState({ + key: key, + state: state + }, null, href); + + if (forceRefresh) { + window.location.replace(href); + } else { + var prevIndex = allKeys.indexOf(history.location.key); + if (prevIndex !== -1) allKeys[prevIndex] = location.key; + setState({ + action: action, + location: location + }); + } + } else { + process.env.NODE_ENV !== "production" ? Object(__WEBPACK_IMPORTED_MODULE_3_tiny_warning__["a" /* default */])(state === undefined, 'Browser history cannot replace state in browsers that do not support HTML5 history') : void 0; + window.location.replace(href); + } + }); + } + + function go(n) { + globalHistory.go(n); + } + + function goBack() { + go(-1); + } + + function goForward() { + go(1); + } + + var listenerCount = 0; + + function checkDOMListeners(delta) { + listenerCount += delta; + + if (listenerCount === 1 && delta === 1) { + window.addEventListener(PopStateEvent, handlePopState); + if (needsHashChangeListener) window.addEventListener(HashChangeEvent, handleHashChange); + } else if (listenerCount === 0) { + window.removeEventListener(PopStateEvent, handlePopState); + if (needsHashChangeListener) window.removeEventListener(HashChangeEvent, handleHashChange); + } + } + + var isBlocked = false; + + function block(prompt) { + if (prompt === void 0) { + prompt = false; + } + + var unblock = transitionManager.setPrompt(prompt); + + if (!isBlocked) { + checkDOMListeners(1); + isBlocked = true; + } + + return function () { + if (isBlocked) { + isBlocked = false; + checkDOMListeners(-1); + } + + return unblock(); + }; + } + + function listen(listener) { + var unlisten = transitionManager.appendListener(listener); + checkDOMListeners(1); + return function () { + checkDOMListeners(-1); + unlisten(); + }; + } + + var history = { + length: globalHistory.length, + action: 'POP', + location: initialLocation, + createHref: createHref, + push: push, + replace: replace, + go: go, + goBack: goBack, + goForward: goForward, + block: block, + listen: listen + }; + return history; +} + +var HashChangeEvent$1 = 'hashchange'; +var HashPathCoders = { + hashbang: { + encodePath: function encodePath(path) { + return path.charAt(0) === '!' ? path : '!/' + stripLeadingSlash(path); + }, + decodePath: function decodePath(path) { + return path.charAt(0) === '!' ? path.substr(1) : path; + } + }, + noslash: { + encodePath: stripLeadingSlash, + decodePath: addLeadingSlash + }, + slash: { + encodePath: addLeadingSlash, + decodePath: addLeadingSlash + } +}; + +function getHashPath() { + // We can't use window.location.hash here because it's not + // consistent across browsers - Firefox will pre-decode it! + var href = window.location.href; + var hashIndex = href.indexOf('#'); + return hashIndex === -1 ? '' : href.substring(hashIndex + 1); +} + +function pushHashPath(path) { + window.location.hash = path; +} + +function replaceHashPath(path) { + var hashIndex = window.location.href.indexOf('#'); + window.location.replace(window.location.href.slice(0, hashIndex >= 0 ? hashIndex : 0) + '#' + path); +} + +function createHashHistory(props) { + if (props === void 0) { + props = {}; + } + + !canUseDOM ? process.env.NODE_ENV !== "production" ? Object(__WEBPACK_IMPORTED_MODULE_4_tiny_invariant__["a" /* default */])(false, 'Hash history needs a DOM') : Object(__WEBPACK_IMPORTED_MODULE_4_tiny_invariant__["a" /* default */])(false) : void 0; + var globalHistory = window.history; + var canGoWithoutReload = supportsGoWithoutReloadUsingHash(); + var _props = props, + _props$getUserConfirm = _props.getUserConfirmation, + getUserConfirmation = _props$getUserConfirm === void 0 ? getConfirmation : _props$getUserConfirm, + _props$hashType = _props.hashType, + hashType = _props$hashType === void 0 ? 'slash' : _props$hashType; + var basename = props.basename ? stripTrailingSlash(addLeadingSlash(props.basename)) : ''; + var _HashPathCoders$hashT = HashPathCoders[hashType], + encodePath = _HashPathCoders$hashT.encodePath, + decodePath = _HashPathCoders$hashT.decodePath; + + function getDOMLocation() { + var path = decodePath(getHashPath()); + process.env.NODE_ENV !== "production" ? Object(__WEBPACK_IMPORTED_MODULE_3_tiny_warning__["a" /* default */])(!basename || hasBasename(path, basename), 'You are attempting to use a basename on a page whose URL path does not begin ' + 'with the basename. Expected path "' + path + '" to begin with "' + basename + '".') : void 0; + if (basename) path = stripBasename(path, basename); + return createLocation(path); + } + + var transitionManager = createTransitionManager(); + + function setState(nextState) { + Object(__WEBPACK_IMPORTED_MODULE_0__babel_runtime_helpers_esm_extends__["a" /* default */])(history, nextState); + + history.length = globalHistory.length; + transitionManager.notifyListeners(history.location, history.action); + } + + var forceNextPop = false; + var ignorePath = null; + + function handleHashChange() { + var path = getHashPath(); + var encodedPath = encodePath(path); + + if (path !== encodedPath) { + // Ensure we always have a properly-encoded hash. + replaceHashPath(encodedPath); + } else { + var location = getDOMLocation(); + var prevLocation = history.location; + if (!forceNextPop && locationsAreEqual(prevLocation, location)) return; // A hashchange doesn't always == location change. + + if (ignorePath === createPath(location)) return; // Ignore this change; we already setState in push/replace. + + ignorePath = null; + handlePop(location); + } + } + + function handlePop(location) { + if (forceNextPop) { + forceNextPop = false; + setState(); + } else { + var action = 'POP'; + transitionManager.confirmTransitionTo(location, action, getUserConfirmation, function (ok) { + if (ok) { + setState({ + action: action, + location: location + }); + } else { + revertPop(location); + } + }); + } + } + + function revertPop(fromLocation) { + var toLocation = history.location; // TODO: We could probably make this more reliable by + // keeping a list of paths we've seen in sessionStorage. + // Instead, we just default to 0 for paths we don't know. + + var toIndex = allPaths.lastIndexOf(createPath(toLocation)); + if (toIndex === -1) toIndex = 0; + var fromIndex = allPaths.lastIndexOf(createPath(fromLocation)); + if (fromIndex === -1) fromIndex = 0; + var delta = toIndex - fromIndex; + + if (delta) { + forceNextPop = true; + go(delta); + } + } // Ensure the hash is encoded properly before doing anything else. + + + var path = getHashPath(); + var encodedPath = encodePath(path); + if (path !== encodedPath) replaceHashPath(encodedPath); + var initialLocation = getDOMLocation(); + var allPaths = [createPath(initialLocation)]; // Public interface + + function createHref(location) { + return '#' + encodePath(basename + createPath(location)); + } + + function push(path, state) { + process.env.NODE_ENV !== "production" ? Object(__WEBPACK_IMPORTED_MODULE_3_tiny_warning__["a" /* default */])(state === undefined, 'Hash history cannot push state; it is ignored') : void 0; + var action = 'PUSH'; + var location = createLocation(path, undefined, undefined, history.location); + transitionManager.confirmTransitionTo(location, action, getUserConfirmation, function (ok) { + if (!ok) return; + var path = createPath(location); + var encodedPath = encodePath(basename + path); + var hashChanged = getHashPath() !== encodedPath; + + if (hashChanged) { + // We cannot tell if a hashchange was caused by a PUSH, so we'd + // rather setState here and ignore the hashchange. The caveat here + // is that other hash histories in the page will consider it a POP. + ignorePath = path; + pushHashPath(encodedPath); + var prevIndex = allPaths.lastIndexOf(createPath(history.location)); + var nextPaths = allPaths.slice(0, prevIndex === -1 ? 0 : prevIndex + 1); + nextPaths.push(path); + allPaths = nextPaths; + setState({ + action: action, + location: location + }); + } else { + process.env.NODE_ENV !== "production" ? Object(__WEBPACK_IMPORTED_MODULE_3_tiny_warning__["a" /* default */])(false, 'Hash history cannot PUSH the same path; a new entry will not be added to the history stack') : void 0; + setState(); + } + }); + } + + function replace(path, state) { + process.env.NODE_ENV !== "production" ? Object(__WEBPACK_IMPORTED_MODULE_3_tiny_warning__["a" /* default */])(state === undefined, 'Hash history cannot replace state; it is ignored') : void 0; + var action = 'REPLACE'; + var location = createLocation(path, undefined, undefined, history.location); + transitionManager.confirmTransitionTo(location, action, getUserConfirmation, function (ok) { + if (!ok) return; + var path = createPath(location); + var encodedPath = encodePath(basename + path); + var hashChanged = getHashPath() !== encodedPath; + + if (hashChanged) { + // We cannot tell if a hashchange was caused by a REPLACE, so we'd + // rather setState here and ignore the hashchange. The caveat here + // is that other hash histories in the page will consider it a POP. + ignorePath = path; + replaceHashPath(encodedPath); + } + + var prevIndex = allPaths.indexOf(createPath(history.location)); + if (prevIndex !== -1) allPaths[prevIndex] = path; + setState({ + action: action, + location: location + }); + }); + } + + function go(n) { + process.env.NODE_ENV !== "production" ? Object(__WEBPACK_IMPORTED_MODULE_3_tiny_warning__["a" /* default */])(canGoWithoutReload, 'Hash history go(n) causes a full page reload in this browser') : void 0; + globalHistory.go(n); + } + + function goBack() { + go(-1); + } + + function goForward() { + go(1); + } + + var listenerCount = 0; + + function checkDOMListeners(delta) { + listenerCount += delta; + + if (listenerCount === 1 && delta === 1) { + window.addEventListener(HashChangeEvent$1, handleHashChange); + } else if (listenerCount === 0) { + window.removeEventListener(HashChangeEvent$1, handleHashChange); + } + } + + var isBlocked = false; + + function block(prompt) { + if (prompt === void 0) { + prompt = false; + } + + var unblock = transitionManager.setPrompt(prompt); + + if (!isBlocked) { + checkDOMListeners(1); + isBlocked = true; + } + + return function () { + if (isBlocked) { + isBlocked = false; + checkDOMListeners(-1); + } + + return unblock(); + }; + } + + function listen(listener) { + var unlisten = transitionManager.appendListener(listener); + checkDOMListeners(1); + return function () { + checkDOMListeners(-1); + unlisten(); + }; + } + + var history = { + length: globalHistory.length, + action: 'POP', + location: initialLocation, + createHref: createHref, + push: push, + replace: replace, + go: go, + goBack: goBack, + goForward: goForward, + block: block, + listen: listen + }; + return history; +} + +function clamp(n, lowerBound, upperBound) { + return Math.min(Math.max(n, lowerBound), upperBound); +} +/** + * Creates a history object that stores locations in memory. + */ + + +function createMemoryHistory(props) { + if (props === void 0) { + props = {}; + } + + var _props = props, + getUserConfirmation = _props.getUserConfirmation, + _props$initialEntries = _props.initialEntries, + initialEntries = _props$initialEntries === void 0 ? ['/'] : _props$initialEntries, + _props$initialIndex = _props.initialIndex, + initialIndex = _props$initialIndex === void 0 ? 0 : _props$initialIndex, + _props$keyLength = _props.keyLength, + keyLength = _props$keyLength === void 0 ? 6 : _props$keyLength; + var transitionManager = createTransitionManager(); + + function setState(nextState) { + Object(__WEBPACK_IMPORTED_MODULE_0__babel_runtime_helpers_esm_extends__["a" /* default */])(history, nextState); + + history.length = history.entries.length; + transitionManager.notifyListeners(history.location, history.action); + } + + function createKey() { + return Math.random().toString(36).substr(2, keyLength); + } + + var index = clamp(initialIndex, 0, initialEntries.length - 1); + var entries = initialEntries.map(function (entry) { + return typeof entry === 'string' ? createLocation(entry, undefined, createKey()) : createLocation(entry, undefined, entry.key || createKey()); + }); // Public interface + + var createHref = createPath; + + function push(path, state) { + process.env.NODE_ENV !== "production" ? Object(__WEBPACK_IMPORTED_MODULE_3_tiny_warning__["a" /* default */])(!(typeof path === 'object' && path.state !== undefined && state !== undefined), 'You should avoid providing a 2nd state argument to push when the 1st ' + 'argument is a location-like object that already has state; it is ignored') : void 0; + var action = 'PUSH'; + var location = createLocation(path, state, createKey(), history.location); + transitionManager.confirmTransitionTo(location, action, getUserConfirmation, function (ok) { + if (!ok) return; + var prevIndex = history.index; + var nextIndex = prevIndex + 1; + var nextEntries = history.entries.slice(0); + + if (nextEntries.length > nextIndex) { + nextEntries.splice(nextIndex, nextEntries.length - nextIndex, location); + } else { + nextEntries.push(location); + } + + setState({ + action: action, + location: location, + index: nextIndex, + entries: nextEntries + }); + }); + } + + function replace(path, state) { + process.env.NODE_ENV !== "production" ? Object(__WEBPACK_IMPORTED_MODULE_3_tiny_warning__["a" /* default */])(!(typeof path === 'object' && path.state !== undefined && state !== undefined), 'You should avoid providing a 2nd state argument to replace when the 1st ' + 'argument is a location-like object that already has state; it is ignored') : void 0; + var action = 'REPLACE'; + var location = createLocation(path, state, createKey(), history.location); + transitionManager.confirmTransitionTo(location, action, getUserConfirmation, function (ok) { + if (!ok) return; + history.entries[history.index] = location; + setState({ + action: action, + location: location + }); + }); + } + + function go(n) { + var nextIndex = clamp(history.index + n, 0, history.entries.length - 1); + var action = 'POP'; + var location = history.entries[nextIndex]; + transitionManager.confirmTransitionTo(location, action, getUserConfirmation, function (ok) { + if (ok) { + setState({ + action: action, + location: location, + index: nextIndex + }); + } else { + // Mimic the behavior of DOM histories by + // causing a render after a cancelled POP. + setState(); + } + }); + } + + function goBack() { + go(-1); + } + + function goForward() { + go(1); + } + + function canGo(n) { + var nextIndex = history.index + n; + return nextIndex >= 0 && nextIndex < history.entries.length; + } + + function block(prompt) { + if (prompt === void 0) { + prompt = false; + } + + return transitionManager.setPrompt(prompt); + } + + function listen(listener) { + return transitionManager.appendListener(listener); + } + + var history = { + length: entries.length, + action: 'POP', + location: entries[index], + index: index, + entries: entries, + createHref: createHref, + push: push, + replace: replace, + go: go, + goBack: goBack, + goForward: goForward, + canGo: canGo, + block: block, + listen: listen + }; + return history; +} +/* WEBPACK VAR INJECTION */}.call(__webpack_exports__, __webpack_require__(10))) /***/ }), -/* 36 */ +/* 33 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -20381,7 +21132,7 @@ exports.getMe = getMe; exports.getTrackLyrics = getTrackLyrics; exports.findTrackLyrics = findTrackLyrics; -var coreActions = __webpack_require__(10); +var coreActions = __webpack_require__(9); var uiActions = __webpack_require__(3); var helpers = __webpack_require__(1); @@ -20594,10 +21345,10 @@ function findTrackLyrics(track) { }); }; } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(17))) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(18))) /***/ }), -/* 37 */ +/* 34 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -20765,30 +21516,30 @@ function streamsLoaded(streams) { } /***/ }), -/* 38 */ +/* 35 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; Object.defineProperty(__webpack_exports__, "__esModule", { value: true }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__MemoryRouter__ = __webpack_require__(227); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__MemoryRouter__ = __webpack_require__(74); /* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "MemoryRouter", function() { return __WEBPACK_IMPORTED_MODULE_0__MemoryRouter__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Prompt__ = __webpack_require__(234); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Prompt__ = __webpack_require__(77); /* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "Prompt", function() { return __WEBPACK_IMPORTED_MODULE_1__Prompt__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__Redirect__ = __webpack_require__(235); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__Redirect__ = __webpack_require__(78); /* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "Redirect", function() { return __WEBPACK_IMPORTED_MODULE_2__Redirect__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__Route__ = __webpack_require__(108); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__Route__ = __webpack_require__(57); /* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "Route", function() { return __WEBPACK_IMPORTED_MODULE_3__Route__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__Router__ = __webpack_require__(77); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__Router__ = __webpack_require__(46); /* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "Router", function() { return __WEBPACK_IMPORTED_MODULE_4__Router__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__StaticRouter__ = __webpack_require__(236); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__StaticRouter__ = __webpack_require__(79); /* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "StaticRouter", function() { return __WEBPACK_IMPORTED_MODULE_5__StaticRouter__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__Switch__ = __webpack_require__(237); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__Switch__ = __webpack_require__(80); /* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "Switch", function() { return __WEBPACK_IMPORTED_MODULE_6__Switch__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__generatePath__ = __webpack_require__(107); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__generatePath__ = __webpack_require__(58); /* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "generatePath", function() { return __WEBPACK_IMPORTED_MODULE_7__generatePath__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__matchPath__ = __webpack_require__(78); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__matchPath__ = __webpack_require__(47); /* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "matchPath", function() { return __WEBPACK_IMPORTED_MODULE_8__matchPath__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__withRouter__ = __webpack_require__(238); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__withRouter__ = __webpack_require__(81); /* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "withRouter", function() { return __WEBPACK_IMPORTED_MODULE_9__withRouter__["a"]; }); @@ -20812,134 +21563,7 @@ Object.defineProperty(__webpack_exports__, "__esModule", { value: true }); /***/ }), -/* 39 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright (c) 2014-present, Facebook, Inc. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */ - - - -/** - * Similar to invariant but only logs a warning if the condition is not met. - * This can be used to log issues in development environments in critical - * paths. Removing the logging code for production environments will keep the - * same logic and follow the same code paths. - */ - -var __DEV__ = process.env.NODE_ENV !== 'production'; - -var warning = function() {}; - -if (__DEV__) { - var printWarning = function printWarning(format, args) { - var len = arguments.length; - args = new Array(len > 2 ? len - 2 : 0); - for (var key = 2; key < len; key++) { - args[key - 2] = arguments[key]; - } - var argIndex = 0; - var message = 'Warning: ' + - format.replace(/%s/g, function() { - return args[argIndex++]; - }); - if (typeof console !== 'undefined') { - console.error(message); - } - try { - // --- Welcome to debugging React --- - // This error was thrown as a convenience so that you can use this stack - // to find the callsite that caused this warning to fire. - throw new Error(message); - } catch (x) {} - } - - warning = function(condition, format, args) { - var len = arguments.length; - args = new Array(len > 2 ? len - 2 : 0); - for (var key = 2; key < len; key++) { - args[key - 2] = arguments[key]; - } - if (format === undefined) { - throw new Error( - '`warning(condition, format, ...args)` requires a warning ' + - 'message argument' - ); - } - if (!condition) { - printWarning.apply(null, [format].concat(args)); - } - }; -} - -module.exports = warning; - -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(6))) - -/***/ }), -/* 40 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright (c) 2013-present, Facebook, Inc. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */ - - - -/** - * Use invariant() to assert state which your program assumes to be true. - * - * Provide sprintf-style format (only %s is supported) and arguments - * to provide information about what broke and what you were - * expecting. - * - * The invariant message will be stripped in production, but the invariant - * will remain to ensure logic does not differ in production. - */ - -var invariant = function(condition, format, a, b, c, d, e, f) { - if (process.env.NODE_ENV !== 'production') { - if (format === undefined) { - throw new Error('invariant requires an error message argument'); - } - } - - if (!condition) { - var error; - if (format === undefined) { - error = new Error( - 'Minified exception occurred; use the non-minified dev environment ' + - 'for the full error message and additional helpful warnings.' - ); - } else { - var args = [a, b, c, d, e, f]; - var argIndex = 0; - error = new Error( - format.replace(/%s/g, function() { return args[argIndex++]; }) - ); - error.name = 'Invariant Violation'; - } - - error.framesToPop = 1; // we don't care about invariant's own frame - throw error; - } -}; - -module.exports = invariant; - -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(6))) - -/***/ }), -/* 41 */ +/* 36 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -20963,7 +21587,7 @@ var _Thumbnail = __webpack_require__(11); var _Thumbnail2 = _interopRequireDefault(_Thumbnail); -var _GridItem = __webpack_require__(42); +var _GridItem = __webpack_require__(37); var _GridItem2 = _interopRequireDefault(_GridItem); @@ -20975,7 +21599,7 @@ var _actions = __webpack_require__(3); var uiActions = _interopRequireWildcard(_actions); -var _actions2 = __webpack_require__(16); +var _actions2 = __webpack_require__(17); var lastfmActions = _interopRequireWildcard(_actions2); @@ -21065,7 +21689,7 @@ var mapDispatchToProps = function mapDispatchToProps(dispatch) { exports.default = (0, _reactRedux.connect)(mapStateToProps, mapDispatchToProps)(ArtistGrid); /***/ }), -/* 42 */ +/* 37 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -21081,7 +21705,7 @@ var _react = __webpack_require__(0); var _react2 = _interopRequireDefault(_react); -var _reactDom = __webpack_require__(58); +var _reactDom = __webpack_require__(53); var _reactDom2 = _interopRequireDefault(_reactDom); @@ -21089,7 +21713,7 @@ var _helpers = __webpack_require__(1); var helpers = _interopRequireWildcard(_helpers); -var _Link = __webpack_require__(8); +var _Link = __webpack_require__(7); var _Link2 = _interopRequireDefault(_Link); @@ -21276,149 +21900,104 @@ var GridItem = function (_React$Component) { exports.default = GridItem; /***/ }), -/* 43 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 38 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return addLeadingSlash; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "f", function() { return stripLeadingSlash; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return hasBasename; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "e", function() { return stripBasename; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "g", function() { return stripTrailingSlash; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "d", function() { return parsePath; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return createPath; }); -var addLeadingSlash = function addLeadingSlash(path) { - return path.charAt(0) === '/' ? path : '/' + path; +/* +object-assign +(c) Sindre Sorhus +@license MIT +*/ + + +/* eslint-disable no-unused-vars */ +var getOwnPropertySymbols = Object.getOwnPropertySymbols; +var hasOwnProperty = Object.prototype.hasOwnProperty; +var propIsEnumerable = Object.prototype.propertyIsEnumerable; + +function toObject(val) { + if (val === null || val === undefined) { + throw new TypeError('Object.assign cannot be called with null or undefined'); + } + + return Object(val); +} + +function shouldUseNative() { + try { + if (!Object.assign) { + return false; + } + + // Detect buggy property enumeration order in older V8 versions. + + // https://bugs.chromium.org/p/v8/issues/detail?id=4118 + var test1 = new String('abc'); // eslint-disable-line no-new-wrappers + test1[5] = 'de'; + if (Object.getOwnPropertyNames(test1)[0] === '5') { + return false; + } + + // https://bugs.chromium.org/p/v8/issues/detail?id=3056 + var test2 = {}; + for (var i = 0; i < 10; i++) { + test2['_' + String.fromCharCode(i)] = i; + } + var order2 = Object.getOwnPropertyNames(test2).map(function (n) { + return test2[n]; + }); + if (order2.join('') !== '0123456789') { + return false; + } + + // https://bugs.chromium.org/p/v8/issues/detail?id=3056 + var test3 = {}; + 'abcdefghijklmnopqrst'.split('').forEach(function (letter) { + test3[letter] = letter; + }); + if (Object.keys(Object.assign({}, test3)).join('') !== + 'abcdefghijklmnopqrst') { + return false; + } + + return true; + } catch (err) { + // We don't expect any of the above to throw, but better to be safe. + return false; + } +} + +module.exports = shouldUseNative() ? Object.assign : function (target, source) { + var from; + var to = toObject(target); + var symbols; + + for (var s = 1; s < arguments.length; s++) { + from = Object(arguments[s]); + + for (var key in from) { + if (hasOwnProperty.call(from, key)) { + to[key] = from[key]; + } + } + + if (getOwnPropertySymbols) { + symbols = getOwnPropertySymbols(from); + for (var i = 0; i < symbols.length; i++) { + if (propIsEnumerable.call(from, symbols[i])) { + to[symbols[i]] = from[symbols[i]]; + } + } + } + } + + return to; }; -var stripLeadingSlash = function stripLeadingSlash(path) { - return path.charAt(0) === '/' ? path.substr(1) : path; -}; - -var hasBasename = function hasBasename(path, prefix) { - return new RegExp('^' + prefix + '(\\/|\\?|#|$)', 'i').test(path); -}; - -var stripBasename = function stripBasename(path, prefix) { - return hasBasename(path, prefix) ? path.substr(prefix.length) : path; -}; - -var stripTrailingSlash = function stripTrailingSlash(path) { - return path.charAt(path.length - 1) === '/' ? path.slice(0, -1) : path; -}; - -var parsePath = function parsePath(path) { - var pathname = path || '/'; - var search = ''; - var hash = ''; - - var hashIndex = pathname.indexOf('#'); - if (hashIndex !== -1) { - hash = pathname.substr(hashIndex); - pathname = pathname.substr(0, hashIndex); - } - - var searchIndex = pathname.indexOf('?'); - if (searchIndex !== -1) { - search = pathname.substr(searchIndex); - pathname = pathname.substr(0, searchIndex); - } - - return { - pathname: pathname, - search: search === '?' ? '' : search, - hash: hash === '#' ? '' : hash - }; -}; - -var createPath = function createPath(location) { - var pathname = location.pathname, - search = location.search, - hash = location.hash; - - - var path = pathname || '/'; - - if (search && search !== '?') path += search.charAt(0) === '?' ? search : '?' + search; - - if (hash && hash !== '#') path += hash.charAt(0) === '#' ? hash : '#' + hash; - - return path; -}; /***/ }), -/* 44 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return addLeadingSlash; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "f", function() { return stripLeadingSlash; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return hasBasename; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "e", function() { return stripBasename; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "g", function() { return stripTrailingSlash; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "d", function() { return parsePath; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return createPath; }); -var addLeadingSlash = function addLeadingSlash(path) { - return path.charAt(0) === '/' ? path : '/' + path; -}; - -var stripLeadingSlash = function stripLeadingSlash(path) { - return path.charAt(0) === '/' ? path.substr(1) : path; -}; - -var hasBasename = function hasBasename(path, prefix) { - return new RegExp('^' + prefix + '(\\/|\\?|#|$)', 'i').test(path); -}; - -var stripBasename = function stripBasename(path, prefix) { - return hasBasename(path, prefix) ? path.substr(prefix.length) : path; -}; - -var stripTrailingSlash = function stripTrailingSlash(path) { - return path.charAt(path.length - 1) === '/' ? path.slice(0, -1) : path; -}; - -var parsePath = function parsePath(path) { - var pathname = path || '/'; - var search = ''; - var hash = ''; - - var hashIndex = pathname.indexOf('#'); - if (hashIndex !== -1) { - hash = pathname.substr(hashIndex); - pathname = pathname.substr(0, hashIndex); - } - - var searchIndex = pathname.indexOf('?'); - if (searchIndex !== -1) { - search = pathname.substr(searchIndex); - pathname = pathname.substr(0, searchIndex); - } - - return { - pathname: pathname, - search: search === '?' ? '' : search, - hash: hash === '#' ? '' : hash - }; -}; - -var createPath = function createPath(location) { - var pathname = location.pathname, - search = location.search, - hash = location.hash; - - - var path = pathname || '/'; - - if (search && search !== '?') path += search.charAt(0) === '?' ? search : '?' + search; - - if (hash && hash !== '#') path += hash.charAt(0) === '#' ? hash : '#' + hash; - - return path; -}; - -/***/ }), -/* 45 */ +/* 39 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -21438,7 +22017,7 @@ var _reactRedux = __webpack_require__(4); var _redux = __webpack_require__(2); -var _Link = __webpack_require__(8); +var _Link = __webpack_require__(7); var _Link2 = _interopRequireDefault(_Link); @@ -21450,7 +22029,7 @@ var _actions = __webpack_require__(3); var uiActions = _interopRequireWildcard(_actions); -var _actions2 = __webpack_require__(9); +var _actions2 = __webpack_require__(8); var spotifyActions = _interopRequireWildcard(_actions2); @@ -21545,7 +22124,7 @@ var mapDispatchToProps = function mapDispatchToProps(dispatch) { exports.default = (0, _reactRedux.connect)(mapStateToProps, mapDispatchToProps)(FollowButton); /***/ }), -/* 46 */ +/* 40 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -21573,11 +22152,11 @@ var _actions = __webpack_require__(3); var uiActions = _interopRequireWildcard(_actions); -var _actions2 = __webpack_require__(16); +var _actions2 = __webpack_require__(17); var lastfmActions = _interopRequireWildcard(_actions2); -var _GridItem = __webpack_require__(42); +var _GridItem = __webpack_require__(37); var _GridItem2 = _interopRequireDefault(_GridItem); @@ -21665,7 +22244,7 @@ var mapDispatchToProps = function mapDispatchToProps(dispatch) { exports.default = (0, _reactRedux.connect)(mapStateToProps, mapDispatchToProps)(AlbumGrid); /***/ }), -/* 47 */ +/* 41 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -21693,7 +22272,7 @@ var _actions = __webpack_require__(3); var uiActions = _interopRequireWildcard(_actions); -var _GridItem = __webpack_require__(42); +var _GridItem = __webpack_require__(37); var _GridItem2 = _interopRequireDefault(_GridItem); @@ -21778,7 +22357,7 @@ var mapDispatchToProps = function mapDispatchToProps(dispatch) { exports.default = (0, _reactRedux.connect)(mapStateToProps, mapDispatchToProps)(PlaylistGrid); /***/ }), -/* 48 */ +/* 42 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -21798,9 +22377,9 @@ var _reactRedux = __webpack_require__(4); var _redux = __webpack_require__(2); -var _reactRouter = __webpack_require__(38); +var _reactRouter = __webpack_require__(35); -var _ListItem = __webpack_require__(298); +var _ListItem = __webpack_require__(246); var _ListItem2 = _interopRequireDefault(_ListItem); @@ -21812,7 +22391,7 @@ var _actions = __webpack_require__(3); var uiActions = _interopRequireWildcard(_actions); -var _actions2 = __webpack_require__(16); +var _actions2 = __webpack_require__(17); var lastfmActions = _interopRequireWildcard(_actions2); @@ -21893,7 +22472,7 @@ var mapDispatchToProps = function mapDispatchToProps(dispatch) { exports.default = (0, _reactRouter.withRouter)((0, _reactRedux.connect)(mapStateToProps, mapDispatchToProps)(List)); /***/ }), -/* 49 */ +/* 43 */ /***/ (function(module, exports) { var g; @@ -21920,154 +22499,2086 @@ module.exports = g; /***/ }), -/* 50 */ +/* 44 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-2015, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - */ +/* WEBPACK VAR INJECTION */(function(process) { + +if (process.env.NODE_ENV === 'production') { + module.exports = __webpack_require__(105); +} else { + module.exports = __webpack_require__(106); +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(10))) + +/***/ }), +/* 45 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +/* harmony export (immutable) */ __webpack_exports__["a"] = _extends; +function _extends() { + _extends = Object.assign || function (target) { + for (var i = 1; i < arguments.length; i++) { + var source = arguments[i]; + + for (var key in source) { + if (Object.prototype.hasOwnProperty.call(source, key)) { + target[key] = source[key]; + } + } + } + + return target; + }; + + return _extends.apply(this, arguments); +} + +/***/ }), +/* 46 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_warning__ = __webpack_require__(28); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_warning___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_warning__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_invariant__ = __webpack_require__(27); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_invariant___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_invariant__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_react__ = __webpack_require__(0); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_react__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_prop_types__ = __webpack_require__(12); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_prop_types___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3_prop_types__); +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + + + /** - * Similar to invariant but only logs a warning if the condition is not met. - * This can be used to log issues in development environments in critical - * paths. Removing the logging code for production environments will keep the - * same logic and follow the same code paths. + * The public API for putting history on context. */ -var warning = function() {}; +var Router = function (_React$Component) { + _inherits(Router, _React$Component); -if (process.env.NODE_ENV !== 'production') { - warning = function(condition, format, args) { - var len = arguments.length; - args = new Array(len > 2 ? len - 2 : 0); - for (var key = 2; key < len; key++) { - args[key - 2] = arguments[key]; - } - if (format === undefined) { - throw new Error( - '`warning(condition, format, ...args)` requires a warning ' + - 'message argument' - ); + function Router() { + var _temp, _this, _ret; + + _classCallCheck(this, Router); + + for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { + args[_key] = arguments[_key]; } - if (format.length < 10 || (/^[s\W]*$/).test(format)) { - throw new Error( - 'The warning format should be able to uniquely identify this ' + - 'warning. Please, use a more descriptive format than: ' + format - ); - } + return _ret = (_temp = (_this = _possibleConstructorReturn(this, _React$Component.call.apply(_React$Component, [this].concat(args))), _this), _this.state = { + match: _this.computeMatch(_this.props.history.location.pathname) + }, _temp), _possibleConstructorReturn(_this, _ret); + } - if (!condition) { - var argIndex = 0; - var message = 'Warning: ' + - format.replace(/%s/g, function() { - return args[argIndex++]; - }); - if (typeof console !== 'undefined') { - console.error(message); - } - try { - // This error was thrown as a convenience so that you can use this stack - // to find the callsite that caused this warning to fire. - throw new Error(message); - } catch(x) {} - } + Router.prototype.getChildContext = function getChildContext() { + return { + router: _extends({}, this.context.router, { + history: this.props.history, + route: { + location: this.props.history.location, + match: this.state.match + } + }) + }; }; -} -module.exports = warning; + Router.prototype.computeMatch = function computeMatch(pathname) { + return { + path: "/", + url: "/", + params: {}, + isExact: pathname === "/" + }; + }; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(6))) + Router.prototype.componentWillMount = function componentWillMount() { + var _this2 = this; + + var _props = this.props, + children = _props.children, + history = _props.history; + + + __WEBPACK_IMPORTED_MODULE_1_invariant___default()(children == null || __WEBPACK_IMPORTED_MODULE_2_react___default.a.Children.count(children) === 1, "A may have only one child element"); + + // Do this here so we can setState when a changes the + // location in componentWillMount. This happens e.g. when doing + // server rendering using a . + this.unlisten = history.listen(function () { + _this2.setState({ + match: _this2.computeMatch(history.location.pathname) + }); + }); + }; + + Router.prototype.componentWillReceiveProps = function componentWillReceiveProps(nextProps) { + __WEBPACK_IMPORTED_MODULE_0_warning___default()(this.props.history === nextProps.history, "You cannot change "); + }; + + Router.prototype.componentWillUnmount = function componentWillUnmount() { + this.unlisten(); + }; + + Router.prototype.render = function render() { + var children = this.props.children; + + return children ? __WEBPACK_IMPORTED_MODULE_2_react___default.a.Children.only(children) : null; + }; + + return Router; +}(__WEBPACK_IMPORTED_MODULE_2_react___default.a.Component); + +Router.propTypes = { + history: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object.isRequired, + children: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.node +}; +Router.contextTypes = { + router: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object +}; +Router.childContextTypes = { + router: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object.isRequired +}; + + +/* harmony default export */ __webpack_exports__["a"] = (Router); /***/ }), -/* 51 */ +/* 47 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return createLocation; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return locationsAreEqual; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_resolve_pathname__ = __webpack_require__(91); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_value_equal__ = __webpack_require__(92); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__PathUtils__ = __webpack_require__(43); -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_path_to_regexp__ = __webpack_require__(76); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_path_to_regexp___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_path_to_regexp__); +var patternCache = {}; +var cacheLimit = 10000; +var cacheCount = 0; +var compilePath = function compilePath(pattern, options) { + var cacheKey = "" + options.end + options.strict + options.sensitive; + var cache = patternCache[cacheKey] || (patternCache[cacheKey] = {}); + if (cache[pattern]) return cache[pattern]; -var createLocation = function createLocation(path, state, key, currentLocation) { - var location = void 0; - if (typeof path === 'string') { - // Two-arg form: push(path, state) - location = Object(__WEBPACK_IMPORTED_MODULE_2__PathUtils__["d" /* parsePath */])(path); - location.state = state; - } else { - // One-arg form: push(location) - location = _extends({}, path); + var keys = []; + var re = __WEBPACK_IMPORTED_MODULE_0_path_to_regexp___default()(pattern, keys, options); + var compiledPattern = { re: re, keys: keys }; - if (location.pathname === undefined) location.pathname = ''; - - if (location.search) { - if (location.search.charAt(0) !== '?') location.search = '?' + location.search; - } else { - location.search = ''; - } - - if (location.hash) { - if (location.hash.charAt(0) !== '#') location.hash = '#' + location.hash; - } else { - location.hash = ''; - } - - if (state !== undefined && location.state === undefined) location.state = state; + if (cacheCount < cacheLimit) { + cache[pattern] = compiledPattern; + cacheCount++; } - try { - location.pathname = decodeURI(location.pathname); - } catch (e) { - if (e instanceof URIError) { - throw new URIError('Pathname "' + location.pathname + '" could not be decoded. ' + 'This is likely caused by an invalid percent-encoding.'); - } else { - throw e; - } - } - - if (key) location.key = key; - - if (currentLocation) { - // Resolve incomplete/relative pathname relative to current location. - if (!location.pathname) { - location.pathname = currentLocation.pathname; - } else if (location.pathname.charAt(0) !== '/') { - location.pathname = Object(__WEBPACK_IMPORTED_MODULE_0_resolve_pathname__["a" /* default */])(location.pathname, currentLocation.pathname); - } - } else { - // When there is no prior location and pathname is empty, set it to / - if (!location.pathname) { - location.pathname = '/'; - } - } - - return location; + return compiledPattern; }; -var locationsAreEqual = function locationsAreEqual(a, b) { - return a.pathname === b.pathname && a.search === b.search && a.hash === b.hash && a.key === b.key && Object(__WEBPACK_IMPORTED_MODULE_1_value_equal__["a" /* default */])(a.state, b.state); +/** + * Public API for matching a URL pathname to a path pattern. + */ +var matchPath = function matchPath(pathname) { + var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}; + var parent = arguments[2]; + + if (typeof options === "string") options = { path: options }; + + var _options = options, + path = _options.path, + _options$exact = _options.exact, + exact = _options$exact === undefined ? false : _options$exact, + _options$strict = _options.strict, + strict = _options$strict === undefined ? false : _options$strict, + _options$sensitive = _options.sensitive, + sensitive = _options$sensitive === undefined ? false : _options$sensitive; + + + if (path == null) return parent; + + var _compilePath = compilePath(path, { end: exact, strict: strict, sensitive: sensitive }), + re = _compilePath.re, + keys = _compilePath.keys; + + var match = re.exec(pathname); + + if (!match) return null; + + var url = match[0], + values = match.slice(1); + + var isExact = pathname === url; + + if (exact && !isExact) return null; + + return { + path: path, // the path pattern used to match + url: path === "/" && url === "" ? "/" : url, // the matched portion of the URL + isExact: isExact, // whether or not we matched exactly + params: keys.reduce(function (memo, key, index) { + memo[key.name] = values[index]; + return memo; + }, {}) + }; }; +/* harmony default export */ __webpack_exports__["a"] = (matchPath); + +/***/ }), +/* 48 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); + +var _react = __webpack_require__(0); + +var _react2 = _interopRequireDefault(_react); + +var _ErrorMessage = __webpack_require__(31); + +var _ErrorMessage2 = _interopRequireDefault(_ErrorMessage); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + +var ErrorBoundary = function (_React$Component) { + _inherits(ErrorBoundary, _React$Component); + + function ErrorBoundary(props) { + _classCallCheck(this, ErrorBoundary); + + var _this = _possibleConstructorReturn(this, (ErrorBoundary.__proto__ || Object.getPrototypeOf(ErrorBoundary)).call(this, props)); + + _this.state = { + hasError: false, + error: null, + info: null + }; + return _this; + } + + _createClass(ErrorBoundary, [{ + key: 'componentDidCatch', + value: function componentDidCatch(error, info) { + this.setState({ + hasError: true, + error: error, + info: info + }); + console.error(error, info); + } + }, { + key: 'render', + value: function render() { + if (this.state.hasError) { + return _react2.default.createElement( + _ErrorMessage2.default, + { type: 'error-boundary' }, + this.state.info ? _react2.default.createElement( + 'pre', + { className: 'error-message__trace' }, + this.state.info.componentStack + ) : null + ); + } + return this.props.children; + } + }]); + + return ErrorBoundary; +}(_react2.default.Component); + +exports.default = ErrorBoundary; + +/***/ }), +/* 49 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); + +var _react = __webpack_require__(0); + +var _react2 = _interopRequireDefault(_react); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + +var NiceNumber = function (_React$Component) { + _inherits(NiceNumber, _React$Component); + + function NiceNumber(props) { + _classCallCheck(this, NiceNumber); + + return _possibleConstructorReturn(this, (NiceNumber.__proto__ || Object.getPrototypeOf(NiceNumber)).call(this, props)); + } + + _createClass(NiceNumber, [{ + key: 'format', + value: function format() { + var formatted = parseInt(this.props.value); + + // > 1 million + if (formatted > 1000000) { + formatted = formatted / 1000000; + formatted = Math.round(formatted * 10) / 10; + formatted = formatted + 'm'; + + // > 1 thousand + } else if (formatted > 1000) { + formatted = formatted / 1000; + formatted = Math.round(formatted * 10) / 10; + formatted = formatted + 'k'; + } else { + formatted = formatted.toLocaleString(); + } + + return formatted; + } + }, { + key: 'render', + value: function render() { + return _react2.default.createElement( + 'span', + { className: 'counter' }, + this.format() + ); + } + }]); + + return NiceNumber; +}(_react2.default.Component); + +exports.default = NiceNumber; + +/***/ }), +/* 50 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _captialize = __webpack_require__(226); + +Object.defineProperty(exports, 'captialize', { + enumerable: true, + get: function get() { + return _interopRequireDefault(_captialize).default; + } +}); + +var _clamp = __webpack_require__(227); + +Object.defineProperty(exports, 'clamp', { + enumerable: true, + get: function get() { + return _interopRequireDefault(_clamp).default; + } +}); + +var _distanceTo = __webpack_require__(228); + +Object.defineProperty(exports, 'distanceTo', { + enumerable: true, + get: function get() { + return _interopRequireDefault(_distanceTo).default; + } +}); + +var _isDefined = __webpack_require__(229); + +Object.defineProperty(exports, 'isDefined', { + enumerable: true, + get: function get() { + return _interopRequireDefault(_isDefined).default; + } +}); + +var _isNumber = __webpack_require__(230); + +Object.defineProperty(exports, 'isNumber', { + enumerable: true, + get: function get() { + return _interopRequireDefault(_isNumber).default; + } +}); + +var _isObject = __webpack_require__(231); + +Object.defineProperty(exports, 'isObject', { + enumerable: true, + get: function get() { + return _interopRequireDefault(_isObject).default; + } +}); + +var _length = __webpack_require__(232); + +Object.defineProperty(exports, 'length', { + enumerable: true, + get: function get() { + return _interopRequireDefault(_length).default; + } +}); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +//# sourceMappingURL=index.js.map + +/***/ }), +/* 51 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright (c) 2013-present, Facebook, Inc. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */ + + + +var printWarning = function() {}; + +if (process.env.NODE_ENV !== 'production') { + var ReactPropTypesSecret = __webpack_require__(52); + var loggedTypeFailures = {}; + var has = Function.call.bind(Object.prototype.hasOwnProperty); + + printWarning = function(text) { + var message = 'Warning: ' + text; + if (typeof console !== 'undefined') { + console.error(message); + } + try { + // --- Welcome to debugging React --- + // This error was thrown as a convenience so that you can use this stack + // to find the callsite that caused this warning to fire. + throw new Error(message); + } catch (x) {} + }; +} + +/** + * Assert that the values match with the type specs. + * Error messages are memorized and will only be shown once. + * + * @param {object} typeSpecs Map of name to a ReactPropType + * @param {object} values Runtime values that need to be type-checked + * @param {string} location e.g. "prop", "context", "child context" + * @param {string} componentName Name of the component for error messages. + * @param {?Function} getStack Returns the component stack. + * @private + */ +function checkPropTypes(typeSpecs, values, location, componentName, getStack) { + if (process.env.NODE_ENV !== 'production') { + for (var typeSpecName in typeSpecs) { + if (has(typeSpecs, typeSpecName)) { + var error; + // Prop type validation may throw. In case they do, we don't want to + // fail the render phase where it didn't fail before. So we log it. + // After these have been cleaned up, we'll let them throw. + try { + // This is intentionally an invariant that gets caught. It's the same + // behavior as without this statement except with a better message. + if (typeof typeSpecs[typeSpecName] !== 'function') { + var err = Error( + (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' + + 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' + ); + err.name = 'Invariant Violation'; + throw err; + } + error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret); + } catch (ex) { + error = ex; + } + if (error && !(error instanceof Error)) { + printWarning( + (componentName || 'React class') + ': type specification of ' + + location + ' `' + typeSpecName + '` is invalid; the type checker ' + + 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' + + 'You may have forgotten to pass an argument to the type checker ' + + 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' + + 'shape all require an argument).' + ); + } + if (error instanceof Error && !(error.message in loggedTypeFailures)) { + // Only monitor this failure once because there tends to be a lot of the + // same error. + loggedTypeFailures[error.message] = true; + + var stack = getStack ? getStack() : ''; + + printWarning( + 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '') + ); + } + } + } + } +} + +/** + * Resets warning cache when testing. + * + * @private + */ +checkPropTypes.resetWarningCache = function() { + if (process.env.NODE_ENV !== 'production') { + loggedTypeFailures = {}; + } +} + +module.exports = checkPropTypes; + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(10))) + /***/ }), /* 52 */ /***/ (function(module, exports, __webpack_require__) { -var isarray = __webpack_require__(161) +"use strict"; +/** + * Copyright (c) 2013-present, Facebook, Inc. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */ + + + +var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED'; + +module.exports = ReactPropTypesSecret; + + +/***/ }), +/* 53 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) { + +function checkDCE() { + /* global __REACT_DEVTOOLS_GLOBAL_HOOK__ */ + if ( + typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ === 'undefined' || + typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE !== 'function' + ) { + return; + } + if (process.env.NODE_ENV !== 'production') { + // This branch is unreachable because this function is only called + // in production, but the condition is true only in development. + // Therefore if the branch is still here, dead code elimination wasn't + // properly applied. + // Don't change the message. React DevTools relies on it. Also make sure + // this message doesn't occur elsewhere in this function, or it will cause + // a false positive. + throw new Error('^_^'); + } + try { + // Verify that the code above has been dead code eliminated (DCE'd). + __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(checkDCE); + } catch (err) { + // DevTools shouldn't crash React, no matter what. + // We should still report in case we break this code. + console.error(err); + } +} + +if (process.env.NODE_ENV === 'production') { + // DCE check should happen before ReactDOM bundle executes so that + // DevTools can report bad minification during injection. + checkDCE(); + module.exports = __webpack_require__(97); +} else { + module.exports = __webpack_require__(100); +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(10))) + +/***/ }), +/* 54 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return ReactReduxContext; }); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react__ = __webpack_require__(0); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_react__); + +var ReactReduxContext = __WEBPACK_IMPORTED_MODULE_0_react___default.a.createContext(null); +/* unused harmony default export */ var _unused_webpack_default_export = (ReactReduxContext); + +/***/ }), +/* 55 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +/* harmony export (immutable) */ __webpack_exports__["a"] = _objectWithoutPropertiesLoose; +function _objectWithoutPropertiesLoose(source, excluded) { + if (source == null) return {}; + var target = {}; + var sourceKeys = Object.keys(source); + var key, i; + + for (i = 0; i < sourceKeys.length; i++) { + key = sourceKeys[i]; + if (excluded.indexOf(key) >= 0) continue; + target[key] = source[key]; + } + + return target; +} + +/***/ }), +/* 56 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react_router_es_Router__ = __webpack_require__(46); +// Written in this round about way for babel-transform-imports + + +/* harmony default export */ __webpack_exports__["a"] = (__WEBPACK_IMPORTED_MODULE_0_react_router_es_Router__["a" /* default */]); + +/***/ }), +/* 57 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_warning__ = __webpack_require__(28); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_warning___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_warning__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_invariant__ = __webpack_require__(27); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_invariant___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_invariant__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_react__ = __webpack_require__(0); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_react__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_prop_types__ = __webpack_require__(12); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_prop_types___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3_prop_types__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__matchPath__ = __webpack_require__(47); +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + + + + + + + +var isEmptyChildren = function isEmptyChildren(children) { + return __WEBPACK_IMPORTED_MODULE_2_react___default.a.Children.count(children) === 0; +}; + +/** + * The public API for matching a single path and rendering. + */ + +var Route = function (_React$Component) { + _inherits(Route, _React$Component); + + function Route() { + var _temp, _this, _ret; + + _classCallCheck(this, Route); + + for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { + args[_key] = arguments[_key]; + } + + return _ret = (_temp = (_this = _possibleConstructorReturn(this, _React$Component.call.apply(_React$Component, [this].concat(args))), _this), _this.state = { + match: _this.computeMatch(_this.props, _this.context.router) + }, _temp), _possibleConstructorReturn(_this, _ret); + } + + Route.prototype.getChildContext = function getChildContext() { + return { + router: _extends({}, this.context.router, { + route: { + location: this.props.location || this.context.router.route.location, + match: this.state.match + } + }) + }; + }; + + Route.prototype.computeMatch = function computeMatch(_ref, router) { + var computedMatch = _ref.computedMatch, + location = _ref.location, + path = _ref.path, + strict = _ref.strict, + exact = _ref.exact, + sensitive = _ref.sensitive; + + if (computedMatch) return computedMatch; // already computed the match for us + + __WEBPACK_IMPORTED_MODULE_1_invariant___default()(router, "You should not use or withRouter() outside a "); + + var route = router.route; + + var pathname = (location || route.location).pathname; + + return Object(__WEBPACK_IMPORTED_MODULE_4__matchPath__["a" /* default */])(pathname, { path: path, strict: strict, exact: exact, sensitive: sensitive }, route.match); + }; + + Route.prototype.componentWillMount = function componentWillMount() { + __WEBPACK_IMPORTED_MODULE_0_warning___default()(!(this.props.component && this.props.render), "You should not use and in the same route; will be ignored"); + + __WEBPACK_IMPORTED_MODULE_0_warning___default()(!(this.props.component && this.props.children && !isEmptyChildren(this.props.children)), "You should not use and in the same route; will be ignored"); + + __WEBPACK_IMPORTED_MODULE_0_warning___default()(!(this.props.render && this.props.children && !isEmptyChildren(this.props.children)), "You should not use and in the same route; will be ignored"); + }; + + Route.prototype.componentWillReceiveProps = function componentWillReceiveProps(nextProps, nextContext) { + __WEBPACK_IMPORTED_MODULE_0_warning___default()(!(nextProps.location && !this.props.location), ' elements should not change from uncontrolled to controlled (or vice versa). You initially used no "location" prop and then provided one on a subsequent render.'); + + __WEBPACK_IMPORTED_MODULE_0_warning___default()(!(!nextProps.location && this.props.location), ' elements should not change from controlled to uncontrolled (or vice versa). You provided a "location" prop initially but omitted it on a subsequent render.'); + + this.setState({ + match: this.computeMatch(nextProps, nextContext.router) + }); + }; + + Route.prototype.render = function render() { + var match = this.state.match; + var _props = this.props, + children = _props.children, + component = _props.component, + render = _props.render; + var _context$router = this.context.router, + history = _context$router.history, + route = _context$router.route, + staticContext = _context$router.staticContext; + + var location = this.props.location || route.location; + var props = { match: match, location: location, history: history, staticContext: staticContext }; + + if (component) return match ? __WEBPACK_IMPORTED_MODULE_2_react___default.a.createElement(component, props) : null; + + if (render) return match ? render(props) : null; + + if (typeof children === "function") return children(props); + + if (children && !isEmptyChildren(children)) return __WEBPACK_IMPORTED_MODULE_2_react___default.a.Children.only(children); + + return null; + }; + + return Route; +}(__WEBPACK_IMPORTED_MODULE_2_react___default.a.Component); + +Route.propTypes = { + computedMatch: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object, // private, from + path: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.string, + exact: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.bool, + strict: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.bool, + sensitive: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.bool, + component: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.func, + render: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.func, + children: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.node]), + location: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object +}; +Route.contextTypes = { + router: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.shape({ + history: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object.isRequired, + route: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object.isRequired, + staticContext: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object + }) +}; +Route.childContextTypes = { + router: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object.isRequired +}; + + +/* harmony default export */ __webpack_exports__["a"] = (Route); + +/***/ }), +/* 58 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_path_to_regexp__ = __webpack_require__(76); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_path_to_regexp___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_path_to_regexp__); + + +var patternCache = {}; +var cacheLimit = 10000; +var cacheCount = 0; + +var compileGenerator = function compileGenerator(pattern) { + var cacheKey = pattern; + var cache = patternCache[cacheKey] || (patternCache[cacheKey] = {}); + + if (cache[pattern]) return cache[pattern]; + + var compiledGenerator = __WEBPACK_IMPORTED_MODULE_0_path_to_regexp___default.a.compile(pattern); + + if (cacheCount < cacheLimit) { + cache[pattern] = compiledGenerator; + cacheCount++; + } + + return compiledGenerator; +}; + +/** + * Public API for generating a URL pathname from a pattern and parameters. + */ +var generatePath = function generatePath() { + var pattern = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : "/"; + var params = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}; + + if (pattern === "/") { + return pattern; + } + var generator = compileGenerator(pattern); + return generator(params, { pretty: true }); +}; + +/* harmony default export */ __webpack_exports__["a"] = (generatePath); + +/***/ }), +/* 59 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +/* harmony export (immutable) */ __webpack_exports__["a"] = warn; +function warn(s) { + console.warn('[react-ga]', s); +} + +/***/ }), +/* 60 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(process) {var __WEBPACK_AMD_DEFINE_RESULT__;var require;/** @license MIT License (c) copyright 2010-2014 original author or authors */ +/** @author Brian Cavalier */ +/** @author John Hann */ + +/*global process,document,setTimeout,clearTimeout,MutationObserver,WebKitMutationObserver*/ +(function(define) { 'use strict'; +!(__WEBPACK_AMD_DEFINE_RESULT__ = (function(require) { + /*jshint maxcomplexity:6*/ + + // Sniff "best" async scheduling option + // Prefer process.nextTick or MutationObserver, then check for + // setTimeout, and finally vertx, since its the only env that doesn't + // have setTimeout + + var MutationObs; + var capturedSetTimeout = typeof setTimeout !== 'undefined' && setTimeout; + + // Default env + var setTimer = function(f, ms) { return setTimeout(f, ms); }; + var clearTimer = function(t) { return clearTimeout(t); }; + var asap = function (f) { return capturedSetTimeout(f, 0); }; + + // Detect specific env + if (isNode()) { // Node + asap = function (f) { return process.nextTick(f); }; + + } else if (MutationObs = hasMutationObserver()) { // Modern browser + asap = initMutationObserver(MutationObs); + + } else if (!capturedSetTimeout) { // vert.x + var vertxRequire = require; + var vertx = __webpack_require__(167); + setTimer = function (f, ms) { return vertx.setTimer(ms, f); }; + clearTimer = vertx.cancelTimer; + asap = vertx.runOnLoop || vertx.runOnContext; + } + + return { + setTimer: setTimer, + clearTimer: clearTimer, + asap: asap + }; + + function isNode () { + return typeof process !== 'undefined' && + Object.prototype.toString.call(process) === '[object process]'; + } + + function hasMutationObserver () { + return (typeof MutationObserver !== 'undefined' && MutationObserver) || + (typeof WebKitMutationObserver !== 'undefined' && WebKitMutationObserver); + } + + function initMutationObserver(MutationObserver) { + var scheduled; + var node = document.createTextNode(''); + var o = new MutationObserver(run); + o.observe(node, { characterData: true }); + + function run() { + var f = scheduled; + scheduled = void 0; + f(); + } + + var i = 0; + return function (f) { + scheduled = f; + node.data = (i ^= 1); + }; + } +}).call(exports, __webpack_require__, exports, module), + __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); +}(__webpack_require__(16))); + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(10))) + +/***/ }), +/* 61 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.set = set; +exports.getLibraryArtists = getLibraryArtists; +exports.clearLibraryArtists = clearLibraryArtists; +exports.getLibraryAlbums = getLibraryAlbums; +exports.clearLibraryAlbums = clearLibraryAlbums; +function set(data) { + return { + type: 'GOOGLE_SET', + data: data + }; +} + +function getLibraryArtists() { + return { + type: 'GOOGLE_GET_LIBRARY_ARTISTS' + }; +} + +function clearLibraryArtists() { + return { + type: 'GOOGLE_CLEAR_LIBRARY_ARTISTS' + }; +} + +function getLibraryAlbums() { + return { + 'type': 'GOOGLE_GET_LIBRARY_ALBUMS' + }; +} + +function clearLibraryAlbums() { + return { + type: 'GOOGLE_CLEAR_LIBRARY_ALBUMS' + }; +} + +/***/ }), +/* 62 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); + +var _react = __webpack_require__(0); + +var _react2 = _interopRequireDefault(_react); + +var _Icon = __webpack_require__(5); + +var _Icon2 = _interopRequireDefault(_Icon); + +var _helpers = __webpack_require__(1); + +var helpers = _interopRequireWildcard(_helpers); + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } } + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + +var VolumeControl = function (_React$Component) { + _inherits(VolumeControl, _React$Component); + + function VolumeControl(props) { + _classCallCheck(this, VolumeControl); + + var _this = _possibleConstructorReturn(this, (VolumeControl.__proto__ || Object.getPrototypeOf(VolumeControl)).call(this, props)); + + _this.handleChange = helpers.throttle(_this.handleChange.bind(_this), 100); + return _this; + } + + _createClass(VolumeControl, [{ + key: 'handleChange', + value: function handleChange(value) { + this.props.onVolumeChange(value, this.props.volume); + } + }, { + key: 'render', + value: function render() { + var _this2 = this; + + return _react2.default.createElement( + 'div', + { className: "slider__wrapper " + (this.props.className ? this.props.className : "") }, + _react2.default.createElement( + 'div', + { className: "slider slider--volume " + (this.props.mute ? "slider--muted" : "") }, + _react2.default.createElement('input', { + className: 'slider__input', + type: 'range', + min: '0', + max: '25', + value: this.props.volume / 4, + onChange: function onChange(e) { + return _this2.handleChange(parseInt(e.target.value) * 4); + } + }), + _react2.default.createElement( + 'div', + { className: 'slider__track' }, + _react2.default.createElement('div', { className: 'slider__track__progress', style: { width: this.props.volume + '%' } }) + ) + ) + ); + } + }]); + + return VolumeControl; +}(_react2.default.Component); + +exports.default = VolumeControl; + +/***/ }), +/* 63 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); + +var _react = __webpack_require__(0); + +var _react2 = _interopRequireDefault(_react); + +var _Icon = __webpack_require__(5); + +var _Icon2 = _interopRequireDefault(_Icon); + +var _helpers = __webpack_require__(1); + +var helpers = _interopRequireWildcard(_helpers); + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } } + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + +var MuteControl = function (_React$Component) { + _inherits(MuteControl, _React$Component); + + function MuteControl(props) { + _classCallCheck(this, MuteControl); + + return _possibleConstructorReturn(this, (MuteControl.__proto__ || Object.getPrototypeOf(MuteControl)).call(this, props)); + } + + _createClass(MuteControl, [{ + key: 'render', + value: function render() { + var _this2 = this; + + if (this.props.mute) { + return _react2.default.createElement( + 'a', + { className: "control mute-control " + (this.props.noTooltip ? "" : "tooltip ") + (this.props.className ? this.props.className : ""), onClick: function onClick() { + return _this2.props.onMuteChange(false); + } }, + _react2.default.createElement(_Icon2.default, { className: 'red-text', name: 'volume_off' }), + this.props.noTooltip ? null : _react2.default.createElement( + 'span', + { className: 'tooltip__content' }, + 'Unmute' + ) + ); + } else { + return _react2.default.createElement( + 'a', + { className: "control mute-control " + (this.props.noTooltip ? "" : "tooltip ") + (this.props.className ? this.props.className : ""), onClick: function onClick() { + return _this2.props.onMuteChange(true); + } }, + _react2.default.createElement(_Icon2.default, { className: 'muted', name: 'volume_mute' }), + this.props.noTooltip ? null : _react2.default.createElement( + 'span', + { className: 'tooltip__content' }, + 'Mute' + ) + ); + } + } + }]); + + return MuteControl; +}(_react2.default.Component); + +exports.default = MuteControl; + +/***/ }), +/* 64 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); + +var _react = __webpack_require__(0); + +var _react2 = _interopRequireDefault(_react); + +var _Icon = __webpack_require__(5); + +var _Icon2 = _interopRequireDefault(_Icon); + +var _helpers = __webpack_require__(1); + +var helpers = _interopRequireWildcard(_helpers); + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } } + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + +var Popularity = function (_React$Component) { + _inherits(Popularity, _React$Component); + + function Popularity(props) { + _classCallCheck(this, Popularity); + + return _possibleConstructorReturn(this, (Popularity.__proto__ || Object.getPrototypeOf(Popularity)).call(this, props)); + } + + _createClass(Popularity, [{ + key: 'render', + value: function render() { + if (this.props.popularity === undefined || this.props.popularity === null) { + return null; + } + + return _react2.default.createElement( + 'span', + { className: 'popularity' }, + _react2.default.createElement( + 'span', + { className: 'popularity-bars' }, + _react2.default.createElement('span', { className: "bar" + (this.props.popularity > 10 ? " filled" : "") }), + _react2.default.createElement('span', { className: "bar" + (this.props.popularity > 30 ? " filled" : "") }), + _react2.default.createElement('span', { className: "bar" + (this.props.popularity > 50 ? " filled" : "") }), + _react2.default.createElement('span', { className: "bar" + (this.props.popularity > 70 ? " filled" : "") }), + _react2.default.createElement('span', { className: "bar" + (this.props.popularity > 90 ? " filled" : "") }) + ), + _react2.default.createElement( + 'span', + { className: 'popularity-value' }, + this.props.popularity, + '% popularity' + ) + ); + } + }]); + + return Popularity; +}(_react2.default.Component); + +exports.default = Popularity; + +/***/ }), +/* 65 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * @copyright 2015, Andrey Popp <8mayday@gmail.com> + * + * The decorator may be used on classes or methods + * ``` + * @autobind + * class FullBound {} + * + * class PartBound { + * @autobind + * method () {} + * } + * ``` + */ + + +Object.defineProperty(exports, '__esModule', { + value: true +}); +exports['default'] = autobind; + +function autobind() { + for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { + args[_key] = arguments[_key]; + } + + if (args.length === 1) { + return boundClass.apply(undefined, args); + } else { + return boundMethod.apply(undefined, args); + } +} + +/** + * Use boundMethod to bind all methods on the target.prototype + */ +function boundClass(target) { + // (Using reflect to get all keys including symbols) + var keys = undefined; + // Use Reflect if exists + if (typeof Reflect !== 'undefined' && typeof Reflect.ownKeys === 'function') { + keys = Reflect.ownKeys(target.prototype); + } else { + keys = Object.getOwnPropertyNames(target.prototype); + // use symbols if support is provided + if (typeof Object.getOwnPropertySymbols === 'function') { + keys = keys.concat(Object.getOwnPropertySymbols(target.prototype)); + } + } + + keys.forEach(function (key) { + // Ignore special case target method + if (key === 'constructor') { + return; + } + + var descriptor = Object.getOwnPropertyDescriptor(target.prototype, key); + + // Only methods need binding + if (typeof descriptor.value === 'function') { + Object.defineProperty(target.prototype, key, boundMethod(target, key, descriptor)); + } + }); + return target; +} + +/** + * Return a descriptor removing the value and returning a getter + * The getter will return a .bind version of the function + * and memoize the result against a symbol on the instance + */ +function boundMethod(target, key, descriptor) { + var fn = descriptor.value; + + if (typeof fn !== 'function') { + throw new Error('@autobind decorator can only be applied to methods not: ' + typeof fn); + } + + // In IE11 calling Object.defineProperty has a side-effect of evaluating the + // getter for the property which is being replaced. This causes infinite + // recursion and an "Out of stack space" error. + var definingProperty = false; + + return { + configurable: true, + get: function get() { + if (definingProperty || this === target.prototype || this.hasOwnProperty(key)) { + return fn; + } + + var boundFn = fn.bind(this); + definingProperty = true; + Object.defineProperty(this, key, { + value: boundFn, + configurable: true, + writable: true + }); + definingProperty = false; + return boundFn; + } + }; +} +module.exports = exports['default']; + + +/***/ }), +/* 66 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); + +var _react = __webpack_require__(0); + +var _react2 = _interopRequireDefault(_react); + +var _Link = __webpack_require__(7); + +var _Link2 = _interopRequireDefault(_Link); + +var _Icon = __webpack_require__(5); + +var _Icon2 = _interopRequireDefault(_Icon); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + +var FilterField = function (_React$Component) { + _inherits(FilterField, _React$Component); + + function FilterField(props) { + _classCallCheck(this, FilterField); + + var _this = _possibleConstructorReturn(this, (FilterField.__proto__ || Object.getPrototypeOf(FilterField)).call(this, props)); + + _this.state = { + value: '', + active: _this.props.slim_mode ? true : false + }; + + _this.handleKeyUp = _this.handleKeyUp.bind(_this); + return _this; + } + + _createClass(FilterField, [{ + key: 'componentWillMount', + value: function componentWillMount() { + window.addEventListener("keyup", this.handleKeyUp, false); + this.setState({ value: this.props.initialValue }); + } + }, { + key: 'componentWillUnmount', + value: function componentWillUnmount() { + window.removeEventListener("keyup", this.handleKeyUp, false); + } + }, { + key: 'handleKeyUp', + value: function handleKeyUp(e) { + if (e.keyCode == 27 && !this.props.slim_mode) { + e.preventDefault(); + + this.setState({ + value: '', + active: false + }); + + this.handleChange(''); + } + } + }, { + key: 'activate', + value: function activate() { + this.setState({ active: true }); + } + }, { + key: 'handleChange', + value: function handleChange(value) { + this.setState({ + value: value, + active: this.props.slim_mode ? true : value != '' + }); + this.props.handleChange(value); + } + }, { + key: 'handleBlur', + value: function handleBlur() { + if (this.state.value == '' && !this.props.slim_mode) { + this.setState({ active: false }); + } + } + }, { + key: 'render', + value: function render() { + var _this2 = this; + + return _react2.default.createElement( + 'span', + { className: "filter-field " + (this.state.active ? 'active' : ''), onClick: function onClick(e) { + return _this2.activate(); + } }, + _react2.default.createElement( + 'form', + null, + _react2.default.createElement('input', { + type: 'text', + placeholder: 'Filter', + value: this.state.value, + onFocus: function onFocus(e) { + return _this2.activate(); + }, + onBlur: function onBlur(e) { + return _this2.handleBlur(); + }, + onChange: function onChange(e) { + return _this2.handleChange(e.target.value); + } + }), + _react2.default.createElement(_Icon2.default, { name: 'search', type: 'material' }) + ) + ); + } + }]); + + return FilterField; +}(_react2.default.Component); + +exports.default = FilterField; + +/***/ }), +/* 67 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) { + +if (process.env.NODE_ENV === 'production') { + module.exports = __webpack_require__(98); +} else { + module.exports = __webpack_require__(99); +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(10))) + +/***/ }), +/* 68 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +/* harmony export (immutable) */ __webpack_exports__["a"] = _inheritsLoose; +function _inheritsLoose(subClass, superClass) { + subClass.prototype = Object.create(superClass.prototype); + subClass.prototype.constructor = subClass; + subClass.__proto__ = superClass; +} + +/***/ }), +/* 69 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/* harmony export (immutable) */ __webpack_exports__["a"] = connectAdvanced; +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__babel_runtime_helpers_esm_assertThisInitialized__ = __webpack_require__(109); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__babel_runtime_helpers_esm_inheritsLoose__ = __webpack_require__(68); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__babel_runtime_helpers_esm_extends__ = __webpack_require__(45); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__babel_runtime_helpers_esm_objectWithoutPropertiesLoose__ = __webpack_require__(55); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_hoist_non_react_statics__ = __webpack_require__(110); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_hoist_non_react_statics___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_4_hoist_non_react_statics__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_invariant__ = __webpack_require__(27); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_invariant___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_5_invariant__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_react__ = __webpack_require__(0); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_6_react__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_react_is__ = __webpack_require__(44); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_react_is___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_7_react_is__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__Context__ = __webpack_require__(54); + + + + + + + + + + +var stringifyComponent = function stringifyComponent(Comp) { + try { + return JSON.stringify(Comp); + } catch (err) { + return String(Comp); + } +}; + +function connectAdvanced( +/* + selectorFactory is a func that is responsible for returning the selector function used to + compute new props from state, props, and dispatch. For example: + export default connectAdvanced((dispatch, options) => (state, props) => ({ + thing: state.things[props.thingId], + saveThing: fields => dispatch(actionCreators.saveThing(props.thingId, fields)), + }))(YourComponent) + Access to dispatch is provided to the factory so selectorFactories can bind actionCreators + outside of their selector as an optimization. Options passed to connectAdvanced are passed to + the selectorFactory, along with displayName and WrappedComponent, as the second argument. + Note that selectorFactory is responsible for all caching/memoization of inbound and outbound + props. Do not use connectAdvanced directly without memoizing results between calls to your + selector, otherwise the Connect component will re-render on every state or props change. +*/ +selectorFactory, // options object: +_ref) { + if (_ref === void 0) { + _ref = {}; + } + + var _ref2 = _ref, + _ref2$getDisplayName = _ref2.getDisplayName, + getDisplayName = _ref2$getDisplayName === void 0 ? function (name) { + return "ConnectAdvanced(" + name + ")"; + } : _ref2$getDisplayName, + _ref2$methodName = _ref2.methodName, + methodName = _ref2$methodName === void 0 ? 'connectAdvanced' : _ref2$methodName, + _ref2$renderCountProp = _ref2.renderCountProp, + renderCountProp = _ref2$renderCountProp === void 0 ? undefined : _ref2$renderCountProp, + _ref2$shouldHandleSta = _ref2.shouldHandleStateChanges, + shouldHandleStateChanges = _ref2$shouldHandleSta === void 0 ? true : _ref2$shouldHandleSta, + _ref2$storeKey = _ref2.storeKey, + storeKey = _ref2$storeKey === void 0 ? 'store' : _ref2$storeKey, + _ref2$withRef = _ref2.withRef, + withRef = _ref2$withRef === void 0 ? false : _ref2$withRef, + _ref2$forwardRef = _ref2.forwardRef, + forwardRef = _ref2$forwardRef === void 0 ? false : _ref2$forwardRef, + _ref2$context = _ref2.context, + context = _ref2$context === void 0 ? __WEBPACK_IMPORTED_MODULE_8__Context__["a" /* ReactReduxContext */] : _ref2$context, + connectOptions = Object(__WEBPACK_IMPORTED_MODULE_3__babel_runtime_helpers_esm_objectWithoutPropertiesLoose__["a" /* default */])(_ref2, ["getDisplayName", "methodName", "renderCountProp", "shouldHandleStateChanges", "storeKey", "withRef", "forwardRef", "context"]); + + __WEBPACK_IMPORTED_MODULE_5_invariant___default()(renderCountProp === undefined, "renderCountProp is removed. render counting is built into the latest React dev tools profiling extension"); + __WEBPACK_IMPORTED_MODULE_5_invariant___default()(!withRef, 'withRef is removed. To access the wrapped instance, use a ref on the connected component'); + var customStoreWarningMessage = 'To use a custom Redux store for specific components, create a custom React context with ' + "React.createContext(), and pass the context object to React Redux's Provider and specific components" + ' like: . ' + 'You may also pass a {context : MyContext} option to connect'; + __WEBPACK_IMPORTED_MODULE_5_invariant___default()(storeKey === 'store', 'storeKey has been removed and does not do anything. ' + customStoreWarningMessage); + var Context = context; + return function wrapWithConnect(WrappedComponent) { + if (process.env.NODE_ENV !== 'production') { + __WEBPACK_IMPORTED_MODULE_5_invariant___default()(Object(__WEBPACK_IMPORTED_MODULE_7_react_is__["isValidElementType"])(WrappedComponent), "You must pass a component to the function returned by " + (methodName + ". Instead received " + stringifyComponent(WrappedComponent))); + } + + var wrappedComponentName = WrappedComponent.displayName || WrappedComponent.name || 'Component'; + var displayName = getDisplayName(wrappedComponentName); + + var selectorFactoryOptions = Object(__WEBPACK_IMPORTED_MODULE_2__babel_runtime_helpers_esm_extends__["a" /* default */])({}, connectOptions, { + getDisplayName: getDisplayName, + methodName: methodName, + renderCountProp: renderCountProp, + shouldHandleStateChanges: shouldHandleStateChanges, + storeKey: storeKey, + displayName: displayName, + wrappedComponentName: wrappedComponentName, + WrappedComponent: WrappedComponent + }); + + var pure = connectOptions.pure; + var OuterBaseComponent = __WEBPACK_IMPORTED_MODULE_6_react__["Component"]; + + if (pure) { + OuterBaseComponent = __WEBPACK_IMPORTED_MODULE_6_react__["PureComponent"]; + } + + function makeDerivedPropsSelector() { + var lastProps; + var lastState; + var lastDerivedProps; + var lastStore; + var lastSelectorFactoryOptions; + var sourceSelector; + return function selectDerivedProps(state, props, store, selectorFactoryOptions) { + if (pure && lastProps === props && lastState === state) { + return lastDerivedProps; + } + + if (store !== lastStore || lastSelectorFactoryOptions !== selectorFactoryOptions) { + lastStore = store; + lastSelectorFactoryOptions = selectorFactoryOptions; + sourceSelector = selectorFactory(store.dispatch, selectorFactoryOptions); + } + + lastProps = props; + lastState = state; + var nextProps = sourceSelector(state, props); + lastDerivedProps = nextProps; + return lastDerivedProps; + }; + } + + function makeChildElementSelector() { + var lastChildProps, lastForwardRef, lastChildElement, lastComponent; + return function selectChildElement(WrappedComponent, childProps, forwardRef) { + if (childProps !== lastChildProps || forwardRef !== lastForwardRef || lastComponent !== WrappedComponent) { + lastChildProps = childProps; + lastForwardRef = forwardRef; + lastComponent = WrappedComponent; + lastChildElement = __WEBPACK_IMPORTED_MODULE_6_react___default.a.createElement(WrappedComponent, Object(__WEBPACK_IMPORTED_MODULE_2__babel_runtime_helpers_esm_extends__["a" /* default */])({}, childProps, { + ref: forwardRef + })); + } + + return lastChildElement; + }; + } + + var Connect = + /*#__PURE__*/ + function (_OuterBaseComponent) { + Object(__WEBPACK_IMPORTED_MODULE_1__babel_runtime_helpers_esm_inheritsLoose__["a" /* default */])(Connect, _OuterBaseComponent); + + function Connect(props) { + var _this; + + _this = _OuterBaseComponent.call(this, props) || this; + __WEBPACK_IMPORTED_MODULE_5_invariant___default()(forwardRef ? !props.wrapperProps[storeKey] : !props[storeKey], 'Passing redux store in props has been removed and does not do anything. ' + customStoreWarningMessage); + _this.selectDerivedProps = makeDerivedPropsSelector(); + _this.selectChildElement = makeChildElementSelector(); + _this.indirectRenderWrappedComponent = _this.indirectRenderWrappedComponent.bind(Object(__WEBPACK_IMPORTED_MODULE_0__babel_runtime_helpers_esm_assertThisInitialized__["a" /* default */])(_this)); + return _this; + } + + var _proto = Connect.prototype; + + _proto.indirectRenderWrappedComponent = function indirectRenderWrappedComponent(value) { + // calling renderWrappedComponent on prototype from indirectRenderWrappedComponent bound to `this` + return this.renderWrappedComponent(value); + }; + + _proto.renderWrappedComponent = function renderWrappedComponent(value) { + __WEBPACK_IMPORTED_MODULE_5_invariant___default()(value, "Could not find \"store\" in the context of " + ("\"" + displayName + "\". Either wrap the root component in a , ") + "or pass a custom React context provider to and the corresponding " + ("React context consumer to " + displayName + " in connect options.")); + var storeState = value.storeState, + store = value.store; + var wrapperProps = this.props; + var forwardedRef; + + if (forwardRef) { + wrapperProps = this.props.wrapperProps; + forwardedRef = this.props.forwardedRef; + } + + var derivedProps = this.selectDerivedProps(storeState, wrapperProps, store, selectorFactoryOptions); + return this.selectChildElement(WrappedComponent, derivedProps, forwardedRef); + }; + + _proto.render = function render() { + var ContextToUse = this.props.context && this.props.context.Consumer && Object(__WEBPACK_IMPORTED_MODULE_7_react_is__["isContextConsumer"])(__WEBPACK_IMPORTED_MODULE_6_react___default.a.createElement(this.props.context.Consumer, null)) ? this.props.context : Context; + return __WEBPACK_IMPORTED_MODULE_6_react___default.a.createElement(ContextToUse.Consumer, null, this.indirectRenderWrappedComponent); + }; + + return Connect; + }(OuterBaseComponent); + + Connect.WrappedComponent = WrappedComponent; + Connect.displayName = displayName; + + if (forwardRef) { + var forwarded = __WEBPACK_IMPORTED_MODULE_6_react___default.a.forwardRef(function forwardConnectRef(props, ref) { + return __WEBPACK_IMPORTED_MODULE_6_react___default.a.createElement(Connect, { + wrapperProps: props, + forwardedRef: ref + }); + }); + forwarded.displayName = displayName; + forwarded.WrappedComponent = WrappedComponent; + return __WEBPACK_IMPORTED_MODULE_4_hoist_non_react_statics___default()(forwarded, WrappedComponent); + } + + return __WEBPACK_IMPORTED_MODULE_4_hoist_non_react_statics___default()(Connect, WrappedComponent); + }; +} +/* WEBPACK VAR INJECTION */}.call(__webpack_exports__, __webpack_require__(10))) + +/***/ }), +/* 70 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/* harmony export (immutable) */ __webpack_exports__["a"] = wrapMapToPropsConstant; +/* unused harmony export getDependsOnOwnProps */ +/* harmony export (immutable) */ __webpack_exports__["b"] = wrapMapToPropsFunc; +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__utils_verifyPlainObject__ = __webpack_require__(71); + +function wrapMapToPropsConstant(getConstant) { + return function initConstantSelector(dispatch, options) { + var constant = getConstant(dispatch, options); + + function constantSelector() { + return constant; + } + + constantSelector.dependsOnOwnProps = false; + return constantSelector; + }; +} // dependsOnOwnProps is used by createMapToPropsProxy to determine whether to pass props as args +// to the mapToProps function being wrapped. It is also used by makePurePropsSelector to determine +// whether mapToProps needs to be invoked when props have changed. +// +// A length of one signals that mapToProps does not depend on props from the parent component. +// A length of zero is assumed to mean mapToProps is getting args via arguments or ...args and +// therefore not reporting its length accurately.. + +function getDependsOnOwnProps(mapToProps) { + return mapToProps.dependsOnOwnProps !== null && mapToProps.dependsOnOwnProps !== undefined ? Boolean(mapToProps.dependsOnOwnProps) : mapToProps.length !== 1; +} // Used by whenMapStateToPropsIsFunction and whenMapDispatchToPropsIsFunction, +// this function wraps mapToProps in a proxy function which does several things: +// +// * Detects whether the mapToProps function being called depends on props, which +// is used by selectorFactory to decide if it should reinvoke on props changes. +// +// * On first call, handles mapToProps if returns another function, and treats that +// new function as the true mapToProps for subsequent calls. +// +// * On first call, verifies the first result is a plain object, in order to warn +// the developer that their mapToProps function is not returning a valid result. +// + +function wrapMapToPropsFunc(mapToProps, methodName) { + return function initProxySelector(dispatch, _ref) { + var displayName = _ref.displayName; + + var proxy = function mapToPropsProxy(stateOrDispatch, ownProps) { + return proxy.dependsOnOwnProps ? proxy.mapToProps(stateOrDispatch, ownProps) : proxy.mapToProps(stateOrDispatch); + }; // allow detectFactoryAndVerify to get ownProps + + + proxy.dependsOnOwnProps = true; + + proxy.mapToProps = function detectFactoryAndVerify(stateOrDispatch, ownProps) { + proxy.mapToProps = mapToProps; + proxy.dependsOnOwnProps = getDependsOnOwnProps(mapToProps); + var props = proxy(stateOrDispatch, ownProps); + + if (typeof props === 'function') { + proxy.mapToProps = props; + proxy.dependsOnOwnProps = getDependsOnOwnProps(props); + props = proxy(stateOrDispatch, ownProps); + } + + if (process.env.NODE_ENV !== 'production') Object(__WEBPACK_IMPORTED_MODULE_0__utils_verifyPlainObject__["a" /* default */])(props, displayName, methodName); + return props; + }; + + return proxy; + }; +} +/* WEBPACK VAR INJECTION */}.call(__webpack_exports__, __webpack_require__(10))) + +/***/ }), +/* 71 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +/* harmony export (immutable) */ __webpack_exports__["a"] = verifyPlainObject; +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__isPlainObject__ = __webpack_require__(117); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__warning__ = __webpack_require__(72); + + +function verifyPlainObject(value, displayName, methodName) { + if (!Object(__WEBPACK_IMPORTED_MODULE_0__isPlainObject__["a" /* default */])(value)) { + Object(__WEBPACK_IMPORTED_MODULE_1__warning__["a" /* default */])(methodName + "() in " + displayName + " must return a plain object. Instead received " + value + "."); + } +} + +/***/ }), +/* 72 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +/* harmony export (immutable) */ __webpack_exports__["a"] = warning; +/** + * Prints a warning in the console if it exists. + * + * @param {String} message The warning message. + * @returns {void} + */ +function warning(message) { + /* eslint-disable no-console */ + if (typeof console !== 'undefined' && typeof console.error === 'function') { + console.error(message); + } + /* eslint-enable no-console */ + + + try { + // This error was thrown as a convenience so that if you enable + // "break on all exceptions" in your console, + // it would pause the execution at this line. + throw new Error(message); + /* eslint-disable no-empty */ + } catch (e) {} + /* eslint-enable no-empty */ + +} + +/***/ }), +/* 73 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react__ = __webpack_require__(0); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_react__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_prop_types__ = __webpack_require__(12); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_prop_types___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_prop_types__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_invariant__ = __webpack_require__(27); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_invariant___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_invariant__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_history__ = __webpack_require__(32); +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + +function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; } + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + + + + + + +var isModifiedEvent = function isModifiedEvent(event) { + return !!(event.metaKey || event.altKey || event.ctrlKey || event.shiftKey); +}; + +/** + * The public API for rendering a history-aware . + */ + +var Link = function (_React$Component) { + _inherits(Link, _React$Component); + + function Link() { + var _temp, _this, _ret; + + _classCallCheck(this, Link); + + for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { + args[_key] = arguments[_key]; + } + + return _ret = (_temp = (_this = _possibleConstructorReturn(this, _React$Component.call.apply(_React$Component, [this].concat(args))), _this), _this.handleClick = function (event) { + if (_this.props.onClick) _this.props.onClick(event); + + if (!event.defaultPrevented && // onClick prevented default + event.button === 0 && // ignore everything but left clicks + !_this.props.target && // let browser handle "target=_blank" etc. + !isModifiedEvent(event) // ignore clicks with modifier keys + ) { + event.preventDefault(); + + var history = _this.context.router.history; + var _this$props = _this.props, + replace = _this$props.replace, + to = _this$props.to; + + + if (replace) { + history.replace(to); + } else { + history.push(to); + } + } + }, _temp), _possibleConstructorReturn(_this, _ret); + } + + Link.prototype.render = function render() { + var _props = this.props, + replace = _props.replace, + to = _props.to, + innerRef = _props.innerRef, + props = _objectWithoutProperties(_props, ["replace", "to", "innerRef"]); // eslint-disable-line no-unused-vars + + __WEBPACK_IMPORTED_MODULE_2_invariant___default()(this.context.router, "You should not use outside a "); + + __WEBPACK_IMPORTED_MODULE_2_invariant___default()(to !== undefined, 'You must specify the "to" property'); + + var history = this.context.router.history; + + var location = typeof to === "string" ? Object(__WEBPACK_IMPORTED_MODULE_3_history__["c" /* createLocation */])(to, null, null, history.location) : to; + + var href = history.createHref(location); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement("a", _extends({}, props, { onClick: this.handleClick, href: href, ref: innerRef })); + }; + + return Link; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); + +Link.propTypes = { + onClick: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + target: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + replace: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + to: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object]).isRequired, + innerRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func]) +}; +Link.defaultProps = { + replace: false +}; +Link.contextTypes = { + router: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ + history: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ + push: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func.isRequired, + replace: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func.isRequired, + createHref: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func.isRequired + }).isRequired + }).isRequired +}; + + +/* harmony default export */ __webpack_exports__["a"] = (Link); + +/***/ }), +/* 74 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_warning__ = __webpack_require__(28); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_warning___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_warning__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_react__ = __webpack_require__(0); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_react__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_prop_types__ = __webpack_require__(12); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_prop_types___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_prop_types__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_history__ = __webpack_require__(32); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__Router__ = __webpack_require__(46); +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + + + + + + + +/** + * The public API for a that stores location in memory. + */ + +var MemoryRouter = function (_React$Component) { + _inherits(MemoryRouter, _React$Component); + + function MemoryRouter() { + var _temp, _this, _ret; + + _classCallCheck(this, MemoryRouter); + + for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { + args[_key] = arguments[_key]; + } + + return _ret = (_temp = (_this = _possibleConstructorReturn(this, _React$Component.call.apply(_React$Component, [this].concat(args))), _this), _this.history = Object(__WEBPACK_IMPORTED_MODULE_3_history__["d" /* createMemoryHistory */])(_this.props), _temp), _possibleConstructorReturn(_this, _ret); + } + + MemoryRouter.prototype.componentWillMount = function componentWillMount() { + __WEBPACK_IMPORTED_MODULE_0_warning___default()(!this.props.history, " ignores the history prop. To use a custom history, " + "use `import { Router }` instead of `import { MemoryRouter as Router }`."); + }; + + MemoryRouter.prototype.render = function render() { + return __WEBPACK_IMPORTED_MODULE_1_react___default.a.createElement(__WEBPACK_IMPORTED_MODULE_4__Router__["a" /* default */], { history: this.history, children: this.props.children }); + }; + + return MemoryRouter; +}(__WEBPACK_IMPORTED_MODULE_1_react___default.a.Component); + +MemoryRouter.propTypes = { + initialEntries: __WEBPACK_IMPORTED_MODULE_2_prop_types___default.a.array, + initialIndex: __WEBPACK_IMPORTED_MODULE_2_prop_types___default.a.number, + getUserConfirmation: __WEBPACK_IMPORTED_MODULE_2_prop_types___default.a.func, + keyLength: __WEBPACK_IMPORTED_MODULE_2_prop_types___default.a.number, + children: __WEBPACK_IMPORTED_MODULE_2_prop_types___default.a.node +}; + + +/* harmony default export */ __webpack_exports__["a"] = (MemoryRouter); + +/***/ }), +/* 75 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react_router_es_Route__ = __webpack_require__(57); +// Written in this round about way for babel-transform-imports + + +/* harmony default export */ __webpack_exports__["a"] = (__WEBPACK_IMPORTED_MODULE_0_react_router_es_Route__["a" /* default */]); + +/***/ }), +/* 76 */ +/***/ (function(module, exports, __webpack_require__) { + +var isarray = __webpack_require__(130) /** * Expose `pathToRegexp`. @@ -22495,1223 +25006,17 @@ function pathToRegexp (path, keys, options) { } -/***/ }), -/* 53 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-2015, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - */ - - - -/** - * Similar to invariant but only logs a warning if the condition is not met. - * This can be used to log issues in development environments in critical - * paths. Removing the logging code for production environments will keep the - * same logic and follow the same code paths. - */ - -var warning = function() {}; - -if (process.env.NODE_ENV !== 'production') { - warning = function(condition, format, args) { - var len = arguments.length; - args = new Array(len > 2 ? len - 2 : 0); - for (var key = 2; key < len; key++) { - args[key - 2] = arguments[key]; - } - if (format === undefined) { - throw new Error( - '`warning(condition, format, ...args)` requires a warning ' + - 'message argument' - ); - } - - if (format.length < 10 || (/^[s\W]*$/).test(format)) { - throw new Error( - 'The warning format should be able to uniquely identify this ' + - 'warning. Please, use a more descriptive format than: ' + format - ); - } - - if (!condition) { - var argIndex = 0; - var message = 'Warning: ' + - format.replace(/%s/g, function() { - return args[argIndex++]; - }); - if (typeof console !== 'undefined') { - console.error(message); - } - try { - // This error was thrown as a convenience so that you can use this stack - // to find the callsite that caused this warning to fire. - throw new Error(message); - } catch(x) {} - } - }; -} - -module.exports = warning; - -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(6))) - -/***/ }), -/* 54 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return createLocation; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return locationsAreEqual; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_resolve_pathname__ = __webpack_require__(91); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_value_equal__ = __webpack_require__(92); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__PathUtils__ = __webpack_require__(44); -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; - - - - - -var createLocation = function createLocation(path, state, key, currentLocation) { - var location = void 0; - if (typeof path === 'string') { - // Two-arg form: push(path, state) - location = Object(__WEBPACK_IMPORTED_MODULE_2__PathUtils__["d" /* parsePath */])(path); - location.state = state; - } else { - // One-arg form: push(location) - location = _extends({}, path); - - if (location.pathname === undefined) location.pathname = ''; - - if (location.search) { - if (location.search.charAt(0) !== '?') location.search = '?' + location.search; - } else { - location.search = ''; - } - - if (location.hash) { - if (location.hash.charAt(0) !== '#') location.hash = '#' + location.hash; - } else { - location.hash = ''; - } - - if (state !== undefined && location.state === undefined) location.state = state; - } - - try { - location.pathname = decodeURI(location.pathname); - } catch (e) { - if (e instanceof URIError) { - throw new URIError('Pathname "' + location.pathname + '" could not be decoded. ' + 'This is likely caused by an invalid percent-encoding.'); - } else { - throw e; - } - } - - if (key) location.key = key; - - if (currentLocation) { - // Resolve incomplete/relative pathname relative to current location. - if (!location.pathname) { - location.pathname = currentLocation.pathname; - } else if (location.pathname.charAt(0) !== '/') { - location.pathname = Object(__WEBPACK_IMPORTED_MODULE_0_resolve_pathname__["a" /* default */])(location.pathname, currentLocation.pathname); - } - } else { - // When there is no prior location and pathname is empty, set it to / - if (!location.pathname) { - location.pathname = '/'; - } - } - - return location; -}; - -var locationsAreEqual = function locationsAreEqual(a, b) { - return a.pathname === b.pathname && a.search === b.search && a.hash === b.hash && a.key === b.key && Object(__WEBPACK_IMPORTED_MODULE_1_value_equal__["a" /* default */])(a.state, b.state); -}; - -/***/ }), -/* 55 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(0); - -var _react2 = _interopRequireDefault(_react); - -var _ErrorMessage = __webpack_require__(34); - -var _ErrorMessage2 = _interopRequireDefault(_ErrorMessage); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - -var ErrorBoundary = function (_React$Component) { - _inherits(ErrorBoundary, _React$Component); - - function ErrorBoundary(props) { - _classCallCheck(this, ErrorBoundary); - - var _this = _possibleConstructorReturn(this, (ErrorBoundary.__proto__ || Object.getPrototypeOf(ErrorBoundary)).call(this, props)); - - _this.state = { - hasError: false, - error: null, - info: null - }; - return _this; - } - - _createClass(ErrorBoundary, [{ - key: 'componentDidCatch', - value: function componentDidCatch(error, info) { - this.setState({ - hasError: true, - error: error, - info: info - }); - console.error(error, info); - } - }, { - key: 'render', - value: function render() { - if (this.state.hasError) { - return _react2.default.createElement( - _ErrorMessage2.default, - { type: 'error-boundary' }, - this.state.info ? _react2.default.createElement( - 'pre', - { className: 'error-message__trace' }, - this.state.info.componentStack - ) : null - ); - } - return this.props.children; - } - }]); - - return ErrorBoundary; -}(_react2.default.Component); - -exports.default = ErrorBoundary; - -/***/ }), -/* 56 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(0); - -var _react2 = _interopRequireDefault(_react); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - -var NiceNumber = function (_React$Component) { - _inherits(NiceNumber, _React$Component); - - function NiceNumber(props) { - _classCallCheck(this, NiceNumber); - - return _possibleConstructorReturn(this, (NiceNumber.__proto__ || Object.getPrototypeOf(NiceNumber)).call(this, props)); - } - - _createClass(NiceNumber, [{ - key: 'format', - value: function format() { - var formatted = parseInt(this.props.value); - - // > 1 million - if (formatted > 1000000) { - formatted = formatted / 1000000; - formatted = Math.round(formatted * 10) / 10; - formatted = formatted + 'm'; - - // > 1 thousand - } else if (formatted > 1000) { - formatted = formatted / 1000; - formatted = Math.round(formatted * 10) / 10; - formatted = formatted + 'k'; - } else { - formatted = formatted.toLocaleString(); - } - - return formatted; - } - }, { - key: 'render', - value: function render() { - return _react2.default.createElement( - 'span', - { className: 'counter' }, - this.format() - ); - } - }]); - - return NiceNumber; -}(_react2.default.Component); - -exports.default = NiceNumber; - -/***/ }), -/* 57 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _captialize = __webpack_require__(278); - -Object.defineProperty(exports, 'captialize', { - enumerable: true, - get: function get() { - return _interopRequireDefault(_captialize).default; - } -}); - -var _clamp = __webpack_require__(279); - -Object.defineProperty(exports, 'clamp', { - enumerable: true, - get: function get() { - return _interopRequireDefault(_clamp).default; - } -}); - -var _distanceTo = __webpack_require__(280); - -Object.defineProperty(exports, 'distanceTo', { - enumerable: true, - get: function get() { - return _interopRequireDefault(_distanceTo).default; - } -}); - -var _isDefined = __webpack_require__(281); - -Object.defineProperty(exports, 'isDefined', { - enumerable: true, - get: function get() { - return _interopRequireDefault(_isDefined).default; - } -}); - -var _isNumber = __webpack_require__(282); - -Object.defineProperty(exports, 'isNumber', { - enumerable: true, - get: function get() { - return _interopRequireDefault(_isNumber).default; - } -}); - -var _isObject = __webpack_require__(283); - -Object.defineProperty(exports, 'isObject', { - enumerable: true, - get: function get() { - return _interopRequireDefault(_isObject).default; - } -}); - -var _length = __webpack_require__(284); - -Object.defineProperty(exports, 'length', { - enumerable: true, - get: function get() { - return _interopRequireDefault(_length).default; - } -}); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } -//# sourceMappingURL=index.js.map - -/***/ }), -/* 58 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) { - -function checkDCE() { - /* global __REACT_DEVTOOLS_GLOBAL_HOOK__ */ - if ( - typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ === 'undefined' || - typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE !== 'function' - ) { - return; - } - if (process.env.NODE_ENV !== 'production') { - // This branch is unreachable because this function is only called - // in production, but the condition is true only in development. - // Therefore if the branch is still here, dead code elimination wasn't - // properly applied. - // Don't change the message. React DevTools relies on it. Also make sure - // this message doesn't occur elsewhere in this function, or it will cause - // a false positive. - throw new Error('^_^'); - } - try { - // Verify that the code above has been dead code eliminated (DCE'd). - __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(checkDCE); - } catch (err) { - // DevTools shouldn't crash React, no matter what. - // We should still report in case we break this code. - console.error(err); - } -} - -if (process.env.NODE_ENV === 'production') { - // DCE check should happen before ReactDOM bundle executes so that - // DevTools can report bad minification during injection. - checkDCE(); - module.exports = __webpack_require__(120); -} else { - module.exports = __webpack_require__(123); -} - -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(6))) - -/***/ }), -/* 59 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */ - - - -var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED'; - -module.exports = ReactPropTypesSecret; - - -/***/ }), -/* 60 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return ReactReduxContext; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_react__); - -var ReactReduxContext = __WEBPACK_IMPORTED_MODULE_0_react___default.a.createContext(null); -/* unused harmony default export */ var _unused_webpack_default_export = (ReactReduxContext); - -/***/ }), -/* 61 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = _extends; -function _extends() { - _extends = Object.assign || function (target) { - for (var i = 1; i < arguments.length; i++) { - var source = arguments[i]; - - for (var key in source) { - if (Object.prototype.hasOwnProperty.call(source, key)) { - target[key] = source[key]; - } - } - } - - return target; - }; - - return _extends.apply(this, arguments); -} - -/***/ }), -/* 62 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = _objectWithoutPropertiesLoose; -function _objectWithoutPropertiesLoose(source, excluded) { - if (source == null) return {}; - var target = {}; - var sourceKeys = Object.keys(source); - var key, i; - - for (i = 0; i < sourceKeys.length; i++) { - key = sourceKeys[i]; - if (excluded.indexOf(key) >= 0) continue; - target[key] = source[key]; - } - - return target; -} - -/***/ }), -/* 63 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */ - - - -var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED'; - -module.exports = ReactPropTypesSecret; - - -/***/ }), -/* 64 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_warning__ = __webpack_require__(50); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_warning___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_warning__); - - -var createTransitionManager = function createTransitionManager() { - var prompt = null; - - var setPrompt = function setPrompt(nextPrompt) { - __WEBPACK_IMPORTED_MODULE_0_warning___default()(prompt == null, 'A history supports only one prompt at a time'); - - prompt = nextPrompt; - - return function () { - if (prompt === nextPrompt) prompt = null; - }; - }; - - var confirmTransitionTo = function confirmTransitionTo(location, action, getUserConfirmation, callback) { - // TODO: If another transition starts while we're still confirming - // the previous one, we may end up in a weird state. Figure out the - // best way to handle this. - if (prompt != null) { - var result = typeof prompt === 'function' ? prompt(location, action) : prompt; - - if (typeof result === 'string') { - if (typeof getUserConfirmation === 'function') { - getUserConfirmation(result, callback); - } else { - __WEBPACK_IMPORTED_MODULE_0_warning___default()(false, 'A history needs a getUserConfirmation function in order to use a prompt message'); - - callback(true); - } - } else { - // Return false from a transition hook to cancel the transition. - callback(result !== false); - } - } else { - callback(true); - } - }; - - var listeners = []; - - var appendListener = function appendListener(fn) { - var isActive = true; - - var listener = function listener() { - if (isActive) fn.apply(undefined, arguments); - }; - - listeners.push(listener); - - return function () { - isActive = false; - listeners = listeners.filter(function (item) { - return item !== listener; - }); - }; - }; - - var notifyListeners = function notifyListeners() { - for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { - args[_key] = arguments[_key]; - } - - listeners.forEach(function (listener) { - return listener.apply(undefined, args); - }); - }; - - return { - setPrompt: setPrompt, - confirmTransitionTo: confirmTransitionTo, - appendListener: appendListener, - notifyListeners: notifyListeners - }; -}; - -/* harmony default export */ __webpack_exports__["a"] = (createTransitionManager); - -/***/ }), -/* 65 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react_router_es_Router__ = __webpack_require__(66); -// Written in this round about way for babel-transform-imports - - -/* harmony default export */ __webpack_exports__["a"] = (__WEBPACK_IMPORTED_MODULE_0_react_router_es_Router__["a" /* default */]); - -/***/ }), -/* 66 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_warning__ = __webpack_require__(28); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_warning___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_warning__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_invariant__ = __webpack_require__(25); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_invariant___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_invariant__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_react__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_react__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_prop_types__ = __webpack_require__(20); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_prop_types___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3_prop_types__); -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - - - - - - -/** - * The public API for putting history on context. - */ - -var Router = function (_React$Component) { - _inherits(Router, _React$Component); - - function Router() { - var _temp, _this, _ret; - - _classCallCheck(this, Router); - - for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { - args[_key] = arguments[_key]; - } - - return _ret = (_temp = (_this = _possibleConstructorReturn(this, _React$Component.call.apply(_React$Component, [this].concat(args))), _this), _this.state = { - match: _this.computeMatch(_this.props.history.location.pathname) - }, _temp), _possibleConstructorReturn(_this, _ret); - } - - Router.prototype.getChildContext = function getChildContext() { - return { - router: _extends({}, this.context.router, { - history: this.props.history, - route: { - location: this.props.history.location, - match: this.state.match - } - }) - }; - }; - - Router.prototype.computeMatch = function computeMatch(pathname) { - return { - path: "/", - url: "/", - params: {}, - isExact: pathname === "/" - }; - }; - - Router.prototype.componentWillMount = function componentWillMount() { - var _this2 = this; - - var _props = this.props, - children = _props.children, - history = _props.history; - - - __WEBPACK_IMPORTED_MODULE_1_invariant___default()(children == null || __WEBPACK_IMPORTED_MODULE_2_react___default.a.Children.count(children) === 1, "A may have only one child element"); - - // Do this here so we can setState when a changes the - // location in componentWillMount. This happens e.g. when doing - // server rendering using a . - this.unlisten = history.listen(function () { - _this2.setState({ - match: _this2.computeMatch(history.location.pathname) - }); - }); - }; - - Router.prototype.componentWillReceiveProps = function componentWillReceiveProps(nextProps) { - __WEBPACK_IMPORTED_MODULE_0_warning___default()(this.props.history === nextProps.history, "You cannot change "); - }; - - Router.prototype.componentWillUnmount = function componentWillUnmount() { - this.unlisten(); - }; - - Router.prototype.render = function render() { - var children = this.props.children; - - return children ? __WEBPACK_IMPORTED_MODULE_2_react___default.a.Children.only(children) : null; - }; - - return Router; -}(__WEBPACK_IMPORTED_MODULE_2_react___default.a.Component); - -Router.propTypes = { - history: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object.isRequired, - children: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.node -}; -Router.contextTypes = { - router: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object -}; -Router.childContextTypes = { - router: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object.isRequired -}; - - -/* harmony default export */ __webpack_exports__["a"] = (Router); - -/***/ }), -/* 67 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_path_to_regexp__ = __webpack_require__(52); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_path_to_regexp___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_path_to_regexp__); - - -var patternCache = {}; -var cacheLimit = 10000; -var cacheCount = 0; - -var compilePath = function compilePath(pattern, options) { - var cacheKey = "" + options.end + options.strict + options.sensitive; - var cache = patternCache[cacheKey] || (patternCache[cacheKey] = {}); - - if (cache[pattern]) return cache[pattern]; - - var keys = []; - var re = __WEBPACK_IMPORTED_MODULE_0_path_to_regexp___default()(pattern, keys, options); - var compiledPattern = { re: re, keys: keys }; - - if (cacheCount < cacheLimit) { - cache[pattern] = compiledPattern; - cacheCount++; - } - - return compiledPattern; -}; - -/** - * Public API for matching a URL pathname to a path pattern. - */ -var matchPath = function matchPath(pathname) { - var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}; - var parent = arguments[2]; - - if (typeof options === "string") options = { path: options }; - - var _options = options, - path = _options.path, - _options$exact = _options.exact, - exact = _options$exact === undefined ? false : _options$exact, - _options$strict = _options.strict, - strict = _options$strict === undefined ? false : _options$strict, - _options$sensitive = _options.sensitive, - sensitive = _options$sensitive === undefined ? false : _options$sensitive; - - - if (path == null) return parent; - - var _compilePath = compilePath(path, { end: exact, strict: strict, sensitive: sensitive }), - re = _compilePath.re, - keys = _compilePath.keys; - - var match = re.exec(pathname); - - if (!match) return null; - - var url = match[0], - values = match.slice(1); - - var isExact = pathname === url; - - if (exact && !isExact) return null; - - return { - path: path, // the path pattern used to match - url: path === "/" && url === "" ? "/" : url, // the matched portion of the URL - isExact: isExact, // whether or not we matched exactly - params: keys.reduce(function (memo, key, index) { - memo[key.name] = values[index]; - return memo; - }, {}) - }; -}; - -/* harmony default export */ __webpack_exports__["a"] = (matchPath); - -/***/ }), -/* 68 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = warn; -function warn(s) { - console.warn('[react-ga]', s); -} - -/***/ }), -/* 69 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ - -function makeEmptyFunction(arg) { - return function () { - return arg; - }; -} - -/** - * This function accepts and discards inputs; it has no side effects. This is - * primarily useful idiomatically for overridable function endpoints which - * always need to be callable, since JS lacks a null-call idiom ala Cocoa. - */ -var emptyFunction = function emptyFunction() {}; - -emptyFunction.thatReturns = makeEmptyFunction; -emptyFunction.thatReturnsFalse = makeEmptyFunction(false); -emptyFunction.thatReturnsTrue = makeEmptyFunction(true); -emptyFunction.thatReturnsNull = makeEmptyFunction(null); -emptyFunction.thatReturnsThis = function () { - return this; -}; -emptyFunction.thatReturnsArgument = function (arg) { - return arg; -}; - -module.exports = emptyFunction; - -/***/ }), -/* 70 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - - - -/** - * Use invariant() to assert state which your program assumes to be true. - * - * Provide sprintf-style format (only %s is supported) and arguments - * to provide information about what broke and what you were - * expecting. - * - * The invariant message will be stripped in production, but the invariant - * will remain to ensure logic does not differ in production. - */ - -var validateFormat = function validateFormat(format) {}; - -if (process.env.NODE_ENV !== 'production') { - validateFormat = function validateFormat(format) { - if (format === undefined) { - throw new Error('invariant requires an error message argument'); - } - }; -} - -function invariant(condition, format, a, b, c, d, e, f) { - validateFormat(format); - - if (!condition) { - var error; - if (format === undefined) { - error = new Error('Minified exception occurred; use the non-minified dev environment ' + 'for the full error message and additional helpful warnings.'); - } else { - var args = [a, b, c, d, e, f]; - var argIndex = 0; - error = new Error(format.replace(/%s/g, function () { - return args[argIndex++]; - })); - error.name = 'Invariant Violation'; - } - - error.framesToPop = 1; // we don't care about invariant's own frame - throw error; - } -} - -module.exports = invariant; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(6))) - -/***/ }), -/* 71 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - */ - - - -var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED'; - -module.exports = ReactPropTypesSecret; - - -/***/ }), -/* 72 */ -/***/ (function(module, exports, __webpack_require__) { - -/* WEBPACK VAR INJECTION */(function(process) {var __WEBPACK_AMD_DEFINE_RESULT__;var require;/** @license MIT License (c) copyright 2010-2014 original author or authors */ -/** @author Brian Cavalier */ -/** @author John Hann */ - -/*global process,document,setTimeout,clearTimeout,MutationObserver,WebKitMutationObserver*/ -(function(define) { 'use strict'; -!(__WEBPACK_AMD_DEFINE_RESULT__ = (function(require) { - /*jshint maxcomplexity:6*/ - - // Sniff "best" async scheduling option - // Prefer process.nextTick or MutationObserver, then check for - // setTimeout, and finally vertx, since its the only env that doesn't - // have setTimeout - - var MutationObs; - var capturedSetTimeout = typeof setTimeout !== 'undefined' && setTimeout; - - // Default env - var setTimer = function(f, ms) { return setTimeout(f, ms); }; - var clearTimer = function(t) { return clearTimeout(t); }; - var asap = function (f) { return capturedSetTimeout(f, 0); }; - - // Detect specific env - if (isNode()) { // Node - asap = function (f) { return process.nextTick(f); }; - - } else if (MutationObs = hasMutationObserver()) { // Modern browser - asap = initMutationObserver(MutationObs); - - } else if (!capturedSetTimeout) { // vert.x - var vertxRequire = require; - var vertx = __webpack_require__(206); - setTimer = function (f, ms) { return vertx.setTimer(ms, f); }; - clearTimer = vertx.cancelTimer; - asap = vertx.runOnLoop || vertx.runOnContext; - } - - return { - setTimer: setTimer, - clearTimer: clearTimer, - asap: asap - }; - - function isNode () { - return typeof process !== 'undefined' && - Object.prototype.toString.call(process) === '[object process]'; - } - - function hasMutationObserver () { - return (typeof MutationObserver !== 'undefined' && MutationObserver) || - (typeof WebKitMutationObserver !== 'undefined' && WebKitMutationObserver); - } - - function initMutationObserver(MutationObserver) { - var scheduled; - var node = document.createTextNode(''); - var o = new MutationObserver(run); - o.observe(node, { characterData: true }); - - function run() { - var f = scheduled; - scheduled = void 0; - f(); - } - - var i = 0; - return function (f) { - scheduled = f; - node.data = (i ^= 1); - }; - } -}).call(exports, __webpack_require__, exports, module), - __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); -}(__webpack_require__(15))); - -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(6))) - -/***/ }), -/* 73 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); -exports.set = set; -exports.getLibraryArtists = getLibraryArtists; -exports.clearLibraryArtists = clearLibraryArtists; -exports.getLibraryAlbums = getLibraryAlbums; -exports.clearLibraryAlbums = clearLibraryAlbums; -function set(data) { - return { - type: 'GOOGLE_SET', - data: data - }; -} - -function getLibraryArtists() { - return { - type: 'GOOGLE_GET_LIBRARY_ARTISTS' - }; -} - -function clearLibraryArtists() { - return { - type: 'GOOGLE_CLEAR_LIBRARY_ARTISTS' - }; -} - -function getLibraryAlbums() { - return { - 'type': 'GOOGLE_GET_LIBRARY_ALBUMS' - }; -} - -function clearLibraryAlbums() { - return { - type: 'GOOGLE_CLEAR_LIBRARY_ALBUMS' - }; -} - -/***/ }), -/* 74 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */ - - - -var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED'; - -module.exports = ReactPropTypesSecret; - - -/***/ }), -/* 75 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__createBrowserHistory__ = __webpack_require__(231); -/* unused harmony reexport createBrowserHistory */ -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__createHashHistory__ = __webpack_require__(232); -/* unused harmony reexport createHashHistory */ -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__createMemoryHistory__ = __webpack_require__(233); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return __WEBPACK_IMPORTED_MODULE_2__createMemoryHistory__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__LocationUtils__ = __webpack_require__(54); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return __WEBPACK_IMPORTED_MODULE_3__LocationUtils__["a"]; }); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "d", function() { return __WEBPACK_IMPORTED_MODULE_3__LocationUtils__["b"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__PathUtils__ = __webpack_require__(44); -/* unused harmony reexport parsePath */ -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return __WEBPACK_IMPORTED_MODULE_4__PathUtils__["b"]; }); - - - - - - - - - - -/***/ }), -/* 76 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_warning__ = __webpack_require__(53); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_warning___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_warning__); - - -var createTransitionManager = function createTransitionManager() { - var prompt = null; - - var setPrompt = function setPrompt(nextPrompt) { - __WEBPACK_IMPORTED_MODULE_0_warning___default()(prompt == null, 'A history supports only one prompt at a time'); - - prompt = nextPrompt; - - return function () { - if (prompt === nextPrompt) prompt = null; - }; - }; - - var confirmTransitionTo = function confirmTransitionTo(location, action, getUserConfirmation, callback) { - // TODO: If another transition starts while we're still confirming - // the previous one, we may end up in a weird state. Figure out the - // best way to handle this. - if (prompt != null) { - var result = typeof prompt === 'function' ? prompt(location, action) : prompt; - - if (typeof result === 'string') { - if (typeof getUserConfirmation === 'function') { - getUserConfirmation(result, callback); - } else { - __WEBPACK_IMPORTED_MODULE_0_warning___default()(false, 'A history needs a getUserConfirmation function in order to use a prompt message'); - - callback(true); - } - } else { - // Return false from a transition hook to cancel the transition. - callback(result !== false); - } - } else { - callback(true); - } - }; - - var listeners = []; - - var appendListener = function appendListener(fn) { - var isActive = true; - - var listener = function listener() { - if (isActive) fn.apply(undefined, arguments); - }; - - listeners.push(listener); - - return function () { - isActive = false; - listeners = listeners.filter(function (item) { - return item !== listener; - }); - }; - }; - - var notifyListeners = function notifyListeners() { - for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { - args[_key] = arguments[_key]; - } - - listeners.forEach(function (listener) { - return listener.apply(undefined, args); - }); - }; - - return { - setPrompt: setPrompt, - confirmTransitionTo: confirmTransitionTo, - appendListener: appendListener, - notifyListeners: notifyListeners - }; -}; - -/* harmony default export */ __webpack_exports__["a"] = (createTransitionManager); - /***/ }), /* 77 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_warning__ = __webpack_require__(39); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_warning___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_warning__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_invariant__ = __webpack_require__(40); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_invariant___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_invariant__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_react__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_react__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_prop_types__ = __webpack_require__(29); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_prop_types___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3_prop_types__); -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; - +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react__ = __webpack_require__(0); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_react__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_prop_types__ = __webpack_require__(12); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_prop_types___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_prop_types__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_invariant__ = __webpack_require__(27); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_invariant___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_invariant__); function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } @@ -23722,1244 +25027,220 @@ function _inherits(subClass, superClass) { if (typeof superClass !== "function" - /** - * The public API for putting history on context. + * The public API for prompting the user before navigating away + * from a screen with a component. */ -var Router = function (_React$Component) { - _inherits(Router, _React$Component); +var Prompt = function (_React$Component) { + _inherits(Prompt, _React$Component); - function Router() { - var _temp, _this, _ret; + function Prompt() { + _classCallCheck(this, Prompt); - _classCallCheck(this, Router); - - for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { - args[_key] = arguments[_key]; - } - - return _ret = (_temp = (_this = _possibleConstructorReturn(this, _React$Component.call.apply(_React$Component, [this].concat(args))), _this), _this.state = { - match: _this.computeMatch(_this.props.history.location.pathname) - }, _temp), _possibleConstructorReturn(_this, _ret); + return _possibleConstructorReturn(this, _React$Component.apply(this, arguments)); } - Router.prototype.getChildContext = function getChildContext() { - return { - router: _extends({}, this.context.router, { - history: this.props.history, - route: { - location: this.props.history.location, - match: this.state.match - } - }) - }; + Prompt.prototype.enable = function enable(message) { + if (this.unblock) this.unblock(); + + this.unblock = this.context.router.history.block(message); }; - Router.prototype.computeMatch = function computeMatch(pathname) { - return { - path: "/", - url: "/", - params: {}, - isExact: pathname === "/" - }; + Prompt.prototype.disable = function disable() { + if (this.unblock) { + this.unblock(); + this.unblock = null; + } }; - Router.prototype.componentWillMount = function componentWillMount() { - var _this2 = this; + Prompt.prototype.componentWillMount = function componentWillMount() { + __WEBPACK_IMPORTED_MODULE_2_invariant___default()(this.context.router, "You should not use outside a "); - var _props = this.props, - children = _props.children, - history = _props.history; - - - __WEBPACK_IMPORTED_MODULE_1_invariant___default()(children == null || __WEBPACK_IMPORTED_MODULE_2_react___default.a.Children.count(children) === 1, "A may have only one child element"); - - // Do this here so we can setState when a changes the - // location in componentWillMount. This happens e.g. when doing - // server rendering using a . - this.unlisten = history.listen(function () { - _this2.setState({ - match: _this2.computeMatch(history.location.pathname) - }); - }); + if (this.props.when) this.enable(this.props.message); }; - Router.prototype.componentWillReceiveProps = function componentWillReceiveProps(nextProps) { - __WEBPACK_IMPORTED_MODULE_0_warning___default()(this.props.history === nextProps.history, "You cannot change "); + Prompt.prototype.componentWillReceiveProps = function componentWillReceiveProps(nextProps) { + if (nextProps.when) { + if (!this.props.when || this.props.message !== nextProps.message) this.enable(nextProps.message); + } else { + this.disable(); + } }; - Router.prototype.componentWillUnmount = function componentWillUnmount() { - this.unlisten(); + Prompt.prototype.componentWillUnmount = function componentWillUnmount() { + this.disable(); }; - Router.prototype.render = function render() { - var children = this.props.children; - - return children ? __WEBPACK_IMPORTED_MODULE_2_react___default.a.Children.only(children) : null; + Prompt.prototype.render = function render() { + return null; }; - return Router; -}(__WEBPACK_IMPORTED_MODULE_2_react___default.a.Component); + return Prompt; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); -Router.propTypes = { - history: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object.isRequired, - children: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.node +Prompt.propTypes = { + when: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + message: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]).isRequired }; -Router.contextTypes = { - router: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object +Prompt.defaultProps = { + when: true }; -Router.childContextTypes = { - router: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object.isRequired +Prompt.contextTypes = { + router: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ + history: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ + block: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func.isRequired + }).isRequired + }).isRequired }; -/* harmony default export */ __webpack_exports__["a"] = (Router); +/* harmony default export */ __webpack_exports__["a"] = (Prompt); /***/ }), /* 78 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_path_to_regexp__ = __webpack_require__(52); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_path_to_regexp___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_path_to_regexp__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react__ = __webpack_require__(0); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_react__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_prop_types__ = __webpack_require__(12); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_prop_types___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_prop_types__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_warning__ = __webpack_require__(28); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_warning___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_warning__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_invariant__ = __webpack_require__(27); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_invariant___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3_invariant__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_history__ = __webpack_require__(32); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__generatePath__ = __webpack_require__(58); +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } -var patternCache = {}; -var cacheLimit = 10000; -var cacheCount = 0; -var compilePath = function compilePath(pattern, options) { - var cacheKey = "" + options.end + options.strict + options.sensitive; - var cache = patternCache[cacheKey] || (patternCache[cacheKey] = {}); - if (cache[pattern]) return cache[pattern]; - var keys = []; - var re = __WEBPACK_IMPORTED_MODULE_0_path_to_regexp___default()(pattern, keys, options); - var compiledPattern = { re: re, keys: keys }; - if (cacheCount < cacheLimit) { - cache[pattern] = compiledPattern; - cacheCount++; - } - return compiledPattern; -}; /** - * Public API for matching a URL pathname to a path pattern. + * The public API for updating the location programmatically + * with a component. */ -var matchPath = function matchPath(pathname) { - var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}; - var parent = arguments[2]; - if (typeof options === "string") options = { path: options }; +var Redirect = function (_React$Component) { + _inherits(Redirect, _React$Component); - var _options = options, - path = _options.path, - _options$exact = _options.exact, - exact = _options$exact === undefined ? false : _options$exact, - _options$strict = _options.strict, - strict = _options$strict === undefined ? false : _options$strict, - _options$sensitive = _options.sensitive, - sensitive = _options$sensitive === undefined ? false : _options$sensitive; + function Redirect() { + _classCallCheck(this, Redirect); + return _possibleConstructorReturn(this, _React$Component.apply(this, arguments)); + } - if (path == null) return parent; - - var _compilePath = compilePath(path, { end: exact, strict: strict, sensitive: sensitive }), - re = _compilePath.re, - keys = _compilePath.keys; - - var match = re.exec(pathname); - - if (!match) return null; - - var url = match[0], - values = match.slice(1); - - var isExact = pathname === url; - - if (exact && !isExact) return null; - - return { - path: path, // the path pattern used to match - url: path === "/" && url === "" ? "/" : url, // the matched portion of the URL - isExact: isExact, // whether or not we matched exactly - params: keys.reduce(function (memo, key, index) { - memo[key.name] = values[index]; - return memo; - }, {}) + Redirect.prototype.isStatic = function isStatic() { + return this.context.router && this.context.router.staticContext; }; -}; -/* harmony default export */ __webpack_exports__["a"] = (matchPath); + Redirect.prototype.componentWillMount = function componentWillMount() { + __WEBPACK_IMPORTED_MODULE_3_invariant___default()(this.context.router, "You should not use outside a "); -/***/ }), -/* 79 */ -/***/ (function(module, exports, __webpack_require__) { + if (this.isStatic()) this.perform(); + }; -"use strict"; + Redirect.prototype.componentDidMount = function componentDidMount() { + if (!this.isStatic()) this.perform(); + }; + Redirect.prototype.componentDidUpdate = function componentDidUpdate(prevProps) { + var prevTo = Object(__WEBPACK_IMPORTED_MODULE_4_history__["c" /* createLocation */])(prevProps.to); + var nextTo = Object(__WEBPACK_IMPORTED_MODULE_4_history__["c" /* createLocation */])(this.props.to); -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(0); - -var _react2 = _interopRequireDefault(_react); - -var _Icon = __webpack_require__(5); - -var _Icon2 = _interopRequireDefault(_Icon); - -var _helpers = __webpack_require__(1); - -var helpers = _interopRequireWildcard(_helpers); - -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } } - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - -var VolumeControl = function (_React$Component) { - _inherits(VolumeControl, _React$Component); - - function VolumeControl(props) { - _classCallCheck(this, VolumeControl); - - var _this = _possibleConstructorReturn(this, (VolumeControl.__proto__ || Object.getPrototypeOf(VolumeControl)).call(this, props)); - - _this.handleChange = helpers.throttle(_this.handleChange.bind(_this), 100); - return _this; - } - - _createClass(VolumeControl, [{ - key: 'handleChange', - value: function handleChange(value) { - this.props.onVolumeChange(value, this.props.volume); - } - }, { - key: 'render', - value: function render() { - var _this2 = this; - - return _react2.default.createElement( - 'div', - { className: "slider__wrapper " + (this.props.className ? this.props.className : "") }, - _react2.default.createElement( - 'div', - { className: "slider slider--volume " + (this.props.mute ? "slider--muted" : "") }, - _react2.default.createElement('input', { - className: 'slider__input', - type: 'range', - min: '0', - max: '25', - value: this.props.volume / 4, - onChange: function onChange(e) { - return _this2.handleChange(parseInt(e.target.value) * 4); - } - }), - _react2.default.createElement( - 'div', - { className: 'slider__track' }, - _react2.default.createElement('div', { className: 'slider__track__progress', style: { width: this.props.volume + '%' } }) - ) - ) - ); - } - }]); - - return VolumeControl; -}(_react2.default.Component); - -exports.default = VolumeControl; - -/***/ }), -/* 80 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(0); - -var _react2 = _interopRequireDefault(_react); - -var _Icon = __webpack_require__(5); - -var _Icon2 = _interopRequireDefault(_Icon); - -var _helpers = __webpack_require__(1); - -var helpers = _interopRequireWildcard(_helpers); - -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } } - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - -var MuteControl = function (_React$Component) { - _inherits(MuteControl, _React$Component); - - function MuteControl(props) { - _classCallCheck(this, MuteControl); - - return _possibleConstructorReturn(this, (MuteControl.__proto__ || Object.getPrototypeOf(MuteControl)).call(this, props)); - } - - _createClass(MuteControl, [{ - key: 'render', - value: function render() { - var _this2 = this; - - if (this.props.mute) { - return _react2.default.createElement( - 'a', - { className: "control mute-control " + (this.props.noTooltip ? "" : "tooltip ") + (this.props.className ? this.props.className : ""), onClick: function onClick() { - return _this2.props.onMuteChange(false); - } }, - _react2.default.createElement(_Icon2.default, { className: 'red-text', name: 'volume_off' }), - this.props.noTooltip ? null : _react2.default.createElement( - 'span', - { className: 'tooltip__content' }, - 'Unmute' - ) - ); - } else { - return _react2.default.createElement( - 'a', - { className: "control mute-control " + (this.props.noTooltip ? "" : "tooltip ") + (this.props.className ? this.props.className : ""), onClick: function onClick() { - return _this2.props.onMuteChange(true); - } }, - _react2.default.createElement(_Icon2.default, { className: 'muted', name: 'volume_mute' }), - this.props.noTooltip ? null : _react2.default.createElement( - 'span', - { className: 'tooltip__content' }, - 'Mute' - ) - ); - } - } - }]); - - return MuteControl; -}(_react2.default.Component); - -exports.default = MuteControl; - -/***/ }), -/* 81 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(0); - -var _react2 = _interopRequireDefault(_react); - -var _Icon = __webpack_require__(5); - -var _Icon2 = _interopRequireDefault(_Icon); - -var _helpers = __webpack_require__(1); - -var helpers = _interopRequireWildcard(_helpers); - -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } } - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - -var Popularity = function (_React$Component) { - _inherits(Popularity, _React$Component); - - function Popularity(props) { - _classCallCheck(this, Popularity); - - return _possibleConstructorReturn(this, (Popularity.__proto__ || Object.getPrototypeOf(Popularity)).call(this, props)); - } - - _createClass(Popularity, [{ - key: 'render', - value: function render() { - if (this.props.popularity === undefined || this.props.popularity === null) { - return null; - } - - return _react2.default.createElement( - 'span', - { className: 'popularity' }, - _react2.default.createElement( - 'span', - { className: 'popularity-bars' }, - _react2.default.createElement('span', { className: "bar" + (this.props.popularity > 10 ? " filled" : "") }), - _react2.default.createElement('span', { className: "bar" + (this.props.popularity > 30 ? " filled" : "") }), - _react2.default.createElement('span', { className: "bar" + (this.props.popularity > 50 ? " filled" : "") }), - _react2.default.createElement('span', { className: "bar" + (this.props.popularity > 70 ? " filled" : "") }), - _react2.default.createElement('span', { className: "bar" + (this.props.popularity > 90 ? " filled" : "") }) - ), - _react2.default.createElement( - 'span', - { className: 'popularity-value' }, - this.props.popularity, - '% popularity' - ) - ); - } - }]); - - return Popularity; -}(_react2.default.Component); - -exports.default = Popularity; - -/***/ }), -/* 82 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/** - * @copyright 2015, Andrey Popp <8mayday@gmail.com> - * - * The decorator may be used on classes or methods - * ``` - * @autobind - * class FullBound {} - * - * class PartBound { - * @autobind - * method () {} - * } - * ``` - */ - - -Object.defineProperty(exports, '__esModule', { - value: true -}); -exports['default'] = autobind; - -function autobind() { - for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { - args[_key] = arguments[_key]; - } - - if (args.length === 1) { - return boundClass.apply(undefined, args); - } else { - return boundMethod.apply(undefined, args); - } -} - -/** - * Use boundMethod to bind all methods on the target.prototype - */ -function boundClass(target) { - // (Using reflect to get all keys including symbols) - var keys = undefined; - // Use Reflect if exists - if (typeof Reflect !== 'undefined' && typeof Reflect.ownKeys === 'function') { - keys = Reflect.ownKeys(target.prototype); - } else { - keys = Object.getOwnPropertyNames(target.prototype); - // use symbols if support is provided - if (typeof Object.getOwnPropertySymbols === 'function') { - keys = keys.concat(Object.getOwnPropertySymbols(target.prototype)); - } - } - - keys.forEach(function (key) { - // Ignore special case target method - if (key === 'constructor') { + if (Object(__WEBPACK_IMPORTED_MODULE_4_history__["f" /* locationsAreEqual */])(prevTo, nextTo)) { + __WEBPACK_IMPORTED_MODULE_2_warning___default()(false, "You tried to redirect to the same route you're currently on: " + ("\"" + nextTo.pathname + nextTo.search + "\"")); return; } - var descriptor = Object.getOwnPropertyDescriptor(target.prototype, key); - - // Only methods need binding - if (typeof descriptor.value === 'function') { - Object.defineProperty(target.prototype, key, boundMethod(target, key, descriptor)); - } - }); - return target; -} - -/** - * Return a descriptor removing the value and returning a getter - * The getter will return a .bind version of the function - * and memoize the result against a symbol on the instance - */ -function boundMethod(target, key, descriptor) { - var fn = descriptor.value; - - if (typeof fn !== 'function') { - throw new Error('@autobind decorator can only be applied to methods not: ' + typeof fn); - } - - // In IE11 calling Object.defineProperty has a side-effect of evaluating the - // getter for the property which is being replaced. This causes infinite - // recursion and an "Out of stack space" error. - var definingProperty = false; - - return { - configurable: true, - get: function get() { - if (definingProperty || this === target.prototype || this.hasOwnProperty(key)) { - return fn; - } - - var boundFn = fn.bind(this); - definingProperty = true; - Object.defineProperty(this, key, { - value: boundFn, - configurable: true, - writable: true - }); - definingProperty = false; - return boundFn; - } + this.perform(); }; -} -module.exports = exports['default']; + Redirect.prototype.computeTo = function computeTo(_ref) { + var computedMatch = _ref.computedMatch, + to = _ref.to; -/***/ }), -/* 83 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(0); - -var _react2 = _interopRequireDefault(_react); - -var _Link = __webpack_require__(8); - -var _Link2 = _interopRequireDefault(_Link); - -var _Icon = __webpack_require__(5); - -var _Icon2 = _interopRequireDefault(_Icon); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - -var FilterField = function (_React$Component) { - _inherits(FilterField, _React$Component); - - function FilterField(props) { - _classCallCheck(this, FilterField); - - var _this = _possibleConstructorReturn(this, (FilterField.__proto__ || Object.getPrototypeOf(FilterField)).call(this, props)); - - _this.state = { - value: '', - active: _this.props.slim_mode ? true : false - }; - - _this.handleKeyUp = _this.handleKeyUp.bind(_this); - return _this; - } - - _createClass(FilterField, [{ - key: 'componentWillMount', - value: function componentWillMount() { - window.addEventListener("keyup", this.handleKeyUp, false); - this.setState({ value: this.props.initialValue }); - } - }, { - key: 'componentWillUnmount', - value: function componentWillUnmount() { - window.removeEventListener("keyup", this.handleKeyUp, false); - } - }, { - key: 'handleKeyUp', - value: function handleKeyUp(e) { - if (e.keyCode == 27 && !this.props.slim_mode) { - e.preventDefault(); - - this.setState({ - value: '', - active: false - }); - - this.handleChange(''); - } - } - }, { - key: 'activate', - value: function activate() { - this.setState({ active: true }); - } - }, { - key: 'handleChange', - value: function handleChange(value) { - this.setState({ - value: value, - active: this.props.slim_mode ? true : value != '' - }); - this.props.handleChange(value); - } - }, { - key: 'handleBlur', - value: function handleBlur() { - if (this.state.value == '' && !this.props.slim_mode) { - this.setState({ active: false }); - } - } - }, { - key: 'render', - value: function render() { - var _this2 = this; - - return _react2.default.createElement( - 'span', - { className: "filter-field " + (this.state.active ? 'active' : ''), onClick: function onClick(e) { - return _this2.activate(); - } }, - _react2.default.createElement( - 'form', - null, - _react2.default.createElement('input', { - type: 'text', - placeholder: 'Filter', - value: this.state.value, - onFocus: function onFocus(e) { - return _this2.activate(); - }, - onBlur: function onBlur(e) { - return _this2.handleBlur(); - }, - onChange: function onChange(e) { - return _this2.handleChange(e.target.value); - } - }), - _react2.default.createElement(_Icon2.default, { name: 'search', type: 'material' }) - ) - ); - } - }]); - - return FilterField; -}(_react2.default.Component); - -exports.default = FilterField; - -/***/ }), -/* 84 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) { - -if (process.env.NODE_ENV === 'production') { - module.exports = __webpack_require__(121); -} else { - module.exports = __webpack_require__(122); -} - -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(6))) - -/***/ }), -/* 85 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = _inheritsLoose; -function _inheritsLoose(subClass, superClass) { - subClass.prototype = Object.create(superClass.prototype); - subClass.prototype.constructor = subClass; - subClass.__proto__ = superClass; -} - -/***/ }), -/* 86 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/* harmony export (immutable) */ __webpack_exports__["a"] = connectAdvanced; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__babel_runtime_helpers_esm_inheritsLoose__ = __webpack_require__(85); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__babel_runtime_helpers_esm_assertThisInitialized__ = __webpack_require__(134); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__babel_runtime_helpers_esm_extends__ = __webpack_require__(61); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__babel_runtime_helpers_esm_objectWithoutPropertiesLoose__ = __webpack_require__(62); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_hoist_non_react_statics__ = __webpack_require__(135); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_hoist_non_react_statics___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_4_hoist_non_react_statics__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_invariant__ = __webpack_require__(138); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_invariant___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_5_invariant__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_react__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_6_react__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_react_is__ = __webpack_require__(87); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_react_is___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_7_react_is__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__Context__ = __webpack_require__(60); - - - - - - - - - -function connectAdvanced( -/* - selectorFactory is a func that is responsible for returning the selector function used to - compute new props from state, props, and dispatch. For example: - export default connectAdvanced((dispatch, options) => (state, props) => ({ - thing: state.things[props.thingId], - saveThing: fields => dispatch(actionCreators.saveThing(props.thingId, fields)), - }))(YourComponent) - Access to dispatch is provided to the factory so selectorFactories can bind actionCreators - outside of their selector as an optimization. Options passed to connectAdvanced are passed to - the selectorFactory, along with displayName and WrappedComponent, as the second argument. - Note that selectorFactory is responsible for all caching/memoization of inbound and outbound - props. Do not use connectAdvanced directly without memoizing results between calls to your - selector, otherwise the Connect component will re-render on every state or props change. -*/ -selectorFactory, // options object: -_ref) { - if (_ref === void 0) { - _ref = {}; - } - - var _ref2 = _ref, - _ref2$getDisplayName = _ref2.getDisplayName, - getDisplayName = _ref2$getDisplayName === void 0 ? function (name) { - return "ConnectAdvanced(" + name + ")"; - } : _ref2$getDisplayName, - _ref2$methodName = _ref2.methodName, - methodName = _ref2$methodName === void 0 ? 'connectAdvanced' : _ref2$methodName, - _ref2$renderCountProp = _ref2.renderCountProp, - renderCountProp = _ref2$renderCountProp === void 0 ? undefined : _ref2$renderCountProp, - _ref2$shouldHandleSta = _ref2.shouldHandleStateChanges, - shouldHandleStateChanges = _ref2$shouldHandleSta === void 0 ? true : _ref2$shouldHandleSta, - _ref2$storeKey = _ref2.storeKey, - storeKey = _ref2$storeKey === void 0 ? 'store' : _ref2$storeKey, - _ref2$withRef = _ref2.withRef, - withRef = _ref2$withRef === void 0 ? false : _ref2$withRef, - _ref2$forwardRef = _ref2.forwardRef, - forwardRef = _ref2$forwardRef === void 0 ? false : _ref2$forwardRef, - _ref2$context = _ref2.context, - context = _ref2$context === void 0 ? __WEBPACK_IMPORTED_MODULE_8__Context__["a" /* ReactReduxContext */] : _ref2$context, - connectOptions = Object(__WEBPACK_IMPORTED_MODULE_3__babel_runtime_helpers_esm_objectWithoutPropertiesLoose__["a" /* default */])(_ref2, ["getDisplayName", "methodName", "renderCountProp", "shouldHandleStateChanges", "storeKey", "withRef", "forwardRef", "context"]); - - __WEBPACK_IMPORTED_MODULE_5_invariant___default()(renderCountProp === undefined, "renderCountProp is removed. render counting is built into the latest React dev tools profiling extension"); - __WEBPACK_IMPORTED_MODULE_5_invariant___default()(!withRef, 'withRef is removed. To access the wrapped instance, use a ref on the connected component'); - var customStoreWarningMessage = 'To use a custom Redux store for specific components, create a custom React context with ' + "React.createContext(), and pass the context object to React-Redux's Provider and specific components" + ' like: . ' + 'You may also pass a {context : MyContext} option to connect'; - __WEBPACK_IMPORTED_MODULE_5_invariant___default()(storeKey === 'store', 'storeKey has been removed and does not do anything. ' + customStoreWarningMessage); - var Context = context; - return function wrapWithConnect(WrappedComponent) { - if (process.env.NODE_ENV !== 'production') { - __WEBPACK_IMPORTED_MODULE_5_invariant___default()(Object(__WEBPACK_IMPORTED_MODULE_7_react_is__["isValidElementType"])(WrappedComponent), "You must pass a component to the function returned by " + (methodName + ". Instead received " + JSON.stringify(WrappedComponent))); - } - - var wrappedComponentName = WrappedComponent.displayName || WrappedComponent.name || 'Component'; - var displayName = getDisplayName(wrappedComponentName); - - var selectorFactoryOptions = Object(__WEBPACK_IMPORTED_MODULE_2__babel_runtime_helpers_esm_extends__["a" /* default */])({}, connectOptions, { - getDisplayName: getDisplayName, - methodName: methodName, - renderCountProp: renderCountProp, - shouldHandleStateChanges: shouldHandleStateChanges, - storeKey: storeKey, - displayName: displayName, - wrappedComponentName: wrappedComponentName, - WrappedComponent: WrappedComponent - }); - - var pure = connectOptions.pure; - var OuterBaseComponent = __WEBPACK_IMPORTED_MODULE_6_react__["Component"]; - var FinalWrappedComponent = WrappedComponent; - - if (pure) { - OuterBaseComponent = __WEBPACK_IMPORTED_MODULE_6_react__["PureComponent"]; - } - - function makeDerivedPropsSelector() { - var lastProps; - var lastState; - var lastDerivedProps; - var lastStore; - var sourceSelector; - return function selectDerivedProps(state, props, store) { - if (pure && lastProps === props && lastState === state) { - return lastDerivedProps; - } - - if (store !== lastStore) { - lastStore = store; - sourceSelector = selectorFactory(store.dispatch, selectorFactoryOptions); - } - - lastProps = props; - lastState = state; - var nextProps = sourceSelector(state, props); - - if (lastDerivedProps === nextProps) { - return lastDerivedProps; - } - - lastDerivedProps = nextProps; - return lastDerivedProps; - }; - } - - function makeChildElementSelector() { - var lastChildProps, lastForwardRef, lastChildElement; - return function selectChildElement(childProps, forwardRef) { - if (childProps !== lastChildProps || forwardRef !== lastForwardRef) { - lastChildProps = childProps; - lastForwardRef = forwardRef; - lastChildElement = __WEBPACK_IMPORTED_MODULE_6_react___default.a.createElement(FinalWrappedComponent, Object(__WEBPACK_IMPORTED_MODULE_2__babel_runtime_helpers_esm_extends__["a" /* default */])({}, childProps, { - ref: forwardRef - })); - } - - return lastChildElement; - }; - } - - var Connect = - /*#__PURE__*/ - function (_OuterBaseComponent) { - Object(__WEBPACK_IMPORTED_MODULE_0__babel_runtime_helpers_esm_inheritsLoose__["a" /* default */])(Connect, _OuterBaseComponent); - - function Connect(props) { - var _this; - - _this = _OuterBaseComponent.call(this, props) || this; - __WEBPACK_IMPORTED_MODULE_5_invariant___default()(forwardRef ? !props.wrapperProps[storeKey] : !props[storeKey], 'Passing redux store in props has been removed and does not do anything. ' + customStoreWarningMessage); - _this.selectDerivedProps = makeDerivedPropsSelector(); - _this.selectChildElement = makeChildElementSelector(); - _this.renderWrappedComponent = _this.renderWrappedComponent.bind(Object(__WEBPACK_IMPORTED_MODULE_1__babel_runtime_helpers_esm_assertThisInitialized__["a" /* default */])(Object(__WEBPACK_IMPORTED_MODULE_1__babel_runtime_helpers_esm_assertThisInitialized__["a" /* default */])(_this))); - return _this; - } - - var _proto = Connect.prototype; - - _proto.renderWrappedComponent = function renderWrappedComponent(value) { - __WEBPACK_IMPORTED_MODULE_5_invariant___default()(value, "Could not find \"store\" in the context of " + ("\"" + displayName + "\". Either wrap the root component in a , ") + "or pass a custom React context provider to and the corresponding " + ("React context consumer to " + displayName + " in connect options.")); - var storeState = value.storeState, - store = value.store; - var wrapperProps = this.props; - var forwardedRef; - - if (forwardRef) { - wrapperProps = this.props.wrapperProps; - forwardedRef = this.props.forwardedRef; - } - - var derivedProps = this.selectDerivedProps(storeState, wrapperProps, store); - return this.selectChildElement(derivedProps, forwardedRef); - }; - - _proto.render = function render() { - var ContextToUse = this.props.context || Context; - return __WEBPACK_IMPORTED_MODULE_6_react___default.a.createElement(ContextToUse.Consumer, null, this.renderWrappedComponent); - }; - - return Connect; - }(OuterBaseComponent); - - Connect.WrappedComponent = WrappedComponent; - Connect.displayName = displayName; - - if (forwardRef) { - var forwarded = __WEBPACK_IMPORTED_MODULE_6_react___default.a.forwardRef(function forwardConnectRef(props, ref) { - return __WEBPACK_IMPORTED_MODULE_6_react___default.a.createElement(Connect, { - wrapperProps: props, - forwardedRef: ref + if (computedMatch) { + if (typeof to === "string") { + return Object(__WEBPACK_IMPORTED_MODULE_5__generatePath__["a" /* default */])(to, computedMatch.params); + } else { + return _extends({}, to, { + pathname: Object(__WEBPACK_IMPORTED_MODULE_5__generatePath__["a" /* default */])(to.pathname, computedMatch.params) }); - }); - forwarded.displayName = displayName; - forwarded.WrappedComponent = WrappedComponent; - return __WEBPACK_IMPORTED_MODULE_4_hoist_non_react_statics___default()(forwarded, WrappedComponent); - } - - return __WEBPACK_IMPORTED_MODULE_4_hoist_non_react_statics___default()(Connect, WrappedComponent); - }; -} -/* WEBPACK VAR INJECTION */}.call(__webpack_exports__, __webpack_require__(6))) - -/***/ }), -/* 87 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) { - -if (process.env.NODE_ENV === 'production') { - module.exports = __webpack_require__(136); -} else { - module.exports = __webpack_require__(137); -} - -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(6))) - -/***/ }), -/* 88 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/* harmony export (immutable) */ __webpack_exports__["a"] = wrapMapToPropsConstant; -/* unused harmony export getDependsOnOwnProps */ -/* harmony export (immutable) */ __webpack_exports__["b"] = wrapMapToPropsFunc; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__utils_verifyPlainObject__ = __webpack_require__(89); - -function wrapMapToPropsConstant(getConstant) { - return function initConstantSelector(dispatch, options) { - var constant = getConstant(dispatch, options); - - function constantSelector() { - return constant; - } - - constantSelector.dependsOnOwnProps = false; - return constantSelector; - }; -} // dependsOnOwnProps is used by createMapToPropsProxy to determine whether to pass props as args -// to the mapToProps function being wrapped. It is also used by makePurePropsSelector to determine -// whether mapToProps needs to be invoked when props have changed. -// -// A length of one signals that mapToProps does not depend on props from the parent component. -// A length of zero is assumed to mean mapToProps is getting args via arguments or ...args and -// therefore not reporting its length accurately.. - -function getDependsOnOwnProps(mapToProps) { - return mapToProps.dependsOnOwnProps !== null && mapToProps.dependsOnOwnProps !== undefined ? Boolean(mapToProps.dependsOnOwnProps) : mapToProps.length !== 1; -} // Used by whenMapStateToPropsIsFunction and whenMapDispatchToPropsIsFunction, -// this function wraps mapToProps in a proxy function which does several things: -// -// * Detects whether the mapToProps function being called depends on props, which -// is used by selectorFactory to decide if it should reinvoke on props changes. -// -// * On first call, handles mapToProps if returns another function, and treats that -// new function as the true mapToProps for subsequent calls. -// -// * On first call, verifies the first result is a plain object, in order to warn -// the developer that their mapToProps function is not returning a valid result. -// - -function wrapMapToPropsFunc(mapToProps, methodName) { - return function initProxySelector(dispatch, _ref) { - var displayName = _ref.displayName; - - var proxy = function mapToPropsProxy(stateOrDispatch, ownProps) { - return proxy.dependsOnOwnProps ? proxy.mapToProps(stateOrDispatch, ownProps) : proxy.mapToProps(stateOrDispatch); - }; // allow detectFactoryAndVerify to get ownProps - - - proxy.dependsOnOwnProps = true; - - proxy.mapToProps = function detectFactoryAndVerify(stateOrDispatch, ownProps) { - proxy.mapToProps = mapToProps; - proxy.dependsOnOwnProps = getDependsOnOwnProps(mapToProps); - var props = proxy(stateOrDispatch, ownProps); - - if (typeof props === 'function') { - proxy.mapToProps = props; - proxy.dependsOnOwnProps = getDependsOnOwnProps(props); - props = proxy(stateOrDispatch, ownProps); } - - if (process.env.NODE_ENV !== 'production') Object(__WEBPACK_IMPORTED_MODULE_0__utils_verifyPlainObject__["a" /* default */])(props, displayName, methodName); - return props; - }; - - return proxy; - }; -} -/* WEBPACK VAR INJECTION */}.call(__webpack_exports__, __webpack_require__(6))) - -/***/ }), -/* 89 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = verifyPlainObject; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__isPlainObject__ = __webpack_require__(145); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__warning__ = __webpack_require__(90); - - -function verifyPlainObject(value, displayName, methodName) { - if (!Object(__WEBPACK_IMPORTED_MODULE_0__isPlainObject__["a" /* default */])(value)) { - Object(__WEBPACK_IMPORTED_MODULE_1__warning__["a" /* default */])(methodName + "() in " + displayName + " must return a plain object. Instead received " + value + "."); - } -} - -/***/ }), -/* 90 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = warning; -/** - * Prints a warning in the console if it exists. - * - * @param {String} message The warning message. - * @returns {void} - */ -function warning(message) { - /* eslint-disable no-console */ - if (typeof console !== 'undefined' && typeof console.error === 'function') { - console.error(message); - } - /* eslint-enable no-console */ - - - try { - // This error was thrown as a convenience so that if you enable - // "break on all exceptions" in your console, - // it would pause the execution at this line. - throw new Error(message); - /* eslint-disable no-empty */ - } catch (e) {} - /* eslint-enable no-empty */ - -} - -/***/ }), -/* 91 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -function isAbsolute(pathname) { - return pathname.charAt(0) === '/'; -} - -// About 1.5x faster than the two-arg version of Array#splice() -function spliceOne(list, index) { - for (var i = index, k = i + 1, n = list.length; k < n; i += 1, k += 1) { - list[i] = list[k]; - } - - list.pop(); -} - -// This implementation is based heavily on node's url.parse -function resolvePathname(to) { - var from = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : ''; - - var toParts = to && to.split('/') || []; - var fromParts = from && from.split('/') || []; - - var isToAbs = to && isAbsolute(to); - var isFromAbs = from && isAbsolute(from); - var mustEndAbs = isToAbs || isFromAbs; - - if (to && isAbsolute(to)) { - // to is absolute - fromParts = toParts; - } else if (toParts.length) { - // to is relative, drop the filename - fromParts.pop(); - fromParts = fromParts.concat(toParts); - } - - if (!fromParts.length) return '/'; - - var hasTrailingSlash = void 0; - if (fromParts.length) { - var last = fromParts[fromParts.length - 1]; - hasTrailingSlash = last === '.' || last === '..' || last === ''; - } else { - hasTrailingSlash = false; - } - - var up = 0; - for (var i = fromParts.length; i >= 0; i--) { - var part = fromParts[i]; - - if (part === '.') { - spliceOne(fromParts, i); - } else if (part === '..') { - spliceOne(fromParts, i); - up++; - } else if (up) { - spliceOne(fromParts, i); - up--; } - } - if (!mustEndAbs) for (; up--; up) { - fromParts.unshift('..'); - }if (mustEndAbs && fromParts[0] !== '' && (!fromParts[0] || !isAbsolute(fromParts[0]))) fromParts.unshift(''); + return to; + }; - var result = fromParts.join('/'); + Redirect.prototype.perform = function perform() { + var history = this.context.router.history; + var push = this.props.push; - if (hasTrailingSlash && result.substr(-1) !== '/') result += '/'; + var to = this.computeTo(this.props); - return result; -} + if (push) { + history.push(to); + } else { + history.replace(to); + } + }; -/* harmony default export */ __webpack_exports__["a"] = (resolvePathname); + Redirect.prototype.render = function render() { + return null; + }; + + return Redirect; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); + +Redirect.propTypes = { + computedMatch: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, // private, from + push: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + from: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + to: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object]).isRequired +}; +Redirect.defaultProps = { + push: false +}; +Redirect.contextTypes = { + router: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ + history: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ + push: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func.isRequired, + replace: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func.isRequired + }).isRequired, + staticContext: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object + }).isRequired +}; + + +/* harmony default export */ __webpack_exports__["a"] = (Redirect); /***/ }), -/* 92 */ +/* 79 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; -var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; - -function valueEqual(a, b) { - if (a === b) return true; - - if (a == null || b == null) return false; - - if (Array.isArray(a)) { - return Array.isArray(b) && a.length === b.length && a.every(function (item, index) { - return valueEqual(item, b[index]); - }); - } - - var aType = typeof a === 'undefined' ? 'undefined' : _typeof(a); - var bType = typeof b === 'undefined' ? 'undefined' : _typeof(b); - - if (aType !== bType) return false; - - if (aType === 'object') { - var aValue = a.valueOf(); - var bValue = b.valueOf(); - - if (aValue !== a || bValue !== b) return valueEqual(aValue, bValue); - - var aKeys = Object.keys(a); - var bKeys = Object.keys(b); - - if (aKeys.length !== bKeys.length) return false; - - return aKeys.every(function (key) { - return valueEqual(a[key], b[key]); - }); - } - - return false; -} - -/* harmony default export */ __webpack_exports__["a"] = (valueEqual); - -/***/ }), -/* 93 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return canUseDOM; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return addEventListener; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "e", function() { return removeEventListener; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return getConfirmation; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "g", function() { return supportsHistory; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "h", function() { return supportsPopStateOnHashChange; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "f", function() { return supportsGoWithoutReloadUsingHash; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "d", function() { return isExtraneousPopstateEvent; }); -var canUseDOM = !!(typeof window !== 'undefined' && window.document && window.document.createElement); - -var addEventListener = function addEventListener(node, event, listener) { - return node.addEventListener ? node.addEventListener(event, listener, false) : node.attachEvent('on' + event, listener); -}; - -var removeEventListener = function removeEventListener(node, event, listener) { - return node.removeEventListener ? node.removeEventListener(event, listener, false) : node.detachEvent('on' + event, listener); -}; - -var getConfirmation = function getConfirmation(message, callback) { - return callback(window.confirm(message)); -}; // eslint-disable-line no-alert - -/** - * Returns true if the HTML5 history API is supported. Taken from Modernizr. - * - * https://github.com/Modernizr/Modernizr/blob/master/LICENSE - * https://github.com/Modernizr/Modernizr/blob/master/feature-detects/history.js - * changed to avoid false negatives for Windows Phones: https://github.com/reactjs/react-router/issues/586 - */ -var supportsHistory = function supportsHistory() { - var ua = window.navigator.userAgent; - - if ((ua.indexOf('Android 2.') !== -1 || ua.indexOf('Android 4.0') !== -1) && ua.indexOf('Mobile Safari') !== -1 && ua.indexOf('Chrome') === -1 && ua.indexOf('Windows Phone') === -1) return false; - - return window.history && 'pushState' in window.history; -}; - -/** - * Returns true if browser fires popstate on hash change. - * IE10 and IE11 do not. - */ -var supportsPopStateOnHashChange = function supportsPopStateOnHashChange() { - return window.navigator.userAgent.indexOf('Trident') === -1; -}; - -/** - * Returns false if using go(n) with hash history causes a full page reload. - */ -var supportsGoWithoutReloadUsingHash = function supportsGoWithoutReloadUsingHash() { - return window.navigator.userAgent.indexOf('Firefox') === -1; -}; - -/** - * Returns true if a given popstate event is an extraneous WebKit event. - * Accounts for the fact that Chrome on iOS fires real popstate events - * containing undefined state when pressing the back button. - */ -var isExtraneousPopstateEvent = function isExtraneousPopstateEvent(event) { - return event.state === undefined && navigator.userAgent.indexOf('CriOS') === -1; -}; - -/***/ }), -/* 94 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_react__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_prop_types__ = __webpack_require__(20); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_prop_types___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_prop_types__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_invariant__ = __webpack_require__(25); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_invariant___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_invariant__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_history__ = __webpack_require__(35); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_warning__ = __webpack_require__(28); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_warning___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_warning__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_invariant__ = __webpack_require__(27); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_invariant___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_invariant__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_react__ = __webpack_require__(0); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_react__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_prop_types__ = __webpack_require__(12); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_prop_types___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3_prop_types__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_history__ = __webpack_require__(32); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__Router__ = __webpack_require__(46); var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; } @@ -24975,123 +25256,156 @@ function _inherits(subClass, superClass) { if (typeof superClass !== "function" -var isModifiedEvent = function isModifiedEvent(event) { - return !!(event.metaKey || event.altKey || event.ctrlKey || event.shiftKey); + + +var addLeadingSlash = function addLeadingSlash(path) { + return path.charAt(0) === "/" ? path : "/" + path; }; +var addBasename = function addBasename(basename, location) { + if (!basename) return location; + + return _extends({}, location, { + pathname: addLeadingSlash(basename) + location.pathname + }); +}; + +var stripBasename = function stripBasename(basename, location) { + if (!basename) return location; + + var base = addLeadingSlash(basename); + + if (location.pathname.indexOf(base) !== 0) return location; + + return _extends({}, location, { + pathname: location.pathname.substr(base.length) + }); +}; + +var createURL = function createURL(location) { + return typeof location === "string" ? location : Object(__WEBPACK_IMPORTED_MODULE_4_history__["e" /* createPath */])(location); +}; + +var staticHandler = function staticHandler(methodName) { + return function () { + __WEBPACK_IMPORTED_MODULE_1_invariant___default()(false, "You cannot %s with ", methodName); + }; +}; + +var noop = function noop() {}; + /** - * The public API for rendering a history-aware . + * The public top-level API for a "static" , so-called because it + * can't actually change the current location. Instead, it just records + * location changes in a context object. Useful mainly in testing and + * server-rendering scenarios. */ -var Link = function (_React$Component) { - _inherits(Link, _React$Component); +var StaticRouter = function (_React$Component) { + _inherits(StaticRouter, _React$Component); - function Link() { + function StaticRouter() { var _temp, _this, _ret; - _classCallCheck(this, Link); + _classCallCheck(this, StaticRouter); for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { args[_key] = arguments[_key]; } - return _ret = (_temp = (_this = _possibleConstructorReturn(this, _React$Component.call.apply(_React$Component, [this].concat(args))), _this), _this.handleClick = function (event) { - if (_this.props.onClick) _this.props.onClick(event); + return _ret = (_temp = (_this = _possibleConstructorReturn(this, _React$Component.call.apply(_React$Component, [this].concat(args))), _this), _this.createHref = function (path) { + return addLeadingSlash(_this.props.basename + createURL(path)); + }, _this.handlePush = function (location) { + var _this$props = _this.props, + basename = _this$props.basename, + context = _this$props.context; - if (!event.defaultPrevented && // onClick prevented default - event.button === 0 && // ignore everything but left clicks - !_this.props.target && // let browser handle "target=_blank" etc. - !isModifiedEvent(event) // ignore clicks with modifier keys - ) { - event.preventDefault(); + context.action = "PUSH"; + context.location = addBasename(basename, Object(__WEBPACK_IMPORTED_MODULE_4_history__["c" /* createLocation */])(location)); + context.url = createURL(context.location); + }, _this.handleReplace = function (location) { + var _this$props2 = _this.props, + basename = _this$props2.basename, + context = _this$props2.context; - var history = _this.context.router.history; - var _this$props = _this.props, - replace = _this$props.replace, - to = _this$props.to; - - - if (replace) { - history.replace(to); - } else { - history.push(to); - } - } + context.action = "REPLACE"; + context.location = addBasename(basename, Object(__WEBPACK_IMPORTED_MODULE_4_history__["c" /* createLocation */])(location)); + context.url = createURL(context.location); + }, _this.handleListen = function () { + return noop; + }, _this.handleBlock = function () { + return noop; }, _temp), _possibleConstructorReturn(_this, _ret); } - Link.prototype.render = function render() { - var _props = this.props, - replace = _props.replace, - to = _props.to, - innerRef = _props.innerRef, - props = _objectWithoutProperties(_props, ["replace", "to", "innerRef"]); // eslint-disable-line no-unused-vars - - __WEBPACK_IMPORTED_MODULE_2_invariant___default()(this.context.router, "You should not use outside a "); - - __WEBPACK_IMPORTED_MODULE_2_invariant___default()(to !== undefined, 'You must specify the "to" property'); - - var history = this.context.router.history; - - var location = typeof to === "string" ? Object(__WEBPACK_IMPORTED_MODULE_3_history__["c" /* createLocation */])(to, null, null, history.location) : to; - - var href = history.createHref(location); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement("a", _extends({}, props, { onClick: this.handleClick, href: href, ref: innerRef })); + StaticRouter.prototype.getChildContext = function getChildContext() { + return { + router: { + staticContext: this.props.context + } + }; }; - return Link; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); + StaticRouter.prototype.componentWillMount = function componentWillMount() { + __WEBPACK_IMPORTED_MODULE_0_warning___default()(!this.props.history, " ignores the history prop. To use a custom history, " + "use `import { Router }` instead of `import { StaticRouter as Router }`."); + }; -Link.propTypes = { - onClick: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - target: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - replace: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - to: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object]).isRequired, - innerRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func]) + StaticRouter.prototype.render = function render() { + var _props = this.props, + basename = _props.basename, + context = _props.context, + location = _props.location, + props = _objectWithoutProperties(_props, ["basename", "context", "location"]); + + var history = { + createHref: this.createHref, + action: "POP", + location: stripBasename(basename, Object(__WEBPACK_IMPORTED_MODULE_4_history__["c" /* createLocation */])(location)), + push: this.handlePush, + replace: this.handleReplace, + go: staticHandler("go"), + goBack: staticHandler("goBack"), + goForward: staticHandler("goForward"), + listen: this.handleListen, + block: this.handleBlock + }; + + return __WEBPACK_IMPORTED_MODULE_2_react___default.a.createElement(__WEBPACK_IMPORTED_MODULE_5__Router__["a" /* default */], _extends({}, props, { history: history })); + }; + + return StaticRouter; +}(__WEBPACK_IMPORTED_MODULE_2_react___default.a.Component); + +StaticRouter.propTypes = { + basename: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.string, + context: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object.isRequired, + location: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object]) }; -Link.defaultProps = { - replace: false +StaticRouter.defaultProps = { + basename: "", + location: "/" }; -Link.contextTypes = { - router: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ - history: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ - push: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func.isRequired, - replace: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func.isRequired, - createHref: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func.isRequired - }).isRequired - }).isRequired +StaticRouter.childContextTypes = { + router: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object.isRequired }; -/* harmony default export */ __webpack_exports__["a"] = (Link); +/* harmony default export */ __webpack_exports__["a"] = (StaticRouter); /***/ }), -/* 95 */ +/* 80 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react_router_es_Route__ = __webpack_require__(96); -// Written in this round about way for babel-transform-imports - - -/* harmony default export */ __webpack_exports__["a"] = (__WEBPACK_IMPORTED_MODULE_0_react_router_es_Route__["a" /* default */]); - -/***/ }), -/* 96 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_warning__ = __webpack_require__(28); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_warning___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_warning__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_invariant__ = __webpack_require__(25); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_invariant___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_invariant__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_react__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_react__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_prop_types__ = __webpack_require__(20); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_prop_types___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3_prop_types__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__matchPath__ = __webpack_require__(67); -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; - +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react__ = __webpack_require__(0); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_react__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_prop_types__ = __webpack_require__(12); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_prop_types___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_prop_types__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_warning__ = __webpack_require__(28); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_warning___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_warning__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_invariant__ = __webpack_require__(27); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_invariant___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3_invariant__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__matchPath__ = __webpack_require__(47); function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } @@ -25104,179 +25418,123 @@ function _inherits(subClass, superClass) { if (typeof superClass !== "function" -var isEmptyChildren = function isEmptyChildren(children) { - return __WEBPACK_IMPORTED_MODULE_2_react___default.a.Children.count(children) === 0; -}; - /** - * The public API for matching a single path and rendering. + * The public API for rendering the first that matches. */ -var Route = function (_React$Component) { - _inherits(Route, _React$Component); +var Switch = function (_React$Component) { + _inherits(Switch, _React$Component); - function Route() { - var _temp, _this, _ret; + function Switch() { + _classCallCheck(this, Switch); - _classCallCheck(this, Route); - - for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { - args[_key] = arguments[_key]; - } - - return _ret = (_temp = (_this = _possibleConstructorReturn(this, _React$Component.call.apply(_React$Component, [this].concat(args))), _this), _this.state = { - match: _this.computeMatch(_this.props, _this.context.router) - }, _temp), _possibleConstructorReturn(_this, _ret); + return _possibleConstructorReturn(this, _React$Component.apply(this, arguments)); } - Route.prototype.getChildContext = function getChildContext() { - return { - router: _extends({}, this.context.router, { - route: { - location: this.props.location || this.context.router.route.location, - match: this.state.match - } - }) - }; + Switch.prototype.componentWillMount = function componentWillMount() { + __WEBPACK_IMPORTED_MODULE_3_invariant___default()(this.context.router, "You should not use outside a "); }; - Route.prototype.computeMatch = function computeMatch(_ref, router) { - var computedMatch = _ref.computedMatch, - location = _ref.location, - path = _ref.path, - strict = _ref.strict, - exact = _ref.exact, - sensitive = _ref.sensitive; + Switch.prototype.componentWillReceiveProps = function componentWillReceiveProps(nextProps) { + __WEBPACK_IMPORTED_MODULE_2_warning___default()(!(nextProps.location && !this.props.location), ' elements should not change from uncontrolled to controlled (or vice versa). You initially used no "location" prop and then provided one on a subsequent render.'); - if (computedMatch) return computedMatch; // already computed the match for us - - __WEBPACK_IMPORTED_MODULE_1_invariant___default()(router, "You should not use or withRouter() outside a "); - - var route = router.route; - - var pathname = (location || route.location).pathname; - - return Object(__WEBPACK_IMPORTED_MODULE_4__matchPath__["a" /* default */])(pathname, { path: path, strict: strict, exact: exact, sensitive: sensitive }, route.match); + __WEBPACK_IMPORTED_MODULE_2_warning___default()(!(!nextProps.location && this.props.location), ' elements should not change from controlled to uncontrolled (or vice versa). You provided a "location" prop initially but omitted it on a subsequent render.'); }; - Route.prototype.componentWillMount = function componentWillMount() { - __WEBPACK_IMPORTED_MODULE_0_warning___default()(!(this.props.component && this.props.render), "You should not use and in the same route; will be ignored"); - - __WEBPACK_IMPORTED_MODULE_0_warning___default()(!(this.props.component && this.props.children && !isEmptyChildren(this.props.children)), "You should not use and in the same route; will be ignored"); - - __WEBPACK_IMPORTED_MODULE_0_warning___default()(!(this.props.render && this.props.children && !isEmptyChildren(this.props.children)), "You should not use and in the same route; will be ignored"); - }; - - Route.prototype.componentWillReceiveProps = function componentWillReceiveProps(nextProps, nextContext) { - __WEBPACK_IMPORTED_MODULE_0_warning___default()(!(nextProps.location && !this.props.location), ' elements should not change from uncontrolled to controlled (or vice versa). You initially used no "location" prop and then provided one on a subsequent render.'); - - __WEBPACK_IMPORTED_MODULE_0_warning___default()(!(!nextProps.location && this.props.location), ' elements should not change from controlled to uncontrolled (or vice versa). You provided a "location" prop initially but omitted it on a subsequent render.'); - - this.setState({ - match: this.computeMatch(nextProps, nextContext.router) - }); - }; - - Route.prototype.render = function render() { - var match = this.state.match; - var _props = this.props, - children = _props.children, - component = _props.component, - render = _props.render; - var _context$router = this.context.router, - history = _context$router.history, - route = _context$router.route, - staticContext = _context$router.staticContext; + Switch.prototype.render = function render() { + var route = this.context.router.route; + var children = this.props.children; var location = this.props.location || route.location; - var props = { match: match, location: location, history: history, staticContext: staticContext }; - if (component) return match ? __WEBPACK_IMPORTED_MODULE_2_react___default.a.createElement(component, props) : null; + var match = void 0, + child = void 0; + __WEBPACK_IMPORTED_MODULE_0_react___default.a.Children.forEach(children, function (element) { + if (match == null && __WEBPACK_IMPORTED_MODULE_0_react___default.a.isValidElement(element)) { + var _element$props = element.props, + pathProp = _element$props.path, + exact = _element$props.exact, + strict = _element$props.strict, + sensitive = _element$props.sensitive, + from = _element$props.from; - if (render) return match ? render(props) : null; + var path = pathProp || from; - if (typeof children === "function") return children(props); + child = element; + match = Object(__WEBPACK_IMPORTED_MODULE_4__matchPath__["a" /* default */])(location.pathname, { path: path, exact: exact, strict: strict, sensitive: sensitive }, route.match); + } + }); - if (children && !isEmptyChildren(children)) return __WEBPACK_IMPORTED_MODULE_2_react___default.a.Children.only(children); - - return null; + return match ? __WEBPACK_IMPORTED_MODULE_0_react___default.a.cloneElement(child, { location: location, computedMatch: match }) : null; }; - return Route; -}(__WEBPACK_IMPORTED_MODULE_2_react___default.a.Component); + return Switch; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); -Route.propTypes = { - computedMatch: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object, // private, from - path: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.string, - exact: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.bool, - strict: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.bool, - sensitive: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.bool, - component: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.func, - render: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.func, - children: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.node]), - location: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object +Switch.contextTypes = { + router: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ + route: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object.isRequired + }).isRequired }; -Route.contextTypes = { - router: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.shape({ - history: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object.isRequired, - route: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object.isRequired, - staticContext: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object - }) -}; -Route.childContextTypes = { - router: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object.isRequired +Switch.propTypes = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + location: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object }; -/* harmony default export */ __webpack_exports__["a"] = (Route); +/* harmony default export */ __webpack_exports__["a"] = (Switch); /***/ }), -/* 97 */ +/* 81 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_path_to_regexp__ = __webpack_require__(52); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_path_to_regexp___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_path_to_regexp__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react__ = __webpack_require__(0); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_react__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_prop_types__ = __webpack_require__(12); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_prop_types___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_prop_types__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_hoist_non_react_statics__ = __webpack_require__(138); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_hoist_non_react_statics___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_hoist_non_react_statics__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__Route__ = __webpack_require__(57); +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + +function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; } -var patternCache = {}; -var cacheLimit = 10000; -var cacheCount = 0; -var compileGenerator = function compileGenerator(pattern) { - var cacheKey = pattern; - var cache = patternCache[cacheKey] || (patternCache[cacheKey] = {}); - if (cache[pattern]) return cache[pattern]; - var compiledGenerator = __WEBPACK_IMPORTED_MODULE_0_path_to_regexp___default.a.compile(pattern); - - if (cacheCount < cacheLimit) { - cache[pattern] = compiledGenerator; - cacheCount++; - } - - return compiledGenerator; -}; /** - * Public API for generating a URL pathname from a pattern and parameters. + * A public higher-order component to access the imperative API */ -var generatePath = function generatePath() { - var pattern = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : "/"; - var params = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}; +var withRouter = function withRouter(Component) { + var C = function C(props) { + var wrappedComponentRef = props.wrappedComponentRef, + remainingProps = _objectWithoutProperties(props, ["wrappedComponentRef"]); - if (pattern === "/") { - return pattern; - } - var generator = compileGenerator(pattern); - return generator(params, { pretty: true }); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(__WEBPACK_IMPORTED_MODULE_3__Route__["a" /* default */], { + children: function children(routeComponentProps) { + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Component, _extends({}, remainingProps, routeComponentProps, { + ref: wrappedComponentRef + })); + } + }); + }; + + C.displayName = "withRouter(" + (Component.displayName || Component.name) + ")"; + C.WrappedComponent = Component; + C.propTypes = { + wrappedComponentRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func + }; + + return __WEBPACK_IMPORTED_MODULE_2_hoist_non_react_statics___default()(C, Component); }; -/* harmony default export */ __webpack_exports__["a"] = (generatePath); +/* harmony default export */ __webpack_exports__["a"] = (withRouter); /***/ }), -/* 98 */ +/* 82 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; @@ -25288,78 +25546,7 @@ function trim(s) { } /***/ }), -/* 99 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-2015, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - - - -var emptyFunction = __webpack_require__(69); - -/** - * Similar to invariant but only logs a warning if the condition is not met. - * This can be used to log issues in development environments in critical - * paths. Removing the logging code for production environments will keep the - * same logic and follow the same code paths. - */ - -var warning = emptyFunction; - -if (process.env.NODE_ENV !== 'production') { - var printWarning = function printWarning(format) { - for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) { - args[_key - 1] = arguments[_key]; - } - - var argIndex = 0; - var message = 'Warning: ' + format.replace(/%s/g, function () { - return args[argIndex++]; - }); - if (typeof console !== 'undefined') { - console.error(message); - } - try { - // --- Welcome to debugging React --- - // This error was thrown as a convenience so that you can use this stack - // to find the callsite that caused this warning to fire. - throw new Error(message); - } catch (x) {} - }; - - warning = function warning(condition, format) { - if (format === undefined) { - throw new Error('`warning(condition, format, ...args)` requires a warning ' + 'message argument'); - } - - if (format.indexOf('Failed Composite propType: ') === 0) { - return; // Ignore CompositeComponent proptype check. - } - - if (!condition) { - for (var _len2 = arguments.length, args = Array(_len2 > 2 ? _len2 - 2 : 0), _key2 = 2; _key2 < _len2; _key2++) { - args[_key2 - 2] = arguments[_key2]; - } - - printWarning.apply(undefined, [format].concat(args)); - } - }; -} - -module.exports = warning; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(6))) - -/***/ }), -/* 100 */ +/* 83 */ /***/ (function(module, exports) { /* WEBPACK VAR INJECTION */(function(__webpack_amd_options__) {/* globals __webpack_amd_options__ */ @@ -25368,7 +25555,7 @@ module.exports = __webpack_amd_options__; /* WEBPACK VAR INJECTION */}.call(exports, {})) /***/ }), -/* 101 */ +/* 84 */ /***/ (function(module, exports, __webpack_require__) { var __WEBPACK_AMD_DEFINE_RESULT__;/** @license MIT License (c) copyright 2010-2014 original author or authors */ @@ -25398,10 +25585,10 @@ var __WEBPACK_AMD_DEFINE_RESULT__;/** @license MIT License (c) copyright 2010-20 return TimeoutError; }).call(exports, __webpack_require__, exports, module), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); -}(__webpack_require__(15))); +}(__webpack_require__(16))); /***/ }), -/* 102 */ +/* 85 */ /***/ (function(module, exports, __webpack_require__) { var __WEBPACK_AMD_DEFINE_RESULT__;/** @license MIT License (c) copyright 2010-2014 original author or authors */ @@ -25439,11 +25626,11 @@ var __WEBPACK_AMD_DEFINE_RESULT__;/** @license MIT License (c) copyright 2010-20 }).call(exports, __webpack_require__, exports, module), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); -}(__webpack_require__(15))); +}(__webpack_require__(16))); /***/ }), -/* 103 */ +/* 86 */ /***/ (function(module, exports, __webpack_require__) { var __WEBPACK_AMD_DEFINE_RESULT__;/** @license MIT License (c) copyright 2010-2014 original author or authors */ @@ -25499,13 +25686,13 @@ var __WEBPACK_AMD_DEFINE_RESULT__;/** @license MIT License (c) copyright 2010-20 }).call(exports, __webpack_require__, exports, module), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); -}(__webpack_require__(15))); +}(__webpack_require__(16))); /***/ }), -/* 104 */ +/* 87 */ /***/ (function(module, exports, __webpack_require__) { /* WEBPACK VAR INJECTION */(function(process, global) {var __WEBPACK_AMD_DEFINE_RESULT__;/** @@ -25534,7 +25721,7 @@ var __WEBPACK_AMD_DEFINE_RESULT__;/** @license MIT License (c) copyright 2010-20 root = self; } var COMMON_JS = !root.JS_SHA256_NO_COMMON_JS && typeof module === 'object' && module.exports; - var AMD = "function" === 'function' && __webpack_require__(100); + var AMD = "function" === 'function' && __webpack_require__(83); var ARRAY_BUFFER = !root.JS_SHA256_NO_ARRAY_BUFFER && typeof ArrayBuffer !== 'undefined'; var HEX_CHARS = '0123456789abcdef'.split(''); var EXTRA = [-2147483648, 8388608, 32768, 128]; @@ -26028,334 +26215,10 @@ var __WEBPACK_AMD_DEFINE_RESULT__;/** @license MIT License (c) copyright 2010-20 } })(); -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(6), __webpack_require__(49))) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(10), __webpack_require__(43))) /***/ }), -/* 105 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-2015, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - */ - - - -/** - * Use invariant() to assert state which your program assumes to be true. - * - * Provide sprintf-style format (only %s is supported) and arguments - * to provide information about what broke and what you were - * expecting. - * - * The invariant message will be stripped in production, but the invariant - * will remain to ensure logic does not differ in production. - */ - -var invariant = function(condition, format, a, b, c, d, e, f) { - if (process.env.NODE_ENV !== 'production') { - if (format === undefined) { - throw new Error('invariant requires an error message argument'); - } - } - - if (!condition) { - var error; - if (format === undefined) { - error = new Error( - 'Minified exception occurred; use the non-minified dev environment ' + - 'for the full error message and additional helpful warnings.' - ); - } else { - var args = [a, b, c, d, e, f]; - var argIndex = 0; - error = new Error( - format.replace(/%s/g, function() { return args[argIndex++]; }) - ); - error.name = 'Invariant Violation'; - } - - error.framesToPop = 1; // we don't care about invariant's own frame - throw error; - } -}; - -module.exports = invariant; - -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(6))) - -/***/ }), -/* 106 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return canUseDOM; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return addEventListener; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "e", function() { return removeEventListener; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return getConfirmation; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "g", function() { return supportsHistory; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "h", function() { return supportsPopStateOnHashChange; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "f", function() { return supportsGoWithoutReloadUsingHash; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "d", function() { return isExtraneousPopstateEvent; }); -var canUseDOM = !!(typeof window !== 'undefined' && window.document && window.document.createElement); - -var addEventListener = function addEventListener(node, event, listener) { - return node.addEventListener ? node.addEventListener(event, listener, false) : node.attachEvent('on' + event, listener); -}; - -var removeEventListener = function removeEventListener(node, event, listener) { - return node.removeEventListener ? node.removeEventListener(event, listener, false) : node.detachEvent('on' + event, listener); -}; - -var getConfirmation = function getConfirmation(message, callback) { - return callback(window.confirm(message)); -}; // eslint-disable-line no-alert - -/** - * Returns true if the HTML5 history API is supported. Taken from Modernizr. - * - * https://github.com/Modernizr/Modernizr/blob/master/LICENSE - * https://github.com/Modernizr/Modernizr/blob/master/feature-detects/history.js - * changed to avoid false negatives for Windows Phones: https://github.com/reactjs/react-router/issues/586 - */ -var supportsHistory = function supportsHistory() { - var ua = window.navigator.userAgent; - - if ((ua.indexOf('Android 2.') !== -1 || ua.indexOf('Android 4.0') !== -1) && ua.indexOf('Mobile Safari') !== -1 && ua.indexOf('Chrome') === -1 && ua.indexOf('Windows Phone') === -1) return false; - - return window.history && 'pushState' in window.history; -}; - -/** - * Returns true if browser fires popstate on hash change. - * IE10 and IE11 do not. - */ -var supportsPopStateOnHashChange = function supportsPopStateOnHashChange() { - return window.navigator.userAgent.indexOf('Trident') === -1; -}; - -/** - * Returns false if using go(n) with hash history causes a full page reload. - */ -var supportsGoWithoutReloadUsingHash = function supportsGoWithoutReloadUsingHash() { - return window.navigator.userAgent.indexOf('Firefox') === -1; -}; - -/** - * Returns true if a given popstate event is an extraneous WebKit event. - * Accounts for the fact that Chrome on iOS fires real popstate events - * containing undefined state when pressing the back button. - */ -var isExtraneousPopstateEvent = function isExtraneousPopstateEvent(event) { - return event.state === undefined && navigator.userAgent.indexOf('CriOS') === -1; -}; - -/***/ }), -/* 107 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_path_to_regexp__ = __webpack_require__(52); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_path_to_regexp___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_path_to_regexp__); - - -var patternCache = {}; -var cacheLimit = 10000; -var cacheCount = 0; - -var compileGenerator = function compileGenerator(pattern) { - var cacheKey = pattern; - var cache = patternCache[cacheKey] || (patternCache[cacheKey] = {}); - - if (cache[pattern]) return cache[pattern]; - - var compiledGenerator = __WEBPACK_IMPORTED_MODULE_0_path_to_regexp___default.a.compile(pattern); - - if (cacheCount < cacheLimit) { - cache[pattern] = compiledGenerator; - cacheCount++; - } - - return compiledGenerator; -}; - -/** - * Public API for generating a URL pathname from a pattern and parameters. - */ -var generatePath = function generatePath() { - var pattern = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : "/"; - var params = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}; - - if (pattern === "/") { - return pattern; - } - var generator = compileGenerator(pattern); - return generator(params, { pretty: true }); -}; - -/* harmony default export */ __webpack_exports__["a"] = (generatePath); - -/***/ }), -/* 108 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_warning__ = __webpack_require__(39); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_warning___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_warning__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_invariant__ = __webpack_require__(40); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_invariant___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_invariant__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_react__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_react__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_prop_types__ = __webpack_require__(29); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_prop_types___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3_prop_types__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__matchPath__ = __webpack_require__(78); -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - - - - - - - -var isEmptyChildren = function isEmptyChildren(children) { - return __WEBPACK_IMPORTED_MODULE_2_react___default.a.Children.count(children) === 0; -}; - -/** - * The public API for matching a single path and rendering. - */ - -var Route = function (_React$Component) { - _inherits(Route, _React$Component); - - function Route() { - var _temp, _this, _ret; - - _classCallCheck(this, Route); - - for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { - args[_key] = arguments[_key]; - } - - return _ret = (_temp = (_this = _possibleConstructorReturn(this, _React$Component.call.apply(_React$Component, [this].concat(args))), _this), _this.state = { - match: _this.computeMatch(_this.props, _this.context.router) - }, _temp), _possibleConstructorReturn(_this, _ret); - } - - Route.prototype.getChildContext = function getChildContext() { - return { - router: _extends({}, this.context.router, { - route: { - location: this.props.location || this.context.router.route.location, - match: this.state.match - } - }) - }; - }; - - Route.prototype.computeMatch = function computeMatch(_ref, router) { - var computedMatch = _ref.computedMatch, - location = _ref.location, - path = _ref.path, - strict = _ref.strict, - exact = _ref.exact, - sensitive = _ref.sensitive; - - if (computedMatch) return computedMatch; // already computed the match for us - - __WEBPACK_IMPORTED_MODULE_1_invariant___default()(router, "You should not use or withRouter() outside a "); - - var route = router.route; - - var pathname = (location || route.location).pathname; - - return Object(__WEBPACK_IMPORTED_MODULE_4__matchPath__["a" /* default */])(pathname, { path: path, strict: strict, exact: exact, sensitive: sensitive }, route.match); - }; - - Route.prototype.componentWillMount = function componentWillMount() { - __WEBPACK_IMPORTED_MODULE_0_warning___default()(!(this.props.component && this.props.render), "You should not use and in the same route; will be ignored"); - - __WEBPACK_IMPORTED_MODULE_0_warning___default()(!(this.props.component && this.props.children && !isEmptyChildren(this.props.children)), "You should not use and in the same route; will be ignored"); - - __WEBPACK_IMPORTED_MODULE_0_warning___default()(!(this.props.render && this.props.children && !isEmptyChildren(this.props.children)), "You should not use and in the same route; will be ignored"); - }; - - Route.prototype.componentWillReceiveProps = function componentWillReceiveProps(nextProps, nextContext) { - __WEBPACK_IMPORTED_MODULE_0_warning___default()(!(nextProps.location && !this.props.location), ' elements should not change from uncontrolled to controlled (or vice versa). You initially used no "location" prop and then provided one on a subsequent render.'); - - __WEBPACK_IMPORTED_MODULE_0_warning___default()(!(!nextProps.location && this.props.location), ' elements should not change from controlled to uncontrolled (or vice versa). You provided a "location" prop initially but omitted it on a subsequent render.'); - - this.setState({ - match: this.computeMatch(nextProps, nextContext.router) - }); - }; - - Route.prototype.render = function render() { - var match = this.state.match; - var _props = this.props, - children = _props.children, - component = _props.component, - render = _props.render; - var _context$router = this.context.router, - history = _context$router.history, - route = _context$router.route, - staticContext = _context$router.staticContext; - - var location = this.props.location || route.location; - var props = { match: match, location: location, history: history, staticContext: staticContext }; - - if (component) return match ? __WEBPACK_IMPORTED_MODULE_2_react___default.a.createElement(component, props) : null; - - if (render) return match ? render(props) : null; - - if (typeof children === "function") return children(props); - - if (children && !isEmptyChildren(children)) return __WEBPACK_IMPORTED_MODULE_2_react___default.a.Children.only(children); - - return null; - }; - - return Route; -}(__WEBPACK_IMPORTED_MODULE_2_react___default.a.Component); - -Route.propTypes = { - computedMatch: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object, // private, from - path: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.string, - exact: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.bool, - strict: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.bool, - sensitive: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.bool, - component: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.func, - render: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.func, - children: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.node]), - location: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object -}; -Route.contextTypes = { - router: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.shape({ - history: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object.isRequired, - route: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object.isRequired, - staticContext: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object - }) -}; -Route.childContextTypes = { - router: __WEBPACK_IMPORTED_MODULE_3_prop_types___default.a.object.isRequired -}; - - -/* harmony default export */ __webpack_exports__["a"] = (Route); - -/***/ }), -/* 109 */ +/* 88 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -26379,7 +26242,7 @@ var _helpers = __webpack_require__(1); var helpers = _interopRequireWildcard(_helpers); -var _actions = __webpack_require__(7); +var _actions = __webpack_require__(6); var mopidyActions = _interopRequireWildcard(_actions); @@ -26473,7 +26336,7 @@ var mapDispatchToProps = function mapDispatchToProps(dispatch) { exports.default = (0, _reactRedux.connect)(mapStateToProps, mapDispatchToProps)(ProgressSlider); /***/ }), -/* 110 */ +/* 89 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -26493,7 +26356,7 @@ var _Thumbnail = __webpack_require__(11); var _Thumbnail2 = _interopRequireDefault(_Thumbnail); -var _URILink = __webpack_require__(18); +var _URILink = __webpack_require__(19); var _URILink2 = _interopRequireDefault(_URILink); @@ -26563,7 +26426,7 @@ var RelatedArtists = function (_React$Component) { exports.default = RelatedArtists; /***/ }), -/* 111 */ +/* 90 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -26687,7 +26550,7 @@ var ConfirmationButton = function (_React$Component) { exports.default = ConfirmationButton; /***/ }), -/* 112 */ +/* 91 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -26707,7 +26570,7 @@ var _reactRedux = __webpack_require__(4); var _redux = __webpack_require__(2); -var _reactGa = __webpack_require__(14); +var _reactGa = __webpack_require__(15); var _reactGa2 = _interopRequireDefault(_reactGa); @@ -26719,7 +26582,7 @@ var _actions = __webpack_require__(3); var uiActions = _interopRequireWildcard(_actions); -var _actions2 = __webpack_require__(9); +var _actions2 = __webpack_require__(8); var spotifyActions = _interopRequireWildcard(_actions2); @@ -26875,7 +26738,7 @@ var mapDispatchToProps = function mapDispatchToProps(dispatch) { exports.default = (0, _reactRedux.connect)(mapStateToProps, mapDispatchToProps)(SpotifyAuthenticationFrame); /***/ }), -/* 113 */ +/* 92 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -26895,7 +26758,7 @@ var _reactRedux = __webpack_require__(4); var _redux = __webpack_require__(2); -var _reactGa = __webpack_require__(14); +var _reactGa = __webpack_require__(15); var _reactGa2 = _interopRequireDefault(_reactGa); @@ -26907,7 +26770,7 @@ var _actions = __webpack_require__(3); var uiActions = _interopRequireWildcard(_actions); -var _actions2 = __webpack_require__(16); +var _actions2 = __webpack_require__(17); var lastfmActions = _interopRequireWildcard(_actions2); @@ -27062,7 +26925,7 @@ var mapDispatchToProps = function mapDispatchToProps(dispatch) { exports.default = (0, _reactRedux.connect)(mapStateToProps, mapDispatchToProps)(LastfmAuthenticationFrame); /***/ }), -/* 114 */ +/* 93 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -27077,7 +26940,7 @@ var _react = __webpack_require__(0); var _react2 = _interopRequireDefault(_react); -var _propTypes = __webpack_require__(33); +var _propTypes = __webpack_require__(12); var _propTypes2 = _interopRequireDefault(_propTypes); @@ -27121,7 +26984,7 @@ module.exports = exports['default']; //# sourceMappingURL=label.js.map /***/ }), -/* 115 */ +/* 94 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -27131,7 +26994,7 @@ var _react = __webpack_require__(0); var _react2 = _interopRequireDefault(_react); -var _reactDom = __webpack_require__(58); +var _reactDom = __webpack_require__(53); var _reactDom2 = _interopRequireDefault(_reactDom); @@ -27139,13 +27002,13 @@ var _reactRedux = __webpack_require__(4); var _redux = __webpack_require__(2); -var _reactRouterDom = __webpack_require__(32); +var _reactRouterDom = __webpack_require__(30); -var _store = __webpack_require__(175); +var _store = __webpack_require__(139); var _store2 = _interopRequireDefault(_store); -var _App = __webpack_require__(225); +var _App = __webpack_require__(186); var _App2 = _interopRequireDefault(_App); @@ -27155,7 +27018,7 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de ; -__webpack_require__(316); +__webpack_require__(264); _reactDom2.default.render(_react2.default.createElement( _reactRedux.Provider, @@ -27168,11 +27031,11 @@ _reactDom2.default.render(_react2.default.createElement( ), document.getElementById('app')); /***/ }), -/* 116 */ +/* 95 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** @license React v16.8.4 +/** @license React v16.8.5 * react.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. @@ -27181,7 +27044,7 @@ _reactDom2.default.render(_react2.default.createElement( * LICENSE file in the root directory of this source tree. */ -var k=__webpack_require__(31),n="function"===typeof Symbol&&Symbol.for,p=n?Symbol.for("react.element"):60103,q=n?Symbol.for("react.portal"):60106,r=n?Symbol.for("react.fragment"):60107,t=n?Symbol.for("react.strict_mode"):60108,u=n?Symbol.for("react.profiler"):60114,v=n?Symbol.for("react.provider"):60109,w=n?Symbol.for("react.context"):60110,x=n?Symbol.for("react.concurrent_mode"):60111,y=n?Symbol.for("react.forward_ref"):60112,z=n?Symbol.for("react.suspense"):60113,aa=n?Symbol.for("react.memo"): +var k=__webpack_require__(38),n="function"===typeof Symbol&&Symbol.for,p=n?Symbol.for("react.element"):60103,q=n?Symbol.for("react.portal"):60106,r=n?Symbol.for("react.fragment"):60107,t=n?Symbol.for("react.strict_mode"):60108,u=n?Symbol.for("react.profiler"):60114,v=n?Symbol.for("react.provider"):60109,w=n?Symbol.for("react.context"):60110,x=n?Symbol.for("react.concurrent_mode"):60111,y=n?Symbol.for("react.forward_ref"):60112,z=n?Symbol.for("react.suspense"):60113,aa=n?Symbol.for("react.memo"): 60115,ba=n?Symbol.for("react.lazy"):60116,A="function"===typeof Symbol&&Symbol.iterator;function ca(a,b,d,c,e,g,h,f){if(!a){a=void 0;if(void 0===b)a=Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var l=[d,c,e,g,h,f],m=0;a=Error(b.replace(/%s/g,function(){return l[m++]}));a.name="Invariant Violation"}a.framesToPop=1;throw a;}} function B(a){for(var b=arguments.length-1,d="https://reactjs.org/docs/error-decoder.html?invariant="+a,c=0;cP.length&&P.push(a)} function S(a,b,d,c){var e=typeof a;if("undefined"===e||"boolean"===e)a=null;var g=!1;if(null===a)g=!0;else switch(e){case "string":case "number":g=!0;break;case "object":switch(a.$$typeof){case p:case q:g=!0}}if(g)return d(c,a,""===b?"."+T(a,0):b),1;g=0;b=""===b?".":b+":";if(Array.isArray(a))for(var h=0;hc?b:c;0===b&&(Fh=null);$h(a,b)} function ai(a){for(;;){var b=a.alternate,c=a.return,d=a.sibling;if(0===(a.effectTag&1024)){T=a;a:{var e=b;b=a;var f=U;var g=b.pendingProps;switch(b.tag){case 2:break;case 16:break;case 15:case 0:break;case 1:J(b.type)&&Ke(b);break;case 3:Kf(b);Le(b);g=b.stateNode;g.pendingContext&&(g.context=g.pendingContext,g.pendingContext=null);if(null===e||null===e.child)Eg(b),b.effectTag&=-3;mh(b);break;case 5:Mf(b);var h=If(Hf.current);f=b.type;if(null!==e&&null!=b.stateNode)nh(e,b,f,g,h),e.ref!==b.ref&&(b.effectTag|= 128);else if(g){var l=If(N.current);if(Eg(b)){g=b;e=g.stateNode;var k=g.type,m=g.memoizedProps,p=h;e[Fa]=g;e[Ga]=m;f=void 0;h=k;switch(h){case "iframe":case "object":E("load",e);break;case "video":case "audio":for(k=0;k\x3c/script>",k=e.removeChild(e.firstChild)):"string"===typeof p.is?k=k.createElement(e,{is:p.is}):(k=k.createElement(e),"select"===e&&p.multiple&&(k.multiple=!0)):k=k.createElementNS(l,e);e=k;e[Fa]=m;e[Ga]=g;lh(e,b,!1,!1);p=e;k=f;m=g;var t=h,A=re(k,m);switch(k){case "iframe":case "object":E("load", +(e.onclick=te)}f=k;g.updateQueue=f;g=null!==f?!0:!1;g&&kh(b)}else{m=b;p=f;e=g;k=9===h.nodeType?h:h.ownerDocument;l===fe.html&&(l=ge(p));l===fe.html?"script"===p?(e=k.createElement("div"),e.innerHTML="