itsa-react-table
Version:
Editable React.js table
975 lines (838 loc) • 1.06 MB
JavaScript
/******/ (function(modules) { // webpackBootstrap
/******/ // The module cache
/******/ var installedModules = {};
/******/ // The require function
/******/ function __webpack_require__(moduleId) {
/******/ // Check if module is in cache
/******/ if(installedModules[moduleId])
/******/ return installedModules[moduleId].exports;
/******/ // Create a new module (and put it into the cache)
/******/ var module = installedModules[moduleId] = {
/******/ exports: {},
/******/ id: moduleId,
/******/ loaded: false
/******/ };
/******/ // Execute the module function
/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
/******/ // Flag the module as loaded
/******/ module.loaded = true;
/******/ // Return the exports of the module
/******/ return module.exports;
/******/ }
/******/ // expose the modules object (__webpack_modules__)
/******/ __webpack_require__.m = modules;
/******/ // expose the module cache
/******/ __webpack_require__.c = installedModules;
/******/ // __webpack_public_path__
/******/ __webpack_require__.p = "";
/******/ // Load entry module and return exports
/******/ return __webpack_require__(0);
/******/ })
/************************************************************************/
/******/ ([
/* 0 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
__webpack_require__(1);
var React = __webpack_require__(5),
ReactDOM = __webpack_require__(41),
Component = __webpack_require__(188);
var data = [{ id: "ga-3475", name: "gadget", price: "$6.99", cost: 5.99 }, { id: "sp-9980", name: "sprocket", price: "$3.75", cost: 0 }, { id: "wi-0650", name: "widget", price: "$4.25", cost: 3.75 }],
columns = ["id", { key: "name", label: "part name" }, "price", "cost"];
var changeData = function changeData(newData) {
props.data = newData.itsa_deepClone();
renderTable(props);
};
var onChangeCell = function onChangeCell(cells, editValueBeforeBlur) {
console.warn('app onchangecells', cells, editValueBeforeBlur);
var newData = props.data.itsa_deepClone();
cells.forEach(function (obj) {
newData[obj.row][obj.field] = editValueBeforeBlur;
});
props.data = newData;
renderTable(props);
};
var props = {
autoFocus: true,
disabled: false,
tableClass: 'pure-table pure-table-striped',
extendableX: true,
extendableY: "full",
removeableY: true,
cursorNav: true,
loop: false,
columns: columns,
data: data,
rowHeader: true,
editable: "full",
fixedHeaders: true,
// editableCols: [1, 3],
onChange: changeData,
onChangeCell: onChangeCell,
multiEdit: true
};
var renderTable = function renderTable(props) {
ReactDOM.render(React.createElement(Component, props), document.getElementById("component-container"));
};
renderTable(props);
/***/ }),
/* 1 */
/***/ (function(module, exports, __webpack_require__) {
// style-loader: Adds some css to the DOM by adding a <style> tag
// load the styles
var content = __webpack_require__(2);
if(typeof content === 'string') content = [[module.id, content, '']];
// add the styles to the DOM
var update = __webpack_require__(4)(content, {});
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {
// When the styles change, update the <style> tags
if(!content.locals) {
module.hot.accept("!!../../css-loader/index.js!../../sass-loader/index.js!./pure-min.css", function() {
var newContent = require("!!../../css-loader/index.js!../../sass-loader/index.js!./pure-min.css");
if(typeof newContent === 'string') newContent = [[module.id, newContent, '']];
update(newContent);
});
}
// When the module is disposed, remove the <style> tags
module.hot.dispose(function() { update(); });
}
/***/ }),
/* 2 */
/***/ (function(module, exports, __webpack_require__) {
exports = module.exports = __webpack_require__(3)();
// imports
// module
exports.push([module.id, "/*!\nPure v0.6.2\nCopyright 2013 Yahoo!\nLicensed under the BSD License.\nhttps://github.com/yahoo/pure/blob/master/LICENSE.md\n*/\n/*!\nnormalize.css v^3.0 | MIT License | git.io/normalize\nCopyright (c) Nicolas Gallagher and Jonathan Neal\n*/\n/*! normalize.css v3.0.3 | MIT License | github.com/necolas/normalize.css */\n.pure-button:focus, a:active, a:hover {\n outline: 0; }\n\n.pure-table, table {\n border-collapse: collapse;\n border-spacing: 0; }\n\nhtml {\n font-family: sans-serif;\n -ms-text-size-adjust: 100%;\n -webkit-text-size-adjust: 100%; }\n\nbody {\n margin: 0; }\n\narticle, aside, details, figcaption, figure, footer, header, hgroup, main, menu, nav, section, summary {\n display: block; }\n\naudio, canvas, progress, video {\n display: inline-block;\n vertical-align: baseline; }\n\naudio:not([controls]) {\n display: none;\n height: 0; }\n\n[hidden], template {\n display: none; }\n\na {\n background-color: transparent; }\n\nabbr[title] {\n border-bottom: 1px dotted; }\n\nb, optgroup, strong {\n font-weight: 700; }\n\ndfn {\n font-style: italic; }\n\nh1 {\n font-size: 2em;\n margin: .67em 0; }\n\nmark {\n background: #ff0;\n color: #000; }\n\nsmall {\n font-size: 80%; }\n\nsub, sup {\n font-size: 75%;\n line-height: 0;\n position: relative;\n vertical-align: baseline; }\n\nsup {\n top: -.5em; }\n\nsub {\n bottom: -.25em; }\n\nimg {\n border: 0; }\n\nsvg:not(:root) {\n overflow: hidden; }\n\nfigure {\n margin: 1em 40px; }\n\nhr {\n box-sizing: content-box;\n height: 0; }\n\npre, textarea {\n overflow: auto; }\n\ncode, kbd, pre, samp {\n font-family: monospace,monospace;\n font-size: 1em; }\n\nbutton, input, optgroup, select, textarea {\n color: inherit;\n font: inherit;\n margin: 0; }\n\n.pure-button, input {\n line-height: normal; }\n\nbutton {\n overflow: visible; }\n\nbutton, select {\n text-transform: none; }\n\nbutton, html input[type=button], input[type=reset], input[type=submit] {\n -webkit-appearance: button;\n cursor: pointer; }\n\nbutton[disabled], html input[disabled] {\n cursor: default; }\n\nbutton::-moz-focus-inner, input::-moz-focus-inner {\n border: 0;\n padding: 0; }\n\ninput[type=checkbox], input[type=radio] {\n box-sizing: border-box;\n padding: 0; }\n\ninput[type=number]::-webkit-inner-spin-button, input[type=number]::-webkit-outer-spin-button {\n height: auto; }\n\ninput[type=search] {\n -webkit-appearance: textfield;\n box-sizing: content-box; }\n\n.pure-button, .pure-form input:not([type]), .pure-menu {\n box-sizing: border-box; }\n\ninput[type=search]::-webkit-search-cancel-button, input[type=search]::-webkit-search-decoration {\n -webkit-appearance: none; }\n\nfieldset {\n border: 1px solid silver;\n margin: 0 2px;\n padding: .35em .625em .75em; }\n\nlegend, td, th {\n padding: 0; }\n\nlegend {\n border: 0; }\n\n.hidden, [hidden] {\n display: none !important; }\n\n.pure-img {\n max-width: 100%;\n height: auto;\n display: block; }\n\n.pure-g {\n letter-spacing: -.31em;\n text-rendering: optimizespeed;\n font-family: FreeSans,Arimo,\"Droid Sans\",Helvetica,Arial,sans-serif;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n -webkit-align-content: flex-start;\n -ms-flex-line-pack: start;\n align-content: flex-start; }\n\n@media all and (-ms-high-contrast: none), (-ms-high-contrast: active) {\n table .pure-g {\n display: block; } }\n\n.opera-only :-o-prefocus, .pure-g {\n word-spacing: -.43em; }\n\n.pure-u, .pure-u-1, .pure-u-1-1, .pure-u-1-12, .pure-u-1-2, .pure-u-1-24, .pure-u-1-3, .pure-u-1-4, .pure-u-1-5, .pure-u-1-6, .pure-u-1-8, .pure-u-10-24, .pure-u-11-12, .pure-u-11-24, .pure-u-12-24, .pure-u-13-24, .pure-u-14-24, .pure-u-15-24, .pure-u-16-24, .pure-u-17-24, .pure-u-18-24, .pure-u-19-24, .pure-u-2-24, .pure-u-2-3, .pure-u-2-5, .pure-u-20-24, .pure-u-21-24, .pure-u-22-24, .pure-u-23-24, .pure-u-24-24, .pure-u-3-24, .pure-u-3-4, .pure-u-3-5, .pure-u-3-8, .pure-u-4-24, .pure-u-4-5, .pure-u-5-12, .pure-u-5-24, .pure-u-5-5, .pure-u-5-6, .pure-u-5-8, .pure-u-6-24, .pure-u-7-12, .pure-u-7-24, .pure-u-7-8, .pure-u-8-24, .pure-u-9-24 {\n letter-spacing: normal;\n word-spacing: normal;\n vertical-align: top;\n text-rendering: auto;\n display: inline-block;\n zoom: 1; }\n\n.pure-g [class*=pure-u] {\n font-family: sans-serif; }\n\n.pure-u-1-24 {\n width: 4.1667%; }\n\n.pure-u-1-12, .pure-u-2-24 {\n width: 8.3333%; }\n\n.pure-u-1-8, .pure-u-3-24 {\n width: 12.5%; }\n\n.pure-u-1-6, .pure-u-4-24 {\n width: 16.6667%; }\n\n.pure-u-1-5 {\n width: 20%; }\n\n.pure-u-5-24 {\n width: 20.8333%; }\n\n.pure-u-1-4, .pure-u-6-24 {\n width: 25%; }\n\n.pure-u-7-24 {\n width: 29.1667%; }\n\n.pure-u-1-3, .pure-u-8-24 {\n width: 33.3333%; }\n\n.pure-u-3-8, .pure-u-9-24 {\n width: 37.5%; }\n\n.pure-u-2-5 {\n width: 40%; }\n\n.pure-u-10-24, .pure-u-5-12 {\n width: 41.6667%; }\n\n.pure-u-11-24 {\n width: 45.8333%; }\n\n.pure-u-1-2, .pure-u-12-24 {\n width: 50%; }\n\n.pure-u-13-24 {\n width: 54.1667%; }\n\n.pure-u-14-24, .pure-u-7-12 {\n width: 58.3333%; }\n\n.pure-u-3-5 {\n width: 60%; }\n\n.pure-u-15-24, .pure-u-5-8 {\n width: 62.5%; }\n\n.pure-u-16-24, .pure-u-2-3 {\n width: 66.6667%; }\n\n.pure-u-17-24 {\n width: 70.8333%; }\n\n.pure-u-18-24, .pure-u-3-4 {\n width: 75%; }\n\n.pure-u-19-24 {\n width: 79.1667%; }\n\n.pure-u-4-5 {\n width: 80%; }\n\n.pure-u-20-24, .pure-u-5-6 {\n width: 83.3333%; }\n\n.pure-u-21-24, .pure-u-7-8 {\n width: 87.5%; }\n\n.pure-u-11-12, .pure-u-22-24 {\n width: 91.6667%; }\n\n.pure-u-23-24 {\n width: 95.8333%; }\n\n.pure-u-1, .pure-u-1-1, .pure-u-24-24, .pure-u-5-5 {\n width: 100%; }\n\n.pure-button {\n display: inline-block;\n zoom: 1;\n white-space: nowrap;\n vertical-align: middle;\n text-align: center;\n cursor: pointer;\n -webkit-user-drag: none;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none; }\n\n.pure-button::-moz-focus-inner {\n padding: 0;\n border: 0; }\n\n.pure-button-group {\n letter-spacing: -.31em;\n text-rendering: optimizespeed; }\n\n.opera-only :-o-prefocus, .pure-button-group {\n word-spacing: -.43em; }\n\n.pure-button {\n font-family: inherit;\n font-size: 100%;\n padding: .5em 1em;\n color: #444;\n color: rgba(0, 0, 0, 0.8);\n border: 1px solid #999;\n border: transparent;\n background-color: #E6E6E6;\n text-decoration: none;\n border-radius: 2px; }\n\n.pure-button-hover, .pure-button:focus, .pure-button:hover {\n filter: alpha(opacity=90);\n background-image: -webkit-linear-gradient(transparent, rgba(0, 0, 0, 0.05) 40%, rgba(0, 0, 0, 0.1));\n background-image: linear-gradient(transparent, rgba(0, 0, 0, 0.05) 40%, rgba(0, 0, 0, 0.1)); }\n\n.pure-button-active, .pure-button:active {\n box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.15) inset, 0 0 6px rgba(0, 0, 0, 0.2) inset;\n border-color: #000\\9; }\n\n.pure-button-disabled, .pure-button-disabled:active, .pure-button-disabled:focus, .pure-button-disabled:hover, .pure-button[disabled] {\n border: none;\n background-image: none;\n filter: alpha(opacity=40);\n opacity: .4;\n cursor: not-allowed;\n box-shadow: none;\n pointer-events: none; }\n\n.pure-button-hidden {\n display: none; }\n\n.pure-button-primary, .pure-button-selected, a.pure-button-primary, a.pure-button-selected {\n background-color: #0078e7;\n color: #fff; }\n\n.pure-button-group .pure-button {\n letter-spacing: normal;\n word-spacing: normal;\n vertical-align: top;\n text-rendering: auto;\n margin: 0;\n border-radius: 0;\n border-right: 1px solid #111;\n border-right: 1px solid rgba(0, 0, 0, 0.2); }\n\n.pure-button-group .pure-button:first-child {\n border-top-left-radius: 2px;\n border-bottom-left-radius: 2px; }\n\n.pure-button-group .pure-button:last-child {\n border-top-right-radius: 2px;\n border-bottom-right-radius: 2px;\n border-right: none; }\n\n.pure-form input[type=password], .pure-form input[type=email], .pure-form input[type=url], .pure-form input[type=date], .pure-form input[type=month], .pure-form input[type=time], .pure-form input[type=datetime], .pure-form input[type=datetime-local], .pure-form input[type=week], .pure-form input[type=tel], .pure-form input[type=color], .pure-form input[type=number], .pure-form input[type=search], .pure-form input[type=text], .pure-form select, .pure-form textarea {\n padding: .5em .6em;\n display: inline-block;\n border: 1px solid #ccc;\n box-shadow: inset 0 1px 3px #ddd;\n border-radius: 4px;\n vertical-align: middle;\n box-sizing: border-box; }\n\n.pure-form input:not([type]) {\n padding: .5em .6em;\n display: inline-block;\n border: 1px solid #ccc;\n box-shadow: inset 0 1px 3px #ddd;\n border-radius: 4px; }\n\n.pure-form input[type=color] {\n padding: .2em .5em; }\n\n.pure-form input:not([type]):focus, .pure-form input[type=password]:focus, .pure-form input[type=email]:focus, .pure-form input[type=url]:focus, .pure-form input[type=date]:focus, .pure-form input[type=month]:focus, .pure-form input[type=time]:focus, .pure-form input[type=datetime]:focus, .pure-form input[type=datetime-local]:focus, .pure-form input[type=week]:focus, .pure-form input[type=tel]:focus, .pure-form input[type=color]:focus, .pure-form input[type=number]:focus, .pure-form input[type=search]:focus, .pure-form input[type=text]:focus, .pure-form select:focus, .pure-form textarea:focus {\n outline: 0;\n border-color: #129FEA; }\n\n.pure-form input[type=file]:focus, .pure-form input[type=checkbox]:focus, .pure-form input[type=radio]:focus {\n outline: #129FEA auto 1px; }\n\n.pure-form .pure-checkbox, .pure-form .pure-radio {\n margin: .5em 0;\n display: block; }\n\n.pure-form input:not([type])[disabled], .pure-form input[type=password][disabled], .pure-form input[type=email][disabled], .pure-form input[type=url][disabled], .pure-form input[type=date][disabled], .pure-form input[type=month][disabled], .pure-form input[type=time][disabled], .pure-form input[type=datetime][disabled], .pure-form input[type=datetime-local][disabled], .pure-form input[type=week][disabled], .pure-form input[type=tel][disabled], .pure-form input[type=color][disabled], .pure-form input[type=number][disabled], .pure-form input[type=search][disabled], .pure-form input[type=text][disabled], .pure-form select[disabled], .pure-form textarea[disabled] {\n cursor: not-allowed;\n background-color: #eaeded;\n color: #cad2d3; }\n\n.pure-form input[readonly], .pure-form select[readonly], .pure-form textarea[readonly] {\n background-color: #eee;\n color: #777;\n border-color: #ccc; }\n\n.pure-form input:focus:invalid, .pure-form select:focus:invalid, .pure-form textarea:focus:invalid {\n color: #b94a48;\n border-color: #e9322d; }\n\n.pure-form input[type=file]:focus:invalid:focus, .pure-form input[type=checkbox]:focus:invalid:focus, .pure-form input[type=radio]:focus:invalid:focus {\n outline-color: #e9322d; }\n\n.pure-form select {\n height: 2.25em;\n border: 1px solid #ccc;\n background-color: #fff; }\n\n.pure-form select[multiple] {\n height: auto; }\n\n.pure-form label {\n margin: .5em 0 .2em; }\n\n.pure-form fieldset {\n margin: 0;\n padding: .35em 0 .75em;\n border: 0; }\n\n.pure-form legend {\n display: block;\n width: 100%;\n padding: .3em 0;\n margin-bottom: .3em;\n color: #333;\n border-bottom: 1px solid #e5e5e5; }\n\n.pure-form-stacked input:not([type]), .pure-form-stacked input[type=password], .pure-form-stacked input[type=email], .pure-form-stacked input[type=url], .pure-form-stacked input[type=date], .pure-form-stacked input[type=month], .pure-form-stacked input[type=time], .pure-form-stacked input[type=datetime], .pure-form-stacked input[type=datetime-local], .pure-form-stacked input[type=week], .pure-form-stacked input[type=tel], .pure-form-stacked input[type=color], .pure-form-stacked input[type=file], .pure-form-stacked input[type=number], .pure-form-stacked input[type=search], .pure-form-stacked input[type=text], .pure-form-stacked label, .pure-form-stacked select, .pure-form-stacked textarea {\n display: block;\n margin: .25em 0; }\n\n.pure-form-aligned .pure-help-inline, .pure-form-aligned input, .pure-form-aligned select, .pure-form-aligned textarea, .pure-form-message-inline {\n display: inline-block;\n vertical-align: middle; }\n\n.pure-form-aligned textarea {\n vertical-align: top; }\n\n.pure-form-aligned .pure-control-group {\n margin-bottom: .5em; }\n\n.pure-form-aligned .pure-control-group label {\n text-align: right;\n display: inline-block;\n vertical-align: middle;\n width: 10em;\n margin: 0 1em 0 0; }\n\n.pure-form-aligned .pure-controls {\n margin: 1.5em 0 0 11em; }\n\n.pure-form .pure-input-rounded, .pure-form input.pure-input-rounded {\n border-radius: 2em;\n padding: .5em 1em; }\n\n.pure-form .pure-group fieldset {\n margin-bottom: 10px; }\n\n.pure-form .pure-group input, .pure-form .pure-group textarea {\n display: block;\n padding: 10px;\n margin: 0 0 -1px;\n border-radius: 0;\n position: relative;\n top: -1px; }\n\n.pure-form .pure-group input:focus, .pure-form .pure-group textarea:focus {\n z-index: 3; }\n\n.pure-form .pure-group input:first-child, .pure-form .pure-group textarea:first-child {\n top: 1px;\n border-radius: 4px 4px 0 0;\n margin: 0; }\n\n.pure-form .pure-group input:first-child:last-child, .pure-form .pure-group textarea:first-child:last-child {\n top: 1px;\n border-radius: 4px;\n margin: 0; }\n\n.pure-form .pure-group input:last-child, .pure-form .pure-group textarea:last-child {\n top: -2px;\n border-radius: 0 0 4px 4px;\n margin: 0; }\n\n.pure-form .pure-group button {\n margin: .35em 0; }\n\n.pure-form .pure-input-1 {\n width: 100%; }\n\n.pure-form .pure-input-3-4 {\n width: 75%; }\n\n.pure-form .pure-input-2-3 {\n width: 66%; }\n\n.pure-form .pure-input-1-2 {\n width: 50%; }\n\n.pure-form .pure-input-1-3 {\n width: 33%; }\n\n.pure-form .pure-input-1-4 {\n width: 25%; }\n\n.pure-form .pure-help-inline, .pure-form-message-inline {\n display: inline-block;\n padding-left: .3em;\n color: #666;\n vertical-align: middle;\n font-size: .875em; }\n\n.pure-form-message {\n display: block;\n color: #666;\n font-size: .875em; }\n\n@media only screen and (max-width: 480px) {\n .pure-form button[type=submit] {\n margin: .7em 0 0; }\n .pure-form input:not([type]), .pure-form input[type=password], .pure-form input[type=email], .pure-form input[type=url], .pure-form input[type=date], .pure-form input[type=month], .pure-form input[type=time], .pure-form input[type=datetime], .pure-form input[type=datetime-local], .pure-form input[type=week], .pure-form input[type=tel], .pure-form input[type=color], .pure-form input[type=number], .pure-form input[type=search], .pure-form input[type=text], .pure-form label {\n margin-bottom: .3em;\n display: block; }\n .pure-group input:not([type]), .pure-group input[type=password], .pure-group input[type=email], .pure-group input[type=url], .pure-group input[type=date], .pure-group input[type=month], .pure-group input[type=time], .pure-group input[type=datetime], .pure-group input[type=datetime-local], .pure-group input[type=week], .pure-group input[type=tel], .pure-group input[type=color], .pure-group input[type=number], .pure-group input[type=search], .pure-group input[type=text] {\n margin-bottom: 0; }\n .pure-form-aligned .pure-control-group label {\n margin-bottom: .3em;\n text-align: left;\n display: block;\n width: 100%; }\n .pure-form-aligned .pure-controls {\n margin: 1.5em 0 0; }\n .pure-form .pure-help-inline, .pure-form-message, .pure-form-message-inline {\n display: block;\n font-size: .75em;\n padding: .2em 0 .8em; } }\n\n.pure-menu-fixed {\n position: fixed;\n left: 0;\n top: 0;\n z-index: 3; }\n\n.pure-menu-item, .pure-menu-list {\n position: relative; }\n\n.pure-menu-list {\n list-style: none;\n margin: 0;\n padding: 0; }\n\n.pure-menu-item {\n padding: 0;\n margin: 0;\n height: 100%; }\n\n.pure-menu-heading, .pure-menu-link {\n display: block;\n text-decoration: none;\n white-space: nowrap; }\n\n.pure-menu-horizontal {\n width: 100%;\n white-space: nowrap; }\n\n.pure-menu-horizontal .pure-menu-list {\n display: inline-block; }\n\n.pure-menu-horizontal .pure-menu-heading, .pure-menu-horizontal .pure-menu-item, .pure-menu-horizontal .pure-menu-separator {\n display: inline-block;\n zoom: 1;\n vertical-align: middle; }\n\n.pure-menu-item .pure-menu-item {\n display: block; }\n\n.pure-menu-children {\n display: none;\n position: absolute;\n left: 100%;\n top: 0;\n margin: 0;\n padding: 0;\n z-index: 3; }\n\n.pure-menu-horizontal .pure-menu-children {\n left: 0;\n top: auto;\n width: inherit; }\n\n.pure-menu-active > .pure-menu-children, .pure-menu-allow-hover:hover > .pure-menu-children {\n display: block;\n position: absolute; }\n\n.pure-menu-has-children > .pure-menu-link:after {\n padding-left: .5em;\n content: \"\\25B8\";\n font-size: small; }\n\n.pure-menu-horizontal .pure-menu-has-children > .pure-menu-link:after {\n content: \"\\25BE\"; }\n\n.pure-menu-scrollable {\n overflow-y: scroll;\n overflow-x: hidden; }\n\n.pure-menu-scrollable .pure-menu-list {\n display: block; }\n\n.pure-menu-horizontal.pure-menu-scrollable .pure-menu-list {\n display: inline-block; }\n\n.pure-menu-horizontal.pure-menu-scrollable {\n white-space: nowrap;\n overflow-y: hidden;\n overflow-x: auto;\n -ms-overflow-style: none;\n -webkit-overflow-scrolling: touch;\n padding: .5em 0; }\n\n.pure-menu-horizontal.pure-menu-scrollable::-webkit-scrollbar {\n display: none; }\n\n.pure-menu-horizontal .pure-menu-children .pure-menu-separator, .pure-menu-separator {\n background-color: #ccc;\n height: 1px;\n margin: .3em 0; }\n\n.pure-menu-horizontal .pure-menu-separator {\n width: 1px;\n height: 1.3em;\n margin: 0 .3em; }\n\n.pure-menu-horizontal .pure-menu-children .pure-menu-separator {\n display: block;\n width: auto; }\n\n.pure-menu-heading {\n text-transform: uppercase;\n color: #565d64; }\n\n.pure-menu-link {\n color: #777; }\n\n.pure-menu-children {\n background-color: #fff; }\n\n.pure-menu-disabled, .pure-menu-heading, .pure-menu-link {\n padding: .5em 1em; }\n\n.pure-menu-disabled {\n opacity: .5; }\n\n.pure-menu-disabled .pure-menu-link:hover {\n background-color: transparent; }\n\n.pure-menu-active > .pure-menu-link, .pure-menu-link:focus, .pure-menu-link:hover {\n background-color: #eee; }\n\n.pure-menu-selected .pure-menu-link, .pure-menu-selected .pure-menu-link:visited {\n color: #000; }\n\n.pure-table {\n empty-cells: show;\n border: 1px solid #cbcbcb; }\n\n.pure-table caption {\n color: #000;\n font: italic 85%/1 arial,sans-serif;\n padding: 1em 0;\n text-align: center; }\n\n.pure-table td, .pure-table th {\n border-left: 1px solid #cbcbcb;\n border-width: 0 0 0 1px;\n font-size: inherit;\n margin: 0;\n overflow: visible;\n padding: .5em 1em; }\n\n.pure-table td:first-child, .pure-table th:first-child {\n border-left-width: 0; }\n\n.pure-table thead {\n background-color: #e0e0e0;\n color: #000;\n text-align: left;\n vertical-align: bottom; }\n\n.pure-table td {\n background-color: transparent; }\n\n.pure-table-odd td, .pure-table-striped tr:nth-child(2n-1) td {\n background-color: #f2f2f2; }\n\n.pure-table-bordered td {\n border-bottom: 1px solid #cbcbcb; }\n\n.pure-table-bordered tbody > tr:last-child > td {\n border-bottom-width: 0; }\n\n.pure-table-horizontal td, .pure-table-horizontal th {\n border-width: 0 0 1px;\n border-bottom: 1px solid #cbcbcb; }\n\n.pure-table-horizontal tbody > tr:last-child > td {\n border-bottom-width: 0; }\n", ""]);
// exports
/***/ }),
/* 3 */
/***/ (function(module, exports) {
"use strict";
/*
MIT License http://www.opensource.org/licenses/mit-license.php
Author Tobias Koppers @sokra
*/
// css base code, injected by the css-loader
module.exports = function () {
var list = [];
// return the list of modules as css string
list.toString = function toString() {
var result = [];
for (var i = 0; i < this.length; i++) {
var item = this[i];
if (item[2]) {
result.push("@media " + item[2] + "{" + item[1] + "}");
} else {
result.push(item[1]);
}
}
return result.join("");
};
// import a list of modules into the list
list.i = function (modules, mediaQuery) {
if (typeof modules === "string") modules = [[null, modules, ""]];
var alreadyImportedModules = {};
for (var i = 0; i < this.length; i++) {
var id = this[i][0];
if (typeof id === "number") alreadyImportedModules[id] = true;
}
for (i = 0; i < modules.length; i++) {
var item = modules[i];
// skip already imported module
// this implementation is not 100% perfect for weird media query combinations
// when a module is imported multiple times with different media queries.
// I hope this will never occur (Hey this way we have smaller bundles)
if (typeof item[0] !== "number" || !alreadyImportedModules[item[0]]) {
if (mediaQuery && !item[2]) {
item[2] = mediaQuery;
} else if (mediaQuery) {
item[2] = "(" + item[2] + ") and (" + mediaQuery + ")";
}
list.push(item);
}
}
};
return list;
};
/***/ }),
/* 4 */
/***/ (function(module, exports, __webpack_require__) {
/*
MIT License http://www.opensource.org/licenses/mit-license.php
Author Tobias Koppers @sokra
*/
var stylesInDom = {},
memoize = function(fn) {
var memo;
return function () {
if (typeof memo === "undefined") memo = fn.apply(this, arguments);
return memo;
};
},
isOldIE = memoize(function() {
return /msie [6-9]\b/.test(self.navigator.userAgent.toLowerCase());
}),
getHeadElement = memoize(function () {
return document.head || document.getElementsByTagName("head")[0];
}),
singletonElement = null,
singletonCounter = 0,
styleElementsInsertedAtTop = [];
module.exports = function(list, options) {
if(false) {
if(typeof document !== "object") throw new Error("The style-loader cannot be used in a non-browser environment");
}
options = options || {};
// Force single-tag solution on IE6-9, which has a hard limit on the # of <style>
// tags it will allow on a page
if (typeof options.singleton === "undefined") options.singleton = isOldIE();
// By default, add <style> tags to the bottom of <head>.
if (typeof options.insertAt === "undefined") options.insertAt = "bottom";
var styles = listToStyles(list);
addStylesToDom(styles, options);
return function update(newList) {
var mayRemove = [];
for(var i = 0; i < styles.length; i++) {
var item = styles[i];
var domStyle = stylesInDom[item.id];
domStyle.refs--;
mayRemove.push(domStyle);
}
if(newList) {
var newStyles = listToStyles(newList);
addStylesToDom(newStyles, options);
}
for(var i = 0; i < mayRemove.length; i++) {
var domStyle = mayRemove[i];
if(domStyle.refs === 0) {
for(var j = 0; j < domStyle.parts.length; j++)
domStyle.parts[j]();
delete stylesInDom[domStyle.id];
}
}
};
}
function addStylesToDom(styles, options) {
for(var i = 0; i < styles.length; i++) {
var item = styles[i];
var domStyle = stylesInDom[item.id];
if(domStyle) {
domStyle.refs++;
for(var j = 0; j < domStyle.parts.length; j++) {
domStyle.parts[j](item.parts[j]);
}
for(; j < item.parts.length; j++) {
domStyle.parts.push(addStyle(item.parts[j], options));
}
} else {
var parts = [];
for(var j = 0; j < item.parts.length; j++) {
parts.push(addStyle(item.parts[j], options));
}
stylesInDom[item.id] = {id: item.id, refs: 1, parts: parts};
}
}
}
function listToStyles(list) {
var styles = [];
var newStyles = {};
for(var i = 0; i < list.length; i++) {
var item = list[i];
var id = item[0];
var css = item[1];
var media = item[2];
var sourceMap = item[3];
var part = {css: css, media: media, sourceMap: sourceMap};
if(!newStyles[id])
styles.push(newStyles[id] = {id: id, parts: [part]});
else
newStyles[id].parts.push(part);
}
return styles;
}
function insertStyleElement(options, styleElement) {
var head = getHeadElement();
var lastStyleElementInsertedAtTop = styleElementsInsertedAtTop[styleElementsInsertedAtTop.length - 1];
if (options.insertAt === "top") {
if(!lastStyleElementInsertedAtTop) {
head.insertBefore(styleElement, head.firstChild);
} else if(lastStyleElementInsertedAtTop.nextSibling) {
head.insertBefore(styleElement, lastStyleElementInsertedAtTop.nextSibling);
} else {
head.appendChild(styleElement);
}
styleElementsInsertedAtTop.push(styleElement);
} else if (options.insertAt === "bottom") {
head.appendChild(styleElement);
} else {
throw new Error("Invalid value for parameter 'insertAt'. Must be 'top' or 'bottom'.");
}
}
function removeStyleElement(styleElement) {
styleElement.parentNode.removeChild(styleElement);
var idx = styleElementsInsertedAtTop.indexOf(styleElement);
if(idx >= 0) {
styleElementsInsertedAtTop.splice(idx, 1);
}
}
function createStyleElement(options) {
var styleElement = document.createElement("style");
styleElement.type = "text/css";
insertStyleElement(options, styleElement);
return styleElement;
}
function createLinkElement(options) {
var linkElement = document.createElement("link");
linkElement.rel = "stylesheet";
insertStyleElement(options, linkElement);
return linkElement;
}
function addStyle(obj, options) {
var styleElement, update, remove;
if (options.singleton) {
var styleIndex = singletonCounter++;
styleElement = singletonElement || (singletonElement = createStyleElement(options));
update = applyToSingletonTag.bind(null, styleElement, styleIndex, false);
remove = applyToSingletonTag.bind(null, styleElement, styleIndex, true);
} else if(obj.sourceMap &&
typeof URL === "function" &&
typeof URL.createObjectURL === "function" &&
typeof URL.revokeObjectURL === "function" &&
typeof Blob === "function" &&
typeof btoa === "function") {
styleElement = createLinkElement(options);
update = updateLink.bind(null, styleElement);
remove = function() {
removeStyleElement(styleElement);
if(styleElement.href)
URL.revokeObjectURL(styleElement.href);
};
} else {
styleElement = createStyleElement(options);
update = applyToTag.bind(null, styleElement);
remove = function() {
removeStyleElement(styleElement);
};
}
update(obj);
return function updateStyle(newObj) {
if(newObj) {
if(newObj.css === obj.css && newObj.media === obj.media && newObj.sourceMap === obj.sourceMap)
return;
update(obj = newObj);
} else {
remove();
}
};
}
var replaceText = (function () {
var textStore = [];
return function (index, replacement) {
textStore[index] = replacement;
return textStore.filter(Boolean).join('\n');
};
})();
function applyToSingletonTag(styleElement, index, remove, obj) {
var css = remove ? "" : obj.css;
if (styleElement.styleSheet) {
styleElement.styleSheet.cssText = replaceText(index, css);
} else {
var cssNode = document.createTextNode(css);
var childNodes = styleElement.childNodes;
if (childNodes[index]) styleElement.removeChild(childNodes[index]);
if (childNodes.length) {
styleElement.insertBefore(cssNode, childNodes[index]);
} else {
styleElement.appendChild(cssNode);
}
}
}
function applyToTag(styleElement, obj) {
var css = obj.css;
var media = obj.media;
if(media) {
styleElement.setAttribute("media", media)
}
if(styleElement.styleSheet) {
styleElement.styleSheet.cssText = css;
} else {
while(styleElement.firstChild) {
styleElement.removeChild(styleElement.firstChild);
}
styleElement.appendChild(document.createTextNode(css));
}
}
function updateLink(linkElement, obj) {
var css = obj.css;
var sourceMap = obj.sourceMap;
if(sourceMap) {
// http://stackoverflow.com/a/26603875
css += "\n/*# sourceMappingURL=data:application/json;base64," + btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))) + " */";
}
var blob = new Blob([css], { type: "text/css" });
var oldSrc = linkElement.href;
linkElement.href = URL.createObjectURL(blob);
if(oldSrc)
URL.revokeObjectURL(oldSrc);
}
/***/ }),
/* 5 */
/***/ (function(module, exports, __webpack_require__) {
'use strict';
module.exports = __webpack_require__(6);
/***/ }),
/* 6 */
/***/ (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.
*
*/
'use strict';
var _assign = __webpack_require__(8);
var ReactBaseClasses = __webpack_require__(9);
var ReactChildren = __webpack_require__(18);
var ReactDOMFactories = __webpack_require__(26);
var ReactElement = __webpack_require__(20);
var ReactPropTypes = __webpack_require__(32);
var ReactVersion = __webpack_require__(37);
var createReactClass = __webpack_require__(38);
var onlyChild = __webpack_require__(40);
var createElement = ReactElement.createElement;
var createFactory = ReactElement.createFactory;
var cloneElement = ReactElement.cloneElement;
if (process.env.NODE_ENV !== 'production') {
var lowPriorityWarning = __webpack_require__(17);
var canDefineProperty = __webpack_require__(14);
var ReactElementValidator = __webpack_require__(27);
var didWarnPropTypesDeprecated = false;
createElement = ReactElementValidator.createElement;
createFactory = ReactElementValidator.createFactory;
cloneElement = ReactElementValidator.cloneElement;
}
var __spread = _assign;
var createMixin = function createMixin(mixin) {
return mixin;
};
if (process.env.NODE_ENV !== 'production') {
var warnedForSpread = false;
var warnedForCreateMixin = false;
__spread = function __spread() {
lowPriorityWarning(warnedForSpread, 'React.__spread is deprecated and should not be used. Use ' + 'Object.assign directly or another helper function with similar ' + 'semantics. You may be seeing this warning due to your compiler. ' + 'See https://fb.me/react-spread-deprecation for more details.');
warnedForSpread = true;
return _assign.apply(null, arguments);
};
createMixin = function createMixin(mixin) {
lowPriorityWarning(warnedForCreateMixin, 'React.createMixin is deprecated and should not be used. ' + 'In React v16.0, it will be removed. ' + 'You can use this mixin directly instead. ' + 'See https://fb.me/createmixin-was-never-implemented for more info.');
warnedForCreateMixin = true;
return mixin;
};
}
var React = {
// Modern
Children: {
map: ReactChildren.map,
forEach: ReactChildren.forEach,
count: ReactChildren.count,
toArray: ReactChildren.toArray,
only: onlyChild
},
Component: ReactBaseClasses.Component,
PureComponent: ReactBaseClasses.PureComponent,
createElement: createElement,
cloneElement: cloneElement,
isValidElement: ReactElement.isValidElement,
// Classic
PropTypes: ReactPropTypes,
createClass: createReactClass,
createFactory: createFactory,
createMixin: createMixin,
// This looks DOM specific but these are actually isomorphic helpers
// since they are just generating DOM strings.
DOM: ReactDOMFactories,
version: ReactVersion,
// Deprecated hook for JSX spread, don't use this for anything.
__spread: __spread
};
if (process.env.NODE_ENV !== 'production') {
var warnedForCreateClass = false;
if (canDefineProperty) {
Object.defineProperty(React, 'PropTypes', {
get: function get() {
lowPriorityWarning(didWarnPropTypesDeprecated, 'Accessing PropTypes via the main React package is deprecated,' + ' and will be removed in React v16.0.' + ' Use the latest available v15.* prop-types package from npm instead.' + ' For info on usage, compatibility, migration and more, see ' + 'https://fb.me/prop-types-docs');
didWarnPropTypesDeprecated = true;
return ReactPropTypes;
}
});
Object.defineProperty(React, 'createClass', {
get: function get() {
lowPriorityWarning(warnedForCreateClass, 'Accessing createClass via the main React package is deprecated,' + ' and will be removed in React v16.0.' + " Use a plain JavaScript class instead. If you're not yet " + 'ready to migrate, create-react-class v15.* is available ' + 'on npm as a temporary, drop-in replacement. ' + 'For more info see https://fb.me/react-create-class');
warnedForCreateClass = true;
return createReactClass;
}
});
}
// React.DOM factories are deprecated. Wrap these methods so that
// invocations of the React.DOM namespace and alert users to switch
// to the `react-dom-factories` package.
React.DOM = {};
var warnedForFactories = false;
Object.keys(ReactDOMFactories).forEach(function (factory) {
React.DOM[factory] = function () {
if (!warnedForFactories) {
lowPriorityWarning(false, 'Accessing factories like React.DOM.%s has been deprecated ' + 'and will be removed in v16.0+. Use the ' + 'react-dom-factories package instead. ' + ' Version 1.0 provides a drop-in replacement.' + ' For more info, see https://fb.me/react-dom-factories', factory);
warnedForFactories = true;
}
return ReactDOMFactories[factory].apply(ReactDOMFactories, arguments);
};
});
}
module.exports = React;
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7)))
/***/ }),
/* 7 */
/***/ (function(module, exports) {
'use strict';
// 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;
};
/***/ }),
/* 8 */
/***/ (function(module, exports) {
/*
object-assign
(c) Sindre Sorhus
@license MIT
*/
'use strict';
/* 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;
};
/***/ }),
/* 9 */
/***/ (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.
*
*/
'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; };
var _prodInvariant = __webpack_require__(10),
_assign = __webpack_require__(8);
var ReactNoopUpdateQueue = __webpack_require__(11);
var canDefineProperty = __webpack_require__(14);
var emptyObject = __webpack_require__(15);
var invariant = __webpack_require__(16);
var lowPriorityWarning = __webpack_require__(17);
/**
* Base class helpers for the updating state of a component.
*/
function ReactComponent(props, context, updater) {
this.props = props;
this.context = context;
this.refs = emptyObject;
// We initialize the default updater but the real one gets injected by the
// renderer.
this.updater = updater || ReactNoopUpdateQueue;
}
ReactComponent.prototype.isReactComponent = {};
/**
* Sets a subset of the state. Always use this to mutate
* state. You should treat `this.state` as immutable.
*
* There is no guarantee that `this.state` will be immediately updated, so
* accessing `this.state` after calling this method may return the old value.
*
* There is no guarantee that calls to `setState` will run synchronously,
* as they may eventually be batched together. You can provide an optional
* callback that will be executed when the call to setState is actually
* completed.
*
* When a function is provided to setState, it will be called at some point in
* the future (not synchronously). It will be called with the up to date
* component arguments (state, props, context). These values can be different
* from this.* because your function may be called after receiveProps but before
* shouldComponentUpdate, and this new state, props, and context will not yet be
* assigned to this.
*
* @param {object|function} partialState Next partial state or function to
* produce next partial state to be merged with current state.
* @param {?function} callback Called after state is updated.
* @final
* @protected
*/
ReactComponent.prototype.setState = function (partialState, callback) {
!((typeof partialState === 'undefined' ? 'undefined' : _typeof(partialState)) === 'object' || typeof partialState === 'function' || partialState == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'setState(...): takes an object of state variables to update or a function which returns an object of state variables.') : _prodInvariant('85') : void 0;
this.updater.enqueueSetState(this, partialState);
if (callback) {
this.updater.enqueueCallback(this, callback, 'setState');
}
};
/**
* Forces an update. This should only be invoked when it is known with
* certainty that we are **not** in a DOM transaction.
*
* You may want to call this when you know that some deeper aspect of the
* component's state has changed but `setState` was not called.
*
* This will not invoke `shouldComponentUpdate`, but it will invoke
* `componentWillUpdate` and `componentDidUpdate`.
*
* @param {?function} callback Called after update is complete.
* @final
* @protected
*/
ReactComponent.prototype.forceUpdate = function (callback) {
this.updater.enqueueForceUpdate(this);
if (callback) {
this.updater.enqueueCallback(this, callback, 'forceUpdate');
}
};
/**
* Dep