diff --git a/demo/dist/main.js b/demo/dist/main.js
index b3f8d295..2dc1046f 100644
--- a/demo/dist/main.js
+++ b/demo/dist/main.js
@@ -7,7 +7,7 @@
exports["reactJsonView"] = factory(require("React"), require("ReactDOM"));
else
root["reactJsonView"] = factory(root["React"], root["ReactDOM"]);
-})(window, function(__WEBPACK_EXTERNAL_MODULE__1__, __WEBPACK_EXTERNAL_MODULE__19__) {
+})(window, function(__WEBPACK_EXTERNAL_MODULE__0__, __WEBPACK_EXTERNAL_MODULE__9__) {
return /******/ (function(modules) { // webpackBootstrap
/******/ // The module cache
/******/ var installedModules = {};
@@ -91,11 +91,17 @@ return /******/ (function(modules) { // webpackBootstrap
/******/
/******/
/******/ // Load entry module and return exports
-/******/ return __webpack_require__(__webpack_require__.s = 66);
+/******/ return __webpack_require__(__webpack_require__.s = 55);
/******/ })
/************************************************************************/
/******/ ([
/* 0 */
+/***/ (function(module, exports) {
+
+module.exports = __WEBPACK_EXTERNAL_MODULE__0__;
+
+/***/ }),
+/* 1 */
/***/ (function(module, exports, __webpack_require__) {
/**
@@ -108,444 +114,12 @@ return /******/ (function(modules) { // webpackBootstrap
if (false) { var throwOnDirectAccess, ReactIs; } else {
// By explicitly using `prop-types` you are opting into new production behavior.
// http://fb.me/prop-types-in-prod
- module.exports = __webpack_require__(71)();
+ module.exports = __webpack_require__(56)();
}
-/***/ }),
-/* 1 */
-/***/ (function(module, exports) {
-
-module.exports = __WEBPACK_EXTERNAL_MODULE__1__;
-
/***/ }),
/* 2 */
-/***/ (function(module, exports, __webpack_require__) {
-
-"use strict";
-
-
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
-
-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; };
-
-exports.default = style;
-
-var _rjvThemes = __webpack_require__(76);
-
-var _styleConstants = __webpack_require__(77);
-
-var _styleConstants2 = _interopRequireDefault(_styleConstants);
-
-var _reactBase16Styling = __webpack_require__(78);
-
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-var colorMap = function colorMap(theme) {
- return {
- backgroundColor: theme.base00,
- ellipsisColor: theme.base09,
- braceColor: theme.base07,
- expandedIcon: theme.base0D,
- collapsedIcon: theme.base0E,
- keyColor: theme.base07,
- arrayKeyColor: theme.base0C,
- objectSize: theme.base04,
- copyToClipboard: theme.base0F,
- copyToClipboardCheck: theme.base0D,
- objectBorder: theme.base02,
- dataTypes: {
- boolean: theme.base0E,
- date: theme.base0D,
- float: theme.base0B,
- function: theme.base0D,
- integer: theme.base0F,
- string: theme.base09,
- nan: theme.base08,
- null: theme.base0A,
- undefined: theme.base05,
- regexp: theme.base0A,
- background: theme.base02
- },
- editVariable: {
- editIcon: theme.base0E,
- cancelIcon: theme.base09,
- removeIcon: theme.base09,
- addIcon: theme.base0E,
- checkIcon: theme.base0E,
- background: theme.base01,
- color: theme.base0A,
- border: theme.base07
- },
- addKeyModal: {
- background: theme.base05,
- border: theme.base04,
- color: theme.base0A,
- labelColor: theme.base01
- },
- validationFailure: {
- background: theme.base09,
- iconColor: theme.base01,
- fontColor: theme.base01
- }
- };
-};
-
-var getDefaultThemeStyling = function getDefaultThemeStyling(theme) {
- var colors = colorMap(theme);
-
- return {
- 'app-container': {
- fontFamily: _styleConstants2.default.globalFontFamily,
- cursor: _styleConstants2.default.globalCursor,
- backgroundColor: colors.backgroundColor,
- position: 'relative'
- },
- ellipsis: {
- display: 'inline-block',
- color: colors.ellipsisColor,
- fontSize: _styleConstants2.default.ellipsisFontSize,
- lineHeight: _styleConstants2.default.ellipsisLineHeight,
- cursor: _styleConstants2.default.ellipsisCursor
- },
- 'brace-row': {
- display: 'inline-block',
- cursor: 'pointer'
- },
- brace: {
- display: 'inline-block',
- cursor: _styleConstants2.default.braceCursor,
- fontWeight: _styleConstants2.default.braceFontWeight,
- color: colors.braceColor
- },
- 'expanded-icon': {
- color: colors.expandedIcon
- },
- 'collapsed-icon': {
- color: colors.collapsedIcon
- },
- colon: {
- display: 'inline-block',
- margin: _styleConstants2.default.keyMargin,
- color: colors.keyColor,
- verticalAlign: 'top'
- },
- objectKeyVal: function objectKeyVal(component, variable_style) {
- return {
- style: _extends({
- paddingTop: _styleConstants2.default.keyValPaddingTop,
- paddingRight: _styleConstants2.default.keyValPaddingRight,
- paddingBottom: _styleConstants2.default.keyValPaddingBottom,
- borderLeft: _styleConstants2.default.keyValBorderLeft + ' ' + colors.objectBorder,
- ':hover': {
- paddingLeft: variable_style.paddingLeft - 1 + 'px',
- borderLeft: _styleConstants2.default.keyValBorderHover + ' ' + colors.objectBorder
- }
- }, variable_style)
- };
- },
- 'object-key-val-no-border': {
- padding: _styleConstants2.default.keyValPadding
- },
- 'pushed-content': {
- marginLeft: _styleConstants2.default.pushedContentMarginLeft
- },
- variableValue: function variableValue(component, variable_style) {
- return {
- style: _extends({
- display: 'inline-block',
- paddingRight: _styleConstants2.default.variableValuePaddingRight,
- position: 'relative'
- }, variable_style)
- };
- },
- 'object-name': {
- display: 'inline-block',
- color: colors.keyColor,
- letterSpacing: _styleConstants2.default.keyLetterSpacing,
- fontStyle: _styleConstants2.default.keyFontStyle,
- verticalAlign: _styleConstants2.default.keyVerticalAlign,
- opacity: _styleConstants2.default.keyOpacity,
- ':hover': {
- opacity: _styleConstants2.default.keyOpacityHover
- }
- },
- 'array-key': {
- display: 'inline-block',
- color: colors.arrayKeyColor,
- letterSpacing: _styleConstants2.default.keyLetterSpacing,
- fontStyle: _styleConstants2.default.keyFontStyle,
- verticalAlign: _styleConstants2.default.keyVerticalAlign,
- opacity: _styleConstants2.default.keyOpacity,
- ':hover': {
- opacity: _styleConstants2.default.keyOpacityHover
- }
- },
- 'object-size': {
- color: colors.objectSize,
- borderRadius: _styleConstants2.default.objectSizeBorderRadius,
- fontStyle: _styleConstants2.default.objectSizeFontStyle,
- margin: _styleConstants2.default.objectSizeMargin,
- cursor: 'default'
- },
- 'data-type-label': {
- fontSize: _styleConstants2.default.dataTypeFontSize,
- marginRight: _styleConstants2.default.dataTypeMarginRight,
- opacity: _styleConstants2.default.datatypeOpacity
- },
- boolean: {
- display: 'inline-block',
- color: colors.dataTypes.boolean
- },
- date: {
- display: 'inline-block',
- color: colors.dataTypes.date
- },
- 'date-value': {
- marginLeft: _styleConstants2.default.dateValueMarginLeft
- },
- float: {
- display: 'inline-block',
- color: colors.dataTypes.float
- },
- function: {
- display: 'inline-block',
- color: colors.dataTypes['function'],
- cursor: 'pointer',
- whiteSpace: 'pre-line'
- },
- 'function-value': {
- fontStyle: 'italic'
- },
- integer: {
- display: 'inline-block',
- color: colors.dataTypes.integer
- },
- string: {
- display: 'inline-block',
- color: colors.dataTypes.string
- },
- nan: {
- display: 'inline-block',
- color: colors.dataTypes.nan,
- fontSize: _styleConstants2.default.nanFontSize,
- fontWeight: _styleConstants2.default.nanFontWeight,
- backgroundColor: colors.dataTypes.background,
- padding: _styleConstants2.default.nanPadding,
- borderRadius: _styleConstants2.default.nanBorderRadius
- },
- null: {
- display: 'inline-block',
- color: colors.dataTypes.null,
- fontSize: _styleConstants2.default.nullFontSize,
- fontWeight: _styleConstants2.default.nullFontWeight,
- backgroundColor: colors.dataTypes.background,
- padding: _styleConstants2.default.nullPadding,
- borderRadius: _styleConstants2.default.nullBorderRadius
- },
- undefined: {
- display: 'inline-block',
- color: colors.dataTypes.undefined,
- fontSize: _styleConstants2.default.undefinedFontSize,
- padding: _styleConstants2.default.undefinedPadding,
- borderRadius: _styleConstants2.default.undefinedBorderRadius,
- backgroundColor: colors.dataTypes.background
- },
- regexp: {
- display: 'inline-block',
- color: colors.dataTypes.regexp
- },
- 'copy-to-clipboard': {
- cursor: _styleConstants2.default.clipboardCursor
- },
- 'copy-icon': {
- color: colors.copyToClipboard,
- fontSize: _styleConstants2.default.iconFontSize,
- marginRight: _styleConstants2.default.iconMarginRight,
- verticalAlign: 'top'
- },
- 'copy-icon-copied': {
- color: colors.copyToClipboardCheck,
- marginLeft: _styleConstants2.default.clipboardCheckMarginLeft
- },
- 'array-group-meta-data': {
- display: 'inline-block',
- padding: _styleConstants2.default.arrayGroupMetaPadding
- },
- 'object-meta-data': {
- display: 'inline-block',
- padding: _styleConstants2.default.metaDataPadding
- },
- 'icon-container': {
- display: 'inline-block',
- width: _styleConstants2.default.iconContainerWidth
- },
- tooltip: {
- padding: _styleConstants2.default.tooltipPadding
- },
- removeVarIcon: {
- verticalAlign: 'top',
- display: 'inline-block',
- color: colors.editVariable.removeIcon,
- cursor: _styleConstants2.default.iconCursor,
- fontSize: _styleConstants2.default.iconFontSize,
- marginRight: _styleConstants2.default.iconMarginRight
- },
- addVarIcon: {
- verticalAlign: 'top',
- display: 'inline-block',
- color: colors.editVariable.addIcon,
- cursor: _styleConstants2.default.iconCursor,
- fontSize: _styleConstants2.default.iconFontSize,
- marginRight: _styleConstants2.default.iconMarginRight
- },
- editVarIcon: {
- verticalAlign: 'top',
- display: 'inline-block',
- color: colors.editVariable.editIcon,
- cursor: _styleConstants2.default.iconCursor,
- fontSize: _styleConstants2.default.iconFontSize,
- marginRight: _styleConstants2.default.iconMarginRight
- },
- 'edit-icon-container': {
- display: 'inline-block',
- verticalAlign: 'top'
- },
- 'check-icon': {
- display: 'inline-block',
- cursor: _styleConstants2.default.iconCursor,
- color: colors.editVariable.checkIcon,
- fontSize: _styleConstants2.default.iconFontSize,
- paddingRight: _styleConstants2.default.iconPaddingRight
- },
- 'cancel-icon': {
- display: 'inline-block',
- cursor: _styleConstants2.default.iconCursor,
- color: colors.editVariable.cancelIcon,
- fontSize: _styleConstants2.default.iconFontSize,
- paddingRight: _styleConstants2.default.iconPaddingRight
- },
- 'edit-input': {
- display: 'inline-block',
- minHeight: _styleConstants2.default.editInputHeight,
- minWidth: _styleConstants2.default.editInputMinWidth,
- borderRadius: _styleConstants2.default.editInputBorderRadius,
- backgroundColor: colors.editVariable.background,
- color: colors.editVariable.color,
- padding: _styleConstants2.default.editInputPadding,
- marginRight: _styleConstants2.default.editInputMarginRight,
- fontFamily: _styleConstants2.default.editInputFontFamily
- },
- 'detected-row': {
- paddingTop: _styleConstants2.default.detectedRowPaddingTop
- },
- 'key-modal-request': {
- position: _styleConstants2.default.addKeyCoverPosition,
- top: _styleConstants2.default.addKeyCoverPositionPx,
- left: _styleConstants2.default.addKeyCoverPositionPx,
- right: _styleConstants2.default.addKeyCoverPositionPx,
- bottom: _styleConstants2.default.addKeyCoverPositionPx,
- backgroundColor: _styleConstants2.default.addKeyCoverBackground
- },
- 'key-modal': {
- width: _styleConstants2.default.addKeyModalWidth,
- backgroundColor: colors.addKeyModal.background,
- marginLeft: _styleConstants2.default.addKeyModalMargin,
- marginRight: _styleConstants2.default.addKeyModalMargin,
- padding: _styleConstants2.default.addKeyModalPadding,
- borderRadius: _styleConstants2.default.addKeyModalRadius,
- marginTop: '15px',
- position: 'relative'
- },
- 'key-modal-label': {
- color: colors.addKeyModal.labelColor,
- marginLeft: '2px',
- marginBottom: '5px',
- fontSize: '11px'
- },
- 'key-modal-input-container': {
- overflow: 'hidden'
- },
- 'key-modal-input': {
- width: '100%',
- padding: '3px 6px',
- fontFamily: 'monospace',
- color: colors.addKeyModal.color,
- border: 'none',
- boxSizing: 'border-box',
- borderRadius: '2px'
- },
- 'key-modal-cancel': {
- backgroundColor: colors.editVariable.removeIcon,
- position: 'absolute',
- top: '0px',
- right: '0px',
- borderRadius: '0px 3px 0px 3px',
- cursor: 'pointer'
- },
- 'key-modal-cancel-icon': {
- color: colors.addKeyModal.labelColor,
- fontSize: _styleConstants2.default.iconFontSize,
- transform: 'rotate(45deg)'
- },
- 'key-modal-submit': {
- color: colors.editVariable.addIcon,
- fontSize: _styleConstants2.default.iconFontSize,
- position: 'absolute',
- right: '2px',
- top: '3px',
- cursor: 'pointer'
- },
- 'function-ellipsis': {
- display: 'inline-block',
- color: colors.ellipsisColor,
- fontSize: _styleConstants2.default.ellipsisFontSize,
- lineHeight: _styleConstants2.default.ellipsisLineHeight,
- cursor: _styleConstants2.default.ellipsisCursor
- },
- 'validation-failure': {
- float: 'right',
- padding: '3px 6px',
- borderRadius: '2px',
- cursor: 'pointer',
- color: colors.validationFailure.fontColor,
- backgroundColor: colors.validationFailure.background
- },
- 'validation-failure-label': {
- marginRight: '6px'
- },
- 'validation-failure-clear': {
- position: 'relative',
- verticalAlign: 'top',
- cursor: 'pointer',
- color: colors.validationFailure.iconColor,
- fontSize: _styleConstants2.default.iconFontSize,
- transform: 'rotate(45deg)'
- }
- };
-};
-
-var getStyle = function getStyle(theme) {
- var rjv_theme = _rjvThemes.rjv_default;
- if (theme === false || theme === 'none') {
- rjv_theme = _rjvThemes.rjv_grey;
- }
-
- return (0, _reactBase16Styling.createStyling)(getDefaultThemeStyling, { defaultBase16: rjv_theme })(theme);
-};
-
-function style(theme, component, args) {
- if (!theme) {
- console.error('theme has not been set');
- }
-
- return getStyle(theme)(component, args);
-}
-
-/***/ }),
-/* 3 */
/***/ (function(module, exports) {
var core = module.exports = { version: '2.6.11' };
@@ -553,12 +127,12 @@ if (typeof __e == 'number') __e = core; // eslint-disable-line no-undef
/***/ }),
-/* 4 */
+/* 3 */
/***/ (function(module, exports, __webpack_require__) {
-var store = __webpack_require__(38)('wks');
-var uid = __webpack_require__(27);
-var Symbol = __webpack_require__(6).Symbol;
+var store = __webpack_require__(31)('wks');
+var uid = __webpack_require__(21);
+var Symbol = __webpack_require__(4).Symbol;
var USE_SYMBOL = typeof Symbol == 'function';
var $exports = module.exports = function (name) {
@@ -570,55 +144,7 @@ $exports.store = store;
/***/ }),
-/* 5 */
-/***/ (function(module, exports, __webpack_require__) {
-
-"use strict";
-
-
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
-exports.toType = toType;
-exports.isTheme = isTheme;
-//returns a string "type" of input object
-function toType(obj) {
- var type = getType(obj);
- // some extra disambiguation for numbers
- if (type === 'number') {
- if (isNaN(obj)) {
- type = 'nan';
- } else if ((obj | 0) != obj) {
- //bitwise OR produces integers
- type = 'float';
- } else {
- type = 'integer';
- }
- }
- return type;
-}
-
-//source: http://stackoverflow.com/questions/7390426/better-way-to-get-type-of-a-javascript-variable/7390612#7390612
-function getType(obj) {
- return {}.toString.call(obj).match(/\s([a-zA-Z]+)/)[1].toLowerCase();
-}
-
-//validation for base-16 themes
-function isTheme(theme) {
- var theme_keys = ['base00', 'base01', 'base02', 'base03', 'base04', 'base05', 'base06', 'base07', 'base08', 'base09', 'base0A', 'base0B', 'base0C', 'base0D', 'base0E', 'base0F'];
- if (toType(theme) === 'object') {
- for (var i = 0; i < theme_keys.length; i++) {
- if (!(theme_keys[i] in theme)) {
- return false;
- }
- }
- return true;
- }
- return false;
-}
-
-/***/ }),
-/* 6 */
+/* 4 */
/***/ (function(module, exports) {
// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028
@@ -630,7 +156,7 @@ if (typeof __g == 'number') __g = global; // eslint-disable-line no-undef
/***/ }),
-/* 7 */
+/* 5 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -730,7 +256,7 @@ function toComment(sourceMap) {
}
/***/ }),
-/* 8 */
+/* 6 */
/***/ (function(module, exports, __webpack_require__) {
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*!
@@ -787,87 +313,17 @@ var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*!
/***/ }),
-/* 9 */
-/***/ (function(module, exports, __webpack_require__) {
-
-"use strict";
-
-
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
-
-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 _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__(1);
-
-var _react2 = _interopRequireDefault(_react);
-
-var _getStyle = __webpack_require__(2);
-
-var _getStyle2 = _interopRequireDefault(_getStyle);
-
-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; }
-
-//theme
-
-
-var _class = function (_React$PureComponent) {
- _inherits(_class, _React$PureComponent);
-
- function _class() {
- _classCallCheck(this, _class);
-
- return _possibleConstructorReturn(this, (_class.__proto__ || Object.getPrototypeOf(_class)).apply(this, arguments));
- }
-
- _createClass(_class, [{
- key: 'render',
- value: function render() {
- var _props = this.props,
- rjvId = _props.rjvId,
- type_name = _props.type_name,
- displayDataTypes = _props.displayDataTypes,
- theme = _props.theme;
-
- if (displayDataTypes) {
- return _react2.default.createElement(
- 'span',
- _extends({
- className: 'data-type-label'
- }, (0, _getStyle2.default)(theme, 'data-type-label')),
- type_name
- );
- }
- return null;
- }
- }]);
-
- return _class;
-}(_react2.default.PureComponent);
-
-exports.default = _class;
-
-/***/ }),
-/* 10 */
+/* 7 */
/***/ (function(module, exports, __webpack_require__) {
// Thank's IE8 for his funny defineProperty
-module.exports = !__webpack_require__(14)(function () {
+module.exports = !__webpack_require__(12)(function () {
return Object.defineProperty({}, 'a', { get: function () { return 7; } }).a != 7;
});
/***/ }),
-/* 11 */
+/* 8 */
/***/ (function(module, exports) {
var hasOwnProperty = {}.hasOwnProperty;
@@ -877,12 +333,18 @@ module.exports = function (it, key) {
/***/ }),
-/* 12 */
+/* 9 */
+/***/ (function(module, exports) {
+
+module.exports = __WEBPACK_EXTERNAL_MODULE__9__;
+
+/***/ }),
+/* 10 */
/***/ (function(module, exports, __webpack_require__) {
-var dP = __webpack_require__(13);
-var createDesc = __webpack_require__(26);
-module.exports = __webpack_require__(10) ? function (object, key, value) {
+var dP = __webpack_require__(11);
+var createDesc = __webpack_require__(20);
+module.exports = __webpack_require__(7) ? function (object, key, value) {
return dP.f(object, key, createDesc(1, value));
} : function (object, key, value) {
object[key] = value;
@@ -891,15 +353,15 @@ module.exports = __webpack_require__(10) ? function (object, key, value) {
/***/ }),
-/* 13 */
+/* 11 */
/***/ (function(module, exports, __webpack_require__) {
-var anObject = __webpack_require__(20);
-var IE8_DOM_DEFINE = __webpack_require__(49);
-var toPrimitive = __webpack_require__(35);
+var anObject = __webpack_require__(14);
+var IE8_DOM_DEFINE = __webpack_require__(40);
+var toPrimitive = __webpack_require__(28);
var dP = Object.defineProperty;
-exports.f = __webpack_require__(10) ? Object.defineProperty : function defineProperty(O, P, Attributes) {
+exports.f = __webpack_require__(7) ? Object.defineProperty : function defineProperty(O, P, Attributes) {
anObject(O);
P = toPrimitive(P, true);
anObject(Attributes);
@@ -913,7 +375,7 @@ exports.f = __webpack_require__(10) ? Object.defineProperty : function definePro
/***/ }),
-/* 14 */
+/* 12 */
/***/ (function(module, exports) {
module.exports = function (exec) {
@@ -926,772 +388,74 @@ module.exports = function (exec) {
/***/ }),
-/* 15 */
+/* 13 */
/***/ (function(module, exports, __webpack_require__) {
// to indexed object, toObject with fallback for non-array-like ES3 strings
-var IObject = __webpack_require__(54);
-var defined = __webpack_require__(34);
+var IObject = __webpack_require__(45);
+var defined = __webpack_require__(27);
module.exports = function (it) {
return IObject(defined(it));
};
/***/ }),
-/* 16 */
+/* 14 */
/***/ (function(module, exports, __webpack_require__) {
-"use strict";
-
-
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
-
-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 _events = __webpack_require__(173);
-
-var _dispatcher = __webpack_require__(17);
-
-var _dispatcher2 = _interopRequireDefault(_dispatcher);
-
-var _util = __webpack_require__(5);
-
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-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); } }
-
-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; }
-
-//store persistent display attributes for objects and arrays
-var ObjectAttributes = function (_EventEmitter) {
- _inherits(ObjectAttributes, _EventEmitter);
-
- function ObjectAttributes() {
- var _ref;
-
- var _temp, _this, _ret;
-
- _classCallCheck(this, ObjectAttributes);
-
- for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {
- args[_key] = arguments[_key];
- }
-
- return _ret = (_temp = (_this = _possibleConstructorReturn(this, (_ref = ObjectAttributes.__proto__ || Object.getPrototypeOf(ObjectAttributes)).call.apply(_ref, [this].concat(args))), _this), _this.objects = {}, _this.set = function (rjvId, name, key, value) {
- if (_this.objects[rjvId] === undefined) {
- _this.objects[rjvId] = {};
- }
- if (_this.objects[rjvId][name] === undefined) {
- _this.objects[rjvId][name] = {};
- }
- _this.objects[rjvId][name][key] = value;
- }, _this.get = function (rjvId, name, key, default_value) {
- if (_this.objects[rjvId] === undefined || _this.objects[rjvId][name] === undefined || _this.objects[rjvId][name][key] == undefined) {
- return default_value;
- }
- return _this.objects[rjvId][name][key];
- }, _this.handleAction = function (action) {
- var rjvId = action.rjvId,
- data = action.data,
- name = action.name;
-
- switch (name) {
- case 'RESET':
- _this.emit('reset-' + rjvId);
- break;
- case 'VARIABLE_UPDATED':
- action.data.updated_src = _this.updateSrc(rjvId, data);
- _this.set(rjvId, 'action', 'variable-update', _extends({}, data, { type: 'variable-edited' }));
- _this.emit('variable-update-' + rjvId);
- break;
- case 'VARIABLE_REMOVED':
- action.data.updated_src = _this.updateSrc(rjvId, data);
- _this.set(rjvId, 'action', 'variable-update', _extends({}, data, { type: 'variable-removed' }));
- _this.emit('variable-update-' + rjvId);
- break;
- case 'VARIABLE_ADDED':
- action.data.updated_src = _this.updateSrc(rjvId, data);
- _this.set(rjvId, 'action', 'variable-update', _extends({}, data, { type: 'variable-added' }));
- _this.emit('variable-update-' + rjvId);
- break;
- case 'ADD_VARIABLE_KEY_REQUEST':
- _this.set(rjvId, 'action', 'new-key-request', data);
- _this.emit('add-key-request-' + rjvId);
- break;
- }
- }, _this.updateSrc = function (rjvId, request) {
- var name = request.name,
- namespace = request.namespace,
- new_value = request.new_value,
- existing_value = request.existing_value,
- variable_removed = request.variable_removed;
-
-
- namespace.shift();
-
- //deepy copy src
- var src = _this.get(rjvId, 'global', 'src');
- //deep copy of src variable
- var updated_src = _this.deepCopy(src, [].concat(_toConsumableArray(namespace)));
+var isObject = __webpack_require__(15);
+module.exports = function (it) {
+ if (!isObject(it)) throw TypeError(it + ' is not an object!');
+ return it;
+};
- //point at current index
- var walk = updated_src;
- var _iteratorNormalCompletion = true;
- var _didIteratorError = false;
- var _iteratorError = undefined;
- try {
- for (var _iterator = namespace[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
- var idx = _step.value;
+/***/ }),
+/* 15 */
+/***/ (function(module, exports) {
- walk = walk[idx];
- }
- } catch (err) {
- _didIteratorError = true;
- _iteratorError = err;
- } finally {
- try {
- if (!_iteratorNormalCompletion && _iterator.return) {
- _iterator.return();
- }
- } finally {
- if (_didIteratorError) {
- throw _iteratorError;
- }
- }
- }
+module.exports = function (it) {
+ return typeof it === 'object' ? it !== null : typeof it === 'function';
+};
- if (variable_removed) {
- if ((0, _util.toType)(walk) == 'array') {
- walk.splice(name, 1);
- } else {
- delete walk[name];
- }
- } else {
- //update copied variable at specified namespace
- if (name !== null) {
- walk[name] = new_value;
- } else {
- updated_src = new_value;
- }
- }
- _this.set(rjvId, 'global', 'src', updated_src);
-
- return updated_src;
- }, _this.deepCopy = function (src, copy_namespace) {
- var type = (0, _util.toType)(src);
- var result = void 0;
- var idx = copy_namespace.shift();
- if (type == 'array') {
- result = [].concat(_toConsumableArray(src));
- } else if (type == 'object') {
- result = _extends({}, src);
- }
- if (idx !== undefined) {
- result[idx] = _this.deepCopy(src[idx], copy_namespace);
- }
- return result;
- }, _temp), _possibleConstructorReturn(_this, _ret);
- }
+/***/ }),
+/* 16 */
+/***/ (function(module, exports) {
- return ObjectAttributes;
-}(_events.EventEmitter);
+module.exports = {};
-var attributeStore = new ObjectAttributes();
-_dispatcher2.default.register(attributeStore.handleAction.bind(attributeStore));
-exports.default = attributeStore;
/***/ }),
/* 17 */
/***/ (function(module, exports, __webpack_require__) {
-"use strict";
-
-
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
+// 19.1.2.14 / 15.2.3.14 Object.keys(O)
+var $keys = __webpack_require__(44);
+var enumBugKeys = __webpack_require__(32);
-var _flux = __webpack_require__(174);
+module.exports = Object.keys || function keys(O) {
+ return $keys(O, enumBugKeys);
+};
-var dispatcher = new _flux.Dispatcher();
-exports.default = dispatcher;
/***/ }),
/* 18 */
-/***/ (function(module, exports, __webpack_require__) {
-
-"use strict";
-
-
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
-exports.CheckCircle = exports.Edit = exports.Add = exports.AddCircle = exports.RemoveCircle = exports.Clippy = exports.ArrowDown = exports.ArrowRight = exports.SquarePlus = exports.SquareMinus = exports.CirclePlus = exports.CircleMinus = undefined;
-
-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 _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__(1);
-
-var _react2 = _interopRequireDefault(_react);
-
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-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 DEFAULT_WIDTH = 24;
-var DEFAULT_HEIGHT = 24;
-var DEFAULT_COLOR = '#000000';
-
-var CircleMinus = exports.CircleMinus = function (_React$PureComponent) {
- _inherits(CircleMinus, _React$PureComponent);
-
- function CircleMinus() {
- _classCallCheck(this, CircleMinus);
+/***/ (function(module, exports) {
- return _possibleConstructorReturn(this, (CircleMinus.__proto__ || Object.getPrototypeOf(CircleMinus)).apply(this, arguments));
- }
+module.exports = true;
- _createClass(CircleMinus, [{
- key: 'render',
- value: function render() {
- var props = this.props;
- var style = props.style,
- rest = _objectWithoutProperties(props, ['style']);
+/***/ }),
+/* 19 */
+/***/ (function(module, exports, __webpack_require__) {
- return _react2.default.createElement(
- 'span',
- rest,
- _react2.default.createElement(
- 'svg',
- _extends({}, getIconStyle(style), {
- viewBox: '0 0 24 24',
- fill: 'currentColor',
- preserveAspectRatio: 'xMidYMid meet'
- }),
- _react2.default.createElement('path', { d: 'M12,20C7.59,20 4,16.41 4,12C4,7.59 7.59,4 12,4C16.41,4 20,7.59 20,12C20,16.41 16.41,20 12,20M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2M7,13H17V11H7' })
- )
- );
- }
- }]);
-
- return CircleMinus;
-}(_react2.default.PureComponent);
-
-var CirclePlus = exports.CirclePlus = function (_React$PureComponent2) {
- _inherits(CirclePlus, _React$PureComponent2);
-
- function CirclePlus() {
- _classCallCheck(this, CirclePlus);
-
- return _possibleConstructorReturn(this, (CirclePlus.__proto__ || Object.getPrototypeOf(CirclePlus)).apply(this, arguments));
- }
-
- _createClass(CirclePlus, [{
- key: 'render',
- value: function render() {
- var props = this.props;
-
- var style = props.style,
- rest = _objectWithoutProperties(props, ['style']);
-
- return _react2.default.createElement(
- 'span',
- rest,
- _react2.default.createElement(
- 'svg',
- _extends({}, getIconStyle(style), {
- viewBox: '0 0 24 24',
- fill: 'currentColor',
- preserveAspectRatio: 'xMidYMid meet'
- }),
- _react2.default.createElement('path', { d: 'M12,20C7.59,20 4,16.41 4,12C4,7.59 7.59,4 12,4C16.41,4 20,7.59 20,12C20,16.41 16.41,20 12,20M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2M13,7H11V11H7V13H11V17H13V13H17V11H13V7Z' })
- )
- );
- }
- }]);
-
- return CirclePlus;
-}(_react2.default.PureComponent);
-
-var SquareMinus = exports.SquareMinus = function (_React$PureComponent3) {
- _inherits(SquareMinus, _React$PureComponent3);
-
- function SquareMinus() {
- _classCallCheck(this, SquareMinus);
-
- return _possibleConstructorReturn(this, (SquareMinus.__proto__ || Object.getPrototypeOf(SquareMinus)).apply(this, arguments));
- }
-
- _createClass(SquareMinus, [{
- key: 'render',
- value: function render() {
- var props = this.props;
-
- var style = props.style,
- rest = _objectWithoutProperties(props, ['style']);
-
- var svgStyle = getIconStyle(style).style;
-
- return _react2.default.createElement(
- 'span',
- rest,
- _react2.default.createElement(
- 'svg',
- { fill: svgStyle.color,
- width: svgStyle.height, height: svgStyle.width,
- style: svgStyle,
- viewBox: '0 0 1792 1792' },
- _react2.default.createElement('path', { d: 'M1344 800v64q0 14-9 23t-23 9h-832q-14 0-23-9t-9-23v-64q0-14 9-23t23-9h832q14 0 23 9t9 23zm128 448v-832q0-66-47-113t-113-47h-832q-66 0-113 47t-47 113v832q0 66 47 113t113 47h832q66 0 113-47t47-113zm128-832v832q0 119-84.5 203.5t-203.5 84.5h-832q-119 0-203.5-84.5t-84.5-203.5v-832q0-119 84.5-203.5t203.5-84.5h832q119 0 203.5 84.5t84.5 203.5z' })
- )
- );
- }
- }]);
-
- return SquareMinus;
-}(_react2.default.PureComponent);
-
-var SquarePlus = exports.SquarePlus = function (_React$PureComponent4) {
- _inherits(SquarePlus, _React$PureComponent4);
-
- function SquarePlus() {
- _classCallCheck(this, SquarePlus);
-
- return _possibleConstructorReturn(this, (SquarePlus.__proto__ || Object.getPrototypeOf(SquarePlus)).apply(this, arguments));
- }
-
- _createClass(SquarePlus, [{
- key: 'render',
- value: function render() {
- var props = this.props;
-
- var style = props.style,
- rest = _objectWithoutProperties(props, ['style']);
-
- var svgStyle = getIconStyle(style).style;
-
- return _react2.default.createElement(
- 'span',
- rest,
- _react2.default.createElement(
- 'svg',
- { fill: svgStyle.color,
- width: svgStyle.height, height: svgStyle.width,
- style: svgStyle,
- viewBox: '0 0 1792 1792' },
- _react2.default.createElement('path', { d: 'M1344 800v64q0 14-9 23t-23 9h-352v352q0 14-9 23t-23 9h-64q-14 0-23-9t-9-23v-352h-352q-14 0-23-9t-9-23v-64q0-14 9-23t23-9h352v-352q0-14 9-23t23-9h64q14 0 23 9t9 23v352h352q14 0 23 9t9 23zm128 448v-832q0-66-47-113t-113-47h-832q-66 0-113 47t-47 113v832q0 66 47 113t113 47h832q66 0 113-47t47-113zm128-832v832q0 119-84.5 203.5t-203.5 84.5h-832q-119 0-203.5-84.5t-84.5-203.5v-832q0-119 84.5-203.5t203.5-84.5h832q119 0 203.5 84.5t84.5 203.5z' })
- )
- );
- }
- }]);
-
- return SquarePlus;
-}(_react2.default.PureComponent);
-
-var ArrowRight = exports.ArrowRight = function (_React$PureComponent5) {
- _inherits(ArrowRight, _React$PureComponent5);
-
- function ArrowRight() {
- _classCallCheck(this, ArrowRight);
-
- return _possibleConstructorReturn(this, (ArrowRight.__proto__ || Object.getPrototypeOf(ArrowRight)).apply(this, arguments));
- }
-
- _createClass(ArrowRight, [{
- key: 'render',
- value: function render() {
- var props = this.props;
-
- var style = props.style,
- rest = _objectWithoutProperties(props, ['style']);
-
- return _react2.default.createElement(
- 'span',
- rest,
- _react2.default.createElement(
- 'svg',
- {
- style: _extends({}, getIconStyle(style).style, { paddingLeft: '2px', verticalAlign: 'top' }),
- viewBox: '0 0 15 15',
- fill: 'currentColor'
- },
- _react2.default.createElement('path', { d: 'M0 14l6-6-6-6z' })
- )
- );
- }
- }]);
-
- return ArrowRight;
-}(_react2.default.PureComponent);
-
-var ArrowDown = exports.ArrowDown = function (_React$PureComponent6) {
- _inherits(ArrowDown, _React$PureComponent6);
-
- function ArrowDown() {
- _classCallCheck(this, ArrowDown);
-
- return _possibleConstructorReturn(this, (ArrowDown.__proto__ || Object.getPrototypeOf(ArrowDown)).apply(this, arguments));
- }
-
- _createClass(ArrowDown, [{
- key: 'render',
- value: function render() {
- var props = this.props;
-
- var style = props.style,
- rest = _objectWithoutProperties(props, ['style']);
-
- return _react2.default.createElement(
- 'span',
- rest,
- _react2.default.createElement(
- 'svg',
- {
- style: _extends({}, getIconStyle(style).style, { paddingLeft: '2px', verticalAlign: 'top' }),
- viewBox: '0 0 15 15',
- fill: 'currentColor'
- },
- _react2.default.createElement('path', { d: 'M0 5l6 6 6-6z' })
- )
- );
- }
- }]);
-
- return ArrowDown;
-}(_react2.default.PureComponent);
-
-var Clippy = exports.Clippy = function (_React$PureComponent7) {
- _inherits(Clippy, _React$PureComponent7);
-
- function Clippy() {
- _classCallCheck(this, Clippy);
-
- return _possibleConstructorReturn(this, (Clippy.__proto__ || Object.getPrototypeOf(Clippy)).apply(this, arguments));
- }
-
- _createClass(Clippy, [{
- key: 'render',
- value: function render() {
- var props = this.props;
-
- var style = props.style,
- rest = _objectWithoutProperties(props, ['style']);
-
- return _react2.default.createElement(
- 'span',
- rest,
- _react2.default.createElement(
- 'svg',
- _extends({}, getIconStyle(style), {
- viewBox: '0 0 40 40',
- fill: 'currentColor',
- preserveAspectRatio: 'xMidYMid meet'
- }),
- _react2.default.createElement(
- 'g',
- null,
- _react2.default.createElement('path', { d: 'm30 35h-25v-22.5h25v7.5h2.5v-12.5c0-1.4-1.1-2.5-2.5-2.5h-7.5c0-2.8-2.2-5-5-5s-5 2.2-5 5h-7.5c-1.4 0-2.5 1.1-2.5 2.5v27.5c0 1.4 1.1 2.5 2.5 2.5h25c1.4 0 2.5-1.1 2.5-2.5v-5h-2.5v5z m-20-27.5h2.5s2.5-1.1 2.5-2.5 1.1-2.5 2.5-2.5 2.5 1.1 2.5 2.5 1.3 2.5 2.5 2.5h2.5s2.5 1.1 2.5 2.5h-20c0-1.5 1.1-2.5 2.5-2.5z m-2.5 20h5v-2.5h-5v2.5z m17.5-5v-5l-10 7.5 10 7.5v-5h12.5v-5h-12.5z m-17.5 10h7.5v-2.5h-7.5v2.5z m12.5-17.5h-12.5v2.5h12.5v-2.5z m-7.5 5h-5v2.5h5v-2.5z' })
- )
- )
- );
- }
- }]);
-
- return Clippy;
-}(_react2.default.PureComponent);
-
-var RemoveCircle = exports.RemoveCircle = function (_React$PureComponent8) {
- _inherits(RemoveCircle, _React$PureComponent8);
-
- function RemoveCircle() {
- _classCallCheck(this, RemoveCircle);
-
- return _possibleConstructorReturn(this, (RemoveCircle.__proto__ || Object.getPrototypeOf(RemoveCircle)).apply(this, arguments));
- }
-
- _createClass(RemoveCircle, [{
- key: 'render',
- value: function render() {
- var props = this.props;
-
- var style = props.style,
- rest = _objectWithoutProperties(props, ['style']);
-
- return _react2.default.createElement(
- 'span',
- rest,
- _react2.default.createElement(
- 'svg',
- _extends({}, getIconStyle(style), {
- viewBox: '0 0 40 40',
- fill: 'currentColor',
- preserveAspectRatio: 'xMidYMid meet'
- }),
- _react2.default.createElement(
- 'g',
- null,
- _react2.default.createElement('path', { d: 'm28.6 25q0-0.5-0.4-1l-4-4 4-4q0.4-0.5 0.4-1 0-0.6-0.4-1.1l-2-2q-0.4-0.4-1-0.4-0.6 0-1 0.4l-4.1 4.1-4-4.1q-0.4-0.4-1-0.4-0.6 0-1 0.4l-2 2q-0.5 0.5-0.5 1.1 0 0.5 0.5 1l4 4-4 4q-0.5 0.5-0.5 1 0 0.7 0.5 1.1l2 2q0.4 0.4 1 0.4 0.6 0 1-0.4l4-4.1 4.1 4.1q0.4 0.4 1 0.4 0.6 0 1-0.4l2-2q0.4-0.4 0.4-1z m8.7-5q0 4.7-2.3 8.6t-6.3 6.2-8.6 2.3-8.6-2.3-6.2-6.2-2.3-8.6 2.3-8.6 6.2-6.2 8.6-2.3 8.6 2.3 6.3 6.2 2.3 8.6z' })
- )
- )
- );
- }
- }]);
-
- return RemoveCircle;
-}(_react2.default.PureComponent);
-
-var AddCircle = exports.AddCircle = function (_React$PureComponent9) {
- _inherits(AddCircle, _React$PureComponent9);
-
- function AddCircle() {
- _classCallCheck(this, AddCircle);
-
- return _possibleConstructorReturn(this, (AddCircle.__proto__ || Object.getPrototypeOf(AddCircle)).apply(this, arguments));
- }
-
- _createClass(AddCircle, [{
- key: 'render',
- value: function render() {
- var props = this.props;
-
- var style = props.style,
- rest = _objectWithoutProperties(props, ['style']);
-
- return _react2.default.createElement(
- 'span',
- rest,
- _react2.default.createElement(
- 'svg',
- _extends({}, getIconStyle(style), {
- viewBox: '0 0 40 40',
- fill: 'currentColor',
- preserveAspectRatio: 'xMidYMid meet'
- }),
- _react2.default.createElement(
- 'g',
- null,
- _react2.default.createElement('path', { d: 'm30.1 21.4v-2.8q0-0.6-0.4-1t-1-0.5h-5.7v-5.7q0-0.6-0.4-1t-1-0.4h-2.9q-0.6 0-1 0.4t-0.4 1v5.7h-5.7q-0.6 0-1 0.5t-0.5 1v2.8q0 0.6 0.5 1t1 0.5h5.7v5.7q0 0.5 0.4 1t1 0.4h2.9q0.6 0 1-0.4t0.4-1v-5.7h5.7q0.6 0 1-0.5t0.4-1z m7.2-1.4q0 4.7-2.3 8.6t-6.3 6.2-8.6 2.3-8.6-2.3-6.2-6.2-2.3-8.6 2.3-8.6 6.2-6.2 8.6-2.3 8.6 2.3 6.3 6.2 2.3 8.6z' })
- )
- )
- );
- }
- }]);
-
- return AddCircle;
-}(_react2.default.PureComponent);
-
-var Add = exports.Add = function (_React$PureComponent10) {
- _inherits(Add, _React$PureComponent10);
-
- function Add() {
- _classCallCheck(this, Add);
-
- return _possibleConstructorReturn(this, (Add.__proto__ || Object.getPrototypeOf(Add)).apply(this, arguments));
- }
-
- _createClass(Add, [{
- key: 'render',
- value: function render() {
- var props = this.props;
-
- var style = props.style,
- rest = _objectWithoutProperties(props, ['style']);
-
- return _react2.default.createElement(
- 'span',
- rest,
- _react2.default.createElement(
- 'svg',
- _extends({}, getIconStyle(style), {
- viewBox: '0 0 40 40',
- fill: 'currentColor',
- preserveAspectRatio: 'xMidYMid meet'
- }),
- _react2.default.createElement(
- 'g',
- null,
- _react2.default.createElement('path', { d: 'm31.6 21.6h-10v10h-3.2v-10h-10v-3.2h10v-10h3.2v10h10v3.2z' })
- )
- )
- );
- }
- }]);
-
- return Add;
-}(_react2.default.PureComponent);
-
-var Edit = exports.Edit = function (_React$PureComponent11) {
- _inherits(Edit, _React$PureComponent11);
-
- function Edit() {
- _classCallCheck(this, Edit);
-
- return _possibleConstructorReturn(this, (Edit.__proto__ || Object.getPrototypeOf(Edit)).apply(this, arguments));
- }
-
- _createClass(Edit, [{
- key: 'render',
- value: function render() {
- var props = this.props;
-
- var style = props.style,
- rest = _objectWithoutProperties(props, ['style']);
-
- return _react2.default.createElement(
- 'span',
- rest,
- _react2.default.createElement(
- 'svg',
- _extends({}, getIconStyle(style), {
- viewBox: '0 0 40 40',
- fill: 'currentColor',
- preserveAspectRatio: 'xMidYMid meet'
- }),
- _react2.default.createElement(
- 'g',
- null,
- _react2.default.createElement('path', { d: 'm19.8 26.4l2.6-2.6-3.4-3.4-2.6 2.6v1.3h2.2v2.1h1.2z m9.8-16q-0.3-0.4-0.7 0l-7.8 7.8q-0.4 0.4 0 0.7t0.7 0l7.8-7.8q0.4-0.4 0-0.7z m1.8 13.2v4.3q0 2.6-1.9 4.5t-4.5 1.9h-18.6q-2.6 0-4.5-1.9t-1.9-4.5v-18.6q0-2.7 1.9-4.6t4.5-1.8h18.6q1.4 0 2.6 0.5 0.3 0.2 0.4 0.5 0.1 0.4-0.2 0.7l-1.1 1.1q-0.3 0.3-0.7 0.1-0.5-0.1-1-0.1h-18.6q-1.4 0-2.5 1.1t-1 2.5v18.6q0 1.4 1 2.5t2.5 1h18.6q1.5 0 2.5-1t1.1-2.5v-2.9q0-0.2 0.2-0.4l1.4-1.5q0.3-0.3 0.8-0.1t0.4 0.6z m-2.1-16.5l6.4 6.5-15 15h-6.4v-6.5z m9.9 3l-2.1 2-6.4-6.4 2.1-2q0.6-0.7 1.5-0.7t1.5 0.7l3.4 3.4q0.6 0.6 0.6 1.5t-0.6 1.5z' })
- )
- )
- );
- }
- }]);
-
- return Edit;
-}(_react2.default.PureComponent);
-
-var CheckCircle = exports.CheckCircle = function (_React$PureComponent12) {
- _inherits(CheckCircle, _React$PureComponent12);
-
- function CheckCircle() {
- _classCallCheck(this, CheckCircle);
-
- return _possibleConstructorReturn(this, (CheckCircle.__proto__ || Object.getPrototypeOf(CheckCircle)).apply(this, arguments));
- }
-
- _createClass(CheckCircle, [{
- key: 'render',
- value: function render() {
- var props = this.props;
-
- var style = props.style,
- rest = _objectWithoutProperties(props, ['style']);
-
- return _react2.default.createElement(
- 'span',
- rest,
- _react2.default.createElement(
- 'svg',
- _extends({}, getIconStyle(style), {
- viewBox: '0 0 40 40',
- fill: 'currentColor',
- preserveAspectRatio: 'xMidYMid meet'
- }),
- _react2.default.createElement(
- 'g',
- null,
- _react2.default.createElement('path', { d: 'm31.7 16.4q0-0.6-0.4-1l-2.1-2.1q-0.4-0.4-1-0.4t-1 0.4l-9.1 9.1-5-5q-0.5-0.4-1-0.4t-1 0.4l-2.1 2q-0.4 0.4-0.4 1 0 0.6 0.4 1l8.1 8.1q0.4 0.4 1 0.4 0.6 0 1-0.4l12.2-12.1q0.4-0.4 0.4-1z m5.6 3.6q0 4.7-2.3 8.6t-6.3 6.2-8.6 2.3-8.6-2.3-6.2-6.2-2.3-8.6 2.3-8.6 6.2-6.2 8.6-2.3 8.6 2.3 6.3 6.2 2.3 8.6z' })
- )
- )
- );
- }
- }]);
-
- return CheckCircle;
-}(_react2.default.PureComponent);
-
-function getIconStyle(style) {
- if (!style) {
- style = {};
- }
- return { style: _extends({
- verticalAlign: 'middle'
- }, style, {
- color: style.color ? style.color : DEFAULT_COLOR,
- height: '1em',
- width: '1em'
- }) };
-}
-
-/***/ }),
-/* 19 */
-/***/ (function(module, exports) {
-
-module.exports = __WEBPACK_EXTERNAL_MODULE__19__;
-
-/***/ }),
-/* 20 */
-/***/ (function(module, exports, __webpack_require__) {
-
-var isObject = __webpack_require__(21);
-module.exports = function (it) {
- if (!isObject(it)) throw TypeError(it + ' is not an object!');
- return it;
-};
-
-
-/***/ }),
-/* 21 */
-/***/ (function(module, exports) {
-
-module.exports = function (it) {
- return typeof it === 'object' ? it !== null : typeof it === 'function';
-};
-
-
-/***/ }),
-/* 22 */
-/***/ (function(module, exports) {
-
-module.exports = {};
-
-
-/***/ }),
-/* 23 */
-/***/ (function(module, exports, __webpack_require__) {
-
-// 19.1.2.14 / 15.2.3.14 Object.keys(O)
-var $keys = __webpack_require__(53);
-var enumBugKeys = __webpack_require__(39);
-
-module.exports = Object.keys || function keys(O) {
- return $keys(O, enumBugKeys);
-};
-
-
-/***/ }),
-/* 24 */
-/***/ (function(module, exports) {
-
-module.exports = true;
-
-
-/***/ }),
-/* 25 */
-/***/ (function(module, exports, __webpack_require__) {
-
-var global = __webpack_require__(6);
-var core = __webpack_require__(3);
-var ctx = __webpack_require__(83);
-var hide = __webpack_require__(12);
-var has = __webpack_require__(11);
-var PROTOTYPE = 'prototype';
+var global = __webpack_require__(4);
+var core = __webpack_require__(2);
+var ctx = __webpack_require__(62);
+var hide = __webpack_require__(10);
+var has = __webpack_require__(8);
+var PROTOTYPE = 'prototype';
var $export = function (type, name, source) {
var IS_FORCED = type & $export.F;
@@ -1751,7 +515,7 @@ module.exports = $export;
/***/ }),
-/* 26 */
+/* 20 */
/***/ (function(module, exports) {
module.exports = function (bitmap, value) {
@@ -1765,7 +529,7 @@ module.exports = function (bitmap, value) {
/***/ }),
-/* 27 */
+/* 21 */
/***/ (function(module, exports) {
var id = 0;
@@ -1776,25 +540,25 @@ module.exports = function (key) {
/***/ }),
-/* 28 */
+/* 22 */
/***/ (function(module, exports, __webpack_require__) {
// 7.1.13 ToObject(argument)
-var defined = __webpack_require__(34);
+var defined = __webpack_require__(27);
module.exports = function (it) {
return Object(defined(it));
};
/***/ }),
-/* 29 */
+/* 23 */
/***/ (function(module, exports) {
exports.f = {}.propertyIsEnumerable;
/***/ }),
-/* 30 */
+/* 24 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -1973,7 +737,7 @@ function applyToTag(style, options, obj) {
style.removeAttribute('media');
}
- if (sourceMap && btoa) {
+ if (sourceMap && typeof btoa !== 'undefined') {
css += "\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))), " */");
} // For old IE
@@ -2069,400 +833,15 @@ module.exports = function (list, options) {
};
/***/ }),
-/* 31 */
-/***/ (function(module, exports, __webpack_require__) {
-
-"use strict";
-
-
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
-
-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 _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__(1);
-
-var _react2 = _interopRequireDefault(_react);
-
-var _reactLifecyclesCompat = __webpack_require__(46);
-
-var _util = __webpack_require__(5);
-
-var _DataTypes = __webpack_require__(47);
-
-var _VariableEditor = __webpack_require__(183);
-
-var _VariableEditor2 = _interopRequireDefault(_VariableEditor);
-
-var _VariableMeta = __webpack_require__(61);
-
-var _VariableMeta2 = _interopRequireDefault(_VariableMeta);
-
-var _ArrayGroup = __webpack_require__(62);
-
-var _ArrayGroup2 = _interopRequireDefault(_ArrayGroup);
-
-var _ObjectName = __webpack_require__(63);
-
-var _ObjectName2 = _interopRequireDefault(_ObjectName);
-
-var _ObjectAttributes = __webpack_require__(16);
-
-var _ObjectAttributes2 = _interopRequireDefault(_ObjectAttributes);
-
-var _ToggleIcons = __webpack_require__(64);
-
-var _getStyle = __webpack_require__(2);
-
-var _getStyle2 = _interopRequireDefault(_getStyle);
-
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-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; }
-
-//data type components
-
-
-//attribute store
-
-
-//icons
-
-
-//theme
-
-
-//increment 1 with each nested object & array
-var DEPTH_INCREMENT = 1;
-//single indent is 5px
-var SINGLE_INDENT = 5;
-
-var RjvObject = function (_React$PureComponent) {
- _inherits(RjvObject, _React$PureComponent);
-
- function RjvObject(props) {
- _classCallCheck(this, RjvObject);
-
- var _this = _possibleConstructorReturn(this, (RjvObject.__proto__ || Object.getPrototypeOf(RjvObject)).call(this, props));
-
- _initialiseProps.call(_this);
-
- var state = RjvObject.getState(props);
- _this.state = _extends({}, state, {
- prevProps: {}
- });
- return _this;
- }
-
- _createClass(RjvObject, [{
- key: 'getBraceStart',
- value: function getBraceStart(object_type, expanded) {
- var _this2 = this;
-
- var _props = this.props,
- src = _props.src,
- theme = _props.theme,
- iconStyle = _props.iconStyle,
- parent_type = _props.parent_type;
-
-
- if (parent_type === 'array_group') {
- return _react2.default.createElement(
- 'span',
- null,
- _react2.default.createElement(
- 'span',
- (0, _getStyle2.default)(theme, 'brace'),
- object_type === 'array' ? '[' : '{'
- ),
- expanded ? this.getObjectMetaData(src) : null
- );
- }
-
- var IconComponent = expanded ? _ToggleIcons.ExpandedIcon : _ToggleIcons.CollapsedIcon;
-
- return _react2.default.createElement(
- 'span',
- null,
- _react2.default.createElement(
- 'span',
- _extends({
- onClick: function onClick(e) {
- _this2.toggleCollapsed();
- }
- }, (0, _getStyle2.default)(theme, 'brace-row')),
- _react2.default.createElement(
- 'div',
- _extends({
- className: 'icon-container'
- }, (0, _getStyle2.default)(theme, 'icon-container')),
- _react2.default.createElement(IconComponent, { theme: theme, iconStyle: iconStyle })
- ),
- _react2.default.createElement(_ObjectName2.default, this.props),
- _react2.default.createElement(
- 'span',
- (0, _getStyle2.default)(theme, 'brace'),
- object_type === 'array' ? '[' : '{'
- )
- ),
- expanded ? this.getObjectMetaData(src) : null
- );
- }
- }, {
- key: 'render',
- value: function render() {
- var _this3 = this;
-
- // `indentWidth` and `collapsed` props will
- // perpetuate to children via `...rest`
- var _props2 = this.props,
- depth = _props2.depth,
- src = _props2.src,
- namespace = _props2.namespace,
- name = _props2.name,
- type = _props2.type,
- parent_type = _props2.parent_type,
- theme = _props2.theme,
- jsvRoot = _props2.jsvRoot,
- iconStyle = _props2.iconStyle,
- rest = _objectWithoutProperties(_props2, ['depth', 'src', 'namespace', 'name', 'type', 'parent_type', 'theme', 'jsvRoot', 'iconStyle']);
-
- var _state = this.state,
- object_type = _state.object_type,
- expanded = _state.expanded;
-
-
- var styles = {};
- if (!jsvRoot && parent_type !== 'array_group') {
- styles.paddingLeft = this.props.indentWidth * SINGLE_INDENT;
- } else if (parent_type === 'array_group') {
- styles.borderLeft = 0;
- styles.display = 'inline';
- }
-
- return _react2.default.createElement(
- 'div',
- _extends({
- className: 'object-key-val',
- onMouseEnter: function onMouseEnter() {
- return _this3.setState(_extends({}, _this3.state, { hovered: true }));
- },
- onMouseLeave: function onMouseLeave() {
- return _this3.setState(_extends({}, _this3.state, { hovered: false }));
- }
- }, (0, _getStyle2.default)(theme, jsvRoot ? 'jsv-root' : 'objectKeyVal', styles)),
- this.getBraceStart(object_type, expanded),
- expanded ? this.getObjectContent(depth, src, _extends({
- theme: theme,
- iconStyle: iconStyle
- }, rest)) : this.getEllipsis(),
- _react2.default.createElement(
- 'span',
- { className: 'brace-row' },
- _react2.default.createElement(
- 'span',
- {
- style: _extends({}, (0, _getStyle2.default)(theme, 'brace').style, {
- paddingLeft: expanded ? '3px' : '0px'
- })
- },
- object_type === 'array' ? ']' : '}'
- ),
- expanded ? null : this.getObjectMetaData(src)
- )
- );
- }
- }], [{
- key: 'getDerivedStateFromProps',
- value: function getDerivedStateFromProps(nextProps, prevState) {
- var prevProps = prevState.prevProps;
-
- if (nextProps.src !== prevProps.src || nextProps.collapsed !== prevProps.collapsed || nextProps.name !== prevProps.name || nextProps.namespace !== prevProps.namespace || nextProps.rjvId !== prevProps.rjvId) {
- var newState = RjvObject.getState(nextProps);
- return _extends({}, newState, {
- prevProps: nextProps
- });
- }
- return null;
- }
- }]);
-
- return RjvObject;
-}(_react2.default.PureComponent);
-
-//just store name, value and type with a variable
-
-
-RjvObject.getState = function (props) {
- var size = Object.keys(props.src).length;
- var expanded = (props.collapsed === false || props.collapsed !== true && props.collapsed > props.depth) && (!props.shouldCollapse || props.shouldCollapse({
- name: props.name,
- src: props.src,
- type: (0, _util.toType)(props.src),
- namespace: props.namespace
- }) === false) &&
- //initialize closed if object has no items
- size !== 0;
- var state = {
- expanded: _ObjectAttributes2.default.get(props.rjvId, props.namespace, 'expanded', expanded),
- object_type: props.type === 'array' ? 'array' : 'object',
- parent_type: props.type === 'array' ? 'array' : 'object',
- size: size,
- hovered: false
- };
- return state;
-};
-
-var _initialiseProps = function _initialiseProps() {
- var _this4 = this;
-
- this.toggleCollapsed = function () {
- _this4.setState({
- expanded: !_this4.state.expanded
- }, function () {
- _ObjectAttributes2.default.set(_this4.props.rjvId, _this4.props.namespace, 'expanded', _this4.state.expanded);
- });
- };
-
- this.getObjectContent = function (depth, src, props) {
- return _react2.default.createElement(
- 'div',
- { className: 'pushed-content object-container' },
- _react2.default.createElement(
- 'div',
- _extends({
- className: 'object-content'
- }, (0, _getStyle2.default)(_this4.props.theme, 'pushed-content')),
- _this4.renderObjectContents(src, props)
- )
- );
- };
-
- this.getEllipsis = function () {
- var size = _this4.state.size;
-
-
- if (size === 0) {
- //don't render an ellipsis when an object has no items
- return null;
- } else {
- return _react2.default.createElement(
- 'div',
- _extends({}, (0, _getStyle2.default)(_this4.props.theme, 'ellipsis'), {
- className: 'node-ellipsis',
- onClick: _this4.toggleCollapsed
- }),
- '...'
- );
- }
- };
-
- this.getObjectMetaData = function (src) {
- var _props3 = _this4.props,
- rjvId = _props3.rjvId,
- theme = _props3.theme;
- var _state2 = _this4.state,
- size = _state2.size,
- hovered = _state2.hovered;
-
- return _react2.default.createElement(_VariableMeta2.default, _extends({ rowHovered: hovered, size: size }, _this4.props));
- };
-
- this.renderObjectContents = function (variables, props) {
- var _props4 = _this4.props,
- depth = _props4.depth,
- parent_type = _props4.parent_type,
- index_offset = _props4.index_offset,
- groupArraysAfterLength = _props4.groupArraysAfterLength,
- namespace = _props4.namespace;
- var object_type = _this4.state.object_type;
-
- var theme = props.theme;
- var elements = [],
- variable = void 0;
- var keys = Object.keys(variables || {});
- if (_this4.props.sortKeys) {
- keys = keys.sort();
- }
- keys.forEach(function (name) {
- variable = new JsonVariable(name, variables[name]);
-
- if (parent_type === 'array_group' && index_offset) {
- variable.name = parseInt(variable.name) + index_offset;
- }
- if (!variables.hasOwnProperty(name)) {
- return;
- } else if (variable.type === 'object') {
- elements.push(_react2.default.createElement(_DataTypes.JsonObject, _extends({
- key: variable.name,
- depth: depth + DEPTH_INCREMENT,
- name: variable.name,
- src: variable.value,
- namespace: namespace.concat(variable.name),
- parent_type: object_type
- }, props)));
- } else if (variable.type === 'array') {
- var ObjectComponent = _DataTypes.JsonObject;
-
- if (groupArraysAfterLength && variable.value.length > groupArraysAfterLength) {
- ObjectComponent = _ArrayGroup2.default;
- }
-
- elements.push(_react2.default.createElement(ObjectComponent, _extends({
- key: variable.name,
- depth: depth + DEPTH_INCREMENT,
- name: variable.name,
- src: variable.value,
- namespace: namespace.concat(variable.name),
- type: 'array',
- parent_type: object_type
- }, props)));
- } else {
- elements.push(_react2.default.createElement(_VariableEditor2.default, _extends({
- key: variable.name + '_' + namespace,
- variable: variable,
- singleIndent: SINGLE_INDENT,
- namespace: namespace,
- type: _this4.props.type
- }, props)));
- }
- });
- return elements;
- };
-};
-
-var JsonVariable = function JsonVariable(name, value) {
- _classCallCheck(this, JsonVariable);
-
- this.name = name;
- this.value = value;
- this.type = (0, _util.toType)(value);
-};
-
-(0, _reactLifecyclesCompat.polyfill)(RjvObject);
-
-//export component
-exports.default = RjvObject;
-
-/***/ }),
-/* 32 */
+/* 25 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var $at = __webpack_require__(82)(true);
+var $at = __webpack_require__(61)(true);
// 21.1.3.27 String.prototype[@@iterator]()
-__webpack_require__(48)(String, 'String', function (iterated) {
+__webpack_require__(39)(String, 'String', function (iterated) {
this._t = String(iterated); // target
this._i = 0; // next index
// 21.1.5.2.1 %StringIteratorPrototype%.next()
@@ -2478,7 +857,7 @@ __webpack_require__(48)(String, 'String', function (iterated) {
/***/ }),
-/* 33 */
+/* 26 */
/***/ (function(module, exports) {
// 7.1.4 ToInteger
@@ -2490,7 +869,7 @@ module.exports = function (it) {
/***/ }),
-/* 34 */
+/* 27 */
/***/ (function(module, exports) {
// 7.2.1 RequireObjectCoercible(argument)
@@ -2501,11 +880,11 @@ module.exports = function (it) {
/***/ }),
-/* 35 */
+/* 28 */
/***/ (function(module, exports, __webpack_require__) {
// 7.1.1 ToPrimitive(input [, PreferredType])
-var isObject = __webpack_require__(21);
+var isObject = __webpack_require__(15);
// instead of the ES6 spec version, we didn't implement @@toPrimitive case
// and the second argument - flag - preferred type is a string
module.exports = function (it, S) {
@@ -2519,7 +898,7 @@ module.exports = function (it, S) {
/***/ }),
-/* 36 */
+/* 29 */
/***/ (function(module, exports) {
var toString = {}.toString;
@@ -2530,22 +909,22 @@ module.exports = function (it) {
/***/ }),
-/* 37 */
+/* 30 */
/***/ (function(module, exports, __webpack_require__) {
-var shared = __webpack_require__(38)('keys');
-var uid = __webpack_require__(27);
+var shared = __webpack_require__(31)('keys');
+var uid = __webpack_require__(21);
module.exports = function (key) {
return shared[key] || (shared[key] = uid(key));
};
/***/ }),
-/* 38 */
+/* 31 */
/***/ (function(module, exports, __webpack_require__) {
-var core = __webpack_require__(3);
-var global = __webpack_require__(6);
+var core = __webpack_require__(2);
+var global = __webpack_require__(4);
var SHARED = '__core-js_shared__';
var store = global[SHARED] || (global[SHARED] = {});
@@ -2553,13 +932,13 @@ var store = global[SHARED] || (global[SHARED] = {});
return store[key] || (store[key] = value !== undefined ? value : {});
})('versions', []).push({
version: core.version,
- mode: __webpack_require__(24) ? 'pure' : 'global',
+ mode: __webpack_require__(18) ? 'pure' : 'global',
copyright: '© 2019 Denis Pushkarev (zloirock.ru)'
});
/***/ }),
-/* 39 */
+/* 32 */
/***/ (function(module, exports) {
// IE 8- don't enum bug keys
@@ -2569,12 +948,12 @@ module.exports = (
/***/ }),
-/* 40 */
+/* 33 */
/***/ (function(module, exports, __webpack_require__) {
-var def = __webpack_require__(13).f;
-var has = __webpack_require__(11);
-var TAG = __webpack_require__(4)('toStringTag');
+var def = __webpack_require__(11).f;
+var has = __webpack_require__(8);
+var TAG = __webpack_require__(3)('toStringTag');
module.exports = function (it, tag, stat) {
if (it && !has(it = stat ? it : it.prototype, TAG)) def(it, TAG, { configurable: true, value: tag });
@@ -2582,14 +961,14 @@ module.exports = function (it, tag, stat) {
/***/ }),
-/* 41 */
+/* 34 */
/***/ (function(module, exports, __webpack_require__) {
-__webpack_require__(92);
-var global = __webpack_require__(6);
-var hide = __webpack_require__(12);
-var Iterators = __webpack_require__(22);
-var TO_STRING_TAG = __webpack_require__(4)('toStringTag');
+__webpack_require__(71);
+var global = __webpack_require__(4);
+var hide = __webpack_require__(10);
+var Iterators = __webpack_require__(16);
+var TO_STRING_TAG = __webpack_require__(3)('toStringTag');
var DOMIterables = ('CSSRuleList,CSSStyleDeclaration,CSSValueList,ClientRectList,DOMRectList,DOMStringList,' +
'DOMTokenList,DataTransferItemList,FileList,HTMLAllCollection,HTMLCollection,HTMLFormElement,HTMLSelectElement,' +
@@ -2607,21 +986,21 @@ for (var i = 0; i < DOMIterables.length; i++) {
/***/ }),
-/* 42 */
+/* 35 */
/***/ (function(module, exports, __webpack_require__) {
-exports.f = __webpack_require__(4);
+exports.f = __webpack_require__(3);
/***/ }),
-/* 43 */
+/* 36 */
/***/ (function(module, exports, __webpack_require__) {
-var global = __webpack_require__(6);
-var core = __webpack_require__(3);
-var LIBRARY = __webpack_require__(24);
-var wksExt = __webpack_require__(42);
-var defineProperty = __webpack_require__(13).f;
+var global = __webpack_require__(4);
+var core = __webpack_require__(2);
+var LIBRARY = __webpack_require__(18);
+var wksExt = __webpack_require__(35);
+var defineProperty = __webpack_require__(11).f;
module.exports = function (name) {
var $Symbol = core.Symbol || (core.Symbol = LIBRARY ? {} : global.Symbol || {});
if (name.charAt(0) != '_' && !(name in $Symbol)) defineProperty($Symbol, name, { value: wksExt.f(name) });
@@ -2629,14 +1008,14 @@ module.exports = function (name) {
/***/ }),
-/* 44 */
+/* 37 */
/***/ (function(module, exports) {
exports.f = Object.getOwnPropertySymbols;
/***/ }),
-/* 45 */
+/* 38 */
/***/ (function(module, exports) {
function clamp(val, min, max) {
@@ -2646,303 +1025,24 @@ function clamp(val, min, max) {
module.exports = clamp;
/***/ }),
-/* 46 */
-/***/ (function(module, __webpack_exports__, __webpack_require__) {
+/* 39 */
+/***/ (function(module, exports, __webpack_require__) {
"use strict";
-__webpack_require__.r(__webpack_exports__);
-/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "polyfill", function() { return polyfill; });
-/**
- * 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.
- */
-function componentWillMount() {
- // Call this.constructor.gDSFP to support sub-classes.
- var state = this.constructor.getDerivedStateFromProps(this.props, this.state);
- if (state !== null && state !== undefined) {
- this.setState(state);
- }
-}
-
-function componentWillReceiveProps(nextProps) {
- // Call this.constructor.gDSFP to support sub-classes.
- // Use the setState() updater to ensure state isn't stale in certain edge cases.
- function updater(prevState) {
- var state = this.constructor.getDerivedStateFromProps(nextProps, prevState);
- return state !== null && state !== undefined ? state : null;
- }
- // Binding "this" is important for shallow renderer support.
- this.setState(updater.bind(this));
-}
-
-function componentWillUpdate(nextProps, nextState) {
- try {
- var prevProps = this.props;
- var prevState = this.state;
- this.props = nextProps;
- this.state = nextState;
- this.__reactInternalSnapshotFlag = true;
- this.__reactInternalSnapshot = this.getSnapshotBeforeUpdate(
- prevProps,
- prevState
- );
- } finally {
- this.props = prevProps;
- this.state = prevState;
- }
-}
-
-// React may warn about cWM/cWRP/cWU methods being deprecated.
-// Add a flag to suppress these warnings for this special case.
-componentWillMount.__suppressDeprecationWarning = true;
-componentWillReceiveProps.__suppressDeprecationWarning = true;
-componentWillUpdate.__suppressDeprecationWarning = true;
-
-function polyfill(Component) {
- var prototype = Component.prototype;
-
- if (!prototype || !prototype.isReactComponent) {
- throw new Error('Can only polyfill class components');
- }
-
- if (
- typeof Component.getDerivedStateFromProps !== 'function' &&
- typeof prototype.getSnapshotBeforeUpdate !== 'function'
- ) {
- return Component;
- }
-
- // If new component APIs are defined, "unsafe" lifecycles won't be called.
- // Error if any of these lifecycles are present,
- // Because they would work differently between older and newer (16.3+) versions of React.
- var foundWillMountName = null;
- var foundWillReceivePropsName = null;
- var foundWillUpdateName = null;
- if (typeof prototype.componentWillMount === 'function') {
- foundWillMountName = 'componentWillMount';
- } else if (typeof prototype.UNSAFE_componentWillMount === 'function') {
- foundWillMountName = 'UNSAFE_componentWillMount';
- }
- if (typeof prototype.componentWillReceiveProps === 'function') {
- foundWillReceivePropsName = 'componentWillReceiveProps';
- } else if (typeof prototype.UNSAFE_componentWillReceiveProps === 'function') {
- foundWillReceivePropsName = 'UNSAFE_componentWillReceiveProps';
- }
- if (typeof prototype.componentWillUpdate === 'function') {
- foundWillUpdateName = 'componentWillUpdate';
- } else if (typeof prototype.UNSAFE_componentWillUpdate === 'function') {
- foundWillUpdateName = 'UNSAFE_componentWillUpdate';
- }
- if (
- foundWillMountName !== null ||
- foundWillReceivePropsName !== null ||
- foundWillUpdateName !== null
- ) {
- var componentName = Component.displayName || Component.name;
- var newApiName =
- typeof Component.getDerivedStateFromProps === 'function'
- ? 'getDerivedStateFromProps()'
- : 'getSnapshotBeforeUpdate()';
-
- throw Error(
- 'Unsafe legacy lifecycles will not be called for components using new component APIs.\n\n' +
- componentName +
- ' uses ' +
- newApiName +
- ' but also contains the following legacy lifecycles:' +
- (foundWillMountName !== null ? '\n ' + foundWillMountName : '') +
- (foundWillReceivePropsName !== null
- ? '\n ' + foundWillReceivePropsName
- : '') +
- (foundWillUpdateName !== null ? '\n ' + foundWillUpdateName : '') +
- '\n\nThe above lifecycles should be removed. Learn more about this warning here:\n' +
- 'https://fb.me/react-async-component-lifecycle-hooks'
- );
- }
-
- // React <= 16.2 does not support static getDerivedStateFromProps.
- // As a workaround, use cWM and cWRP to invoke the new static lifecycle.
- // Newer versions of React will ignore these lifecycles if gDSFP exists.
- if (typeof Component.getDerivedStateFromProps === 'function') {
- prototype.componentWillMount = componentWillMount;
- prototype.componentWillReceiveProps = componentWillReceiveProps;
- }
-
- // React <= 16.2 does not support getSnapshotBeforeUpdate.
- // As a workaround, use cWU to invoke the new lifecycle.
- // Newer versions of React will ignore that lifecycle if gSBU exists.
- if (typeof prototype.getSnapshotBeforeUpdate === 'function') {
- if (typeof prototype.componentDidUpdate !== 'function') {
- throw new Error(
- 'Cannot polyfill getSnapshotBeforeUpdate() for components that do not define componentDidUpdate() on the prototype'
- );
- }
-
- prototype.componentWillUpdate = componentWillUpdate;
-
- var componentDidUpdate = prototype.componentDidUpdate;
-
- prototype.componentDidUpdate = function componentDidUpdatePolyfill(
- prevProps,
- prevState,
- maybeSnapshot
- ) {
- // 16.3+ will not execute our will-update method;
- // It will pass a snapshot value to did-update though.
- // Older versions will require our polyfilled will-update value.
- // We need to handle both cases, but can't just check for the presence of "maybeSnapshot",
- // Because for <= 15.x versions this might be a "prevContext" object.
- // We also can't just check "__reactInternalSnapshot",
- // Because get-snapshot might return a falsy value.
- // So check for the explicit __reactInternalSnapshotFlag flag to determine behavior.
- var snapshot = this.__reactInternalSnapshotFlag
- ? this.__reactInternalSnapshot
- : maybeSnapshot;
-
- componentDidUpdate.call(this, prevProps, prevState, snapshot);
- };
- }
-
- return Component;
-}
-
-
-
-
-/***/ }),
-/* 47 */
-/***/ (function(module, exports, __webpack_require__) {
-
-"use strict";
-
-
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
-
-var _Boolean = __webpack_require__(75);
-
-Object.defineProperty(exports, 'JsonBoolean', {
- enumerable: true,
- get: function get() {
- return _interopRequireDefault(_Boolean).default;
- }
-});
-
-var _Date = __webpack_require__(170);
-
-Object.defineProperty(exports, 'JsonDate', {
- enumerable: true,
- get: function get() {
- return _interopRequireDefault(_Date).default;
- }
-});
-
-var _Float = __webpack_require__(171);
-
-Object.defineProperty(exports, 'JsonFloat', {
- enumerable: true,
- get: function get() {
- return _interopRequireDefault(_Float).default;
- }
-});
-
-var _Function = __webpack_require__(172);
-
-Object.defineProperty(exports, 'JsonFunction', {
- enumerable: true,
- get: function get() {
- return _interopRequireDefault(_Function).default;
- }
-});
-
-var _Nan = __webpack_require__(177);
-
-Object.defineProperty(exports, 'JsonNan', {
- enumerable: true,
- get: function get() {
- return _interopRequireDefault(_Nan).default;
- }
-});
-
-var _Null = __webpack_require__(178);
-
-Object.defineProperty(exports, 'JsonNull', {
- enumerable: true,
- get: function get() {
- return _interopRequireDefault(_Null).default;
- }
-});
-
-var _Integer = __webpack_require__(179);
-
-Object.defineProperty(exports, 'JsonInteger', {
- enumerable: true,
- get: function get() {
- return _interopRequireDefault(_Integer).default;
- }
-});
-
-var _Object = __webpack_require__(31);
-
-Object.defineProperty(exports, 'JsonObject', {
- enumerable: true,
- get: function get() {
- return _interopRequireDefault(_Object).default;
- }
-});
-
-var _Regexp = __webpack_require__(180);
-
-Object.defineProperty(exports, 'JsonRegexp', {
- enumerable: true,
- get: function get() {
- return _interopRequireDefault(_Regexp).default;
- }
-});
-
-var _String = __webpack_require__(181);
-
-Object.defineProperty(exports, 'JsonString', {
- enumerable: true,
- get: function get() {
- return _interopRequireDefault(_String).default;
- }
-});
-
-var _Undefined = __webpack_require__(182);
-
-Object.defineProperty(exports, 'JsonUndefined', {
- enumerable: true,
- get: function get() {
- return _interopRequireDefault(_Undefined).default;
- }
-});
-
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-/***/ }),
-/* 48 */
-/***/ (function(module, exports, __webpack_require__) {
-
-"use strict";
-
-var LIBRARY = __webpack_require__(24);
-var $export = __webpack_require__(25);
-var redefine = __webpack_require__(51);
-var hide = __webpack_require__(12);
-var Iterators = __webpack_require__(22);
-var $iterCreate = __webpack_require__(85);
-var setToStringTag = __webpack_require__(40);
-var getPrototypeOf = __webpack_require__(91);
-var ITERATOR = __webpack_require__(4)('iterator');
-var BUGGY = !([].keys && 'next' in [].keys()); // Safari has buggy iterators w/o `next`
-var FF_ITERATOR = '@@iterator';
-var KEYS = 'keys';
-var VALUES = 'values';
+var LIBRARY = __webpack_require__(18);
+var $export = __webpack_require__(19);
+var redefine = __webpack_require__(42);
+var hide = __webpack_require__(10);
+var Iterators = __webpack_require__(16);
+var $iterCreate = __webpack_require__(64);
+var setToStringTag = __webpack_require__(33);
+var getPrototypeOf = __webpack_require__(70);
+var ITERATOR = __webpack_require__(3)('iterator');
+var BUGGY = !([].keys && 'next' in [].keys()); // Safari has buggy iterators w/o `next`
+var FF_ITERATOR = '@@iterator';
+var KEYS = 'keys';
+var VALUES = 'values';
var returnThis = function () { return this; };
@@ -3001,20 +1101,20 @@ module.exports = function (Base, NAME, Constructor, next, DEFAULT, IS_SET, FORCE
/***/ }),
-/* 49 */
+/* 40 */
/***/ (function(module, exports, __webpack_require__) {
-module.exports = !__webpack_require__(10) && !__webpack_require__(14)(function () {
- return Object.defineProperty(__webpack_require__(50)('div'), 'a', { get: function () { return 7; } }).a != 7;
+module.exports = !__webpack_require__(7) && !__webpack_require__(12)(function () {
+ return Object.defineProperty(__webpack_require__(41)('div'), 'a', { get: function () { return 7; } }).a != 7;
});
/***/ }),
-/* 50 */
+/* 41 */
/***/ (function(module, exports, __webpack_require__) {
-var isObject = __webpack_require__(21);
-var document = __webpack_require__(6).document;
+var isObject = __webpack_require__(15);
+var document = __webpack_require__(4).document;
// typeof document.createElement is 'object' in old IE
var is = isObject(document) && isObject(document.createElement);
module.exports = function (it) {
@@ -3023,34 +1123,34 @@ module.exports = function (it) {
/***/ }),
-/* 51 */
+/* 42 */
/***/ (function(module, exports, __webpack_require__) {
-module.exports = __webpack_require__(12);
+module.exports = __webpack_require__(10);
/***/ }),
-/* 52 */
+/* 43 */
/***/ (function(module, exports, __webpack_require__) {
// 19.1.2.2 / 15.2.3.5 Object.create(O [, Properties])
-var anObject = __webpack_require__(20);
-var dPs = __webpack_require__(86);
-var enumBugKeys = __webpack_require__(39);
-var IE_PROTO = __webpack_require__(37)('IE_PROTO');
+var anObject = __webpack_require__(14);
+var dPs = __webpack_require__(65);
+var enumBugKeys = __webpack_require__(32);
+var IE_PROTO = __webpack_require__(30)('IE_PROTO');
var Empty = function () { /* empty */ };
var PROTOTYPE = 'prototype';
// Create object with fake `null` prototype: use iframe Object with cleared prototype
var createDict = function () {
// Thrash, waste and sodomy: IE GC bug
- var iframe = __webpack_require__(50)('iframe');
+ var iframe = __webpack_require__(41)('iframe');
var i = enumBugKeys.length;
var lt = '<';
var gt = '>';
var iframeDocument;
iframe.style.display = 'none';
- __webpack_require__(90).appendChild(iframe);
+ __webpack_require__(69).appendChild(iframe);
iframe.src = 'javascript:'; // eslint-disable-line no-script-url
// createDict = iframe.contentWindow.Object;
// html.removeChild(iframe);
@@ -3077,13 +1177,13 @@ module.exports = Object.create || function create(O, Properties) {
/***/ }),
-/* 53 */
+/* 44 */
/***/ (function(module, exports, __webpack_require__) {
-var has = __webpack_require__(11);
-var toIObject = __webpack_require__(15);
-var arrayIndexOf = __webpack_require__(87)(false);
-var IE_PROTO = __webpack_require__(37)('IE_PROTO');
+var has = __webpack_require__(8);
+var toIObject = __webpack_require__(13);
+var arrayIndexOf = __webpack_require__(66)(false);
+var IE_PROTO = __webpack_require__(30)('IE_PROTO');
module.exports = function (object, names) {
var O = toIObject(object);
@@ -3100,11 +1200,11 @@ module.exports = function (object, names) {
/***/ }),
-/* 54 */
+/* 45 */
/***/ (function(module, exports, __webpack_require__) {
// fallback for non-array-like ES3 and non-enumerable old V8 strings
-var cof = __webpack_require__(36);
+var cof = __webpack_require__(29);
// eslint-disable-next-line no-prototype-builtins
module.exports = Object('z').propertyIsEnumerable(0) ? Object : function (it) {
return cof(it) == 'String' ? it.split('') : Object(it);
@@ -3112,12 +1212,12 @@ module.exports = Object('z').propertyIsEnumerable(0) ? Object : function (it) {
/***/ }),
-/* 55 */
+/* 46 */
/***/ (function(module, exports, __webpack_require__) {
// 19.1.2.7 / 15.2.3.4 Object.getOwnPropertyNames(O)
-var $keys = __webpack_require__(53);
-var hiddenKeys = __webpack_require__(39).concat('length', 'prototype');
+var $keys = __webpack_require__(44);
+var hiddenKeys = __webpack_require__(32).concat('length', 'prototype');
exports.f = Object.getOwnPropertyNames || function getOwnPropertyNames(O) {
return $keys(O, hiddenKeys);
@@ -3125,12 +1225,12 @@ exports.f = Object.getOwnPropertyNames || function getOwnPropertyNames(O) {
/***/ }),
-/* 56 */
+/* 47 */
/***/ (function(module, exports, __webpack_require__) {
// getting tag from 19.1.3.6 Object.prototype.toString()
-var cof = __webpack_require__(36);
-var TAG = __webpack_require__(4)('toStringTag');
+var cof = __webpack_require__(29);
+var TAG = __webpack_require__(3)('toStringTag');
// ES3 wrong here
var ARG = cof(function () { return arguments; }()) == 'Arguments';
@@ -3154,7 +1254,7 @@ module.exports = function (it) {
/***/ }),
-/* 57 */
+/* 48 */
/***/ (function(module, exports) {
var g;
@@ -3180,7 +1280,7 @@ module.exports = g;
/***/ }),
-/* 58 */
+/* 49 */
/***/ (function(module, exports) {
var component = /-?\d+(\.\d+)?%?/g;
@@ -3191,796 +1291,25 @@ function extractComponents(color) {
module.exports = extractComponents;
/***/ }),
-/* 59 */
+/* 50 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
Object.defineProperty(exports, "__esModule", {
- value: true
+ value: true
});
-var _util = __webpack_require__(5);
-
-exports.default = function (value) {
- var type = (0, _util.toType)(value);
- var string_value = void 0;
- switch (type) {
- case 'undefined':
- {
- string_value = 'undefined';
- break;
- }
- case 'nan':
- string_value = 'NaN';
- break;
- case 'string':
- string_value = value;
- break;
- case 'date':
- string_value = value.toString();
- break;
- case 'function':
- string_value = value.toString();
- break;
- case 'regexp':
- string_value = value.toString();
- break;
- default:
- {
- try {
- string_value = JSON.stringify(value, null, ' ');
- } catch (e) {
- string_value = '';
- }
- }
- }
-
- return string_value;
-};
-
-/***/ }),
-/* 60 */
-/***/ (function(module, exports, __webpack_require__) {
-
-"use strict";
-
-
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
-
-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 _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__(1);
-
-var _react2 = _interopRequireDefault(_react);
-
-var _util = __webpack_require__(5);
-
-var _stringifyVariable = __webpack_require__(59);
-
-var _stringifyVariable2 = _interopRequireDefault(_stringifyVariable);
-
-var _icons = __webpack_require__(18);
-
-var _getStyle = __webpack_require__(2);
-
-var _getStyle2 = _interopRequireDefault(_getStyle);
-
-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; }
-
-//clibboard icon
-
-
-//theme
-
-
-var _class = function (_React$PureComponent) {
- _inherits(_class, _React$PureComponent);
-
- function _class(props) {
- _classCallCheck(this, _class);
-
- var _this = _possibleConstructorReturn(this, (_class.__proto__ || Object.getPrototypeOf(_class)).call(this, props));
-
- _this.copiedTimer = null;
-
- _this.handleCopy = function () {
- var container = document.createElement('textarea');
- var _this$props = _this.props,
- clickCallback = _this$props.clickCallback,
- src = _this$props.src,
- namespace = _this$props.namespace;
-
-
- container.innerHTML = JSON.stringify(_this.clipboardValue(src), null, ' ');
-
- document.body.appendChild(container);
- container.select();
- document.execCommand('copy');
-
- document.body.removeChild(container);
-
- _this.copiedTimer = setTimeout(function () {
- _this.setState({
- copied: false
- });
- }, 5500);
-
- _this.setState({ copied: true }, function () {
- if (typeof clickCallback !== 'function') {
- return;
- }
-
- clickCallback({
- src: src,
- namespace: namespace,
- name: namespace[namespace.length - 1]
- });
- });
- };
-
- _this.getClippyIcon = function () {
- var theme = _this.props.theme;
-
-
- if (_this.state.copied) {
- return _react2.default.createElement(
- 'span',
- null,
- _react2.default.createElement(_icons.Clippy, _extends({ className: 'copy-icon' }, (0, _getStyle2.default)(theme, 'copy-icon'))),
- _react2.default.createElement(
- 'span',
- (0, _getStyle2.default)(theme, 'copy-icon-copied'),
- '\u2714'
- )
- );
- }
-
- return _react2.default.createElement(_icons.Clippy, _extends({ className: 'copy-icon' }, (0, _getStyle2.default)(theme, 'copy-icon')));
- };
-
- _this.clipboardValue = function (value) {
- var type = (0, _util.toType)(value);
- switch (type) {
- case 'function':
- case 'regexp':
- return value.toString();
- default:
- return value;
- }
- };
-
- _this.state = {
- copied: false
- };
- return _this;
- }
-
- _createClass(_class, [{
- key: 'componentWillUnmount',
- value: function componentWillUnmount() {
- if (this.copiedTimer) {
- clearTimeout(this.copiedTimer);
- this.copiedTimer = null;
- }
- }
- }, {
- key: 'render',
- value: function render() {
- var _props = this.props,
- src = _props.src,
- theme = _props.theme,
- hidden = _props.hidden,
- rowHovered = _props.rowHovered;
-
- var style = (0, _getStyle2.default)(theme, 'copy-to-clipboard').style;
- var display = 'inline';
-
- if (hidden) {
- display = 'none';
- }
-
- return _react2.default.createElement(
- 'span',
- { className: 'copy-to-clipboard-container',
- title: 'Copy to clipboard',
- style: {
- verticalAlign: 'top',
- display: rowHovered ? 'inline-block' : 'none'
- } },
- _react2.default.createElement(
- 'span',
- {
- style: _extends({}, style, {
- display: display
- }),
- onClick: this.handleCopy
- },
- this.getClippyIcon()
- )
- );
- }
- }]);
-
- return _class;
-}(_react2.default.PureComponent);
-
-exports.default = _class;
-
-/***/ }),
-/* 61 */
-/***/ (function(module, exports, __webpack_require__) {
-
-"use strict";
-
-
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
-
-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 _react = __webpack_require__(1);
-
-var _react2 = _interopRequireDefault(_react);
-
-var _dispatcher = __webpack_require__(17);
-
-var _dispatcher2 = _interopRequireDefault(_dispatcher);
-
-var _CopyToClipboard = __webpack_require__(60);
-
-var _CopyToClipboard2 = _interopRequireDefault(_CopyToClipboard);
-
-var _util = __webpack_require__(5);
-
-var _icons = __webpack_require__(18);
-
-var _getStyle = __webpack_require__(2);
-
-var _getStyle2 = _interopRequireDefault(_getStyle);
-
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-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); } }
-
-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; }
-
-//icons
-
-
-//theme
-
-
-var _class = function (_React$PureComponent) {
- _inherits(_class, _React$PureComponent);
-
- function _class() {
- var _ref;
-
- var _temp, _this, _ret;
-
- _classCallCheck(this, _class);
-
- for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {
- args[_key] = arguments[_key];
- }
-
- return _ret = (_temp = (_this = _possibleConstructorReturn(this, (_ref = _class.__proto__ || Object.getPrototypeOf(_class)).call.apply(_ref, [this].concat(args))), _this), _this.getObjectSize = function () {
- var _this$props = _this.props,
- size = _this$props.size,
- theme = _this$props.theme,
- displayObjectSize = _this$props.displayObjectSize;
-
- if (displayObjectSize) {
- return _react2.default.createElement(
- 'span',
- _extends({ className: 'object-size'
- }, (0, _getStyle2.default)(theme, 'object-size')),
- size,
- ' item',
- size === 1 ? '' : 's'
- );
- }
- }, _this.getAddAttribute = function (rowHovered) {
- var _this$props2 = _this.props,
- theme = _this$props2.theme,
- namespace = _this$props2.namespace,
- name = _this$props2.name,
- src = _this$props2.src,
- rjvId = _this$props2.rjvId,
- depth = _this$props2.depth;
-
-
- return _react2.default.createElement(
- 'span',
- {
- className: 'click-to-add',
- style: {
- verticalAlign: 'top',
- display: rowHovered ? 'inline-block' : 'none'
- } },
- _react2.default.createElement(_icons.AddCircle, _extends({
- className: 'click-to-add-icon'
- }, (0, _getStyle2.default)(theme, 'addVarIcon'), {
- onClick: function onClick() {
- var request = {
- name: depth > 0 ? name : null,
- namespace: namespace.splice(0, namespace.length - 1),
- existing_value: src,
- variable_removed: false,
- key_name: null
- };
- if ((0, _util.toType)(src) === 'object') {
- _dispatcher2.default.dispatch({
- name: 'ADD_VARIABLE_KEY_REQUEST',
- rjvId: rjvId,
- data: request
- });
- } else {
- _dispatcher2.default.dispatch({
- name: 'VARIABLE_ADDED',
- rjvId: rjvId,
- data: _extends({}, request, {
- new_value: [].concat(_toConsumableArray(src), [null])
- })
- });
- }
- }
- }))
- );
- }, _this.getRemoveObject = function (rowHovered) {
- var _this$props3 = _this.props,
- theme = _this$props3.theme,
- hover = _this$props3.hover,
- namespace = _this$props3.namespace,
- name = _this$props3.name,
- src = _this$props3.src,
- rjvId = _this$props3.rjvId;
-
- //don't allow deleting of root node
-
- if (namespace.length === 1) {
- return;
- }
- return _react2.default.createElement(
- 'span',
- { className: 'click-to-remove',
- style: {
- display: rowHovered ? 'inline-block' : 'none'
- } },
- _react2.default.createElement(_icons.RemoveCircle, _extends({
- className: 'click-to-remove-icon'
- }, (0, _getStyle2.default)(theme, 'removeVarIcon'), {
- onClick: function onClick() {
- _dispatcher2.default.dispatch({
- name: 'VARIABLE_REMOVED',
- rjvId: rjvId,
- data: {
- name: name,
- namespace: namespace.splice(0, namespace.length - 1),
- existing_value: src,
- variable_removed: true
- }
- });
- }
- }))
- );
- }, _this.render = function () {
- var _this$props4 = _this.props,
- theme = _this$props4.theme,
- onDelete = _this$props4.onDelete,
- onAdd = _this$props4.onAdd,
- enableClipboard = _this$props4.enableClipboard,
- src = _this$props4.src,
- namespace = _this$props4.namespace,
- rowHovered = _this$props4.rowHovered;
-
- return _react2.default.createElement(
- 'div',
- _extends({}, (0, _getStyle2.default)(theme, 'object-meta-data'), {
- className: 'object-meta-data',
- onClick: function onClick(e) {
- e.stopPropagation();
- }
- }),
- _this.getObjectSize(),
- enableClipboard ? _react2.default.createElement(_CopyToClipboard2.default, _extends({
- rowHovered: rowHovered,
- clickCallback: enableClipboard
- }, { src: src, theme: theme, namespace: namespace })) : null,
- onAdd !== false ? _this.getAddAttribute(rowHovered) : null,
- onDelete !== false ? _this.getRemoveObject(rowHovered) : null
- );
- }, _temp), _possibleConstructorReturn(_this, _ret);
- }
-
- return _class;
-}(_react2.default.PureComponent);
-
-exports.default = _class;
-
-/***/ }),
-/* 62 */
-/***/ (function(module, exports, __webpack_require__) {
-
-"use strict";
-
-
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
-
-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 _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__(1);
-
-var _react2 = _interopRequireDefault(_react);
-
-var _getStyle = __webpack_require__(2);
-
-var _getStyle2 = _interopRequireDefault(_getStyle);
-
-var _VariableMeta = __webpack_require__(61);
-
-var _VariableMeta2 = _interopRequireDefault(_VariableMeta);
-
-var _ObjectName = __webpack_require__(63);
-
-var _ObjectName2 = _interopRequireDefault(_ObjectName);
-
-var _Object = __webpack_require__(31);
-
-var _Object2 = _interopRequireDefault(_Object);
-
-var _ToggleIcons = __webpack_require__(64);
-
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-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); } }
-
-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; }
-
-//icons
-
-
-//single indent is 5px
-var SINGLE_INDENT = 5;
-
-var _class = function (_React$PureComponent) {
- _inherits(_class, _React$PureComponent);
-
- function _class(props) {
- _classCallCheck(this, _class);
-
- var _this = _possibleConstructorReturn(this, (_class.__proto__ || Object.getPrototypeOf(_class)).call(this, props));
-
- _this.toggleCollapsed = function (i) {
- var newExpanded = [];
- for (var j in _this.state.expanded) {
- newExpanded.push(_this.state.expanded[j]);
- }
- newExpanded[i] = !newExpanded[i];
- _this.setState({
- expanded: newExpanded
- });
- };
-
- _this.state = {
- expanded: []
- };
- return _this;
- }
-
- _createClass(_class, [{
- key: 'getExpandedIcon',
- value: function getExpandedIcon(i) {
- var _props = this.props,
- theme = _props.theme,
- iconStyle = _props.iconStyle;
-
-
- if (this.state.expanded[i]) {
- return _react2.default.createElement(_ToggleIcons.ExpandedIcon, { theme: theme, iconStyle: iconStyle });
- }
-
- return _react2.default.createElement(_ToggleIcons.CollapsedIcon, { theme: theme, iconStyle: iconStyle });
- }
- }, {
- key: 'render',
- value: function render() {
- var _this2 = this;
-
- var _props2 = this.props,
- src = _props2.src,
- groupArraysAfterLength = _props2.groupArraysAfterLength,
- depth = _props2.depth,
- name = _props2.name,
- theme = _props2.theme,
- jsvRoot = _props2.jsvRoot,
- namespace = _props2.namespace,
- parent_type = _props2.parent_type,
- rest = _objectWithoutProperties(_props2, ['src', 'groupArraysAfterLength', 'depth', 'name', 'theme', 'jsvRoot', 'namespace', 'parent_type']);
-
- var expanded_icon = void 0,
- object_padding_left = 0;
-
- var array_group_padding_left = this.props.indentWidth * SINGLE_INDENT;
-
- if (!jsvRoot) {
- object_padding_left = this.props.indentWidth * SINGLE_INDENT;
- }
-
- var size = groupArraysAfterLength;
- var groups = Math.ceil(src.length / size);
-
- return _react2.default.createElement(
- 'div',
- _extends({ className: 'object-key-val'
- }, (0, _getStyle2.default)(theme, jsvRoot ? 'jsv-root' : 'objectKeyVal', { paddingLeft: object_padding_left })),
- _react2.default.createElement(_ObjectName2.default, this.props),
- _react2.default.createElement(
- 'span',
- null,
- _react2.default.createElement(_VariableMeta2.default, _extends({ size: src.length }, this.props))
- ),
- [].concat(_toConsumableArray(Array(groups))).map(function (_, i) {
- return _react2.default.createElement(
- 'div',
- _extends({ key: i, className: 'object-key-val array-group' }, (0, _getStyle2.default)(theme, 'objectKeyVal', {
- marginLeft: 6,
- paddingLeft: array_group_padding_left
- })),
- _react2.default.createElement(
- 'span',
- (0, _getStyle2.default)(theme, 'brace-row'),
- _react2.default.createElement(
- 'div',
- _extends({ className: 'icon-container' }, (0, _getStyle2.default)(theme, 'icon-container'), {
- onClick: function onClick(e) {
- _this2.toggleCollapsed(i);
- } }),
- _this2.getExpandedIcon(i)
- ),
- _this2.state.expanded[i] ? _react2.default.createElement(_Object2.default, _extends({
- key: name + i,
- depth: 0,
- name: false,
- collapsed: false,
- groupArraysAfterLength: size,
- index_offset: i * size,
- src: src.slice(i * size, i * size + size),
- namespace: namespace,
- type: 'array',
- parent_type: 'array_group',
- theme: theme
- }, rest)) : _react2.default.createElement(
- 'span',
- _extends({}, (0, _getStyle2.default)(theme, 'brace'), { onClick: function onClick(e) {
- _this2.toggleCollapsed(i);
- }, className: 'array-group-brace' }),
- '[',
- _react2.default.createElement(
- 'div',
- _extends({}, (0, _getStyle2.default)(theme, 'array-group-meta-data'), { className: 'array-group-meta-data' }),
- _react2.default.createElement(
- 'span',
- _extends({ className: 'object-size'
- }, (0, _getStyle2.default)(theme, 'object-size')),
- i * size,
- ' - ',
- i * size + size > src.length ? src.length : i * size + size
- )
- ),
- ']'
- )
- )
- );
- })
- );
- }
- }]);
-
- return _class;
-}(_react2.default.PureComponent);
-
-exports.default = _class;
-
-/***/ }),
-/* 63 */
-/***/ (function(module, exports, __webpack_require__) {
-
-"use strict";
-
-
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
-
-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; };
-
-exports.default = getObjectName;
-
-var _react = __webpack_require__(1);
-
-var _react2 = _interopRequireDefault(_react);
-
-var _getStyle = __webpack_require__(2);
-
-var _getStyle2 = _interopRequireDefault(_getStyle);
-
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-function getObjectName(props) {
- var parent_type = props.parent_type,
- namespace = props.namespace,
- theme = props.theme,
- jsvRoot = props.jsvRoot,
- name = props.name;
-
-
- var display_name = props.name ? props.name : '';
-
- if (jsvRoot && (name === false || name === null)) {
- return _react2.default.createElement('span', null);
- } else if (parent_type == 'array') {
- return _react2.default.createElement(
- 'span',
- _extends({}, (0, _getStyle2.default)(theme, 'array-key'), { key: namespace }),
- _react2.default.createElement(
- 'span',
- { className: 'array-key' },
- display_name
- ),
- _react2.default.createElement(
- 'span',
- (0, _getStyle2.default)(theme, 'colon'),
- ':'
- )
- );
- } else {
- return _react2.default.createElement(
- 'span',
- _extends({}, (0, _getStyle2.default)(theme, 'object-name'), { key: namespace }),
- _react2.default.createElement(
- 'span',
- { className: 'object-key' },
- _react2.default.createElement(
- 'span',
- { style: { verticalAlign: 'top' } },
- '"'
- ),
- _react2.default.createElement(
- 'span',
- null,
- display_name
- ),
- _react2.default.createElement(
- 'span',
- { style: { verticalAlign: 'top' } },
- '"'
- )
- ),
- _react2.default.createElement(
- 'span',
- (0, _getStyle2.default)(theme, 'colon'),
- ':'
- )
- );
- }
-}
-
-/***/ }),
-/* 64 */
-/***/ (function(module, exports, __webpack_require__) {
-
-"use strict";
-
-
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
-
-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; };
-
-exports.ExpandedIcon = ExpandedIcon;
-exports.CollapsedIcon = CollapsedIcon;
-
-var _react = __webpack_require__(1);
-
-var _react2 = _interopRequireDefault(_react);
-
-var _getStyle = __webpack_require__(2);
-
-var _getStyle2 = _interopRequireDefault(_getStyle);
-
-var _icons = __webpack_require__(18);
-
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-function ExpandedIcon(props) {
- var theme = props.theme,
- iconStyle = props.iconStyle;
-
- switch (iconStyle) {
- case 'triangle':
- return _react2.default.createElement(_icons.ArrowDown, _extends({}, (0, _getStyle2.default)(theme, 'expanded-icon'), {
- className: 'expanded-icon'
- }));
- case 'square':
- return _react2.default.createElement(_icons.SquareMinus, _extends({}, (0, _getStyle2.default)(theme, 'expanded-icon'), {
- className: 'expanded-icon'
- }));
- default:
- return _react2.default.createElement(_icons.CircleMinus, _extends({}, (0, _getStyle2.default)(theme, 'expanded-icon'), {
- className: 'expanded-icon'
- }));
- }
-}
-
-function CollapsedIcon(props) {
- var theme = props.theme,
- iconStyle = props.iconStyle;
-
- switch (iconStyle) {
- case 'triangle':
- return _react2.default.createElement(_icons.ArrowRight, _extends({}, (0, _getStyle2.default)(theme, 'collapsed-icon'), {
- className: 'collapsed-icon'
- }));
- case 'square':
- return _react2.default.createElement(_icons.SquarePlus, _extends({}, (0, _getStyle2.default)(theme, 'collapsed-icon'), {
- className: 'collapsed-icon'
- }));
- default:
- return _react2.default.createElement(_icons.CirclePlus, _extends({}, (0, _getStyle2.default)(theme, 'collapsed-icon'), {
- className: 'collapsed-icon'
- }));
- }
-}
-
-/***/ }),
-/* 65 */
-/***/ (function(module, exports, __webpack_require__) {
-
-"use strict";
-
-
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
-
-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 _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 _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__(1);
+var _react = __webpack_require__(0);
var _react2 = _interopRequireDefault(_react);
-var _propTypes = __webpack_require__(0);
+var _propTypes = __webpack_require__(1);
var _propTypes2 = _interopRequireDefault(_propTypes);
@@ -4236,11844 +1565,33312 @@ AutosizeInput.defaultProps = {
exports.default = AutosizeInput;
/***/ }),
-/* 66 */
+/* 51 */
/***/ (function(module, exports, __webpack_require__) {
-module.exports = __webpack_require__(67);
+"use strict";
-/***/ }),
-/* 67 */
-/***/ (function(module, exports, __webpack_require__) {
-
-"use strict";
-
+Object.defineProperty(exports, "__esModule", {
+ value: true
+});
+exports.getBase16Theme = exports.createStyling = exports.invertTheme = undefined;
-var _reactDom = __webpack_require__(19);
+var _typeof2 = __webpack_require__(58);
-var _reactDom2 = _interopRequireDefault(_reactDom);
+var _typeof3 = _interopRequireDefault(_typeof2);
-var _index = __webpack_require__(68);
+var _extends2 = __webpack_require__(85);
-var _index2 = _interopRequireDefault(_index);
+var _extends3 = _interopRequireDefault(_extends2);
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+var _slicedToArray2 = __webpack_require__(90);
-__webpack_require__(199);
+var _slicedToArray3 = _interopRequireDefault(_slicedToArray2);
-var app = document.getElementById('mac-react-container');
+var _keys = __webpack_require__(98);
-//app entrypoint
-_reactDom2.default.render(React.createElement(
- 'div',
- { className: 'app-entry' },
- React.createElement(_index2.default, null)
-), app);
+var _keys2 = _interopRequireDefault(_keys);
-/***/ }),
-/* 68 */
-/***/ (function(module, exports, __webpack_require__) {
+var _lodash = __webpack_require__(102);
-"use strict";
+var _lodash2 = _interopRequireDefault(_lodash);
+var _base = __webpack_require__(103);
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
+var base16 = _interopRequireWildcard(_base);
-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 _rgb2hex = __webpack_require__(141);
-var _react = __webpack_require__(1);
+var _rgb2hex2 = _interopRequireDefault(_rgb2hex);
-var _react2 = _interopRequireDefault(_react);
+var _parse = __webpack_require__(142);
-var _Demo = __webpack_require__(69);
+var _parse2 = _interopRequireDefault(_parse);
-var _Demo2 = _interopRequireDefault(_Demo);
+var _lodash3 = __webpack_require__(147);
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+var _lodash4 = _interopRequireDefault(_lodash3);
-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 _colorConverters = __webpack_require__(148);
-function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
+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 _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 _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-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 DEFAULT_BASE16 = base16.default;
-//index entrypoint component
-var _class = function (_React$PureComponent) {
- _inherits(_class, _React$PureComponent);
+var BASE16_KEYS = (0, _keys2.default)(DEFAULT_BASE16);
- function _class() {
- _classCallCheck(this, _class);
+// we need a correcting factor, so that a dark, but not black background color
+// converts to bright enough inversed color
+var flip = function flip(x) {
+ return x < 0.25 ? 1 : x < 0.5 ? 0.9 - x : 1.1 - x;
+};
- return _possibleConstructorReturn(this, (_class.__proto__ || Object.getPrototypeOf(_class)).apply(this, arguments));
- }
+var invertColor = (0, _lodash4.default)(_parse2.default, _colorConverters.rgb2yuv, function (_ref) {
+ var _ref2 = (0, _slicedToArray3.default)(_ref, 3),
+ y = _ref2[0],
+ u = _ref2[1],
+ v = _ref2[2];
- _createClass(_class, [{
- key: 'render',
- value: function render() {
- var props = _objectWithoutProperties(this.state, []);
+ return [flip(y), u, v];
+}, _colorConverters.yuv2rgb, _rgb2hex2.default);
- return _react2.default.createElement(
- 'div',
- { className: 'mac-react' },
- _react2.default.createElement(_Demo2.default, null)
- );
- }
- }]);
+var merger = function merger(styling) {
+ return function (prevStyling) {
+ return {
+ className: [prevStyling.className, styling.className].filter(Boolean).join(' '),
+ style: (0, _extends3.default)({}, prevStyling.style || {}, styling.style || {})
+ };
+ };
+};
- return _class;
-}(_react2.default.PureComponent);
+var mergeStyling = function mergeStyling(customStyling, defaultStyling) {
+ if (customStyling === undefined) {
+ return defaultStyling;
+ }
+ if (defaultStyling === undefined) {
+ return customStyling;
+ }
-exports.default = _class;
+ var customType = typeof customStyling === 'undefined' ? 'undefined' : (0, _typeof3.default)(customStyling);
+ var defaultType = typeof defaultStyling === 'undefined' ? 'undefined' : (0, _typeof3.default)(defaultStyling);
-/***/ }),
-/* 69 */
-/***/ (function(module, exports, __webpack_require__) {
+ switch (customType) {
+ case 'string':
+ switch (defaultType) {
+ case 'string':
+ return [defaultStyling, customStyling].filter(Boolean).join(' ');
+ case 'object':
+ return merger({ className: customStyling, style: defaultStyling });
+ case 'function':
+ return function (styling) {
+ for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
+ args[_key - 1] = arguments[_key];
+ }
-"use strict";
+ return merger({
+ className: customStyling
+ })(defaultStyling.apply(undefined, [styling].concat(args)));
+ };
+ }
+ case 'object':
+ switch (defaultType) {
+ case 'string':
+ return merger({ className: defaultStyling, style: customStyling });
+ case 'object':
+ return (0, _extends3.default)({}, defaultStyling, customStyling);
+ case 'function':
+ return function (styling) {
+ for (var _len2 = arguments.length, args = Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {
+ args[_key2 - 1] = arguments[_key2];
+ }
+ return merger({
+ style: customStyling
+ })(defaultStyling.apply(undefined, [styling].concat(args)));
+ };
+ }
+ case 'function':
+ switch (defaultType) {
+ case 'string':
+ return function (styling) {
+ for (var _len3 = arguments.length, args = Array(_len3 > 1 ? _len3 - 1 : 0), _key3 = 1; _key3 < _len3; _key3++) {
+ args[_key3 - 1] = arguments[_key3];
+ }
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
+ return customStyling.apply(undefined, [merger(styling)({
+ className: defaultStyling
+ })].concat(args));
+ };
+ case 'object':
+ return function (styling) {
+ for (var _len4 = arguments.length, args = Array(_len4 > 1 ? _len4 - 1 : 0), _key4 = 1; _key4 < _len4; _key4++) {
+ args[_key4 - 1] = arguments[_key4];
+ }
-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; }; }();
+ return customStyling.apply(undefined, [merger(styling)({
+ style: defaultStyling
+ })].concat(args));
+ };
+ case 'function':
+ return function (styling) {
+ for (var _len5 = arguments.length, args = Array(_len5 > 1 ? _len5 - 1 : 0), _key5 = 1; _key5 < _len5; _key5++) {
+ args[_key5 - 1] = arguments[_key5];
+ }
-var _react = __webpack_require__(1);
+ return customStyling.apply(undefined, [defaultStyling.apply(undefined, [styling].concat(args))].concat(args));
+ };
+ }
+ }
+};
-var _react2 = _interopRequireDefault(_react);
+var mergeStylings = function mergeStylings(customStylings, defaultStylings) {
+ var keys = (0, _keys2.default)(defaultStylings);
+ for (var key in customStylings) {
+ if (keys.indexOf(key) === -1) keys.push(key);
+ }
-var _reactSelect = __webpack_require__(70);
+ return keys.reduce(function (mergedStyling, key) {
+ return mergedStyling[key] = mergeStyling(customStylings[key], defaultStylings[key]), mergedStyling;
+ }, {});
+};
-var _reactSelect2 = _interopRequireDefault(_reactSelect);
+var getStylingByKeys = function getStylingByKeys(mergedStyling, keys) {
+ for (var _len6 = arguments.length, args = Array(_len6 > 2 ? _len6 - 2 : 0), _key6 = 2; _key6 < _len6; _key6++) {
+ args[_key6 - 2] = arguments[_key6];
+ }
-var _index = __webpack_require__(73);
+ if (keys === null) {
+ return mergedStyling;
+ }
-var _index2 = _interopRequireDefault(_index);
+ if (!Array.isArray(keys)) {
+ keys = [keys];
+ }
-var _reactGithubButton = __webpack_require__(189);
+ var styles = keys.map(function (key) {
+ return mergedStyling[key];
+ }).filter(Boolean);
-var _reactGithubButton2 = _interopRequireDefault(_reactGithubButton);
+ var props = styles.reduce(function (obj, s) {
+ if (typeof s === 'string') {
+ obj.className = [obj.className, s].filter(Boolean).join(' ');
+ } else if ((typeof s === 'undefined' ? 'undefined' : (0, _typeof3.default)(s)) === 'object') {
+ obj.style = (0, _extends3.default)({}, obj.style, s);
+ } else if (typeof s === 'function') {
+ obj = (0, _extends3.default)({}, obj, s.apply(undefined, [obj].concat(args)));
+ }
-var _Code = __webpack_require__(192);
+ return obj;
+ }, { className: '', style: {} });
-var _Code2 = _interopRequireDefault(_Code);
+ if (!props.className) {
+ delete props.className;
+ }
-__webpack_require__(193);
+ if ((0, _keys2.default)(props.style).length === 0) {
+ delete props.style;
+ }
-__webpack_require__(195);
+ return props;
+};
-__webpack_require__(197);
+var invertTheme = exports.invertTheme = function invertTheme(theme) {
+ return (0, _keys2.default)(theme).reduce(function (t, key) {
+ return t[key] = /^base/.test(key) ? invertColor(theme[key]) : key === 'scheme' ? theme[key] + ':inverted' : theme[key], t;
+ }, {});
+};
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+var createStyling = exports.createStyling = (0, _lodash2.default)(function (getStylingFromBase16) {
+ for (var _len7 = arguments.length, args = Array(_len7 > 3 ? _len7 - 3 : 0), _key7 = 3; _key7 < _len7; _key7++) {
+ args[_key7 - 3] = arguments[_key7];
+ }
-function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
+ var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
+ var themeOrStyling = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
+ var _options$defaultBase = options.defaultBase16,
+ defaultBase16 = _options$defaultBase === undefined ? DEFAULT_BASE16 : _options$defaultBase,
+ _options$base16Themes = options.base16Themes,
+ base16Themes = _options$base16Themes === undefined ? null : _options$base16Themes;
-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 base16Theme = getBase16Theme(themeOrStyling, base16Themes);
+ if (base16Theme) {
+ themeOrStyling = (0, _extends3.default)({}, base16Theme, themeOrStyling);
+ }
-//index entrypoint component
-var _class = function (_React$PureComponent) {
- _inherits(_class, _React$PureComponent);
-
- function _class(props) {
- _classCallCheck(this, _class);
-
- var _this = _possibleConstructorReturn(this, (_class.__proto__ || Object.getPrototypeOf(_class)).call(this, props));
-
- _this.getNotes = function (on_edit_enabled, on_add_enabled) {
- var notes = [];
- if (on_edit_enabled) {
- notes.push(_react2.default.createElement(
- "span",
- null,
- "To edit a value, try ",
- _react2.default.createElement(
- _Code2.default,
- null,
- "ctrl/cmd + click"
- ),
- " enter edit mode"
- ));
- notes.push(_react2.default.createElement(
- "span",
- null,
- "When editing a value, try ",
- _react2.default.createElement(
- _Code2.default,
- null,
- "ctrl/cmd + Enter"
- ),
- " to submit changes"
- ));
- notes.push(_react2.default.createElement(
- "span",
- null,
- "When editing a value, try ",
- _react2.default.createElement(
- _Code2.default,
- null,
- "Escape"
- ),
- " key to cancel"
- ));
- }
- if (on_add_enabled) {
- notes.push(_react2.default.createElement(
- "span",
- null,
- "When adding a new key, try ",
- _react2.default.createElement(
- _Code2.default,
- null,
- "Enter"
- ),
- " to submit"
- ));
- notes.push(_react2.default.createElement(
- "span",
- null,
- "When adding a new key, try ",
- _react2.default.createElement(
- _Code2.default,
- null,
- "Escape"
- ),
- " to cancel"
- ));
- }
+ var theme = BASE16_KEYS.reduce(function (t, key) {
+ return t[key] = themeOrStyling[key] || defaultBase16[key], t;
+ }, {});
- if (notes.length === 0) {
- return null;
- }
+ var customStyling = (0, _keys2.default)(themeOrStyling).reduce(function (s, key) {
+ return BASE16_KEYS.indexOf(key) === -1 ? (s[key] = themeOrStyling[key], s) : s;
+ }, {});
- return _react2.default.createElement(
- "div",
- { style: { marginTop: "20px", fontStyle: "italic" } },
- "Keyboard Shortcuts",
- _react2.default.createElement(
- "ul",
- null,
- notes.map(function (note) {
- return _react2.default.createElement(
- "li",
- null,
- note
- );
- })
- )
- );
- };
+ var defaultStyling = getStylingFromBase16(theme);
- _this.getIconStyleInput = function (iconStyle) {
- return _react2.default.createElement(_reactSelect2.default, {
- name: "icon-style",
- value: iconStyle,
- options: [{ value: "circle", label: "circle" }, { value: "square", label: "square" }, { value: "triangle", label: "triangle" }],
- onChange: function onChange(val) {
- _this.set("iconStyle", val);
- }
- });
- };
+ var mergedStyling = mergeStylings(customStyling, defaultStyling);
- _this.getEditInput = function (onEdit) {
- return _react2.default.createElement(_reactSelect2.default, {
- name: "enable-edit",
- value: onEdit,
- options: [{ value: true, label: "true" }, { value: false, label: "false" }],
- onChange: function onChange(val) {
- _this.set("onEdit", val);
- }
- });
- };
+ return (0, _lodash2.default)(getStylingByKeys, 2).apply(undefined, [mergedStyling].concat(args));
+}, 3);
- _this.getAddInput = function (onAdd) {
- return _react2.default.createElement(_reactSelect2.default, {
- name: "enable-add",
- value: onAdd,
- options: [{ value: true, label: "true" }, { value: false, label: "false" }],
- onChange: function onChange(val) {
- _this.set("onAdd", val);
- }
- });
- };
+var getBase16Theme = exports.getBase16Theme = function getBase16Theme(theme, base16Themes) {
+ if (theme && theme.extend) {
+ theme = theme.extend;
+ }
- _this.getDeleteInput = function (onDelete) {
- return _react2.default.createElement(_reactSelect2.default, {
- name: "enable-delete",
- value: onDelete,
- options: [{ value: true, label: "true" }, { value: false, label: "false" }],
- onChange: function onChange(val) {
- _this.set("onDelete", val);
- }
- });
- };
+ if (typeof theme === 'string') {
+ var _theme$split = theme.split(':'),
+ _theme$split2 = (0, _slicedToArray3.default)(_theme$split, 2),
+ themeName = _theme$split2[0],
+ modifier = _theme$split2[1];
- _this.getEnableClipboardInput = function (enableClipboard) {
- return _react2.default.createElement(_reactSelect2.default, {
- name: "enable-clipboard",
- value: enableClipboard,
- options: [{ value: true, label: "true" }, { value: false, label: "false" }],
- onChange: function onChange(val) {
- _this.set("enableClipboard", val);
- }
- });
- };
+ theme = (base16Themes || {})[themeName] || base16[themeName];
+ if (modifier === 'inverted') {
+ theme = invertTheme(theme);
+ }
+ }
- _this.getObjectSizeInput = function (displayObjectSize) {
- return _react2.default.createElement(_reactSelect2.default, {
- name: "display-object-size",
- value: displayObjectSize,
- options: [{ value: true, label: "true" }, { value: false, label: "false" }],
- onChange: function onChange(val) {
- _this.set("displayObjectSize", val);
- }
- });
- };
+ return theme && theme.hasOwnProperty('base00') ? theme : undefined;
+};
- _this.getDataTypesInput = function (displayDataTypes) {
- return _react2.default.createElement(_reactSelect2.default, {
- name: "display-data-types",
- value: displayDataTypes,
- options: [{ value: true, label: "true" }, { value: false, label: "false" }],
- onChange: function onChange(val) {
- _this.set("displayDataTypes", val);
- }
- });
- };
+/***/ }),
+/* 52 */
+/***/ (function(module, exports, __webpack_require__) {
- _this.getCollapsedStringsInput = function (collapseStringsAfter) {
- return _react2.default.createElement(_reactSelect2.default, {
- name: "collapse-strings",
- value: collapseStringsAfter,
- options: [{ value: false, label: "false" }, { value: 5, label: 5 }, { value: 10, label: 10 }, { value: 15, label: 15 }, { value: 20, label: 20 }],
- onChange: function onChange(val) {
- _this.set("collapseStringsAfter", val);
- }
- });
- };
-
- _this.getCollapsedInput = function (collapsed) {
- return _react2.default.createElement(_reactSelect2.default, {
- name: "collapsed",
- value: collapsed,
- options: [{ value: true, label: "true" }, { value: false, label: "false" }, { value: 1, label: 1 }, { value: 2, label: 2 }],
- onChange: function onChange(val) {
- _this.set("collapsed", val);
- }
- });
- };
+"use strict";
+// Copyright Joyent, Inc. and other Node contributors.
+//
+// Permission is hereby granted, free of charge, to any person obtaining a
+// copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to permit
+// persons to whom the Software is furnished to do so, subject to the
+// following conditions:
+//
+// The above copyright notice and this permission notice shall be included
+// in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
+// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+// USE OR OTHER DEALINGS IN THE SOFTWARE.
- _this.getIndentWidthInput = function (indentWidth) {
- return _react2.default.createElement(_reactSelect2.default, {
- name: "indent-width",
- value: indentWidth,
- options: [{ value: 0, label: 0 }, { value: 1, label: 1 }, { value: 2, label: 2 }, { value: 3, label: 3 }, { value: 4, label: 4 }, { value: 5, label: 5 }, { value: 6, label: 6 }, { value: 7, label: 7 }, { value: 8, label: 8 }, { value: 9, label: 9 }, { value: 10, label: 10 }],
- onChange: function onChange(val) {
- _this.set("indentWidth", val);
- }
- });
- };
- _this.getThemeInput = function (theme) {
- return _react2.default.createElement(_reactSelect2.default, {
- name: "theme-select",
- value: theme,
- options: [{ value: "apathy", label: "apathy" }, { value: "apathy:inverted", label: "apathy:inverted" }, { value: "ashes", label: "ashes" }, { value: "bespin", label: "bespin" }, { value: "brewer", label: "brewer" }, { value: "bright:inverted", label: "bright:inverted" }, { value: "bright", label: "bright" }, { value: "chalk", label: "chalk" }, { value: "codeschool", label: "codeschool" }, { value: "colors", label: "colors" }, { value: "eighties", label: "eighties" }, { value: "embers", label: "embers" }, { value: "flat", label: "flat" }, { value: "google", label: "google" }, { value: "grayscale", label: "grayscale" }, {
- value: "grayscale:inverted",
- label: "grayscale:inverted"
- }, { value: "greenscreen", label: "greenscreen" }, { value: "harmonic", label: "harmonic" }, { value: "hopscotch", label: "hopscotch" }, { value: "isotope", label: "isotope" }, { value: "marrakesh", label: "marrakesh" }, { value: "mocha", label: "mocha" }, { value: "monokai", label: "monokai" }, { value: "ocean", label: "ocean" }, { value: "paraiso", label: "paraiso" }, { value: "pop", label: "pop" }, { value: "railscasts", label: "railscasts" }, { value: "rjv-default", label: "rjv-default" }, { value: "shapeshifter", label: "shapeshifter" }, {
- value: "shapeshifter:inverted",
- label: "shapeshifter:inverted"
- }, { value: "solarized", label: "solarized" }, { value: "summerfruit", label: "summerfruit" }, {
- value: "summerfruit:inverted",
- label: "summerfruit:inverted"
- }, { value: "threezerotwofour", label: "threezerotwofour" }, { value: "tomorrow", label: "tomorrow" }, { value: "tube", label: "tube" }, { value: "twilight", label: "twilight" }],
- onChange: function onChange(val) {
- _this.set("theme", val);
- }
- });
- };
- _this.set = function (field, value) {
- var state = {};
- state[field] = value.value;
- _this.setState(state);
- };
+var R = typeof Reflect === 'object' ? Reflect : null
+var ReflectApply = R && typeof R.apply === 'function'
+ ? R.apply
+ : function ReflectApply(target, receiver, args) {
+ return Function.prototype.apply.call(target, receiver, args);
+ }
- _this.getExampleJson = function () {
- return {
- string: "this is a test string",
- integer: 42,
- array: [1, 2, 3, "test", NaN],
- float: 3.14159,
- undefined: undefined,
- object: {
- "first-child": true,
- "second-child": false,
- "last-child": null
- },
- string_number: "1234",
- date: new Date()
- };
- };
+var ReflectOwnKeys
+if (R && typeof R.ownKeys === 'function') {
+ ReflectOwnKeys = R.ownKeys
+} else if (Object.getOwnPropertySymbols) {
+ ReflectOwnKeys = function ReflectOwnKeys(target) {
+ return Object.getOwnPropertyNames(target)
+ .concat(Object.getOwnPropertySymbols(target));
+ };
+} else {
+ ReflectOwnKeys = function ReflectOwnKeys(target) {
+ return Object.getOwnPropertyNames(target);
+ };
+}
- _this.state = {
- src: _this.getExampleJson()
- };
- return _this;
- }
-
- _createClass(_class, [{
- key: "render",
- value: function render() {
- var _this2 = this;
-
- var _props = this.props,
- collapseStringsAfter = _props.collapseStringsAfter,
- onAdd = _props.onAdd,
- onEdit = _props.onEdit,
- onDelete = _props.onDelete,
- displayObjectSize = _props.displayObjectSize,
- enableClipboard = _props.enableClipboard,
- theme = _props.theme,
- iconStyle = _props.iconStyle,
- collapsed = _props.collapsed,
- indentWidth = _props.indentWidth,
- displayDataTypes = _props.displayDataTypes;
- var src = this.state.src;
-
- var style = {
- padding: "10px",
- borderRadius: "3px",
- margin: "10px 0px"
- };
-
- return _react2.default.createElement(
- "div",
- { className: "rjv-demo" },
- _react2.default.createElement(
- "div",
- { className: "rjv-header" },
- _react2.default.createElement(
- "div",
- { className: "header-1" },
- "react-json-view"
- ),
- _react2.default.createElement(
- "div",
- { className: "header-2" },
- "component demo"
- ),
- _react2.default.createElement("img", {
- className: "rjv-logo",
- src: "https://github.com/mac-s-g/react-json-view/blob/master/doc/rjv-icon-alt.png?raw=true",
- onClick: function onClick() {
- window.open("https://github.com/mac-s-g/react-json-view", "_blank");
- }
- }),
- _react2.default.createElement(_reactGithubButton2.default, {
- type: "stargazers",
- namespace: "mac-s-g",
- repo: "react-json-view"
- })
- ),
- _react2.default.createElement(_index2.default, {
- name: false,
- collapsed: collapsed,
- style: style,
- theme: theme,
- src: src,
- collapseStringsAfterLength: collapseStringsAfter,
- onEdit: onEdit ? function (e) {
- console.log(e);
- _this2.setState({ src: e.updated_src });
- } : false,
- onDelete: onDelete ? function (e) {
- console.log(e);
- _this2.setState({ src: e.updated_src });
- } : false,
- onAdd: onAdd ? function (e) {
- console.log(e);
- _this2.setState({ src: e.updated_src });
- } : false,
- displayObjectSize: displayObjectSize,
- enableClipboard: enableClipboard,
- indentWidth: indentWidth,
- displayDataTypes: displayDataTypes,
- iconStyle: iconStyle
- }),
- _react2.default.createElement(
- "div",
- { className: "rjv-settings" },
- _react2.default.createElement(
- "div",
- { className: "rjv-input" },
- _react2.default.createElement(
- "div",
- { className: "rjv-label" },
- "Theme:"
- ),
- this.getThemeInput(theme)
- ),
- _react2.default.createElement(
- "div",
- { className: "rjv-input" },
- _react2.default.createElement(
- "div",
- { className: "rjv-label" },
- "Icon Style:"
- ),
- this.getIconStyleInput(iconStyle)
- ),
- _react2.default.createElement(
- "div",
- { className: "rjv-input" },
- _react2.default.createElement(
- "div",
- { className: "rjv-label" },
- "Enable Edit:"
- ),
- this.getEditInput(onEdit)
- ),
- _react2.default.createElement(
- "div",
- { className: "rjv-input" },
- _react2.default.createElement(
- "div",
- { className: "rjv-label" },
- "Enable Add:"
- ),
- this.getAddInput(onAdd)
- ),
- _react2.default.createElement(
- "div",
- { className: "rjv-input" },
- _react2.default.createElement(
- "div",
- { className: "rjv-label" },
- "Enable Delete:"
- ),
- this.getDeleteInput(onDelete)
- ),
- _react2.default.createElement(
- "div",
- { className: "rjv-input" },
- _react2.default.createElement(
- "div",
- { className: "rjv-label" },
- "Enable Clipboard:"
- ),
- this.getEnableClipboardInput(enableClipboard)
- )
- ),
- _react2.default.createElement(
- "div",
- { className: "rjv-settings" },
- _react2.default.createElement(
- "div",
- { className: "rjv-input" },
- _react2.default.createElement(
- "div",
- { className: "rjv-label" },
- "Display Data Types:"
- ),
- this.getDataTypesInput(displayDataTypes)
- ),
- _react2.default.createElement(
- "div",
- { className: "rjv-input" },
- _react2.default.createElement(
- "div",
- { className: "rjv-label" },
- "Display Object Size:"
- ),
- this.getObjectSizeInput(displayObjectSize)
- ),
- _react2.default.createElement(
- "div",
- { className: "rjv-input" },
- _react2.default.createElement(
- "div",
- { className: "rjv-label" },
- "Indent Width:"
- ),
- this.getIndentWidthInput(indentWidth)
- ),
- _react2.default.createElement(
- "div",
- { className: "rjv-input" },
- _react2.default.createElement(
- "div",
- { className: "rjv-label" },
- "Collapsed:"
- ),
- this.getCollapsedInput(collapsed)
- ),
- _react2.default.createElement(
- "div",
- { className: "rjv-input" },
- _react2.default.createElement(
- "div",
- { className: "rjv-label" },
- "Collapse Strings After Length:"
- ),
- this.getCollapsedStringsInput(collapseStringsAfter)
- )
- ),
- this.getNotes(onEdit, onAdd)
- );
- }
-
- //just a function to get an example JSON object
-
- }]);
-
- return _class;
-}(_react2.default.PureComponent);
-
-_class.defaultProps = {
- theme: "monokai",
- src: null,
- collapsed: false,
- collapseStringsAfter: 15,
- onAdd: true,
- onEdit: true,
- onDelete: true,
- displayObjectSize: true,
- enableClipboard: true,
- indentWidth: 4,
- displayDataTypes: true,
- iconStyle: "triangle"
-};
-exports.default = _class;
+function ProcessEmitWarning(warning) {
+ if (console && console.warn) console.warn(warning);
+}
-/***/ }),
-/* 70 */
-/***/ (function(module, __webpack_exports__, __webpack_require__) {
+var NumberIsNaN = Number.isNaN || function NumberIsNaN(value) {
+ return value !== value;
+}
-"use strict";
-__webpack_require__.r(__webpack_exports__);
-/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Async", function() { return Async; });
-/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "AsyncCreatable", function() { return AsyncCreatableSelect; });
-/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Creatable", function() { return CreatableSelect; });
-/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Value", function() { return Value; });
-/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Option", function() { return Option; });
-/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "defaultMenuRenderer", function() { return menuRenderer; });
-/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "defaultArrowRenderer", function() { return arrowRenderer; });
-/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "defaultClearRenderer", function() { return clearRenderer; });
-/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "defaultFilterOptions", function() { return filterOptions; });
-/* harmony import */ var react_input_autosize__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(65);
-/* harmony import */ var react_input_autosize__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_input_autosize__WEBPACK_IMPORTED_MODULE_0__);
-/* harmony import */ var classnames__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(8);
-/* harmony import */ var classnames__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(classnames__WEBPACK_IMPORTED_MODULE_1__);
-/* harmony import */ var prop_types__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(0);
-/* harmony import */ var prop_types__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(prop_types__WEBPACK_IMPORTED_MODULE_2__);
-/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(1);
-/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_3__);
-/* harmony import */ var react_dom__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(19);
-/* harmony import */ var react_dom__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(react_dom__WEBPACK_IMPORTED_MODULE_4__);
+function EventEmitter() {
+ EventEmitter.init.call(this);
+}
+module.exports = EventEmitter;
+module.exports.once = once;
+// Backwards-compat with node 0.10.x
+EventEmitter.EventEmitter = EventEmitter;
+EventEmitter.prototype._events = undefined;
+EventEmitter.prototype._eventsCount = 0;
+EventEmitter.prototype._maxListeners = undefined;
+// By default EventEmitters will print a warning if more than 10 listeners are
+// added to it. This is a useful default which helps finding memory leaks.
+var defaultMaxListeners = 10;
+function checkListener(listener) {
+ if (typeof listener !== 'function') {
+ throw new TypeError('The "listener" argument must be of type Function. Received type ' + typeof listener);
+ }
+}
+Object.defineProperty(EventEmitter, 'defaultMaxListeners', {
+ enumerable: true,
+ get: function() {
+ return defaultMaxListeners;
+ },
+ set: function(arg) {
+ if (typeof arg !== 'number' || arg < 0 || NumberIsNaN(arg)) {
+ throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received ' + arg + '.');
+ }
+ defaultMaxListeners = arg;
+ }
+});
-var arrowRenderer = function arrowRenderer(_ref) {
- var onMouseDown = _ref.onMouseDown;
+EventEmitter.init = function() {
- return react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement('span', {
- className: 'Select-arrow',
- onMouseDown: onMouseDown
- });
-};
+ if (this._events === undefined ||
+ this._events === Object.getPrototypeOf(this)._events) {
+ this._events = Object.create(null);
+ this._eventsCount = 0;
+ }
-arrowRenderer.propTypes = {
- onMouseDown: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func
+ this._maxListeners = this._maxListeners || undefined;
};
-var clearRenderer = function clearRenderer() {
- return react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement('span', {
- className: 'Select-clear',
- dangerouslySetInnerHTML: { __html: '×' }
- });
+// Obviously not all Emitters should be limited to 10. This function allows
+// that to be increased. Set to zero for unlimited.
+EventEmitter.prototype.setMaxListeners = function setMaxListeners(n) {
+ if (typeof n !== 'number' || n < 0 || NumberIsNaN(n)) {
+ throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received ' + n + '.');
+ }
+ this._maxListeners = n;
+ return this;
};
-var map = [{ 'base': 'A', 'letters': /[\u0041\u24B6\uFF21\u00C0\u00C1\u00C2\u1EA6\u1EA4\u1EAA\u1EA8\u00C3\u0100\u0102\u1EB0\u1EAE\u1EB4\u1EB2\u0226\u01E0\u00C4\u01DE\u1EA2\u00C5\u01FA\u01CD\u0200\u0202\u1EA0\u1EAC\u1EB6\u1E00\u0104\u023A\u2C6F]/g }, { 'base': 'AA', 'letters': /[\uA732]/g }, { 'base': 'AE', 'letters': /[\u00C6\u01FC\u01E2]/g }, { 'base': 'AO', 'letters': /[\uA734]/g }, { 'base': 'AU', 'letters': /[\uA736]/g }, { 'base': 'AV', 'letters': /[\uA738\uA73A]/g }, { 'base': 'AY', 'letters': /[\uA73C]/g }, { 'base': 'B', 'letters': /[\u0042\u24B7\uFF22\u1E02\u1E04\u1E06\u0243\u0182\u0181]/g }, { 'base': 'C', 'letters': /[\u0043\u24B8\uFF23\u0106\u0108\u010A\u010C\u00C7\u1E08\u0187\u023B\uA73E]/g }, { 'base': 'D', 'letters': /[\u0044\u24B9\uFF24\u1E0A\u010E\u1E0C\u1E10\u1E12\u1E0E\u0110\u018B\u018A\u0189\uA779]/g }, { 'base': 'DZ', 'letters': /[\u01F1\u01C4]/g }, { 'base': 'Dz', 'letters': /[\u01F2\u01C5]/g }, { 'base': 'E', 'letters': /[\u0045\u24BA\uFF25\u00C8\u00C9\u00CA\u1EC0\u1EBE\u1EC4\u1EC2\u1EBC\u0112\u1E14\u1E16\u0114\u0116\u00CB\u1EBA\u011A\u0204\u0206\u1EB8\u1EC6\u0228\u1E1C\u0118\u1E18\u1E1A\u0190\u018E]/g }, { 'base': 'F', 'letters': /[\u0046\u24BB\uFF26\u1E1E\u0191\uA77B]/g }, { 'base': 'G', 'letters': /[\u0047\u24BC\uFF27\u01F4\u011C\u1E20\u011E\u0120\u01E6\u0122\u01E4\u0193\uA7A0\uA77D\uA77E]/g }, { 'base': 'H', 'letters': /[\u0048\u24BD\uFF28\u0124\u1E22\u1E26\u021E\u1E24\u1E28\u1E2A\u0126\u2C67\u2C75\uA78D]/g }, { 'base': 'I', 'letters': /[\u0049\u24BE\uFF29\u00CC\u00CD\u00CE\u0128\u012A\u012C\u0130\u00CF\u1E2E\u1EC8\u01CF\u0208\u020A\u1ECA\u012E\u1E2C\u0197]/g }, { 'base': 'J', 'letters': /[\u004A\u24BF\uFF2A\u0134\u0248]/g }, { 'base': 'K', 'letters': /[\u004B\u24C0\uFF2B\u1E30\u01E8\u1E32\u0136\u1E34\u0198\u2C69\uA740\uA742\uA744\uA7A2]/g }, { 'base': 'L', 'letters': /[\u004C\u24C1\uFF2C\u013F\u0139\u013D\u1E36\u1E38\u013B\u1E3C\u1E3A\u0141\u023D\u2C62\u2C60\uA748\uA746\uA780]/g }, { 'base': 'LJ', 'letters': /[\u01C7]/g }, { 'base': 'Lj', 'letters': /[\u01C8]/g }, { 'base': 'M', 'letters': /[\u004D\u24C2\uFF2D\u1E3E\u1E40\u1E42\u2C6E\u019C]/g }, { 'base': 'N', 'letters': /[\u004E\u24C3\uFF2E\u01F8\u0143\u00D1\u1E44\u0147\u1E46\u0145\u1E4A\u1E48\u0220\u019D\uA790\uA7A4]/g }, { 'base': 'NJ', 'letters': /[\u01CA]/g }, { 'base': 'Nj', 'letters': /[\u01CB]/g }, { 'base': 'O', 'letters': /[\u004F\u24C4\uFF2F\u00D2\u00D3\u00D4\u1ED2\u1ED0\u1ED6\u1ED4\u00D5\u1E4C\u022C\u1E4E\u014C\u1E50\u1E52\u014E\u022E\u0230\u00D6\u022A\u1ECE\u0150\u01D1\u020C\u020E\u01A0\u1EDC\u1EDA\u1EE0\u1EDE\u1EE2\u1ECC\u1ED8\u01EA\u01EC\u00D8\u01FE\u0186\u019F\uA74A\uA74C]/g }, { 'base': 'OI', 'letters': /[\u01A2]/g }, { 'base': 'OO', 'letters': /[\uA74E]/g }, { 'base': 'OU', 'letters': /[\u0222]/g }, { 'base': 'P', 'letters': /[\u0050\u24C5\uFF30\u1E54\u1E56\u01A4\u2C63\uA750\uA752\uA754]/g }, { 'base': 'Q', 'letters': /[\u0051\u24C6\uFF31\uA756\uA758\u024A]/g }, { 'base': 'R', 'letters': /[\u0052\u24C7\uFF32\u0154\u1E58\u0158\u0210\u0212\u1E5A\u1E5C\u0156\u1E5E\u024C\u2C64\uA75A\uA7A6\uA782]/g }, { 'base': 'S', 'letters': /[\u0053\u24C8\uFF33\u1E9E\u015A\u1E64\u015C\u1E60\u0160\u1E66\u1E62\u1E68\u0218\u015E\u2C7E\uA7A8\uA784]/g }, { 'base': 'T', 'letters': /[\u0054\u24C9\uFF34\u1E6A\u0164\u1E6C\u021A\u0162\u1E70\u1E6E\u0166\u01AC\u01AE\u023E\uA786]/g }, { 'base': 'TZ', 'letters': /[\uA728]/g }, { 'base': 'U', 'letters': /[\u0055\u24CA\uFF35\u00D9\u00DA\u00DB\u0168\u1E78\u016A\u1E7A\u016C\u00DC\u01DB\u01D7\u01D5\u01D9\u1EE6\u016E\u0170\u01D3\u0214\u0216\u01AF\u1EEA\u1EE8\u1EEE\u1EEC\u1EF0\u1EE4\u1E72\u0172\u1E76\u1E74\u0244]/g }, { 'base': 'V', 'letters': /[\u0056\u24CB\uFF36\u1E7C\u1E7E\u01B2\uA75E\u0245]/g }, { 'base': 'VY', 'letters': /[\uA760]/g }, { 'base': 'W', 'letters': /[\u0057\u24CC\uFF37\u1E80\u1E82\u0174\u1E86\u1E84\u1E88\u2C72]/g }, { 'base': 'X', 'letters': /[\u0058\u24CD\uFF38\u1E8A\u1E8C]/g }, { 'base': 'Y', 'letters': /[\u0059\u24CE\uFF39\u1EF2\u00DD\u0176\u1EF8\u0232\u1E8E\u0178\u1EF6\u1EF4\u01B3\u024E\u1EFE]/g }, { 'base': 'Z', 'letters': /[\u005A\u24CF\uFF3A\u0179\u1E90\u017B\u017D\u1E92\u1E94\u01B5\u0224\u2C7F\u2C6B\uA762]/g }, { 'base': 'a', 'letters': /[\u0061\u24D0\uFF41\u1E9A\u00E0\u00E1\u00E2\u1EA7\u1EA5\u1EAB\u1EA9\u00E3\u0101\u0103\u1EB1\u1EAF\u1EB5\u1EB3\u0227\u01E1\u00E4\u01DF\u1EA3\u00E5\u01FB\u01CE\u0201\u0203\u1EA1\u1EAD\u1EB7\u1E01\u0105\u2C65\u0250]/g }, { 'base': 'aa', 'letters': /[\uA733]/g }, { 'base': 'ae', 'letters': /[\u00E6\u01FD\u01E3]/g }, { 'base': 'ao', 'letters': /[\uA735]/g }, { 'base': 'au', 'letters': /[\uA737]/g }, { 'base': 'av', 'letters': /[\uA739\uA73B]/g }, { 'base': 'ay', 'letters': /[\uA73D]/g }, { 'base': 'b', 'letters': /[\u0062\u24D1\uFF42\u1E03\u1E05\u1E07\u0180\u0183\u0253]/g }, { 'base': 'c', 'letters': /[\u0063\u24D2\uFF43\u0107\u0109\u010B\u010D\u00E7\u1E09\u0188\u023C\uA73F\u2184]/g }, { 'base': 'd', 'letters': /[\u0064\u24D3\uFF44\u1E0B\u010F\u1E0D\u1E11\u1E13\u1E0F\u0111\u018C\u0256\u0257\uA77A]/g }, { 'base': 'dz', 'letters': /[\u01F3\u01C6]/g }, { 'base': 'e', 'letters': /[\u0065\u24D4\uFF45\u00E8\u00E9\u00EA\u1EC1\u1EBF\u1EC5\u1EC3\u1EBD\u0113\u1E15\u1E17\u0115\u0117\u00EB\u1EBB\u011B\u0205\u0207\u1EB9\u1EC7\u0229\u1E1D\u0119\u1E19\u1E1B\u0247\u025B\u01DD]/g }, { 'base': 'f', 'letters': /[\u0066\u24D5\uFF46\u1E1F\u0192\uA77C]/g }, { 'base': 'g', 'letters': /[\u0067\u24D6\uFF47\u01F5\u011D\u1E21\u011F\u0121\u01E7\u0123\u01E5\u0260\uA7A1\u1D79\uA77F]/g }, { 'base': 'h', 'letters': /[\u0068\u24D7\uFF48\u0125\u1E23\u1E27\u021F\u1E25\u1E29\u1E2B\u1E96\u0127\u2C68\u2C76\u0265]/g }, { 'base': 'hv', 'letters': /[\u0195]/g }, { 'base': 'i', 'letters': /[\u0069\u24D8\uFF49\u00EC\u00ED\u00EE\u0129\u012B\u012D\u00EF\u1E2F\u1EC9\u01D0\u0209\u020B\u1ECB\u012F\u1E2D\u0268\u0131]/g }, { 'base': 'j', 'letters': /[\u006A\u24D9\uFF4A\u0135\u01F0\u0249]/g }, { 'base': 'k', 'letters': /[\u006B\u24DA\uFF4B\u1E31\u01E9\u1E33\u0137\u1E35\u0199\u2C6A\uA741\uA743\uA745\uA7A3]/g }, { 'base': 'l', 'letters': /[\u006C\u24DB\uFF4C\u0140\u013A\u013E\u1E37\u1E39\u013C\u1E3D\u1E3B\u017F\u0142\u019A\u026B\u2C61\uA749\uA781\uA747]/g }, { 'base': 'lj', 'letters': /[\u01C9]/g }, { 'base': 'm', 'letters': /[\u006D\u24DC\uFF4D\u1E3F\u1E41\u1E43\u0271\u026F]/g }, { 'base': 'n', 'letters': /[\u006E\u24DD\uFF4E\u01F9\u0144\u00F1\u1E45\u0148\u1E47\u0146\u1E4B\u1E49\u019E\u0272\u0149\uA791\uA7A5]/g }, { 'base': 'nj', 'letters': /[\u01CC]/g }, { 'base': 'o', 'letters': /[\u006F\u24DE\uFF4F\u00F2\u00F3\u00F4\u1ED3\u1ED1\u1ED7\u1ED5\u00F5\u1E4D\u022D\u1E4F\u014D\u1E51\u1E53\u014F\u022F\u0231\u00F6\u022B\u1ECF\u0151\u01D2\u020D\u020F\u01A1\u1EDD\u1EDB\u1EE1\u1EDF\u1EE3\u1ECD\u1ED9\u01EB\u01ED\u00F8\u01FF\u0254\uA74B\uA74D\u0275]/g }, { 'base': 'oi', 'letters': /[\u01A3]/g }, { 'base': 'ou', 'letters': /[\u0223]/g }, { 'base': 'oo', 'letters': /[\uA74F]/g }, { 'base': 'p', 'letters': /[\u0070\u24DF\uFF50\u1E55\u1E57\u01A5\u1D7D\uA751\uA753\uA755]/g }, { 'base': 'q', 'letters': /[\u0071\u24E0\uFF51\u024B\uA757\uA759]/g }, { 'base': 'r', 'letters': /[\u0072\u24E1\uFF52\u0155\u1E59\u0159\u0211\u0213\u1E5B\u1E5D\u0157\u1E5F\u024D\u027D\uA75B\uA7A7\uA783]/g }, { 'base': 's', 'letters': /[\u0073\u24E2\uFF53\u00DF\u015B\u1E65\u015D\u1E61\u0161\u1E67\u1E63\u1E69\u0219\u015F\u023F\uA7A9\uA785\u1E9B]/g }, { 'base': 't', 'letters': /[\u0074\u24E3\uFF54\u1E6B\u1E97\u0165\u1E6D\u021B\u0163\u1E71\u1E6F\u0167\u01AD\u0288\u2C66\uA787]/g }, { 'base': 'tz', 'letters': /[\uA729]/g }, { 'base': 'u', 'letters': /[\u0075\u24E4\uFF55\u00F9\u00FA\u00FB\u0169\u1E79\u016B\u1E7B\u016D\u00FC\u01DC\u01D8\u01D6\u01DA\u1EE7\u016F\u0171\u01D4\u0215\u0217\u01B0\u1EEB\u1EE9\u1EEF\u1EED\u1EF1\u1EE5\u1E73\u0173\u1E77\u1E75\u0289]/g }, { 'base': 'v', 'letters': /[\u0076\u24E5\uFF56\u1E7D\u1E7F\u028B\uA75F\u028C]/g }, { 'base': 'vy', 'letters': /[\uA761]/g }, { 'base': 'w', 'letters': /[\u0077\u24E6\uFF57\u1E81\u1E83\u0175\u1E87\u1E85\u1E98\u1E89\u2C73]/g }, { 'base': 'x', 'letters': /[\u0078\u24E7\uFF58\u1E8B\u1E8D]/g }, { 'base': 'y', 'letters': /[\u0079\u24E8\uFF59\u1EF3\u00FD\u0177\u1EF9\u0233\u1E8F\u00FF\u1EF7\u1E99\u1EF5\u01B4\u024F\u1EFF]/g }, { 'base': 'z', 'letters': /[\u007A\u24E9\uFF5A\u017A\u1E91\u017C\u017E\u1E93\u1E95\u01B6\u0225\u0240\u2C6C\uA763]/g }];
-
-var stripDiacritics = function stripDiacritics(str) {
- for (var i = 0; i < map.length; i++) {
- str = str.replace(map[i].letters, map[i].base);
- }
- return str;
-};
+function _getMaxListeners(that) {
+ if (that._maxListeners === undefined)
+ return EventEmitter.defaultMaxListeners;
+ return that._maxListeners;
+}
-var trim = function trim(str) {
- return str.replace(/^\s+|\s+$/g, '');
+EventEmitter.prototype.getMaxListeners = function getMaxListeners() {
+ return _getMaxListeners(this);
};
-var isValid = function isValid(value) {
- return typeof value !== 'undefined' && value !== null && value !== '';
-};
+EventEmitter.prototype.emit = function emit(type) {
+ var args = [];
+ for (var i = 1; i < arguments.length; i++) args.push(arguments[i]);
+ var doError = (type === 'error');
-var filterOptions = function filterOptions(options, filterValue, excludeOptions, props) {
- if (props.ignoreAccents) {
- filterValue = stripDiacritics(filterValue);
- }
+ var events = this._events;
+ if (events !== undefined)
+ doError = (doError && events.error === undefined);
+ else if (!doError)
+ return false;
- if (props.ignoreCase) {
- filterValue = filterValue.toLowerCase();
- }
+ // If there is no 'error' event listener then throw.
+ if (doError) {
+ var er;
+ if (args.length > 0)
+ er = args[0];
+ if (er instanceof Error) {
+ // Note: The comments on the `throw` lines are intentional, they show
+ // up in Node's output if this results in an unhandled exception.
+ throw er; // Unhandled 'error' event
+ }
+ // At least give some kind of context to the user
+ var err = new Error('Unhandled error.' + (er ? ' (' + er.message + ')' : ''));
+ err.context = er;
+ throw err; // Unhandled 'error' event
+ }
- if (props.trimFilter) {
- filterValue = trim(filterValue);
- }
+ var handler = events[type];
- if (excludeOptions) excludeOptions = excludeOptions.map(function (i) {
- return i[props.valueKey];
- });
+ if (handler === undefined)
+ return false;
- return options.filter(function (option) {
- if (excludeOptions && excludeOptions.indexOf(option[props.valueKey]) > -1) return false;
- if (props.filterOption) return props.filterOption.call(undefined, option, filterValue);
- if (!filterValue) return true;
+ if (typeof handler === 'function') {
+ ReflectApply(handler, this, args);
+ } else {
+ var len = handler.length;
+ var listeners = arrayClone(handler, len);
+ for (var i = 0; i < len; ++i)
+ ReflectApply(listeners[i], this, args);
+ }
- var value = option[props.valueKey];
- var label = option[props.labelKey];
- var hasValue = isValid(value);
- var hasLabel = isValid(label);
+ return true;
+};
- if (!hasValue && !hasLabel) {
- return false;
- }
+function _addListener(target, type, listener, prepend) {
+ var m;
+ var events;
+ var existing;
- var valueTest = hasValue ? String(value) : null;
- var labelTest = hasLabel ? String(label) : null;
+ checkListener(listener);
- if (props.ignoreAccents) {
- if (valueTest && props.matchProp !== 'label') valueTest = stripDiacritics(valueTest);
- if (labelTest && props.matchProp !== 'value') labelTest = stripDiacritics(labelTest);
- }
+ events = target._events;
+ if (events === undefined) {
+ events = target._events = Object.create(null);
+ target._eventsCount = 0;
+ } else {
+ // To avoid recursion in the case that type === "newListener"! Before
+ // adding it to the listeners, first emit "newListener".
+ if (events.newListener !== undefined) {
+ target.emit('newListener', type,
+ listener.listener ? listener.listener : listener);
- if (props.ignoreCase) {
- if (valueTest && props.matchProp !== 'label') valueTest = valueTest.toLowerCase();
- if (labelTest && props.matchProp !== 'value') labelTest = labelTest.toLowerCase();
- }
+ // Re-assign `events` because a newListener handler could have caused the
+ // this._events to be assigned to a new object
+ events = target._events;
+ }
+ existing = events[type];
+ }
- return props.matchPos === 'start' ? valueTest && props.matchProp !== 'label' && valueTest.substr(0, filterValue.length) === filterValue || labelTest && props.matchProp !== 'value' && labelTest.substr(0, filterValue.length) === filterValue : valueTest && props.matchProp !== 'label' && valueTest.indexOf(filterValue) >= 0 || labelTest && props.matchProp !== 'value' && labelTest.indexOf(filterValue) >= 0;
- });
-};
+ if (existing === undefined) {
+ // Optimize the case of one listener. Don't need the extra array object.
+ existing = events[type] = listener;
+ ++target._eventsCount;
+ } else {
+ if (typeof existing === 'function') {
+ // Adding the second element, need to change to array.
+ existing = events[type] =
+ prepend ? [listener, existing] : [existing, listener];
+ // If we've already got an array, just append.
+ } else if (prepend) {
+ existing.unshift(listener);
+ } else {
+ existing.push(listener);
+ }
-var menuRenderer = function menuRenderer(_ref) {
- var focusedOption = _ref.focusedOption,
- focusOption = _ref.focusOption,
- inputValue = _ref.inputValue,
- instancePrefix = _ref.instancePrefix,
- onFocus = _ref.onFocus,
- onOptionRef = _ref.onOptionRef,
- onSelect = _ref.onSelect,
- optionClassName = _ref.optionClassName,
- optionComponent = _ref.optionComponent,
- optionRenderer = _ref.optionRenderer,
- options = _ref.options,
- removeValue = _ref.removeValue,
- selectValue = _ref.selectValue,
- valueArray = _ref.valueArray,
- valueKey = _ref.valueKey;
-
- var Option = optionComponent;
+ // Check for listener leak
+ m = _getMaxListeners(target);
+ if (m > 0 && existing.length > m && !existing.warned) {
+ existing.warned = true;
+ // No error code for this since it is a Warning
+ // eslint-disable-next-line no-restricted-syntax
+ var w = new Error('Possible EventEmitter memory leak detected. ' +
+ existing.length + ' ' + String(type) + ' listeners ' +
+ 'added. Use emitter.setMaxListeners() to ' +
+ 'increase limit');
+ w.name = 'MaxListenersExceededWarning';
+ w.emitter = target;
+ w.type = type;
+ w.count = existing.length;
+ ProcessEmitWarning(w);
+ }
+ }
- return options.map(function (option, i) {
- var isSelected = valueArray && valueArray.some(function (x) {
- return x[valueKey] === option[valueKey];
- });
- var isFocused = option === focusedOption;
- var optionClass = classnames__WEBPACK_IMPORTED_MODULE_1___default()(optionClassName, {
- 'Select-option': true,
- 'is-selected': isSelected,
- 'is-focused': isFocused,
- 'is-disabled': option.disabled
- });
+ return target;
+}
- return react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement(
- Option,
- {
- className: optionClass,
- focusOption: focusOption,
- inputValue: inputValue,
- instancePrefix: instancePrefix,
- isDisabled: option.disabled,
- isFocused: isFocused,
- isSelected: isSelected,
- key: 'option-' + i + '-' + option[valueKey],
- onFocus: onFocus,
- onSelect: onSelect,
- option: option,
- optionIndex: i,
- ref: function ref(_ref2) {
- onOptionRef(_ref2, isFocused);
- },
- removeValue: removeValue,
- selectValue: selectValue
- },
- optionRenderer(option, i, inputValue)
- );
- });
+EventEmitter.prototype.addListener = function addListener(type, listener) {
+ return _addListener(this, type, listener, false);
};
-menuRenderer.propTypes = {
- focusOption: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func,
- focusedOption: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.object,
- inputValue: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string,
- instancePrefix: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string,
- onFocus: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func,
- onOptionRef: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func,
- onSelect: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func,
- optionClassName: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string,
- optionComponent: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func,
- optionRenderer: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func,
- options: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.array,
- removeValue: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func,
- selectValue: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func,
- valueArray: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.array,
- valueKey: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string
-};
+EventEmitter.prototype.on = EventEmitter.prototype.addListener;
-var blockEvent = (function (event) {
- event.preventDefault();
- event.stopPropagation();
- if (event.target.tagName !== 'A' || !('href' in event.target)) {
- return;
- }
- if (event.target.target) {
- window.open(event.target.href, event.target.target);
- } else {
- window.location.href = event.target.href;
- }
-});
+EventEmitter.prototype.prependListener =
+ function prependListener(type, listener) {
+ return _addListener(this, type, listener, true);
+ };
-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 onceWrapper() {
+ if (!this.fired) {
+ this.target.removeListener(this.type, this.wrapFn);
+ this.fired = true;
+ if (arguments.length === 0)
+ return this.listener.call(this.target);
+ return this.listener.apply(this.target, arguments);
+ }
+}
+function _onceWrap(target, type, listener) {
+ var state = { fired: false, wrapFn: undefined, target: target, type: type, listener: listener };
+ var wrapped = onceWrapper.bind(state);
+ wrapped.listener = listener;
+ state.wrapFn = wrapped;
+ return wrapped;
+}
+EventEmitter.prototype.once = function once(type, listener) {
+ checkListener(listener);
+ this.on(type, _onceWrap(this, type, listener));
+ return this;
+};
+EventEmitter.prototype.prependOnceListener =
+ function prependOnceListener(type, listener) {
+ checkListener(listener);
+ this.prependListener(type, _onceWrap(this, type, listener));
+ return this;
+ };
+// Emits a 'removeListener' event if and only if the listener was removed.
+EventEmitter.prototype.removeListener =
+ function removeListener(type, listener) {
+ var list, events, position, i, originalListener;
-var asyncGenerator = function () {
- function AwaitValue(value) {
- this.value = value;
- }
+ checkListener(listener);
- function AsyncGenerator(gen) {
- var front, back;
+ events = this._events;
+ if (events === undefined)
+ return this;
- function send(key, arg) {
- return new Promise(function (resolve, reject) {
- var request = {
- key: key,
- arg: arg,
- resolve: resolve,
- reject: reject,
- next: null
- };
+ list = events[type];
+ if (list === undefined)
+ return this;
- if (back) {
- back = back.next = request;
- } else {
- front = back = request;
- resume(key, arg);
+ if (list === listener || list.listener === listener) {
+ if (--this._eventsCount === 0)
+ this._events = Object.create(null);
+ else {
+ delete events[type];
+ if (events.removeListener)
+ this.emit('removeListener', type, list.listener || listener);
}
- });
- }
-
- function resume(key, arg) {
- try {
- var result = gen[key](arg);
- var value = result.value;
+ } else if (typeof list !== 'function') {
+ position = -1;
- if (value instanceof AwaitValue) {
- Promise.resolve(value.value).then(function (arg) {
- resume("next", arg);
- }, function (arg) {
- resume("throw", arg);
- });
- } else {
- settle(result.done ? "return" : "normal", result.value);
+ for (i = list.length - 1; i >= 0; i--) {
+ if (list[i] === listener || list[i].listener === listener) {
+ originalListener = list[i].listener;
+ position = i;
+ break;
+ }
}
- } catch (err) {
- settle("throw", err);
- }
- }
- function settle(type, value) {
- switch (type) {
- case "return":
- front.resolve({
- value: value,
- done: true
- });
- break;
-
- case "throw":
- front.reject(value);
- break;
+ if (position < 0)
+ return this;
- default:
- front.resolve({
- value: value,
- done: false
- });
- break;
- }
+ if (position === 0)
+ list.shift();
+ else {
+ spliceOne(list, position);
+ }
- front = front.next;
+ if (list.length === 1)
+ events[type] = list[0];
- if (front) {
- resume(front.key, front.arg);
- } else {
- back = null;
+ if (events.removeListener !== undefined)
+ this.emit('removeListener', type, originalListener || listener);
}
- }
-
- this._invoke = send;
-
- if (typeof gen.return !== "function") {
- this.return = undefined;
- }
- }
- if (typeof Symbol === "function" && Symbol.asyncIterator) {
- AsyncGenerator.prototype[Symbol.asyncIterator] = function () {
return this;
};
- }
-
- AsyncGenerator.prototype.next = function (arg) {
- return this._invoke("next", arg);
- };
-
- AsyncGenerator.prototype.throw = function (arg) {
- return this._invoke("throw", arg);
- };
-
- AsyncGenerator.prototype.return = function (arg) {
- return this._invoke("return", arg);
- };
-
- return {
- wrap: function (fn) {
- return function () {
- return new AsyncGenerator(fn.apply(this, arguments));
- };
- },
- await: function (value) {
- return new AwaitValue(value);
- }
- };
-}();
-
+EventEmitter.prototype.off = EventEmitter.prototype.removeListener;
+EventEmitter.prototype.removeAllListeners =
+ function removeAllListeners(type) {
+ var listeners, events, i;
+ events = this._events;
+ if (events === undefined)
+ return this;
-var classCallCheck = function (instance, Constructor) {
- if (!(instance instanceof Constructor)) {
- throw new TypeError("Cannot call a class as a function");
- }
-};
+ // not listening for removeListener, no need to emit
+ if (events.removeListener === undefined) {
+ if (arguments.length === 0) {
+ this._events = Object.create(null);
+ this._eventsCount = 0;
+ } else if (events[type] !== undefined) {
+ if (--this._eventsCount === 0)
+ this._events = Object.create(null);
+ else
+ delete events[type];
+ }
+ return this;
+ }
-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);
- }
- }
+ // emit removeListener for all listeners on all events
+ if (arguments.length === 0) {
+ var keys = Object.keys(events);
+ var key;
+ for (i = 0; i < keys.length; ++i) {
+ key = keys[i];
+ if (key === 'removeListener') continue;
+ this.removeAllListeners(key);
+ }
+ this.removeAllListeners('removeListener');
+ this._events = Object.create(null);
+ this._eventsCount = 0;
+ return this;
+ }
- return function (Constructor, protoProps, staticProps) {
- if (protoProps) defineProperties(Constructor.prototype, protoProps);
- if (staticProps) defineProperties(Constructor, staticProps);
- return Constructor;
- };
-}();
+ listeners = events[type];
+ if (typeof listeners === 'function') {
+ this.removeListener(type, listeners);
+ } else if (listeners !== undefined) {
+ // LIFO order
+ for (i = listeners.length - 1; i >= 0; i--) {
+ this.removeListener(type, listeners[i]);
+ }
+ }
+ return this;
+ };
+function _listeners(target, type, unwrap) {
+ var events = target._events;
+ if (events === undefined)
+ return [];
-var defineProperty = function (obj, key, value) {
- if (key in obj) {
- Object.defineProperty(obj, key, {
- value: value,
- enumerable: true,
- configurable: true,
- writable: true
- });
+ var evlistener = events[type];
+ if (evlistener === undefined)
+ return [];
+
+ if (typeof evlistener === 'function')
+ return unwrap ? [evlistener.listener || evlistener] : [evlistener];
+
+ return unwrap ?
+ unwrapListeners(evlistener) : arrayClone(evlistener, evlistener.length);
+}
+
+EventEmitter.prototype.listeners = function listeners(type) {
+ return _listeners(this, type, true);
+};
+
+EventEmitter.prototype.rawListeners = function rawListeners(type) {
+ return _listeners(this, type, false);
+};
+
+EventEmitter.listenerCount = function(emitter, type) {
+ if (typeof emitter.listenerCount === 'function') {
+ return emitter.listenerCount(type);
} else {
- obj[key] = value;
+ return listenerCount.call(emitter, type);
}
-
- return obj;
};
-var _extends = Object.assign || function (target) {
- for (var i = 1; i < arguments.length; i++) {
- var source = arguments[i];
+EventEmitter.prototype.listenerCount = listenerCount;
+function listenerCount(type) {
+ var events = this._events;
- for (var key in source) {
- if (Object.prototype.hasOwnProperty.call(source, key)) {
- target[key] = source[key];
- }
+ if (events !== undefined) {
+ var evlistener = events[type];
+
+ if (typeof evlistener === 'function') {
+ return 1;
+ } else if (evlistener !== undefined) {
+ return evlistener.length;
}
}
- return target;
+ return 0;
+}
+
+EventEmitter.prototype.eventNames = function eventNames() {
+ return this._eventsCount > 0 ? ReflectOwnKeys(this._events) : [];
};
+function arrayClone(arr, n) {
+ var copy = new Array(n);
+ for (var i = 0; i < n; ++i)
+ copy[i] = arr[i];
+ return copy;
+}
+function spliceOne(list, index) {
+ for (; index + 1 < list.length; index++)
+ list[index] = list[index + 1];
+ list.pop();
+}
-var inherits = function (subClass, superClass) {
- if (typeof superClass !== "function" && superClass !== null) {
- throw new TypeError("Super expression must either be null or a function, not " + typeof superClass);
+function unwrapListeners(arr) {
+ var ret = new Array(arr.length);
+ for (var i = 0; i < ret.length; ++i) {
+ ret[i] = arr[i].listener || arr[i];
}
+ return ret;
+}
- subClass.prototype = Object.create(superClass && superClass.prototype, {
- constructor: {
- value: subClass,
- enumerable: false,
- writable: true,
- configurable: true
+function once(emitter, name) {
+ return new Promise(function (resolve, reject) {
+ function eventListener() {
+ if (errorListener !== undefined) {
+ emitter.removeListener('error', errorListener);
+ }
+ resolve([].slice.call(arguments));
+ };
+ var errorListener;
+
+ // Adding an error listener is not optional because
+ // if an error is thrown on an event emitter we cannot
+ // guarantee that the actual event we are waiting will
+ // be fired. The result could be a silent way to create
+ // memory or file descriptor leaks, which is something
+ // we should avoid.
+ if (name !== 'error') {
+ errorListener = function errorListener(err) {
+ emitter.removeListener(name, eventListener);
+ reject(err);
+ };
+
+ emitter.once('error', errorListener);
}
+
+ emitter.once(name, eventListener);
});
- if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass;
-};
+}
+/***/ }),
+/* 53 */
+/***/ (function(module, exports, __webpack_require__) {
+/**
+ * Copyright (c) 2014-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.
+ */
+module.exports.Dispatcher = __webpack_require__(149);
+/***/ }),
+/* 54 */
+/***/ (function(module, exports, __webpack_require__) {
+"use strict";
-var objectWithoutProperties = function (obj, keys) {
- var target = {};
+Object.defineProperty(exports, "__esModule", {
+ value: true
+});
- for (var i in obj) {
- if (keys.indexOf(i) >= 0) continue;
- if (!Object.prototype.hasOwnProperty.call(obj, i)) continue;
- target[i] = obj[i];
- }
+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; };
- return target;
-};
+var _react = __webpack_require__(0);
-var possibleConstructorReturn = function (self, call) {
- if (!self) {
- throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
- }
+var _react2 = _interopRequireDefault(_react);
- return call && (typeof call === "object" || typeof call === "function") ? call : self;
-};
+var _propTypes = __webpack_require__(1);
-var Option = function (_React$Component) {
- inherits(Option, _React$Component);
+var _propTypes2 = _interopRequireDefault(_propTypes);
- function Option(props) {
- classCallCheck(this, Option);
+var _ajaxGet = __webpack_require__(151);
- var _this = possibleConstructorReturn(this, (Option.__proto__ || Object.getPrototypeOf(Option)).call(this, props));
+var _ajaxGet2 = _interopRequireDefault(_ajaxGet);
- _this.handleMouseDown = _this.handleMouseDown.bind(_this);
- _this.handleMouseEnter = _this.handleMouseEnter.bind(_this);
- _this.handleMouseMove = _this.handleMouseMove.bind(_this);
- _this.handleTouchStart = _this.handleTouchStart.bind(_this);
- _this.handleTouchEnd = _this.handleTouchEnd.bind(_this);
- _this.handleTouchMove = _this.handleTouchMove.bind(_this);
- _this.onFocus = _this.onFocus.bind(_this);
- return _this;
- }
+var _utils = __webpack_require__(152);
- createClass(Option, [{
- key: 'handleMouseDown',
- value: function handleMouseDown(event) {
- event.preventDefault();
- event.stopPropagation();
- this.props.onSelect(this.props.option, event);
- }
- }, {
- key: 'handleMouseEnter',
- value: function handleMouseEnter(event) {
- this.onFocus(event);
- }
- }, {
- key: 'handleMouseMove',
- value: function handleMouseMove(event) {
- this.onFocus(event);
- }
- }, {
- key: 'handleTouchEnd',
- value: function handleTouchEnd(event) {
- // Check if the view is being dragged, In this case
- // we don't want to fire the click event (because the user only wants to scroll)
- if (this.dragging) return;
+var utils = _interopRequireWildcard(_utils);
- this.handleMouseDown(event);
- }
- }, {
- key: 'handleTouchMove',
- value: function handleTouchMove() {
- // Set a flag that the view is being dragged
- this.dragging = true;
- }
- }, {
- key: 'handleTouchStart',
- value: function handleTouchStart() {
- // Set a flag that the view is not being dragged
- this.dragging = false;
- }
- }, {
- key: 'onFocus',
- value: function onFocus(event) {
- if (!this.props.isFocused) {
- this.props.onFocus(this.props.option, event);
- }
- }
- }, {
- key: 'render',
- value: function render() {
- var _props = this.props,
- option = _props.option,
- instancePrefix = _props.instancePrefix,
- optionIndex = _props.optionIndex;
+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 className = classnames__WEBPACK_IMPORTED_MODULE_1___default()(this.props.className, option.className);
+function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
- return option.disabled ? react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement(
- 'div',
- { className: className,
- onMouseDown: blockEvent,
- onClick: blockEvent },
- this.props.children
- ) : react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement(
- 'div',
- { className: className,
- style: option.style,
- role: 'option',
- 'aria-label': option.label,
- onMouseDown: this.handleMouseDown,
- onMouseEnter: this.handleMouseEnter,
- onMouseMove: this.handleMouseMove,
- onTouchStart: this.handleTouchStart,
- onTouchMove: this.handleTouchMove,
- onTouchEnd: this.handleTouchEnd,
- id: instancePrefix + '-option-' + optionIndex,
- title: option.title },
- this.props.children
- );
- }
- }]);
- return Option;
-}(react__WEBPACK_IMPORTED_MODULE_3___default.a.Component);
-
-Option.propTypes = {
- children: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.node,
- className: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string, // className (based on mouse position)
- instancePrefix: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string.isRequired, // unique prefix for the ids (used for aria)
- isDisabled: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // the option is disabled
- isFocused: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // the option is focused
- isSelected: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // the option is selected
- onFocus: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func, // method to handle mouseEnter on option element
- onSelect: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func, // method to handle click on option element
- onUnfocus: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func, // method to handle mouseLeave on option element
- option: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.object.isRequired, // object that is base for that option
- optionIndex: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.number // index of the option, used to generate unique ids for aria
-};
-
-var Value = function (_React$Component) {
- inherits(Value, _React$Component);
+function _defaults(obj, defaults) { var keys = Object.getOwnPropertyNames(defaults); for (var i = 0; i < keys.length; i++) { var key = keys[i]; var value = Object.getOwnPropertyDescriptor(defaults, key); if (value && value.configurable && obj[key] === undefined) { Object.defineProperty(obj, key, value); } } return obj; }
- function Value(props) {
- classCallCheck(this, Value);
+function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
- var _this = possibleConstructorReturn(this, (Value.__proto__ || Object.getPrototypeOf(Value)).call(this, props));
+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; }
- _this.handleMouseDown = _this.handleMouseDown.bind(_this);
- _this.onRemove = _this.onRemove.bind(_this);
- _this.handleTouchEndRemove = _this.handleTouchEndRemove.bind(_this);
- _this.handleTouchMove = _this.handleTouchMove.bind(_this);
- _this.handleTouchStart = _this.handleTouchStart.bind(_this);
- return _this;
- }
+function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
- createClass(Value, [{
- key: 'handleMouseDown',
- value: function handleMouseDown(event) {
- if (event.type === 'mousedown' && event.button !== 0) {
- return;
- }
- if (this.props.onClick) {
- event.stopPropagation();
- this.props.onClick(this.props.value, event);
- return;
- }
- if (this.props.value.href) {
- event.stopPropagation();
- }
- }
- }, {
- key: 'onRemove',
- value: function onRemove(event) {
- event.preventDefault();
- event.stopPropagation();
- this.props.onRemove(this.props.value);
- }
- }, {
- key: 'handleTouchEndRemove',
- value: function handleTouchEndRemove(event) {
- // Check if the view is being dragged, In this case
- // we don't want to fire the click event (because the user only wants to scroll)
- if (this.dragging) return;
+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; }
- // Fire the mouse events
- this.onRemove(event);
- }
- }, {
- key: 'handleTouchMove',
- value: function handleTouchMove() {
- // Set a flag that the view is being dragged
- this.dragging = true;
- }
- }, {
- key: 'handleTouchStart',
- value: function handleTouchStart() {
- // Set a flag that the view is not being dragged
- this.dragging = false;
- }
- }, {
- key: 'renderRemoveIcon',
- value: function renderRemoveIcon() {
- if (this.props.disabled || !this.props.onRemove) return;
- return react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement(
- 'span',
- { className: 'Select-value-icon',
- 'aria-hidden': 'true',
- onMouseDown: this.onRemove,
- onTouchEnd: this.handleTouchEndRemove,
- onTouchStart: this.handleTouchStart,
- onTouchMove: this.handleTouchMove },
- '\xD7'
- );
- }
- }, {
- key: 'renderLabel',
- value: function renderLabel() {
- var className = 'Select-value-label';
- return this.props.onClick || this.props.value.href ? react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement(
- 'a',
- { className: className, href: this.props.value.href, target: this.props.value.target, onMouseDown: this.handleMouseDown, onTouchEnd: this.handleMouseDown },
- this.props.children
- ) : react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement(
- 'span',
- { className: className, role: 'option', 'aria-selected': 'true', id: this.props.id },
- this.props.children
- );
- }
- }, {
- key: 'render',
- value: function render() {
- return react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement(
- 'div',
- { className: classnames__WEBPACK_IMPORTED_MODULE_1___default()('Select-value', this.props.value.disabled ? 'Select-value-disabled' : '', this.props.value.className),
- style: this.props.value.style,
- title: this.props.value.title
- },
- this.renderRemoveIcon(),
- this.renderLabel()
- );
- }
- }]);
- return Value;
-}(react__WEBPACK_IMPORTED_MODULE_3___default.a.Component);
+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) : _defaults(subClass, superClass); }
-Value.propTypes = {
- children: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.node,
- disabled: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // disabled prop passed to ReactSelect
- id: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string, // Unique id for the value - used for aria
- onClick: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func, // method to handle click on value label
- onRemove: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func, // method to handle removal of the value
- value: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.object.isRequired // the option object for this value
+var typeToLabel = {
+ stargazers: 'Star',
+ watchers: 'Watch',
+ forks: 'Fork'
};
-/*!
- Copyright (c) 2018 Jed Watson.
- Licensed under the MIT License (MIT), see
- http://jedwatson.github.io/react-select
-*/
-var stringifyValue = function stringifyValue(value) {
- return typeof value === 'string' ? value : value !== null && JSON.stringify(value) || '';
+var typeToPath = {
+ forks: 'network'
};
-var stringOrNode = prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.oneOfType([prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string, prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.node]);
-var stringOrNumber = prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.oneOfType([prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string, prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.number]);
+var GitHubButton = function (_React$Component) {
+ _inherits(GitHubButton, _React$Component);
-var instanceId = 1;
+ function GitHubButton() {
+ var _temp, _this, _ret;
-var shouldShowValue = function shouldShowValue(state, props) {
- var inputValue = state.inputValue,
- isPseudoFocused = state.isPseudoFocused,
- isFocused = state.isFocused;
- var onSelectResetsInput = props.onSelectResetsInput;
+ _classCallCheck(this, GitHubButton);
+ for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {
+ args[_key] = arguments[_key];
+ }
- if (!inputValue) return true;
+ return _ret = (_temp = (_this = _possibleConstructorReturn(this, _React$Component.call.apply(_React$Component, [this].concat(args))), _this), _this.state = {
+ count: null
+ }, _temp), _possibleConstructorReturn(_this, _ret);
+ }
- if (!onSelectResetsInput) {
- return !(!isFocused && isPseudoFocused || isFocused && !isPseudoFocused);
- }
+ GitHubButton.prototype.componentDidMount = function componentDidMount() {
+ var _this2 = this;
- return false;
-};
+ this.xhr = (0, _ajaxGet2["default"])(this.getRequestUrl(), function (response) {
+ _this2.setCount(response);
+ });
+ };
-var shouldShowPlaceholder = function shouldShowPlaceholder(state, props, isOpen) {
- var inputValue = state.inputValue,
- isPseudoFocused = state.isPseudoFocused,
- isFocused = state.isFocused;
- var onSelectResetsInput = props.onSelectResetsInput;
+ GitHubButton.prototype.componentWillUnmount = function componentWillUnmount() {
+ if (this.xhr) {
+ this.xhr.abort();
+ }
+ };
+ GitHubButton.prototype.setCount = function setCount(data) {
+ if (!data) return;
+ var count = data[this.props.type + '_count'];
+ this.setState({ count: count });
+ };
- return !inputValue || !onSelectResetsInput && !isOpen && !isPseudoFocused && !isFocused;
-};
+ GitHubButton.prototype.getRequestUrl = function getRequestUrl() {
+ var _props = this.props,
+ namespace = _props.namespace,
+ repo = _props.repo;
-/**
- * Retrieve a value from the given options and valueKey
- * @param {String|Number|Array} value - the selected value(s)
- * @param {Object} props - the Select component's props (or nextProps)
- */
-var expandValue = function expandValue(value, props) {
- var valueType = typeof value === 'undefined' ? 'undefined' : _typeof(value);
- if (valueType !== 'string' && valueType !== 'number' && valueType !== 'boolean') return value;
- var options = props.options,
- valueKey = props.valueKey;
+ return '//api.github.com/repos/' + namespace + '/' + repo;
+ };
- if (!options) return;
- for (var i = 0; i < options.length; i++) {
- if (String(options[i][valueKey]) === String(value)) return options[i];
- }
-};
+ GitHubButton.prototype.getRepoUrl = function getRepoUrl() {
+ var _props2 = this.props,
+ namespace = _props2.namespace,
+ repo = _props2.repo;
-var handleRequired = function handleRequired(value, multi) {
- if (!value) return true;
- return multi ? value.length === 0 : Object.keys(value).length === 0;
-};
+ return '//github.com/' + namespace + '/' + repo + '/';
+ };
-var Select$1 = function (_React$Component) {
- inherits(Select, _React$Component);
+ GitHubButton.prototype.getCountUrl = function getCountUrl() {
+ var _props3 = this.props,
+ namespace = _props3.namespace,
+ repo = _props3.repo,
+ type = _props3.type;
- function Select(props) {
- classCallCheck(this, Select);
+ return '//github.com/' + namespace + '/' + repo + '/' + (typeToPath[type] || type) + '/';
+ };
- var _this = possibleConstructorReturn(this, (Select.__proto__ || Object.getPrototypeOf(Select)).call(this, props));
+ GitHubButton.prototype.getCountStyle = function getCountStyle() {
+ var count = this.state.count;
+ if (count !== null) {
+ return {
+ display: 'block'
+ };
+ }
+ return null;
+ };
- ['clearValue', 'focusOption', 'getOptionLabel', 'handleInputBlur', 'handleInputChange', 'handleInputFocus', 'handleInputValueChange', 'handleKeyDown', 'handleMenuScroll', 'handleMouseDown', 'handleMouseDownOnArrow', 'handleMouseDownOnMenu', 'handleTouchEnd', 'handleTouchEndClearValue', 'handleTouchMove', 'handleTouchOutside', 'handleTouchStart', 'handleValueClick', 'onOptionRef', 'removeValue', 'selectValue'].forEach(function (fn) {
- return _this[fn] = _this[fn].bind(_this);
- });
-
- _this.state = {
- inputValue: '',
- isFocused: false,
- isOpen: false,
- isPseudoFocused: false,
- required: false
- };
- return _this;
- }
+ GitHubButton.prototype.render = function render() {
+ var _props4 = this.props,
+ className = _props4.className,
+ type = _props4.type,
+ size = _props4.size,
+ rest = _objectWithoutProperties(_props4, ['className', 'type', 'size']);
- createClass(Select, [{
- key: 'componentWillMount',
- value: function componentWillMount() {
- this._instancePrefix = 'react-select-' + (this.props.instanceId || ++instanceId) + '-';
- var valueArray = this.getValueArray(this.props.value);
+ delete rest.namespace;
+ delete rest.repo;
- if (this.props.required) {
- this.setState({
- required: handleRequired(valueArray[0], this.props.multi)
- });
- }
- }
- }, {
- key: 'componentDidMount',
- value: function componentDidMount() {
- if (typeof this.props.autofocus !== 'undefined' && typeof console !== 'undefined') {
- console.warn('Warning: The autofocus prop has changed to autoFocus, support will be removed after react-select@1.0');
- }
- if (this.props.autoFocus || this.props.autofocus) {
- this.focus();
- }
- }
- }, {
- key: 'componentWillReceiveProps',
- value: function componentWillReceiveProps(nextProps) {
- var valueArray = this.getValueArray(nextProps.value, nextProps);
+ var count = this.state.count;
- if (nextProps.required) {
- this.setState({
- required: handleRequired(valueArray[0], nextProps.multi)
- });
- } else if (this.props.required) {
- // Used to be required but it's not any more
- this.setState({ required: false });
- }
+ var buttonClassName = utils.classNames(_defineProperty({
+ 'github-btn': true,
+ 'github-btn-large': size === 'large'
+ }, className, className));
- if (this.state.inputValue && this.props.value !== nextProps.value && nextProps.onSelectResetsInput) {
- this.setState({ inputValue: this.handleInputValueChange('') });
- }
- }
- }, {
- key: 'componentDidUpdate',
- value: function componentDidUpdate(prevProps, prevState) {
- // focus to the selected option
- if (this.menu && this.focused && this.state.isOpen && !this.hasScrolledToOption) {
- var focusedOptionNode = Object(react_dom__WEBPACK_IMPORTED_MODULE_4__["findDOMNode"])(this.focused);
- var menuNode = Object(react_dom__WEBPACK_IMPORTED_MODULE_4__["findDOMNode"])(this.menu);
+ return _react2["default"].createElement(
+ 'span',
+ _extends({}, rest, { className: buttonClassName }),
+ _react2["default"].createElement(
+ 'a',
+ { className: 'gh-btn', href: this.getRepoUrl(), target: '_blank' },
+ _react2["default"].createElement('span', { className: 'gh-ico', 'aria-hidden': 'true' }),
+ _react2["default"].createElement(
+ 'span',
+ { className: 'gh-text' },
+ typeToLabel[type]
+ )
+ ),
+ _react2["default"].createElement(
+ 'a',
+ { className: 'gh-count', target: '_blank',
+ href: this.getCountUrl(),
+ style: this.getCountStyle()
+ },
+ count
+ )
+ );
+ };
- var scrollTop = menuNode.scrollTop;
- var scrollBottom = scrollTop + menuNode.offsetHeight;
- var optionTop = focusedOptionNode.offsetTop;
- var optionBottom = optionTop + focusedOptionNode.offsetHeight;
+ return GitHubButton;
+}(_react2["default"].Component);
- if (scrollTop > optionTop || scrollBottom < optionBottom) {
- menuNode.scrollTop = focusedOptionNode.offsetTop;
- }
+GitHubButton.displayName = 'GitHubButton';
+GitHubButton.propTypes = {
+ className: _propTypes2["default"].string,
+ type: _propTypes2["default"].oneOf(['stargazers', 'watchers', 'forks']).isRequired,
+ namespace: _propTypes2["default"].string.isRequired,
+ repo: _propTypes2["default"].string.isRequired,
+ size: _propTypes2["default"].oneOf(['large'])
+};
+exports["default"] = GitHubButton;
+module.exports = exports['default'];
- // We still set hasScrolledToOption to true even if we didn't
- // actually need to scroll, as we've still confirmed that the
- // option is in view.
- this.hasScrolledToOption = true;
- } else if (!this.state.isOpen) {
- this.hasScrolledToOption = false;
- }
+/***/ }),
+/* 55 */
+/***/ (function(module, exports, __webpack_require__) {
- if (this._scrollToFocusedOptionOnUpdate && this.focused && this.menu) {
- this._scrollToFocusedOptionOnUpdate = false;
- var focusedDOM = Object(react_dom__WEBPACK_IMPORTED_MODULE_4__["findDOMNode"])(this.focused);
- var menuDOM = Object(react_dom__WEBPACK_IMPORTED_MODULE_4__["findDOMNode"])(this.menu);
- var focusedRect = focusedDOM.getBoundingClientRect();
- var menuRect = menuDOM.getBoundingClientRect();
- if (focusedRect.bottom > menuRect.bottom) {
- menuDOM.scrollTop = focusedDOM.offsetTop + focusedDOM.clientHeight - menuDOM.offsetHeight;
- } else if (focusedRect.top < menuRect.top) {
- menuDOM.scrollTop = focusedDOM.offsetTop;
- }
- }
- if (this.props.scrollMenuIntoView && this.menuContainer) {
- var menuContainerRect = this.menuContainer.getBoundingClientRect();
- if (window.innerHeight < menuContainerRect.bottom + this.props.menuBuffer) {
- window.scrollBy(0, menuContainerRect.bottom + this.props.menuBuffer - window.innerHeight);
- }
- }
- if (prevProps.disabled !== this.props.disabled) {
- this.setState({ isFocused: false }); // eslint-disable-line react/no-did-update-set-state
- this.closeMenu();
- }
- if (prevState.isOpen !== this.state.isOpen) {
- this.toggleTouchOutsideEvent(this.state.isOpen);
- var handler = this.state.isOpen ? this.props.onOpen : this.props.onClose;
- handler && handler();
- }
- }
- }, {
- key: 'componentWillUnmount',
- value: function componentWillUnmount() {
- this.toggleTouchOutsideEvent(false);
- }
- }, {
- key: 'toggleTouchOutsideEvent',
- value: function toggleTouchOutsideEvent(enabled) {
- var eventTogglerName = enabled ? document.addEventListener ? 'addEventListener' : 'attachEvent' : document.removeEventListener ? 'removeEventListener' : 'detachEvent';
- var pref = document.addEventListener ? '' : 'on';
+module.exports = __webpack_require__(161);
- document[eventTogglerName](pref + 'touchstart', this.handleTouchOutside);
- document[eventTogglerName](pref + 'mousedown', this.handleTouchOutside);
- }
- }, {
- key: 'handleTouchOutside',
- value: function handleTouchOutside(event) {
- // handle touch outside on ios to dismiss menu
- if (this.wrapper && !this.wrapper.contains(event.target)) {
- this.closeMenu();
- }
- }
- }, {
- key: 'focus',
- value: function focus() {
- if (!this.input) return;
- this.input.focus();
- }
- }, {
- key: 'blurInput',
- value: function blurInput() {
- if (!this.input) return;
- this.input.blur();
- }
- }, {
- key: 'handleTouchMove',
- value: function handleTouchMove() {
- // Set a flag that the view is being dragged
- this.dragging = true;
- }
- }, {
- key: 'handleTouchStart',
- value: function handleTouchStart() {
- // Set a flag that the view is not being dragged
- this.dragging = false;
- }
- }, {
- key: 'handleTouchEnd',
- value: function handleTouchEnd(event) {
- // Check if the view is being dragged, In this case
- // we don't want to fire the click event (because the user only wants to scroll)
- if (this.dragging) return;
- // Fire the mouse events
- this.handleMouseDown(event);
- }
- }, {
- key: 'handleTouchEndClearValue',
- value: function handleTouchEndClearValue(event) {
- // Check if the view is being dragged, In this case
- // we don't want to fire the click event (because the user only wants to scroll)
- if (this.dragging) return;
+/***/ }),
+/* 56 */
+/***/ (function(module, exports, __webpack_require__) {
- // Clear the value
- this.clearValue(event);
- }
- }, {
- key: 'handleMouseDown',
- value: function handleMouseDown(event) {
- // if the event was triggered by a mousedown and not the primary
- // button, or if the component is disabled, ignore it.
- if (this.props.disabled || event.type === 'mousedown' && event.button !== 0) {
- return;
- }
+"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.
+ */
- if (event.target.tagName === 'INPUT') {
- if (!this.state.isFocused) {
- this._openAfterFocus = this.props.openOnClick;
- this.focus();
- } else if (!this.state.isOpen) {
- this.setState({
- isOpen: true,
- isPseudoFocused: false,
- focusedOption: null
- });
- }
- return;
- }
- // prevent default event handlers
- event.preventDefault();
+var ReactPropTypesSecret = __webpack_require__(57);
- // for the non-searchable select, toggle the menu
- if (!this.props.searchable) {
- // This code means that if a select is searchable, onClick the options menu will not appear, only on subsequent click will it open.
- this.focus();
- return this.setState({
- isOpen: !this.state.isOpen,
- focusedOption: null
- });
- }
+function emptyFunction() {}
+function emptyFunctionWithReset() {}
+emptyFunctionWithReset.resetWarningCache = emptyFunction;
- if (this.state.isFocused) {
- // On iOS, we can get into a state where we think the input is focused but it isn't really,
- // since iOS ignores programmatic calls to input.focus() that weren't triggered by a click event.
- // Call focus() again here to be safe.
- this.focus();
+module.exports = function() {
+ function shim(props, propName, componentName, location, propFullName, secret) {
+ if (secret === ReactPropTypesSecret) {
+ // It is still safe when called from React.
+ return;
+ }
+ var err = new Error(
+ 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +
+ 'Use PropTypes.checkPropTypes() to call them. ' +
+ 'Read more at http://fb.me/use-check-prop-types'
+ );
+ err.name = 'Invariant Violation';
+ throw err;
+ };
+ shim.isRequired = shim;
+ function getShim() {
+ return shim;
+ };
+ // Important!
+ // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.
+ var ReactPropTypes = {
+ array: shim,
+ bool: shim,
+ func: shim,
+ number: shim,
+ object: shim,
+ string: shim,
+ symbol: shim,
- var input = this.input;
- var toOpen = true;
+ any: shim,
+ arrayOf: getShim,
+ element: shim,
+ elementType: shim,
+ instanceOf: getShim,
+ node: shim,
+ objectOf: getShim,
+ oneOf: getShim,
+ oneOfType: getShim,
+ shape: getShim,
+ exact: getShim,
- if (typeof input.getInput === 'function') {
- // Get the actual DOM input if the ref is an component
- input = input.getInput();
- }
+ checkPropTypes: emptyFunctionWithReset,
+ resetWarningCache: emptyFunction
+ };
- // clears the value so that the cursor will be at the end of input when the component re-renders
- input.value = '';
+ ReactPropTypes.PropTypes = ReactPropTypes;
- if (this._focusAfterClear) {
- toOpen = false;
- this._focusAfterClear = false;
- }
+ return ReactPropTypes;
+};
- // if the input is focused, ensure the menu is open
- this.setState({
- isOpen: toOpen,
- isPseudoFocused: false,
- focusedOption: null
- });
- } else {
- // otherwise, focus the input and open the menu
- this._openAfterFocus = this.props.openOnClick;
- this.focus();
- this.setState({ focusedOption: null });
- }
- }
- }, {
- key: 'handleMouseDownOnArrow',
- value: function handleMouseDownOnArrow(event) {
- // if the event was triggered by a mousedown and not the primary
- // button, or if the component is disabled, ignore it.
- if (this.props.disabled || event.type === 'mousedown' && event.button !== 0) {
- return;
- }
- if (this.state.isOpen) {
- // prevent default event handlers
- event.stopPropagation();
- event.preventDefault();
- // close the menu
- this.closeMenu();
- } else {
- // If the menu isn't open, let the event bubble to the main handleMouseDown
- this.setState({
- isOpen: true
- });
- }
- }
- }, {
- key: 'handleMouseDownOnMenu',
- value: function handleMouseDownOnMenu(event) {
- // if the event was triggered by a mousedown and not the primary
- // button, or if the component is disabled, ignore it.
- if (this.props.disabled || event.type === 'mousedown' && event.button !== 0) {
- return;
- }
+/***/ }),
+/* 57 */
+/***/ (function(module, exports, __webpack_require__) {
- event.stopPropagation();
- event.preventDefault();
+"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.
+ */
- this._openAfterFocus = true;
- this.focus();
- }
- }, {
- key: 'closeMenu',
- value: function closeMenu() {
- if (this.props.onCloseResetsInput) {
- this.setState({
- inputValue: this.handleInputValueChange(''),
- isOpen: false,
- isPseudoFocused: this.state.isFocused && !this.props.multi
- });
- } else {
- this.setState({
- isOpen: false,
- isPseudoFocused: this.state.isFocused && !this.props.multi
- });
- }
- this.hasScrolledToOption = false;
- }
- }, {
- key: 'handleInputFocus',
- value: function handleInputFocus(event) {
- if (this.props.disabled) return;
- var toOpen = this.state.isOpen || this._openAfterFocus || this.props.openOnFocus;
- toOpen = this._focusAfterClear ? false : toOpen; //if focus happens after clear values, don't open dropdown yet.
- if (this.props.onFocus) {
- this.props.onFocus(event);
- }
+var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';
- this.setState({
- isFocused: true,
- isOpen: !!toOpen
- });
+module.exports = ReactPropTypesSecret;
- this._focusAfterClear = false;
- this._openAfterFocus = false;
- }
- }, {
- key: 'handleInputBlur',
- value: function handleInputBlur(event) {
- // The check for menu.contains(activeElement) is necessary to prevent IE11's scrollbar from closing the menu in certain contexts.
- if (this.menu && (this.menu === document.activeElement || this.menu.contains(document.activeElement))) {
- this.focus();
- return;
- }
- if (this.props.onBlur) {
- this.props.onBlur(event);
- }
- var onBlurredState = {
- isFocused: false,
- isOpen: false,
- isPseudoFocused: false
- };
- if (this.props.onBlurResetsInput) {
- onBlurredState.inputValue = this.handleInputValueChange('');
- }
- this.setState(onBlurredState);
- }
- }, {
- key: 'handleInputChange',
- value: function handleInputChange(event) {
- var newInputValue = event.target.value;
+/***/ }),
+/* 58 */
+/***/ (function(module, exports, __webpack_require__) {
- if (this.state.inputValue !== event.target.value) {
- newInputValue = this.handleInputValueChange(newInputValue);
- }
+"use strict";
- this.setState({
- inputValue: newInputValue,
- isOpen: true,
- isPseudoFocused: false
- });
- }
- }, {
- key: 'setInputValue',
- value: function setInputValue(newValue) {
- if (this.props.onInputChange) {
- var nextState = this.props.onInputChange(newValue);
- if (nextState != null && (typeof nextState === 'undefined' ? 'undefined' : _typeof(nextState)) !== 'object') {
- newValue = '' + nextState;
- }
- }
- this.setState({
- inputValue: newValue
- });
- }
- }, {
- key: 'handleInputValueChange',
- value: function handleInputValueChange(newValue) {
- if (this.props.onInputChange) {
- var nextState = this.props.onInputChange(newValue);
- // Note: != used deliberately here to catch undefined and null
- if (nextState != null && (typeof nextState === 'undefined' ? 'undefined' : _typeof(nextState)) !== 'object') {
- newValue = '' + nextState;
- }
- }
- return newValue;
- }
- }, {
- key: 'handleKeyDown',
- value: function handleKeyDown(event) {
- if (this.props.disabled) return;
- if (typeof this.props.onInputKeyDown === 'function') {
- this.props.onInputKeyDown(event);
- if (event.defaultPrevented) {
- return;
- }
- }
+exports.__esModule = true;
- switch (event.keyCode) {
- case 8:
- // backspace
- if (!this.state.inputValue && this.props.backspaceRemoves) {
- event.preventDefault();
- this.popValue();
- }
- break;
- case 9:
- // tab
- if (event.shiftKey || !this.state.isOpen || !this.props.tabSelectsValue) {
- break;
- }
- event.preventDefault();
- this.selectFocusedOption();
- break;
- case 13:
- // enter
- event.preventDefault();
- event.stopPropagation();
- if (this.state.isOpen) {
- this.selectFocusedOption();
- } else {
- this.focusNextOption();
- }
- break;
- case 27:
- // escape
- event.preventDefault();
- if (this.state.isOpen) {
- this.closeMenu();
- event.stopPropagation();
- } else if (this.props.clearable && this.props.escapeClearsValue) {
- this.clearValue(event);
- event.stopPropagation();
- }
- break;
- case 32:
- // space
- if (this.props.searchable) {
- break;
- }
- event.preventDefault();
- if (!this.state.isOpen) {
- this.focusNextOption();
- break;
- }
- event.stopPropagation();
- this.selectFocusedOption();
- break;
- case 38:
- // up
- event.preventDefault();
- this.focusPreviousOption();
- break;
- case 40:
- // down
- event.preventDefault();
- this.focusNextOption();
- break;
- case 33:
- // page up
- event.preventDefault();
- this.focusPageUpOption();
- break;
- case 34:
- // page down
- event.preventDefault();
- this.focusPageDownOption();
- break;
- case 35:
- // end key
- if (event.shiftKey) {
- break;
- }
- event.preventDefault();
- this.focusEndOption();
- break;
- case 36:
- // home key
- if (event.shiftKey) {
- break;
- }
- event.preventDefault();
- this.focusStartOption();
- break;
- case 46:
- // delete
- if (!this.state.inputValue && this.props.deleteRemoves) {
- event.preventDefault();
- this.popValue();
- }
- break;
- }
- }
- }, {
- key: 'handleValueClick',
- value: function handleValueClick(option, event) {
- if (!this.props.onValueClick) return;
- this.props.onValueClick(option, event);
- }
- }, {
- key: 'handleMenuScroll',
- value: function handleMenuScroll(event) {
- if (!this.props.onMenuScrollToBottom) return;
- var target = event.target;
+var _iterator = __webpack_require__(59);
- if (target.scrollHeight > target.offsetHeight && target.scrollHeight - target.offsetHeight - target.scrollTop <= 0) {
- this.props.onMenuScrollToBottom();
- }
- }
- }, {
- key: 'getOptionLabel',
- value: function getOptionLabel(op) {
- return op[this.props.labelKey];
- }
+var _iterator2 = _interopRequireDefault(_iterator);
- /**
- * Turns a value into an array from the given options
- * @param {String|Number|Array} value - the value of the select input
- * @param {Object} nextProps - optionally specify the nextProps so the returned array uses the latest configuration
- * @returns {Array} the value of the select represented in an array
- */
+var _symbol = __webpack_require__(74);
- }, {
- key: 'getValueArray',
- value: function getValueArray(value) {
- var nextProps = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : undefined;
+var _symbol2 = _interopRequireDefault(_symbol);
- /** support optionally passing in the `nextProps` so `componentWillReceiveProps` updates will function as expected */
- var props = (typeof nextProps === 'undefined' ? 'undefined' : _typeof(nextProps)) === 'object' ? nextProps : this.props;
- if (props.multi) {
- if (typeof value === 'string') {
- value = value.split(props.delimiter);
- }
- if (!Array.isArray(value)) {
- if (value === null || value === undefined) return [];
- value = [value];
- }
- return value.map(function (value) {
- return expandValue(value, props);
- }).filter(function (i) {
- return i;
- });
- }
- var expandedValue = expandValue(value, props);
- return expandedValue ? [expandedValue] : [];
- }
- }, {
- key: 'setValue',
- value: function setValue(value) {
- var _this2 = this;
+var _typeof = typeof _symbol2.default === "function" && typeof _iterator2.default === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof _symbol2.default === "function" && obj.constructor === _symbol2.default && obj !== _symbol2.default.prototype ? "symbol" : typeof obj; };
- if (this.props.autoBlur) {
- this.blurInput();
- }
- if (this.props.required) {
- var required = handleRequired(value, this.props.multi);
- this.setState({ required: required });
- }
- if (this.props.simpleValue && value) {
- value = this.props.multi ? value.map(function (i) {
- return i[_this2.props.valueKey];
- }).join(this.props.delimiter) : value[this.props.valueKey];
- }
- if (this.props.onChange) {
- this.props.onChange(value);
- }
- }
- }, {
- key: 'selectValue',
- value: function selectValue(value) {
- var _this3 = this;
+function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
- // NOTE: we actually add/set the value in a callback to make sure the
- // input value is empty to avoid styling issues in Chrome
- if (this.props.closeOnSelect) {
- this.hasScrolledToOption = false;
- }
- var updatedValue = this.props.onSelectResetsInput ? '' : this.state.inputValue;
- if (this.props.multi) {
- this.setState({
- focusedIndex: null,
- inputValue: this.handleInputValueChange(updatedValue),
- isOpen: !this.props.closeOnSelect
- }, function () {
- var valueArray = _this3.getValueArray(_this3.props.value);
- if (valueArray.some(function (i) {
- return i[_this3.props.valueKey] === value[_this3.props.valueKey];
- })) {
- _this3.removeValue(value);
- } else {
- _this3.addValue(value);
- }
- });
- } else {
- this.setState({
- inputValue: this.handleInputValueChange(updatedValue),
- isOpen: !this.props.closeOnSelect,
- isPseudoFocused: this.state.isFocused
- }, function () {
- _this3.setValue(value);
- });
- }
- }
- }, {
- key: 'addValue',
- value: function addValue(value) {
- var valueArray = this.getValueArray(this.props.value);
- var visibleOptions = this._visibleOptions.filter(function (val) {
- return !val.disabled;
- });
- var lastValueIndex = visibleOptions.indexOf(value);
- this.setValue(valueArray.concat(value));
- if (!this.props.closeOnSelect) {
- return;
- }
- if (visibleOptions.length - 1 === lastValueIndex) {
- // the last option was selected; focus the second-last one
- this.focusOption(visibleOptions[lastValueIndex - 1]);
- } else if (visibleOptions.length > lastValueIndex) {
- // focus the option below the selected one
- this.focusOption(visibleOptions[lastValueIndex + 1]);
- }
- }
- }, {
- key: 'popValue',
- value: function popValue() {
- var valueArray = this.getValueArray(this.props.value);
- if (!valueArray.length) return;
- if (valueArray[valueArray.length - 1].clearableValue === false) return;
- this.setValue(this.props.multi ? valueArray.slice(0, valueArray.length - 1) : null);
- }
- }, {
- key: 'removeValue',
- value: function removeValue(value) {
- var _this4 = this;
+exports.default = typeof _symbol2.default === "function" && _typeof(_iterator2.default) === "symbol" ? function (obj) {
+ return typeof obj === "undefined" ? "undefined" : _typeof(obj);
+} : function (obj) {
+ return obj && typeof _symbol2.default === "function" && obj.constructor === _symbol2.default && obj !== _symbol2.default.prototype ? "symbol" : typeof obj === "undefined" ? "undefined" : _typeof(obj);
+};
- var valueArray = this.getValueArray(this.props.value);
- this.setValue(valueArray.filter(function (i) {
- return i[_this4.props.valueKey] !== value[_this4.props.valueKey];
- }));
- this.focus();
- }
- }, {
- key: 'clearValue',
- value: function clearValue(event) {
- // if the event was triggered by a mousedown and not the primary
- // button, ignore it.
- if (event && event.type === 'mousedown' && event.button !== 0) {
- return;
- }
+/***/ }),
+/* 59 */
+/***/ (function(module, exports, __webpack_require__) {
- event.preventDefault();
+module.exports = { "default": __webpack_require__(60), __esModule: true };
- this.setValue(this.getResetValue());
- this.setState({
- inputValue: this.handleInputValueChange(''),
- isOpen: false
- }, this.focus);
+/***/ }),
+/* 60 */
+/***/ (function(module, exports, __webpack_require__) {
- this._focusAfterClear = true;
- }
- }, {
- key: 'getResetValue',
- value: function getResetValue() {
- if (this.props.resetValue !== undefined) {
- return this.props.resetValue;
- } else if (this.props.multi) {
- return [];
- } else {
- return null;
- }
- }
- }, {
- key: 'focusOption',
- value: function focusOption(option) {
- this.setState({
- focusedOption: option
- });
- }
- }, {
- key: 'focusNextOption',
- value: function focusNextOption() {
- this.focusAdjacentOption('next');
- }
- }, {
- key: 'focusPreviousOption',
- value: function focusPreviousOption() {
- this.focusAdjacentOption('previous');
- }
- }, {
- key: 'focusPageUpOption',
- value: function focusPageUpOption() {
- this.focusAdjacentOption('page_up');
- }
- }, {
- key: 'focusPageDownOption',
- value: function focusPageDownOption() {
- this.focusAdjacentOption('page_down');
- }
- }, {
- key: 'focusStartOption',
- value: function focusStartOption() {
- this.focusAdjacentOption('start');
- }
- }, {
- key: 'focusEndOption',
- value: function focusEndOption() {
- this.focusAdjacentOption('end');
- }
- }, {
- key: 'focusAdjacentOption',
- value: function focusAdjacentOption(dir) {
- var options = this._visibleOptions.map(function (option, index) {
- return { option: option, index: index };
- }).filter(function (option) {
- return !option.option.disabled;
- });
- this._scrollToFocusedOptionOnUpdate = true;
- if (!this.state.isOpen) {
- var newState = {
- focusedOption: this._focusedOption || (options.length ? options[dir === 'next' ? 0 : options.length - 1].option : null),
- isOpen: true
- };
- if (this.props.onSelectResetsInput) {
- newState.inputValue = '';
- }
- this.setState(newState);
- return;
- }
- if (!options.length) return;
- var focusedIndex = -1;
- for (var i = 0; i < options.length; i++) {
- if (this._focusedOption === options[i].option) {
- focusedIndex = i;
- break;
- }
- }
- if (dir === 'next' && focusedIndex !== -1) {
- focusedIndex = (focusedIndex + 1) % options.length;
- } else if (dir === 'previous') {
- if (focusedIndex > 0) {
- focusedIndex = focusedIndex - 1;
- } else {
- focusedIndex = options.length - 1;
- }
- } else if (dir === 'start') {
- focusedIndex = 0;
- } else if (dir === 'end') {
- focusedIndex = options.length - 1;
- } else if (dir === 'page_up') {
- var potentialIndex = focusedIndex - this.props.pageSize;
- if (potentialIndex < 0) {
- focusedIndex = 0;
- } else {
- focusedIndex = potentialIndex;
- }
- } else if (dir === 'page_down') {
- var _potentialIndex = focusedIndex + this.props.pageSize;
- if (_potentialIndex > options.length - 1) {
- focusedIndex = options.length - 1;
- } else {
- focusedIndex = _potentialIndex;
- }
- }
+__webpack_require__(25);
+__webpack_require__(34);
+module.exports = __webpack_require__(35).f('iterator');
- if (focusedIndex === -1) {
- focusedIndex = 0;
- }
- this.setState({
- focusedIndex: options[focusedIndex].index,
- focusedOption: options[focusedIndex].option
- });
- }
- }, {
- key: 'getFocusedOption',
- value: function getFocusedOption() {
- return this._focusedOption;
- }
- }, {
- key: 'selectFocusedOption',
- value: function selectFocusedOption() {
- if (this._focusedOption) {
- return this.selectValue(this._focusedOption);
- }
- }
- }, {
- key: 'renderLoading',
- value: function renderLoading() {
- if (!this.props.isLoading) return;
- return react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement(
- 'span',
- { className: 'Select-loading-zone', 'aria-hidden': 'true' },
- react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement('span', { className: 'Select-loading' })
- );
- }
- }, {
- key: 'renderValue',
- value: function renderValue(valueArray, isOpen) {
- var _this5 = this;
+/***/ }),
+/* 61 */
+/***/ (function(module, exports, __webpack_require__) {
- var renderLabel = this.props.valueRenderer || this.getOptionLabel;
- var ValueComponent = this.props.valueComponent;
- if (!valueArray.length) {
- var showPlaceholder = shouldShowPlaceholder(this.state, this.props, isOpen);
- return showPlaceholder ? react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement(
- 'div',
- { className: 'Select-placeholder' },
- this.props.placeholder
- ) : null;
- }
- var onClick = this.props.onValueClick ? this.handleValueClick : null;
- if (this.props.multi) {
- return valueArray.map(function (value, i) {
- return react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement(
- ValueComponent,
- {
- disabled: _this5.props.disabled || value.clearableValue === false,
- id: _this5._instancePrefix + '-value-' + i,
- instancePrefix: _this5._instancePrefix,
- key: 'value-' + i + '-' + value[_this5.props.valueKey],
- onClick: onClick,
- onRemove: _this5.removeValue,
- placeholder: _this5.props.placeholder,
- value: value,
- values: valueArray
- },
- renderLabel(value, i),
- react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement(
- 'span',
- { className: 'Select-aria-only' },
- '\xA0'
- )
- );
- });
- } else if (shouldShowValue(this.state, this.props)) {
- if (isOpen) onClick = null;
- return react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement(
- ValueComponent,
- {
- disabled: this.props.disabled,
- id: this._instancePrefix + '-value-item',
- instancePrefix: this._instancePrefix,
- onClick: onClick,
- placeholder: this.props.placeholder,
- value: valueArray[0]
- },
- renderLabel(valueArray[0])
- );
- }
- }
- }, {
- key: 'renderInput',
- value: function renderInput(valueArray, focusedOptionIndex) {
- var _classNames,
- _this6 = this;
+var toInteger = __webpack_require__(26);
+var defined = __webpack_require__(27);
+// true -> String#at
+// false -> String#codePointAt
+module.exports = function (TO_STRING) {
+ return function (that, pos) {
+ var s = String(defined(that));
+ var i = toInteger(pos);
+ var l = s.length;
+ var a, b;
+ if (i < 0 || i >= l) return TO_STRING ? '' : undefined;
+ a = s.charCodeAt(i);
+ return a < 0xd800 || a > 0xdbff || i + 1 === l || (b = s.charCodeAt(i + 1)) < 0xdc00 || b > 0xdfff
+ ? TO_STRING ? s.charAt(i) : a
+ : TO_STRING ? s.slice(i, i + 2) : (a - 0xd800 << 10) + (b - 0xdc00) + 0x10000;
+ };
+};
- var className = classnames__WEBPACK_IMPORTED_MODULE_1___default()('Select-input', this.props.inputProps.className);
- var isOpen = this.state.isOpen;
- var ariaOwns = classnames__WEBPACK_IMPORTED_MODULE_1___default()((_classNames = {}, defineProperty(_classNames, this._instancePrefix + '-list', isOpen), defineProperty(_classNames, this._instancePrefix + '-backspace-remove-message', this.props.multi && !this.props.disabled && this.state.isFocused && !this.state.inputValue), _classNames));
+/***/ }),
+/* 62 */
+/***/ (function(module, exports, __webpack_require__) {
- var value = this.state.inputValue;
- if (value && !this.props.onSelectResetsInput && !this.state.isFocused) {
- // it hides input value when it is not focused and was not reset on select
- value = '';
- }
+// optional / simple context binding
+var aFunction = __webpack_require__(63);
+module.exports = function (fn, that, length) {
+ aFunction(fn);
+ if (that === undefined) return fn;
+ switch (length) {
+ case 1: return function (a) {
+ return fn.call(that, a);
+ };
+ case 2: return function (a, b) {
+ return fn.call(that, a, b);
+ };
+ case 3: return function (a, b, c) {
+ return fn.call(that, a, b, c);
+ };
+ }
+ return function (/* ...args */) {
+ return fn.apply(that, arguments);
+ };
+};
- var inputProps = _extends({}, this.props.inputProps, {
- 'aria-activedescendant': isOpen ? this._instancePrefix + '-option-' + focusedOptionIndex : this._instancePrefix + '-value',
- 'aria-describedby': this.props['aria-describedby'],
- 'aria-expanded': '' + isOpen,
- 'aria-haspopup': '' + isOpen,
- 'aria-label': this.props['aria-label'],
- 'aria-labelledby': this.props['aria-labelledby'],
- 'aria-owns': ariaOwns,
- onBlur: this.handleInputBlur,
- onChange: this.handleInputChange,
- onFocus: this.handleInputFocus,
- ref: function ref(_ref) {
- return _this6.input = _ref;
- },
- role: 'combobox',
- required: this.state.required,
- tabIndex: this.props.tabIndex,
- value: value
- });
- if (this.props.inputRenderer) {
- return this.props.inputRenderer(inputProps);
- }
+/***/ }),
+/* 63 */
+/***/ (function(module, exports) {
- if (this.props.disabled || !this.props.searchable) {
- var divProps = objectWithoutProperties(this.props.inputProps, []);
+module.exports = function (it) {
+ if (typeof it != 'function') throw TypeError(it + ' is not a function!');
+ return it;
+};
- var _ariaOwns = classnames__WEBPACK_IMPORTED_MODULE_1___default()(defineProperty({}, this._instancePrefix + '-list', isOpen));
- return react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement('div', _extends({}, divProps, {
- 'aria-expanded': isOpen,
- 'aria-owns': _ariaOwns,
- 'aria-activedescendant': isOpen ? this._instancePrefix + '-option-' + focusedOptionIndex : this._instancePrefix + '-value',
- 'aria-disabled': '' + this.props.disabled,
- 'aria-label': this.props['aria-label'],
- 'aria-labelledby': this.props['aria-labelledby'],
- className: className,
- onBlur: this.handleInputBlur,
- onFocus: this.handleInputFocus,
- ref: function ref(_ref2) {
- return _this6.input = _ref2;
- },
- role: 'combobox',
- style: { border: 0, width: 1, display: 'inline-block' },
- tabIndex: this.props.tabIndex || 0
- }));
- }
+/***/ }),
+/* 64 */
+/***/ (function(module, exports, __webpack_require__) {
- if (this.props.autosize) {
- return react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement(react_input_autosize__WEBPACK_IMPORTED_MODULE_0___default.a, _extends({ id: this.props.id }, inputProps, { className: className, minWidth: '5' }));
- }
- return react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement(
- 'div',
- { className: className, key: 'input-wrap', style: { display: 'inline-block' } },
- react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement('input', _extends({ id: this.props.id }, inputProps))
- );
- }
- }, {
- key: 'renderClear',
- value: function renderClear() {
- var valueArray = this.getValueArray(this.props.value);
- if (!this.props.clearable || !valueArray.length || this.props.disabled || this.props.isLoading) return;
- var ariaLabel = this.props.multi ? this.props.clearAllText : this.props.clearValueText;
- var clear = this.props.clearRenderer();
+"use strict";
- return react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement(
- 'span',
- {
- 'aria-label': ariaLabel,
- className: 'Select-clear-zone',
- onMouseDown: this.clearValue,
- onTouchEnd: this.handleTouchEndClearValue,
- onTouchMove: this.handleTouchMove,
- onTouchStart: this.handleTouchStart,
- title: ariaLabel
- },
- clear
- );
- }
- }, {
- key: 'renderArrow',
- value: function renderArrow() {
- if (!this.props.arrowRenderer) return;
+var create = __webpack_require__(43);
+var descriptor = __webpack_require__(20);
+var setToStringTag = __webpack_require__(33);
+var IteratorPrototype = {};
- var onMouseDown = this.handleMouseDownOnArrow;
- var isOpen = this.state.isOpen;
- var arrow = this.props.arrowRenderer({ onMouseDown: onMouseDown, isOpen: isOpen });
+// 25.1.2.1.1 %IteratorPrototype%[@@iterator]()
+__webpack_require__(10)(IteratorPrototype, __webpack_require__(3)('iterator'), function () { return this; });
- if (!arrow) {
- return null;
- }
+module.exports = function (Constructor, NAME, next) {
+ Constructor.prototype = create(IteratorPrototype, { next: descriptor(1, next) });
+ setToStringTag(Constructor, NAME + ' Iterator');
+};
- return react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement(
- 'span',
- {
- className: 'Select-arrow-zone',
- onMouseDown: onMouseDown
- },
- arrow
- );
- }
- }, {
- key: 'filterOptions',
- value: function filterOptions$$1(excludeOptions) {
- var filterValue = this.state.inputValue;
- var options = this.props.options || [];
- if (this.props.filterOptions) {
- // Maintain backwards compatibility with boolean attribute
- var filterOptions$$1 = typeof this.props.filterOptions === 'function' ? this.props.filterOptions : filterOptions;
- return filterOptions$$1(options, filterValue, excludeOptions, {
- filterOption: this.props.filterOption,
- ignoreAccents: this.props.ignoreAccents,
- ignoreCase: this.props.ignoreCase,
- labelKey: this.props.labelKey,
- matchPos: this.props.matchPos,
- matchProp: this.props.matchProp,
- trimFilter: this.props.trimFilter,
- valueKey: this.props.valueKey
- });
- } else {
- return options;
- }
- }
- }, {
- key: 'onOptionRef',
- value: function onOptionRef(ref, isFocused) {
- if (isFocused) {
- this.focused = ref;
- }
- }
- }, {
- key: 'renderMenu',
- value: function renderMenu(options, valueArray, focusedOption) {
- if (options && options.length) {
- return this.props.menuRenderer({
- focusedOption: focusedOption,
- focusOption: this.focusOption,
- inputValue: this.state.inputValue,
- instancePrefix: this._instancePrefix,
- labelKey: this.props.labelKey,
- onFocus: this.focusOption,
- onOptionRef: this.onOptionRef,
- onSelect: this.selectValue,
- optionClassName: this.props.optionClassName,
- optionComponent: this.props.optionComponent,
- optionRenderer: this.props.optionRenderer || this.getOptionLabel,
- options: options,
- removeValue: this.removeValue,
- selectValue: this.selectValue,
- valueArray: valueArray,
- valueKey: this.props.valueKey
- });
- } else if (this.props.noResultsText) {
- return react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement(
- 'div',
- { className: 'Select-noresults' },
- this.props.noResultsText
- );
- } else {
- return null;
- }
- }
- }, {
- key: 'renderHiddenField',
- value: function renderHiddenField(valueArray) {
- var _this7 = this;
+/***/ }),
+/* 65 */
+/***/ (function(module, exports, __webpack_require__) {
- if (!this.props.name) return;
- if (this.props.joinValues) {
- var value = valueArray.map(function (i) {
- return stringifyValue(i[_this7.props.valueKey]);
- }).join(this.props.delimiter);
- return react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement('input', {
- disabled: this.props.disabled,
- name: this.props.name,
- ref: function ref(_ref3) {
- return _this7.value = _ref3;
- },
- type: 'hidden',
- value: value
- });
- }
- return valueArray.map(function (item, index) {
- return react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement('input', {
- disabled: _this7.props.disabled,
- key: 'hidden.' + index,
- name: _this7.props.name,
- ref: 'value' + index,
- type: 'hidden',
- value: stringifyValue(item[_this7.props.valueKey])
- });
- });
- }
- }, {
- key: 'getFocusableOptionIndex',
- value: function getFocusableOptionIndex(selectedOption) {
- var options = this._visibleOptions;
- if (!options.length) return null;
+var dP = __webpack_require__(11);
+var anObject = __webpack_require__(14);
+var getKeys = __webpack_require__(17);
- var valueKey = this.props.valueKey;
- var focusedOption = this.state.focusedOption || selectedOption;
- if (focusedOption && !focusedOption.disabled) {
- var focusedOptionIndex = -1;
- options.some(function (option, index) {
- var isOptionEqual = option[valueKey] === focusedOption[valueKey];
- if (isOptionEqual) {
- focusedOptionIndex = index;
- }
- return isOptionEqual;
- });
- if (focusedOptionIndex !== -1) {
- return focusedOptionIndex;
- }
- }
+module.exports = __webpack_require__(7) ? Object.defineProperties : function defineProperties(O, Properties) {
+ anObject(O);
+ var keys = getKeys(Properties);
+ var length = keys.length;
+ var i = 0;
+ var P;
+ while (length > i) dP.f(O, P = keys[i++], Properties[P]);
+ return O;
+};
- for (var i = 0; i < options.length; i++) {
- if (!options[i].disabled) return i;
- }
- return null;
- }
- }, {
- key: 'renderOuter',
- value: function renderOuter(options, valueArray, focusedOption) {
- var _this8 = this;
- var menu = this.renderMenu(options, valueArray, focusedOption);
- if (!menu) {
- return null;
- }
+/***/ }),
+/* 66 */
+/***/ (function(module, exports, __webpack_require__) {
- return react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement(
- 'div',
- { ref: function ref(_ref5) {
- return _this8.menuContainer = _ref5;
- }, className: 'Select-menu-outer', style: this.props.menuContainerStyle },
- react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement(
- 'div',
- {
- className: 'Select-menu',
- id: this._instancePrefix + '-list',
- onMouseDown: this.handleMouseDownOnMenu,
- onScroll: this.handleMenuScroll,
- ref: function ref(_ref4) {
- return _this8.menu = _ref4;
- },
- role: 'listbox',
- style: this.props.menuStyle,
- tabIndex: -1
- },
- menu
- )
- );
- }
- }, {
- key: 'render',
- value: function render() {
- var _this9 = this;
+// false -> Array#indexOf
+// true -> Array#includes
+var toIObject = __webpack_require__(13);
+var toLength = __webpack_require__(67);
+var toAbsoluteIndex = __webpack_require__(68);
+module.exports = function (IS_INCLUDES) {
+ return function ($this, el, fromIndex) {
+ var O = toIObject($this);
+ var length = toLength(O.length);
+ var index = toAbsoluteIndex(fromIndex, length);
+ var value;
+ // Array#includes uses SameValueZero equality algorithm
+ // eslint-disable-next-line no-self-compare
+ if (IS_INCLUDES && el != el) while (length > index) {
+ value = O[index++];
+ // eslint-disable-next-line no-self-compare
+ if (value != value) return true;
+ // Array#indexOf ignores holes, Array#includes - not
+ } else for (;length > index; index++) if (IS_INCLUDES || index in O) {
+ if (O[index] === el) return IS_INCLUDES || index || 0;
+ } return !IS_INCLUDES && -1;
+ };
+};
- var valueArray = this.getValueArray(this.props.value);
- var options = this._visibleOptions = this.filterOptions(this.props.multi && this.props.removeSelected ? valueArray : null);
- var isOpen = this.state.isOpen;
- if (this.props.multi && !options.length && valueArray.length && !this.state.inputValue) isOpen = false;
- var focusedOptionIndex = this.getFocusableOptionIndex(valueArray[0]);
- var focusedOption = null;
- if (focusedOptionIndex !== null) {
- focusedOption = this._focusedOption = options[focusedOptionIndex];
- } else {
- focusedOption = this._focusedOption = null;
- }
- var className = classnames__WEBPACK_IMPORTED_MODULE_1___default()('Select', this.props.className, {
- 'has-value': valueArray.length,
- 'is-clearable': this.props.clearable,
- 'is-disabled': this.props.disabled,
- 'is-focused': this.state.isFocused,
- 'is-loading': this.props.isLoading,
- 'is-open': isOpen,
- 'is-pseudo-focused': this.state.isPseudoFocused,
- 'is-searchable': this.props.searchable,
- 'Select--multi': this.props.multi,
- 'Select--rtl': this.props.rtl,
- 'Select--single': !this.props.multi
- });
+/***/ }),
+/* 67 */
+/***/ (function(module, exports, __webpack_require__) {
- var removeMessage = null;
- if (this.props.multi && !this.props.disabled && valueArray.length && !this.state.inputValue && this.state.isFocused && this.props.backspaceRemoves) {
- removeMessage = react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement(
- 'span',
- { id: this._instancePrefix + '-backspace-remove-message', className: 'Select-aria-only', 'aria-live': 'assertive' },
- this.props.backspaceToRemoveMessage.replace('{label}', valueArray[valueArray.length - 1][this.props.labelKey])
- );
- }
+// 7.1.15 ToLength
+var toInteger = __webpack_require__(26);
+var min = Math.min;
+module.exports = function (it) {
+ return it > 0 ? min(toInteger(it), 0x1fffffffffffff) : 0; // pow(2, 53) - 1 == 9007199254740991
+};
- return react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement(
- 'div',
- { ref: function ref(_ref7) {
- return _this9.wrapper = _ref7;
- },
- className: className,
- style: this.props.wrapperStyle },
- this.renderHiddenField(valueArray),
- react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement(
- 'div',
- { ref: function ref(_ref6) {
- return _this9.control = _ref6;
- },
- className: 'Select-control',
- onKeyDown: this.handleKeyDown,
- onMouseDown: this.handleMouseDown,
- onTouchEnd: this.handleTouchEnd,
- onTouchMove: this.handleTouchMove,
- onTouchStart: this.handleTouchStart,
- style: this.props.style
- },
- react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement(
- 'div',
- { className: 'Select-multi-value-wrapper', id: this._instancePrefix + '-value' },
- this.renderValue(valueArray, isOpen),
- this.renderInput(valueArray, focusedOptionIndex)
- ),
- removeMessage,
- this.renderLoading(),
- this.renderClear(),
- this.renderArrow()
- ),
- isOpen ? this.renderOuter(options, valueArray, focusedOption) : null
- );
- }
- }]);
- return Select;
-}(react__WEBPACK_IMPORTED_MODULE_3___default.a.Component);
-Select$1.propTypes = {
- 'aria-describedby': prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string, // html id(s) of element(s) that should be used to describe this input (for assistive tech)
- 'aria-label': prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string, // aria label (for assistive tech)
- 'aria-labelledby': prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string, // html id of an element that should be used as the label (for assistive tech)
- arrowRenderer: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func, // create the drop-down caret element
- autoBlur: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // automatically blur the component when an option is selected
- autoFocus: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // autofocus the component on mount
- autofocus: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // deprecated; use autoFocus instead
- autosize: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // whether to enable autosizing or not
- backspaceRemoves: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // whether backspace removes an item if there is no text input
- backspaceToRemoveMessage: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string, // message to use for screenreaders to press backspace to remove the current item - {label} is replaced with the item label
- className: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string, // className for the outer element
- clearAllText: stringOrNode, // title for the "clear" control when multi: true
- clearRenderer: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func, // create clearable x element
- clearValueText: stringOrNode, // title for the "clear" control
- clearable: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // should it be possible to reset value
- closeOnSelect: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // whether to close the menu when a value is selected
- deleteRemoves: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // whether delete removes an item if there is no text input
- delimiter: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string, // delimiter to use to join multiple values for the hidden field value
- disabled: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // whether the Select is disabled or not
- escapeClearsValue: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // whether escape clears the value when the menu is closed
- filterOption: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func, // method to filter a single option (option, filterString)
- filterOptions: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.any, // boolean to enable default filtering or function to filter the options array ([options], filterString, [values])
- id: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string, // html id to set on the input element for accessibility or tests
- ignoreAccents: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // whether to strip diacritics when filtering
- ignoreCase: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // whether to perform case-insensitive filtering
- inputProps: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.object, // custom attributes for the Input
- inputRenderer: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func, // returns a custom input component
- instanceId: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string, // set the components instanceId
- isLoading: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // whether the Select is loading externally or not (such as options being loaded)
- joinValues: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // joins multiple values into a single form field with the delimiter (legacy mode)
- labelKey: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string, // path of the label value in option objects
- matchPos: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string, // (any|start) match the start or entire string when filtering
- matchProp: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string, // (any|label|value) which option property to filter on
- menuBuffer: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.number, // optional buffer (in px) between the bottom of the viewport and the bottom of the menu
- menuContainerStyle: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.object, // optional style to apply to the menu container
- menuRenderer: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func, // renders a custom menu with options
- menuStyle: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.object, // optional style to apply to the menu
- multi: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // multi-value input
- name: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string, // generates a hidden tag with this field name for html forms
- noResultsText: stringOrNode, // placeholder displayed when there are no matching search results
- onBlur: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func, // onBlur handler: function (event) {}
- onBlurResetsInput: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // whether input is cleared on blur
- onChange: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func, // onChange handler: function (newValue) {}
- onClose: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func, // fires when the menu is closed
- onCloseResetsInput: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // whether input is cleared when menu is closed through the arrow
- onFocus: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func, // onFocus handler: function (event) {}
- onInputChange: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func, // onInputChange handler: function (inputValue) {}
- onInputKeyDown: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func, // input keyDown handler: function (event) {}
- onMenuScrollToBottom: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func, // fires when the menu is scrolled to the bottom; can be used to paginate options
- onOpen: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func, // fires when the menu is opened
- onSelectResetsInput: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // whether input is cleared on select (works only for multiselect)
- onValueClick: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func, // onClick handler for value labels: function (value, event) {}
- openOnClick: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // boolean to control opening the menu when the control is clicked
- openOnFocus: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // always open options menu on focus
- optionClassName: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string, // additional class(es) to apply to the elements
- optionComponent: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func, // option component to render in dropdown
- optionRenderer: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func, // optionRenderer: function (option) {}
- options: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.array, // array of options
- pageSize: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.number, // number of entries to page when using page up/down keys
- placeholder: stringOrNode, // field placeholder, displayed when there's no value
- removeSelected: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // whether the selected option is removed from the dropdown on multi selects
- required: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // applies HTML5 required attribute when needed
- resetValue: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.any, // value to use when you clear the control
- rtl: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // set to true in order to use react-select in right-to-left direction
- scrollMenuIntoView: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // boolean to enable the viewport to shift so that the full menu fully visible when engaged
- searchable: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // whether to enable searching feature or not
- simpleValue: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // pass the value to onChange as a simple value (legacy pre 1.0 mode), defaults to false
- style: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.object, // optional style to apply to the control
- tabIndex: stringOrNumber, // optional tab index of the control
- tabSelectsValue: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // whether to treat tabbing out while focused to be value selection
- trimFilter: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // whether to trim whitespace around filter value
- value: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.any, // initial field value
- valueComponent: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func, // value component to render
- valueKey: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string, // path of the label value in option objects
- valueRenderer: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func, // valueRenderer: function (option) {}
- wrapperStyle: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.object // optional style to apply to the component wrapper
-};
+/***/ }),
+/* 68 */
+/***/ (function(module, exports, __webpack_require__) {
-Select$1.defaultProps = {
- arrowRenderer: arrowRenderer,
- autosize: true,
- backspaceRemoves: true,
- backspaceToRemoveMessage: 'Press backspace to remove {label}',
- clearable: true,
- clearAllText: 'Clear all',
- clearRenderer: clearRenderer,
- clearValueText: 'Clear value',
- closeOnSelect: true,
- deleteRemoves: true,
- delimiter: ',',
- disabled: false,
- escapeClearsValue: true,
- filterOptions: filterOptions,
- ignoreAccents: true,
- ignoreCase: true,
- inputProps: {},
- isLoading: false,
- joinValues: false,
- labelKey: 'label',
- matchPos: 'any',
- matchProp: 'any',
- menuBuffer: 0,
- menuRenderer: menuRenderer,
- multi: false,
- noResultsText: 'No results found',
- onBlurResetsInput: true,
- onCloseResetsInput: true,
- onSelectResetsInput: true,
- openOnClick: true,
- optionComponent: Option,
- pageSize: 5,
- placeholder: 'Select...',
- removeSelected: true,
- required: false,
- rtl: false,
- scrollMenuIntoView: true,
- searchable: true,
- simpleValue: false,
- tabSelectsValue: true,
- trimFilter: true,
- valueComponent: Value,
- valueKey: 'value'
+var toInteger = __webpack_require__(26);
+var max = Math.max;
+var min = Math.min;
+module.exports = function (index, length) {
+ index = toInteger(index);
+ return index < 0 ? max(index + length, 0) : min(index, length);
};
-var propTypes = {
- autoload: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool.isRequired, // automatically call the `loadOptions` prop on-mount; defaults to true
- cache: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.any, // object to use to cache results; set to null/false to disable caching
- children: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func.isRequired, // Child function responsible for creating the inner Select component; (props: Object): PropTypes.element
- ignoreAccents: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // strip diacritics when filtering; defaults to true
- ignoreCase: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // perform case-insensitive filtering; defaults to true
- loadOptions: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func.isRequired, // callback to load options asynchronously; (inputValue: string, callback: Function): ?Promise
- loadingPlaceholder: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.oneOfType([// replaces the placeholder while options are loading
- prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string, prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.node]),
- multi: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool, // multi-value input
- noResultsText: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.oneOfType([// field noResultsText, displayed when no options come back from the server
- prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string, prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.node]),
- onChange: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func, // onChange handler: function (newValue) {}
- onInputChange: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func, // optional for keeping track of what is being typed
- options: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.array.isRequired, // array of options
- placeholder: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.oneOfType([// field placeholder, displayed when there's no value (shared with Select)
- prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string, prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.node]),
- searchPromptText: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.oneOfType([// label to prompt for search input
- prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string, prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.node]),
- value: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.any // initial field value
-};
-var defaultCache = {};
+/***/ }),
+/* 69 */
+/***/ (function(module, exports, __webpack_require__) {
-var defaultChildren = function defaultChildren(props) {
- return react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement(Select$1, props);
-};
+var document = __webpack_require__(4).document;
+module.exports = document && document.documentElement;
-var defaultProps = {
- autoload: true,
- cache: defaultCache,
- children: defaultChildren,
- ignoreAccents: true,
- ignoreCase: true,
- loadingPlaceholder: 'Loading...',
- options: [],
- searchPromptText: 'Type to search'
+
+/***/ }),
+/* 70 */
+/***/ (function(module, exports, __webpack_require__) {
+
+// 19.1.2.9 / 15.2.3.2 Object.getPrototypeOf(O)
+var has = __webpack_require__(8);
+var toObject = __webpack_require__(22);
+var IE_PROTO = __webpack_require__(30)('IE_PROTO');
+var ObjectProto = Object.prototype;
+
+module.exports = Object.getPrototypeOf || function (O) {
+ O = toObject(O);
+ if (has(O, IE_PROTO)) return O[IE_PROTO];
+ if (typeof O.constructor == 'function' && O instanceof O.constructor) {
+ return O.constructor.prototype;
+ } return O instanceof Object ? ObjectProto : null;
};
-var Async = function (_Component) {
- inherits(Async, _Component);
- function Async(props, context) {
- classCallCheck(this, Async);
+/***/ }),
+/* 71 */
+/***/ (function(module, exports, __webpack_require__) {
- var _this = possibleConstructorReturn(this, (Async.__proto__ || Object.getPrototypeOf(Async)).call(this, props, context));
+"use strict";
- _this._cache = props.cache === defaultCache ? {} : props.cache;
+var addToUnscopables = __webpack_require__(72);
+var step = __webpack_require__(73);
+var Iterators = __webpack_require__(16);
+var toIObject = __webpack_require__(13);
- _this.state = {
- inputValue: '',
- isLoading: false,
- options: props.options
- };
+// 22.1.3.4 Array.prototype.entries()
+// 22.1.3.13 Array.prototype.keys()
+// 22.1.3.29 Array.prototype.values()
+// 22.1.3.30 Array.prototype[@@iterator]()
+module.exports = __webpack_require__(39)(Array, 'Array', function (iterated, kind) {
+ this._t = toIObject(iterated); // target
+ this._i = 0; // next index
+ this._k = kind; // kind
+// 22.1.5.2.1 %ArrayIteratorPrototype%.next()
+}, function () {
+ var O = this._t;
+ var kind = this._k;
+ var index = this._i++;
+ if (!O || index >= O.length) {
+ this._t = undefined;
+ return step(1);
+ }
+ if (kind == 'keys') return step(0, index);
+ if (kind == 'values') return step(0, O[index]);
+ return step(0, [index, O[index]]);
+}, 'values');
- _this.onInputChange = _this.onInputChange.bind(_this);
- return _this;
- }
+// argumentsList[@@iterator] is %ArrayProto_values% (9.4.4.6, 9.4.4.7)
+Iterators.Arguments = Iterators.Array;
- createClass(Async, [{
- key: 'componentDidMount',
- value: function componentDidMount() {
- var autoload = this.props.autoload;
+addToUnscopables('keys');
+addToUnscopables('values');
+addToUnscopables('entries');
- if (autoload) {
- this.loadOptions('');
- }
- }
- }, {
- key: 'componentWillReceiveProps',
- value: function componentWillReceiveProps(nextProps) {
- if (nextProps.options !== this.props.options) {
- this.setState({
- options: nextProps.options
- });
- }
- }
- }, {
- key: 'componentWillUnmount',
- value: function componentWillUnmount() {
- this._callback = null;
- }
- }, {
- key: 'loadOptions',
- value: function loadOptions(inputValue) {
- var _this2 = this;
+/***/ }),
+/* 72 */
+/***/ (function(module, exports) {
- var loadOptions = this.props.loadOptions;
+module.exports = function () { /* empty */ };
- var cache = this._cache;
- if (cache && Object.prototype.hasOwnProperty.call(cache, inputValue)) {
- this._callback = null;
+/***/ }),
+/* 73 */
+/***/ (function(module, exports) {
- this.setState({
- isLoading: false,
- options: cache[inputValue]
- });
+module.exports = function (done, value) {
+ return { value: value, done: !!done };
+};
- return;
- }
- var callback = function callback(error, data) {
- var options = data && data.options || [];
+/***/ }),
+/* 74 */
+/***/ (function(module, exports, __webpack_require__) {
- if (cache) {
- cache[inputValue] = options;
- }
+module.exports = { "default": __webpack_require__(75), __esModule: true };
- if (callback === _this2._callback) {
- _this2._callback = null;
+/***/ }),
+/* 75 */
+/***/ (function(module, exports, __webpack_require__) {
- _this2.setState({
- isLoading: false,
- options: options
- });
- }
- };
+__webpack_require__(76);
+__webpack_require__(82);
+__webpack_require__(83);
+__webpack_require__(84);
+module.exports = __webpack_require__(2).Symbol;
- // Ignore all but the most recent request
- this._callback = callback;
- var promise = loadOptions(inputValue, callback);
- if (promise) {
- promise.then(function (data) {
- return callback(null, data);
- }, function (error) {
- return callback(error);
- });
- }
+/***/ }),
+/* 76 */
+/***/ (function(module, exports, __webpack_require__) {
- if (this._callback && !this.state.isLoading) {
- this.setState({
- isLoading: true
- });
- }
- }
- }, {
- key: 'onInputChange',
- value: function onInputChange(inputValue) {
- var _props = this.props,
- ignoreAccents = _props.ignoreAccents,
- ignoreCase = _props.ignoreCase,
- onInputChange = _props.onInputChange;
-
- var newInputValue = inputValue;
+"use strict";
- if (onInputChange) {
- var value = onInputChange(newInputValue);
- // Note: != used deliberately here to catch undefined and null
- if (value != null && (typeof value === 'undefined' ? 'undefined' : _typeof(value)) !== 'object') {
- newInputValue = '' + value;
- }
- }
+// ECMAScript 6 symbols shim
+var global = __webpack_require__(4);
+var has = __webpack_require__(8);
+var DESCRIPTORS = __webpack_require__(7);
+var $export = __webpack_require__(19);
+var redefine = __webpack_require__(42);
+var META = __webpack_require__(77).KEY;
+var $fails = __webpack_require__(12);
+var shared = __webpack_require__(31);
+var setToStringTag = __webpack_require__(33);
+var uid = __webpack_require__(21);
+var wks = __webpack_require__(3);
+var wksExt = __webpack_require__(35);
+var wksDefine = __webpack_require__(36);
+var enumKeys = __webpack_require__(78);
+var isArray = __webpack_require__(79);
+var anObject = __webpack_require__(14);
+var isObject = __webpack_require__(15);
+var toObject = __webpack_require__(22);
+var toIObject = __webpack_require__(13);
+var toPrimitive = __webpack_require__(28);
+var createDesc = __webpack_require__(20);
+var _create = __webpack_require__(43);
+var gOPNExt = __webpack_require__(80);
+var $GOPD = __webpack_require__(81);
+var $GOPS = __webpack_require__(37);
+var $DP = __webpack_require__(11);
+var $keys = __webpack_require__(17);
+var gOPD = $GOPD.f;
+var dP = $DP.f;
+var gOPN = gOPNExt.f;
+var $Symbol = global.Symbol;
+var $JSON = global.JSON;
+var _stringify = $JSON && $JSON.stringify;
+var PROTOTYPE = 'prototype';
+var HIDDEN = wks('_hidden');
+var TO_PRIMITIVE = wks('toPrimitive');
+var isEnum = {}.propertyIsEnumerable;
+var SymbolRegistry = shared('symbol-registry');
+var AllSymbols = shared('symbols');
+var OPSymbols = shared('op-symbols');
+var ObjectProto = Object[PROTOTYPE];
+var USE_NATIVE = typeof $Symbol == 'function' && !!$GOPS.f;
+var QObject = global.QObject;
+// Don't use setters in Qt Script, https://github.com/zloirock/core-js/issues/173
+var setter = !QObject || !QObject[PROTOTYPE] || !QObject[PROTOTYPE].findChild;
- var transformedInputValue = newInputValue;
+// fallback for old Android, https://code.google.com/p/v8/issues/detail?id=687
+var setSymbolDesc = DESCRIPTORS && $fails(function () {
+ return _create(dP({}, 'a', {
+ get: function () { return dP(this, 'a', { value: 7 }).a; }
+ })).a != 7;
+}) ? function (it, key, D) {
+ var protoDesc = gOPD(ObjectProto, key);
+ if (protoDesc) delete ObjectProto[key];
+ dP(it, key, D);
+ if (protoDesc && it !== ObjectProto) dP(ObjectProto, key, protoDesc);
+} : dP;
- if (ignoreAccents) {
- transformedInputValue = stripDiacritics(transformedInputValue);
- }
+var wrap = function (tag) {
+ var sym = AllSymbols[tag] = _create($Symbol[PROTOTYPE]);
+ sym._k = tag;
+ return sym;
+};
- if (ignoreCase) {
- transformedInputValue = transformedInputValue.toLowerCase();
- }
+var isSymbol = USE_NATIVE && typeof $Symbol.iterator == 'symbol' ? function (it) {
+ return typeof it == 'symbol';
+} : function (it) {
+ return it instanceof $Symbol;
+};
- this.setState({ inputValue: newInputValue });
- this.loadOptions(transformedInputValue);
+var $defineProperty = function defineProperty(it, key, D) {
+ if (it === ObjectProto) $defineProperty(OPSymbols, key, D);
+ anObject(it);
+ key = toPrimitive(key, true);
+ anObject(D);
+ if (has(AllSymbols, key)) {
+ if (!D.enumerable) {
+ if (!has(it, HIDDEN)) dP(it, HIDDEN, createDesc(1, {}));
+ it[HIDDEN][key] = true;
+ } else {
+ if (has(it, HIDDEN) && it[HIDDEN][key]) it[HIDDEN][key] = false;
+ D = _create(D, { enumerable: createDesc(0, false) });
+ } return setSymbolDesc(it, key, D);
+ } return dP(it, key, D);
+};
+var $defineProperties = function defineProperties(it, P) {
+ anObject(it);
+ var keys = enumKeys(P = toIObject(P));
+ var i = 0;
+ var l = keys.length;
+ var key;
+ while (l > i) $defineProperty(it, key = keys[i++], P[key]);
+ return it;
+};
+var $create = function create(it, P) {
+ return P === undefined ? _create(it) : $defineProperties(_create(it), P);
+};
+var $propertyIsEnumerable = function propertyIsEnumerable(key) {
+ var E = isEnum.call(this, key = toPrimitive(key, true));
+ if (this === ObjectProto && has(AllSymbols, key) && !has(OPSymbols, key)) return false;
+ return E || !has(this, key) || !has(AllSymbols, key) || has(this, HIDDEN) && this[HIDDEN][key] ? E : true;
+};
+var $getOwnPropertyDescriptor = function getOwnPropertyDescriptor(it, key) {
+ it = toIObject(it);
+ key = toPrimitive(key, true);
+ if (it === ObjectProto && has(AllSymbols, key) && !has(OPSymbols, key)) return;
+ var D = gOPD(it, key);
+ if (D && has(AllSymbols, key) && !(has(it, HIDDEN) && it[HIDDEN][key])) D.enumerable = true;
+ return D;
+};
+var $getOwnPropertyNames = function getOwnPropertyNames(it) {
+ var names = gOPN(toIObject(it));
+ var result = [];
+ var i = 0;
+ var key;
+ while (names.length > i) {
+ if (!has(AllSymbols, key = names[i++]) && key != HIDDEN && key != META) result.push(key);
+ } return result;
+};
+var $getOwnPropertySymbols = function getOwnPropertySymbols(it) {
+ var IS_OP = it === ObjectProto;
+ var names = gOPN(IS_OP ? OPSymbols : toIObject(it));
+ var result = [];
+ var i = 0;
+ var key;
+ while (names.length > i) {
+ if (has(AllSymbols, key = names[i++]) && (IS_OP ? has(ObjectProto, key) : true)) result.push(AllSymbols[key]);
+ } return result;
+};
- // Return new input value, but without applying toLowerCase() to avoid modifying the user's view case of the input while typing.
- return newInputValue;
- }
- }, {
- key: 'noResultsText',
- value: function noResultsText() {
- var _props2 = this.props,
- loadingPlaceholder = _props2.loadingPlaceholder,
- noResultsText = _props2.noResultsText,
- searchPromptText = _props2.searchPromptText;
- var _state = this.state,
- inputValue = _state.inputValue,
- isLoading = _state.isLoading;
+// 19.4.1.1 Symbol([description])
+if (!USE_NATIVE) {
+ $Symbol = function Symbol() {
+ if (this instanceof $Symbol) throw TypeError('Symbol is not a constructor!');
+ var tag = uid(arguments.length > 0 ? arguments[0] : undefined);
+ var $set = function (value) {
+ if (this === ObjectProto) $set.call(OPSymbols, value);
+ if (has(this, HIDDEN) && has(this[HIDDEN], tag)) this[HIDDEN][tag] = false;
+ setSymbolDesc(this, tag, createDesc(1, value));
+ };
+ if (DESCRIPTORS && setter) setSymbolDesc(ObjectProto, tag, { configurable: true, set: $set });
+ return wrap(tag);
+ };
+ redefine($Symbol[PROTOTYPE], 'toString', function toString() {
+ return this._k;
+ });
+ $GOPD.f = $getOwnPropertyDescriptor;
+ $DP.f = $defineProperty;
+ __webpack_require__(46).f = gOPNExt.f = $getOwnPropertyNames;
+ __webpack_require__(23).f = $propertyIsEnumerable;
+ $GOPS.f = $getOwnPropertySymbols;
- if (isLoading) {
- return loadingPlaceholder;
- }
- if (inputValue && noResultsText) {
- return noResultsText;
- }
- return searchPromptText;
- }
- }, {
- key: 'focus',
- value: function focus() {
- this.select.focus();
- }
- }, {
- key: 'render',
- value: function render() {
- var _this3 = this;
+ if (DESCRIPTORS && !__webpack_require__(18)) {
+ redefine(ObjectProto, 'propertyIsEnumerable', $propertyIsEnumerable, true);
+ }
- var _props3 = this.props,
- children = _props3.children,
- loadingPlaceholder = _props3.loadingPlaceholder,
- placeholder = _props3.placeholder;
- var _state2 = this.state,
- isLoading = _state2.isLoading,
- options = _state2.options;
+ wksExt.f = function (name) {
+ return wrap(wks(name));
+ };
+}
+$export($export.G + $export.W + $export.F * !USE_NATIVE, { Symbol: $Symbol });
- var props = {
- noResultsText: this.noResultsText(),
- placeholder: isLoading ? loadingPlaceholder : placeholder,
- options: isLoading && loadingPlaceholder ? [] : options,
- ref: function ref(_ref) {
- return _this3.select = _ref;
- }
- };
+for (var es6Symbols = (
+ // 19.4.2.2, 19.4.2.3, 19.4.2.4, 19.4.2.6, 19.4.2.8, 19.4.2.9, 19.4.2.10, 19.4.2.11, 19.4.2.12, 19.4.2.13, 19.4.2.14
+ 'hasInstance,isConcatSpreadable,iterator,match,replace,search,species,split,toPrimitive,toStringTag,unscopables'
+).split(','), j = 0; es6Symbols.length > j;)wks(es6Symbols[j++]);
- return children(_extends({}, this.props, props, {
- isLoading: isLoading,
- onInputChange: this.onInputChange
- }));
- }
- }]);
- return Async;
-}(react__WEBPACK_IMPORTED_MODULE_3__["Component"]);
+for (var wellKnownSymbols = $keys(wks.store), k = 0; wellKnownSymbols.length > k;) wksDefine(wellKnownSymbols[k++]);
-Async.propTypes = propTypes;
-Async.defaultProps = defaultProps;
+$export($export.S + $export.F * !USE_NATIVE, 'Symbol', {
+ // 19.4.2.1 Symbol.for(key)
+ 'for': function (key) {
+ return has(SymbolRegistry, key += '')
+ ? SymbolRegistry[key]
+ : SymbolRegistry[key] = $Symbol(key);
+ },
+ // 19.4.2.5 Symbol.keyFor(sym)
+ keyFor: function keyFor(sym) {
+ if (!isSymbol(sym)) throw TypeError(sym + ' is not a symbol!');
+ for (var key in SymbolRegistry) if (SymbolRegistry[key] === sym) return key;
+ },
+ useSetter: function () { setter = true; },
+ useSimple: function () { setter = false; }
+});
-var CreatableSelect = function (_React$Component) {
- inherits(CreatableSelect, _React$Component);
+$export($export.S + $export.F * !USE_NATIVE, 'Object', {
+ // 19.1.2.2 Object.create(O [, Properties])
+ create: $create,
+ // 19.1.2.4 Object.defineProperty(O, P, Attributes)
+ defineProperty: $defineProperty,
+ // 19.1.2.3 Object.defineProperties(O, Properties)
+ defineProperties: $defineProperties,
+ // 19.1.2.6 Object.getOwnPropertyDescriptor(O, P)
+ getOwnPropertyDescriptor: $getOwnPropertyDescriptor,
+ // 19.1.2.7 Object.getOwnPropertyNames(O)
+ getOwnPropertyNames: $getOwnPropertyNames,
+ // 19.1.2.8 Object.getOwnPropertySymbols(O)
+ getOwnPropertySymbols: $getOwnPropertySymbols
+});
- function CreatableSelect(props, context) {
- classCallCheck(this, CreatableSelect);
+// Chrome 38 and 39 `Object.getOwnPropertySymbols` fails on primitives
+// https://bugs.chromium.org/p/v8/issues/detail?id=3443
+var FAILS_ON_PRIMITIVES = $fails(function () { $GOPS.f(1); });
- var _this = possibleConstructorReturn(this, (CreatableSelect.__proto__ || Object.getPrototypeOf(CreatableSelect)).call(this, props, context));
+$export($export.S + $export.F * FAILS_ON_PRIMITIVES, 'Object', {
+ getOwnPropertySymbols: function getOwnPropertySymbols(it) {
+ return $GOPS.f(toObject(it));
+ }
+});
- _this.filterOptions = _this.filterOptions.bind(_this);
- _this.menuRenderer = _this.menuRenderer.bind(_this);
- _this.onInputKeyDown = _this.onInputKeyDown.bind(_this);
- _this.onInputChange = _this.onInputChange.bind(_this);
- _this.onOptionSelect = _this.onOptionSelect.bind(_this);
- return _this;
- }
+// 24.3.2 JSON.stringify(value [, replacer [, space]])
+$JSON && $export($export.S + $export.F * (!USE_NATIVE || $fails(function () {
+ var S = $Symbol();
+ // MS Edge converts symbol values to JSON as {}
+ // WebKit converts symbol values to JSON as null
+ // V8 throws on boxed symbols
+ return _stringify([S]) != '[null]' || _stringify({ a: S }) != '{}' || _stringify(Object(S)) != '{}';
+})), 'JSON', {
+ stringify: function stringify(it) {
+ var args = [it];
+ var i = 1;
+ var replacer, $replacer;
+ while (arguments.length > i) args.push(arguments[i++]);
+ $replacer = replacer = args[1];
+ if (!isObject(replacer) && it === undefined || isSymbol(it)) return; // IE8 returns string on undefined
+ if (!isArray(replacer)) replacer = function (key, value) {
+ if (typeof $replacer == 'function') value = $replacer.call(this, key, value);
+ if (!isSymbol(value)) return value;
+ };
+ args[1] = replacer;
+ return _stringify.apply($JSON, args);
+ }
+});
- createClass(CreatableSelect, [{
- key: 'createNewOption',
- value: function createNewOption() {
- var _props = this.props,
- isValidNewOption = _props.isValidNewOption,
- newOptionCreator = _props.newOptionCreator,
- onNewOptionClick = _props.onNewOptionClick,
- _props$options = _props.options,
- options = _props$options === undefined ? [] : _props$options;
+// 19.4.3.4 Symbol.prototype[@@toPrimitive](hint)
+$Symbol[PROTOTYPE][TO_PRIMITIVE] || __webpack_require__(10)($Symbol[PROTOTYPE], TO_PRIMITIVE, $Symbol[PROTOTYPE].valueOf);
+// 19.4.3.5 Symbol.prototype[@@toStringTag]
+setToStringTag($Symbol, 'Symbol');
+// 20.2.1.9 Math[@@toStringTag]
+setToStringTag(Math, 'Math', true);
+// 24.3.3 JSON[@@toStringTag]
+setToStringTag(global.JSON, 'JSON', true);
- if (isValidNewOption({ label: this.inputValue })) {
- var option = newOptionCreator({ label: this.inputValue, labelKey: this.labelKey, valueKey: this.valueKey });
- var _isOptionUnique = this.isOptionUnique({ option: option, options: options });
+/***/ }),
+/* 77 */
+/***/ (function(module, exports, __webpack_require__) {
- // Don't add the same option twice.
- if (_isOptionUnique) {
- if (onNewOptionClick) {
- onNewOptionClick(option);
- } else {
- options.unshift(option);
+var META = __webpack_require__(21)('meta');
+var isObject = __webpack_require__(15);
+var has = __webpack_require__(8);
+var setDesc = __webpack_require__(11).f;
+var id = 0;
+var isExtensible = Object.isExtensible || function () {
+ return true;
+};
+var FREEZE = !__webpack_require__(12)(function () {
+ return isExtensible(Object.preventExtensions({}));
+});
+var setMeta = function (it) {
+ setDesc(it, META, { value: {
+ i: 'O' + ++id, // object ID
+ w: {} // weak collections IDs
+ } });
+};
+var fastKey = function (it, create) {
+ // return primitive with prefix
+ if (!isObject(it)) return typeof it == 'symbol' ? it : (typeof it == 'string' ? 'S' : 'P') + it;
+ if (!has(it, META)) {
+ // can't set metadata to uncaught frozen object
+ if (!isExtensible(it)) return 'F';
+ // not necessary to add metadata
+ if (!create) return 'E';
+ // add missing metadata
+ setMeta(it);
+ // return object ID
+ } return it[META].i;
+};
+var getWeak = function (it, create) {
+ if (!has(it, META)) {
+ // can't set metadata to uncaught frozen object
+ if (!isExtensible(it)) return true;
+ // not necessary to add metadata
+ if (!create) return false;
+ // add missing metadata
+ setMeta(it);
+ // return hash weak collections IDs
+ } return it[META].w;
+};
+// add metadata on freeze-family methods calling
+var onFreeze = function (it) {
+ if (FREEZE && meta.NEED && isExtensible(it) && !has(it, META)) setMeta(it);
+ return it;
+};
+var meta = module.exports = {
+ KEY: META,
+ NEED: false,
+ fastKey: fastKey,
+ getWeak: getWeak,
+ onFreeze: onFreeze
+};
- this.select.selectValue(option);
- }
- }
- }
- }
- }, {
- key: 'filterOptions',
- value: function filterOptions$$1() {
- var _props2 = this.props,
- filterOptions$$1 = _props2.filterOptions,
- isValidNewOption = _props2.isValidNewOption,
- promptTextCreator = _props2.promptTextCreator,
- showNewOptionAtTop = _props2.showNewOptionAtTop;
- // TRICKY Check currently selected options as well.
- // Don't display a create-prompt for a value that's selected.
- // This covers async edge-cases where a newly-created Option isn't yet in the async-loaded array.
+/***/ }),
+/* 78 */
+/***/ (function(module, exports, __webpack_require__) {
- var excludeOptions = (arguments.length <= 2 ? undefined : arguments[2]) || [];
+// all enumerable object keys, includes symbols
+var getKeys = __webpack_require__(17);
+var gOPS = __webpack_require__(37);
+var pIE = __webpack_require__(23);
+module.exports = function (it) {
+ var result = getKeys(it);
+ var getSymbols = gOPS.f;
+ if (getSymbols) {
+ var symbols = getSymbols(it);
+ var isEnum = pIE.f;
+ var i = 0;
+ var key;
+ while (symbols.length > i) if (isEnum.call(it, key = symbols[i++])) result.push(key);
+ } return result;
+};
- var filteredOptions = filterOptions$$1.apply(undefined, arguments) || [];
- if (isValidNewOption({ label: this.inputValue })) {
- var _newOptionCreator = this.props.newOptionCreator;
+/***/ }),
+/* 79 */
+/***/ (function(module, exports, __webpack_require__) {
+// 7.2.2 IsArray(argument)
+var cof = __webpack_require__(29);
+module.exports = Array.isArray || function isArray(arg) {
+ return cof(arg) == 'Array';
+};
- var option = _newOptionCreator({
- label: this.inputValue,
- labelKey: this.labelKey,
- valueKey: this.valueKey
- });
- // TRICKY Compare to all options (not just filtered options) in case option has already been selected).
- // For multi-selects, this would remove it from the filtered list.
- var _isOptionUnique2 = this.isOptionUnique({
- option: option,
- options: excludeOptions.concat(filteredOptions)
- });
+/***/ }),
+/* 80 */
+/***/ (function(module, exports, __webpack_require__) {
- if (_isOptionUnique2) {
- var prompt = promptTextCreator(this.inputValue);
+// fallback for IE11 buggy Object.getOwnPropertyNames with iframe and window
+var toIObject = __webpack_require__(13);
+var gOPN = __webpack_require__(46).f;
+var toString = {}.toString;
- this._createPlaceholderOption = _newOptionCreator({
- label: prompt,
- labelKey: this.labelKey,
- valueKey: this.valueKey
- });
+var windowNames = typeof window == 'object' && window && Object.getOwnPropertyNames
+ ? Object.getOwnPropertyNames(window) : [];
- if (showNewOptionAtTop) {
- filteredOptions.unshift(this._createPlaceholderOption);
- } else {
- filteredOptions.push(this._createPlaceholderOption);
- }
- }
- }
+var getWindowNames = function (it) {
+ try {
+ return gOPN(it);
+ } catch (e) {
+ return windowNames.slice();
+ }
+};
- return filteredOptions;
- }
- }, {
- key: 'isOptionUnique',
- value: function isOptionUnique(_ref) {
- var option = _ref.option,
- options = _ref.options;
- var isOptionUnique = this.props.isOptionUnique;
+module.exports.f = function getOwnPropertyNames(it) {
+ return windowNames && toString.call(it) == '[object Window]' ? getWindowNames(it) : gOPN(toIObject(it));
+};
- options = options || this.props.options;
+/***/ }),
+/* 81 */
+/***/ (function(module, exports, __webpack_require__) {
- return isOptionUnique({
- labelKey: this.labelKey,
- option: option,
- options: options,
- valueKey: this.valueKey
- });
- }
- }, {
- key: 'menuRenderer',
- value: function menuRenderer$$1(params) {
- var menuRenderer$$1 = this.props.menuRenderer;
+var pIE = __webpack_require__(23);
+var createDesc = __webpack_require__(20);
+var toIObject = __webpack_require__(13);
+var toPrimitive = __webpack_require__(28);
+var has = __webpack_require__(8);
+var IE8_DOM_DEFINE = __webpack_require__(40);
+var gOPD = Object.getOwnPropertyDescriptor;
+exports.f = __webpack_require__(7) ? gOPD : function getOwnPropertyDescriptor(O, P) {
+ O = toIObject(O);
+ P = toPrimitive(P, true);
+ if (IE8_DOM_DEFINE) try {
+ return gOPD(O, P);
+ } catch (e) { /* empty */ }
+ if (has(O, P)) return createDesc(!pIE.f.call(O, P), O[P]);
+};
- return menuRenderer$$1(_extends({}, params, {
- onSelect: this.onOptionSelect,
- selectValue: this.onOptionSelect
- }));
- }
- }, {
- key: 'onInputChange',
- value: function onInputChange(input) {
- var onInputChange = this.props.onInputChange;
- // This value may be needed in between Select mounts (when this.select is null)
+/***/ }),
+/* 82 */
+/***/ (function(module, exports) {
- this.inputValue = input;
- if (onInputChange) {
- this.inputValue = onInputChange(input);
- }
- return this.inputValue;
- }
- }, {
- key: 'onInputKeyDown',
- value: function onInputKeyDown(event) {
- var _props3 = this.props,
- shouldKeyDownEventCreateNewOption = _props3.shouldKeyDownEventCreateNewOption,
- onInputKeyDown = _props3.onInputKeyDown;
+/***/ }),
+/* 83 */
+/***/ (function(module, exports, __webpack_require__) {
- var focusedOption = this.select.getFocusedOption();
+__webpack_require__(36)('asyncIterator');
- if (focusedOption && focusedOption === this._createPlaceholderOption && shouldKeyDownEventCreateNewOption(event)) {
- this.createNewOption();
- // Prevent decorated Select from doing anything additional with this keyDown event
- event.preventDefault();
- } else if (onInputKeyDown) {
- onInputKeyDown(event);
- }
- }
- }, {
- key: 'onOptionSelect',
- value: function onOptionSelect(option) {
- if (option === this._createPlaceholderOption) {
- this.createNewOption();
- } else {
- this.select.selectValue(option);
- }
- }
- }, {
- key: 'focus',
- value: function focus() {
- this.select.focus();
- }
- }, {
- key: 'render',
- value: function render() {
- var _this2 = this;
+/***/ }),
+/* 84 */
+/***/ (function(module, exports, __webpack_require__) {
- var _props4 = this.props,
- refProp = _props4.ref,
- restProps = objectWithoutProperties(_props4, ['ref']);
- var children = this.props.children;
+__webpack_require__(36)('observable');
- // We can't use destructuring default values to set the children,
- // because it won't apply work if `children` is null. A falsy check is
- // more reliable in real world use-cases.
- if (!children) {
- children = defaultChildren$2;
- }
+/***/ }),
+/* 85 */
+/***/ (function(module, exports, __webpack_require__) {
- var props = _extends({}, restProps, {
- allowCreate: true,
- filterOptions: this.filterOptions,
- menuRenderer: this.menuRenderer,
- onInputChange: this.onInputChange,
- onInputKeyDown: this.onInputKeyDown,
- ref: function ref(_ref2) {
- _this2.select = _ref2;
+"use strict";
- // These values may be needed in between Select mounts (when this.select is null)
- if (_ref2) {
- _this2.labelKey = _ref2.props.labelKey;
- _this2.valueKey = _ref2.props.valueKey;
- }
- if (refProp) {
- refProp(_ref2);
- }
- }
- });
- return children(props);
- }
- }]);
- return CreatableSelect;
-}(react__WEBPACK_IMPORTED_MODULE_3___default.a.Component);
+exports.__esModule = true;
-var defaultChildren$2 = function defaultChildren(props) {
- return react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement(Select$1, props);
-};
+var _assign = __webpack_require__(86);
-var isOptionUnique = function isOptionUnique(_ref3) {
- var option = _ref3.option,
- options = _ref3.options,
- labelKey = _ref3.labelKey,
- valueKey = _ref3.valueKey;
+var _assign2 = _interopRequireDefault(_assign);
- if (!options || !options.length) {
- return true;
- }
+function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
- return options.filter(function (existingOption) {
- return existingOption[labelKey] === option[labelKey] || existingOption[valueKey] === option[valueKey];
- }).length === 0;
-};
+exports.default = _assign2.default || function (target) {
+ for (var i = 1; i < arguments.length; i++) {
+ var source = arguments[i];
-var isValidNewOption = function isValidNewOption(_ref4) {
- var label = _ref4.label;
- return !!label;
+ for (var key in source) {
+ if (Object.prototype.hasOwnProperty.call(source, key)) {
+ target[key] = source[key];
+ }
+ }
+ }
+
+ return target;
};
-var newOptionCreator = function newOptionCreator(_ref5) {
- var label = _ref5.label,
- labelKey = _ref5.labelKey,
- valueKey = _ref5.valueKey;
+/***/ }),
+/* 86 */
+/***/ (function(module, exports, __webpack_require__) {
- var option = {};
- option[valueKey] = label;
- option[labelKey] = label;
- option.className = 'Select-create-option-placeholder';
+module.exports = { "default": __webpack_require__(87), __esModule: true };
- return option;
-};
+/***/ }),
+/* 87 */
+/***/ (function(module, exports, __webpack_require__) {
-var promptTextCreator = function promptTextCreator(label) {
- return 'Create option "' + label + '"';
-};
+__webpack_require__(88);
+module.exports = __webpack_require__(2).Object.assign;
-var shouldKeyDownEventCreateNewOption = function shouldKeyDownEventCreateNewOption(_ref6) {
- var keyCode = _ref6.keyCode;
- switch (keyCode) {
- case 9: // TAB
- case 13: // ENTER
- case 188:
- // COMMA
- return true;
- default:
- return false;
- }
-};
+/***/ }),
+/* 88 */
+/***/ (function(module, exports, __webpack_require__) {
-// Default prop methods
-CreatableSelect.isOptionUnique = isOptionUnique;
-CreatableSelect.isValidNewOption = isValidNewOption;
-CreatableSelect.newOptionCreator = newOptionCreator;
-CreatableSelect.promptTextCreator = promptTextCreator;
-CreatableSelect.shouldKeyDownEventCreateNewOption = shouldKeyDownEventCreateNewOption;
+// 19.1.3.1 Object.assign(target, source)
+var $export = __webpack_require__(19);
-CreatableSelect.defaultProps = {
- filterOptions: filterOptions,
- isOptionUnique: isOptionUnique,
- isValidNewOption: isValidNewOption,
- menuRenderer: menuRenderer,
- newOptionCreator: newOptionCreator,
- promptTextCreator: promptTextCreator,
- shouldKeyDownEventCreateNewOption: shouldKeyDownEventCreateNewOption,
- showNewOptionAtTop: true
-};
+$export($export.S + $export.F, 'Object', { assign: __webpack_require__(89) });
-CreatableSelect.propTypes = {
- // Child function responsible for creating the inner Select component
- // This component can be used to compose HOCs (eg Creatable and Async)
- // (props: Object): PropTypes.element
- children: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func,
- // See Select.propTypes.filterOptions
- filterOptions: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.any,
+/***/ }),
+/* 89 */
+/***/ (function(module, exports, __webpack_require__) {
- // Searches for any matching option within the set of options.
- // This function prevents duplicate options from being created.
- // ({ option: Object, options: Array, labelKey: string, valueKey: string }): boolean
- isOptionUnique: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func,
+"use strict";
- // Determines if the current input text represents a valid option.
- // ({ label: string }): boolean
- isValidNewOption: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func,
+// 19.1.2.1 Object.assign(target, source, ...)
+var DESCRIPTORS = __webpack_require__(7);
+var getKeys = __webpack_require__(17);
+var gOPS = __webpack_require__(37);
+var pIE = __webpack_require__(23);
+var toObject = __webpack_require__(22);
+var IObject = __webpack_require__(45);
+var $assign = Object.assign;
- // See Select.propTypes.menuRenderer
- menuRenderer: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.any,
+// should work with symbols and should have deterministic property order (V8 bug)
+module.exports = !$assign || __webpack_require__(12)(function () {
+ var A = {};
+ var B = {};
+ // eslint-disable-next-line no-undef
+ var S = Symbol();
+ var K = 'abcdefghijklmnopqrst';
+ A[S] = 7;
+ K.split('').forEach(function (k) { B[k] = k; });
+ return $assign({}, A)[S] != 7 || Object.keys($assign({}, B)).join('') != K;
+}) ? function assign(target, source) { // eslint-disable-line no-unused-vars
+ var T = toObject(target);
+ var aLen = arguments.length;
+ var index = 1;
+ var getSymbols = gOPS.f;
+ var isEnum = pIE.f;
+ while (aLen > index) {
+ var S = IObject(arguments[index++]);
+ var keys = getSymbols ? getKeys(S).concat(getSymbols(S)) : getKeys(S);
+ var length = keys.length;
+ var j = 0;
+ var key;
+ while (length > j) {
+ key = keys[j++];
+ if (!DESCRIPTORS || isEnum.call(S, key)) T[key] = S[key];
+ }
+ } return T;
+} : $assign;
- // Factory to create new option.
- // ({ label: string, labelKey: string, valueKey: string }): Object
- newOptionCreator: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func,
- // input change handler: function (inputValue) {}
- onInputChange: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func,
+/***/ }),
+/* 90 */
+/***/ (function(module, exports, __webpack_require__) {
- // input keyDown handler: function (event) {}
- onInputKeyDown: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func,
+"use strict";
- // new option click handler: function (option) {}
- onNewOptionClick: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func,
- // See Select.propTypes.options
- options: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.array,
+exports.__esModule = true;
- // Creates prompt/placeholder option text.
- // (filterText: string): string
- promptTextCreator: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func,
+var _isIterable2 = __webpack_require__(91);
- ref: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func,
+var _isIterable3 = _interopRequireDefault(_isIterable2);
- // Decides if a keyDown event (eg its `keyCode`) should result in the creation of a new option.
- shouldKeyDownEventCreateNewOption: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func,
+var _getIterator2 = __webpack_require__(94);
- // Where to show prompt/placeholder option text.
- // true: new option prompt at top of list (default)
- // false: new option prompt at bottom of list
- showNewOptionAtTop: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool
-};
+var _getIterator3 = _interopRequireDefault(_getIterator2);
-var AsyncCreatableSelect = function (_React$Component) {
- inherits(AsyncCreatableSelect, _React$Component);
+function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
- function AsyncCreatableSelect() {
- classCallCheck(this, AsyncCreatableSelect);
- return possibleConstructorReturn(this, (AsyncCreatableSelect.__proto__ || Object.getPrototypeOf(AsyncCreatableSelect)).apply(this, arguments));
- }
+exports.default = function () {
+ function sliceIterator(arr, i) {
+ var _arr = [];
+ var _n = true;
+ var _d = false;
+ var _e = undefined;
- createClass(AsyncCreatableSelect, [{
- key: 'focus',
- value: function focus() {
- this.select.focus();
- }
- }, {
- key: 'render',
- value: function render() {
- var _this2 = this;
+ try {
+ for (var _i = (0, _getIterator3.default)(arr), _s; !(_n = (_s = _i.next()).done); _n = true) {
+ _arr.push(_s.value);
- return react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement(
- Async,
- this.props,
- function (_ref) {
- var ref = _ref.ref,
- asyncProps = objectWithoutProperties(_ref, ['ref']);
+ if (i && _arr.length === i) break;
+ }
+ } catch (err) {
+ _d = true;
+ _e = err;
+ } finally {
+ try {
+ if (!_n && _i["return"]) _i["return"]();
+ } finally {
+ if (_d) throw _e;
+ }
+ }
- var asyncRef = ref;
- return react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement(
- CreatableSelect,
- asyncProps,
- function (_ref2) {
- var ref = _ref2.ref,
- creatableProps = objectWithoutProperties(_ref2, ['ref']);
+ return _arr;
+ }
- var creatableRef = ref;
- return _this2.props.children(_extends({}, creatableProps, {
- ref: function ref(select) {
- creatableRef(select);
- asyncRef(select);
- _this2.select = select;
- }
- }));
- }
- );
- }
- );
- }
- }]);
- return AsyncCreatableSelect;
-}(react__WEBPACK_IMPORTED_MODULE_3___default.a.Component);
-
-var defaultChildren$1 = function defaultChildren(props) {
- return react__WEBPACK_IMPORTED_MODULE_3___default.a.createElement(Select$1, props);
-};
-
-AsyncCreatableSelect.propTypes = {
- children: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.func.isRequired // Child function responsible for creating the inner Select component; (props: Object): PropTypes.element
-};
+ return function (arr, i) {
+ if (Array.isArray(arr)) {
+ return arr;
+ } else if ((0, _isIterable3.default)(Object(arr))) {
+ return sliceIterator(arr, i);
+ } else {
+ throw new TypeError("Invalid attempt to destructure non-iterable instance");
+ }
+ };
+}();
-AsyncCreatableSelect.defaultProps = {
- children: defaultChildren$1
-};
+/***/ }),
+/* 91 */
+/***/ (function(module, exports, __webpack_require__) {
-Select$1.Async = Async;
-Select$1.AsyncCreatable = AsyncCreatableSelect;
-Select$1.Creatable = CreatableSelect;
-Select$1.Value = Value;
-Select$1.Option = Option;
+module.exports = { "default": __webpack_require__(92), __esModule: true };
+/***/ }),
+/* 92 */
+/***/ (function(module, exports, __webpack_require__) {
-/* harmony default export */ __webpack_exports__["default"] = (Select$1);
+__webpack_require__(34);
+__webpack_require__(25);
+module.exports = __webpack_require__(93);
/***/ }),
-/* 71 */
+/* 93 */
/***/ (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 classof = __webpack_require__(47);
+var ITERATOR = __webpack_require__(3)('iterator');
+var Iterators = __webpack_require__(16);
+module.exports = __webpack_require__(2).isIterable = function (it) {
+ var O = Object(it);
+ return O[ITERATOR] !== undefined
+ || '@@iterator' in O
+ // eslint-disable-next-line no-prototype-builtins
+ || Iterators.hasOwnProperty(classof(O));
+};
-var ReactPropTypesSecret = __webpack_require__(72);
+/***/ }),
+/* 94 */
+/***/ (function(module, exports, __webpack_require__) {
-function emptyFunction() {}
-function emptyFunctionWithReset() {}
-emptyFunctionWithReset.resetWarningCache = emptyFunction;
+module.exports = { "default": __webpack_require__(95), __esModule: true };
-module.exports = function() {
- function shim(props, propName, componentName, location, propFullName, secret) {
- if (secret === ReactPropTypesSecret) {
- // It is still safe when called from React.
- return;
- }
- var err = new Error(
- 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +
- 'Use PropTypes.checkPropTypes() to call them. ' +
- 'Read more at http://fb.me/use-check-prop-types'
- );
- err.name = 'Invariant Violation';
- throw err;
- };
- shim.isRequired = shim;
- function getShim() {
- return shim;
- };
- // Important!
- // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.
- var ReactPropTypes = {
- array: shim,
- bool: shim,
- func: shim,
- number: shim,
- object: shim,
- string: shim,
- symbol: shim,
+/***/ }),
+/* 95 */
+/***/ (function(module, exports, __webpack_require__) {
- any: shim,
- arrayOf: getShim,
- element: shim,
- elementType: shim,
- instanceOf: getShim,
- node: shim,
- objectOf: getShim,
- oneOf: getShim,
- oneOfType: getShim,
- shape: getShim,
- exact: getShim,
+__webpack_require__(34);
+__webpack_require__(25);
+module.exports = __webpack_require__(96);
- checkPropTypes: emptyFunctionWithReset,
- resetWarningCache: emptyFunction
- };
- ReactPropTypes.PropTypes = ReactPropTypes;
+/***/ }),
+/* 96 */
+/***/ (function(module, exports, __webpack_require__) {
- return ReactPropTypes;
+var anObject = __webpack_require__(14);
+var get = __webpack_require__(97);
+module.exports = __webpack_require__(2).getIterator = function (it) {
+ var iterFn = get(it);
+ if (typeof iterFn != 'function') throw TypeError(it + ' is not iterable!');
+ return anObject(iterFn.call(it));
};
/***/ }),
-/* 72 */
+/* 97 */
/***/ (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 classof = __webpack_require__(47);
+var ITERATOR = __webpack_require__(3)('iterator');
+var Iterators = __webpack_require__(16);
+module.exports = __webpack_require__(2).getIteratorMethod = function (it) {
+ if (it != undefined) return it[ITERATOR]
+ || it['@@iterator']
+ || Iterators[classof(it)];
+};
+
+/***/ }),
+/* 98 */
+/***/ (function(module, exports, __webpack_require__) {
+module.exports = { "default": __webpack_require__(99), __esModule: true };
-var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';
+/***/ }),
+/* 99 */
+/***/ (function(module, exports, __webpack_require__) {
-module.exports = ReactPropTypesSecret;
+__webpack_require__(100);
+module.exports = __webpack_require__(2).Object.keys;
/***/ }),
-/* 73 */
+/* 100 */
/***/ (function(module, exports, __webpack_require__) {
-"use strict";
-
+// 19.1.2.14 Object.keys(O)
+var toObject = __webpack_require__(22);
+var $keys = __webpack_require__(17);
-Object.defineProperty(exports, "__esModule", {
- value: true
+__webpack_require__(101)('keys', function () {
+ return function keys(it) {
+ return $keys(toObject(it));
+ };
});
-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 _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__(1);
+/***/ }),
+/* 101 */
+/***/ (function(module, exports, __webpack_require__) {
-var _react2 = _interopRequireDefault(_react);
+// most Object methods by ES6 should accept primitives
+var $export = __webpack_require__(19);
+var core = __webpack_require__(2);
+var fails = __webpack_require__(12);
+module.exports = function (KEY, exec) {
+ var fn = (core.Object || {})[KEY] || Object[KEY];
+ var exp = {};
+ exp[KEY] = exec(fn);
+ $export($export.S + $export.F * fails(function () { fn(1); }), 'Object', exp);
+};
-var _reactLifecyclesCompat = __webpack_require__(46);
-var _JsonViewer = __webpack_require__(74);
+/***/ }),
+/* 102 */
+/***/ (function(module, exports, __webpack_require__) {
-var _JsonViewer2 = _interopRequireDefault(_JsonViewer);
+/* WEBPACK VAR INJECTION */(function(global) {/**
+ * lodash (Custom Build)
+ * Build: `lodash modularize exports="npm" -o ./`
+ * Copyright jQuery Foundation and other contributors
+ * Released under MIT license
+ * Based on Underscore.js 1.8.3
+ * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
+ */
-var _AddKeyRequest = __webpack_require__(186);
+/** Used as the `TypeError` message for "Functions" methods. */
+var FUNC_ERROR_TEXT = 'Expected a function';
-var _AddKeyRequest2 = _interopRequireDefault(_AddKeyRequest);
+/** Used as the internal argument placeholder. */
+var PLACEHOLDER = '__lodash_placeholder__';
-var _ValidationFailure = __webpack_require__(188);
+/** Used to compose bitmasks for function metadata. */
+var BIND_FLAG = 1,
+ BIND_KEY_FLAG = 2,
+ CURRY_BOUND_FLAG = 4,
+ CURRY_FLAG = 8,
+ CURRY_RIGHT_FLAG = 16,
+ PARTIAL_FLAG = 32,
+ PARTIAL_RIGHT_FLAG = 64,
+ ARY_FLAG = 128,
+ REARG_FLAG = 256,
+ FLIP_FLAG = 512;
-var _ValidationFailure2 = _interopRequireDefault(_ValidationFailure);
+/** Used as references for various `Number` constants. */
+var INFINITY = 1 / 0,
+ MAX_SAFE_INTEGER = 9007199254740991,
+ MAX_INTEGER = 1.7976931348623157e+308,
+ NAN = 0 / 0;
-var _util = __webpack_require__(5);
+/** Used to associate wrap methods with their bit flags. */
+var wrapFlags = [
+ ['ary', ARY_FLAG],
+ ['bind', BIND_FLAG],
+ ['bindKey', BIND_KEY_FLAG],
+ ['curry', CURRY_FLAG],
+ ['curryRight', CURRY_RIGHT_FLAG],
+ ['flip', FLIP_FLAG],
+ ['partial', PARTIAL_FLAG],
+ ['partialRight', PARTIAL_RIGHT_FLAG],
+ ['rearg', REARG_FLAG]
+];
-var _ObjectAttributes = __webpack_require__(16);
+/** `Object#toString` result references. */
+var funcTag = '[object Function]',
+ genTag = '[object GeneratorFunction]',
+ symbolTag = '[object Symbol]';
-var _ObjectAttributes2 = _interopRequireDefault(_ObjectAttributes);
+/**
+ * Used to match `RegExp`
+ * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns).
+ */
+var reRegExpChar = /[\\^$.*+?()[\]{}|]/g;
-var _getStyle = __webpack_require__(2);
+/** Used to match leading and trailing whitespace. */
+var reTrim = /^\s+|\s+$/g;
-var _getStyle2 = _interopRequireDefault(_getStyle);
+/** Used to match wrap detail comments. */
+var reWrapComment = /\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,
+ reWrapDetails = /\{\n\/\* \[wrapped with (.+)\] \*/,
+ reSplitDetails = /,? & /;
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+/** Used to detect bad signed hexadecimal string values. */
+var reIsBadHex = /^[-+]0x[0-9a-f]+$/i;
-function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
+/** Used to detect binary string values. */
+var reIsBinary = /^0b[01]+$/i;
-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; }
+/** Used to detect host constructors (Safari). */
+var reIsHostCtor = /^\[object .+?Constructor\]$/;
-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; }
+/** Used to detect octal string values. */
+var reIsOctal = /^0o[0-7]+$/i;
-//global theme
+/** Used to detect unsigned integer values. */
+var reIsUint = /^(?:0|[1-9]\d*)$/;
+/** Built-in method references without a dependency on `root`. */
+var freeParseInt = parseInt;
-//forward src through to JsonObject component
-var ReactJsonView = function (_React$PureComponent) {
- _inherits(ReactJsonView, _React$PureComponent);
+/** Detect free variable `global` from Node.js. */
+var freeGlobal = typeof global == 'object' && global && global.Object === Object && global;
- function ReactJsonView(props) {
- _classCallCheck(this, ReactJsonView);
+/** Detect free variable `self`. */
+var freeSelf = typeof self == 'object' && self && self.Object === Object && self;
- var _this = _possibleConstructorReturn(this, (ReactJsonView.__proto__ || Object.getPrototypeOf(ReactJsonView)).call(this, props));
+/** Used as a reference to the global object. */
+var root = freeGlobal || freeSelf || Function('return this')();
- _this.rjvId = Date.now().toString();
+/**
+ * A faster alternative to `Function#apply`, this function invokes `func`
+ * with the `this` binding of `thisArg` and the arguments of `args`.
+ *
+ * @private
+ * @param {Function} func The function to invoke.
+ * @param {*} thisArg The `this` binding of `func`.
+ * @param {Array} args The arguments to invoke `func` with.
+ * @returns {*} Returns the result of `func`.
+ */
+function apply(func, thisArg, args) {
+ switch (args.length) {
+ case 0: return func.call(thisArg);
+ case 1: return func.call(thisArg, args[0]);
+ case 2: return func.call(thisArg, args[0], args[1]);
+ case 3: return func.call(thisArg, args[0], args[1], args[2]);
+ }
+ return func.apply(thisArg, args);
+}
- _this.getListeners = function () {
- return {
- 'reset': _this.resetState,
- 'variable-update': _this.updateSrc,
- 'add-key-request': _this.addKeyRequest
- };
- };
-
- _this.updateSrc = function () {
- var _ObjectAttributes$get = _ObjectAttributes2.default.get(_this.rjvId, 'action', 'variable-update'),
- name = _ObjectAttributes$get.name,
- namespace = _ObjectAttributes$get.namespace,
- new_value = _ObjectAttributes$get.new_value,
- existing_value = _ObjectAttributes$get.existing_value,
- variable_removed = _ObjectAttributes$get.variable_removed,
- updated_src = _ObjectAttributes$get.updated_src,
- type = _ObjectAttributes$get.type;
-
- var _this$props = _this.props,
- onEdit = _this$props.onEdit,
- onDelete = _this$props.onDelete,
- onAdd = _this$props.onAdd;
- var src = _this.state.src;
-
-
- var result = void 0;
-
- var on_edit_payload = {
- existing_src: src,
- new_value: new_value,
- updated_src: updated_src,
- name: name,
- namespace: namespace,
- existing_value: existing_value
- };
-
- switch (type) {
- case 'variable-added':
- result = onAdd(on_edit_payload);
- break;
- case 'variable-edited':
- result = onEdit(on_edit_payload);
- break;
- case 'variable-removed':
- result = onDelete(on_edit_payload);
- break;
- }
-
- if (result !== false) {
- _ObjectAttributes2.default.set(_this.rjvId, 'global', 'src', updated_src);
- _this.setState({
- src: updated_src
- });
- } else {
- _this.setState({
- validationFailure: true
- });
- }
- };
-
- _this.addKeyRequest = function () {
- _this.setState({
- addKeyRequest: true
- });
- };
-
- _this.resetState = function () {
- _this.setState({
- validationFailure: false,
- addKeyRequest: false
- });
- };
+/**
+ * A specialized version of `_.forEach` for arrays without support for
+ * iteratee shorthands.
+ *
+ * @private
+ * @param {Array} [array] The array to iterate over.
+ * @param {Function} iteratee The function invoked per iteration.
+ * @returns {Array} Returns `array`.
+ */
+function arrayEach(array, iteratee) {
+ var index = -1,
+ length = array ? array.length : 0;
- _this.state = {
- //listen to request to add/edit a key to an object
- addKeyRequest: false,
- editKeyRequest: false,
- validationFailure: false,
- src: ReactJsonView.defaultProps.src,
- name: ReactJsonView.defaultProps.name,
- theme: ReactJsonView.defaultProps.theme,
- validationMessage: ReactJsonView.defaultProps.validationMessage,
- // the state object also needs to remember the prev prop values, because we need to compare
- // old and new props in getDerivedStateFromProps().
- prevSrc: ReactJsonView.defaultProps.src,
- prevName: ReactJsonView.defaultProps.name,
- prevTheme: ReactJsonView.defaultProps.theme
- };
- return _this;
+ while (++index < length) {
+ if (iteratee(array[index], index, array) === false) {
+ break;
}
+ }
+ return array;
+}
- //reference id for this instance
-
-
- //all acceptable props and default values
+/**
+ * A specialized version of `_.includes` for arrays without support for
+ * specifying an index to search from.
+ *
+ * @private
+ * @param {Array} [array] The array to inspect.
+ * @param {*} target The value to search for.
+ * @returns {boolean} Returns `true` if `target` is found, else `false`.
+ */
+function arrayIncludes(array, value) {
+ var length = array ? array.length : 0;
+ return !!length && baseIndexOf(array, value, 0) > -1;
+}
+/**
+ * The base implementation of `_.findIndex` and `_.findLastIndex` without
+ * support for iteratee shorthands.
+ *
+ * @private
+ * @param {Array} array The array to inspect.
+ * @param {Function} predicate The function invoked per iteration.
+ * @param {number} fromIndex The index to search from.
+ * @param {boolean} [fromRight] Specify iterating from right to left.
+ * @returns {number} Returns the index of the matched value, else `-1`.
+ */
+function baseFindIndex(array, predicate, fromIndex, fromRight) {
+ var length = array.length,
+ index = fromIndex + (fromRight ? 1 : -1);
- _createClass(ReactJsonView, [{
- key: 'componentDidMount',
- value: function componentDidMount() {
- // initialize
- _ObjectAttributes2.default.set(this.rjvId, 'global', 'src', this.state.src);
- // bind to events
- var listeners = this.getListeners();
- for (var i in listeners) {
- _ObjectAttributes2.default.on(i + '-' + this.rjvId, listeners[i]);
- }
- //reset key request to false once it's observed
- this.setState({
- addKeyRequest: false,
- editKeyRequest: false
- });
- }
- }, {
- key: 'componentDidUpdate',
- value: function componentDidUpdate(prevProps, prevState) {
- //reset key request to false once it's observed
- if (prevState.addKeyRequest !== false) {
- this.setState({
- addKeyRequest: false
- });
- }
- if (prevState.editKeyRequest !== false) {
- this.setState({
- editKeyRequest: false
- });
- }
- if (prevProps.src !== this.state.src) {
- _ObjectAttributes2.default.set(this.rjvId, 'global', 'src', this.state.src);
- }
- }
- }, {
- key: 'componentWillUnmount',
- value: function componentWillUnmount() {
- var listeners = this.getListeners();
- for (var i in listeners) {
- _ObjectAttributes2.default.removeListener(i + '-' + this.rjvId, listeners[i]);
- }
- }
- //make sure props are passed in as expected
-
- }, {
- key: 'render',
- value: function render() {
- var _state = this.state,
- validationFailure = _state.validationFailure,
- validationMessage = _state.validationMessage,
- addKeyRequest = _state.addKeyRequest,
- theme = _state.theme,
- src = _state.src,
- name = _state.name;
- var _props = this.props,
- style = _props.style,
- defaultValue = _props.defaultValue;
-
-
- return _react2.default.createElement(
- 'div',
- {
- className: 'react-json-view',
- style: _extends({}, (0, _getStyle2.default)(theme, 'app-container').style, style)
- },
- _react2.default.createElement(_ValidationFailure2.default, {
- message: validationMessage,
- active: validationFailure,
- theme: theme,
- rjvId: this.rjvId }),
- _react2.default.createElement(_JsonViewer2.default, _extends({}, this.props, {
- src: src,
- name: name,
- theme: theme,
- type: (0, _util.toType)(src),
- rjvId: this.rjvId })),
- _react2.default.createElement(_AddKeyRequest2.default, {
- active: addKeyRequest,
- theme: theme,
- rjvId: this.rjvId,
- defaultValue: defaultValue })
- );
- }
- }], [{
- key: 'getDerivedStateFromProps',
-
-
- // will trigger whenever setState() is called, or parent passes in new props.
- value: function getDerivedStateFromProps(nextProps, prevState) {
- if (nextProps.src !== prevState.prevSrc || nextProps.name !== prevState.prevName || nextProps.theme !== prevState.prevTheme) {
- // if we pass in new props, we re-validate
- var newPartialState = {
- src: nextProps.src,
- name: nextProps.name,
- theme: nextProps.theme,
- validationMessage: nextProps.validationMessage,
- prevSrc: nextProps.src,
- prevName: nextProps.name,
- prevTheme: nextProps.theme
- };
- return ReactJsonView.validateState(newPartialState);
- }
- return null;
- }
- }]);
-
- return ReactJsonView;
-}(_react2.default.PureComponent);
-
-ReactJsonView.defaultProps = {
- src: {},
- name: 'root',
- theme: 'rjv-default',
- collapsed: false,
- collapseStringsAfterLength: false,
- shouldCollapse: false,
- sortKeys: false,
- groupArraysAfterLength: 100,
- indentWidth: 4,
- enableClipboard: true,
- displayObjectSize: true,
- displayDataTypes: true,
- onEdit: false,
- onDelete: false,
- onAdd: false,
- onSelect: false,
- iconStyle: 'triangle',
- style: {},
- validationMessage: 'Validation Error',
- defaultValue: null };
-
-ReactJsonView.validateState = function (state) {
- var validatedState = {};
- //make sure theme is valid
- if ((0, _util.toType)(state.theme) === 'object' && !(0, _util.isTheme)(state.theme)) {
- console.error('react-json-view error:', 'theme prop must be a theme name or valid base-16 theme object.', 'defaulting to "rjv-default" theme');
- validatedState.theme = 'rjv-default';
- }
- //make sure `src` prop is valid
- if ((0, _util.toType)(state.src) !== 'object' && (0, _util.toType)(state.src) !== 'array') {
- console.error('react-json-view error:', 'src property must be a valid json object');
- validatedState.name = 'ERROR';
- validatedState.src = {
- message: 'src property must be a valid json object'
- };
+ while ((fromRight ? index-- : ++index < length)) {
+ if (predicate(array[index], index, array)) {
+ return index;
}
- return _extends({}, state, validatedState);
-};
-
-(0, _reactLifecyclesCompat.polyfill)(ReactJsonView);
-
-exports.default = ReactJsonView;
-
-/***/ }),
-/* 74 */
-/***/ (function(module, exports, __webpack_require__) {
-
-"use strict";
-
-
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
+ }
+ return -1;
+}
-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; };
+/**
+ * The base implementation of `_.indexOf` without `fromIndex` bounds checks.
+ *
+ * @private
+ * @param {Array} array The array to inspect.
+ * @param {*} value The value to search for.
+ * @param {number} fromIndex The index to search from.
+ * @returns {number} Returns the index of the matched value, else `-1`.
+ */
+function baseIndexOf(array, value, fromIndex) {
+ if (value !== value) {
+ return baseFindIndex(array, baseIsNaN, fromIndex);
+ }
+ var index = fromIndex - 1,
+ length = array.length;
-var _react = __webpack_require__(1);
+ while (++index < length) {
+ if (array[index] === value) {
+ return index;
+ }
+ }
+ return -1;
+}
-var _react2 = _interopRequireDefault(_react);
+/**
+ * The base implementation of `_.isNaN` without support for number objects.
+ *
+ * @private
+ * @param {*} value The value to check.
+ * @returns {boolean} Returns `true` if `value` is `NaN`, else `false`.
+ */
+function baseIsNaN(value) {
+ return value !== value;
+}
-var _Object = __webpack_require__(31);
+/**
+ * Gets the number of `placeholder` occurrences in `array`.
+ *
+ * @private
+ * @param {Array} array The array to inspect.
+ * @param {*} placeholder The placeholder to search for.
+ * @returns {number} Returns the placeholder count.
+ */
+function countHolders(array, placeholder) {
+ var length = array.length,
+ result = 0;
-var _Object2 = _interopRequireDefault(_Object);
+ while (length--) {
+ if (array[length] === placeholder) {
+ result++;
+ }
+ }
+ return result;
+}
-var _ArrayGroup = __webpack_require__(62);
+/**
+ * Gets the value at `key` of `object`.
+ *
+ * @private
+ * @param {Object} [object] The object to query.
+ * @param {string} key The key of the property to get.
+ * @returns {*} Returns the property value.
+ */
+function getValue(object, key) {
+ return object == null ? undefined : object[key];
+}
-var _ArrayGroup2 = _interopRequireDefault(_ArrayGroup);
+/**
+ * Checks if `value` is a host object in IE < 9.
+ *
+ * @private
+ * @param {*} value The value to check.
+ * @returns {boolean} Returns `true` if `value` is a host object, else `false`.
+ */
+function isHostObject(value) {
+ // Many host objects are `Object` objects that can coerce to strings
+ // despite having improperly defined `toString` methods.
+ var result = false;
+ if (value != null && typeof value.toString != 'function') {
+ try {
+ result = !!(value + '');
+ } catch (e) {}
+ }
+ return result;
+}
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+/**
+ * Replaces all `placeholder` elements in `array` with an internal placeholder
+ * and returns an array of their indexes.
+ *
+ * @private
+ * @param {Array} array The array to modify.
+ * @param {*} placeholder The placeholder to replace.
+ * @returns {Array} Returns the new array of placeholder indexes.
+ */
+function replaceHolders(array, placeholder) {
+ var index = -1,
+ length = array.length,
+ resIndex = 0,
+ result = [];
-function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
+ while (++index < length) {
+ var value = array[index];
+ if (value === placeholder || value === PLACEHOLDER) {
+ array[index] = PLACEHOLDER;
+ result[resIndex++] = index;
+ }
+ }
+ return result;
+}
-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; }
+/** Used for built-in method references. */
+var funcProto = Function.prototype,
+ objectProto = Object.prototype;
-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; }
+/** Used to detect overreaching core-js shims. */
+var coreJsData = root['__core-js_shared__'];
-var _class = function (_React$PureComponent) {
- _inherits(_class, _React$PureComponent);
+/** Used to detect methods masquerading as native. */
+var maskSrcKey = (function() {
+ var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || '');
+ return uid ? ('Symbol(src)_1.' + uid) : '';
+}());
- function _class() {
- var _ref;
+/** Used to resolve the decompiled source of functions. */
+var funcToString = funcProto.toString;
- var _temp, _this, _ret;
+/** Used to check objects for own properties. */
+var hasOwnProperty = objectProto.hasOwnProperty;
- _classCallCheck(this, _class);
+/**
+ * Used to resolve the
+ * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)
+ * of values.
+ */
+var objectToString = objectProto.toString;
- for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {
- args[_key] = arguments[_key];
- }
+/** Used to detect if a method is native. */
+var reIsNative = RegExp('^' +
+ funcToString.call(hasOwnProperty).replace(reRegExpChar, '\\$&')
+ .replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$'
+);
- return _ret = (_temp = (_this = _possibleConstructorReturn(this, (_ref = _class.__proto__ || Object.getPrototypeOf(_class)).call.apply(_ref, [this].concat(args))), _this), _this.render = function () {
- var _this2 = _this,
- props = _this2.props;
+/** Built-in value references. */
+var objectCreate = Object.create;
- var namespace = [props.name];
- var ObjectComponent = _Object2.default;
+/* Built-in method references for those with the same name as other `lodash` methods. */
+var nativeMax = Math.max,
+ nativeMin = Math.min;
- if (props.groupArraysAfterLength && props.src.length > props.groupArraysAfterLength) {
- ObjectComponent = _ArrayGroup2.default;
- }
+/* Used to set `toString` methods. */
+var defineProperty = (function() {
+ var func = getNative(Object, 'defineProperty'),
+ name = getNative.name;
- return _react2.default.createElement(
- 'div',
- { className: 'pretty-json-container object-container' },
- _react2.default.createElement(
- 'div',
- { className: 'object-content' },
- _react2.default.createElement(ObjectComponent, _extends({
- namespace: namespace,
- depth: 0,
- jsvRoot: true
- }, props))
- )
- );
- }, _temp), _possibleConstructorReturn(_this, _ret);
- }
+ return (name && name.length > 2) ? func : undefined;
+}());
- return _class;
-}(_react2.default.PureComponent);
+/**
+ * The base implementation of `_.create` without support for assigning
+ * properties to the created object.
+ *
+ * @private
+ * @param {Object} prototype The object to inherit from.
+ * @returns {Object} Returns the new object.
+ */
+function baseCreate(proto) {
+ return isObject(proto) ? objectCreate(proto) : {};
+}
-exports.default = _class;
-
-/***/ }),
-/* 75 */
-/***/ (function(module, exports, __webpack_require__) {
-
-"use strict";
-
-
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
-
-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 _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__(1);
+/**
+ * The base implementation of `_.isNative` without bad shim checks.
+ *
+ * @private
+ * @param {*} value The value to check.
+ * @returns {boolean} Returns `true` if `value` is a native function,
+ * else `false`.
+ */
+function baseIsNative(value) {
+ if (!isObject(value) || isMasked(value)) {
+ return false;
+ }
+ var pattern = (isFunction(value) || isHostObject(value)) ? reIsNative : reIsHostCtor;
+ return pattern.test(toSource(value));
+}
-var _react2 = _interopRequireDefault(_react);
+/**
+ * Creates an array that is the composition of partially applied arguments,
+ * placeholders, and provided arguments into a single array of arguments.
+ *
+ * @private
+ * @param {Array} args The provided arguments.
+ * @param {Array} partials The arguments to prepend to those provided.
+ * @param {Array} holders The `partials` placeholder indexes.
+ * @params {boolean} [isCurried] Specify composing for a curried function.
+ * @returns {Array} Returns the new array of composed arguments.
+ */
+function composeArgs(args, partials, holders, isCurried) {
+ var argsIndex = -1,
+ argsLength = args.length,
+ holdersLength = holders.length,
+ leftIndex = -1,
+ leftLength = partials.length,
+ rangeLength = nativeMax(argsLength - holdersLength, 0),
+ result = Array(leftLength + rangeLength),
+ isUncurried = !isCurried;
-var _DataTypeLabel = __webpack_require__(9);
+ while (++leftIndex < leftLength) {
+ result[leftIndex] = partials[leftIndex];
+ }
+ while (++argsIndex < holdersLength) {
+ if (isUncurried || argsIndex < argsLength) {
+ result[holders[argsIndex]] = args[argsIndex];
+ }
+ }
+ while (rangeLength--) {
+ result[leftIndex++] = args[argsIndex++];
+ }
+ return result;
+}
-var _DataTypeLabel2 = _interopRequireDefault(_DataTypeLabel);
+/**
+ * This function is like `composeArgs` except that the arguments composition
+ * is tailored for `_.partialRight`.
+ *
+ * @private
+ * @param {Array} args The provided arguments.
+ * @param {Array} partials The arguments to append to those provided.
+ * @param {Array} holders The `partials` placeholder indexes.
+ * @params {boolean} [isCurried] Specify composing for a curried function.
+ * @returns {Array} Returns the new array of composed arguments.
+ */
+function composeArgsRight(args, partials, holders, isCurried) {
+ var argsIndex = -1,
+ argsLength = args.length,
+ holdersIndex = -1,
+ holdersLength = holders.length,
+ rightIndex = -1,
+ rightLength = partials.length,
+ rangeLength = nativeMax(argsLength - holdersLength, 0),
+ result = Array(rangeLength + rightLength),
+ isUncurried = !isCurried;
-var _getStyle = __webpack_require__(2);
+ while (++argsIndex < rangeLength) {
+ result[argsIndex] = args[argsIndex];
+ }
+ var offset = argsIndex;
+ while (++rightIndex < rightLength) {
+ result[offset + rightIndex] = partials[rightIndex];
+ }
+ while (++holdersIndex < holdersLength) {
+ if (isUncurried || argsIndex < argsLength) {
+ result[offset + holders[holdersIndex]] = args[argsIndex++];
+ }
+ }
+ return result;
+}
-var _getStyle2 = _interopRequireDefault(_getStyle);
+/**
+ * Copies the values of `source` to `array`.
+ *
+ * @private
+ * @param {Array} source The array to copy values from.
+ * @param {Array} [array=[]] The array to copy values to.
+ * @returns {Array} Returns `array`.
+ */
+function copyArray(source, array) {
+ var index = -1,
+ length = source.length;
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+ array || (array = Array(length));
+ while (++index < length) {
+ array[index] = source[index];
+ }
+ return array;
+}
-function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
+/**
+ * Creates a function that wraps `func` to invoke it with the optional `this`
+ * binding of `thisArg`.
+ *
+ * @private
+ * @param {Function} func The function to wrap.
+ * @param {number} bitmask The bitmask flags. See `createWrap` for more details.
+ * @param {*} [thisArg] The `this` binding of `func`.
+ * @returns {Function} Returns the new wrapped function.
+ */
+function createBind(func, bitmask, thisArg) {
+ var isBind = bitmask & BIND_FLAG,
+ Ctor = createCtor(func);
-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 wrapper() {
+ var fn = (this && this !== root && this instanceof wrapper) ? Ctor : func;
+ return fn.apply(isBind ? thisArg : this, arguments);
+ }
+ return wrapper;
+}
-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; }
+/**
+ * Creates a function that produces an instance of `Ctor` regardless of
+ * whether it was invoked as part of a `new` expression or by `call` or `apply`.
+ *
+ * @private
+ * @param {Function} Ctor The constructor to wrap.
+ * @returns {Function} Returns the new wrapped function.
+ */
+function createCtor(Ctor) {
+ return function() {
+ // Use a `switch` statement to work with class constructors. See
+ // http://ecma-international.org/ecma-262/7.0/#sec-ecmascript-function-objects-call-thisargument-argumentslist
+ // for more details.
+ var args = arguments;
+ switch (args.length) {
+ case 0: return new Ctor;
+ case 1: return new Ctor(args[0]);
+ case 2: return new Ctor(args[0], args[1]);
+ case 3: return new Ctor(args[0], args[1], args[2]);
+ case 4: return new Ctor(args[0], args[1], args[2], args[3]);
+ case 5: return new Ctor(args[0], args[1], args[2], args[3], args[4]);
+ case 6: return new Ctor(args[0], args[1], args[2], args[3], args[4], args[5]);
+ case 7: return new Ctor(args[0], args[1], args[2], args[3], args[4], args[5], args[6]);
+ }
+ var thisBinding = baseCreate(Ctor.prototype),
+ result = Ctor.apply(thisBinding, args);
-//theme
+ // Mimic the constructor's `return` behavior.
+ // See https://es5.github.io/#x13.2.2 for more details.
+ return isObject(result) ? result : thisBinding;
+ };
+}
+/**
+ * Creates a function that wraps `func` to enable currying.
+ *
+ * @private
+ * @param {Function} func The function to wrap.
+ * @param {number} bitmask The bitmask flags. See `createWrap` for more details.
+ * @param {number} arity The arity of `func`.
+ * @returns {Function} Returns the new wrapped function.
+ */
+function createCurry(func, bitmask, arity) {
+ var Ctor = createCtor(func);
-var _class = function (_React$PureComponent) {
- _inherits(_class, _React$PureComponent);
+ function wrapper() {
+ var length = arguments.length,
+ args = Array(length),
+ index = length,
+ placeholder = getHolder(wrapper);
- function _class() {
- _classCallCheck(this, _class);
+ while (index--) {
+ args[index] = arguments[index];
+ }
+ var holders = (length < 3 && args[0] !== placeholder && args[length - 1] !== placeholder)
+ ? []
+ : replaceHolders(args, placeholder);
- return _possibleConstructorReturn(this, (_class.__proto__ || Object.getPrototypeOf(_class)).apply(this, arguments));
+ length -= holders.length;
+ if (length < arity) {
+ return createRecurry(
+ func, bitmask, createHybrid, wrapper.placeholder, undefined,
+ args, holders, undefined, undefined, arity - length);
}
+ var fn = (this && this !== root && this instanceof wrapper) ? Ctor : func;
+ return apply(fn, this, args);
+ }
+ return wrapper;
+}
- _createClass(_class, [{
- key: 'render',
- value: function render() {
- var type_name = 'bool';
- var props = this.props;
+/**
+ * Creates a function that wraps `func` to invoke it with optional `this`
+ * binding of `thisArg`, partial application, and currying.
+ *
+ * @private
+ * @param {Function|string} func The function or method name to wrap.
+ * @param {number} bitmask The bitmask flags. See `createWrap` for more details.
+ * @param {*} [thisArg] The `this` binding of `func`.
+ * @param {Array} [partials] The arguments to prepend to those provided to
+ * the new function.
+ * @param {Array} [holders] The `partials` placeholder indexes.
+ * @param {Array} [partialsRight] The arguments to append to those provided
+ * to the new function.
+ * @param {Array} [holdersRight] The `partialsRight` placeholder indexes.
+ * @param {Array} [argPos] The argument positions of the new function.
+ * @param {number} [ary] The arity cap of `func`.
+ * @param {number} [arity] The arity of `func`.
+ * @returns {Function} Returns the new wrapped function.
+ */
+function createHybrid(func, bitmask, thisArg, partials, holders, partialsRight, holdersRight, argPos, ary, arity) {
+ var isAry = bitmask & ARY_FLAG,
+ isBind = bitmask & BIND_FLAG,
+ isBindKey = bitmask & BIND_KEY_FLAG,
+ isCurried = bitmask & (CURRY_FLAG | CURRY_RIGHT_FLAG),
+ isFlip = bitmask & FLIP_FLAG,
+ Ctor = isBindKey ? undefined : createCtor(func);
+ function wrapper() {
+ var length = arguments.length,
+ args = Array(length),
+ index = length;
- return _react2.default.createElement(
- 'div',
- (0, _getStyle2.default)(props.theme, 'boolean'),
- _react2.default.createElement(_DataTypeLabel2.default, _extends({ type_name: type_name }, props)),
- props.value ? 'true' : 'false'
- );
- }
- }]);
+ while (index--) {
+ args[index] = arguments[index];
+ }
+ if (isCurried) {
+ var placeholder = getHolder(wrapper),
+ holdersCount = countHolders(args, placeholder);
+ }
+ if (partials) {
+ args = composeArgs(args, partials, holders, isCurried);
+ }
+ if (partialsRight) {
+ args = composeArgsRight(args, partialsRight, holdersRight, isCurried);
+ }
+ length -= holdersCount;
+ if (isCurried && length < arity) {
+ var newHolders = replaceHolders(args, placeholder);
+ return createRecurry(
+ func, bitmask, createHybrid, wrapper.placeholder, thisArg,
+ args, newHolders, argPos, ary, arity - length
+ );
+ }
+ var thisBinding = isBind ? thisArg : this,
+ fn = isBindKey ? thisBinding[func] : func;
- return _class;
-}(_react2.default.PureComponent);
+ length = args.length;
+ if (argPos) {
+ args = reorder(args, argPos);
+ } else if (isFlip && length > 1) {
+ args.reverse();
+ }
+ if (isAry && ary < length) {
+ args.length = ary;
+ }
+ if (this && this !== root && this instanceof wrapper) {
+ fn = Ctor || createCtor(fn);
+ }
+ return fn.apply(thisBinding, args);
+ }
+ return wrapper;
+}
-exports.default = _class;
+/**
+ * Creates a function that wraps `func` to invoke it with the `this` binding
+ * of `thisArg` and `partials` prepended to the arguments it receives.
+ *
+ * @private
+ * @param {Function} func The function to wrap.
+ * @param {number} bitmask The bitmask flags. See `createWrap` for more details.
+ * @param {*} thisArg The `this` binding of `func`.
+ * @param {Array} partials The arguments to prepend to those provided to
+ * the new function.
+ * @returns {Function} Returns the new wrapped function.
+ */
+function createPartial(func, bitmask, thisArg, partials) {
+ var isBind = bitmask & BIND_FLAG,
+ Ctor = createCtor(func);
-/***/ }),
-/* 76 */
-/***/ (function(module, exports, __webpack_require__) {
+ function wrapper() {
+ var argsIndex = -1,
+ argsLength = arguments.length,
+ leftIndex = -1,
+ leftLength = partials.length,
+ args = Array(leftLength + argsLength),
+ fn = (this && this !== root && this instanceof wrapper) ? Ctor : func;
-"use strict";
+ while (++leftIndex < leftLength) {
+ args[leftIndex] = partials[leftIndex];
+ }
+ while (argsLength--) {
+ args[leftIndex++] = arguments[++argsIndex];
+ }
+ return apply(fn, isBind ? thisArg : this, args);
+ }
+ return wrapper;
+}
+/**
+ * Creates a function that wraps `func` to continue currying.
+ *
+ * @private
+ * @param {Function} func The function to wrap.
+ * @param {number} bitmask The bitmask flags. See `createWrap` for more details.
+ * @param {Function} wrapFunc The function to create the `func` wrapper.
+ * @param {*} placeholder The placeholder value.
+ * @param {*} [thisArg] The `this` binding of `func`.
+ * @param {Array} [partials] The arguments to prepend to those provided to
+ * the new function.
+ * @param {Array} [holders] The `partials` placeholder indexes.
+ * @param {Array} [argPos] The argument positions of the new function.
+ * @param {number} [ary] The arity cap of `func`.
+ * @param {number} [arity] The arity of `func`.
+ * @returns {Function} Returns the new wrapped function.
+ */
+function createRecurry(func, bitmask, wrapFunc, placeholder, thisArg, partials, holders, argPos, ary, arity) {
+ var isCurry = bitmask & CURRY_FLAG,
+ newHolders = isCurry ? holders : undefined,
+ newHoldersRight = isCurry ? undefined : holders,
+ newPartials = isCurry ? partials : undefined,
+ newPartialsRight = isCurry ? undefined : partials;
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
-var rjv_default = exports.rjv_default = {
- scheme: 'rjv-default',
- author: 'mac gainor',
- //transparent main background
- base00: 'rgba(0, 0, 0, 0)',
- base01: 'rgb(245, 245, 245)',
- base02: 'rgb(235, 235, 235)',
- base03: '#93a1a1',
- base04: 'rgba(0, 0, 0, 0.3)',
- base05: '#586e75',
- base06: '#073642',
- base07: '#002b36',
- base08: '#d33682',
- base09: '#cb4b16',
- base0A: '#dc322f',
- base0B: '#859900',
- base0C: '#6c71c4',
- base0D: '#586e75',
- base0E: '#2aa198',
- base0F: '#268bd2'
-};
-
-var rjv_grey = exports.rjv_grey = {
- scheme: 'rjv-grey',
- author: 'mac gainor',
- base00: 'rgba(1, 1, 1, 0)',
- base01: 'rgba(1, 1, 1, 0.1)',
- base02: 'rgba(0, 0, 0, 0.2)',
- base03: 'rgba(1, 1, 1, 0.3)',
- base04: 'rgba(0, 0, 0, 0.4)',
- base05: 'rgba(1, 1, 1, 0.5)',
- base06: 'rgba(1, 1, 1, 0.6)',
- base07: 'rgba(1, 1, 1, 0.7)',
- base08: 'rgba(1, 1, 1, 0.8)',
- base09: 'rgba(1, 1, 1, 0.8)',
- base0A: 'rgba(1, 1, 1, 0.8)',
- base0B: 'rgba(1, 1, 1, 0.8)',
- base0C: 'rgba(1, 1, 1, 0.8)',
- base0D: 'rgba(1, 1, 1, 0.8)',
- base0E: 'rgba(1, 1, 1, 0.8)',
- base0F: 'rgba(1, 1, 1, 0.8)'
-};
+ bitmask |= (isCurry ? PARTIAL_FLAG : PARTIAL_RIGHT_FLAG);
+ bitmask &= ~(isCurry ? PARTIAL_RIGHT_FLAG : PARTIAL_FLAG);
-/***/ }),
-/* 77 */
-/***/ (function(module, exports, __webpack_require__) {
+ if (!(bitmask & CURRY_BOUND_FLAG)) {
+ bitmask &= ~(BIND_FLAG | BIND_KEY_FLAG);
+ }
-"use strict";
+ var result = wrapFunc(func, bitmask, thisArg, newPartials, newHolders, newPartialsRight, newHoldersRight, argPos, ary, arity);
+ result.placeholder = placeholder;
+ return setWrapToString(result, func, bitmask);
+}
+/**
+ * Creates a function that either curries or invokes `func` with optional
+ * `this` binding and partially applied arguments.
+ *
+ * @private
+ * @param {Function|string} func The function or method name to wrap.
+ * @param {number} bitmask The bitmask flags.
+ * The bitmask may be composed of the following flags:
+ * 1 - `_.bind`
+ * 2 - `_.bindKey`
+ * 4 - `_.curry` or `_.curryRight` of a bound function
+ * 8 - `_.curry`
+ * 16 - `_.curryRight`
+ * 32 - `_.partial`
+ * 64 - `_.partialRight`
+ * 128 - `_.rearg`
+ * 256 - `_.ary`
+ * 512 - `_.flip`
+ * @param {*} [thisArg] The `this` binding of `func`.
+ * @param {Array} [partials] The arguments to be partially applied.
+ * @param {Array} [holders] The `partials` placeholder indexes.
+ * @param {Array} [argPos] The argument positions of the new function.
+ * @param {number} [ary] The arity cap of `func`.
+ * @param {number} [arity] The arity of `func`.
+ * @returns {Function} Returns the new wrapped function.
+ */
+function createWrap(func, bitmask, thisArg, partials, holders, argPos, ary, arity) {
+ var isBindKey = bitmask & BIND_KEY_FLAG;
+ if (!isBindKey && typeof func != 'function') {
+ throw new TypeError(FUNC_ERROR_TEXT);
+ }
+ var length = partials ? partials.length : 0;
+ if (!length) {
+ bitmask &= ~(PARTIAL_FLAG | PARTIAL_RIGHT_FLAG);
+ partials = holders = undefined;
+ }
+ ary = ary === undefined ? ary : nativeMax(toInteger(ary), 0);
+ arity = arity === undefined ? arity : toInteger(arity);
+ length -= holders ? holders.length : 0;
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
-exports.default = {
- white: '#fff',
- black: '#000',
- transparent: 'rgba(1, 1, 1, 0)',
+ if (bitmask & PARTIAL_RIGHT_FLAG) {
+ var partialsRight = partials,
+ holdersRight = holders;
- globalFontFamily: 'monospace',
- globalCursor: 'default',
+ partials = holders = undefined;
+ }
- indentBlockWidth: '5px',
+ var newData = [
+ func, bitmask, thisArg, partials, holders, partialsRight, holdersRight,
+ argPos, ary, arity
+ ];
- braceFontWeight: 'bold',
- braceCursor: 'pointer',
+ func = newData[0];
+ bitmask = newData[1];
+ thisArg = newData[2];
+ partials = newData[3];
+ holders = newData[4];
+ arity = newData[9] = newData[9] == null
+ ? (isBindKey ? 0 : func.length)
+ : nativeMax(newData[9] - length, 0);
- ellipsisFontSize: '18px',
- ellipsisLineHeight: '10px',
- ellipsisCursor: 'pointer',
+ if (!arity && bitmask & (CURRY_FLAG | CURRY_RIGHT_FLAG)) {
+ bitmask &= ~(CURRY_FLAG | CURRY_RIGHT_FLAG);
+ }
+ if (!bitmask || bitmask == BIND_FLAG) {
+ var result = createBind(func, bitmask, thisArg);
+ } else if (bitmask == CURRY_FLAG || bitmask == CURRY_RIGHT_FLAG) {
+ result = createCurry(func, bitmask, arity);
+ } else if ((bitmask == PARTIAL_FLAG || bitmask == (BIND_FLAG | PARTIAL_FLAG)) && !holders.length) {
+ result = createPartial(func, bitmask, thisArg, partials);
+ } else {
+ result = createHybrid.apply(undefined, newData);
+ }
+ return setWrapToString(result, func, bitmask);
+}
- keyMargin: '0px 5px',
- keyLetterSpacing: '0.5px',
- keyFontStyle: 'none',
- keyBorderRadius: '3px',
- keyColonWeight: 'bold',
- keyVerticalAlign: 'top',
- keyOpacity: '0.85',
- keyOpacityHover: '1',
+/**
+ * Gets the argument placeholder value for `func`.
+ *
+ * @private
+ * @param {Function} func The function to inspect.
+ * @returns {*} Returns the placeholder value.
+ */
+function getHolder(func) {
+ var object = func;
+ return object.placeholder;
+}
- keyValPaddingTop: '3px',
- keyValPaddingBottom: '3px',
- keyValPaddingRight: '5px',
- keyValBorderLeft: '1px solid',
- keyValBorderHover: '2px solid',
- keyValPaddingHover: '3px 5px 3px 4px',
+/**
+ * Gets the native function at `key` of `object`.
+ *
+ * @private
+ * @param {Object} object The object to query.
+ * @param {string} key The key of the method to get.
+ * @returns {*} Returns the function if it's native, else `undefined`.
+ */
+function getNative(object, key) {
+ var value = getValue(object, key);
+ return baseIsNative(value) ? value : undefined;
+}
- pushedContentMarginLeft: '6px',
+/**
+ * Extracts wrapper details from the `source` body comment.
+ *
+ * @private
+ * @param {string} source The source to inspect.
+ * @returns {Array} Returns the wrapper details.
+ */
+function getWrapDetails(source) {
+ var match = source.match(reWrapDetails);
+ return match ? match[1].split(reSplitDetails) : [];
+}
- variableValuePaddingRight: '6px',
+/**
+ * Inserts wrapper `details` in a comment at the top of the `source` body.
+ *
+ * @private
+ * @param {string} source The source to modify.
+ * @returns {Array} details The details to insert.
+ * @returns {string} Returns the modified source.
+ */
+function insertWrapDetails(source, details) {
+ var length = details.length,
+ lastIndex = length - 1;
- nullFontSize: '11px',
- nullFontWeight: 'bold',
- nullPadding: '1px 2px',
- nullBorderRadius: '3px',
+ details[lastIndex] = (length > 1 ? '& ' : '') + details[lastIndex];
+ details = details.join(length > 2 ? ', ' : ' ');
+ return source.replace(reWrapComment, '{\n/* [wrapped with ' + details + '] */\n');
+}
- nanFontSize: '11px',
- nanFontWeight: 'bold',
- nanPadding: '1px 2px',
- nanBorderRadius: '3px',
+/**
+ * Checks if `value` is a valid array-like index.
+ *
+ * @private
+ * @param {*} value The value to check.
+ * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index.
+ * @returns {boolean} Returns `true` if `value` is a valid index, else `false`.
+ */
+function isIndex(value, length) {
+ length = length == null ? MAX_SAFE_INTEGER : length;
+ return !!length &&
+ (typeof value == 'number' || reIsUint.test(value)) &&
+ (value > -1 && value % 1 == 0 && value < length);
+}
- undefinedFontSize: '11px',
- undefinedFontWeight: 'bold',
- undefinedPadding: '1px 2px',
- undefinedBorderRadius: '3px',
+/**
+ * Checks if `func` has its source masked.
+ *
+ * @private
+ * @param {Function} func The function to check.
+ * @returns {boolean} Returns `true` if `func` is masked, else `false`.
+ */
+function isMasked(func) {
+ return !!maskSrcKey && (maskSrcKey in func);
+}
- dataTypeFontSize: '11px',
- dataTypeMarginRight: '4px',
- datatypeOpacity: '0.8',
+/**
+ * Reorder `array` according to the specified indexes where the element at
+ * the first index is assigned as the first element, the element at
+ * the second index is assigned as the second element, and so on.
+ *
+ * @private
+ * @param {Array} array The array to reorder.
+ * @param {Array} indexes The arranged array indexes.
+ * @returns {Array} Returns `array`.
+ */
+function reorder(array, indexes) {
+ var arrLength = array.length,
+ length = nativeMin(indexes.length, arrLength),
+ oldArray = copyArray(array);
- objectSizeBorderRadius: '3px',
- objectSizeFontStyle: 'italic',
- objectSizeMargin: '0px 6px 0px 0px',
+ while (length--) {
+ var index = indexes[length];
+ array[length] = isIndex(index, arrLength) ? oldArray[index] : undefined;
+ }
+ return array;
+}
- clipboardCursor: 'pointer',
- clipboardCheckMarginLeft: '-12px',
-
- metaDataPadding: '0px 0px 0px 10px',
-
- arrayGroupMetaPadding: '0px 0px 0px 4px',
-
- iconContainerWidth: '17px',
-
- tooltipPadding: '4px',
-
- editInputHeight: '25px',
- editInputMinWidth: '130px',
- editInputBorderRadius: '2px',
- editInputPadding: '5px',
- editInputMarginRight: '4px',
- editInputFontFamily: 'monospace',
-
- iconCursor: 'pointer',
- iconFontSize: '15px',
- iconPaddingRight: '1px',
-
- dateValueMarginLeft: '2px',
-
- iconMarginRight: '3px',
-
- detectedRowPaddingTop: '3px',
-
- addKeyCoverBackground: 'rgba(255, 255, 255, 0.3)',
- addKeyCoverPosition: 'absolute',
- addKeyCoverPositionPx: '0px',
- addKeyModalWidth: '200px',
- addKeyModalMargin: 'auto',
- addKeyModalPadding: '10px',
- addKeyModalRadius: '3px'
+/**
+ * Sets the `toString` method of `wrapper` to mimic the source of `reference`
+ * with wrapper details in a comment at the top of the source body.
+ *
+ * @private
+ * @param {Function} wrapper The function to modify.
+ * @param {Function} reference The reference function.
+ * @param {number} bitmask The bitmask flags. See `createWrap` for more details.
+ * @returns {Function} Returns `wrapper`.
+ */
+var setWrapToString = !defineProperty ? identity : function(wrapper, reference, bitmask) {
+ var source = (reference + '');
+ return defineProperty(wrapper, 'toString', {
+ 'configurable': true,
+ 'enumerable': false,
+ 'value': constant(insertWrapDetails(source, updateWrapDetails(getWrapDetails(source), bitmask)))
+ });
};
-/***/ }),
-/* 78 */
-/***/ (function(module, exports, __webpack_require__) {
-
-"use strict";
-
+/**
+ * Converts `func` to its source code.
+ *
+ * @private
+ * @param {Function} func The function to process.
+ * @returns {string} Returns the source code.
+ */
+function toSource(func) {
+ if (func != null) {
+ try {
+ return funcToString.call(func);
+ } catch (e) {}
+ try {
+ return (func + '');
+ } catch (e) {}
+ }
+ return '';
+}
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
-exports.getBase16Theme = exports.createStyling = exports.invertTheme = undefined;
+/**
+ * Updates wrapper `details` based on `bitmask` flags.
+ *
+ * @private
+ * @returns {Array} details The details to modify.
+ * @param {number} bitmask The bitmask flags. See `createWrap` for more details.
+ * @returns {Array} Returns `details`.
+ */
+function updateWrapDetails(details, bitmask) {
+ arrayEach(wrapFlags, function(pair) {
+ var value = '_.' + pair[0];
+ if ((bitmask & pair[1]) && !arrayIncludes(details, value)) {
+ details.push(value);
+ }
+ });
+ return details.sort();
+}
-var _typeof2 = __webpack_require__(79);
+/**
+ * Creates a function that accepts arguments of `func` and either invokes
+ * `func` returning its result, if at least `arity` number of arguments have
+ * been provided, or returns a function that accepts the remaining `func`
+ * arguments, and so on. The arity of `func` may be specified if `func.length`
+ * is not sufficient.
+ *
+ * The `_.curry.placeholder` value, which defaults to `_` in monolithic builds,
+ * may be used as a placeholder for provided arguments.
+ *
+ * **Note:** This method doesn't set the "length" property of curried functions.
+ *
+ * @static
+ * @memberOf _
+ * @since 2.0.0
+ * @category Function
+ * @param {Function} func The function to curry.
+ * @param {number} [arity=func.length] The arity of `func`.
+ * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.
+ * @returns {Function} Returns the new curried function.
+ * @example
+ *
+ * var abc = function(a, b, c) {
+ * return [a, b, c];
+ * };
+ *
+ * var curried = _.curry(abc);
+ *
+ * curried(1)(2)(3);
+ * // => [1, 2, 3]
+ *
+ * curried(1, 2)(3);
+ * // => [1, 2, 3]
+ *
+ * curried(1, 2, 3);
+ * // => [1, 2, 3]
+ *
+ * // Curried with placeholders.
+ * curried(1)(_, 3)(2);
+ * // => [1, 2, 3]
+ */
+function curry(func, arity, guard) {
+ arity = guard ? undefined : arity;
+ var result = createWrap(func, CURRY_FLAG, undefined, undefined, undefined, undefined, undefined, arity);
+ result.placeholder = curry.placeholder;
+ return result;
+}
-var _typeof3 = _interopRequireDefault(_typeof2);
+/**
+ * Checks if `value` is classified as a `Function` object.
+ *
+ * @static
+ * @memberOf _
+ * @since 0.1.0
+ * @category Lang
+ * @param {*} value The value to check.
+ * @returns {boolean} Returns `true` if `value` is a function, else `false`.
+ * @example
+ *
+ * _.isFunction(_);
+ * // => true
+ *
+ * _.isFunction(/abc/);
+ * // => false
+ */
+function isFunction(value) {
+ // The use of `Object#toString` avoids issues with the `typeof` operator
+ // in Safari 8-9 which returns 'object' for typed array and other constructors.
+ var tag = isObject(value) ? objectToString.call(value) : '';
+ return tag == funcTag || tag == genTag;
+}
-var _extends2 = __webpack_require__(106);
+/**
+ * Checks if `value` is the
+ * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)
+ * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)
+ *
+ * @static
+ * @memberOf _
+ * @since 0.1.0
+ * @category Lang
+ * @param {*} value The value to check.
+ * @returns {boolean} Returns `true` if `value` is an object, else `false`.
+ * @example
+ *
+ * _.isObject({});
+ * // => true
+ *
+ * _.isObject([1, 2, 3]);
+ * // => true
+ *
+ * _.isObject(_.noop);
+ * // => true
+ *
+ * _.isObject(null);
+ * // => false
+ */
+function isObject(value) {
+ var type = typeof value;
+ return !!value && (type == 'object' || type == 'function');
+}
-var _extends3 = _interopRequireDefault(_extends2);
+/**
+ * Checks if `value` is object-like. A value is object-like if it's not `null`
+ * and has a `typeof` result of "object".
+ *
+ * @static
+ * @memberOf _
+ * @since 4.0.0
+ * @category Lang
+ * @param {*} value The value to check.
+ * @returns {boolean} Returns `true` if `value` is object-like, else `false`.
+ * @example
+ *
+ * _.isObjectLike({});
+ * // => true
+ *
+ * _.isObjectLike([1, 2, 3]);
+ * // => true
+ *
+ * _.isObjectLike(_.noop);
+ * // => false
+ *
+ * _.isObjectLike(null);
+ * // => false
+ */
+function isObjectLike(value) {
+ return !!value && typeof value == 'object';
+}
-var _slicedToArray2 = __webpack_require__(111);
+/**
+ * Checks if `value` is classified as a `Symbol` primitive or object.
+ *
+ * @static
+ * @memberOf _
+ * @since 4.0.0
+ * @category Lang
+ * @param {*} value The value to check.
+ * @returns {boolean} Returns `true` if `value` is a symbol, else `false`.
+ * @example
+ *
+ * _.isSymbol(Symbol.iterator);
+ * // => true
+ *
+ * _.isSymbol('abc');
+ * // => false
+ */
+function isSymbol(value) {
+ return typeof value == 'symbol' ||
+ (isObjectLike(value) && objectToString.call(value) == symbolTag);
+}
-var _slicedToArray3 = _interopRequireDefault(_slicedToArray2);
+/**
+ * Converts `value` to a finite number.
+ *
+ * @static
+ * @memberOf _
+ * @since 4.12.0
+ * @category Lang
+ * @param {*} value The value to convert.
+ * @returns {number} Returns the converted number.
+ * @example
+ *
+ * _.toFinite(3.2);
+ * // => 3.2
+ *
+ * _.toFinite(Number.MIN_VALUE);
+ * // => 5e-324
+ *
+ * _.toFinite(Infinity);
+ * // => 1.7976931348623157e+308
+ *
+ * _.toFinite('3.2');
+ * // => 3.2
+ */
+function toFinite(value) {
+ if (!value) {
+ return value === 0 ? value : 0;
+ }
+ value = toNumber(value);
+ if (value === INFINITY || value === -INFINITY) {
+ var sign = (value < 0 ? -1 : 1);
+ return sign * MAX_INTEGER;
+ }
+ return value === value ? value : 0;
+}
-var _keys = __webpack_require__(119);
+/**
+ * Converts `value` to an integer.
+ *
+ * **Note:** This method is loosely based on
+ * [`ToInteger`](http://www.ecma-international.org/ecma-262/7.0/#sec-tointeger).
+ *
+ * @static
+ * @memberOf _
+ * @since 4.0.0
+ * @category Lang
+ * @param {*} value The value to convert.
+ * @returns {number} Returns the converted integer.
+ * @example
+ *
+ * _.toInteger(3.2);
+ * // => 3
+ *
+ * _.toInteger(Number.MIN_VALUE);
+ * // => 0
+ *
+ * _.toInteger(Infinity);
+ * // => 1.7976931348623157e+308
+ *
+ * _.toInteger('3.2');
+ * // => 3
+ */
+function toInteger(value) {
+ var result = toFinite(value),
+ remainder = result % 1;
-var _keys2 = _interopRequireDefault(_keys);
+ return result === result ? (remainder ? result - remainder : result) : 0;
+}
-var _lodash = __webpack_require__(123);
+/**
+ * Converts `value` to a number.
+ *
+ * @static
+ * @memberOf _
+ * @since 4.0.0
+ * @category Lang
+ * @param {*} value The value to process.
+ * @returns {number} Returns the number.
+ * @example
+ *
+ * _.toNumber(3.2);
+ * // => 3.2
+ *
+ * _.toNumber(Number.MIN_VALUE);
+ * // => 5e-324
+ *
+ * _.toNumber(Infinity);
+ * // => Infinity
+ *
+ * _.toNumber('3.2');
+ * // => 3.2
+ */
+function toNumber(value) {
+ if (typeof value == 'number') {
+ return value;
+ }
+ if (isSymbol(value)) {
+ return NAN;
+ }
+ if (isObject(value)) {
+ var other = typeof value.valueOf == 'function' ? value.valueOf() : value;
+ value = isObject(other) ? (other + '') : other;
+ }
+ if (typeof value != 'string') {
+ return value === 0 ? value : +value;
+ }
+ value = value.replace(reTrim, '');
+ var isBinary = reIsBinary.test(value);
+ return (isBinary || reIsOctal.test(value))
+ ? freeParseInt(value.slice(2), isBinary ? 2 : 8)
+ : (reIsBadHex.test(value) ? NAN : +value);
+}
-var _lodash2 = _interopRequireDefault(_lodash);
+/**
+ * Creates a function that returns `value`.
+ *
+ * @static
+ * @memberOf _
+ * @since 2.4.0
+ * @category Util
+ * @param {*} value The value to return from the new function.
+ * @returns {Function} Returns the new constant function.
+ * @example
+ *
+ * var objects = _.times(2, _.constant({ 'a': 1 }));
+ *
+ * console.log(objects);
+ * // => [{ 'a': 1 }, { 'a': 1 }]
+ *
+ * console.log(objects[0] === objects[1]);
+ * // => true
+ */
+function constant(value) {
+ return function() {
+ return value;
+ };
+}
-var _base = __webpack_require__(124);
+/**
+ * This method returns the first argument it receives.
+ *
+ * @static
+ * @since 0.1.0
+ * @memberOf _
+ * @category Util
+ * @param {*} value Any value.
+ * @returns {*} Returns `value`.
+ * @example
+ *
+ * var object = { 'a': 1 };
+ *
+ * console.log(_.identity(object) === object);
+ * // => true
+ */
+function identity(value) {
+ return value;
+}
-var base16 = _interopRequireWildcard(_base);
+// Assign default placeholders.
+curry.placeholder = {};
-var _rgb2hex = __webpack_require__(162);
+module.exports = curry;
-var _rgb2hex2 = _interopRequireDefault(_rgb2hex);
+/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(48)))
-var _parse = __webpack_require__(163);
+/***/ }),
+/* 103 */
+/***/ (function(module, exports, __webpack_require__) {
-var _parse2 = _interopRequireDefault(_parse);
+"use strict";
-var _lodash3 = __webpack_require__(168);
-var _lodash4 = _interopRequireDefault(_lodash3);
+exports.__esModule = true;
-var _colorConverters = __webpack_require__(169);
+function _interopRequire(obj) { return obj && obj.__esModule ? obj['default'] : obj; }
-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 _threezerotwofour = __webpack_require__(104);
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+exports.threezerotwofour = _interopRequire(_threezerotwofour);
-var DEFAULT_BASE16 = base16.default;
+var _apathy = __webpack_require__(105);
-var BASE16_KEYS = (0, _keys2.default)(DEFAULT_BASE16);
+exports.apathy = _interopRequire(_apathy);
-// we need a correcting factor, so that a dark, but not black background color
-// converts to bright enough inversed color
-var flip = function flip(x) {
- return x < 0.25 ? 1 : x < 0.5 ? 0.9 - x : 1.1 - x;
-};
+var _ashes = __webpack_require__(106);
-var invertColor = (0, _lodash4.default)(_parse2.default, _colorConverters.rgb2yuv, function (_ref) {
- var _ref2 = (0, _slicedToArray3.default)(_ref, 3),
- y = _ref2[0],
- u = _ref2[1],
- v = _ref2[2];
+exports.ashes = _interopRequire(_ashes);
- return [flip(y), u, v];
-}, _colorConverters.yuv2rgb, _rgb2hex2.default);
+var _atelierDune = __webpack_require__(107);
-var merger = function merger(styling) {
- return function (prevStyling) {
- return {
- className: [prevStyling.className, styling.className].filter(Boolean).join(' '),
- style: (0, _extends3.default)({}, prevStyling.style || {}, styling.style || {})
- };
- };
-};
+exports.atelierDune = _interopRequire(_atelierDune);
-var mergeStyling = function mergeStyling(customStyling, defaultStyling) {
- if (customStyling === undefined) {
- return defaultStyling;
- }
- if (defaultStyling === undefined) {
- return customStyling;
- }
+var _atelierForest = __webpack_require__(108);
- var customType = typeof customStyling === 'undefined' ? 'undefined' : (0, _typeof3.default)(customStyling);
- var defaultType = typeof defaultStyling === 'undefined' ? 'undefined' : (0, _typeof3.default)(defaultStyling);
+exports.atelierForest = _interopRequire(_atelierForest);
- switch (customType) {
- case 'string':
- switch (defaultType) {
- case 'string':
- return [defaultStyling, customStyling].filter(Boolean).join(' ');
- case 'object':
- return merger({ className: customStyling, style: defaultStyling });
- case 'function':
- return function (styling) {
- for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
- args[_key - 1] = arguments[_key];
- }
+var _atelierHeath = __webpack_require__(109);
- return merger({
- className: customStyling
- })(defaultStyling.apply(undefined, [styling].concat(args)));
- };
- }
- case 'object':
- switch (defaultType) {
- case 'string':
- return merger({ className: defaultStyling, style: customStyling });
- case 'object':
- return (0, _extends3.default)({}, defaultStyling, customStyling);
- case 'function':
- return function (styling) {
- for (var _len2 = arguments.length, args = Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {
- args[_key2 - 1] = arguments[_key2];
- }
+exports.atelierHeath = _interopRequire(_atelierHeath);
- return merger({
- style: customStyling
- })(defaultStyling.apply(undefined, [styling].concat(args)));
- };
- }
- case 'function':
- switch (defaultType) {
- case 'string':
- return function (styling) {
- for (var _len3 = arguments.length, args = Array(_len3 > 1 ? _len3 - 1 : 0), _key3 = 1; _key3 < _len3; _key3++) {
- args[_key3 - 1] = arguments[_key3];
- }
+var _atelierLakeside = __webpack_require__(110);
- return customStyling.apply(undefined, [merger(styling)({
- className: defaultStyling
- })].concat(args));
- };
- case 'object':
- return function (styling) {
- for (var _len4 = arguments.length, args = Array(_len4 > 1 ? _len4 - 1 : 0), _key4 = 1; _key4 < _len4; _key4++) {
- args[_key4 - 1] = arguments[_key4];
- }
+exports.atelierLakeside = _interopRequire(_atelierLakeside);
- return customStyling.apply(undefined, [merger(styling)({
- style: defaultStyling
- })].concat(args));
- };
- case 'function':
- return function (styling) {
- for (var _len5 = arguments.length, args = Array(_len5 > 1 ? _len5 - 1 : 0), _key5 = 1; _key5 < _len5; _key5++) {
- args[_key5 - 1] = arguments[_key5];
- }
+var _atelierSeaside = __webpack_require__(111);
- return customStyling.apply(undefined, [defaultStyling.apply(undefined, [styling].concat(args))].concat(args));
- };
- }
- }
-};
+exports.atelierSeaside = _interopRequire(_atelierSeaside);
-var mergeStylings = function mergeStylings(customStylings, defaultStylings) {
- var keys = (0, _keys2.default)(defaultStylings);
- for (var key in customStylings) {
- if (keys.indexOf(key) === -1) keys.push(key);
- }
+var _bespin = __webpack_require__(112);
- return keys.reduce(function (mergedStyling, key) {
- return mergedStyling[key] = mergeStyling(customStylings[key], defaultStylings[key]), mergedStyling;
- }, {});
-};
+exports.bespin = _interopRequire(_bespin);
-var getStylingByKeys = function getStylingByKeys(mergedStyling, keys) {
- for (var _len6 = arguments.length, args = Array(_len6 > 2 ? _len6 - 2 : 0), _key6 = 2; _key6 < _len6; _key6++) {
- args[_key6 - 2] = arguments[_key6];
- }
+var _brewer = __webpack_require__(113);
- if (keys === null) {
- return mergedStyling;
- }
+exports.brewer = _interopRequire(_brewer);
- if (!Array.isArray(keys)) {
- keys = [keys];
- }
-
- var styles = keys.map(function (key) {
- return mergedStyling[key];
- }).filter(Boolean);
-
- var props = styles.reduce(function (obj, s) {
- if (typeof s === 'string') {
- obj.className = [obj.className, s].filter(Boolean).join(' ');
- } else if ((typeof s === 'undefined' ? 'undefined' : (0, _typeof3.default)(s)) === 'object') {
- obj.style = (0, _extends3.default)({}, obj.style, s);
- } else if (typeof s === 'function') {
- obj = (0, _extends3.default)({}, obj, s.apply(undefined, [obj].concat(args)));
- }
-
- return obj;
- }, { className: '', style: {} });
-
- if (!props.className) {
- delete props.className;
- }
-
- if ((0, _keys2.default)(props.style).length === 0) {
- delete props.style;
- }
+var _bright = __webpack_require__(114);
- return props;
-};
+exports.bright = _interopRequire(_bright);
-var invertTheme = exports.invertTheme = function invertTheme(theme) {
- return (0, _keys2.default)(theme).reduce(function (t, key) {
- return t[key] = /^base/.test(key) ? invertColor(theme[key]) : key === 'scheme' ? theme[key] + ':inverted' : theme[key], t;
- }, {});
-};
+var _chalk = __webpack_require__(115);
-var createStyling = exports.createStyling = (0, _lodash2.default)(function (getStylingFromBase16) {
- for (var _len7 = arguments.length, args = Array(_len7 > 3 ? _len7 - 3 : 0), _key7 = 3; _key7 < _len7; _key7++) {
- args[_key7 - 3] = arguments[_key7];
- }
+exports.chalk = _interopRequire(_chalk);
- var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
- var themeOrStyling = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
- var _options$defaultBase = options.defaultBase16,
- defaultBase16 = _options$defaultBase === undefined ? DEFAULT_BASE16 : _options$defaultBase,
- _options$base16Themes = options.base16Themes,
- base16Themes = _options$base16Themes === undefined ? null : _options$base16Themes;
+var _codeschool = __webpack_require__(116);
+exports.codeschool = _interopRequire(_codeschool);
- var base16Theme = getBase16Theme(themeOrStyling, base16Themes);
- if (base16Theme) {
- themeOrStyling = (0, _extends3.default)({}, base16Theme, themeOrStyling);
- }
+var _colors = __webpack_require__(117);
- var theme = BASE16_KEYS.reduce(function (t, key) {
- return t[key] = themeOrStyling[key] || defaultBase16[key], t;
- }, {});
+exports.colors = _interopRequire(_colors);
- var customStyling = (0, _keys2.default)(themeOrStyling).reduce(function (s, key) {
- return BASE16_KEYS.indexOf(key) === -1 ? (s[key] = themeOrStyling[key], s) : s;
- }, {});
+var _default = __webpack_require__(118);
- var defaultStyling = getStylingFromBase16(theme);
+exports['default'] = _interopRequire(_default);
- var mergedStyling = mergeStylings(customStyling, defaultStyling);
+var _eighties = __webpack_require__(119);
- return (0, _lodash2.default)(getStylingByKeys, 2).apply(undefined, [mergedStyling].concat(args));
-}, 3);
+exports.eighties = _interopRequire(_eighties);
-var getBase16Theme = exports.getBase16Theme = function getBase16Theme(theme, base16Themes) {
- if (theme && theme.extend) {
- theme = theme.extend;
- }
+var _embers = __webpack_require__(120);
- if (typeof theme === 'string') {
- var _theme$split = theme.split(':'),
- _theme$split2 = (0, _slicedToArray3.default)(_theme$split, 2),
- themeName = _theme$split2[0],
- modifier = _theme$split2[1];
+exports.embers = _interopRequire(_embers);
- theme = (base16Themes || {})[themeName] || base16[themeName];
- if (modifier === 'inverted') {
- theme = invertTheme(theme);
- }
- }
+var _flat = __webpack_require__(121);
- return theme && theme.hasOwnProperty('base00') ? theme : undefined;
-};
+exports.flat = _interopRequire(_flat);
-/***/ }),
-/* 79 */
-/***/ (function(module, exports, __webpack_require__) {
+var _google = __webpack_require__(122);
-"use strict";
+exports.google = _interopRequire(_google);
+var _grayscale = __webpack_require__(123);
-exports.__esModule = true;
+exports.grayscale = _interopRequire(_grayscale);
-var _iterator = __webpack_require__(80);
+var _greenscreen = __webpack_require__(124);
-var _iterator2 = _interopRequireDefault(_iterator);
+exports.greenscreen = _interopRequire(_greenscreen);
-var _symbol = __webpack_require__(95);
+var _harmonic = __webpack_require__(125);
-var _symbol2 = _interopRequireDefault(_symbol);
+exports.harmonic = _interopRequire(_harmonic);
-var _typeof = typeof _symbol2.default === "function" && typeof _iterator2.default === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof _symbol2.default === "function" && obj.constructor === _symbol2.default && obj !== _symbol2.default.prototype ? "symbol" : typeof obj; };
+var _hopscotch = __webpack_require__(126);
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+exports.hopscotch = _interopRequire(_hopscotch);
-exports.default = typeof _symbol2.default === "function" && _typeof(_iterator2.default) === "symbol" ? function (obj) {
- return typeof obj === "undefined" ? "undefined" : _typeof(obj);
-} : function (obj) {
- return obj && typeof _symbol2.default === "function" && obj.constructor === _symbol2.default && obj !== _symbol2.default.prototype ? "symbol" : typeof obj === "undefined" ? "undefined" : _typeof(obj);
-};
+var _isotope = __webpack_require__(127);
-/***/ }),
-/* 80 */
-/***/ (function(module, exports, __webpack_require__) {
+exports.isotope = _interopRequire(_isotope);
-module.exports = { "default": __webpack_require__(81), __esModule: true };
+var _marrakesh = __webpack_require__(128);
-/***/ }),
-/* 81 */
-/***/ (function(module, exports, __webpack_require__) {
+exports.marrakesh = _interopRequire(_marrakesh);
-__webpack_require__(32);
-__webpack_require__(41);
-module.exports = __webpack_require__(42).f('iterator');
+var _mocha = __webpack_require__(129);
+exports.mocha = _interopRequire(_mocha);
-/***/ }),
-/* 82 */
-/***/ (function(module, exports, __webpack_require__) {
+var _monokai = __webpack_require__(130);
-var toInteger = __webpack_require__(33);
-var defined = __webpack_require__(34);
-// true -> String#at
-// false -> String#codePointAt
-module.exports = function (TO_STRING) {
- return function (that, pos) {
- var s = String(defined(that));
- var i = toInteger(pos);
- var l = s.length;
- var a, b;
- if (i < 0 || i >= l) return TO_STRING ? '' : undefined;
- a = s.charCodeAt(i);
- return a < 0xd800 || a > 0xdbff || i + 1 === l || (b = s.charCodeAt(i + 1)) < 0xdc00 || b > 0xdfff
- ? TO_STRING ? s.charAt(i) : a
- : TO_STRING ? s.slice(i, i + 2) : (a - 0xd800 << 10) + (b - 0xdc00) + 0x10000;
- };
-};
+exports.monokai = _interopRequire(_monokai);
+var _ocean = __webpack_require__(131);
-/***/ }),
-/* 83 */
-/***/ (function(module, exports, __webpack_require__) {
+exports.ocean = _interopRequire(_ocean);
-// optional / simple context binding
-var aFunction = __webpack_require__(84);
-module.exports = function (fn, that, length) {
- aFunction(fn);
- if (that === undefined) return fn;
- switch (length) {
- case 1: return function (a) {
- return fn.call(that, a);
- };
- case 2: return function (a, b) {
- return fn.call(that, a, b);
- };
- case 3: return function (a, b, c) {
- return fn.call(that, a, b, c);
- };
- }
- return function (/* ...args */) {
- return fn.apply(that, arguments);
- };
-};
+var _paraiso = __webpack_require__(132);
+exports.paraiso = _interopRequire(_paraiso);
-/***/ }),
-/* 84 */
-/***/ (function(module, exports) {
+var _pop = __webpack_require__(133);
-module.exports = function (it) {
- if (typeof it != 'function') throw TypeError(it + ' is not a function!');
- return it;
-};
+exports.pop = _interopRequire(_pop);
+var _railscasts = __webpack_require__(134);
-/***/ }),
-/* 85 */
-/***/ (function(module, exports, __webpack_require__) {
+exports.railscasts = _interopRequire(_railscasts);
-"use strict";
+var _shapeshifter = __webpack_require__(135);
-var create = __webpack_require__(52);
-var descriptor = __webpack_require__(26);
-var setToStringTag = __webpack_require__(40);
-var IteratorPrototype = {};
+exports.shapeshifter = _interopRequire(_shapeshifter);
-// 25.1.2.1.1 %IteratorPrototype%[@@iterator]()
-__webpack_require__(12)(IteratorPrototype, __webpack_require__(4)('iterator'), function () { return this; });
+var _solarized = __webpack_require__(136);
-module.exports = function (Constructor, NAME, next) {
- Constructor.prototype = create(IteratorPrototype, { next: descriptor(1, next) });
- setToStringTag(Constructor, NAME + ' Iterator');
-};
+exports.solarized = _interopRequire(_solarized);
+var _summerfruit = __webpack_require__(137);
-/***/ }),
-/* 86 */
-/***/ (function(module, exports, __webpack_require__) {
+exports.summerfruit = _interopRequire(_summerfruit);
-var dP = __webpack_require__(13);
-var anObject = __webpack_require__(20);
-var getKeys = __webpack_require__(23);
+var _tomorrow = __webpack_require__(138);
-module.exports = __webpack_require__(10) ? Object.defineProperties : function defineProperties(O, Properties) {
- anObject(O);
- var keys = getKeys(Properties);
- var length = keys.length;
- var i = 0;
- var P;
- while (length > i) dP.f(O, P = keys[i++], Properties[P]);
- return O;
-};
+exports.tomorrow = _interopRequire(_tomorrow);
+var _tube = __webpack_require__(139);
-/***/ }),
-/* 87 */
-/***/ (function(module, exports, __webpack_require__) {
+exports.tube = _interopRequire(_tube);
-// false -> Array#indexOf
-// true -> Array#includes
-var toIObject = __webpack_require__(15);
-var toLength = __webpack_require__(88);
-var toAbsoluteIndex = __webpack_require__(89);
-module.exports = function (IS_INCLUDES) {
- return function ($this, el, fromIndex) {
- var O = toIObject($this);
- var length = toLength(O.length);
- var index = toAbsoluteIndex(fromIndex, length);
- var value;
- // Array#includes uses SameValueZero equality algorithm
- // eslint-disable-next-line no-self-compare
- if (IS_INCLUDES && el != el) while (length > index) {
- value = O[index++];
- // eslint-disable-next-line no-self-compare
- if (value != value) return true;
- // Array#indexOf ignores holes, Array#includes - not
- } else for (;length > index; index++) if (IS_INCLUDES || index in O) {
- if (O[index] === el) return IS_INCLUDES || index || 0;
- } return !IS_INCLUDES && -1;
- };
-};
+var _twilight = __webpack_require__(140);
+exports.twilight = _interopRequire(_twilight);
/***/ }),
-/* 88 */
+/* 104 */
/***/ (function(module, exports, __webpack_require__) {
-// 7.1.15 ToLength
-var toInteger = __webpack_require__(33);
-var min = Math.min;
-module.exports = function (it) {
- return it > 0 ? min(toInteger(it), 0x1fffffffffffff) : 0; // pow(2, 53) - 1 == 9007199254740991
-};
-
+"use strict";
-/***/ }),
-/* 89 */
-/***/ (function(module, exports, __webpack_require__) {
-var toInteger = __webpack_require__(33);
-var max = Math.max;
-var min = Math.min;
-module.exports = function (index, length) {
- index = toInteger(index);
- return index < 0 ? max(index + length, 0) : min(index, length);
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'threezerotwofour',
+ author: 'jan t. sott (http://github.com/idleberg)',
+ base00: '#090300',
+ base01: '#3a3432',
+ base02: '#4a4543',
+ base03: '#5c5855',
+ base04: '#807d7c',
+ base05: '#a5a2a2',
+ base06: '#d6d5d4',
+ base07: '#f7f7f7',
+ base08: '#db2d20',
+ base09: '#e8bbd0',
+ base0A: '#fded02',
+ base0B: '#01a252',
+ base0C: '#b5e4f4',
+ base0D: '#01a0e4',
+ base0E: '#a16a94',
+ base0F: '#cdab53'
};
-
+module.exports = exports['default'];
/***/ }),
-/* 90 */
+/* 105 */
/***/ (function(module, exports, __webpack_require__) {
-var document = __webpack_require__(6).document;
-module.exports = document && document.documentElement;
+"use strict";
-/***/ }),
-/* 91 */
-/***/ (function(module, exports, __webpack_require__) {
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'apathy',
+ author: 'jannik siebert (https://github.com/janniks)',
+ base00: '#031A16',
+ base01: '#0B342D',
+ base02: '#184E45',
+ base03: '#2B685E',
+ base04: '#5F9C92',
+ base05: '#81B5AC',
+ base06: '#A7CEC8',
+ base07: '#D2E7E4',
+ base08: '#3E9688',
+ base09: '#3E7996',
+ base0A: '#3E4C96',
+ base0B: '#883E96',
+ base0C: '#963E4C',
+ base0D: '#96883E',
+ base0E: '#4C963E',
+ base0F: '#3E965B'
+};
+module.exports = exports['default'];
-// 19.1.2.9 / 15.2.3.2 Object.getPrototypeOf(O)
-var has = __webpack_require__(11);
-var toObject = __webpack_require__(28);
-var IE_PROTO = __webpack_require__(37)('IE_PROTO');
-var ObjectProto = Object.prototype;
+/***/ }),
+/* 106 */
+/***/ (function(module, exports, __webpack_require__) {
+
+"use strict";
-module.exports = Object.getPrototypeOf || function (O) {
- O = toObject(O);
- if (has(O, IE_PROTO)) return O[IE_PROTO];
- if (typeof O.constructor == 'function' && O instanceof O.constructor) {
- return O.constructor.prototype;
- } return O instanceof Object ? ObjectProto : null;
-};
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'ashes',
+ author: 'jannik siebert (https://github.com/janniks)',
+ base00: '#1C2023',
+ base01: '#393F45',
+ base02: '#565E65',
+ base03: '#747C84',
+ base04: '#ADB3BA',
+ base05: '#C7CCD1',
+ base06: '#DFE2E5',
+ base07: '#F3F4F5',
+ base08: '#C7AE95',
+ base09: '#C7C795',
+ base0A: '#AEC795',
+ base0B: '#95C7AE',
+ base0C: '#95AEC7',
+ base0D: '#AE95C7',
+ base0E: '#C795AE',
+ base0F: '#C79595'
+};
+module.exports = exports['default'];
/***/ }),
-/* 92 */
+/* 107 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var addToUnscopables = __webpack_require__(93);
-var step = __webpack_require__(94);
-var Iterators = __webpack_require__(22);
-var toIObject = __webpack_require__(15);
-// 22.1.3.4 Array.prototype.entries()
-// 22.1.3.13 Array.prototype.keys()
-// 22.1.3.29 Array.prototype.values()
-// 22.1.3.30 Array.prototype[@@iterator]()
-module.exports = __webpack_require__(48)(Array, 'Array', function (iterated, kind) {
- this._t = toIObject(iterated); // target
- this._i = 0; // next index
- this._k = kind; // kind
-// 22.1.5.2.1 %ArrayIteratorPrototype%.next()
-}, function () {
- var O = this._t;
- var kind = this._k;
- var index = this._i++;
- if (!O || index >= O.length) {
- this._t = undefined;
- return step(1);
- }
- if (kind == 'keys') return step(0, index);
- if (kind == 'values') return step(0, O[index]);
- return step(0, [index, O[index]]);
-}, 'values');
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'atelier dune',
+ author: 'bram de haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/dune)',
+ base00: '#20201d',
+ base01: '#292824',
+ base02: '#6e6b5e',
+ base03: '#7d7a68',
+ base04: '#999580',
+ base05: '#a6a28c',
+ base06: '#e8e4cf',
+ base07: '#fefbec',
+ base08: '#d73737',
+ base09: '#b65611',
+ base0A: '#cfb017',
+ base0B: '#60ac39',
+ base0C: '#1fad83',
+ base0D: '#6684e1',
+ base0E: '#b854d4',
+ base0F: '#d43552'
+};
+module.exports = exports['default'];
-// argumentsList[@@iterator] is %ArrayProto_values% (9.4.4.6, 9.4.4.7)
-Iterators.Arguments = Iterators.Array;
+/***/ }),
+/* 108 */
+/***/ (function(module, exports, __webpack_require__) {
+
+"use strict";
-addToUnscopables('keys');
-addToUnscopables('values');
-addToUnscopables('entries');
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'atelier forest',
+ author: 'bram de haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/forest)',
+ base00: '#1b1918',
+ base01: '#2c2421',
+ base02: '#68615e',
+ base03: '#766e6b',
+ base04: '#9c9491',
+ base05: '#a8a19f',
+ base06: '#e6e2e0',
+ base07: '#f1efee',
+ base08: '#f22c40',
+ base09: '#df5320',
+ base0A: '#d5911a',
+ base0B: '#5ab738',
+ base0C: '#00ad9c',
+ base0D: '#407ee7',
+ base0E: '#6666ea',
+ base0F: '#c33ff3'
+};
+module.exports = exports['default'];
/***/ }),
-/* 93 */
-/***/ (function(module, exports) {
+/* 109 */
+/***/ (function(module, exports, __webpack_require__) {
-module.exports = function () { /* empty */ };
+"use strict";
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'atelier heath',
+ author: 'bram de haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/heath)',
+ base00: '#1b181b',
+ base01: '#292329',
+ base02: '#695d69',
+ base03: '#776977',
+ base04: '#9e8f9e',
+ base05: '#ab9bab',
+ base06: '#d8cad8',
+ base07: '#f7f3f7',
+ base08: '#ca402b',
+ base09: '#a65926',
+ base0A: '#bb8a35',
+ base0B: '#379a37',
+ base0C: '#159393',
+ base0D: '#516aec',
+ base0E: '#7b59c0',
+ base0F: '#cc33cc'
+};
+module.exports = exports['default'];
+
/***/ }),
-/* 94 */
-/***/ (function(module, exports) {
+/* 110 */
+/***/ (function(module, exports, __webpack_require__) {
+
+"use strict";
-module.exports = function (done, value) {
- return { value: value, done: !!done };
-};
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'atelier lakeside',
+ author: 'bram de haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/lakeside/)',
+ base00: '#161b1d',
+ base01: '#1f292e',
+ base02: '#516d7b',
+ base03: '#5a7b8c',
+ base04: '#7195a8',
+ base05: '#7ea2b4',
+ base06: '#c1e4f6',
+ base07: '#ebf8ff',
+ base08: '#d22d72',
+ base09: '#935c25',
+ base0A: '#8a8a0f',
+ base0B: '#568c3b',
+ base0C: '#2d8f6f',
+ base0D: '#257fad',
+ base0E: '#5d5db1',
+ base0F: '#b72dd2'
+};
+module.exports = exports['default'];
/***/ }),
-/* 95 */
+/* 111 */
/***/ (function(module, exports, __webpack_require__) {
-module.exports = { "default": __webpack_require__(96), __esModule: true };
+"use strict";
+
+
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'atelier seaside',
+ author: 'bram de haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/seaside/)',
+ base00: '#131513',
+ base01: '#242924',
+ base02: '#5e6e5e',
+ base03: '#687d68',
+ base04: '#809980',
+ base05: '#8ca68c',
+ base06: '#cfe8cf',
+ base07: '#f0fff0',
+ base08: '#e6193c',
+ base09: '#87711d',
+ base0A: '#c3c322',
+ base0B: '#29a329',
+ base0C: '#1999b3',
+ base0D: '#3d62f5',
+ base0E: '#ad2bee',
+ base0F: '#e619c3'
+};
+module.exports = exports['default'];
/***/ }),
-/* 96 */
+/* 112 */
/***/ (function(module, exports, __webpack_require__) {
-__webpack_require__(97);
-__webpack_require__(103);
-__webpack_require__(104);
-__webpack_require__(105);
-module.exports = __webpack_require__(3).Symbol;
+"use strict";
+
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'bespin',
+ author: 'jan t. sott',
+ base00: '#28211c',
+ base01: '#36312e',
+ base02: '#5e5d5c',
+ base03: '#666666',
+ base04: '#797977',
+ base05: '#8a8986',
+ base06: '#9d9b97',
+ base07: '#baae9e',
+ base08: '#cf6a4c',
+ base09: '#cf7d34',
+ base0A: '#f9ee98',
+ base0B: '#54be0d',
+ base0C: '#afc4db',
+ base0D: '#5ea6ea',
+ base0E: '#9b859d',
+ base0F: '#937121'
+};
+module.exports = exports['default'];
/***/ }),
-/* 97 */
+/* 113 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-// ECMAScript 6 symbols shim
-var global = __webpack_require__(6);
-var has = __webpack_require__(11);
-var DESCRIPTORS = __webpack_require__(10);
-var $export = __webpack_require__(25);
-var redefine = __webpack_require__(51);
-var META = __webpack_require__(98).KEY;
-var $fails = __webpack_require__(14);
-var shared = __webpack_require__(38);
-var setToStringTag = __webpack_require__(40);
-var uid = __webpack_require__(27);
-var wks = __webpack_require__(4);
-var wksExt = __webpack_require__(42);
-var wksDefine = __webpack_require__(43);
-var enumKeys = __webpack_require__(99);
-var isArray = __webpack_require__(100);
-var anObject = __webpack_require__(20);
-var isObject = __webpack_require__(21);
-var toObject = __webpack_require__(28);
-var toIObject = __webpack_require__(15);
-var toPrimitive = __webpack_require__(35);
-var createDesc = __webpack_require__(26);
-var _create = __webpack_require__(52);
-var gOPNExt = __webpack_require__(101);
-var $GOPD = __webpack_require__(102);
-var $GOPS = __webpack_require__(44);
-var $DP = __webpack_require__(13);
-var $keys = __webpack_require__(23);
-var gOPD = $GOPD.f;
-var dP = $DP.f;
-var gOPN = gOPNExt.f;
-var $Symbol = global.Symbol;
-var $JSON = global.JSON;
-var _stringify = $JSON && $JSON.stringify;
-var PROTOTYPE = 'prototype';
-var HIDDEN = wks('_hidden');
-var TO_PRIMITIVE = wks('toPrimitive');
-var isEnum = {}.propertyIsEnumerable;
-var SymbolRegistry = shared('symbol-registry');
-var AllSymbols = shared('symbols');
-var OPSymbols = shared('op-symbols');
-var ObjectProto = Object[PROTOTYPE];
-var USE_NATIVE = typeof $Symbol == 'function' && !!$GOPS.f;
-var QObject = global.QObject;
-// Don't use setters in Qt Script, https://github.com/zloirock/core-js/issues/173
-var setter = !QObject || !QObject[PROTOTYPE] || !QObject[PROTOTYPE].findChild;
-
-// fallback for old Android, https://code.google.com/p/v8/issues/detail?id=687
-var setSymbolDesc = DESCRIPTORS && $fails(function () {
- return _create(dP({}, 'a', {
- get: function () { return dP(this, 'a', { value: 7 }).a; }
- })).a != 7;
-}) ? function (it, key, D) {
- var protoDesc = gOPD(ObjectProto, key);
- if (protoDesc) delete ObjectProto[key];
- dP(it, key, D);
- if (protoDesc && it !== ObjectProto) dP(ObjectProto, key, protoDesc);
-} : dP;
-var wrap = function (tag) {
- var sym = AllSymbols[tag] = _create($Symbol[PROTOTYPE]);
- sym._k = tag;
- return sym;
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'brewer',
+ author: 'timothée poisot (http://github.com/tpoisot)',
+ base00: '#0c0d0e',
+ base01: '#2e2f30',
+ base02: '#515253',
+ base03: '#737475',
+ base04: '#959697',
+ base05: '#b7b8b9',
+ base06: '#dadbdc',
+ base07: '#fcfdfe',
+ base08: '#e31a1c',
+ base09: '#e6550d',
+ base0A: '#dca060',
+ base0B: '#31a354',
+ base0C: '#80b1d3',
+ base0D: '#3182bd',
+ base0E: '#756bb1',
+ base0F: '#b15928'
};
+module.exports = exports['default'];
-var isSymbol = USE_NATIVE && typeof $Symbol.iterator == 'symbol' ? function (it) {
- return typeof it == 'symbol';
-} : function (it) {
- return it instanceof $Symbol;
-};
+/***/ }),
+/* 114 */
+/***/ (function(module, exports, __webpack_require__) {
-var $defineProperty = function defineProperty(it, key, D) {
- if (it === ObjectProto) $defineProperty(OPSymbols, key, D);
- anObject(it);
- key = toPrimitive(key, true);
- anObject(D);
- if (has(AllSymbols, key)) {
- if (!D.enumerable) {
- if (!has(it, HIDDEN)) dP(it, HIDDEN, createDesc(1, {}));
- it[HIDDEN][key] = true;
- } else {
- if (has(it, HIDDEN) && it[HIDDEN][key]) it[HIDDEN][key] = false;
- D = _create(D, { enumerable: createDesc(0, false) });
- } return setSymbolDesc(it, key, D);
- } return dP(it, key, D);
-};
-var $defineProperties = function defineProperties(it, P) {
- anObject(it);
- var keys = enumKeys(P = toIObject(P));
- var i = 0;
- var l = keys.length;
- var key;
- while (l > i) $defineProperty(it, key = keys[i++], P[key]);
- return it;
-};
-var $create = function create(it, P) {
- return P === undefined ? _create(it) : $defineProperties(_create(it), P);
-};
-var $propertyIsEnumerable = function propertyIsEnumerable(key) {
- var E = isEnum.call(this, key = toPrimitive(key, true));
- if (this === ObjectProto && has(AllSymbols, key) && !has(OPSymbols, key)) return false;
- return E || !has(this, key) || !has(AllSymbols, key) || has(this, HIDDEN) && this[HIDDEN][key] ? E : true;
-};
-var $getOwnPropertyDescriptor = function getOwnPropertyDescriptor(it, key) {
- it = toIObject(it);
- key = toPrimitive(key, true);
- if (it === ObjectProto && has(AllSymbols, key) && !has(OPSymbols, key)) return;
- var D = gOPD(it, key);
- if (D && has(AllSymbols, key) && !(has(it, HIDDEN) && it[HIDDEN][key])) D.enumerable = true;
- return D;
-};
-var $getOwnPropertyNames = function getOwnPropertyNames(it) {
- var names = gOPN(toIObject(it));
- var result = [];
- var i = 0;
- var key;
- while (names.length > i) {
- if (!has(AllSymbols, key = names[i++]) && key != HIDDEN && key != META) result.push(key);
- } return result;
-};
-var $getOwnPropertySymbols = function getOwnPropertySymbols(it) {
- var IS_OP = it === ObjectProto;
- var names = gOPN(IS_OP ? OPSymbols : toIObject(it));
- var result = [];
- var i = 0;
- var key;
- while (names.length > i) {
- if (has(AllSymbols, key = names[i++]) && (IS_OP ? has(ObjectProto, key) : true)) result.push(AllSymbols[key]);
- } return result;
-};
+"use strict";
-// 19.4.1.1 Symbol([description])
-if (!USE_NATIVE) {
- $Symbol = function Symbol() {
- if (this instanceof $Symbol) throw TypeError('Symbol is not a constructor!');
- var tag = uid(arguments.length > 0 ? arguments[0] : undefined);
- var $set = function (value) {
- if (this === ObjectProto) $set.call(OPSymbols, value);
- if (has(this, HIDDEN) && has(this[HIDDEN], tag)) this[HIDDEN][tag] = false;
- setSymbolDesc(this, tag, createDesc(1, value));
- };
- if (DESCRIPTORS && setter) setSymbolDesc(ObjectProto, tag, { configurable: true, set: $set });
- return wrap(tag);
- };
- redefine($Symbol[PROTOTYPE], 'toString', function toString() {
- return this._k;
- });
- $GOPD.f = $getOwnPropertyDescriptor;
- $DP.f = $defineProperty;
- __webpack_require__(55).f = gOPNExt.f = $getOwnPropertyNames;
- __webpack_require__(29).f = $propertyIsEnumerable;
- $GOPS.f = $getOwnPropertySymbols;
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'bright',
+ author: 'chris kempson (http://chriskempson.com)',
+ base00: '#000000',
+ base01: '#303030',
+ base02: '#505050',
+ base03: '#b0b0b0',
+ base04: '#d0d0d0',
+ base05: '#e0e0e0',
+ base06: '#f5f5f5',
+ base07: '#ffffff',
+ base08: '#fb0120',
+ base09: '#fc6d24',
+ base0A: '#fda331',
+ base0B: '#a1c659',
+ base0C: '#76c7b7',
+ base0D: '#6fb3d2',
+ base0E: '#d381c3',
+ base0F: '#be643c'
+};
+module.exports = exports['default'];
- if (DESCRIPTORS && !__webpack_require__(24)) {
- redefine(ObjectProto, 'propertyIsEnumerable', $propertyIsEnumerable, true);
- }
+/***/ }),
+/* 115 */
+/***/ (function(module, exports, __webpack_require__) {
- wksExt.f = function (name) {
- return wrap(wks(name));
- };
-}
+"use strict";
-$export($export.G + $export.W + $export.F * !USE_NATIVE, { Symbol: $Symbol });
-for (var es6Symbols = (
- // 19.4.2.2, 19.4.2.3, 19.4.2.4, 19.4.2.6, 19.4.2.8, 19.4.2.9, 19.4.2.10, 19.4.2.11, 19.4.2.12, 19.4.2.13, 19.4.2.14
- 'hasInstance,isConcatSpreadable,iterator,match,replace,search,species,split,toPrimitive,toStringTag,unscopables'
-).split(','), j = 0; es6Symbols.length > j;)wks(es6Symbols[j++]);
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'chalk',
+ author: 'chris kempson (http://chriskempson.com)',
+ base00: '#151515',
+ base01: '#202020',
+ base02: '#303030',
+ base03: '#505050',
+ base04: '#b0b0b0',
+ base05: '#d0d0d0',
+ base06: '#e0e0e0',
+ base07: '#f5f5f5',
+ base08: '#fb9fb1',
+ base09: '#eda987',
+ base0A: '#ddb26f',
+ base0B: '#acc267',
+ base0C: '#12cfc0',
+ base0D: '#6fc2ef',
+ base0E: '#e1a3ee',
+ base0F: '#deaf8f'
+};
+module.exports = exports['default'];
-for (var wellKnownSymbols = $keys(wks.store), k = 0; wellKnownSymbols.length > k;) wksDefine(wellKnownSymbols[k++]);
+/***/ }),
+/* 116 */
+/***/ (function(module, exports, __webpack_require__) {
-$export($export.S + $export.F * !USE_NATIVE, 'Symbol', {
- // 19.4.2.1 Symbol.for(key)
- 'for': function (key) {
- return has(SymbolRegistry, key += '')
- ? SymbolRegistry[key]
- : SymbolRegistry[key] = $Symbol(key);
- },
- // 19.4.2.5 Symbol.keyFor(sym)
- keyFor: function keyFor(sym) {
- if (!isSymbol(sym)) throw TypeError(sym + ' is not a symbol!');
- for (var key in SymbolRegistry) if (SymbolRegistry[key] === sym) return key;
- },
- useSetter: function () { setter = true; },
- useSimple: function () { setter = false; }
-});
+"use strict";
-$export($export.S + $export.F * !USE_NATIVE, 'Object', {
- // 19.1.2.2 Object.create(O [, Properties])
- create: $create,
- // 19.1.2.4 Object.defineProperty(O, P, Attributes)
- defineProperty: $defineProperty,
- // 19.1.2.3 Object.defineProperties(O, Properties)
- defineProperties: $defineProperties,
- // 19.1.2.6 Object.getOwnPropertyDescriptor(O, P)
- getOwnPropertyDescriptor: $getOwnPropertyDescriptor,
- // 19.1.2.7 Object.getOwnPropertyNames(O)
- getOwnPropertyNames: $getOwnPropertyNames,
- // 19.1.2.8 Object.getOwnPropertySymbols(O)
- getOwnPropertySymbols: $getOwnPropertySymbols
-});
-
-// Chrome 38 and 39 `Object.getOwnPropertySymbols` fails on primitives
-// https://bugs.chromium.org/p/v8/issues/detail?id=3443
-var FAILS_ON_PRIMITIVES = $fails(function () { $GOPS.f(1); });
-
-$export($export.S + $export.F * FAILS_ON_PRIMITIVES, 'Object', {
- getOwnPropertySymbols: function getOwnPropertySymbols(it) {
- return $GOPS.f(toObject(it));
- }
-});
-
-// 24.3.2 JSON.stringify(value [, replacer [, space]])
-$JSON && $export($export.S + $export.F * (!USE_NATIVE || $fails(function () {
- var S = $Symbol();
- // MS Edge converts symbol values to JSON as {}
- // WebKit converts symbol values to JSON as null
- // V8 throws on boxed symbols
- return _stringify([S]) != '[null]' || _stringify({ a: S }) != '{}' || _stringify(Object(S)) != '{}';
-})), 'JSON', {
- stringify: function stringify(it) {
- var args = [it];
- var i = 1;
- var replacer, $replacer;
- while (arguments.length > i) args.push(arguments[i++]);
- $replacer = replacer = args[1];
- if (!isObject(replacer) && it === undefined || isSymbol(it)) return; // IE8 returns string on undefined
- if (!isArray(replacer)) replacer = function (key, value) {
- if (typeof $replacer == 'function') value = $replacer.call(this, key, value);
- if (!isSymbol(value)) return value;
- };
- args[1] = replacer;
- return _stringify.apply($JSON, args);
- }
-});
-
-// 19.4.3.4 Symbol.prototype[@@toPrimitive](hint)
-$Symbol[PROTOTYPE][TO_PRIMITIVE] || __webpack_require__(12)($Symbol[PROTOTYPE], TO_PRIMITIVE, $Symbol[PROTOTYPE].valueOf);
-// 19.4.3.5 Symbol.prototype[@@toStringTag]
-setToStringTag($Symbol, 'Symbol');
-// 20.2.1.9 Math[@@toStringTag]
-setToStringTag(Math, 'Math', true);
-// 24.3.3 JSON[@@toStringTag]
-setToStringTag(global.JSON, 'JSON', true);
-
-
-/***/ }),
-/* 98 */
-/***/ (function(module, exports, __webpack_require__) {
-
-var META = __webpack_require__(27)('meta');
-var isObject = __webpack_require__(21);
-var has = __webpack_require__(11);
-var setDesc = __webpack_require__(13).f;
-var id = 0;
-var isExtensible = Object.isExtensible || function () {
- return true;
-};
-var FREEZE = !__webpack_require__(14)(function () {
- return isExtensible(Object.preventExtensions({}));
-});
-var setMeta = function (it) {
- setDesc(it, META, { value: {
- i: 'O' + ++id, // object ID
- w: {} // weak collections IDs
- } });
-};
-var fastKey = function (it, create) {
- // return primitive with prefix
- if (!isObject(it)) return typeof it == 'symbol' ? it : (typeof it == 'string' ? 'S' : 'P') + it;
- if (!has(it, META)) {
- // can't set metadata to uncaught frozen object
- if (!isExtensible(it)) return 'F';
- // not necessary to add metadata
- if (!create) return 'E';
- // add missing metadata
- setMeta(it);
- // return object ID
- } return it[META].i;
-};
-var getWeak = function (it, create) {
- if (!has(it, META)) {
- // can't set metadata to uncaught frozen object
- if (!isExtensible(it)) return true;
- // not necessary to add metadata
- if (!create) return false;
- // add missing metadata
- setMeta(it);
- // return hash weak collections IDs
- } return it[META].w;
-};
-// add metadata on freeze-family methods calling
-var onFreeze = function (it) {
- if (FREEZE && meta.NEED && isExtensible(it) && !has(it, META)) setMeta(it);
- return it;
-};
-var meta = module.exports = {
- KEY: META,
- NEED: false,
- fastKey: fastKey,
- getWeak: getWeak,
- onFreeze: onFreeze
-};
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'codeschool',
+ author: 'brettof86',
+ base00: '#232c31',
+ base01: '#1c3657',
+ base02: '#2a343a',
+ base03: '#3f4944',
+ base04: '#84898c',
+ base05: '#9ea7a6',
+ base06: '#a7cfa3',
+ base07: '#b5d8f6',
+ base08: '#2a5491',
+ base09: '#43820d',
+ base0A: '#a03b1e',
+ base0B: '#237986',
+ base0C: '#b02f30',
+ base0D: '#484d79',
+ base0E: '#c59820',
+ base0F: '#c98344'
+};
+module.exports = exports['default'];
/***/ }),
-/* 99 */
+/* 117 */
/***/ (function(module, exports, __webpack_require__) {
-// all enumerable object keys, includes symbols
-var getKeys = __webpack_require__(23);
-var gOPS = __webpack_require__(44);
-var pIE = __webpack_require__(29);
-module.exports = function (it) {
- var result = getKeys(it);
- var getSymbols = gOPS.f;
- if (getSymbols) {
- var symbols = getSymbols(it);
- var isEnum = pIE.f;
- var i = 0;
- var key;
- while (symbols.length > i) if (isEnum.call(it, key = symbols[i++])) result.push(key);
- } return result;
-};
-
+"use strict";
-/***/ }),
-/* 100 */
-/***/ (function(module, exports, __webpack_require__) {
-// 7.2.2 IsArray(argument)
-var cof = __webpack_require__(36);
-module.exports = Array.isArray || function isArray(arg) {
- return cof(arg) == 'Array';
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'colors',
+ author: 'mrmrs (http://clrs.cc)',
+ base00: '#111111',
+ base01: '#333333',
+ base02: '#555555',
+ base03: '#777777',
+ base04: '#999999',
+ base05: '#bbbbbb',
+ base06: '#dddddd',
+ base07: '#ffffff',
+ base08: '#ff4136',
+ base09: '#ff851b',
+ base0A: '#ffdc00',
+ base0B: '#2ecc40',
+ base0C: '#7fdbff',
+ base0D: '#0074d9',
+ base0E: '#b10dc9',
+ base0F: '#85144b'
};
-
+module.exports = exports['default'];
/***/ }),
-/* 101 */
+/* 118 */
/***/ (function(module, exports, __webpack_require__) {
-// fallback for IE11 buggy Object.getOwnPropertyNames with iframe and window
-var toIObject = __webpack_require__(15);
-var gOPN = __webpack_require__(55).f;
-var toString = {}.toString;
-
-var windowNames = typeof window == 'object' && window && Object.getOwnPropertyNames
- ? Object.getOwnPropertyNames(window) : [];
+"use strict";
-var getWindowNames = function (it) {
- try {
- return gOPN(it);
- } catch (e) {
- return windowNames.slice();
- }
-};
-module.exports.f = function getOwnPropertyNames(it) {
- return windowNames && toString.call(it) == '[object Window]' ? getWindowNames(it) : gOPN(toIObject(it));
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'default',
+ author: 'chris kempson (http://chriskempson.com)',
+ base00: '#181818',
+ base01: '#282828',
+ base02: '#383838',
+ base03: '#585858',
+ base04: '#b8b8b8',
+ base05: '#d8d8d8',
+ base06: '#e8e8e8',
+ base07: '#f8f8f8',
+ base08: '#ab4642',
+ base09: '#dc9656',
+ base0A: '#f7ca88',
+ base0B: '#a1b56c',
+ base0C: '#86c1b9',
+ base0D: '#7cafc2',
+ base0E: '#ba8baf',
+ base0F: '#a16946'
};
-
+module.exports = exports['default'];
/***/ }),
-/* 102 */
+/* 119 */
/***/ (function(module, exports, __webpack_require__) {
-var pIE = __webpack_require__(29);
-var createDesc = __webpack_require__(26);
-var toIObject = __webpack_require__(15);
-var toPrimitive = __webpack_require__(35);
-var has = __webpack_require__(11);
-var IE8_DOM_DEFINE = __webpack_require__(49);
-var gOPD = Object.getOwnPropertyDescriptor;
-
-exports.f = __webpack_require__(10) ? gOPD : function getOwnPropertyDescriptor(O, P) {
- O = toIObject(O);
- P = toPrimitive(P, true);
- if (IE8_DOM_DEFINE) try {
- return gOPD(O, P);
- } catch (e) { /* empty */ }
- if (has(O, P)) return createDesc(!pIE.f.call(O, P), O[P]);
-};
-
-
-/***/ }),
-/* 103 */
-/***/ (function(module, exports) {
+"use strict";
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'eighties',
+ author: 'chris kempson (http://chriskempson.com)',
+ base00: '#2d2d2d',
+ base01: '#393939',
+ base02: '#515151',
+ base03: '#747369',
+ base04: '#a09f93',
+ base05: '#d3d0c8',
+ base06: '#e8e6df',
+ base07: '#f2f0ec',
+ base08: '#f2777a',
+ base09: '#f99157',
+ base0A: '#ffcc66',
+ base0B: '#99cc99',
+ base0C: '#66cccc',
+ base0D: '#6699cc',
+ base0E: '#cc99cc',
+ base0F: '#d27b53'
+};
+module.exports = exports['default'];
/***/ }),
-/* 104 */
+/* 120 */
/***/ (function(module, exports, __webpack_require__) {
-__webpack_require__(43)('asyncIterator');
-
-
-/***/ }),
-/* 105 */
-/***/ (function(module, exports, __webpack_require__) {
+"use strict";
-__webpack_require__(43)('observable');
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'embers',
+ author: 'jannik siebert (https://github.com/janniks)',
+ base00: '#16130F',
+ base01: '#2C2620',
+ base02: '#433B32',
+ base03: '#5A5047',
+ base04: '#8A8075',
+ base05: '#A39A90',
+ base06: '#BEB6AE',
+ base07: '#DBD6D1',
+ base08: '#826D57',
+ base09: '#828257',
+ base0A: '#6D8257',
+ base0B: '#57826D',
+ base0C: '#576D82',
+ base0D: '#6D5782',
+ base0E: '#82576D',
+ base0F: '#825757'
+};
+module.exports = exports['default'];
/***/ }),
-/* 106 */
+/* 121 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
exports.__esModule = true;
-
-var _assign = __webpack_require__(107);
-
-var _assign2 = _interopRequireDefault(_assign);
-
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-exports.default = _assign2.default || 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;
+exports['default'] = {
+ scheme: 'flat',
+ author: 'chris kempson (http://chriskempson.com)',
+ base00: '#2C3E50',
+ base01: '#34495E',
+ base02: '#7F8C8D',
+ base03: '#95A5A6',
+ base04: '#BDC3C7',
+ base05: '#e0e0e0',
+ base06: '#f5f5f5',
+ base07: '#ECF0F1',
+ base08: '#E74C3C',
+ base09: '#E67E22',
+ base0A: '#F1C40F',
+ base0B: '#2ECC71',
+ base0C: '#1ABC9C',
+ base0D: '#3498DB',
+ base0E: '#9B59B6',
+ base0F: '#be643c'
};
+module.exports = exports['default'];
/***/ }),
-/* 107 */
+/* 122 */
/***/ (function(module, exports, __webpack_require__) {
-module.exports = { "default": __webpack_require__(108), __esModule: true };
-
-/***/ }),
-/* 108 */
-/***/ (function(module, exports, __webpack_require__) {
+"use strict";
-__webpack_require__(109);
-module.exports = __webpack_require__(3).Object.assign;
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'google',
+ author: 'seth wright (http://sethawright.com)',
+ base00: '#1d1f21',
+ base01: '#282a2e',
+ base02: '#373b41',
+ base03: '#969896',
+ base04: '#b4b7b4',
+ base05: '#c5c8c6',
+ base06: '#e0e0e0',
+ base07: '#ffffff',
+ base08: '#CC342B',
+ base09: '#F96A38',
+ base0A: '#FBA922',
+ base0B: '#198844',
+ base0C: '#3971ED',
+ base0D: '#3971ED',
+ base0E: '#A36AC7',
+ base0F: '#3971ED'
+};
+module.exports = exports['default'];
/***/ }),
-/* 109 */
+/* 123 */
/***/ (function(module, exports, __webpack_require__) {
-// 19.1.3.1 Object.assign(target, source)
-var $export = __webpack_require__(25);
+"use strict";
-$export($export.S + $export.F, 'Object', { assign: __webpack_require__(110) });
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'grayscale',
+ author: 'alexandre gavioli (https://github.com/alexx2/)',
+ base00: '#101010',
+ base01: '#252525',
+ base02: '#464646',
+ base03: '#525252',
+ base04: '#ababab',
+ base05: '#b9b9b9',
+ base06: '#e3e3e3',
+ base07: '#f7f7f7',
+ base08: '#7c7c7c',
+ base09: '#999999',
+ base0A: '#a0a0a0',
+ base0B: '#8e8e8e',
+ base0C: '#868686',
+ base0D: '#686868',
+ base0E: '#747474',
+ base0F: '#5e5e5e'
+};
+module.exports = exports['default'];
/***/ }),
-/* 110 */
+/* 124 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-// 19.1.2.1 Object.assign(target, source, ...)
-var DESCRIPTORS = __webpack_require__(10);
-var getKeys = __webpack_require__(23);
-var gOPS = __webpack_require__(44);
-var pIE = __webpack_require__(29);
-var toObject = __webpack_require__(28);
-var IObject = __webpack_require__(54);
-var $assign = Object.assign;
-
-// should work with symbols and should have deterministic property order (V8 bug)
-module.exports = !$assign || __webpack_require__(14)(function () {
- var A = {};
- var B = {};
- // eslint-disable-next-line no-undef
- var S = Symbol();
- var K = 'abcdefghijklmnopqrst';
- A[S] = 7;
- K.split('').forEach(function (k) { B[k] = k; });
- return $assign({}, A)[S] != 7 || Object.keys($assign({}, B)).join('') != K;
-}) ? function assign(target, source) { // eslint-disable-line no-unused-vars
- var T = toObject(target);
- var aLen = arguments.length;
- var index = 1;
- var getSymbols = gOPS.f;
- var isEnum = pIE.f;
- while (aLen > index) {
- var S = IObject(arguments[index++]);
- var keys = getSymbols ? getKeys(S).concat(getSymbols(S)) : getKeys(S);
- var length = keys.length;
- var j = 0;
- var key;
- while (length > j) {
- key = keys[j++];
- if (!DESCRIPTORS || isEnum.call(S, key)) T[key] = S[key];
- }
- } return T;
-} : $assign;
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'green screen',
+ author: 'chris kempson (http://chriskempson.com)',
+ base00: '#001100',
+ base01: '#003300',
+ base02: '#005500',
+ base03: '#007700',
+ base04: '#009900',
+ base05: '#00bb00',
+ base06: '#00dd00',
+ base07: '#00ff00',
+ base08: '#007700',
+ base09: '#009900',
+ base0A: '#007700',
+ base0B: '#00bb00',
+ base0C: '#005500',
+ base0D: '#009900',
+ base0E: '#00bb00',
+ base0F: '#005500'
+};
+module.exports = exports['default'];
/***/ }),
-/* 111 */
+/* 125 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
exports.__esModule = true;
+exports['default'] = {
+ scheme: 'harmonic16',
+ author: 'jannik siebert (https://github.com/janniks)',
+ base00: '#0b1c2c',
+ base01: '#223b54',
+ base02: '#405c79',
+ base03: '#627e99',
+ base04: '#aabcce',
+ base05: '#cbd6e2',
+ base06: '#e5ebf1',
+ base07: '#f7f9fb',
+ base08: '#bf8b56',
+ base09: '#bfbf56',
+ base0A: '#8bbf56',
+ base0B: '#56bf8b',
+ base0C: '#568bbf',
+ base0D: '#8b56bf',
+ base0E: '#bf568b',
+ base0F: '#bf5656'
+};
+module.exports = exports['default'];
-var _isIterable2 = __webpack_require__(112);
-
-var _isIterable3 = _interopRequireDefault(_isIterable2);
-
-var _getIterator2 = __webpack_require__(115);
+/***/ }),
+/* 126 */
+/***/ (function(module, exports, __webpack_require__) {
-var _getIterator3 = _interopRequireDefault(_getIterator2);
+"use strict";
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-exports.default = function () {
- function sliceIterator(arr, i) {
- var _arr = [];
- var _n = true;
- var _d = false;
- var _e = undefined;
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'hopscotch',
+ author: 'jan t. sott',
+ base00: '#322931',
+ base01: '#433b42',
+ base02: '#5c545b',
+ base03: '#797379',
+ base04: '#989498',
+ base05: '#b9b5b8',
+ base06: '#d5d3d5',
+ base07: '#ffffff',
+ base08: '#dd464c',
+ base09: '#fd8b19',
+ base0A: '#fdcc59',
+ base0B: '#8fc13e',
+ base0C: '#149b93',
+ base0D: '#1290bf',
+ base0E: '#c85e7c',
+ base0F: '#b33508'
+};
+module.exports = exports['default'];
- try {
- for (var _i = (0, _getIterator3.default)(arr), _s; !(_n = (_s = _i.next()).done); _n = true) {
- _arr.push(_s.value);
+/***/ }),
+/* 127 */
+/***/ (function(module, exports, __webpack_require__) {
- if (i && _arr.length === i) break;
- }
- } catch (err) {
- _d = true;
- _e = err;
- } finally {
- try {
- if (!_n && _i["return"]) _i["return"]();
- } finally {
- if (_d) throw _e;
- }
- }
+"use strict";
- return _arr;
- }
- return function (arr, i) {
- if (Array.isArray(arr)) {
- return arr;
- } else if ((0, _isIterable3.default)(Object(arr))) {
- return sliceIterator(arr, i);
- } else {
- throw new TypeError("Invalid attempt to destructure non-iterable instance");
- }
- };
-}();
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'isotope',
+ author: 'jan t. sott',
+ base00: '#000000',
+ base01: '#404040',
+ base02: '#606060',
+ base03: '#808080',
+ base04: '#c0c0c0',
+ base05: '#d0d0d0',
+ base06: '#e0e0e0',
+ base07: '#ffffff',
+ base08: '#ff0000',
+ base09: '#ff9900',
+ base0A: '#ff0099',
+ base0B: '#33ff00',
+ base0C: '#00ffff',
+ base0D: '#0066ff',
+ base0E: '#cc00ff',
+ base0F: '#3300ff'
+};
+module.exports = exports['default'];
/***/ }),
-/* 112 */
+/* 128 */
/***/ (function(module, exports, __webpack_require__) {
-module.exports = { "default": __webpack_require__(113), __esModule: true };
-
-/***/ }),
-/* 113 */
-/***/ (function(module, exports, __webpack_require__) {
+"use strict";
-__webpack_require__(41);
-__webpack_require__(32);
-module.exports = __webpack_require__(114);
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'marrakesh',
+ author: 'alexandre gavioli (http://github.com/alexx2/)',
+ base00: '#201602',
+ base01: '#302e00',
+ base02: '#5f5b17',
+ base03: '#6c6823',
+ base04: '#86813b',
+ base05: '#948e48',
+ base06: '#ccc37a',
+ base07: '#faf0a5',
+ base08: '#c35359',
+ base09: '#b36144',
+ base0A: '#a88339',
+ base0B: '#18974e',
+ base0C: '#75a738',
+ base0D: '#477ca1',
+ base0E: '#8868b3',
+ base0F: '#b3588e'
+};
+module.exports = exports['default'];
/***/ }),
-/* 114 */
+/* 129 */
/***/ (function(module, exports, __webpack_require__) {
-var classof = __webpack_require__(56);
-var ITERATOR = __webpack_require__(4)('iterator');
-var Iterators = __webpack_require__(22);
-module.exports = __webpack_require__(3).isIterable = function (it) {
- var O = Object(it);
- return O[ITERATOR] !== undefined
- || '@@iterator' in O
- // eslint-disable-next-line no-prototype-builtins
- || Iterators.hasOwnProperty(classof(O));
-};
-
+"use strict";
-/***/ }),
-/* 115 */
-/***/ (function(module, exports, __webpack_require__) {
-module.exports = { "default": __webpack_require__(116), __esModule: true };
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'mocha',
+ author: 'chris kempson (http://chriskempson.com)',
+ base00: '#3B3228',
+ base01: '#534636',
+ base02: '#645240',
+ base03: '#7e705a',
+ base04: '#b8afad',
+ base05: '#d0c8c6',
+ base06: '#e9e1dd',
+ base07: '#f5eeeb',
+ base08: '#cb6077',
+ base09: '#d28b71',
+ base0A: '#f4bc87',
+ base0B: '#beb55b',
+ base0C: '#7bbda4',
+ base0D: '#8ab3b5',
+ base0E: '#a89bb9',
+ base0F: '#bb9584'
+};
+module.exports = exports['default'];
/***/ }),
-/* 116 */
+/* 130 */
/***/ (function(module, exports, __webpack_require__) {
-__webpack_require__(41);
-__webpack_require__(32);
-module.exports = __webpack_require__(117);
-
+"use strict";
-/***/ }),
-/* 117 */
-/***/ (function(module, exports, __webpack_require__) {
-var anObject = __webpack_require__(20);
-var get = __webpack_require__(118);
-module.exports = __webpack_require__(3).getIterator = function (it) {
- var iterFn = get(it);
- if (typeof iterFn != 'function') throw TypeError(it + ' is not iterable!');
- return anObject(iterFn.call(it));
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'monokai',
+ author: 'wimer hazenberg (http://www.monokai.nl)',
+ base00: '#272822',
+ base01: '#383830',
+ base02: '#49483e',
+ base03: '#75715e',
+ base04: '#a59f85',
+ base05: '#f8f8f2',
+ base06: '#f5f4f1',
+ base07: '#f9f8f5',
+ base08: '#f92672',
+ base09: '#fd971f',
+ base0A: '#f4bf75',
+ base0B: '#a6e22e',
+ base0C: '#a1efe4',
+ base0D: '#66d9ef',
+ base0E: '#ae81ff',
+ base0F: '#cc6633'
};
-
+module.exports = exports['default'];
/***/ }),
-/* 118 */
+/* 131 */
/***/ (function(module, exports, __webpack_require__) {
-var classof = __webpack_require__(56);
-var ITERATOR = __webpack_require__(4)('iterator');
-var Iterators = __webpack_require__(22);
-module.exports = __webpack_require__(3).getIteratorMethod = function (it) {
- if (it != undefined) return it[ITERATOR]
- || it['@@iterator']
- || Iterators[classof(it)];
-};
+"use strict";
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'ocean',
+ author: 'chris kempson (http://chriskempson.com)',
+ base00: '#2b303b',
+ base01: '#343d46',
+ base02: '#4f5b66',
+ base03: '#65737e',
+ base04: '#a7adba',
+ base05: '#c0c5ce',
+ base06: '#dfe1e8',
+ base07: '#eff1f5',
+ base08: '#bf616a',
+ base09: '#d08770',
+ base0A: '#ebcb8b',
+ base0B: '#a3be8c',
+ base0C: '#96b5b4',
+ base0D: '#8fa1b3',
+ base0E: '#b48ead',
+ base0F: '#ab7967'
+};
+module.exports = exports['default'];
+
/***/ }),
-/* 119 */
+/* 132 */
/***/ (function(module, exports, __webpack_require__) {
-module.exports = { "default": __webpack_require__(120), __esModule: true };
+"use strict";
+
+
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'paraiso',
+ author: 'jan t. sott',
+ base00: '#2f1e2e',
+ base01: '#41323f',
+ base02: '#4f424c',
+ base03: '#776e71',
+ base04: '#8d8687',
+ base05: '#a39e9b',
+ base06: '#b9b6b0',
+ base07: '#e7e9db',
+ base08: '#ef6155',
+ base09: '#f99b15',
+ base0A: '#fec418',
+ base0B: '#48b685',
+ base0C: '#5bc4bf',
+ base0D: '#06b6ef',
+ base0E: '#815ba4',
+ base0F: '#e96ba8'
+};
+module.exports = exports['default'];
/***/ }),
-/* 120 */
+/* 133 */
/***/ (function(module, exports, __webpack_require__) {
-__webpack_require__(121);
-module.exports = __webpack_require__(3).Object.keys;
+"use strict";
+
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'pop',
+ author: 'chris kempson (http://chriskempson.com)',
+ base00: '#000000',
+ base01: '#202020',
+ base02: '#303030',
+ base03: '#505050',
+ base04: '#b0b0b0',
+ base05: '#d0d0d0',
+ base06: '#e0e0e0',
+ base07: '#ffffff',
+ base08: '#eb008a',
+ base09: '#f29333',
+ base0A: '#f8ca12',
+ base0B: '#37b349',
+ base0C: '#00aabb',
+ base0D: '#0e5a94',
+ base0E: '#b31e8d',
+ base0F: '#7a2d00'
+};
+module.exports = exports['default'];
/***/ }),
-/* 121 */
+/* 134 */
/***/ (function(module, exports, __webpack_require__) {
-// 19.1.2.14 Object.keys(O)
-var toObject = __webpack_require__(28);
-var $keys = __webpack_require__(23);
+"use strict";
-__webpack_require__(122)('keys', function () {
- return function keys(it) {
- return $keys(toObject(it));
- };
-});
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'railscasts',
+ author: 'ryan bates (http://railscasts.com)',
+ base00: '#2b2b2b',
+ base01: '#272935',
+ base02: '#3a4055',
+ base03: '#5a647e',
+ base04: '#d4cfc9',
+ base05: '#e6e1dc',
+ base06: '#f4f1ed',
+ base07: '#f9f7f3',
+ base08: '#da4939',
+ base09: '#cc7833',
+ base0A: '#ffc66d',
+ base0B: '#a5c261',
+ base0C: '#519f50',
+ base0D: '#6d9cbe',
+ base0E: '#b6b3eb',
+ base0F: '#bc9458'
+};
+module.exports = exports['default'];
/***/ }),
-/* 122 */
+/* 135 */
/***/ (function(module, exports, __webpack_require__) {
-// most Object methods by ES6 should accept primitives
-var $export = __webpack_require__(25);
-var core = __webpack_require__(3);
-var fails = __webpack_require__(14);
-module.exports = function (KEY, exec) {
- var fn = (core.Object || {})[KEY] || Object[KEY];
- var exp = {};
- exp[KEY] = exec(fn);
- $export($export.S + $export.F * fails(function () { fn(1); }), 'Object', exp);
-};
+"use strict";
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'shapeshifter',
+ author: 'tyler benziger (http://tybenz.com)',
+ base00: '#000000',
+ base01: '#040404',
+ base02: '#102015',
+ base03: '#343434',
+ base04: '#555555',
+ base05: '#ababab',
+ base06: '#e0e0e0',
+ base07: '#f9f9f9',
+ base08: '#e92f2f',
+ base09: '#e09448',
+ base0A: '#dddd13',
+ base0B: '#0ed839',
+ base0C: '#23edda',
+ base0D: '#3b48e3',
+ base0E: '#f996e2',
+ base0F: '#69542d'
+};
+module.exports = exports['default'];
+
/***/ }),
-/* 123 */
+/* 136 */
/***/ (function(module, exports, __webpack_require__) {
-/* WEBPACK VAR INJECTION */(function(global) {/**
- * lodash (Custom Build)
- * Build: `lodash modularize exports="npm" -o ./`
- * Copyright jQuery Foundation and other contributors
- * Released under MIT license
- * Based on Underscore.js 1.8.3
- * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
- */
-
-/** Used as the `TypeError` message for "Functions" methods. */
-var FUNC_ERROR_TEXT = 'Expected a function';
+"use strict";
-/** Used as the internal argument placeholder. */
-var PLACEHOLDER = '__lodash_placeholder__';
-/** Used to compose bitmasks for function metadata. */
-var BIND_FLAG = 1,
- BIND_KEY_FLAG = 2,
- CURRY_BOUND_FLAG = 4,
- CURRY_FLAG = 8,
- CURRY_RIGHT_FLAG = 16,
- PARTIAL_FLAG = 32,
- PARTIAL_RIGHT_FLAG = 64,
- ARY_FLAG = 128,
- REARG_FLAG = 256,
- FLIP_FLAG = 512;
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'solarized',
+ author: 'ethan schoonover (http://ethanschoonover.com/solarized)',
+ base00: '#002b36',
+ base01: '#073642',
+ base02: '#586e75',
+ base03: '#657b83',
+ base04: '#839496',
+ base05: '#93a1a1',
+ base06: '#eee8d5',
+ base07: '#fdf6e3',
+ base08: '#dc322f',
+ base09: '#cb4b16',
+ base0A: '#b58900',
+ base0B: '#859900',
+ base0C: '#2aa198',
+ base0D: '#268bd2',
+ base0E: '#6c71c4',
+ base0F: '#d33682'
+};
+module.exports = exports['default'];
-/** Used as references for various `Number` constants. */
-var INFINITY = 1 / 0,
- MAX_SAFE_INTEGER = 9007199254740991,
- MAX_INTEGER = 1.7976931348623157e+308,
- NAN = 0 / 0;
+/***/ }),
+/* 137 */
+/***/ (function(module, exports, __webpack_require__) {
-/** Used to associate wrap methods with their bit flags. */
-var wrapFlags = [
- ['ary', ARY_FLAG],
- ['bind', BIND_FLAG],
- ['bindKey', BIND_KEY_FLAG],
- ['curry', CURRY_FLAG],
- ['curryRight', CURRY_RIGHT_FLAG],
- ['flip', FLIP_FLAG],
- ['partial', PARTIAL_FLAG],
- ['partialRight', PARTIAL_RIGHT_FLAG],
- ['rearg', REARG_FLAG]
-];
+"use strict";
-/** `Object#toString` result references. */
-var funcTag = '[object Function]',
- genTag = '[object GeneratorFunction]',
- symbolTag = '[object Symbol]';
-/**
- * Used to match `RegExp`
- * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns).
- */
-var reRegExpChar = /[\\^$.*+?()[\]{}|]/g;
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'summerfruit',
+ author: 'christopher corley (http://cscorley.github.io/)',
+ base00: '#151515',
+ base01: '#202020',
+ base02: '#303030',
+ base03: '#505050',
+ base04: '#B0B0B0',
+ base05: '#D0D0D0',
+ base06: '#E0E0E0',
+ base07: '#FFFFFF',
+ base08: '#FF0086',
+ base09: '#FD8900',
+ base0A: '#ABA800',
+ base0B: '#00C918',
+ base0C: '#1faaaa',
+ base0D: '#3777E6',
+ base0E: '#AD00A1',
+ base0F: '#cc6633'
+};
+module.exports = exports['default'];
-/** Used to match leading and trailing whitespace. */
-var reTrim = /^\s+|\s+$/g;
+/***/ }),
+/* 138 */
+/***/ (function(module, exports, __webpack_require__) {
-/** Used to match wrap detail comments. */
-var reWrapComment = /\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,
- reWrapDetails = /\{\n\/\* \[wrapped with (.+)\] \*/,
- reSplitDetails = /,? & /;
+"use strict";
-/** Used to detect bad signed hexadecimal string values. */
-var reIsBadHex = /^[-+]0x[0-9a-f]+$/i;
-/** Used to detect binary string values. */
-var reIsBinary = /^0b[01]+$/i;
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'tomorrow',
+ author: 'chris kempson (http://chriskempson.com)',
+ base00: '#1d1f21',
+ base01: '#282a2e',
+ base02: '#373b41',
+ base03: '#969896',
+ base04: '#b4b7b4',
+ base05: '#c5c8c6',
+ base06: '#e0e0e0',
+ base07: '#ffffff',
+ base08: '#cc6666',
+ base09: '#de935f',
+ base0A: '#f0c674',
+ base0B: '#b5bd68',
+ base0C: '#8abeb7',
+ base0D: '#81a2be',
+ base0E: '#b294bb',
+ base0F: '#a3685a'
+};
+module.exports = exports['default'];
-/** Used to detect host constructors (Safari). */
-var reIsHostCtor = /^\[object .+?Constructor\]$/;
+/***/ }),
+/* 139 */
+/***/ (function(module, exports, __webpack_require__) {
-/** Used to detect octal string values. */
-var reIsOctal = /^0o[0-7]+$/i;
+"use strict";
-/** Used to detect unsigned integer values. */
-var reIsUint = /^(?:0|[1-9]\d*)$/;
-/** Built-in method references without a dependency on `root`. */
-var freeParseInt = parseInt;
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'london tube',
+ author: 'jan t. sott',
+ base00: '#231f20',
+ base01: '#1c3f95',
+ base02: '#5a5758',
+ base03: '#737171',
+ base04: '#959ca1',
+ base05: '#d9d8d8',
+ base06: '#e7e7e8',
+ base07: '#ffffff',
+ base08: '#ee2e24',
+ base09: '#f386a1',
+ base0A: '#ffd204',
+ base0B: '#00853e',
+ base0C: '#85cebc',
+ base0D: '#009ddc',
+ base0E: '#98005d',
+ base0F: '#b06110'
+};
+module.exports = exports['default'];
-/** Detect free variable `global` from Node.js. */
-var freeGlobal = typeof global == 'object' && global && global.Object === Object && global;
+/***/ }),
+/* 140 */
+/***/ (function(module, exports, __webpack_require__) {
-/** Detect free variable `self`. */
-var freeSelf = typeof self == 'object' && self && self.Object === Object && self;
+"use strict";
-/** Used as a reference to the global object. */
-var root = freeGlobal || freeSelf || Function('return this')();
-/**
- * A faster alternative to `Function#apply`, this function invokes `func`
- * with the `this` binding of `thisArg` and the arguments of `args`.
- *
- * @private
- * @param {Function} func The function to invoke.
- * @param {*} thisArg The `this` binding of `func`.
- * @param {Array} args The arguments to invoke `func` with.
- * @returns {*} Returns the result of `func`.
- */
-function apply(func, thisArg, args) {
- switch (args.length) {
- case 0: return func.call(thisArg);
- case 1: return func.call(thisArg, args[0]);
- case 2: return func.call(thisArg, args[0], args[1]);
- case 3: return func.call(thisArg, args[0], args[1], args[2]);
- }
- return func.apply(thisArg, args);
-}
+exports.__esModule = true;
+exports['default'] = {
+ scheme: 'twilight',
+ author: 'david hart (http://hart-dev.com)',
+ base00: '#1e1e1e',
+ base01: '#323537',
+ base02: '#464b50',
+ base03: '#5f5a60',
+ base04: '#838184',
+ base05: '#a7a7a7',
+ base06: '#c3c3c3',
+ base07: '#ffffff',
+ base08: '#cf6a4c',
+ base09: '#cda869',
+ base0A: '#f9ee98',
+ base0B: '#8f9d6a',
+ base0C: '#afc4db',
+ base0D: '#7587a6',
+ base0E: '#9b859d',
+ base0F: '#9b703f'
+};
+module.exports = exports['default'];
-/**
- * A specialized version of `_.forEach` for arrays without support for
- * iteratee shorthands.
- *
- * @private
- * @param {Array} [array] The array to iterate over.
- * @param {Function} iteratee The function invoked per iteration.
- * @returns {Array} Returns `array`.
- */
-function arrayEach(array, iteratee) {
- var index = -1,
- length = array ? array.length : 0;
+/***/ }),
+/* 141 */
+/***/ (function(module, exports, __webpack_require__) {
- while (++index < length) {
- if (iteratee(array[index], index, array) === false) {
- break;
- }
- }
- return array;
-}
+var clamp = __webpack_require__(38);
-/**
- * A specialized version of `_.includes` for arrays without support for
- * specifying an index to search from.
- *
- * @private
- * @param {Array} [array] The array to inspect.
- * @param {*} target The value to search for.
- * @returns {boolean} Returns `true` if `target` is found, else `false`.
- */
-function arrayIncludes(array, value) {
- var length = array ? array.length : 0;
- return !!length && baseIndexOf(array, value, 0) > -1;
+function componentToHex(c) {
+ var value = Math.round(clamp(c, 0, 255));
+ var hex = value.toString(16);
+
+ return hex.length == 1 ? "0" + hex : hex;
}
-/**
- * The base implementation of `_.findIndex` and `_.findLastIndex` without
- * support for iteratee shorthands.
- *
- * @private
- * @param {Array} array The array to inspect.
- * @param {Function} predicate The function invoked per iteration.
- * @param {number} fromIndex The index to search from.
- * @param {boolean} [fromRight] Specify iterating from right to left.
- * @returns {number} Returns the index of the matched value, else `-1`.
- */
-function baseFindIndex(array, predicate, fromIndex, fromRight) {
- var length = array.length,
- index = fromIndex + (fromRight ? 1 : -1);
+function rgb2hex(rgb) {
+ var alpha = rgb.length === 4 ? componentToHex(rgb[3] * 255) : "";
- while ((fromRight ? index-- : ++index < length)) {
- if (predicate(array[index], index, array)) {
- return index;
- }
- }
- return -1;
+ return "#" + componentToHex(rgb[0]) + componentToHex(rgb[1]) + componentToHex(rgb[2]) + alpha;
}
-/**
- * The base implementation of `_.indexOf` without `fromIndex` bounds checks.
- *
- * @private
- * @param {Array} array The array to inspect.
- * @param {*} value The value to search for.
- * @param {number} fromIndex The index to search from.
- * @returns {number} Returns the index of the matched value, else `-1`.
- */
-function baseIndexOf(array, value, fromIndex) {
- if (value !== value) {
- return baseFindIndex(array, baseIsNaN, fromIndex);
+module.exports = rgb2hex;
+
+/***/ }),
+/* 142 */
+/***/ (function(module, exports, __webpack_require__) {
+
+var hsl = __webpack_require__(143);
+var hex = __webpack_require__(144);
+var rgb = __webpack_require__(145);
+var hsl2rgb = __webpack_require__(146);
+
+function hsl2rgbParse(color) {
+ var h = hsl(color);
+ var r = hsl2rgb(h);
+
+ // handle alpha since hsl2rgb doesn't know (or care!) about it
+ if(h.length === 4) {
+ r.push(h[3]);
}
- var index = fromIndex - 1,
- length = array.length;
- while (++index < length) {
- if (array[index] === value) {
- return index;
+ return r;
+}
+
+var space2parser = {
+ "#" : hex,
+ "hsl" : hsl2rgbParse,
+ "rgb" : rgb
+};
+
+function parse(color) {
+ for(var scheme in space2parser) {
+ if(color.indexOf(scheme) === 0) {
+ return space2parser[scheme](color);
}
}
- return -1;
}
-/**
- * The base implementation of `_.isNaN` without support for number objects.
- *
- * @private
- * @param {*} value The value to check.
- * @returns {boolean} Returns `true` if `value` is `NaN`, else `false`.
- */
-function baseIsNaN(value) {
- return value !== value;
-}
+parse.rgb = rgb;
+parse.hsl = hsl;
+parse.hex = hex;
-/**
- * Gets the number of `placeholder` occurrences in `array`.
- *
- * @private
- * @param {Array} array The array to inspect.
- * @param {*} placeholder The placeholder to search for.
- * @returns {number} Returns the placeholder count.
- */
-function countHolders(array, placeholder) {
- var length = array.length,
- result = 0;
+module.exports = parse;
- while (length--) {
- if (array[length] === placeholder) {
- result++;
- }
+/***/ }),
+/* 143 */
+/***/ (function(module, exports, __webpack_require__) {
+
+var extractComponents = __webpack_require__(49);
+var clamp = __webpack_require__(38);
+
+function parseHslComponent(component, i) {
+ component = parseFloat(component);
+
+ switch(i) {
+ case 0:
+ return clamp(component, 0, 360);
+ case 1:
+ case 2:
+ return clamp(component, 0, 100);
+ case 3:
+ return clamp(component, 0, 1);
}
- return result;
}
-/**
- * Gets the value at `key` of `object`.
- *
- * @private
- * @param {Object} [object] The object to query.
- * @param {string} key The key of the property to get.
- * @returns {*} Returns the property value.
- */
-function getValue(object, key) {
- return object == null ? undefined : object[key];
+function hsl(color) {
+ return extractComponents(color).map(parseHslComponent);
}
-/**
- * Checks if `value` is a host object in IE < 9.
- *
- * @private
- * @param {*} value The value to check.
- * @returns {boolean} Returns `true` if `value` is a host object, else `false`.
- */
-function isHostObject(value) {
- // Many host objects are `Object` objects that can coerce to strings
- // despite having improperly defined `toString` methods.
- var result = false;
- if (value != null && typeof value.toString != 'function') {
- try {
- result = !!(value + '');
- } catch (e) {}
+module.exports = hsl;
+
+/***/ }),
+/* 144 */
+/***/ (function(module, exports) {
+
+function expand(hex) {
+ var result = "#";
+
+ for (var i = 1; i < hex.length; i++) {
+ var val = hex.charAt(i);
+ result += val + val;
}
+
return result;
}
-/**
- * Replaces all `placeholder` elements in `array` with an internal placeholder
- * and returns an array of their indexes.
- *
- * @private
- * @param {Array} array The array to modify.
- * @param {*} placeholder The placeholder to replace.
- * @returns {Array} Returns the new array of placeholder indexes.
- */
-function replaceHolders(array, placeholder) {
- var index = -1,
- length = array.length,
- resIndex = 0,
- result = [];
+function hex(hex) {
+ // #RGB or #RGBA
+ if(hex.length === 4 || hex.length === 5) {
+ hex = expand(hex);
+ }
- while (++index < length) {
- var value = array[index];
- if (value === placeholder || value === PLACEHOLDER) {
- array[index] = PLACEHOLDER;
- result[resIndex++] = index;
- }
+ var rgb = [
+ parseInt(hex.substring(1,3), 16),
+ parseInt(hex.substring(3,5), 16),
+ parseInt(hex.substring(5,7), 16)
+ ];
+
+ // #RRGGBBAA
+ if (hex.length === 9) {
+ var alpha = parseFloat((parseInt(hex.substring(7,9), 16) / 255).toFixed(2));
+ rgb.push(alpha);
}
- return result;
+
+ return rgb;
}
-/** Used for built-in method references. */
-var funcProto = Function.prototype,
- objectProto = Object.prototype;
+module.exports = hex;
-/** Used to detect overreaching core-js shims. */
-var coreJsData = root['__core-js_shared__'];
+/***/ }),
+/* 145 */
+/***/ (function(module, exports, __webpack_require__) {
-/** Used to detect methods masquerading as native. */
-var maskSrcKey = (function() {
- var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || '');
- return uid ? ('Symbol(src)_1.' + uid) : '';
-}());
+var extractComponents = __webpack_require__(49);
+var clamp = __webpack_require__(38);
-/** Used to resolve the decompiled source of functions. */
-var funcToString = funcProto.toString;
+function parseRgbComponent(component, i) {
+ if (i < 3) {
+ if (component.indexOf('%') != -1) {
+ return Math.round(255 * clamp(parseInt(component, 10), 0, 100)/100);
+ } else {
+ return clamp(parseInt(component, 10), 0, 255);
+ }
+ } else {
+ return clamp(parseFloat(component), 0, 1);
+ }
+}
-/** Used to check objects for own properties. */
-var hasOwnProperty = objectProto.hasOwnProperty;
+function rgb(color) {
+ return extractComponents(color).map(parseRgbComponent);
+}
-/**
- * Used to resolve the
- * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)
- * of values.
- */
-var objectToString = objectProto.toString;
+module.exports = rgb;
-/** Used to detect if a method is native. */
-var reIsNative = RegExp('^' +
- funcToString.call(hasOwnProperty).replace(reRegExpChar, '\\$&')
- .replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$'
-);
+/***/ }),
+/* 146 */
+/***/ (function(module, exports) {
-/** Built-in value references. */
-var objectCreate = Object.create;
+function hsl2rgb(hsl) {
+ var h = hsl[0] / 360,
+ s = hsl[1] / 100,
+ l = hsl[2] / 100,
+ t1, t2, t3, rgb, val;
-/* Built-in method references for those with the same name as other `lodash` methods. */
-var nativeMax = Math.max,
- nativeMin = Math.min;
+ if (s == 0) {
+ val = l * 255;
+ return [val, val, val];
+ }
-/* Used to set `toString` methods. */
-var defineProperty = (function() {
- var func = getNative(Object, 'defineProperty'),
- name = getNative.name;
+ if (l < 0.5)
+ t2 = l * (1 + s);
+ else
+ t2 = l + s - l * s;
+ t1 = 2 * l - t2;
- return (name && name.length > 2) ? func : undefined;
-}());
+ rgb = [0, 0, 0];
+ for (var i = 0; i < 3; i++) {
+ t3 = h + 1 / 3 * - (i - 1);
+ t3 < 0 && t3++;
+ t3 > 1 && t3--;
-/**
- * The base implementation of `_.create` without support for assigning
- * properties to the created object.
- *
- * @private
- * @param {Object} prototype The object to inherit from.
- * @returns {Object} Returns the new object.
- */
-function baseCreate(proto) {
- return isObject(proto) ? objectCreate(proto) : {};
+ if (6 * t3 < 1)
+ val = t1 + (t2 - t1) * 6 * t3;
+ else if (2 * t3 < 1)
+ val = t2;
+ else if (3 * t3 < 2)
+ val = t1 + (t2 - t1) * (2 / 3 - t3) * 6;
+ else
+ val = t1;
+
+ rgb[i] = val * 255;
+ }
+
+ return rgb;
}
+module.exports = hsl2rgb;
+
+/***/ }),
+/* 147 */
+/***/ (function(module, exports, __webpack_require__) {
+
+/* WEBPACK VAR INJECTION */(function(global) {/**
+ * lodash (Custom Build)
+ * Build: `lodash modularize exports="npm" -o ./`
+ * Copyright jQuery Foundation and other contributors
+ * Released under MIT license
+ * Based on Underscore.js 1.8.3
+ * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
+ */
+
+/** Used as the `TypeError` message for "Functions" methods. */
+var FUNC_ERROR_TEXT = 'Expected a function';
+
+/** Used as references for various `Number` constants. */
+var MAX_SAFE_INTEGER = 9007199254740991;
+
+/** `Object#toString` result references. */
+var argsTag = '[object Arguments]',
+ funcTag = '[object Function]',
+ genTag = '[object GeneratorFunction]';
+
+/** Detect free variable `global` from Node.js. */
+var freeGlobal = typeof global == 'object' && global && global.Object === Object && global;
+
+/** Detect free variable `self`. */
+var freeSelf = typeof self == 'object' && self && self.Object === Object && self;
+
+/** Used as a reference to the global object. */
+var root = freeGlobal || freeSelf || Function('return this')();
+
/**
- * The base implementation of `_.isNative` without bad shim checks.
+ * A faster alternative to `Function#apply`, this function invokes `func`
+ * with the `this` binding of `thisArg` and the arguments of `args`.
*
* @private
- * @param {*} value The value to check.
- * @returns {boolean} Returns `true` if `value` is a native function,
- * else `false`.
+ * @param {Function} func The function to invoke.
+ * @param {*} thisArg The `this` binding of `func`.
+ * @param {Array} args The arguments to invoke `func` with.
+ * @returns {*} Returns the result of `func`.
*/
-function baseIsNative(value) {
- if (!isObject(value) || isMasked(value)) {
- return false;
+function apply(func, thisArg, args) {
+ switch (args.length) {
+ case 0: return func.call(thisArg);
+ case 1: return func.call(thisArg, args[0]);
+ case 2: return func.call(thisArg, args[0], args[1]);
+ case 3: return func.call(thisArg, args[0], args[1], args[2]);
}
- var pattern = (isFunction(value) || isHostObject(value)) ? reIsNative : reIsHostCtor;
- return pattern.test(toSource(value));
+ return func.apply(thisArg, args);
}
/**
- * Creates an array that is the composition of partially applied arguments,
- * placeholders, and provided arguments into a single array of arguments.
+ * Appends the elements of `values` to `array`.
*
* @private
- * @param {Array} args The provided arguments.
- * @param {Array} partials The arguments to prepend to those provided.
- * @param {Array} holders The `partials` placeholder indexes.
- * @params {boolean} [isCurried] Specify composing for a curried function.
- * @returns {Array} Returns the new array of composed arguments.
+ * @param {Array} array The array to modify.
+ * @param {Array} values The values to append.
+ * @returns {Array} Returns `array`.
*/
-function composeArgs(args, partials, holders, isCurried) {
- var argsIndex = -1,
- argsLength = args.length,
- holdersLength = holders.length,
- leftIndex = -1,
- leftLength = partials.length,
- rangeLength = nativeMax(argsLength - holdersLength, 0),
- result = Array(leftLength + rangeLength),
- isUncurried = !isCurried;
+function arrayPush(array, values) {
+ var index = -1,
+ length = values.length,
+ offset = array.length;
- while (++leftIndex < leftLength) {
- result[leftIndex] = partials[leftIndex];
- }
- while (++argsIndex < holdersLength) {
- if (isUncurried || argsIndex < argsLength) {
- result[holders[argsIndex]] = args[argsIndex];
- }
- }
- while (rangeLength--) {
- result[leftIndex++] = args[argsIndex++];
+ while (++index < length) {
+ array[offset + index] = values[index];
}
- return result;
+ return array;
}
+/** Used for built-in method references. */
+var objectProto = Object.prototype;
+
+/** Used to check objects for own properties. */
+var hasOwnProperty = objectProto.hasOwnProperty;
+
/**
- * This function is like `composeArgs` except that the arguments composition
- * is tailored for `_.partialRight`.
- *
- * @private
- * @param {Array} args The provided arguments.
- * @param {Array} partials The arguments to append to those provided.
- * @param {Array} holders The `partials` placeholder indexes.
- * @params {boolean} [isCurried] Specify composing for a curried function.
- * @returns {Array} Returns the new array of composed arguments.
+ * Used to resolve the
+ * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)
+ * of values.
*/
-function composeArgsRight(args, partials, holders, isCurried) {
- var argsIndex = -1,
- argsLength = args.length,
- holdersIndex = -1,
- holdersLength = holders.length,
- rightIndex = -1,
- rightLength = partials.length,
- rangeLength = nativeMax(argsLength - holdersLength, 0),
- result = Array(rangeLength + rightLength),
- isUncurried = !isCurried;
+var objectToString = objectProto.toString;
- while (++argsIndex < rangeLength) {
- result[argsIndex] = args[argsIndex];
- }
- var offset = argsIndex;
- while (++rightIndex < rightLength) {
- result[offset + rightIndex] = partials[rightIndex];
- }
- while (++holdersIndex < holdersLength) {
- if (isUncurried || argsIndex < argsLength) {
- result[offset + holders[holdersIndex]] = args[argsIndex++];
- }
- }
- return result;
-}
+/** Built-in value references. */
+var Symbol = root.Symbol,
+ propertyIsEnumerable = objectProto.propertyIsEnumerable,
+ spreadableSymbol = Symbol ? Symbol.isConcatSpreadable : undefined;
+
+/* Built-in method references for those with the same name as other `lodash` methods. */
+var nativeMax = Math.max;
/**
- * Copies the values of `source` to `array`.
+ * The base implementation of `_.flatten` with support for restricting flattening.
*
* @private
- * @param {Array} source The array to copy values from.
- * @param {Array} [array=[]] The array to copy values to.
- * @returns {Array} Returns `array`.
+ * @param {Array} array The array to flatten.
+ * @param {number} depth The maximum recursion depth.
+ * @param {boolean} [predicate=isFlattenable] The function invoked per iteration.
+ * @param {boolean} [isStrict] Restrict to values that pass `predicate` checks.
+ * @param {Array} [result=[]] The initial result value.
+ * @returns {Array} Returns the new flattened array.
*/
-function copyArray(source, array) {
+function baseFlatten(array, depth, predicate, isStrict, result) {
var index = -1,
- length = source.length;
+ length = array.length;
+
+ predicate || (predicate = isFlattenable);
+ result || (result = []);
- array || (array = Array(length));
while (++index < length) {
- array[index] = source[index];
+ var value = array[index];
+ if (depth > 0 && predicate(value)) {
+ if (depth > 1) {
+ // Recursively flatten arrays (susceptible to call stack limits).
+ baseFlatten(value, depth - 1, predicate, isStrict, result);
+ } else {
+ arrayPush(result, value);
+ }
+ } else if (!isStrict) {
+ result[result.length] = value;
+ }
}
- return array;
+ return result;
}
/**
- * Creates a function that wraps `func` to invoke it with the optional `this`
- * binding of `thisArg`.
+ * The base implementation of `_.rest` which doesn't validate or coerce arguments.
*
* @private
- * @param {Function} func The function to wrap.
- * @param {number} bitmask The bitmask flags. See `createWrap` for more details.
- * @param {*} [thisArg] The `this` binding of `func`.
- * @returns {Function} Returns the new wrapped function.
+ * @param {Function} func The function to apply a rest parameter to.
+ * @param {number} [start=func.length-1] The start position of the rest parameter.
+ * @returns {Function} Returns the new function.
*/
-function createBind(func, bitmask, thisArg) {
- var isBind = bitmask & BIND_FLAG,
- Ctor = createCtor(func);
+function baseRest(func, start) {
+ start = nativeMax(start === undefined ? (func.length - 1) : start, 0);
+ return function() {
+ var args = arguments,
+ index = -1,
+ length = nativeMax(args.length - start, 0),
+ array = Array(length);
- function wrapper() {
- var fn = (this && this !== root && this instanceof wrapper) ? Ctor : func;
- return fn.apply(isBind ? thisArg : this, arguments);
- }
- return wrapper;
+ while (++index < length) {
+ array[index] = args[start + index];
+ }
+ index = -1;
+ var otherArgs = Array(start + 1);
+ while (++index < start) {
+ otherArgs[index] = args[index];
+ }
+ otherArgs[start] = array;
+ return apply(func, this, otherArgs);
+ };
}
/**
- * Creates a function that produces an instance of `Ctor` regardless of
- * whether it was invoked as part of a `new` expression or by `call` or `apply`.
+ * Creates a `_.flow` or `_.flowRight` function.
*
* @private
- * @param {Function} Ctor The constructor to wrap.
- * @returns {Function} Returns the new wrapped function.
+ * @param {boolean} [fromRight] Specify iterating from right to left.
+ * @returns {Function} Returns the new flow function.
*/
-function createCtor(Ctor) {
- return function() {
- // Use a `switch` statement to work with class constructors. See
- // http://ecma-international.org/ecma-262/7.0/#sec-ecmascript-function-objects-call-thisargument-argumentslist
- // for more details.
- var args = arguments;
- switch (args.length) {
- case 0: return new Ctor;
- case 1: return new Ctor(args[0]);
- case 2: return new Ctor(args[0], args[1]);
- case 3: return new Ctor(args[0], args[1], args[2]);
- case 4: return new Ctor(args[0], args[1], args[2], args[3]);
- case 5: return new Ctor(args[0], args[1], args[2], args[3], args[4]);
- case 6: return new Ctor(args[0], args[1], args[2], args[3], args[4], args[5]);
- case 7: return new Ctor(args[0], args[1], args[2], args[3], args[4], args[5], args[6]);
- }
- var thisBinding = baseCreate(Ctor.prototype),
- result = Ctor.apply(thisBinding, args);
-
- // Mimic the constructor's `return` behavior.
- // See https://es5.github.io/#x13.2.2 for more details.
- return isObject(result) ? result : thisBinding;
- };
-}
-
-/**
- * Creates a function that wraps `func` to enable currying.
- *
- * @private
- * @param {Function} func The function to wrap.
- * @param {number} bitmask The bitmask flags. See `createWrap` for more details.
- * @param {number} arity The arity of `func`.
- * @returns {Function} Returns the new wrapped function.
- */
-function createCurry(func, bitmask, arity) {
- var Ctor = createCtor(func);
+function createFlow(fromRight) {
+ return baseRest(function(funcs) {
+ funcs = baseFlatten(funcs, 1);
- function wrapper() {
- var length = arguments.length,
- args = Array(length),
- index = length,
- placeholder = getHolder(wrapper);
+ var length = funcs.length,
+ index = length;
+ if (fromRight) {
+ funcs.reverse();
+ }
while (index--) {
- args[index] = arguments[index];
+ if (typeof funcs[index] != 'function') {
+ throw new TypeError(FUNC_ERROR_TEXT);
+ }
}
- var holders = (length < 3 && args[0] !== placeholder && args[length - 1] !== placeholder)
- ? []
- : replaceHolders(args, placeholder);
+ return function() {
+ var index = 0,
+ result = length ? funcs[index].apply(this, arguments) : arguments[0];
- length -= holders.length;
- if (length < arity) {
- return createRecurry(
- func, bitmask, createHybrid, wrapper.placeholder, undefined,
- args, holders, undefined, undefined, arity - length);
- }
- var fn = (this && this !== root && this instanceof wrapper) ? Ctor : func;
- return apply(fn, this, args);
- }
- return wrapper;
+ while (++index < length) {
+ result = funcs[index].call(this, result);
+ }
+ return result;
+ };
+ });
}
/**
- * Creates a function that wraps `func` to invoke it with optional `this`
- * binding of `thisArg`, partial application, and currying.
+ * Checks if `value` is a flattenable `arguments` object or array.
*
* @private
- * @param {Function|string} func The function or method name to wrap.
- * @param {number} bitmask The bitmask flags. See `createWrap` for more details.
- * @param {*} [thisArg] The `this` binding of `func`.
- * @param {Array} [partials] The arguments to prepend to those provided to
- * the new function.
- * @param {Array} [holders] The `partials` placeholder indexes.
- * @param {Array} [partialsRight] The arguments to append to those provided
- * to the new function.
- * @param {Array} [holdersRight] The `partialsRight` placeholder indexes.
- * @param {Array} [argPos] The argument positions of the new function.
- * @param {number} [ary] The arity cap of `func`.
- * @param {number} [arity] The arity of `func`.
- * @returns {Function} Returns the new wrapped function.
+ * @param {*} value The value to check.
+ * @returns {boolean} Returns `true` if `value` is flattenable, else `false`.
*/
-function createHybrid(func, bitmask, thisArg, partials, holders, partialsRight, holdersRight, argPos, ary, arity) {
- var isAry = bitmask & ARY_FLAG,
- isBind = bitmask & BIND_FLAG,
- isBindKey = bitmask & BIND_KEY_FLAG,
- isCurried = bitmask & (CURRY_FLAG | CURRY_RIGHT_FLAG),
- isFlip = bitmask & FLIP_FLAG,
- Ctor = isBindKey ? undefined : createCtor(func);
-
- function wrapper() {
- var length = arguments.length,
- args = Array(length),
- index = length;
-
- while (index--) {
- args[index] = arguments[index];
- }
- if (isCurried) {
- var placeholder = getHolder(wrapper),
- holdersCount = countHolders(args, placeholder);
- }
- if (partials) {
- args = composeArgs(args, partials, holders, isCurried);
- }
- if (partialsRight) {
- args = composeArgsRight(args, partialsRight, holdersRight, isCurried);
- }
- length -= holdersCount;
- if (isCurried && length < arity) {
- var newHolders = replaceHolders(args, placeholder);
- return createRecurry(
- func, bitmask, createHybrid, wrapper.placeholder, thisArg,
- args, newHolders, argPos, ary, arity - length
- );
- }
- var thisBinding = isBind ? thisArg : this,
- fn = isBindKey ? thisBinding[func] : func;
-
- length = args.length;
- if (argPos) {
- args = reorder(args, argPos);
- } else if (isFlip && length > 1) {
- args.reverse();
- }
- if (isAry && ary < length) {
- args.length = ary;
- }
- if (this && this !== root && this instanceof wrapper) {
- fn = Ctor || createCtor(fn);
- }
- return fn.apply(thisBinding, args);
- }
- return wrapper;
+function isFlattenable(value) {
+ return isArray(value) || isArguments(value) ||
+ !!(spreadableSymbol && value && value[spreadableSymbol]);
}
/**
- * Creates a function that wraps `func` to invoke it with the `this` binding
- * of `thisArg` and `partials` prepended to the arguments it receives.
+ * Checks if `value` is likely an `arguments` object.
*
- * @private
- * @param {Function} func The function to wrap.
- * @param {number} bitmask The bitmask flags. See `createWrap` for more details.
- * @param {*} thisArg The `this` binding of `func`.
- * @param {Array} partials The arguments to prepend to those provided to
- * the new function.
- * @returns {Function} Returns the new wrapped function.
+ * @static
+ * @memberOf _
+ * @since 0.1.0
+ * @category Lang
+ * @param {*} value The value to check.
+ * @returns {boolean} Returns `true` if `value` is an `arguments` object,
+ * else `false`.
+ * @example
+ *
+ * _.isArguments(function() { return arguments; }());
+ * // => true
+ *
+ * _.isArguments([1, 2, 3]);
+ * // => false
*/
-function createPartial(func, bitmask, thisArg, partials) {
- var isBind = bitmask & BIND_FLAG,
- Ctor = createCtor(func);
-
- function wrapper() {
- var argsIndex = -1,
- argsLength = arguments.length,
- leftIndex = -1,
- leftLength = partials.length,
- args = Array(leftLength + argsLength),
- fn = (this && this !== root && this instanceof wrapper) ? Ctor : func;
-
- while (++leftIndex < leftLength) {
- args[leftIndex] = partials[leftIndex];
- }
- while (argsLength--) {
- args[leftIndex++] = arguments[++argsIndex];
- }
- return apply(fn, isBind ? thisArg : this, args);
- }
- return wrapper;
+function isArguments(value) {
+ // Safari 8.1 makes `arguments.callee` enumerable in strict mode.
+ return isArrayLikeObject(value) && hasOwnProperty.call(value, 'callee') &&
+ (!propertyIsEnumerable.call(value, 'callee') || objectToString.call(value) == argsTag);
}
/**
- * Creates a function that wraps `func` to continue currying.
+ * Checks if `value` is classified as an `Array` object.
*
- * @private
- * @param {Function} func The function to wrap.
- * @param {number} bitmask The bitmask flags. See `createWrap` for more details.
- * @param {Function} wrapFunc The function to create the `func` wrapper.
- * @param {*} placeholder The placeholder value.
- * @param {*} [thisArg] The `this` binding of `func`.
- * @param {Array} [partials] The arguments to prepend to those provided to
- * the new function.
- * @param {Array} [holders] The `partials` placeholder indexes.
- * @param {Array} [argPos] The argument positions of the new function.
- * @param {number} [ary] The arity cap of `func`.
- * @param {number} [arity] The arity of `func`.
- * @returns {Function} Returns the new wrapped function.
+ * @static
+ * @memberOf _
+ * @since 0.1.0
+ * @category Lang
+ * @param {*} value The value to check.
+ * @returns {boolean} Returns `true` if `value` is an array, else `false`.
+ * @example
+ *
+ * _.isArray([1, 2, 3]);
+ * // => true
+ *
+ * _.isArray(document.body.children);
+ * // => false
+ *
+ * _.isArray('abc');
+ * // => false
+ *
+ * _.isArray(_.noop);
+ * // => false
*/
-function createRecurry(func, bitmask, wrapFunc, placeholder, thisArg, partials, holders, argPos, ary, arity) {
- var isCurry = bitmask & CURRY_FLAG,
- newHolders = isCurry ? holders : undefined,
- newHoldersRight = isCurry ? undefined : holders,
- newPartials = isCurry ? partials : undefined,
- newPartialsRight = isCurry ? undefined : partials;
-
- bitmask |= (isCurry ? PARTIAL_FLAG : PARTIAL_RIGHT_FLAG);
- bitmask &= ~(isCurry ? PARTIAL_RIGHT_FLAG : PARTIAL_FLAG);
-
- if (!(bitmask & CURRY_BOUND_FLAG)) {
- bitmask &= ~(BIND_FLAG | BIND_KEY_FLAG);
- }
-
- var result = wrapFunc(func, bitmask, thisArg, newPartials, newHolders, newPartialsRight, newHoldersRight, argPos, ary, arity);
- result.placeholder = placeholder;
- return setWrapToString(result, func, bitmask);
-}
+var isArray = Array.isArray;
/**
- * Creates a function that either curries or invokes `func` with optional
- * `this` binding and partially applied arguments.
+ * Checks if `value` is array-like. A value is considered array-like if it's
+ * not a function and has a `value.length` that's an integer greater than or
+ * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`.
*
- * @private
- * @param {Function|string} func The function or method name to wrap.
- * @param {number} bitmask The bitmask flags.
- * The bitmask may be composed of the following flags:
- * 1 - `_.bind`
- * 2 - `_.bindKey`
- * 4 - `_.curry` or `_.curryRight` of a bound function
- * 8 - `_.curry`
- * 16 - `_.curryRight`
- * 32 - `_.partial`
- * 64 - `_.partialRight`
- * 128 - `_.rearg`
- * 256 - `_.ary`
- * 512 - `_.flip`
- * @param {*} [thisArg] The `this` binding of `func`.
- * @param {Array} [partials] The arguments to be partially applied.
- * @param {Array} [holders] The `partials` placeholder indexes.
- * @param {Array} [argPos] The argument positions of the new function.
- * @param {number} [ary] The arity cap of `func`.
- * @param {number} [arity] The arity of `func`.
- * @returns {Function} Returns the new wrapped function.
- */
-function createWrap(func, bitmask, thisArg, partials, holders, argPos, ary, arity) {
- var isBindKey = bitmask & BIND_KEY_FLAG;
- if (!isBindKey && typeof func != 'function') {
- throw new TypeError(FUNC_ERROR_TEXT);
- }
- var length = partials ? partials.length : 0;
- if (!length) {
- bitmask &= ~(PARTIAL_FLAG | PARTIAL_RIGHT_FLAG);
- partials = holders = undefined;
- }
- ary = ary === undefined ? ary : nativeMax(toInteger(ary), 0);
- arity = arity === undefined ? arity : toInteger(arity);
- length -= holders ? holders.length : 0;
-
- if (bitmask & PARTIAL_RIGHT_FLAG) {
- var partialsRight = partials,
- holdersRight = holders;
-
- partials = holders = undefined;
- }
-
- var newData = [
- func, bitmask, thisArg, partials, holders, partialsRight, holdersRight,
- argPos, ary, arity
- ];
-
- func = newData[0];
- bitmask = newData[1];
- thisArg = newData[2];
- partials = newData[3];
- holders = newData[4];
- arity = newData[9] = newData[9] == null
- ? (isBindKey ? 0 : func.length)
- : nativeMax(newData[9] - length, 0);
-
- if (!arity && bitmask & (CURRY_FLAG | CURRY_RIGHT_FLAG)) {
- bitmask &= ~(CURRY_FLAG | CURRY_RIGHT_FLAG);
- }
- if (!bitmask || bitmask == BIND_FLAG) {
- var result = createBind(func, bitmask, thisArg);
- } else if (bitmask == CURRY_FLAG || bitmask == CURRY_RIGHT_FLAG) {
- result = createCurry(func, bitmask, arity);
- } else if ((bitmask == PARTIAL_FLAG || bitmask == (BIND_FLAG | PARTIAL_FLAG)) && !holders.length) {
- result = createPartial(func, bitmask, thisArg, partials);
- } else {
- result = createHybrid.apply(undefined, newData);
- }
- return setWrapToString(result, func, bitmask);
-}
-
-/**
- * Gets the argument placeholder value for `func`.
+ * @static
+ * @memberOf _
+ * @since 4.0.0
+ * @category Lang
+ * @param {*} value The value to check.
+ * @returns {boolean} Returns `true` if `value` is array-like, else `false`.
+ * @example
*
- * @private
- * @param {Function} func The function to inspect.
- * @returns {*} Returns the placeholder value.
+ * _.isArrayLike([1, 2, 3]);
+ * // => true
+ *
+ * _.isArrayLike(document.body.children);
+ * // => true
+ *
+ * _.isArrayLike('abc');
+ * // => true
+ *
+ * _.isArrayLike(_.noop);
+ * // => false
*/
-function getHolder(func) {
- var object = func;
- return object.placeholder;
+function isArrayLike(value) {
+ return value != null && isLength(value.length) && !isFunction(value);
}
/**
- * Gets the native function at `key` of `object`.
+ * This method is like `_.isArrayLike` except that it also checks if `value`
+ * is an object.
*
- * @private
- * @param {Object} object The object to query.
- * @param {string} key The key of the method to get.
- * @returns {*} Returns the function if it's native, else `undefined`.
+ * @static
+ * @memberOf _
+ * @since 4.0.0
+ * @category Lang
+ * @param {*} value The value to check.
+ * @returns {boolean} Returns `true` if `value` is an array-like object,
+ * else `false`.
+ * @example
+ *
+ * _.isArrayLikeObject([1, 2, 3]);
+ * // => true
+ *
+ * _.isArrayLikeObject(document.body.children);
+ * // => true
+ *
+ * _.isArrayLikeObject('abc');
+ * // => false
+ *
+ * _.isArrayLikeObject(_.noop);
+ * // => false
*/
-function getNative(object, key) {
- var value = getValue(object, key);
- return baseIsNative(value) ? value : undefined;
+function isArrayLikeObject(value) {
+ return isObjectLike(value) && isArrayLike(value);
}
/**
- * Extracts wrapper details from the `source` body comment.
+ * Checks if `value` is classified as a `Function` object.
*
- * @private
- * @param {string} source The source to inspect.
- * @returns {Array} Returns the wrapper details.
+ * @static
+ * @memberOf _
+ * @since 0.1.0
+ * @category Lang
+ * @param {*} value The value to check.
+ * @returns {boolean} Returns `true` if `value` is a function, else `false`.
+ * @example
+ *
+ * _.isFunction(_);
+ * // => true
+ *
+ * _.isFunction(/abc/);
+ * // => false
*/
-function getWrapDetails(source) {
- var match = source.match(reWrapDetails);
- return match ? match[1].split(reSplitDetails) : [];
+function isFunction(value) {
+ // The use of `Object#toString` avoids issues with the `typeof` operator
+ // in Safari 8-9 which returns 'object' for typed array and other constructors.
+ var tag = isObject(value) ? objectToString.call(value) : '';
+ return tag == funcTag || tag == genTag;
}
/**
- * Inserts wrapper `details` in a comment at the top of the `source` body.
+ * Checks if `value` is a valid array-like length.
*
- * @private
- * @param {string} source The source to modify.
- * @returns {Array} details The details to insert.
- * @returns {string} Returns the modified source.
+ * **Note:** This method is loosely based on
+ * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength).
+ *
+ * @static
+ * @memberOf _
+ * @since 4.0.0
+ * @category Lang
+ * @param {*} value The value to check.
+ * @returns {boolean} Returns `true` if `value` is a valid length, else `false`.
+ * @example
+ *
+ * _.isLength(3);
+ * // => true
+ *
+ * _.isLength(Number.MIN_VALUE);
+ * // => false
+ *
+ * _.isLength(Infinity);
+ * // => false
+ *
+ * _.isLength('3');
+ * // => false
*/
-function insertWrapDetails(source, details) {
- var length = details.length,
- lastIndex = length - 1;
-
- details[lastIndex] = (length > 1 ? '& ' : '') + details[lastIndex];
- details = details.join(length > 2 ? ', ' : ' ');
- return source.replace(reWrapComment, '{\n/* [wrapped with ' + details + '] */\n');
+function isLength(value) {
+ return typeof value == 'number' &&
+ value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;
}
/**
- * Checks if `value` is a valid array-like index.
+ * Checks if `value` is the
+ * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)
+ * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)
*
- * @private
+ * @static
+ * @memberOf _
+ * @since 0.1.0
+ * @category Lang
* @param {*} value The value to check.
- * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index.
- * @returns {boolean} Returns `true` if `value` is a valid index, else `false`.
+ * @returns {boolean} Returns `true` if `value` is an object, else `false`.
+ * @example
+ *
+ * _.isObject({});
+ * // => true
+ *
+ * _.isObject([1, 2, 3]);
+ * // => true
+ *
+ * _.isObject(_.noop);
+ * // => true
+ *
+ * _.isObject(null);
+ * // => false
*/
-function isIndex(value, length) {
- length = length == null ? MAX_SAFE_INTEGER : length;
- return !!length &&
- (typeof value == 'number' || reIsUint.test(value)) &&
- (value > -1 && value % 1 == 0 && value < length);
+function isObject(value) {
+ var type = typeof value;
+ return !!value && (type == 'object' || type == 'function');
}
/**
- * Checks if `func` has its source masked.
+ * Checks if `value` is object-like. A value is object-like if it's not `null`
+ * and has a `typeof` result of "object".
*
- * @private
- * @param {Function} func The function to check.
- * @returns {boolean} Returns `true` if `func` is masked, else `false`.
+ * @static
+ * @memberOf _
+ * @since 4.0.0
+ * @category Lang
+ * @param {*} value The value to check.
+ * @returns {boolean} Returns `true` if `value` is object-like, else `false`.
+ * @example
+ *
+ * _.isObjectLike({});
+ * // => true
+ *
+ * _.isObjectLike([1, 2, 3]);
+ * // => true
+ *
+ * _.isObjectLike(_.noop);
+ * // => false
+ *
+ * _.isObjectLike(null);
+ * // => false
*/
-function isMasked(func) {
- return !!maskSrcKey && (maskSrcKey in func);
+function isObjectLike(value) {
+ return !!value && typeof value == 'object';
}
/**
- * Reorder `array` according to the specified indexes where the element at
- * the first index is assigned as the first element, the element at
- * the second index is assigned as the second element, and so on.
+ * Creates a function that returns the result of invoking the given functions
+ * with the `this` binding of the created function, where each successive
+ * invocation is supplied the return value of the previous.
*
- * @private
- * @param {Array} array The array to reorder.
- * @param {Array} indexes The arranged array indexes.
- * @returns {Array} Returns `array`.
- */
-function reorder(array, indexes) {
- var arrLength = array.length,
- length = nativeMin(indexes.length, arrLength),
- oldArray = copyArray(array);
+ * @static
+ * @memberOf _
+ * @since 3.0.0
+ * @category Util
+ * @param {...(Function|Function[])} [funcs] The functions to invoke.
+ * @returns {Function} Returns the new composite function.
+ * @see _.flowRight
+ * @example
+ *
+ * function square(n) {
+ * return n * n;
+ * }
+ *
+ * var addSquare = _.flow([_.add, square]);
+ * addSquare(1, 2);
+ * // => 9
+ */
+var flow = createFlow();
- while (length--) {
- var index = indexes[length];
- array[length] = isIndex(index, arrLength) ? oldArray[index] : undefined;
- }
- return array;
+module.exports = flow;
+
+/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(48)))
+
+/***/ }),
+/* 148 */
+/***/ (function(module, exports, __webpack_require__) {
+
+"use strict";
+
+
+Object.defineProperty(exports, "__esModule", {
+ value: true
+});
+exports.yuv2rgb = yuv2rgb;
+exports.rgb2yuv = rgb2yuv;
+function yuv2rgb(yuv) {
+ var y = yuv[0],
+ u = yuv[1],
+ v = yuv[2],
+ r,
+ g,
+ b;
+
+ r = y * 1 + u * 0 + v * 1.13983;
+ g = y * 1 + u * -0.39465 + v * -0.58060;
+ b = y * 1 + u * 2.02311 + v * 0;
+
+ r = Math.min(Math.max(0, r), 1);
+ g = Math.min(Math.max(0, g), 1);
+ b = Math.min(Math.max(0, b), 1);
+
+ return [r * 255, g * 255, b * 255];
}
-/**
- * Sets the `toString` method of `wrapper` to mimic the source of `reference`
- * with wrapper details in a comment at the top of the source body.
- *
- * @private
- * @param {Function} wrapper The function to modify.
- * @param {Function} reference The reference function.
- * @param {number} bitmask The bitmask flags. See `createWrap` for more details.
- * @returns {Function} Returns `wrapper`.
- */
-var setWrapToString = !defineProperty ? identity : function(wrapper, reference, bitmask) {
- var source = (reference + '');
- return defineProperty(wrapper, 'toString', {
- 'configurable': true,
- 'enumerable': false,
- 'value': constant(insertWrapDetails(source, updateWrapDetails(getWrapDetails(source), bitmask)))
- });
+function rgb2yuv(rgb) {
+ var r = rgb[0] / 255,
+ g = rgb[1] / 255,
+ b = rgb[2] / 255;
+
+ var y = r * 0.299 + g * 0.587 + b * 0.114;
+ var u = r * -0.14713 + g * -0.28886 + b * 0.436;
+ var v = r * 0.615 + g * -0.51499 + b * -0.10001;
+
+ return [y, u, v];
};
-/**
- * Converts `func` to its source code.
- *
- * @private
- * @param {Function} func The function to process.
- * @returns {string} Returns the source code.
- */
-function toSource(func) {
- if (func != null) {
- try {
- return funcToString.call(func);
- } catch (e) {}
- try {
- return (func + '');
- } catch (e) {}
- }
- return '';
-}
+/***/ }),
+/* 149 */
+/***/ (function(module, exports, __webpack_require__) {
+"use strict";
/**
- * Updates wrapper `details` based on `bitmask` flags.
+ * Copyright (c) 2014-present, Facebook, Inc.
+ * All rights reserved.
*
- * @private
- * @returns {Array} details The details to modify.
- * @param {number} bitmask The bitmask flags. See `createWrap` for more details.
- * @returns {Array} Returns `details`.
+ * 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.
+ *
+ * @providesModule Dispatcher
+ *
+ * @preventMunge
*/
-function updateWrapDetails(details, bitmask) {
- arrayEach(wrapFlags, function(pair) {
- var value = '_.' + pair[0];
- if ((bitmask & pair[1]) && !arrayIncludes(details, value)) {
- details.push(value);
- }
- });
- return details.sort();
-}
+
+
+
+exports.__esModule = true;
+
+function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }
+
+var invariant = __webpack_require__(150);
+
+var _prefix = 'ID_';
/**
- * Creates a function that accepts arguments of `func` and either invokes
- * `func` returning its result, if at least `arity` number of arguments have
- * been provided, or returns a function that accepts the remaining `func`
- * arguments, and so on. The arity of `func` may be specified if `func.length`
- * is not sufficient.
- *
- * The `_.curry.placeholder` value, which defaults to `_` in monolithic builds,
- * may be used as a placeholder for provided arguments.
+ * Dispatcher is used to broadcast payloads to registered callbacks. This is
+ * different from generic pub-sub systems in two ways:
*
- * **Note:** This method doesn't set the "length" property of curried functions.
+ * 1) Callbacks are not subscribed to particular events. Every payload is
+ * dispatched to every registered callback.
+ * 2) Callbacks can be deferred in whole or part until other callbacks have
+ * been executed.
*
- * @static
- * @memberOf _
- * @since 2.0.0
- * @category Function
- * @param {Function} func The function to curry.
- * @param {number} [arity=func.length] The arity of `func`.
- * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.
- * @returns {Function} Returns the new curried function.
- * @example
+ * For example, consider this hypothetical flight destination form, which
+ * selects a default city when a country is selected:
*
- * var abc = function(a, b, c) {
- * return [a, b, c];
- * };
+ * var flightDispatcher = new Dispatcher();
*
- * var curried = _.curry(abc);
+ * // Keeps track of which country is selected
+ * var CountryStore = {country: null};
*
- * curried(1)(2)(3);
- * // => [1, 2, 3]
+ * // Keeps track of which city is selected
+ * var CityStore = {city: null};
*
- * curried(1, 2)(3);
- * // => [1, 2, 3]
+ * // Keeps track of the base flight price of the selected city
+ * var FlightPriceStore = {price: null}
*
- * curried(1, 2, 3);
- * // => [1, 2, 3]
+ * When a user changes the selected city, we dispatch the payload:
*
- * // Curried with placeholders.
- * curried(1)(_, 3)(2);
- * // => [1, 2, 3]
- */
-function curry(func, arity, guard) {
- arity = guard ? undefined : arity;
- var result = createWrap(func, CURRY_FLAG, undefined, undefined, undefined, undefined, undefined, arity);
- result.placeholder = curry.placeholder;
- return result;
-}
-
-/**
- * Checks if `value` is classified as a `Function` object.
+ * flightDispatcher.dispatch({
+ * actionType: 'city-update',
+ * selectedCity: 'paris'
+ * });
*
- * @static
- * @memberOf _
- * @since 0.1.0
- * @category Lang
- * @param {*} value The value to check.
- * @returns {boolean} Returns `true` if `value` is a function, else `false`.
- * @example
+ * This payload is digested by `CityStore`:
*
- * _.isFunction(_);
- * // => true
+ * flightDispatcher.register(function(payload) {
+ * if (payload.actionType === 'city-update') {
+ * CityStore.city = payload.selectedCity;
+ * }
+ * });
*
- * _.isFunction(/abc/);
- * // => false
- */
-function isFunction(value) {
- // The use of `Object#toString` avoids issues with the `typeof` operator
- // in Safari 8-9 which returns 'object' for typed array and other constructors.
- var tag = isObject(value) ? objectToString.call(value) : '';
- return tag == funcTag || tag == genTag;
-}
-
-/**
- * Checks if `value` is the
- * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)
- * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)
+ * When the user selects a country, we dispatch the payload:
*
- * @static
- * @memberOf _
- * @since 0.1.0
- * @category Lang
- * @param {*} value The value to check.
- * @returns {boolean} Returns `true` if `value` is an object, else `false`.
- * @example
+ * flightDispatcher.dispatch({
+ * actionType: 'country-update',
+ * selectedCountry: 'australia'
+ * });
*
- * _.isObject({});
- * // => true
+ * This payload is digested by both stores:
*
- * _.isObject([1, 2, 3]);
- * // => true
+ * CountryStore.dispatchToken = flightDispatcher.register(function(payload) {
+ * if (payload.actionType === 'country-update') {
+ * CountryStore.country = payload.selectedCountry;
+ * }
+ * });
*
- * _.isObject(_.noop);
- * // => true
+ * When the callback to update `CountryStore` is registered, we save a reference
+ * to the returned token. Using this token with `waitFor()`, we can guarantee
+ * that `CountryStore` is updated before the callback that updates `CityStore`
+ * needs to query its data.
*
- * _.isObject(null);
- * // => false
- */
-function isObject(value) {
- var type = typeof value;
- return !!value && (type == 'object' || type == 'function');
-}
-
-/**
- * Checks if `value` is object-like. A value is object-like if it's not `null`
- * and has a `typeof` result of "object".
- *
- * @static
- * @memberOf _
- * @since 4.0.0
- * @category Lang
- * @param {*} value The value to check.
- * @returns {boolean} Returns `true` if `value` is object-like, else `false`.
- * @example
+ * CityStore.dispatchToken = flightDispatcher.register(function(payload) {
+ * if (payload.actionType === 'country-update') {
+ * // `CountryStore.country` may not be updated.
+ * flightDispatcher.waitFor([CountryStore.dispatchToken]);
+ * // `CountryStore.country` is now guaranteed to be updated.
*
- * _.isObjectLike({});
- * // => true
+ * // Select the default city for the new country
+ * CityStore.city = getDefaultCityForCountry(CountryStore.country);
+ * }
+ * });
*
- * _.isObjectLike([1, 2, 3]);
- * // => true
+ * The usage of `waitFor()` can be chained, for example:
*
- * _.isObjectLike(_.noop);
- * // => false
+ * FlightPriceStore.dispatchToken =
+ * flightDispatcher.register(function(payload) {
+ * switch (payload.actionType) {
+ * case 'country-update':
+ * case 'city-update':
+ * flightDispatcher.waitFor([CityStore.dispatchToken]);
+ * FlightPriceStore.price =
+ * getFlightPriceStore(CountryStore.country, CityStore.city);
+ * break;
+ * }
+ * });
*
- * _.isObjectLike(null);
- * // => false
+ * The `country-update` payload will be guaranteed to invoke the stores'
+ * registered callbacks in order: `CountryStore`, `CityStore`, then
+ * `FlightPriceStore`.
*/
-function isObjectLike(value) {
- return !!value && typeof value == 'object';
-}
+var Dispatcher = (function () {
+ function Dispatcher() {
+ _classCallCheck(this, Dispatcher);
+
+ this._callbacks = {};
+ this._isDispatching = false;
+ this._isHandled = {};
+ this._isPending = {};
+ this._lastID = 1;
+ }
+
+ /**
+ * Registers a callback to be invoked with every dispatched payload. Returns
+ * a token that can be used with `waitFor()`.
+ */
+
+ Dispatcher.prototype.register = function register(callback) {
+ var id = _prefix + this._lastID++;
+ this._callbacks[id] = callback;
+ return id;
+ };
+
+ /**
+ * Removes a callback based on its token.
+ */
+
+ Dispatcher.prototype.unregister = function unregister(id) {
+ !this._callbacks[id] ? false ? undefined : invariant(false) : undefined;
+ delete this._callbacks[id];
+ };
+
+ /**
+ * Waits for the callbacks specified to be invoked before continuing execution
+ * of the current callback. This method should only be used by a callback in
+ * response to a dispatched payload.
+ */
+
+ Dispatcher.prototype.waitFor = function waitFor(ids) {
+ !this._isDispatching ? false ? undefined : invariant(false) : undefined;
+ for (var ii = 0; ii < ids.length; ii++) {
+ var id = ids[ii];
+ if (this._isPending[id]) {
+ !this._isHandled[id] ? false ? undefined : invariant(false) : undefined;
+ continue;
+ }
+ !this._callbacks[id] ? false ? undefined : invariant(false) : undefined;
+ this._invokeCallback(id);
+ }
+ };
+
+ /**
+ * Dispatches a payload to all registered callbacks.
+ */
+
+ Dispatcher.prototype.dispatch = function dispatch(payload) {
+ !!this._isDispatching ? false ? undefined : invariant(false) : undefined;
+ this._startDispatching(payload);
+ try {
+ for (var id in this._callbacks) {
+ if (this._isPending[id]) {
+ continue;
+ }
+ this._invokeCallback(id);
+ }
+ } finally {
+ this._stopDispatching();
+ }
+ };
+
+ /**
+ * Is this Dispatcher currently dispatching.
+ */
+
+ Dispatcher.prototype.isDispatching = function isDispatching() {
+ return this._isDispatching;
+ };
+
+ /**
+ * Call the callback stored with the given id. Also do some internal
+ * bookkeeping.
+ *
+ * @internal
+ */
+
+ Dispatcher.prototype._invokeCallback = function _invokeCallback(id) {
+ this._isPending[id] = true;
+ this._callbacks[id](this._pendingPayload);
+ this._isHandled[id] = true;
+ };
+
+ /**
+ * Set up bookkeeping needed when dispatching.
+ *
+ * @internal
+ */
+
+ Dispatcher.prototype._startDispatching = function _startDispatching(payload) {
+ for (var id in this._callbacks) {
+ this._isPending[id] = false;
+ this._isHandled[id] = false;
+ }
+ this._pendingPayload = payload;
+ this._isDispatching = true;
+ };
+
+ /**
+ * Clear bookkeeping used for dispatching.
+ *
+ * @internal
+ */
+
+ Dispatcher.prototype._stopDispatching = function _stopDispatching() {
+ delete this._pendingPayload;
+ this._isDispatching = false;
+ };
+
+ return Dispatcher;
+})();
+
+module.exports = Dispatcher;
+
+/***/ }),
+/* 150 */
+/***/ (function(module, exports, __webpack_require__) {
+
+"use strict";
/**
- * Checks if `value` is classified as a `Symbol` primitive or object.
- *
- * @static
- * @memberOf _
- * @since 4.0.0
- * @category Lang
- * @param {*} value The value to check.
- * @returns {boolean} Returns `true` if `value` is a symbol, else `false`.
- * @example
+ * Copyright (c) 2013-present, Facebook, Inc.
*
- * _.isSymbol(Symbol.iterator);
- * // => true
+ * This source code is licensed under the MIT license found in the
+ * LICENSE file in the root directory of this source tree.
*
- * _.isSymbol('abc');
- * // => false
*/
-function isSymbol(value) {
- return typeof value == 'symbol' ||
- (isObjectLike(value) && objectToString.call(value) == symbolTag);
-}
+
+
/**
- * Converts `value` to a finite number.
- *
- * @static
- * @memberOf _
- * @since 4.12.0
- * @category Lang
- * @param {*} value The value to convert.
- * @returns {number} Returns the converted number.
- * @example
- *
- * _.toFinite(3.2);
- * // => 3.2
- *
- * _.toFinite(Number.MIN_VALUE);
- * // => 5e-324
+ * Use invariant() to assert state which your program assumes to be true.
*
- * _.toFinite(Infinity);
- * // => 1.7976931348623157e+308
+ * Provide sprintf-style format (only %s is supported) and arguments
+ * to provide information about what broke and what you were
+ * expecting.
*
- * _.toFinite('3.2');
- * // => 3.2
+ * The invariant message will be stripped in production, but the invariant
+ * will remain to ensure logic does not differ in production.
*/
-function toFinite(value) {
- if (!value) {
- return value === 0 ? value : 0;
- }
- value = toNumber(value);
- if (value === INFINITY || value === -INFINITY) {
- var sign = (value < 0 ? -1 : 1);
- return sign * MAX_INTEGER;
- }
- return value === value ? value : 0;
-}
-/**
- * Converts `value` to an integer.
- *
- * **Note:** This method is loosely based on
- * [`ToInteger`](http://www.ecma-international.org/ecma-262/7.0/#sec-tointeger).
- *
- * @static
- * @memberOf _
- * @since 4.0.0
- * @category Lang
- * @param {*} value The value to convert.
- * @returns {number} Returns the converted integer.
- * @example
- *
- * _.toInteger(3.2);
- * // => 3
- *
- * _.toInteger(Number.MIN_VALUE);
- * // => 0
- *
- * _.toInteger(Infinity);
- * // => 1.7976931348623157e+308
- *
- * _.toInteger('3.2');
- * // => 3
- */
-function toInteger(value) {
- var result = toFinite(value),
- remainder = result % 1;
+var validateFormat = function validateFormat(format) {};
- return result === result ? (remainder ? result - remainder : result) : 0;
-}
+if (false) {}
-/**
- * Converts `value` to a number.
- *
- * @static
- * @memberOf _
- * @since 4.0.0
- * @category Lang
- * @param {*} value The value to process.
- * @returns {number} Returns the number.
- * @example
- *
- * _.toNumber(3.2);
- * // => 3.2
- *
- * _.toNumber(Number.MIN_VALUE);
- * // => 5e-324
- *
- * _.toNumber(Infinity);
- * // => Infinity
- *
- * _.toNumber('3.2');
- * // => 3.2
- */
-function toNumber(value) {
- if (typeof value == 'number') {
- return value;
- }
- if (isSymbol(value)) {
- return NAN;
- }
- if (isObject(value)) {
- var other = typeof value.valueOf == 'function' ? value.valueOf() : value;
- value = isObject(other) ? (other + '') : other;
- }
- if (typeof value != 'string') {
- return value === 0 ? value : +value;
+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;
}
- value = value.replace(reTrim, '');
- var isBinary = reIsBinary.test(value);
- return (isBinary || reIsOctal.test(value))
- ? freeParseInt(value.slice(2), isBinary ? 2 : 8)
- : (reIsBadHex.test(value) ? NAN : +value);
}
-/**
- * Creates a function that returns `value`.
- *
- * @static
- * @memberOf _
- * @since 2.4.0
- * @category Util
- * @param {*} value The value to return from the new function.
- * @returns {Function} Returns the new constant function.
- * @example
- *
- * var objects = _.times(2, _.constant({ 'a': 1 }));
- *
- * console.log(objects);
- * // => [{ 'a': 1 }, { 'a': 1 }]
- *
- * console.log(objects[0] === objects[1]);
- * // => true
- */
-function constant(value) {
- return function() {
- return value;
- };
-}
+module.exports = invariant;
-/**
- * This method returns the first argument it receives.
- *
- * @static
- * @since 0.1.0
- * @memberOf _
- * @category Util
- * @param {*} value Any value.
- * @returns {*} Returns `value`.
- * @example
- *
- * var object = { 'a': 1 };
- *
- * console.log(_.identity(object) === object);
- * // => true
- */
-function identity(value) {
- return value;
-}
+/***/ }),
+/* 151 */
+/***/ (function(module, exports, __webpack_require__) {
-// Assign default placeholders.
-curry.placeholder = {};
+"use strict";
-module.exports = curry;
-/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(57)))
+Object.defineProperty(exports, "__esModule", {
+ value: true
+});
+exports["default"] = ajaxGet;
+function ajaxGet(url, callback) {
+ if (typeof XDomainRequest !== 'undefined') {
+ callback(null);
+ return null;
+ }
+
+ var xhr = new XMLHttpRequest();
+ xhr.onreadystatechange = function () {
+ if (xhr.readyState === XMLHttpRequest.DONE && xhr.status === 200) {
+ callback(JSON.parse(xhr.responseText));
+ }
+ };
+ xhr.open('GET', url, true);
+ xhr.send();
+ return xhr;
+}
+module.exports = exports['default'];
/***/ }),
-/* 124 */
+/* 152 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-exports.__esModule = true;
+Object.defineProperty(exports, "__esModule", {
+ value: true
+});
+exports.classNames = classNames;
+function classNames(classSet) {
+ return Object.keys(classSet).filter(function (key) {
+ return classSet[key];
+ }).join(' ');
+}
-function _interopRequire(obj) { return obj && obj.__esModule ? obj['default'] : obj; }
+/***/ }),
+/* 153 */
+/***/ (function(module, exports, __webpack_require__) {
-var _threezerotwofour = __webpack_require__(125);
+var api = __webpack_require__(24);
+ var content = __webpack_require__(154);
-exports.threezerotwofour = _interopRequire(_threezerotwofour);
+ content = content.__esModule ? content.default : content;
-var _apathy = __webpack_require__(126);
+ if (typeof content === 'string') {
+ content = [[module.i, content, '']];
+ }
-exports.apathy = _interopRequire(_apathy);
+var options = {};
-var _ashes = __webpack_require__(127);
+options.insert = "head";
+options.singleton = false;
-exports.ashes = _interopRequire(_ashes);
+var update = api(content, options);
-var _atelierDune = __webpack_require__(128);
-exports.atelierDune = _interopRequire(_atelierDune);
-var _atelierForest = __webpack_require__(129);
+module.exports = content.locals || {};
-exports.atelierForest = _interopRequire(_atelierForest);
+/***/ }),
+/* 154 */
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
-var _atelierHeath = __webpack_require__(130);
+"use strict";
+__webpack_require__.r(__webpack_exports__);
+/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5);
+/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0__);
+// Imports
-exports.atelierHeath = _interopRequire(_atelierHeath);
+var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default()(false);
+// Module
+___CSS_LOADER_EXPORT___.push([module.i, ".rjv-demo .rjv-settings,.rjv-demo .rjv-source{vertical-align:top;display:inline-block;margin-top:5px;margin-right:10px;min-width:300px;max-width:400px}.rjv-demo .rjv-settings .rjv-input,.rjv-demo .rjv-source .rjv-input{margin-bottom:5px}.rjv-demo .rjv-settings .rjv-input .rjv-label,.rjv-demo .rjv-source .rjv-input .rjv-label{font-size:14px;font-weight:bold}.rjv-demo .rjv-header{position:relative}.rjv-demo .rjv-header .rjv-logo{width:100px;position:absolute;right:0px;top:0px;cursor:pointer}.rjv-demo .rjv-header .github-btn{display:block;position:absolute;right:0px;top:48px}\n", ""]);
+// Exports
+/* harmony default export */ __webpack_exports__["default"] = (___CSS_LOADER_EXPORT___);
-var _atelierLakeside = __webpack_require__(131);
-exports.atelierLakeside = _interopRequire(_atelierLakeside);
+/***/ }),
+/* 155 */
+/***/ (function(module, exports, __webpack_require__) {
-var _atelierSeaside = __webpack_require__(132);
+var api = __webpack_require__(24);
+ var content = __webpack_require__(156);
-exports.atelierSeaside = _interopRequire(_atelierSeaside);
+ content = content.__esModule ? content.default : content;
-var _bespin = __webpack_require__(133);
+ if (typeof content === 'string') {
+ content = [[module.i, content, '']];
+ }
-exports.bespin = _interopRequire(_bespin);
+var options = {};
-var _brewer = __webpack_require__(134);
+options.insert = "head";
+options.singleton = false;
-exports.brewer = _interopRequire(_brewer);
+var update = api(content, options);
-var _bright = __webpack_require__(135);
-exports.bright = _interopRequire(_bright);
-var _chalk = __webpack_require__(136);
+module.exports = content.locals || {};
-exports.chalk = _interopRequire(_chalk);
+/***/ }),
+/* 156 */
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
-var _codeschool = __webpack_require__(137);
+"use strict";
+__webpack_require__.r(__webpack_exports__);
+/* harmony import */ var _css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5);
+/* harmony import */ var _css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0__);
+// Imports
-exports.codeschool = _interopRequire(_codeschool);
+var ___CSS_LOADER_EXPORT___ = _css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default()(false);
+// Module
+___CSS_LOADER_EXPORT___.push([module.i, ".Select{position:relative}.Select input::-webkit-contacts-auto-fill-button,.Select input::-webkit-credentials-auto-fill-button{display:none !important}.Select input::-ms-clear{display:none !important}.Select input::-ms-reveal{display:none !important}.Select,.Select div,.Select input,.Select span{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.Select.is-disabled .Select-arrow-zone{cursor:default;pointer-events:none;opacity:0.35}.Select.is-disabled>.Select-control{background-color:#f9f9f9}.Select.is-disabled>.Select-control:hover{box-shadow:none}.Select.is-open>.Select-control{border-bottom-right-radius:0;border-bottom-left-radius:0;background:#fff;border-color:#b3b3b3 #ccc #d9d9d9}.Select.is-open>.Select-control .Select-arrow{top:-2px;border-color:transparent transparent #999;border-width:0 5px 5px}.Select.is-searchable.is-open>.Select-control{cursor:text}.Select.is-searchable.is-focused:not(.is-open)>.Select-control{cursor:text}.Select.is-focused>.Select-control{background:#fff}.Select.is-focused:not(.is-open)>.Select-control{border-color:#007eff;box-shadow:inset 0 1px 1px rgba(0,0,0,0.075),0 0 0 3px rgba(0,126,255,0.1);background:#fff}.Select.has-value.is-clearable.Select--single>.Select-control .Select-value{padding-right:42px}.Select.has-value.Select--single>.Select-control .Select-value .Select-value-label,.Select.has-value.is-pseudo-focused.Select--single>.Select-control .Select-value .Select-value-label{color:#333}.Select.has-value.Select--single>.Select-control .Select-value a.Select-value-label,.Select.has-value.is-pseudo-focused.Select--single>.Select-control .Select-value a.Select-value-label{cursor:pointer;text-decoration:none}.Select.has-value.Select--single>.Select-control .Select-value a.Select-value-label:hover,.Select.has-value.is-pseudo-focused.Select--single>.Select-control .Select-value a.Select-value-label:hover,.Select.has-value.Select--single>.Select-control .Select-value a.Select-value-label:focus,.Select.has-value.is-pseudo-focused.Select--single>.Select-control .Select-value a.Select-value-label:focus{color:#007eff;outline:none;text-decoration:underline}.Select.has-value.Select--single>.Select-control .Select-value a.Select-value-label:focus,.Select.has-value.is-pseudo-focused.Select--single>.Select-control .Select-value a.Select-value-label:focus{background:#fff}.Select.has-value.is-pseudo-focused .Select-input{opacity:0}.Select.is-open .Select-arrow,.Select .Select-arrow-zone:hover>.Select-arrow{border-top-color:#666}.Select.Select--rtl{direction:rtl;text-align:right}.Select-control{background-color:#fff;border-color:#d9d9d9 #ccc #b3b3b3;border-radius:4px;border:1px solid #ccc;color:#333;cursor:default;display:table;border-spacing:0;border-collapse:separate;height:36px;outline:none;overflow:hidden;position:relative;width:100%}.Select-control:hover{box-shadow:0 1px 0 rgba(0,0,0,0.06)}.Select-control .Select-input:focus{outline:none;background:#fff}.Select-placeholder,.Select--single>.Select-control .Select-value{bottom:0;color:#aaa;left:0;line-height:34px;padding-left:10px;padding-right:10px;position:absolute;right:0;top:0;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.Select-input{height:34px;padding-left:10px;padding-right:10px;vertical-align:middle}.Select-input>input{width:100%;background:none transparent;border:0 none;box-shadow:none;cursor:default;display:inline-block;font-family:inherit;font-size:inherit;margin:0;outline:none;line-height:17px;padding:8px 0 12px;-webkit-appearance:none}.is-focused .Select-input>input{cursor:text}.has-value.is-pseudo-focused .Select-input{opacity:0}.Select-control:not(.is-searchable)>.Select-input{outline:none}.Select-loading-zone{cursor:pointer;display:table-cell;position:relative;text-align:center;vertical-align:middle;width:16px}.Select-loading{-webkit-animation:Select-animation-spin 400ms infinite linear;-o-animation:Select-animation-spin 400ms infinite linear;animation:Select-animation-spin 400ms infinite linear;width:16px;height:16px;box-sizing:border-box;border-radius:50%;border:2px solid #ccc;border-right-color:#333;display:inline-block;position:relative;vertical-align:middle}.Select-clear-zone{-webkit-animation:Select-animation-fadeIn 200ms;-o-animation:Select-animation-fadeIn 200ms;animation:Select-animation-fadeIn 200ms;color:#999;cursor:pointer;display:table-cell;position:relative;text-align:center;vertical-align:middle;width:17px}.Select-clear-zone:hover{color:#D0021B}.Select-clear{display:inline-block;font-size:18px;line-height:1}.Select--multi .Select-clear-zone{width:17px}.Select-arrow-zone{cursor:pointer;display:table-cell;position:relative;text-align:center;vertical-align:middle;width:25px;padding-right:5px}.Select--rtl .Select-arrow-zone{padding-right:0;padding-left:5px}.Select-arrow{border-color:#999 transparent transparent;border-style:solid;border-width:5px 5px 2.5px;display:inline-block;height:0;width:0;position:relative}.Select-control>*:last-child{padding-right:5px}.Select--multi .Select-multi-value-wrapper{display:inline-block}.Select .Select-aria-only{position:absolute;display:inline-block;height:1px;width:1px;margin:-1px;clip:rect(0, 0, 0, 0);overflow:hidden;float:left}@-webkit-keyframes Select-animation-fadeIn{from{opacity:0}to{opacity:1}}@keyframes Select-animation-fadeIn{from{opacity:0}to{opacity:1}}.Select-menu-outer{border-bottom-right-radius:4px;border-bottom-left-radius:4px;background-color:#fff;border:1px solid #ccc;border-top-color:#e6e6e6;box-shadow:0 1px 0 rgba(0,0,0,0.06);box-sizing:border-box;margin-top:-1px;max-height:200px;position:absolute;left:0;top:100%;width:100%;z-index:1;-webkit-overflow-scrolling:touch}.Select-menu{max-height:198px;overflow-y:auto}.Select-option{box-sizing:border-box;background-color:#fff;color:#666666;cursor:pointer;display:block;padding:8px 10px}.Select-option:last-child{border-bottom-right-radius:4px;border-bottom-left-radius:4px}.Select-option.is-selected{background-color:#f5faff;background-color:rgba(0,126,255,0.04);color:#333}.Select-option.is-focused{background-color:#ebf5ff;background-color:rgba(0,126,255,0.08);color:#333}.Select-option.is-disabled{color:#cccccc;cursor:default}.Select-noresults{box-sizing:border-box;color:#999999;cursor:default;display:block;padding:8px 10px}.Select--multi .Select-input{vertical-align:middle;margin-left:10px;padding:0}.Select--multi.Select--rtl .Select-input{margin-left:0;margin-right:10px}.Select--multi.has-value .Select-input{margin-left:5px}.Select--multi .Select-value{background-color:#ebf5ff;background-color:rgba(0,126,255,0.08);border-radius:2px;border:1px solid #c2e0ff;border:1px solid rgba(0,126,255,0.24);color:#007eff;display:inline-block;font-size:0.9em;line-height:1.4;margin-left:5px;margin-top:5px;vertical-align:top}.Select--multi .Select-value-icon,.Select--multi .Select-value-label{display:inline-block;vertical-align:middle}.Select--multi .Select-value-label{border-bottom-right-radius:2px;border-top-right-radius:2px;cursor:default;padding:2px 5px}.Select--multi a.Select-value-label{color:#007eff;cursor:pointer;text-decoration:none}.Select--multi a.Select-value-label:hover{text-decoration:underline}.Select--multi .Select-value-icon{cursor:pointer;border-bottom-left-radius:2px;border-top-left-radius:2px;border-right:1px solid #c2e0ff;border-right:1px solid rgba(0,126,255,0.24);padding:1px 5px 3px}.Select--multi .Select-value-icon:hover,.Select--multi .Select-value-icon:focus{background-color:#d8eafd;background-color:rgba(0,113,230,0.08);color:#0071e6}.Select--multi .Select-value-icon:active{background-color:#c2e0ff;background-color:rgba(0,126,255,0.24)}.Select--multi.Select--rtl .Select-value{margin-left:0;margin-right:5px}.Select--multi.Select--rtl .Select-value-icon{border-right:none;border-left:1px solid #c2e0ff;border-left:1px solid rgba(0,126,255,0.24)}.Select--multi.is-disabled .Select-value{background-color:#fcfcfc;border:1px solid #e3e3e3;color:#333}.Select--multi.is-disabled .Select-value-icon{cursor:not-allowed;border-right:1px solid #e3e3e3}.Select--multi.is-disabled .Select-value-icon:hover,.Select--multi.is-disabled .Select-value-icon:focus,.Select--multi.is-disabled .Select-value-icon:active{background-color:#fcfcfc}@keyframes Select-animation-spin{to{transform:rotate(1turn)}}@-webkit-keyframes Select-animation-spin{to{-webkit-transform:rotate(1turn)}}\n", ""]);
+// Exports
+/* harmony default export */ __webpack_exports__["default"] = (___CSS_LOADER_EXPORT___);
-var _colors = __webpack_require__(138);
-exports.colors = _interopRequire(_colors);
+/***/ }),
+/* 157 */
+/***/ (function(module, exports, __webpack_require__) {
-var _default = __webpack_require__(139);
+var api = __webpack_require__(24);
+ var content = __webpack_require__(158);
-exports['default'] = _interopRequire(_default);
+ content = content.__esModule ? content.default : content;
-var _eighties = __webpack_require__(140);
+ if (typeof content === 'string') {
+ content = [[module.i, content, '']];
+ }
-exports.eighties = _interopRequire(_eighties);
+var options = {};
-var _embers = __webpack_require__(141);
+options.insert = "head";
+options.singleton = false;
-exports.embers = _interopRequire(_embers);
+var update = api(content, options);
-var _flat = __webpack_require__(142);
-exports.flat = _interopRequire(_flat);
-var _google = __webpack_require__(143);
+module.exports = content.locals || {};
-exports.google = _interopRequire(_google);
+/***/ }),
+/* 158 */
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
-var _grayscale = __webpack_require__(144);
+"use strict";
+__webpack_require__.r(__webpack_exports__);
+/* harmony import */ var _css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5);
+/* harmony import */ var _css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0__);
+// Imports
-exports.grayscale = _interopRequire(_grayscale);
+var ___CSS_LOADER_EXPORT___ = _css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default()(false);
+// Module
+___CSS_LOADER_EXPORT___.push([module.i, ".github-btn{font:bold 11px/14px 'Helvetica Neue', Helvetica, Arial, sans-serif;height:20px;overflow:hidden}.gh-btn,.gh-count,.gh-ico{float:left}.gh-btn,.gh-count{padding:2px 5px 2px 4px;color:#333;text-decoration:none;white-space:nowrap;cursor:pointer;border-radius:3px}.gh-btn{background-color:#eee;background-image:-webkit-gradient(linear, left top, left bottom, color-stop(0, #fcfcfc), color-stop(100%, #eee));background-image:-webkit-linear-gradient(top, #fcfcfc 0, #eee 100%);background-image:-moz-linear-gradient(top, #fcfcfc 0, #eee 100%);background-image:-ms-linear-gradient(top, #fcfcfc 0, #eee 100%);background-image:-o-linear-gradient(top, #fcfcfc 0, #eee 100%);background-image:linear-gradient(to bottom, #fcfcfc 0, #eee 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fcfcfc', endColorstr='#eeeeee', GradientType=0);background-repeat:no-repeat;border:1px solid #d5d5d5}.gh-btn:hover,.gh-btn:focus{text-decoration:none;background-color:#ddd;background-image:-webkit-gradient(linear, left top, left bottom, color-stop(0, #eee), color-stop(100%, #ddd));background-image:-webkit-linear-gradient(top, #eee 0, #ddd 100%);background-image:-moz-linear-gradient(top, #eee 0, #ddd 100%);background-image:-ms-linear-gradient(top, #eee 0, #ddd 100%);background-image:-o-linear-gradient(top, #eee 0, #ddd 100%);background-image:linear-gradient(to bottom, #eee 0, #ddd 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#eeeeee', endColorstr='#dddddd', GradientType=0);border-color:#ccc}.gh-btn:active{background-image:none;background-color:#dcdcdc;border-color:#b5b5b5;box-shadow:inset 0 2px 4px rgba(0,0,0,0.15)}.gh-ico{width:14px;height:14px;margin-right:4px;background-image:url(\"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB2ZXJzaW9uPSIxLjEiIGlkPSJMYXllcl8xIiB4PSIwcHgiIHk9IjBweCIgd2lkdGg9IjQwcHgiIGhlaWdodD0iNDBweCIgdmlld0JveD0iMTIgMTIgNDAgNDAiIGVuYWJsZS1iYWNrZ3JvdW5kPSJuZXcgMTIgMTIgNDAgNDAiIHhtbDpzcGFjZT0icHJlc2VydmUiPjxwYXRoIGZpbGw9IiMzMzMzMzMiIGQ9Ik0zMiAxMy40Yy0xMC41IDAtMTkgOC41LTE5IDE5YzAgOC40IDUuNSAxNS41IDEzIDE4YzEgMC4yIDEuMy0wLjQgMS4zLTAuOWMwLTAuNSAwLTEuNyAwLTMuMiBjLTUuMyAxLjEtNi40LTIuNi02LjQtMi42QzIwIDQxLjYgMTguOCA0MSAxOC44IDQxYy0xLjctMS4yIDAuMS0xLjEgMC4xLTEuMWMxLjkgMC4xIDIuOSAyIDIuOSAyYzEuNyAyLjkgNC41IDIuMSA1LjUgMS42IGMwLjItMS4yIDAuNy0yLjEgMS4yLTIuNmMtNC4yLTAuNS04LjctMi4xLTguNy05LjRjMC0yLjEgMC43LTMuNyAyLTUuMWMtMC4yLTAuNS0wLjgtMi40IDAuMi01YzAgMCAxLjYtMC41IDUuMiAyIGMxLjUtMC40IDMuMS0wLjcgNC44LTAuN2MxLjYgMCAzLjMgMC4yIDQuNyAwLjdjMy42LTIuNCA1LjItMiA1LjItMmMxIDIuNiAwLjQgNC42IDAuMiA1YzEuMiAxLjMgMiAzIDIgNS4xYzAgNy4zLTQuNSA4LjktOC43IDkuNCBjMC43IDAuNiAxLjMgMS43IDEuMyAzLjVjMCAyLjYgMCA0LjYgMCA1LjJjMCAwLjUgMC40IDEuMSAxLjMgMC45YzcuNS0yLjYgMTMtOS43IDEzLTE4LjFDNTEgMjEuOSA0Mi41IDEzLjQgMzIgMTMuNHoiLz48L3N2Zz4=\");background-size:100% 100%;background-repeat:no-repeat}.gh-count{position:relative;display:none;margin-left:4px;background-color:#fafafa;border:1px solid #d4d4d4}.gh-count:hover,.gh-count:focus{color:#4183C4}.gh-count:before,.gh-count:after{content:'';position:absolute;display:inline-block;width:0;height:0;border-color:transparent;border-style:solid}.gh-count:before{top:50%;left:-3px;margin-top:-4px;border-width:4px 4px 4px 0;border-right-color:#fafafa}.gh-count:after{top:50%;left:-4px;z-index:-1;margin-top:-5px;border-width:5px 5px 5px 0;border-right-color:#d4d4d4}.github-btn-large{height:30px}.github-btn-large .gh-btn,.github-btn-large .gh-count{padding:3px 10px 3px 8px;font-size:16px;line-height:22px;border-radius:4px}.github-btn-large .gh-ico{width:20px;height:20px}.github-btn-large .gh-count{margin-left:6px}.github-btn-large .gh-count:before{left:-5px;margin-top:-6px;border-width:6px 6px 6px 0}.github-btn-large .gh-count:after{left:-6px;margin-top:-7px;border-width:7px 7px 7px 0}\n", ""]);
+// Exports
+/* harmony default export */ __webpack_exports__["default"] = (___CSS_LOADER_EXPORT___);
-var _greenscreen = __webpack_require__(145);
-exports.greenscreen = _interopRequire(_greenscreen);
+/***/ }),
+/* 159 */
+/***/ (function(module, exports, __webpack_require__) {
-var _harmonic = __webpack_require__(146);
+var api = __webpack_require__(24);
+ var content = __webpack_require__(160);
-exports.harmonic = _interopRequire(_harmonic);
+ content = content.__esModule ? content.default : content;
-var _hopscotch = __webpack_require__(147);
+ if (typeof content === 'string') {
+ content = [[module.i, content, '']];
+ }
-exports.hopscotch = _interopRequire(_hopscotch);
+var options = {};
-var _isotope = __webpack_require__(148);
+options.insert = "head";
+options.singleton = false;
-exports.isotope = _interopRequire(_isotope);
+var update = api(content, options);
-var _marrakesh = __webpack_require__(149);
-exports.marrakesh = _interopRequire(_marrakesh);
-var _mocha = __webpack_require__(150);
+module.exports = content.locals || {};
-exports.mocha = _interopRequire(_mocha);
+/***/ }),
+/* 160 */
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
-var _monokai = __webpack_require__(151);
+"use strict";
+__webpack_require__.r(__webpack_exports__);
+/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5);
+/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0__);
+// Imports
-exports.monokai = _interopRequire(_monokai);
+var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default()(false);
+___CSS_LOADER_EXPORT___.push([module.i, "@import url(https://fonts.googleapis.com/css?family=Open+Sans);"]);
+// Module
+___CSS_LOADER_EXPORT___.push([module.i, "#mac-react-container{font-family:\"Open Sans\";padding:20px}#mac-react-container .header-1{font-size:28px;margin-right:5px;margin-bottom:3px}#mac-react-container .header-2{font-size:22px;margin-right:5px;margin-bottom:5px;font-style:italic}\n", ""]);
+// Exports
+/* harmony default export */ __webpack_exports__["default"] = (___CSS_LOADER_EXPORT___);
-var _ocean = __webpack_require__(152);
-exports.ocean = _interopRequire(_ocean);
+/***/ }),
+/* 161 */
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
-var _paraiso = __webpack_require__(153);
+"use strict";
+// ESM COMPAT FLAG
+__webpack_require__.r(__webpack_exports__);
-exports.paraiso = _interopRequire(_paraiso);
+// EXTERNAL MODULE: external "ReactDOM"
+var external_ReactDOM_ = __webpack_require__(9);
+var external_ReactDOM_default = /*#__PURE__*/__webpack_require__.n(external_ReactDOM_);
-var _pop = __webpack_require__(154);
+// CONCATENATED MODULE: ./node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/classCallCheck.js
+function _classCallCheck(instance, Constructor) {
+ if (!(instance instanceof Constructor)) {
+ throw new TypeError("Cannot call a class as a function");
+ }
+}
+// CONCATENATED MODULE: ./node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/createClass.js
+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);
+ }
+}
-exports.pop = _interopRequire(_pop);
+function _createClass(Constructor, protoProps, staticProps) {
+ if (protoProps) _defineProperties(Constructor.prototype, protoProps);
+ if (staticProps) _defineProperties(Constructor, staticProps);
+ return Constructor;
+}
+// CONCATENATED MODULE: ./node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js
+function _setPrototypeOf(o, p) {
+ _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) {
+ o.__proto__ = p;
+ return o;
+ };
-var _railscasts = __webpack_require__(155);
+ return _setPrototypeOf(o, p);
+}
+// CONCATENATED MODULE: ./node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/inherits.js
-exports.railscasts = _interopRequire(_railscasts);
+function _inherits(subClass, superClass) {
+ if (typeof superClass !== "function" && superClass !== null) {
+ throw new TypeError("Super expression must either be null or a function");
+ }
-var _shapeshifter = __webpack_require__(156);
+ subClass.prototype = Object.create(superClass && superClass.prototype, {
+ constructor: {
+ value: subClass,
+ writable: true,
+ configurable: true
+ }
+ });
+ if (superClass) _setPrototypeOf(subClass, superClass);
+}
+// CONCATENATED MODULE: ./node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/getPrototypeOf.js
+function _getPrototypeOf(o) {
+ _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) {
+ return o.__proto__ || Object.getPrototypeOf(o);
+ };
+ return _getPrototypeOf(o);
+}
+// CONCATENATED MODULE: ./node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/isNativeReflectConstruct.js
+function _isNativeReflectConstruct() {
+ if (typeof Reflect === "undefined" || !Reflect.construct) return false;
+ if (Reflect.construct.sham) return false;
+ if (typeof Proxy === "function") return true;
-exports.shapeshifter = _interopRequire(_shapeshifter);
+ try {
+ Date.prototype.toString.call(Reflect.construct(Date, [], function () {}));
+ return true;
+ } catch (e) {
+ return false;
+ }
+}
+// CONCATENATED MODULE: ./node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/typeof.js
+function _typeof(obj) {
+ "@babel/helpers - typeof";
-var _solarized = __webpack_require__(157);
+ if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") {
+ _typeof = function _typeof(obj) {
+ return typeof obj;
+ };
+ } else {
+ _typeof = function _typeof(obj) {
+ return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
+ };
+ }
-exports.solarized = _interopRequire(_solarized);
+ return _typeof(obj);
+}
+// CONCATENATED MODULE: ./node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/assertThisInitialized.js
+function _assertThisInitialized(self) {
+ if (self === void 0) {
+ throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
+ }
-var _summerfruit = __webpack_require__(158);
+ return self;
+}
+// CONCATENATED MODULE: ./node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/possibleConstructorReturn.js
-exports.summerfruit = _interopRequire(_summerfruit);
-var _tomorrow = __webpack_require__(159);
+function _possibleConstructorReturn(self, call) {
+ if (call && (_typeof(call) === "object" || typeof call === "function")) {
+ return call;
+ }
-exports.tomorrow = _interopRequire(_tomorrow);
+ return _assertThisInitialized(self);
+}
+// CONCATENATED MODULE: ./node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/createSuper.js
-var _tube = __webpack_require__(160);
-exports.tube = _interopRequire(_tube);
-var _twilight = __webpack_require__(161);
+function _createSuper(Derived) {
+ var hasNativeReflectConstruct = _isNativeReflectConstruct();
+ return function _createSuperInternal() {
+ var Super = _getPrototypeOf(Derived),
+ result;
-exports.twilight = _interopRequire(_twilight);
+ if (hasNativeReflectConstruct) {
+ var NewTarget = _getPrototypeOf(this).constructor;
+ result = Reflect.construct(Super, arguments, NewTarget);
+ } else {
+ result = Super.apply(this, arguments);
+ }
-/***/ }),
-/* 125 */
-/***/ (function(module, exports, __webpack_require__) {
+ return _possibleConstructorReturn(this, result);
+ };
+}
+// EXTERNAL MODULE: external "React"
+var external_React_ = __webpack_require__(0);
+var external_React_default = /*#__PURE__*/__webpack_require__.n(external_React_);
-"use strict";
+// EXTERNAL MODULE: ./node_modules/react-input-autosize/lib/AutosizeInput.js
+var AutosizeInput = __webpack_require__(50);
+var AutosizeInput_default = /*#__PURE__*/__webpack_require__.n(AutosizeInput);
+// EXTERNAL MODULE: ./node_modules/classnames/index.js
+var classnames = __webpack_require__(6);
+var classnames_default = /*#__PURE__*/__webpack_require__.n(classnames);
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'threezerotwofour',
- author: 'jan t. sott (http://github.com/idleberg)',
- base00: '#090300',
- base01: '#3a3432',
- base02: '#4a4543',
- base03: '#5c5855',
- base04: '#807d7c',
- base05: '#a5a2a2',
- base06: '#d6d5d4',
- base07: '#f7f7f7',
- base08: '#db2d20',
- base09: '#e8bbd0',
- base0A: '#fded02',
- base0B: '#01a252',
- base0C: '#b5e4f4',
- base0D: '#01a0e4',
- base0E: '#a16a94',
- base0F: '#cdab53'
-};
-module.exports = exports['default'];
+// EXTERNAL MODULE: ./node_modules/prop-types/index.js
+var prop_types = __webpack_require__(1);
+var prop_types_default = /*#__PURE__*/__webpack_require__.n(prop_types);
-/***/ }),
-/* 126 */
-/***/ (function(module, exports, __webpack_require__) {
+// CONCATENATED MODULE: ./node_modules/react-select/dist/react-select.es.js
-"use strict";
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'apathy',
- author: 'jannik siebert (https://github.com/janniks)',
- base00: '#031A16',
- base01: '#0B342D',
- base02: '#184E45',
- base03: '#2B685E',
- base04: '#5F9C92',
- base05: '#81B5AC',
- base06: '#A7CEC8',
- base07: '#D2E7E4',
- base08: '#3E9688',
- base09: '#3E7996',
- base0A: '#3E4C96',
- base0B: '#883E96',
- base0C: '#963E4C',
- base0D: '#96883E',
- base0E: '#4C963E',
- base0F: '#3E965B'
-};
-module.exports = exports['default'];
-/***/ }),
-/* 127 */
-/***/ (function(module, exports, __webpack_require__) {
-"use strict";
+var react_select_es_arrowRenderer = function arrowRenderer(_ref) {
+ var onMouseDown = _ref.onMouseDown;
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'ashes',
- author: 'jannik siebert (https://github.com/janniks)',
- base00: '#1C2023',
- base01: '#393F45',
- base02: '#565E65',
- base03: '#747C84',
- base04: '#ADB3BA',
- base05: '#C7CCD1',
- base06: '#DFE2E5',
- base07: '#F3F4F5',
- base08: '#C7AE95',
- base09: '#C7C795',
- base0A: '#AEC795',
- base0B: '#95C7AE',
- base0C: '#95AEC7',
- base0D: '#AE95C7',
- base0E: '#C795AE',
- base0F: '#C79595'
+ return external_React_default.a.createElement('span', {
+ className: 'Select-arrow',
+ onMouseDown: onMouseDown
+ });
};
-module.exports = exports['default'];
-/***/ }),
-/* 128 */
-/***/ (function(module, exports, __webpack_require__) {
+react_select_es_arrowRenderer.propTypes = {
+ onMouseDown: prop_types_default.a.func
+};
-"use strict";
+var react_select_es_clearRenderer = function clearRenderer() {
+ return external_React_default.a.createElement('span', {
+ className: 'Select-clear',
+ dangerouslySetInnerHTML: { __html: '×' }
+ });
+};
+var map = [{ 'base': 'A', 'letters': /[\u0041\u24B6\uFF21\u00C0\u00C1\u00C2\u1EA6\u1EA4\u1EAA\u1EA8\u00C3\u0100\u0102\u1EB0\u1EAE\u1EB4\u1EB2\u0226\u01E0\u00C4\u01DE\u1EA2\u00C5\u01FA\u01CD\u0200\u0202\u1EA0\u1EAC\u1EB6\u1E00\u0104\u023A\u2C6F]/g }, { 'base': 'AA', 'letters': /[\uA732]/g }, { 'base': 'AE', 'letters': /[\u00C6\u01FC\u01E2]/g }, { 'base': 'AO', 'letters': /[\uA734]/g }, { 'base': 'AU', 'letters': /[\uA736]/g }, { 'base': 'AV', 'letters': /[\uA738\uA73A]/g }, { 'base': 'AY', 'letters': /[\uA73C]/g }, { 'base': 'B', 'letters': /[\u0042\u24B7\uFF22\u1E02\u1E04\u1E06\u0243\u0182\u0181]/g }, { 'base': 'C', 'letters': /[\u0043\u24B8\uFF23\u0106\u0108\u010A\u010C\u00C7\u1E08\u0187\u023B\uA73E]/g }, { 'base': 'D', 'letters': /[\u0044\u24B9\uFF24\u1E0A\u010E\u1E0C\u1E10\u1E12\u1E0E\u0110\u018B\u018A\u0189\uA779]/g }, { 'base': 'DZ', 'letters': /[\u01F1\u01C4]/g }, { 'base': 'Dz', 'letters': /[\u01F2\u01C5]/g }, { 'base': 'E', 'letters': /[\u0045\u24BA\uFF25\u00C8\u00C9\u00CA\u1EC0\u1EBE\u1EC4\u1EC2\u1EBC\u0112\u1E14\u1E16\u0114\u0116\u00CB\u1EBA\u011A\u0204\u0206\u1EB8\u1EC6\u0228\u1E1C\u0118\u1E18\u1E1A\u0190\u018E]/g }, { 'base': 'F', 'letters': /[\u0046\u24BB\uFF26\u1E1E\u0191\uA77B]/g }, { 'base': 'G', 'letters': /[\u0047\u24BC\uFF27\u01F4\u011C\u1E20\u011E\u0120\u01E6\u0122\u01E4\u0193\uA7A0\uA77D\uA77E]/g }, { 'base': 'H', 'letters': /[\u0048\u24BD\uFF28\u0124\u1E22\u1E26\u021E\u1E24\u1E28\u1E2A\u0126\u2C67\u2C75\uA78D]/g }, { 'base': 'I', 'letters': /[\u0049\u24BE\uFF29\u00CC\u00CD\u00CE\u0128\u012A\u012C\u0130\u00CF\u1E2E\u1EC8\u01CF\u0208\u020A\u1ECA\u012E\u1E2C\u0197]/g }, { 'base': 'J', 'letters': /[\u004A\u24BF\uFF2A\u0134\u0248]/g }, { 'base': 'K', 'letters': /[\u004B\u24C0\uFF2B\u1E30\u01E8\u1E32\u0136\u1E34\u0198\u2C69\uA740\uA742\uA744\uA7A2]/g }, { 'base': 'L', 'letters': /[\u004C\u24C1\uFF2C\u013F\u0139\u013D\u1E36\u1E38\u013B\u1E3C\u1E3A\u0141\u023D\u2C62\u2C60\uA748\uA746\uA780]/g }, { 'base': 'LJ', 'letters': /[\u01C7]/g }, { 'base': 'Lj', 'letters': /[\u01C8]/g }, { 'base': 'M', 'letters': /[\u004D\u24C2\uFF2D\u1E3E\u1E40\u1E42\u2C6E\u019C]/g }, { 'base': 'N', 'letters': /[\u004E\u24C3\uFF2E\u01F8\u0143\u00D1\u1E44\u0147\u1E46\u0145\u1E4A\u1E48\u0220\u019D\uA790\uA7A4]/g }, { 'base': 'NJ', 'letters': /[\u01CA]/g }, { 'base': 'Nj', 'letters': /[\u01CB]/g }, { 'base': 'O', 'letters': /[\u004F\u24C4\uFF2F\u00D2\u00D3\u00D4\u1ED2\u1ED0\u1ED6\u1ED4\u00D5\u1E4C\u022C\u1E4E\u014C\u1E50\u1E52\u014E\u022E\u0230\u00D6\u022A\u1ECE\u0150\u01D1\u020C\u020E\u01A0\u1EDC\u1EDA\u1EE0\u1EDE\u1EE2\u1ECC\u1ED8\u01EA\u01EC\u00D8\u01FE\u0186\u019F\uA74A\uA74C]/g }, { 'base': 'OI', 'letters': /[\u01A2]/g }, { 'base': 'OO', 'letters': /[\uA74E]/g }, { 'base': 'OU', 'letters': /[\u0222]/g }, { 'base': 'P', 'letters': /[\u0050\u24C5\uFF30\u1E54\u1E56\u01A4\u2C63\uA750\uA752\uA754]/g }, { 'base': 'Q', 'letters': /[\u0051\u24C6\uFF31\uA756\uA758\u024A]/g }, { 'base': 'R', 'letters': /[\u0052\u24C7\uFF32\u0154\u1E58\u0158\u0210\u0212\u1E5A\u1E5C\u0156\u1E5E\u024C\u2C64\uA75A\uA7A6\uA782]/g }, { 'base': 'S', 'letters': /[\u0053\u24C8\uFF33\u1E9E\u015A\u1E64\u015C\u1E60\u0160\u1E66\u1E62\u1E68\u0218\u015E\u2C7E\uA7A8\uA784]/g }, { 'base': 'T', 'letters': /[\u0054\u24C9\uFF34\u1E6A\u0164\u1E6C\u021A\u0162\u1E70\u1E6E\u0166\u01AC\u01AE\u023E\uA786]/g }, { 'base': 'TZ', 'letters': /[\uA728]/g }, { 'base': 'U', 'letters': /[\u0055\u24CA\uFF35\u00D9\u00DA\u00DB\u0168\u1E78\u016A\u1E7A\u016C\u00DC\u01DB\u01D7\u01D5\u01D9\u1EE6\u016E\u0170\u01D3\u0214\u0216\u01AF\u1EEA\u1EE8\u1EEE\u1EEC\u1EF0\u1EE4\u1E72\u0172\u1E76\u1E74\u0244]/g }, { 'base': 'V', 'letters': /[\u0056\u24CB\uFF36\u1E7C\u1E7E\u01B2\uA75E\u0245]/g }, { 'base': 'VY', 'letters': /[\uA760]/g }, { 'base': 'W', 'letters': /[\u0057\u24CC\uFF37\u1E80\u1E82\u0174\u1E86\u1E84\u1E88\u2C72]/g }, { 'base': 'X', 'letters': /[\u0058\u24CD\uFF38\u1E8A\u1E8C]/g }, { 'base': 'Y', 'letters': /[\u0059\u24CE\uFF39\u1EF2\u00DD\u0176\u1EF8\u0232\u1E8E\u0178\u1EF6\u1EF4\u01B3\u024E\u1EFE]/g }, { 'base': 'Z', 'letters': /[\u005A\u24CF\uFF3A\u0179\u1E90\u017B\u017D\u1E92\u1E94\u01B5\u0224\u2C7F\u2C6B\uA762]/g }, { 'base': 'a', 'letters': /[\u0061\u24D0\uFF41\u1E9A\u00E0\u00E1\u00E2\u1EA7\u1EA5\u1EAB\u1EA9\u00E3\u0101\u0103\u1EB1\u1EAF\u1EB5\u1EB3\u0227\u01E1\u00E4\u01DF\u1EA3\u00E5\u01FB\u01CE\u0201\u0203\u1EA1\u1EAD\u1EB7\u1E01\u0105\u2C65\u0250]/g }, { 'base': 'aa', 'letters': /[\uA733]/g }, { 'base': 'ae', 'letters': /[\u00E6\u01FD\u01E3]/g }, { 'base': 'ao', 'letters': /[\uA735]/g }, { 'base': 'au', 'letters': /[\uA737]/g }, { 'base': 'av', 'letters': /[\uA739\uA73B]/g }, { 'base': 'ay', 'letters': /[\uA73D]/g }, { 'base': 'b', 'letters': /[\u0062\u24D1\uFF42\u1E03\u1E05\u1E07\u0180\u0183\u0253]/g }, { 'base': 'c', 'letters': /[\u0063\u24D2\uFF43\u0107\u0109\u010B\u010D\u00E7\u1E09\u0188\u023C\uA73F\u2184]/g }, { 'base': 'd', 'letters': /[\u0064\u24D3\uFF44\u1E0B\u010F\u1E0D\u1E11\u1E13\u1E0F\u0111\u018C\u0256\u0257\uA77A]/g }, { 'base': 'dz', 'letters': /[\u01F3\u01C6]/g }, { 'base': 'e', 'letters': /[\u0065\u24D4\uFF45\u00E8\u00E9\u00EA\u1EC1\u1EBF\u1EC5\u1EC3\u1EBD\u0113\u1E15\u1E17\u0115\u0117\u00EB\u1EBB\u011B\u0205\u0207\u1EB9\u1EC7\u0229\u1E1D\u0119\u1E19\u1E1B\u0247\u025B\u01DD]/g }, { 'base': 'f', 'letters': /[\u0066\u24D5\uFF46\u1E1F\u0192\uA77C]/g }, { 'base': 'g', 'letters': /[\u0067\u24D6\uFF47\u01F5\u011D\u1E21\u011F\u0121\u01E7\u0123\u01E5\u0260\uA7A1\u1D79\uA77F]/g }, { 'base': 'h', 'letters': /[\u0068\u24D7\uFF48\u0125\u1E23\u1E27\u021F\u1E25\u1E29\u1E2B\u1E96\u0127\u2C68\u2C76\u0265]/g }, { 'base': 'hv', 'letters': /[\u0195]/g }, { 'base': 'i', 'letters': /[\u0069\u24D8\uFF49\u00EC\u00ED\u00EE\u0129\u012B\u012D\u00EF\u1E2F\u1EC9\u01D0\u0209\u020B\u1ECB\u012F\u1E2D\u0268\u0131]/g }, { 'base': 'j', 'letters': /[\u006A\u24D9\uFF4A\u0135\u01F0\u0249]/g }, { 'base': 'k', 'letters': /[\u006B\u24DA\uFF4B\u1E31\u01E9\u1E33\u0137\u1E35\u0199\u2C6A\uA741\uA743\uA745\uA7A3]/g }, { 'base': 'l', 'letters': /[\u006C\u24DB\uFF4C\u0140\u013A\u013E\u1E37\u1E39\u013C\u1E3D\u1E3B\u017F\u0142\u019A\u026B\u2C61\uA749\uA781\uA747]/g }, { 'base': 'lj', 'letters': /[\u01C9]/g }, { 'base': 'm', 'letters': /[\u006D\u24DC\uFF4D\u1E3F\u1E41\u1E43\u0271\u026F]/g }, { 'base': 'n', 'letters': /[\u006E\u24DD\uFF4E\u01F9\u0144\u00F1\u1E45\u0148\u1E47\u0146\u1E4B\u1E49\u019E\u0272\u0149\uA791\uA7A5]/g }, { 'base': 'nj', 'letters': /[\u01CC]/g }, { 'base': 'o', 'letters': /[\u006F\u24DE\uFF4F\u00F2\u00F3\u00F4\u1ED3\u1ED1\u1ED7\u1ED5\u00F5\u1E4D\u022D\u1E4F\u014D\u1E51\u1E53\u014F\u022F\u0231\u00F6\u022B\u1ECF\u0151\u01D2\u020D\u020F\u01A1\u1EDD\u1EDB\u1EE1\u1EDF\u1EE3\u1ECD\u1ED9\u01EB\u01ED\u00F8\u01FF\u0254\uA74B\uA74D\u0275]/g }, { 'base': 'oi', 'letters': /[\u01A3]/g }, { 'base': 'ou', 'letters': /[\u0223]/g }, { 'base': 'oo', 'letters': /[\uA74F]/g }, { 'base': 'p', 'letters': /[\u0070\u24DF\uFF50\u1E55\u1E57\u01A5\u1D7D\uA751\uA753\uA755]/g }, { 'base': 'q', 'letters': /[\u0071\u24E0\uFF51\u024B\uA757\uA759]/g }, { 'base': 'r', 'letters': /[\u0072\u24E1\uFF52\u0155\u1E59\u0159\u0211\u0213\u1E5B\u1E5D\u0157\u1E5F\u024D\u027D\uA75B\uA7A7\uA783]/g }, { 'base': 's', 'letters': /[\u0073\u24E2\uFF53\u00DF\u015B\u1E65\u015D\u1E61\u0161\u1E67\u1E63\u1E69\u0219\u015F\u023F\uA7A9\uA785\u1E9B]/g }, { 'base': 't', 'letters': /[\u0074\u24E3\uFF54\u1E6B\u1E97\u0165\u1E6D\u021B\u0163\u1E71\u1E6F\u0167\u01AD\u0288\u2C66\uA787]/g }, { 'base': 'tz', 'letters': /[\uA729]/g }, { 'base': 'u', 'letters': /[\u0075\u24E4\uFF55\u00F9\u00FA\u00FB\u0169\u1E79\u016B\u1E7B\u016D\u00FC\u01DC\u01D8\u01D6\u01DA\u1EE7\u016F\u0171\u01D4\u0215\u0217\u01B0\u1EEB\u1EE9\u1EEF\u1EED\u1EF1\u1EE5\u1E73\u0173\u1E77\u1E75\u0289]/g }, { 'base': 'v', 'letters': /[\u0076\u24E5\uFF56\u1E7D\u1E7F\u028B\uA75F\u028C]/g }, { 'base': 'vy', 'letters': /[\uA761]/g }, { 'base': 'w', 'letters': /[\u0077\u24E6\uFF57\u1E81\u1E83\u0175\u1E87\u1E85\u1E98\u1E89\u2C73]/g }, { 'base': 'x', 'letters': /[\u0078\u24E7\uFF58\u1E8B\u1E8D]/g }, { 'base': 'y', 'letters': /[\u0079\u24E8\uFF59\u1EF3\u00FD\u0177\u1EF9\u0233\u1E8F\u00FF\u1EF7\u1E99\u1EF5\u01B4\u024F\u1EFF]/g }, { 'base': 'z', 'letters': /[\u007A\u24E9\uFF5A\u017A\u1E91\u017C\u017E\u1E93\u1E95\u01B6\u0225\u0240\u2C6C\uA763]/g }];
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'atelier dune',
- author: 'bram de haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/dune)',
- base00: '#20201d',
- base01: '#292824',
- base02: '#6e6b5e',
- base03: '#7d7a68',
- base04: '#999580',
- base05: '#a6a28c',
- base06: '#e8e4cf',
- base07: '#fefbec',
- base08: '#d73737',
- base09: '#b65611',
- base0A: '#cfb017',
- base0B: '#60ac39',
- base0C: '#1fad83',
- base0D: '#6684e1',
- base0E: '#b854d4',
- base0F: '#d43552'
+var stripDiacritics = function stripDiacritics(str) {
+ for (var i = 0; i < map.length; i++) {
+ str = str.replace(map[i].letters, map[i].base);
+ }
+ return str;
};
-module.exports = exports['default'];
-/***/ }),
-/* 129 */
-/***/ (function(module, exports, __webpack_require__) {
+var trim = function trim(str) {
+ return str.replace(/^\s+|\s+$/g, '');
+};
-"use strict";
+var react_select_es_isValid = function isValid(value) {
+ return typeof value !== 'undefined' && value !== null && value !== '';
+};
+var filterOptions = function filterOptions(options, filterValue, excludeOptions, props) {
+ if (props.ignoreAccents) {
+ filterValue = stripDiacritics(filterValue);
+ }
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'atelier forest',
- author: 'bram de haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/forest)',
- base00: '#1b1918',
- base01: '#2c2421',
- base02: '#68615e',
- base03: '#766e6b',
- base04: '#9c9491',
- base05: '#a8a19f',
- base06: '#e6e2e0',
- base07: '#f1efee',
- base08: '#f22c40',
- base09: '#df5320',
- base0A: '#d5911a',
- base0B: '#5ab738',
- base0C: '#00ad9c',
- base0D: '#407ee7',
- base0E: '#6666ea',
- base0F: '#c33ff3'
-};
-module.exports = exports['default'];
+ if (props.ignoreCase) {
+ filterValue = filterValue.toLowerCase();
+ }
-/***/ }),
-/* 130 */
-/***/ (function(module, exports, __webpack_require__) {
+ if (props.trimFilter) {
+ filterValue = trim(filterValue);
+ }
-"use strict";
+ if (excludeOptions) excludeOptions = excludeOptions.map(function (i) {
+ return i[props.valueKey];
+ });
+ return options.filter(function (option) {
+ if (excludeOptions && excludeOptions.indexOf(option[props.valueKey]) > -1) return false;
+ if (props.filterOption) return props.filterOption.call(undefined, option, filterValue);
+ if (!filterValue) return true;
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'atelier heath',
- author: 'bram de haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/heath)',
- base00: '#1b181b',
- base01: '#292329',
- base02: '#695d69',
- base03: '#776977',
- base04: '#9e8f9e',
- base05: '#ab9bab',
- base06: '#d8cad8',
- base07: '#f7f3f7',
- base08: '#ca402b',
- base09: '#a65926',
- base0A: '#bb8a35',
- base0B: '#379a37',
- base0C: '#159393',
- base0D: '#516aec',
- base0E: '#7b59c0',
- base0F: '#cc33cc'
-};
-module.exports = exports['default'];
-
-/***/ }),
-/* 131 */
-/***/ (function(module, exports, __webpack_require__) {
-
-"use strict";
-
+ var value = option[props.valueKey];
+ var label = option[props.labelKey];
+ var hasValue = react_select_es_isValid(value);
+ var hasLabel = react_select_es_isValid(label);
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'atelier lakeside',
- author: 'bram de haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/lakeside/)',
- base00: '#161b1d',
- base01: '#1f292e',
- base02: '#516d7b',
- base03: '#5a7b8c',
- base04: '#7195a8',
- base05: '#7ea2b4',
- base06: '#c1e4f6',
- base07: '#ebf8ff',
- base08: '#d22d72',
- base09: '#935c25',
- base0A: '#8a8a0f',
- base0B: '#568c3b',
- base0C: '#2d8f6f',
- base0D: '#257fad',
- base0E: '#5d5db1',
- base0F: '#b72dd2'
-};
-module.exports = exports['default'];
+ if (!hasValue && !hasLabel) {
+ return false;
+ }
-/***/ }),
-/* 132 */
-/***/ (function(module, exports, __webpack_require__) {
+ var valueTest = hasValue ? String(value) : null;
+ var labelTest = hasLabel ? String(label) : null;
-"use strict";
+ if (props.ignoreAccents) {
+ if (valueTest && props.matchProp !== 'label') valueTest = stripDiacritics(valueTest);
+ if (labelTest && props.matchProp !== 'value') labelTest = stripDiacritics(labelTest);
+ }
+ if (props.ignoreCase) {
+ if (valueTest && props.matchProp !== 'label') valueTest = valueTest.toLowerCase();
+ if (labelTest && props.matchProp !== 'value') labelTest = labelTest.toLowerCase();
+ }
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'atelier seaside',
- author: 'bram de haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/seaside/)',
- base00: '#131513',
- base01: '#242924',
- base02: '#5e6e5e',
- base03: '#687d68',
- base04: '#809980',
- base05: '#8ca68c',
- base06: '#cfe8cf',
- base07: '#f0fff0',
- base08: '#e6193c',
- base09: '#87711d',
- base0A: '#c3c322',
- base0B: '#29a329',
- base0C: '#1999b3',
- base0D: '#3d62f5',
- base0E: '#ad2bee',
- base0F: '#e619c3'
+ return props.matchPos === 'start' ? valueTest && props.matchProp !== 'label' && valueTest.substr(0, filterValue.length) === filterValue || labelTest && props.matchProp !== 'value' && labelTest.substr(0, filterValue.length) === filterValue : valueTest && props.matchProp !== 'label' && valueTest.indexOf(filterValue) >= 0 || labelTest && props.matchProp !== 'value' && labelTest.indexOf(filterValue) >= 0;
+ });
};
-module.exports = exports['default'];
-/***/ }),
-/* 133 */
-/***/ (function(module, exports, __webpack_require__) {
+var react_select_es_menuRenderer = function menuRenderer(_ref) {
+ var focusedOption = _ref.focusedOption,
+ focusOption = _ref.focusOption,
+ inputValue = _ref.inputValue,
+ instancePrefix = _ref.instancePrefix,
+ onFocus = _ref.onFocus,
+ onOptionRef = _ref.onOptionRef,
+ onSelect = _ref.onSelect,
+ optionClassName = _ref.optionClassName,
+ optionComponent = _ref.optionComponent,
+ optionRenderer = _ref.optionRenderer,
+ options = _ref.options,
+ removeValue = _ref.removeValue,
+ selectValue = _ref.selectValue,
+ valueArray = _ref.valueArray,
+ valueKey = _ref.valueKey;
-"use strict";
+ var Option = optionComponent;
+ return options.map(function (option, i) {
+ var isSelected = valueArray && valueArray.some(function (x) {
+ return x[valueKey] === option[valueKey];
+ });
+ var isFocused = option === focusedOption;
+ var optionClass = classnames_default()(optionClassName, {
+ 'Select-option': true,
+ 'is-selected': isSelected,
+ 'is-focused': isFocused,
+ 'is-disabled': option.disabled
+ });
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'bespin',
- author: 'jan t. sott',
- base00: '#28211c',
- base01: '#36312e',
- base02: '#5e5d5c',
- base03: '#666666',
- base04: '#797977',
- base05: '#8a8986',
- base06: '#9d9b97',
- base07: '#baae9e',
- base08: '#cf6a4c',
- base09: '#cf7d34',
- base0A: '#f9ee98',
- base0B: '#54be0d',
- base0C: '#afc4db',
- base0D: '#5ea6ea',
- base0E: '#9b859d',
- base0F: '#937121'
+ return external_React_default.a.createElement(
+ Option,
+ {
+ className: optionClass,
+ focusOption: focusOption,
+ inputValue: inputValue,
+ instancePrefix: instancePrefix,
+ isDisabled: option.disabled,
+ isFocused: isFocused,
+ isSelected: isSelected,
+ key: 'option-' + i + '-' + option[valueKey],
+ onFocus: onFocus,
+ onSelect: onSelect,
+ option: option,
+ optionIndex: i,
+ ref: function ref(_ref2) {
+ onOptionRef(_ref2, isFocused);
+ },
+ removeValue: removeValue,
+ selectValue: selectValue
+ },
+ optionRenderer(option, i, inputValue)
+ );
+ });
};
-module.exports = exports['default'];
-
-/***/ }),
-/* 134 */
-/***/ (function(module, exports, __webpack_require__) {
-"use strict";
+react_select_es_menuRenderer.propTypes = {
+ focusOption: prop_types_default.a.func,
+ focusedOption: prop_types_default.a.object,
+ inputValue: prop_types_default.a.string,
+ instancePrefix: prop_types_default.a.string,
+ onFocus: prop_types_default.a.func,
+ onOptionRef: prop_types_default.a.func,
+ onSelect: prop_types_default.a.func,
+ optionClassName: prop_types_default.a.string,
+ optionComponent: prop_types_default.a.func,
+ optionRenderer: prop_types_default.a.func,
+ options: prop_types_default.a.array,
+ removeValue: prop_types_default.a.func,
+ selectValue: prop_types_default.a.func,
+ valueArray: prop_types_default.a.array,
+ valueKey: prop_types_default.a.string
+};
+var blockEvent = (function (event) {
+ event.preventDefault();
+ event.stopPropagation();
+ if (event.target.tagName !== 'A' || !('href' in event.target)) {
+ return;
+ }
+ if (event.target.target) {
+ window.open(event.target.href, event.target.target);
+ } else {
+ window.location.href = event.target.href;
+ }
+});
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'brewer',
- author: 'timothée poisot (http://github.com/tpoisot)',
- base00: '#0c0d0e',
- base01: '#2e2f30',
- base02: '#515253',
- base03: '#737475',
- base04: '#959697',
- base05: '#b7b8b9',
- base06: '#dadbdc',
- base07: '#fcfdfe',
- base08: '#e31a1c',
- base09: '#e6550d',
- base0A: '#dca060',
- base0B: '#31a354',
- base0C: '#80b1d3',
- base0D: '#3182bd',
- base0E: '#756bb1',
- base0F: '#b15928'
+var react_select_es_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;
};
-module.exports = exports['default'];
-/***/ }),
-/* 135 */
-/***/ (function(module, exports, __webpack_require__) {
-"use strict";
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'bright',
- author: 'chris kempson (http://chriskempson.com)',
- base00: '#000000',
- base01: '#303030',
- base02: '#505050',
- base03: '#b0b0b0',
- base04: '#d0d0d0',
- base05: '#e0e0e0',
- base06: '#f5f5f5',
- base07: '#ffffff',
- base08: '#fb0120',
- base09: '#fc6d24',
- base0A: '#fda331',
- base0B: '#a1c659',
- base0C: '#76c7b7',
- base0D: '#6fb3d2',
- base0E: '#d381c3',
- base0F: '#be643c'
-};
-module.exports = exports['default'];
-/***/ }),
-/* 136 */
-/***/ (function(module, exports, __webpack_require__) {
+var asyncGenerator = function () {
+ function AwaitValue(value) {
+ this.value = value;
+ }
-"use strict";
+ function AsyncGenerator(gen) {
+ var front, back;
+ function send(key, arg) {
+ return new Promise(function (resolve, reject) {
+ var request = {
+ key: key,
+ arg: arg,
+ resolve: resolve,
+ reject: reject,
+ next: null
+ };
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'chalk',
- author: 'chris kempson (http://chriskempson.com)',
- base00: '#151515',
- base01: '#202020',
- base02: '#303030',
- base03: '#505050',
- base04: '#b0b0b0',
- base05: '#d0d0d0',
- base06: '#e0e0e0',
- base07: '#f5f5f5',
- base08: '#fb9fb1',
- base09: '#eda987',
- base0A: '#ddb26f',
- base0B: '#acc267',
- base0C: '#12cfc0',
- base0D: '#6fc2ef',
- base0E: '#e1a3ee',
- base0F: '#deaf8f'
-};
-module.exports = exports['default'];
-
-/***/ }),
-/* 137 */
-/***/ (function(module, exports, __webpack_require__) {
+ if (back) {
+ back = back.next = request;
+ } else {
+ front = back = request;
+ resume(key, arg);
+ }
+ });
+ }
-"use strict";
+ function resume(key, arg) {
+ try {
+ var result = gen[key](arg);
+ var value = result.value;
+ if (value instanceof AwaitValue) {
+ Promise.resolve(value.value).then(function (arg) {
+ resume("next", arg);
+ }, function (arg) {
+ resume("throw", arg);
+ });
+ } else {
+ settle(result.done ? "return" : "normal", result.value);
+ }
+ } catch (err) {
+ settle("throw", err);
+ }
+ }
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'codeschool',
- author: 'brettof86',
- base00: '#232c31',
- base01: '#1c3657',
- base02: '#2a343a',
- base03: '#3f4944',
- base04: '#84898c',
- base05: '#9ea7a6',
- base06: '#a7cfa3',
- base07: '#b5d8f6',
- base08: '#2a5491',
- base09: '#43820d',
- base0A: '#a03b1e',
- base0B: '#237986',
- base0C: '#b02f30',
- base0D: '#484d79',
- base0E: '#c59820',
- base0F: '#c98344'
-};
-module.exports = exports['default'];
+ function settle(type, value) {
+ switch (type) {
+ case "return":
+ front.resolve({
+ value: value,
+ done: true
+ });
+ break;
-/***/ }),
-/* 138 */
-/***/ (function(module, exports, __webpack_require__) {
+ case "throw":
+ front.reject(value);
+ break;
-"use strict";
+ default:
+ front.resolve({
+ value: value,
+ done: false
+ });
+ break;
+ }
+ front = front.next;
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'colors',
- author: 'mrmrs (http://clrs.cc)',
- base00: '#111111',
- base01: '#333333',
- base02: '#555555',
- base03: '#777777',
- base04: '#999999',
- base05: '#bbbbbb',
- base06: '#dddddd',
- base07: '#ffffff',
- base08: '#ff4136',
- base09: '#ff851b',
- base0A: '#ffdc00',
- base0B: '#2ecc40',
- base0C: '#7fdbff',
- base0D: '#0074d9',
- base0E: '#b10dc9',
- base0F: '#85144b'
-};
-module.exports = exports['default'];
+ if (front) {
+ resume(front.key, front.arg);
+ } else {
+ back = null;
+ }
+ }
-/***/ }),
-/* 139 */
-/***/ (function(module, exports, __webpack_require__) {
+ this._invoke = send;
-"use strict";
+ if (typeof gen.return !== "function") {
+ this.return = undefined;
+ }
+ }
+ if (typeof Symbol === "function" && Symbol.asyncIterator) {
+ AsyncGenerator.prototype[Symbol.asyncIterator] = function () {
+ return this;
+ };
+ }
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'default',
- author: 'chris kempson (http://chriskempson.com)',
- base00: '#181818',
- base01: '#282828',
- base02: '#383838',
- base03: '#585858',
- base04: '#b8b8b8',
- base05: '#d8d8d8',
- base06: '#e8e8e8',
- base07: '#f8f8f8',
- base08: '#ab4642',
- base09: '#dc9656',
- base0A: '#f7ca88',
- base0B: '#a1b56c',
- base0C: '#86c1b9',
- base0D: '#7cafc2',
- base0E: '#ba8baf',
- base0F: '#a16946'
-};
-module.exports = exports['default'];
+ AsyncGenerator.prototype.next = function (arg) {
+ return this._invoke("next", arg);
+ };
-/***/ }),
-/* 140 */
-/***/ (function(module, exports, __webpack_require__) {
+ AsyncGenerator.prototype.throw = function (arg) {
+ return this._invoke("throw", arg);
+ };
-"use strict";
+ AsyncGenerator.prototype.return = function (arg) {
+ return this._invoke("return", arg);
+ };
+ return {
+ wrap: function (fn) {
+ return function () {
+ return new AsyncGenerator(fn.apply(this, arguments));
+ };
+ },
+ await: function (value) {
+ return new AwaitValue(value);
+ }
+ };
+}();
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'eighties',
- author: 'chris kempson (http://chriskempson.com)',
- base00: '#2d2d2d',
- base01: '#393939',
- base02: '#515151',
- base03: '#747369',
- base04: '#a09f93',
- base05: '#d3d0c8',
- base06: '#e8e6df',
- base07: '#f2f0ec',
- base08: '#f2777a',
- base09: '#f99157',
- base0A: '#ffcc66',
- base0B: '#99cc99',
- base0C: '#66cccc',
- base0D: '#6699cc',
- base0E: '#cc99cc',
- base0F: '#d27b53'
-};
-module.exports = exports['default'];
-/***/ }),
-/* 141 */
-/***/ (function(module, exports, __webpack_require__) {
-"use strict";
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'embers',
- author: 'jannik siebert (https://github.com/janniks)',
- base00: '#16130F',
- base01: '#2C2620',
- base02: '#433B32',
- base03: '#5A5047',
- base04: '#8A8075',
- base05: '#A39A90',
- base06: '#BEB6AE',
- base07: '#DBD6D1',
- base08: '#826D57',
- base09: '#828257',
- base0A: '#6D8257',
- base0B: '#57826D',
- base0C: '#576D82',
- base0D: '#6D5782',
- base0E: '#82576D',
- base0F: '#825757'
+var classCallCheck = function (instance, Constructor) {
+ if (!(instance instanceof Constructor)) {
+ throw new TypeError("Cannot call a class as a function");
+ }
};
-module.exports = exports['default'];
-/***/ }),
-/* 142 */
-/***/ (function(module, exports, __webpack_require__) {
+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);
+ }
+ }
-"use strict";
+ return function (Constructor, protoProps, staticProps) {
+ if (protoProps) defineProperties(Constructor.prototype, protoProps);
+ if (staticProps) defineProperties(Constructor, staticProps);
+ return Constructor;
+ };
+}();
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'flat',
- author: 'chris kempson (http://chriskempson.com)',
- base00: '#2C3E50',
- base01: '#34495E',
- base02: '#7F8C8D',
- base03: '#95A5A6',
- base04: '#BDC3C7',
- base05: '#e0e0e0',
- base06: '#f5f5f5',
- base07: '#ECF0F1',
- base08: '#E74C3C',
- base09: '#E67E22',
- base0A: '#F1C40F',
- base0B: '#2ECC71',
- base0C: '#1ABC9C',
- base0D: '#3498DB',
- base0E: '#9B59B6',
- base0F: '#be643c'
-};
-module.exports = exports['default'];
-/***/ }),
-/* 143 */
-/***/ (function(module, exports, __webpack_require__) {
-"use strict";
+var defineProperty = function (obj, key, value) {
+ if (key in obj) {
+ Object.defineProperty(obj, key, {
+ value: value,
+ enumerable: true,
+ configurable: true,
+ writable: true
+ });
+ } else {
+ obj[key] = value;
+ }
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'google',
- author: 'seth wright (http://sethawright.com)',
- base00: '#1d1f21',
- base01: '#282a2e',
- base02: '#373b41',
- base03: '#969896',
- base04: '#b4b7b4',
- base05: '#c5c8c6',
- base06: '#e0e0e0',
- base07: '#ffffff',
- base08: '#CC342B',
- base09: '#F96A38',
- base0A: '#FBA922',
- base0B: '#198844',
- base0C: '#3971ED',
- base0D: '#3971ED',
- base0E: '#A36AC7',
- base0F: '#3971ED'
+ return obj;
};
-module.exports = exports['default'];
-
-/***/ }),
-/* 144 */
-/***/ (function(module, exports, __webpack_require__) {
-"use strict";
+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];
+ }
+ }
+ }
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'grayscale',
- author: 'alexandre gavioli (https://github.com/alexx2/)',
- base00: '#101010',
- base01: '#252525',
- base02: '#464646',
- base03: '#525252',
- base04: '#ababab',
- base05: '#b9b9b9',
- base06: '#e3e3e3',
- base07: '#f7f7f7',
- base08: '#7c7c7c',
- base09: '#999999',
- base0A: '#a0a0a0',
- base0B: '#8e8e8e',
- base0C: '#868686',
- base0D: '#686868',
- base0E: '#747474',
- base0F: '#5e5e5e'
+ return target;
};
-module.exports = exports['default'];
-/***/ }),
-/* 145 */
-/***/ (function(module, exports, __webpack_require__) {
-"use strict";
+var inherits = function (subClass, superClass) {
+ if (typeof superClass !== "function" && superClass !== null) {
+ throw new TypeError("Super expression must either be null or a function, not " + typeof superClass);
+ }
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'green screen',
- author: 'chris kempson (http://chriskempson.com)',
- base00: '#001100',
- base01: '#003300',
- base02: '#005500',
- base03: '#007700',
- base04: '#009900',
- base05: '#00bb00',
- base06: '#00dd00',
- base07: '#00ff00',
- base08: '#007700',
- base09: '#009900',
- base0A: '#007700',
- base0B: '#00bb00',
- base0C: '#005500',
- base0D: '#009900',
- base0E: '#00bb00',
- base0F: '#005500'
+ 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;
};
-module.exports = exports['default'];
-
-/***/ }),
-/* 146 */
-/***/ (function(module, exports, __webpack_require__) {
-"use strict";
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'harmonic16',
- author: 'jannik siebert (https://github.com/janniks)',
- base00: '#0b1c2c',
- base01: '#223b54',
- base02: '#405c79',
- base03: '#627e99',
- base04: '#aabcce',
- base05: '#cbd6e2',
- base06: '#e5ebf1',
- base07: '#f7f9fb',
- base08: '#bf8b56',
- base09: '#bfbf56',
- base0A: '#8bbf56',
- base0B: '#56bf8b',
- base0C: '#568bbf',
- base0D: '#8b56bf',
- base0E: '#bf568b',
- base0F: '#bf5656'
-};
-module.exports = exports['default'];
-/***/ }),
-/* 147 */
-/***/ (function(module, exports, __webpack_require__) {
-"use strict";
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'hopscotch',
- author: 'jan t. sott',
- base00: '#322931',
- base01: '#433b42',
- base02: '#5c545b',
- base03: '#797379',
- base04: '#989498',
- base05: '#b9b5b8',
- base06: '#d5d3d5',
- base07: '#ffffff',
- base08: '#dd464c',
- base09: '#fd8b19',
- base0A: '#fdcc59',
- base0B: '#8fc13e',
- base0C: '#149b93',
- base0D: '#1290bf',
- base0E: '#c85e7c',
- base0F: '#b33508'
-};
-module.exports = exports['default'];
-/***/ }),
-/* 148 */
-/***/ (function(module, exports, __webpack_require__) {
-"use strict";
+var objectWithoutProperties = function (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];
+ }
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'isotope',
- author: 'jan t. sott',
- base00: '#000000',
- base01: '#404040',
- base02: '#606060',
- base03: '#808080',
- base04: '#c0c0c0',
- base05: '#d0d0d0',
- base06: '#e0e0e0',
- base07: '#ffffff',
- base08: '#ff0000',
- base09: '#ff9900',
- base0A: '#ff0099',
- base0B: '#33ff00',
- base0C: '#00ffff',
- base0D: '#0066ff',
- base0E: '#cc00ff',
- base0F: '#3300ff'
+ return target;
};
-module.exports = exports['default'];
-
-/***/ }),
-/* 149 */
-/***/ (function(module, exports, __webpack_require__) {
-
-"use strict";
+var possibleConstructorReturn = function (self, call) {
+ if (!self) {
+ throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
+ }
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'marrakesh',
- author: 'alexandre gavioli (http://github.com/alexx2/)',
- base00: '#201602',
- base01: '#302e00',
- base02: '#5f5b17',
- base03: '#6c6823',
- base04: '#86813b',
- base05: '#948e48',
- base06: '#ccc37a',
- base07: '#faf0a5',
- base08: '#c35359',
- base09: '#b36144',
- base0A: '#a88339',
- base0B: '#18974e',
- base0C: '#75a738',
- base0D: '#477ca1',
- base0E: '#8868b3',
- base0F: '#b3588e'
+ return call && (typeof call === "object" || typeof call === "function") ? call : self;
};
-module.exports = exports['default'];
-/***/ }),
-/* 150 */
-/***/ (function(module, exports, __webpack_require__) {
+var react_select_es_Option = function (_React$Component) {
+ inherits(Option, _React$Component);
-"use strict";
+ function Option(props) {
+ classCallCheck(this, Option);
+ var _this = possibleConstructorReturn(this, (Option.__proto__ || Object.getPrototypeOf(Option)).call(this, props));
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'mocha',
- author: 'chris kempson (http://chriskempson.com)',
- base00: '#3B3228',
- base01: '#534636',
- base02: '#645240',
- base03: '#7e705a',
- base04: '#b8afad',
- base05: '#d0c8c6',
- base06: '#e9e1dd',
- base07: '#f5eeeb',
- base08: '#cb6077',
- base09: '#d28b71',
- base0A: '#f4bc87',
- base0B: '#beb55b',
- base0C: '#7bbda4',
- base0D: '#8ab3b5',
- base0E: '#a89bb9',
- base0F: '#bb9584'
-};
-module.exports = exports['default'];
+ _this.handleMouseDown = _this.handleMouseDown.bind(_this);
+ _this.handleMouseEnter = _this.handleMouseEnter.bind(_this);
+ _this.handleMouseMove = _this.handleMouseMove.bind(_this);
+ _this.handleTouchStart = _this.handleTouchStart.bind(_this);
+ _this.handleTouchEnd = _this.handleTouchEnd.bind(_this);
+ _this.handleTouchMove = _this.handleTouchMove.bind(_this);
+ _this.onFocus = _this.onFocus.bind(_this);
+ return _this;
+ }
-/***/ }),
-/* 151 */
-/***/ (function(module, exports, __webpack_require__) {
+ createClass(Option, [{
+ key: 'handleMouseDown',
+ value: function handleMouseDown(event) {
+ event.preventDefault();
+ event.stopPropagation();
+ this.props.onSelect(this.props.option, event);
+ }
+ }, {
+ key: 'handleMouseEnter',
+ value: function handleMouseEnter(event) {
+ this.onFocus(event);
+ }
+ }, {
+ key: 'handleMouseMove',
+ value: function handleMouseMove(event) {
+ this.onFocus(event);
+ }
+ }, {
+ key: 'handleTouchEnd',
+ value: function handleTouchEnd(event) {
+ // Check if the view is being dragged, In this case
+ // we don't want to fire the click event (because the user only wants to scroll)
+ if (this.dragging) return;
-"use strict";
+ this.handleMouseDown(event);
+ }
+ }, {
+ key: 'handleTouchMove',
+ value: function handleTouchMove() {
+ // Set a flag that the view is being dragged
+ this.dragging = true;
+ }
+ }, {
+ key: 'handleTouchStart',
+ value: function handleTouchStart() {
+ // Set a flag that the view is not being dragged
+ this.dragging = false;
+ }
+ }, {
+ key: 'onFocus',
+ value: function onFocus(event) {
+ if (!this.props.isFocused) {
+ this.props.onFocus(this.props.option, event);
+ }
+ }
+ }, {
+ key: 'render',
+ value: function render() {
+ var _props = this.props,
+ option = _props.option,
+ instancePrefix = _props.instancePrefix,
+ optionIndex = _props.optionIndex;
+ var className = classnames_default()(this.props.className, option.className);
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'monokai',
- author: 'wimer hazenberg (http://www.monokai.nl)',
- base00: '#272822',
- base01: '#383830',
- base02: '#49483e',
- base03: '#75715e',
- base04: '#a59f85',
- base05: '#f8f8f2',
- base06: '#f5f4f1',
- base07: '#f9f8f5',
- base08: '#f92672',
- base09: '#fd971f',
- base0A: '#f4bf75',
- base0B: '#a6e22e',
- base0C: '#a1efe4',
- base0D: '#66d9ef',
- base0E: '#ae81ff',
- base0F: '#cc6633'
+ return option.disabled ? external_React_default.a.createElement(
+ 'div',
+ { className: className,
+ onMouseDown: blockEvent,
+ onClick: blockEvent },
+ this.props.children
+ ) : external_React_default.a.createElement(
+ 'div',
+ { className: className,
+ style: option.style,
+ role: 'option',
+ 'aria-label': option.label,
+ onMouseDown: this.handleMouseDown,
+ onMouseEnter: this.handleMouseEnter,
+ onMouseMove: this.handleMouseMove,
+ onTouchStart: this.handleTouchStart,
+ onTouchMove: this.handleTouchMove,
+ onTouchEnd: this.handleTouchEnd,
+ id: instancePrefix + '-option-' + optionIndex,
+ title: option.title },
+ this.props.children
+ );
+ }
+ }]);
+ return Option;
+}(external_React_default.a.Component);
+
+react_select_es_Option.propTypes = {
+ children: prop_types_default.a.node,
+ className: prop_types_default.a.string, // className (based on mouse position)
+ instancePrefix: prop_types_default.a.string.isRequired, // unique prefix for the ids (used for aria)
+ isDisabled: prop_types_default.a.bool, // the option is disabled
+ isFocused: prop_types_default.a.bool, // the option is focused
+ isSelected: prop_types_default.a.bool, // the option is selected
+ onFocus: prop_types_default.a.func, // method to handle mouseEnter on option element
+ onSelect: prop_types_default.a.func, // method to handle click on option element
+ onUnfocus: prop_types_default.a.func, // method to handle mouseLeave on option element
+ option: prop_types_default.a.object.isRequired, // object that is base for that option
+ optionIndex: prop_types_default.a.number // index of the option, used to generate unique ids for aria
};
-module.exports = exports['default'];
-
-/***/ }),
-/* 152 */
-/***/ (function(module, exports, __webpack_require__) {
-"use strict";
+var react_select_es_Value = function (_React$Component) {
+ inherits(Value, _React$Component);
+ function Value(props) {
+ classCallCheck(this, Value);
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'ocean',
- author: 'chris kempson (http://chriskempson.com)',
- base00: '#2b303b',
- base01: '#343d46',
- base02: '#4f5b66',
- base03: '#65737e',
- base04: '#a7adba',
- base05: '#c0c5ce',
- base06: '#dfe1e8',
- base07: '#eff1f5',
- base08: '#bf616a',
- base09: '#d08770',
- base0A: '#ebcb8b',
- base0B: '#a3be8c',
- base0C: '#96b5b4',
- base0D: '#8fa1b3',
- base0E: '#b48ead',
- base0F: '#ab7967'
-};
-module.exports = exports['default'];
+ var _this = possibleConstructorReturn(this, (Value.__proto__ || Object.getPrototypeOf(Value)).call(this, props));
-/***/ }),
-/* 153 */
-/***/ (function(module, exports, __webpack_require__) {
+ _this.handleMouseDown = _this.handleMouseDown.bind(_this);
+ _this.onRemove = _this.onRemove.bind(_this);
+ _this.handleTouchEndRemove = _this.handleTouchEndRemove.bind(_this);
+ _this.handleTouchMove = _this.handleTouchMove.bind(_this);
+ _this.handleTouchStart = _this.handleTouchStart.bind(_this);
+ return _this;
+ }
-"use strict";
+ createClass(Value, [{
+ key: 'handleMouseDown',
+ value: function handleMouseDown(event) {
+ if (event.type === 'mousedown' && event.button !== 0) {
+ return;
+ }
+ if (this.props.onClick) {
+ event.stopPropagation();
+ this.props.onClick(this.props.value, event);
+ return;
+ }
+ if (this.props.value.href) {
+ event.stopPropagation();
+ }
+ }
+ }, {
+ key: 'onRemove',
+ value: function onRemove(event) {
+ event.preventDefault();
+ event.stopPropagation();
+ this.props.onRemove(this.props.value);
+ }
+ }, {
+ key: 'handleTouchEndRemove',
+ value: function handleTouchEndRemove(event) {
+ // Check if the view is being dragged, In this case
+ // we don't want to fire the click event (because the user only wants to scroll)
+ if (this.dragging) return;
+ // Fire the mouse events
+ this.onRemove(event);
+ }
+ }, {
+ key: 'handleTouchMove',
+ value: function handleTouchMove() {
+ // Set a flag that the view is being dragged
+ this.dragging = true;
+ }
+ }, {
+ key: 'handleTouchStart',
+ value: function handleTouchStart() {
+ // Set a flag that the view is not being dragged
+ this.dragging = false;
+ }
+ }, {
+ key: 'renderRemoveIcon',
+ value: function renderRemoveIcon() {
+ if (this.props.disabled || !this.props.onRemove) return;
+ return external_React_default.a.createElement(
+ 'span',
+ { className: 'Select-value-icon',
+ 'aria-hidden': 'true',
+ onMouseDown: this.onRemove,
+ onTouchEnd: this.handleTouchEndRemove,
+ onTouchStart: this.handleTouchStart,
+ onTouchMove: this.handleTouchMove },
+ '\xD7'
+ );
+ }
+ }, {
+ key: 'renderLabel',
+ value: function renderLabel() {
+ var className = 'Select-value-label';
+ return this.props.onClick || this.props.value.href ? external_React_default.a.createElement(
+ 'a',
+ { className: className, href: this.props.value.href, target: this.props.value.target, onMouseDown: this.handleMouseDown, onTouchEnd: this.handleMouseDown },
+ this.props.children
+ ) : external_React_default.a.createElement(
+ 'span',
+ { className: className, role: 'option', 'aria-selected': 'true', id: this.props.id },
+ this.props.children
+ );
+ }
+ }, {
+ key: 'render',
+ value: function render() {
+ return external_React_default.a.createElement(
+ 'div',
+ { className: classnames_default()('Select-value', this.props.value.disabled ? 'Select-value-disabled' : '', this.props.value.className),
+ style: this.props.value.style,
+ title: this.props.value.title
+ },
+ this.renderRemoveIcon(),
+ this.renderLabel()
+ );
+ }
+ }]);
+ return Value;
+}(external_React_default.a.Component);
+
+react_select_es_Value.propTypes = {
+ children: prop_types_default.a.node,
+ disabled: prop_types_default.a.bool, // disabled prop passed to ReactSelect
+ id: prop_types_default.a.string, // Unique id for the value - used for aria
+ onClick: prop_types_default.a.func, // method to handle click on value label
+ onRemove: prop_types_default.a.func, // method to handle removal of the value
+ value: prop_types_default.a.object.isRequired // the option object for this value
+};
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'paraiso',
- author: 'jan t. sott',
- base00: '#2f1e2e',
- base01: '#41323f',
- base02: '#4f424c',
- base03: '#776e71',
- base04: '#8d8687',
- base05: '#a39e9b',
- base06: '#b9b6b0',
- base07: '#e7e9db',
- base08: '#ef6155',
- base09: '#f99b15',
- base0A: '#fec418',
- base0B: '#48b685',
- base0C: '#5bc4bf',
- base0D: '#06b6ef',
- base0E: '#815ba4',
- base0F: '#e96ba8'
+/*!
+ Copyright (c) 2018 Jed Watson.
+ Licensed under the MIT License (MIT), see
+ http://jedwatson.github.io/react-select
+*/
+var stringifyValue = function stringifyValue(value) {
+ return typeof value === 'string' ? value : value !== null && JSON.stringify(value) || '';
};
-module.exports = exports['default'];
-
-/***/ }),
-/* 154 */
-/***/ (function(module, exports, __webpack_require__) {
-"use strict";
+var stringOrNode = prop_types_default.a.oneOfType([prop_types_default.a.string, prop_types_default.a.node]);
+var stringOrNumber = prop_types_default.a.oneOfType([prop_types_default.a.string, prop_types_default.a.number]);
+var instanceId = 1;
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'pop',
- author: 'chris kempson (http://chriskempson.com)',
- base00: '#000000',
- base01: '#202020',
- base02: '#303030',
- base03: '#505050',
- base04: '#b0b0b0',
- base05: '#d0d0d0',
- base06: '#e0e0e0',
- base07: '#ffffff',
- base08: '#eb008a',
- base09: '#f29333',
- base0A: '#f8ca12',
- base0B: '#37b349',
- base0C: '#00aabb',
- base0D: '#0e5a94',
- base0E: '#b31e8d',
- base0F: '#7a2d00'
-};
-module.exports = exports['default'];
+var shouldShowValue = function shouldShowValue(state, props) {
+ var inputValue = state.inputValue,
+ isPseudoFocused = state.isPseudoFocused,
+ isFocused = state.isFocused;
+ var onSelectResetsInput = props.onSelectResetsInput;
-/***/ }),
-/* 155 */
-/***/ (function(module, exports, __webpack_require__) {
-"use strict";
+ if (!inputValue) return true;
+ if (!onSelectResetsInput) {
+ return !(!isFocused && isPseudoFocused || isFocused && !isPseudoFocused);
+ }
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'railscasts',
- author: 'ryan bates (http://railscasts.com)',
- base00: '#2b2b2b',
- base01: '#272935',
- base02: '#3a4055',
- base03: '#5a647e',
- base04: '#d4cfc9',
- base05: '#e6e1dc',
- base06: '#f4f1ed',
- base07: '#f9f7f3',
- base08: '#da4939',
- base09: '#cc7833',
- base0A: '#ffc66d',
- base0B: '#a5c261',
- base0C: '#519f50',
- base0D: '#6d9cbe',
- base0E: '#b6b3eb',
- base0F: '#bc9458'
+ return false;
};
-module.exports = exports['default'];
-/***/ }),
-/* 156 */
-/***/ (function(module, exports, __webpack_require__) {
+var shouldShowPlaceholder = function shouldShowPlaceholder(state, props, isOpen) {
+ var inputValue = state.inputValue,
+ isPseudoFocused = state.isPseudoFocused,
+ isFocused = state.isFocused;
+ var onSelectResetsInput = props.onSelectResetsInput;
-"use strict";
+ return !inputValue || !onSelectResetsInput && !isOpen && !isPseudoFocused && !isFocused;
+};
+
+/**
+ * Retrieve a value from the given options and valueKey
+ * @param {String|Number|Array} value - the selected value(s)
+ * @param {Object} props - the Select component's props (or nextProps)
+ */
+var expandValue = function expandValue(value, props) {
+ var valueType = typeof value === 'undefined' ? 'undefined' : react_select_es_typeof(value);
+ if (valueType !== 'string' && valueType !== 'number' && valueType !== 'boolean') return value;
+ var options = props.options,
+ valueKey = props.valueKey;
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'shapeshifter',
- author: 'tyler benziger (http://tybenz.com)',
- base00: '#000000',
- base01: '#040404',
- base02: '#102015',
- base03: '#343434',
- base04: '#555555',
- base05: '#ababab',
- base06: '#e0e0e0',
- base07: '#f9f9f9',
- base08: '#e92f2f',
- base09: '#e09448',
- base0A: '#dddd13',
- base0B: '#0ed839',
- base0C: '#23edda',
- base0D: '#3b48e3',
- base0E: '#f996e2',
- base0F: '#69542d'
+ if (!options) return;
+ for (var i = 0; i < options.length; i++) {
+ if (String(options[i][valueKey]) === String(value)) return options[i];
+ }
};
-module.exports = exports['default'];
-/***/ }),
-/* 157 */
-/***/ (function(module, exports, __webpack_require__) {
+var handleRequired = function handleRequired(value, multi) {
+ if (!value) return true;
+ return multi ? value.length === 0 : Object.keys(value).length === 0;
+};
-"use strict";
+var Select$1 = function (_React$Component) {
+ inherits(Select, _React$Component);
+ function Select(props) {
+ classCallCheck(this, Select);
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'solarized',
- author: 'ethan schoonover (http://ethanschoonover.com/solarized)',
- base00: '#002b36',
- base01: '#073642',
- base02: '#586e75',
- base03: '#657b83',
- base04: '#839496',
- base05: '#93a1a1',
- base06: '#eee8d5',
- base07: '#fdf6e3',
- base08: '#dc322f',
- base09: '#cb4b16',
- base0A: '#b58900',
- base0B: '#859900',
- base0C: '#2aa198',
- base0D: '#268bd2',
- base0E: '#6c71c4',
- base0F: '#d33682'
-};
-module.exports = exports['default'];
+ var _this = possibleConstructorReturn(this, (Select.__proto__ || Object.getPrototypeOf(Select)).call(this, props));
-/***/ }),
-/* 158 */
-/***/ (function(module, exports, __webpack_require__) {
+ ['clearValue', 'focusOption', 'getOptionLabel', 'handleInputBlur', 'handleInputChange', 'handleInputFocus', 'handleInputValueChange', 'handleKeyDown', 'handleMenuScroll', 'handleMouseDown', 'handleMouseDownOnArrow', 'handleMouseDownOnMenu', 'handleTouchEnd', 'handleTouchEndClearValue', 'handleTouchMove', 'handleTouchOutside', 'handleTouchStart', 'handleValueClick', 'onOptionRef', 'removeValue', 'selectValue'].forEach(function (fn) {
+ return _this[fn] = _this[fn].bind(_this);
+ });
-"use strict";
+ _this.state = {
+ inputValue: '',
+ isFocused: false,
+ isOpen: false,
+ isPseudoFocused: false,
+ required: false
+ };
+ return _this;
+ }
+ createClass(Select, [{
+ key: 'componentWillMount',
+ value: function componentWillMount() {
+ this._instancePrefix = 'react-select-' + (this.props.instanceId || ++instanceId) + '-';
+ var valueArray = this.getValueArray(this.props.value);
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'summerfruit',
- author: 'christopher corley (http://cscorley.github.io/)',
- base00: '#151515',
- base01: '#202020',
- base02: '#303030',
- base03: '#505050',
- base04: '#B0B0B0',
- base05: '#D0D0D0',
- base06: '#E0E0E0',
- base07: '#FFFFFF',
- base08: '#FF0086',
- base09: '#FD8900',
- base0A: '#ABA800',
- base0B: '#00C918',
- base0C: '#1faaaa',
- base0D: '#3777E6',
- base0E: '#AD00A1',
- base0F: '#cc6633'
-};
-module.exports = exports['default'];
+ if (this.props.required) {
+ this.setState({
+ required: handleRequired(valueArray[0], this.props.multi)
+ });
+ }
+ }
+ }, {
+ key: 'componentDidMount',
+ value: function componentDidMount() {
+ if (typeof this.props.autofocus !== 'undefined' && typeof console !== 'undefined') {
+ console.warn('Warning: The autofocus prop has changed to autoFocus, support will be removed after react-select@1.0');
+ }
+ if (this.props.autoFocus || this.props.autofocus) {
+ this.focus();
+ }
+ }
+ }, {
+ key: 'componentWillReceiveProps',
+ value: function componentWillReceiveProps(nextProps) {
+ var valueArray = this.getValueArray(nextProps.value, nextProps);
-/***/ }),
-/* 159 */
-/***/ (function(module, exports, __webpack_require__) {
+ if (nextProps.required) {
+ this.setState({
+ required: handleRequired(valueArray[0], nextProps.multi)
+ });
+ } else if (this.props.required) {
+ // Used to be required but it's not any more
+ this.setState({ required: false });
+ }
-"use strict";
+ if (this.state.inputValue && this.props.value !== nextProps.value && nextProps.onSelectResetsInput) {
+ this.setState({ inputValue: this.handleInputValueChange('') });
+ }
+ }
+ }, {
+ key: 'componentDidUpdate',
+ value: function componentDidUpdate(prevProps, prevState) {
+ // focus to the selected option
+ if (this.menu && this.focused && this.state.isOpen && !this.hasScrolledToOption) {
+ var focusedOptionNode = Object(external_ReactDOM_["findDOMNode"])(this.focused);
+ var menuNode = Object(external_ReactDOM_["findDOMNode"])(this.menu);
+ var scrollTop = menuNode.scrollTop;
+ var scrollBottom = scrollTop + menuNode.offsetHeight;
+ var optionTop = focusedOptionNode.offsetTop;
+ var optionBottom = optionTop + focusedOptionNode.offsetHeight;
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'tomorrow',
- author: 'chris kempson (http://chriskempson.com)',
- base00: '#1d1f21',
- base01: '#282a2e',
- base02: '#373b41',
- base03: '#969896',
- base04: '#b4b7b4',
- base05: '#c5c8c6',
- base06: '#e0e0e0',
- base07: '#ffffff',
- base08: '#cc6666',
- base09: '#de935f',
- base0A: '#f0c674',
- base0B: '#b5bd68',
- base0C: '#8abeb7',
- base0D: '#81a2be',
- base0E: '#b294bb',
- base0F: '#a3685a'
-};
-module.exports = exports['default'];
+ if (scrollTop > optionTop || scrollBottom < optionBottom) {
+ menuNode.scrollTop = focusedOptionNode.offsetTop;
+ }
-/***/ }),
-/* 160 */
-/***/ (function(module, exports, __webpack_require__) {
+ // We still set hasScrolledToOption to true even if we didn't
+ // actually need to scroll, as we've still confirmed that the
+ // option is in view.
+ this.hasScrolledToOption = true;
+ } else if (!this.state.isOpen) {
+ this.hasScrolledToOption = false;
+ }
-"use strict";
+ if (this._scrollToFocusedOptionOnUpdate && this.focused && this.menu) {
+ this._scrollToFocusedOptionOnUpdate = false;
+ var focusedDOM = Object(external_ReactDOM_["findDOMNode"])(this.focused);
+ var menuDOM = Object(external_ReactDOM_["findDOMNode"])(this.menu);
+ var focusedRect = focusedDOM.getBoundingClientRect();
+ var menuRect = menuDOM.getBoundingClientRect();
+ if (focusedRect.bottom > menuRect.bottom) {
+ menuDOM.scrollTop = focusedDOM.offsetTop + focusedDOM.clientHeight - menuDOM.offsetHeight;
+ } else if (focusedRect.top < menuRect.top) {
+ menuDOM.scrollTop = focusedDOM.offsetTop;
+ }
+ }
+ if (this.props.scrollMenuIntoView && this.menuContainer) {
+ var menuContainerRect = this.menuContainer.getBoundingClientRect();
+ if (window.innerHeight < menuContainerRect.bottom + this.props.menuBuffer) {
+ window.scrollBy(0, menuContainerRect.bottom + this.props.menuBuffer - window.innerHeight);
+ }
+ }
+ if (prevProps.disabled !== this.props.disabled) {
+ this.setState({ isFocused: false }); // eslint-disable-line react/no-did-update-set-state
+ this.closeMenu();
+ }
+ if (prevState.isOpen !== this.state.isOpen) {
+ this.toggleTouchOutsideEvent(this.state.isOpen);
+ var handler = this.state.isOpen ? this.props.onOpen : this.props.onClose;
+ handler && handler();
+ }
+ }
+ }, {
+ key: 'componentWillUnmount',
+ value: function componentWillUnmount() {
+ this.toggleTouchOutsideEvent(false);
+ }
+ }, {
+ key: 'toggleTouchOutsideEvent',
+ value: function toggleTouchOutsideEvent(enabled) {
+ var eventTogglerName = enabled ? document.addEventListener ? 'addEventListener' : 'attachEvent' : document.removeEventListener ? 'removeEventListener' : 'detachEvent';
+ var pref = document.addEventListener ? '' : 'on';
+ document[eventTogglerName](pref + 'touchstart', this.handleTouchOutside);
+ document[eventTogglerName](pref + 'mousedown', this.handleTouchOutside);
+ }
+ }, {
+ key: 'handleTouchOutside',
+ value: function handleTouchOutside(event) {
+ // handle touch outside on ios to dismiss menu
+ if (this.wrapper && !this.wrapper.contains(event.target)) {
+ this.closeMenu();
+ }
+ }
+ }, {
+ key: 'focus',
+ value: function focus() {
+ if (!this.input) return;
+ this.input.focus();
+ }
+ }, {
+ key: 'blurInput',
+ value: function blurInput() {
+ if (!this.input) return;
+ this.input.blur();
+ }
+ }, {
+ key: 'handleTouchMove',
+ value: function handleTouchMove() {
+ // Set a flag that the view is being dragged
+ this.dragging = true;
+ }
+ }, {
+ key: 'handleTouchStart',
+ value: function handleTouchStart() {
+ // Set a flag that the view is not being dragged
+ this.dragging = false;
+ }
+ }, {
+ key: 'handleTouchEnd',
+ value: function handleTouchEnd(event) {
+ // Check if the view is being dragged, In this case
+ // we don't want to fire the click event (because the user only wants to scroll)
+ if (this.dragging) return;
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'london tube',
- author: 'jan t. sott',
- base00: '#231f20',
- base01: '#1c3f95',
- base02: '#5a5758',
- base03: '#737171',
- base04: '#959ca1',
- base05: '#d9d8d8',
- base06: '#e7e7e8',
- base07: '#ffffff',
- base08: '#ee2e24',
- base09: '#f386a1',
- base0A: '#ffd204',
- base0B: '#00853e',
- base0C: '#85cebc',
- base0D: '#009ddc',
- base0E: '#98005d',
- base0F: '#b06110'
-};
-module.exports = exports['default'];
+ // Fire the mouse events
+ this.handleMouseDown(event);
+ }
+ }, {
+ key: 'handleTouchEndClearValue',
+ value: function handleTouchEndClearValue(event) {
+ // Check if the view is being dragged, In this case
+ // we don't want to fire the click event (because the user only wants to scroll)
+ if (this.dragging) return;
-/***/ }),
-/* 161 */
-/***/ (function(module, exports, __webpack_require__) {
+ // Clear the value
+ this.clearValue(event);
+ }
+ }, {
+ key: 'handleMouseDown',
+ value: function handleMouseDown(event) {
+ // if the event was triggered by a mousedown and not the primary
+ // button, or if the component is disabled, ignore it.
+ if (this.props.disabled || event.type === 'mousedown' && event.button !== 0) {
+ return;
+ }
-"use strict";
+ if (event.target.tagName === 'INPUT') {
+ if (!this.state.isFocused) {
+ this._openAfterFocus = this.props.openOnClick;
+ this.focus();
+ } else if (!this.state.isOpen) {
+ this.setState({
+ isOpen: true,
+ isPseudoFocused: false,
+ focusedOption: null
+ });
+ }
+ return;
+ }
-exports.__esModule = true;
-exports['default'] = {
- scheme: 'twilight',
- author: 'david hart (http://hart-dev.com)',
- base00: '#1e1e1e',
- base01: '#323537',
- base02: '#464b50',
- base03: '#5f5a60',
- base04: '#838184',
- base05: '#a7a7a7',
- base06: '#c3c3c3',
- base07: '#ffffff',
- base08: '#cf6a4c',
- base09: '#cda869',
- base0A: '#f9ee98',
- base0B: '#8f9d6a',
- base0C: '#afc4db',
- base0D: '#7587a6',
- base0E: '#9b859d',
- base0F: '#9b703f'
-};
-module.exports = exports['default'];
+ // prevent default event handlers
+ event.preventDefault();
-/***/ }),
-/* 162 */
-/***/ (function(module, exports, __webpack_require__) {
+ // for the non-searchable select, toggle the menu
+ if (!this.props.searchable) {
+ // This code means that if a select is searchable, onClick the options menu will not appear, only on subsequent click will it open.
+ this.focus();
+ return this.setState({
+ isOpen: !this.state.isOpen,
+ focusedOption: null
+ });
+ }
-var clamp = __webpack_require__(45);
+ if (this.state.isFocused) {
+ // On iOS, we can get into a state where we think the input is focused but it isn't really,
+ // since iOS ignores programmatic calls to input.focus() that weren't triggered by a click event.
+ // Call focus() again here to be safe.
+ this.focus();
-function componentToHex(c) {
- var value = Math.round(clamp(c, 0, 255));
- var hex = value.toString(16);
+ var input = this.input;
+ var toOpen = true;
- return hex.length == 1 ? "0" + hex : hex;
-}
+ if (typeof input.getInput === 'function') {
+ // Get the actual DOM input if the ref is an component
+ input = input.getInput();
+ }
-function rgb2hex(rgb) {
- var alpha = rgb.length === 4 ? componentToHex(rgb[3] * 255) : "";
+ // clears the value so that the cursor will be at the end of input when the component re-renders
+ input.value = '';
- return "#" + componentToHex(rgb[0]) + componentToHex(rgb[1]) + componentToHex(rgb[2]) + alpha;
-}
+ if (this._focusAfterClear) {
+ toOpen = false;
+ this._focusAfterClear = false;
+ }
-module.exports = rgb2hex;
+ // if the input is focused, ensure the menu is open
+ this.setState({
+ isOpen: toOpen,
+ isPseudoFocused: false,
+ focusedOption: null
+ });
+ } else {
+ // otherwise, focus the input and open the menu
+ this._openAfterFocus = this.props.openOnClick;
+ this.focus();
+ this.setState({ focusedOption: null });
+ }
+ }
+ }, {
+ key: 'handleMouseDownOnArrow',
+ value: function handleMouseDownOnArrow(event) {
+ // if the event was triggered by a mousedown and not the primary
+ // button, or if the component is disabled, ignore it.
+ if (this.props.disabled || event.type === 'mousedown' && event.button !== 0) {
+ return;
+ }
-/***/ }),
-/* 163 */
-/***/ (function(module, exports, __webpack_require__) {
-
-var hsl = __webpack_require__(164);
-var hex = __webpack_require__(165);
-var rgb = __webpack_require__(166);
-var hsl2rgb = __webpack_require__(167);
-
-function hsl2rgbParse(color) {
- var h = hsl(color);
- var r = hsl2rgb(h);
-
- // handle alpha since hsl2rgb doesn't know (or care!) about it
- if(h.length === 4) {
- r.push(h[3]);
- }
-
- return r;
-}
-
-var space2parser = {
- "#" : hex,
- "hsl" : hsl2rgbParse,
- "rgb" : rgb
-};
-
-function parse(color) {
- for(var scheme in space2parser) {
- if(color.indexOf(scheme) === 0) {
- return space2parser[scheme](color);
- }
- }
-}
-
-parse.rgb = rgb;
-parse.hsl = hsl;
-parse.hex = hex;
-
-module.exports = parse;
-
-/***/ }),
-/* 164 */
-/***/ (function(module, exports, __webpack_require__) {
-
-var extractComponents = __webpack_require__(58);
-var clamp = __webpack_require__(45);
-
-function parseHslComponent(component, i) {
- component = parseFloat(component);
-
- switch(i) {
- case 0:
- return clamp(component, 0, 360);
- case 1:
- case 2:
- return clamp(component, 0, 100);
- case 3:
- return clamp(component, 0, 1);
- }
-}
-
-function hsl(color) {
- return extractComponents(color).map(parseHslComponent);
-}
-
-module.exports = hsl;
-
-/***/ }),
-/* 165 */
-/***/ (function(module, exports) {
-
-function expand(hex) {
- var result = "#";
-
- for (var i = 1; i < hex.length; i++) {
- var val = hex.charAt(i);
- result += val + val;
- }
-
- return result;
-}
-
-function hex(hex) {
- // #RGB or #RGBA
- if(hex.length === 4 || hex.length === 5) {
- hex = expand(hex);
- }
-
- var rgb = [
- parseInt(hex.substring(1,3), 16),
- parseInt(hex.substring(3,5), 16),
- parseInt(hex.substring(5,7), 16)
- ];
-
- // #RRGGBBAA
- if (hex.length === 9) {
- var alpha = parseFloat((parseInt(hex.substring(7,9), 16) / 255).toFixed(2));
- rgb.push(alpha);
- }
-
- return rgb;
-}
+ if (this.state.isOpen) {
+ // prevent default event handlers
+ event.stopPropagation();
+ event.preventDefault();
+ // close the menu
+ this.closeMenu();
+ } else {
+ // If the menu isn't open, let the event bubble to the main handleMouseDown
+ this.setState({
+ isOpen: true
+ });
+ }
+ }
+ }, {
+ key: 'handleMouseDownOnMenu',
+ value: function handleMouseDownOnMenu(event) {
+ // if the event was triggered by a mousedown and not the primary
+ // button, or if the component is disabled, ignore it.
+ if (this.props.disabled || event.type === 'mousedown' && event.button !== 0) {
+ return;
+ }
-module.exports = hex;
+ event.stopPropagation();
+ event.preventDefault();
-/***/ }),
-/* 166 */
-/***/ (function(module, exports, __webpack_require__) {
+ this._openAfterFocus = true;
+ this.focus();
+ }
+ }, {
+ key: 'closeMenu',
+ value: function closeMenu() {
+ if (this.props.onCloseResetsInput) {
+ this.setState({
+ inputValue: this.handleInputValueChange(''),
+ isOpen: false,
+ isPseudoFocused: this.state.isFocused && !this.props.multi
+ });
+ } else {
+ this.setState({
+ isOpen: false,
+ isPseudoFocused: this.state.isFocused && !this.props.multi
+ });
+ }
+ this.hasScrolledToOption = false;
+ }
+ }, {
+ key: 'handleInputFocus',
+ value: function handleInputFocus(event) {
+ if (this.props.disabled) return;
-var extractComponents = __webpack_require__(58);
-var clamp = __webpack_require__(45);
+ var toOpen = this.state.isOpen || this._openAfterFocus || this.props.openOnFocus;
+ toOpen = this._focusAfterClear ? false : toOpen; //if focus happens after clear values, don't open dropdown yet.
-function parseRgbComponent(component, i) {
- if (i < 3) {
- if (component.indexOf('%') != -1) {
- return Math.round(255 * clamp(parseInt(component, 10), 0, 100)/100);
- } else {
- return clamp(parseInt(component, 10), 0, 255);
- }
- } else {
- return clamp(parseFloat(component), 0, 1);
- }
-}
+ if (this.props.onFocus) {
+ this.props.onFocus(event);
+ }
-function rgb(color) {
- return extractComponents(color).map(parseRgbComponent);
-}
+ this.setState({
+ isFocused: true,
+ isOpen: !!toOpen
+ });
-module.exports = rgb;
+ this._focusAfterClear = false;
+ this._openAfterFocus = false;
+ }
+ }, {
+ key: 'handleInputBlur',
+ value: function handleInputBlur(event) {
+ // The check for menu.contains(activeElement) is necessary to prevent IE11's scrollbar from closing the menu in certain contexts.
+ if (this.menu && (this.menu === document.activeElement || this.menu.contains(document.activeElement))) {
+ this.focus();
+ return;
+ }
-/***/ }),
-/* 167 */
-/***/ (function(module, exports) {
+ if (this.props.onBlur) {
+ this.props.onBlur(event);
+ }
+ var onBlurredState = {
+ isFocused: false,
+ isOpen: false,
+ isPseudoFocused: false
+ };
+ if (this.props.onBlurResetsInput) {
+ onBlurredState.inputValue = this.handleInputValueChange('');
+ }
+ this.setState(onBlurredState);
+ }
+ }, {
+ key: 'handleInputChange',
+ value: function handleInputChange(event) {
+ var newInputValue = event.target.value;
-function hsl2rgb(hsl) {
- var h = hsl[0] / 360,
- s = hsl[1] / 100,
- l = hsl[2] / 100,
- t1, t2, t3, rgb, val;
+ if (this.state.inputValue !== event.target.value) {
+ newInputValue = this.handleInputValueChange(newInputValue);
+ }
- if (s == 0) {
- val = l * 255;
- return [val, val, val];
- }
+ this.setState({
+ inputValue: newInputValue,
+ isOpen: true,
+ isPseudoFocused: false
+ });
+ }
+ }, {
+ key: 'setInputValue',
+ value: function setInputValue(newValue) {
+ if (this.props.onInputChange) {
+ var nextState = this.props.onInputChange(newValue);
+ if (nextState != null && (typeof nextState === 'undefined' ? 'undefined' : react_select_es_typeof(nextState)) !== 'object') {
+ newValue = '' + nextState;
+ }
+ }
+ this.setState({
+ inputValue: newValue
+ });
+ }
+ }, {
+ key: 'handleInputValueChange',
+ value: function handleInputValueChange(newValue) {
+ if (this.props.onInputChange) {
+ var nextState = this.props.onInputChange(newValue);
+ // Note: != used deliberately here to catch undefined and null
+ if (nextState != null && (typeof nextState === 'undefined' ? 'undefined' : react_select_es_typeof(nextState)) !== 'object') {
+ newValue = '' + nextState;
+ }
+ }
+ return newValue;
+ }
+ }, {
+ key: 'handleKeyDown',
+ value: function handleKeyDown(event) {
+ if (this.props.disabled) return;
- if (l < 0.5)
- t2 = l * (1 + s);
- else
- t2 = l + s - l * s;
- t1 = 2 * l - t2;
+ if (typeof this.props.onInputKeyDown === 'function') {
+ this.props.onInputKeyDown(event);
+ if (event.defaultPrevented) {
+ return;
+ }
+ }
- rgb = [0, 0, 0];
- for (var i = 0; i < 3; i++) {
- t3 = h + 1 / 3 * - (i - 1);
- t3 < 0 && t3++;
- t3 > 1 && t3--;
+ switch (event.keyCode) {
+ case 8:
+ // backspace
+ if (!this.state.inputValue && this.props.backspaceRemoves) {
+ event.preventDefault();
+ this.popValue();
+ }
+ break;
+ case 9:
+ // tab
+ if (event.shiftKey || !this.state.isOpen || !this.props.tabSelectsValue) {
+ break;
+ }
+ event.preventDefault();
+ this.selectFocusedOption();
+ break;
+ case 13:
+ // enter
+ event.preventDefault();
+ event.stopPropagation();
+ if (this.state.isOpen) {
+ this.selectFocusedOption();
+ } else {
+ this.focusNextOption();
+ }
+ break;
+ case 27:
+ // escape
+ event.preventDefault();
+ if (this.state.isOpen) {
+ this.closeMenu();
+ event.stopPropagation();
+ } else if (this.props.clearable && this.props.escapeClearsValue) {
+ this.clearValue(event);
+ event.stopPropagation();
+ }
+ break;
+ case 32:
+ // space
+ if (this.props.searchable) {
+ break;
+ }
+ event.preventDefault();
+ if (!this.state.isOpen) {
+ this.focusNextOption();
+ break;
+ }
+ event.stopPropagation();
+ this.selectFocusedOption();
+ break;
+ case 38:
+ // up
+ event.preventDefault();
+ this.focusPreviousOption();
+ break;
+ case 40:
+ // down
+ event.preventDefault();
+ this.focusNextOption();
+ break;
+ case 33:
+ // page up
+ event.preventDefault();
+ this.focusPageUpOption();
+ break;
+ case 34:
+ // page down
+ event.preventDefault();
+ this.focusPageDownOption();
+ break;
+ case 35:
+ // end key
+ if (event.shiftKey) {
+ break;
+ }
+ event.preventDefault();
+ this.focusEndOption();
+ break;
+ case 36:
+ // home key
+ if (event.shiftKey) {
+ break;
+ }
+ event.preventDefault();
+ this.focusStartOption();
+ break;
+ case 46:
+ // delete
+ if (!this.state.inputValue && this.props.deleteRemoves) {
+ event.preventDefault();
+ this.popValue();
+ }
+ break;
+ }
+ }
+ }, {
+ key: 'handleValueClick',
+ value: function handleValueClick(option, event) {
+ if (!this.props.onValueClick) return;
+ this.props.onValueClick(option, event);
+ }
+ }, {
+ key: 'handleMenuScroll',
+ value: function handleMenuScroll(event) {
+ if (!this.props.onMenuScrollToBottom) return;
+ var target = event.target;
- if (6 * t3 < 1)
- val = t1 + (t2 - t1) * 6 * t3;
- else if (2 * t3 < 1)
- val = t2;
- else if (3 * t3 < 2)
- val = t1 + (t2 - t1) * (2 / 3 - t3) * 6;
- else
- val = t1;
+ if (target.scrollHeight > target.offsetHeight && target.scrollHeight - target.offsetHeight - target.scrollTop <= 0) {
+ this.props.onMenuScrollToBottom();
+ }
+ }
+ }, {
+ key: 'getOptionLabel',
+ value: function getOptionLabel(op) {
+ return op[this.props.labelKey];
+ }
- rgb[i] = val * 255;
- }
+ /**
+ * Turns a value into an array from the given options
+ * @param {String|Number|Array} value - the value of the select input
+ * @param {Object} nextProps - optionally specify the nextProps so the returned array uses the latest configuration
+ * @returns {Array} the value of the select represented in an array
+ */
- return rgb;
-}
+ }, {
+ key: 'getValueArray',
+ value: function getValueArray(value) {
+ var nextProps = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : undefined;
-module.exports = hsl2rgb;
+ /** support optionally passing in the `nextProps` so `componentWillReceiveProps` updates will function as expected */
+ var props = (typeof nextProps === 'undefined' ? 'undefined' : react_select_es_typeof(nextProps)) === 'object' ? nextProps : this.props;
+ if (props.multi) {
+ if (typeof value === 'string') {
+ value = value.split(props.delimiter);
+ }
+ if (!Array.isArray(value)) {
+ if (value === null || value === undefined) return [];
+ value = [value];
+ }
+ return value.map(function (value) {
+ return expandValue(value, props);
+ }).filter(function (i) {
+ return i;
+ });
+ }
+ var expandedValue = expandValue(value, props);
+ return expandedValue ? [expandedValue] : [];
+ }
+ }, {
+ key: 'setValue',
+ value: function setValue(value) {
+ var _this2 = this;
-/***/ }),
-/* 168 */
-/***/ (function(module, exports, __webpack_require__) {
+ if (this.props.autoBlur) {
+ this.blurInput();
+ }
+ if (this.props.required) {
+ var required = handleRequired(value, this.props.multi);
+ this.setState({ required: required });
+ }
+ if (this.props.simpleValue && value) {
+ value = this.props.multi ? value.map(function (i) {
+ return i[_this2.props.valueKey];
+ }).join(this.props.delimiter) : value[this.props.valueKey];
+ }
+ if (this.props.onChange) {
+ this.props.onChange(value);
+ }
+ }
+ }, {
+ key: 'selectValue',
+ value: function selectValue(value) {
+ var _this3 = this;
-/* WEBPACK VAR INJECTION */(function(global) {/**
- * lodash (Custom Build)
- * Build: `lodash modularize exports="npm" -o ./`
- * Copyright jQuery Foundation and other contributors
- * Released under MIT license
- * Based on Underscore.js 1.8.3
- * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
- */
+ // NOTE: we actually add/set the value in a callback to make sure the
+ // input value is empty to avoid styling issues in Chrome
+ if (this.props.closeOnSelect) {
+ this.hasScrolledToOption = false;
+ }
+ var updatedValue = this.props.onSelectResetsInput ? '' : this.state.inputValue;
+ if (this.props.multi) {
+ this.setState({
+ focusedIndex: null,
+ inputValue: this.handleInputValueChange(updatedValue),
+ isOpen: !this.props.closeOnSelect
+ }, function () {
+ var valueArray = _this3.getValueArray(_this3.props.value);
+ if (valueArray.some(function (i) {
+ return i[_this3.props.valueKey] === value[_this3.props.valueKey];
+ })) {
+ _this3.removeValue(value);
+ } else {
+ _this3.addValue(value);
+ }
+ });
+ } else {
+ this.setState({
+ inputValue: this.handleInputValueChange(updatedValue),
+ isOpen: !this.props.closeOnSelect,
+ isPseudoFocused: this.state.isFocused
+ }, function () {
+ _this3.setValue(value);
+ });
+ }
+ }
+ }, {
+ key: 'addValue',
+ value: function addValue(value) {
+ var valueArray = this.getValueArray(this.props.value);
+ var visibleOptions = this._visibleOptions.filter(function (val) {
+ return !val.disabled;
+ });
+ var lastValueIndex = visibleOptions.indexOf(value);
+ this.setValue(valueArray.concat(value));
+ if (!this.props.closeOnSelect) {
+ return;
+ }
+ if (visibleOptions.length - 1 === lastValueIndex) {
+ // the last option was selected; focus the second-last one
+ this.focusOption(visibleOptions[lastValueIndex - 1]);
+ } else if (visibleOptions.length > lastValueIndex) {
+ // focus the option below the selected one
+ this.focusOption(visibleOptions[lastValueIndex + 1]);
+ }
+ }
+ }, {
+ key: 'popValue',
+ value: function popValue() {
+ var valueArray = this.getValueArray(this.props.value);
+ if (!valueArray.length) return;
+ if (valueArray[valueArray.length - 1].clearableValue === false) return;
+ this.setValue(this.props.multi ? valueArray.slice(0, valueArray.length - 1) : null);
+ }
+ }, {
+ key: 'removeValue',
+ value: function removeValue(value) {
+ var _this4 = this;
-/** Used as the `TypeError` message for "Functions" methods. */
-var FUNC_ERROR_TEXT = 'Expected a function';
+ var valueArray = this.getValueArray(this.props.value);
+ this.setValue(valueArray.filter(function (i) {
+ return i[_this4.props.valueKey] !== value[_this4.props.valueKey];
+ }));
+ this.focus();
+ }
+ }, {
+ key: 'clearValue',
+ value: function clearValue(event) {
+ // if the event was triggered by a mousedown and not the primary
+ // button, ignore it.
+ if (event && event.type === 'mousedown' && event.button !== 0) {
+ return;
+ }
-/** Used as references for various `Number` constants. */
-var MAX_SAFE_INTEGER = 9007199254740991;
+ event.preventDefault();
-/** `Object#toString` result references. */
-var argsTag = '[object Arguments]',
- funcTag = '[object Function]',
- genTag = '[object GeneratorFunction]';
+ this.setValue(this.getResetValue());
+ this.setState({
+ inputValue: this.handleInputValueChange(''),
+ isOpen: false
+ }, this.focus);
-/** Detect free variable `global` from Node.js. */
-var freeGlobal = typeof global == 'object' && global && global.Object === Object && global;
+ this._focusAfterClear = true;
+ }
+ }, {
+ key: 'getResetValue',
+ value: function getResetValue() {
+ if (this.props.resetValue !== undefined) {
+ return this.props.resetValue;
+ } else if (this.props.multi) {
+ return [];
+ } else {
+ return null;
+ }
+ }
+ }, {
+ key: 'focusOption',
+ value: function focusOption(option) {
+ this.setState({
+ focusedOption: option
+ });
+ }
+ }, {
+ key: 'focusNextOption',
+ value: function focusNextOption() {
+ this.focusAdjacentOption('next');
+ }
+ }, {
+ key: 'focusPreviousOption',
+ value: function focusPreviousOption() {
+ this.focusAdjacentOption('previous');
+ }
+ }, {
+ key: 'focusPageUpOption',
+ value: function focusPageUpOption() {
+ this.focusAdjacentOption('page_up');
+ }
+ }, {
+ key: 'focusPageDownOption',
+ value: function focusPageDownOption() {
+ this.focusAdjacentOption('page_down');
+ }
+ }, {
+ key: 'focusStartOption',
+ value: function focusStartOption() {
+ this.focusAdjacentOption('start');
+ }
+ }, {
+ key: 'focusEndOption',
+ value: function focusEndOption() {
+ this.focusAdjacentOption('end');
+ }
+ }, {
+ key: 'focusAdjacentOption',
+ value: function focusAdjacentOption(dir) {
+ var options = this._visibleOptions.map(function (option, index) {
+ return { option: option, index: index };
+ }).filter(function (option) {
+ return !option.option.disabled;
+ });
+ this._scrollToFocusedOptionOnUpdate = true;
+ if (!this.state.isOpen) {
+ var newState = {
+ focusedOption: this._focusedOption || (options.length ? options[dir === 'next' ? 0 : options.length - 1].option : null),
+ isOpen: true
+ };
+ if (this.props.onSelectResetsInput) {
+ newState.inputValue = '';
+ }
+ this.setState(newState);
+ return;
+ }
+ if (!options.length) return;
+ var focusedIndex = -1;
+ for (var i = 0; i < options.length; i++) {
+ if (this._focusedOption === options[i].option) {
+ focusedIndex = i;
+ break;
+ }
+ }
+ if (dir === 'next' && focusedIndex !== -1) {
+ focusedIndex = (focusedIndex + 1) % options.length;
+ } else if (dir === 'previous') {
+ if (focusedIndex > 0) {
+ focusedIndex = focusedIndex - 1;
+ } else {
+ focusedIndex = options.length - 1;
+ }
+ } else if (dir === 'start') {
+ focusedIndex = 0;
+ } else if (dir === 'end') {
+ focusedIndex = options.length - 1;
+ } else if (dir === 'page_up') {
+ var potentialIndex = focusedIndex - this.props.pageSize;
+ if (potentialIndex < 0) {
+ focusedIndex = 0;
+ } else {
+ focusedIndex = potentialIndex;
+ }
+ } else if (dir === 'page_down') {
+ var _potentialIndex = focusedIndex + this.props.pageSize;
+ if (_potentialIndex > options.length - 1) {
+ focusedIndex = options.length - 1;
+ } else {
+ focusedIndex = _potentialIndex;
+ }
+ }
-/** Detect free variable `self`. */
-var freeSelf = typeof self == 'object' && self && self.Object === Object && self;
+ if (focusedIndex === -1) {
+ focusedIndex = 0;
+ }
-/** Used as a reference to the global object. */
-var root = freeGlobal || freeSelf || Function('return this')();
+ this.setState({
+ focusedIndex: options[focusedIndex].index,
+ focusedOption: options[focusedIndex].option
+ });
+ }
+ }, {
+ key: 'getFocusedOption',
+ value: function getFocusedOption() {
+ return this._focusedOption;
+ }
+ }, {
+ key: 'selectFocusedOption',
+ value: function selectFocusedOption() {
+ if (this._focusedOption) {
+ return this.selectValue(this._focusedOption);
+ }
+ }
+ }, {
+ key: 'renderLoading',
+ value: function renderLoading() {
+ if (!this.props.isLoading) return;
+ return external_React_default.a.createElement(
+ 'span',
+ { className: 'Select-loading-zone', 'aria-hidden': 'true' },
+ external_React_default.a.createElement('span', { className: 'Select-loading' })
+ );
+ }
+ }, {
+ key: 'renderValue',
+ value: function renderValue(valueArray, isOpen) {
+ var _this5 = this;
-/**
- * A faster alternative to `Function#apply`, this function invokes `func`
- * with the `this` binding of `thisArg` and the arguments of `args`.
- *
- * @private
- * @param {Function} func The function to invoke.
- * @param {*} thisArg The `this` binding of `func`.
- * @param {Array} args The arguments to invoke `func` with.
- * @returns {*} Returns the result of `func`.
- */
-function apply(func, thisArg, args) {
- switch (args.length) {
- case 0: return func.call(thisArg);
- case 1: return func.call(thisArg, args[0]);
- case 2: return func.call(thisArg, args[0], args[1]);
- case 3: return func.call(thisArg, args[0], args[1], args[2]);
- }
- return func.apply(thisArg, args);
-}
+ var renderLabel = this.props.valueRenderer || this.getOptionLabel;
+ var ValueComponent = this.props.valueComponent;
+ if (!valueArray.length) {
+ var showPlaceholder = shouldShowPlaceholder(this.state, this.props, isOpen);
+ return showPlaceholder ? external_React_default.a.createElement(
+ 'div',
+ { className: 'Select-placeholder' },
+ this.props.placeholder
+ ) : null;
+ }
+ var onClick = this.props.onValueClick ? this.handleValueClick : null;
+ if (this.props.multi) {
+ return valueArray.map(function (value, i) {
+ return external_React_default.a.createElement(
+ ValueComponent,
+ {
+ disabled: _this5.props.disabled || value.clearableValue === false,
+ id: _this5._instancePrefix + '-value-' + i,
+ instancePrefix: _this5._instancePrefix,
+ key: 'value-' + i + '-' + value[_this5.props.valueKey],
+ onClick: onClick,
+ onRemove: _this5.removeValue,
+ placeholder: _this5.props.placeholder,
+ value: value,
+ values: valueArray
+ },
+ renderLabel(value, i),
+ external_React_default.a.createElement(
+ 'span',
+ { className: 'Select-aria-only' },
+ '\xA0'
+ )
+ );
+ });
+ } else if (shouldShowValue(this.state, this.props)) {
+ if (isOpen) onClick = null;
+ return external_React_default.a.createElement(
+ ValueComponent,
+ {
+ disabled: this.props.disabled,
+ id: this._instancePrefix + '-value-item',
+ instancePrefix: this._instancePrefix,
+ onClick: onClick,
+ placeholder: this.props.placeholder,
+ value: valueArray[0]
+ },
+ renderLabel(valueArray[0])
+ );
+ }
+ }
+ }, {
+ key: 'renderInput',
+ value: function renderInput(valueArray, focusedOptionIndex) {
+ var _classNames,
+ _this6 = this;
-/**
- * Appends the elements of `values` to `array`.
- *
- * @private
- * @param {Array} array The array to modify.
- * @param {Array} values The values to append.
- * @returns {Array} Returns `array`.
- */
-function arrayPush(array, values) {
- var index = -1,
- length = values.length,
- offset = array.length;
+ var className = classnames_default()('Select-input', this.props.inputProps.className);
+ var isOpen = this.state.isOpen;
- while (++index < length) {
- array[offset + index] = values[index];
- }
- return array;
-}
-
-/** Used for built-in method references. */
-var objectProto = Object.prototype;
+ var ariaOwns = classnames_default()((_classNames = {}, defineProperty(_classNames, this._instancePrefix + '-list', isOpen), defineProperty(_classNames, this._instancePrefix + '-backspace-remove-message', this.props.multi && !this.props.disabled && this.state.isFocused && !this.state.inputValue), _classNames));
-/** Used to check objects for own properties. */
-var hasOwnProperty = objectProto.hasOwnProperty;
+ var value = this.state.inputValue;
+ if (value && !this.props.onSelectResetsInput && !this.state.isFocused) {
+ // it hides input value when it is not focused and was not reset on select
+ value = '';
+ }
-/**
- * Used to resolve the
- * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)
- * of values.
- */
-var objectToString = objectProto.toString;
+ var inputProps = _extends({}, this.props.inputProps, {
+ 'aria-activedescendant': isOpen ? this._instancePrefix + '-option-' + focusedOptionIndex : this._instancePrefix + '-value',
+ 'aria-describedby': this.props['aria-describedby'],
+ 'aria-expanded': '' + isOpen,
+ 'aria-haspopup': '' + isOpen,
+ 'aria-label': this.props['aria-label'],
+ 'aria-labelledby': this.props['aria-labelledby'],
+ 'aria-owns': ariaOwns,
+ onBlur: this.handleInputBlur,
+ onChange: this.handleInputChange,
+ onFocus: this.handleInputFocus,
+ ref: function ref(_ref) {
+ return _this6.input = _ref;
+ },
+ role: 'combobox',
+ required: this.state.required,
+ tabIndex: this.props.tabIndex,
+ value: value
+ });
-/** Built-in value references. */
-var Symbol = root.Symbol,
- propertyIsEnumerable = objectProto.propertyIsEnumerable,
- spreadableSymbol = Symbol ? Symbol.isConcatSpreadable : undefined;
+ if (this.props.inputRenderer) {
+ return this.props.inputRenderer(inputProps);
+ }
-/* Built-in method references for those with the same name as other `lodash` methods. */
-var nativeMax = Math.max;
+ if (this.props.disabled || !this.props.searchable) {
+ var divProps = objectWithoutProperties(this.props.inputProps, []);
-/**
- * The base implementation of `_.flatten` with support for restricting flattening.
- *
- * @private
- * @param {Array} array The array to flatten.
- * @param {number} depth The maximum recursion depth.
- * @param {boolean} [predicate=isFlattenable] The function invoked per iteration.
- * @param {boolean} [isStrict] Restrict to values that pass `predicate` checks.
- * @param {Array} [result=[]] The initial result value.
- * @returns {Array} Returns the new flattened array.
- */
-function baseFlatten(array, depth, predicate, isStrict, result) {
- var index = -1,
- length = array.length;
- predicate || (predicate = isFlattenable);
- result || (result = []);
+ var _ariaOwns = classnames_default()(defineProperty({}, this._instancePrefix + '-list', isOpen));
+ return external_React_default.a.createElement('div', _extends({}, divProps, {
+ 'aria-expanded': isOpen,
+ 'aria-owns': _ariaOwns,
+ 'aria-activedescendant': isOpen ? this._instancePrefix + '-option-' + focusedOptionIndex : this._instancePrefix + '-value',
+ 'aria-disabled': '' + this.props.disabled,
+ 'aria-label': this.props['aria-label'],
+ 'aria-labelledby': this.props['aria-labelledby'],
+ className: className,
+ onBlur: this.handleInputBlur,
+ onFocus: this.handleInputFocus,
+ ref: function ref(_ref2) {
+ return _this6.input = _ref2;
+ },
+ role: 'combobox',
+ style: { border: 0, width: 1, display: 'inline-block' },
+ tabIndex: this.props.tabIndex || 0
+ }));
+ }
- while (++index < length) {
- var value = array[index];
- if (depth > 0 && predicate(value)) {
- if (depth > 1) {
- // Recursively flatten arrays (susceptible to call stack limits).
- baseFlatten(value, depth - 1, predicate, isStrict, result);
- } else {
- arrayPush(result, value);
- }
- } else if (!isStrict) {
- result[result.length] = value;
- }
- }
- return result;
-}
+ if (this.props.autosize) {
+ return external_React_default.a.createElement(AutosizeInput_default.a, _extends({ id: this.props.id }, inputProps, { className: className, minWidth: '5' }));
+ }
+ return external_React_default.a.createElement(
+ 'div',
+ { className: className, key: 'input-wrap', style: { display: 'inline-block' } },
+ external_React_default.a.createElement('input', _extends({ id: this.props.id }, inputProps))
+ );
+ }
+ }, {
+ key: 'renderClear',
+ value: function renderClear() {
+ var valueArray = this.getValueArray(this.props.value);
+ if (!this.props.clearable || !valueArray.length || this.props.disabled || this.props.isLoading) return;
+ var ariaLabel = this.props.multi ? this.props.clearAllText : this.props.clearValueText;
+ var clear = this.props.clearRenderer();
-/**
- * The base implementation of `_.rest` which doesn't validate or coerce arguments.
- *
- * @private
- * @param {Function} func The function to apply a rest parameter to.
- * @param {number} [start=func.length-1] The start position of the rest parameter.
- * @returns {Function} Returns the new function.
- */
-function baseRest(func, start) {
- start = nativeMax(start === undefined ? (func.length - 1) : start, 0);
- return function() {
- var args = arguments,
- index = -1,
- length = nativeMax(args.length - start, 0),
- array = Array(length);
+ return external_React_default.a.createElement(
+ 'span',
+ {
+ 'aria-label': ariaLabel,
+ className: 'Select-clear-zone',
+ onMouseDown: this.clearValue,
+ onTouchEnd: this.handleTouchEndClearValue,
+ onTouchMove: this.handleTouchMove,
+ onTouchStart: this.handleTouchStart,
+ title: ariaLabel
+ },
+ clear
+ );
+ }
+ }, {
+ key: 'renderArrow',
+ value: function renderArrow() {
+ if (!this.props.arrowRenderer) return;
- while (++index < length) {
- array[index] = args[start + index];
- }
- index = -1;
- var otherArgs = Array(start + 1);
- while (++index < start) {
- otherArgs[index] = args[index];
- }
- otherArgs[start] = array;
- return apply(func, this, otherArgs);
- };
-}
+ var onMouseDown = this.handleMouseDownOnArrow;
+ var isOpen = this.state.isOpen;
+ var arrow = this.props.arrowRenderer({ onMouseDown: onMouseDown, isOpen: isOpen });
-/**
- * Creates a `_.flow` or `_.flowRight` function.
- *
- * @private
- * @param {boolean} [fromRight] Specify iterating from right to left.
- * @returns {Function} Returns the new flow function.
- */
-function createFlow(fromRight) {
- return baseRest(function(funcs) {
- funcs = baseFlatten(funcs, 1);
+ if (!arrow) {
+ return null;
+ }
- var length = funcs.length,
- index = length;
+ return external_React_default.a.createElement(
+ 'span',
+ {
+ className: 'Select-arrow-zone',
+ onMouseDown: onMouseDown
+ },
+ arrow
+ );
+ }
+ }, {
+ key: 'filterOptions',
+ value: function filterOptions$$1(excludeOptions) {
+ var filterValue = this.state.inputValue;
+ var options = this.props.options || [];
+ if (this.props.filterOptions) {
+ // Maintain backwards compatibility with boolean attribute
+ var filterOptions$$1 = typeof this.props.filterOptions === 'function' ? this.props.filterOptions : filterOptions;
- if (fromRight) {
- funcs.reverse();
- }
- while (index--) {
- if (typeof funcs[index] != 'function') {
- throw new TypeError(FUNC_ERROR_TEXT);
- }
- }
- return function() {
- var index = 0,
- result = length ? funcs[index].apply(this, arguments) : arguments[0];
+ return filterOptions$$1(options, filterValue, excludeOptions, {
+ filterOption: this.props.filterOption,
+ ignoreAccents: this.props.ignoreAccents,
+ ignoreCase: this.props.ignoreCase,
+ labelKey: this.props.labelKey,
+ matchPos: this.props.matchPos,
+ matchProp: this.props.matchProp,
+ trimFilter: this.props.trimFilter,
+ valueKey: this.props.valueKey
+ });
+ } else {
+ return options;
+ }
+ }
+ }, {
+ key: 'onOptionRef',
+ value: function onOptionRef(ref, isFocused) {
+ if (isFocused) {
+ this.focused = ref;
+ }
+ }
+ }, {
+ key: 'renderMenu',
+ value: function renderMenu(options, valueArray, focusedOption) {
+ if (options && options.length) {
+ return this.props.menuRenderer({
+ focusedOption: focusedOption,
+ focusOption: this.focusOption,
+ inputValue: this.state.inputValue,
+ instancePrefix: this._instancePrefix,
+ labelKey: this.props.labelKey,
+ onFocus: this.focusOption,
+ onOptionRef: this.onOptionRef,
+ onSelect: this.selectValue,
+ optionClassName: this.props.optionClassName,
+ optionComponent: this.props.optionComponent,
+ optionRenderer: this.props.optionRenderer || this.getOptionLabel,
+ options: options,
+ removeValue: this.removeValue,
+ selectValue: this.selectValue,
+ valueArray: valueArray,
+ valueKey: this.props.valueKey
+ });
+ } else if (this.props.noResultsText) {
+ return external_React_default.a.createElement(
+ 'div',
+ { className: 'Select-noresults' },
+ this.props.noResultsText
+ );
+ } else {
+ return null;
+ }
+ }
+ }, {
+ key: 'renderHiddenField',
+ value: function renderHiddenField(valueArray) {
+ var _this7 = this;
- while (++index < length) {
- result = funcs[index].call(this, result);
- }
- return result;
- };
- });
-}
+ if (!this.props.name) return;
+ if (this.props.joinValues) {
+ var value = valueArray.map(function (i) {
+ return stringifyValue(i[_this7.props.valueKey]);
+ }).join(this.props.delimiter);
+ return external_React_default.a.createElement('input', {
+ disabled: this.props.disabled,
+ name: this.props.name,
+ ref: function ref(_ref3) {
+ return _this7.value = _ref3;
+ },
+ type: 'hidden',
+ value: value
+ });
+ }
+ return valueArray.map(function (item, index) {
+ return external_React_default.a.createElement('input', {
+ disabled: _this7.props.disabled,
+ key: 'hidden.' + index,
+ name: _this7.props.name,
+ ref: 'value' + index,
+ type: 'hidden',
+ value: stringifyValue(item[_this7.props.valueKey])
+ });
+ });
+ }
+ }, {
+ key: 'getFocusableOptionIndex',
+ value: function getFocusableOptionIndex(selectedOption) {
+ var options = this._visibleOptions;
+ if (!options.length) return null;
-/**
- * Checks if `value` is a flattenable `arguments` object or array.
- *
- * @private
- * @param {*} value The value to check.
- * @returns {boolean} Returns `true` if `value` is flattenable, else `false`.
- */
-function isFlattenable(value) {
- return isArray(value) || isArguments(value) ||
- !!(spreadableSymbol && value && value[spreadableSymbol]);
-}
+ var valueKey = this.props.valueKey;
+ var focusedOption = this.state.focusedOption || selectedOption;
+ if (focusedOption && !focusedOption.disabled) {
+ var focusedOptionIndex = -1;
+ options.some(function (option, index) {
+ var isOptionEqual = option[valueKey] === focusedOption[valueKey];
+ if (isOptionEqual) {
+ focusedOptionIndex = index;
+ }
+ return isOptionEqual;
+ });
+ if (focusedOptionIndex !== -1) {
+ return focusedOptionIndex;
+ }
+ }
-/**
- * Checks if `value` is likely an `arguments` object.
- *
- * @static
- * @memberOf _
- * @since 0.1.0
- * @category Lang
- * @param {*} value The value to check.
- * @returns {boolean} Returns `true` if `value` is an `arguments` object,
- * else `false`.
- * @example
- *
- * _.isArguments(function() { return arguments; }());
- * // => true
- *
- * _.isArguments([1, 2, 3]);
- * // => false
- */
-function isArguments(value) {
- // Safari 8.1 makes `arguments.callee` enumerable in strict mode.
- return isArrayLikeObject(value) && hasOwnProperty.call(value, 'callee') &&
- (!propertyIsEnumerable.call(value, 'callee') || objectToString.call(value) == argsTag);
-}
+ for (var i = 0; i < options.length; i++) {
+ if (!options[i].disabled) return i;
+ }
+ return null;
+ }
+ }, {
+ key: 'renderOuter',
+ value: function renderOuter(options, valueArray, focusedOption) {
+ var _this8 = this;
-/**
- * Checks if `value` is classified as an `Array` object.
- *
- * @static
- * @memberOf _
- * @since 0.1.0
- * @category Lang
- * @param {*} value The value to check.
- * @returns {boolean} Returns `true` if `value` is an array, else `false`.
- * @example
- *
- * _.isArray([1, 2, 3]);
- * // => true
- *
- * _.isArray(document.body.children);
- * // => false
- *
- * _.isArray('abc');
- * // => false
- *
- * _.isArray(_.noop);
- * // => false
- */
-var isArray = Array.isArray;
+ var menu = this.renderMenu(options, valueArray, focusedOption);
+ if (!menu) {
+ return null;
+ }
-/**
- * Checks if `value` is array-like. A value is considered array-like if it's
- * not a function and has a `value.length` that's an integer greater than or
- * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`.
- *
- * @static
- * @memberOf _
- * @since 4.0.0
- * @category Lang
- * @param {*} value The value to check.
- * @returns {boolean} Returns `true` if `value` is array-like, else `false`.
- * @example
- *
- * _.isArrayLike([1, 2, 3]);
- * // => true
- *
- * _.isArrayLike(document.body.children);
- * // => true
- *
- * _.isArrayLike('abc');
- * // => true
- *
- * _.isArrayLike(_.noop);
- * // => false
- */
-function isArrayLike(value) {
- return value != null && isLength(value.length) && !isFunction(value);
-}
+ return external_React_default.a.createElement(
+ 'div',
+ { ref: function ref(_ref5) {
+ return _this8.menuContainer = _ref5;
+ }, className: 'Select-menu-outer', style: this.props.menuContainerStyle },
+ external_React_default.a.createElement(
+ 'div',
+ {
+ className: 'Select-menu',
+ id: this._instancePrefix + '-list',
+ onMouseDown: this.handleMouseDownOnMenu,
+ onScroll: this.handleMenuScroll,
+ ref: function ref(_ref4) {
+ return _this8.menu = _ref4;
+ },
+ role: 'listbox',
+ style: this.props.menuStyle,
+ tabIndex: -1
+ },
+ menu
+ )
+ );
+ }
+ }, {
+ key: 'render',
+ value: function render() {
+ var _this9 = this;
-/**
- * This method is like `_.isArrayLike` except that it also checks if `value`
- * is an object.
- *
- * @static
- * @memberOf _
- * @since 4.0.0
- * @category Lang
- * @param {*} value The value to check.
- * @returns {boolean} Returns `true` if `value` is an array-like object,
- * else `false`.
- * @example
- *
- * _.isArrayLikeObject([1, 2, 3]);
- * // => true
- *
- * _.isArrayLikeObject(document.body.children);
- * // => true
- *
- * _.isArrayLikeObject('abc');
- * // => false
- *
- * _.isArrayLikeObject(_.noop);
- * // => false
- */
-function isArrayLikeObject(value) {
- return isObjectLike(value) && isArrayLike(value);
-}
+ var valueArray = this.getValueArray(this.props.value);
+ var options = this._visibleOptions = this.filterOptions(this.props.multi && this.props.removeSelected ? valueArray : null);
+ var isOpen = this.state.isOpen;
+ if (this.props.multi && !options.length && valueArray.length && !this.state.inputValue) isOpen = false;
+ var focusedOptionIndex = this.getFocusableOptionIndex(valueArray[0]);
-/**
- * Checks if `value` is classified as a `Function` object.
- *
- * @static
- * @memberOf _
- * @since 0.1.0
- * @category Lang
- * @param {*} value The value to check.
- * @returns {boolean} Returns `true` if `value` is a function, else `false`.
- * @example
- *
- * _.isFunction(_);
- * // => true
- *
- * _.isFunction(/abc/);
- * // => false
- */
-function isFunction(value) {
- // The use of `Object#toString` avoids issues with the `typeof` operator
- // in Safari 8-9 which returns 'object' for typed array and other constructors.
- var tag = isObject(value) ? objectToString.call(value) : '';
- return tag == funcTag || tag == genTag;
-}
+ var focusedOption = null;
+ if (focusedOptionIndex !== null) {
+ focusedOption = this._focusedOption = options[focusedOptionIndex];
+ } else {
+ focusedOption = this._focusedOption = null;
+ }
+ var className = classnames_default()('Select', this.props.className, {
+ 'has-value': valueArray.length,
+ 'is-clearable': this.props.clearable,
+ 'is-disabled': this.props.disabled,
+ 'is-focused': this.state.isFocused,
+ 'is-loading': this.props.isLoading,
+ 'is-open': isOpen,
+ 'is-pseudo-focused': this.state.isPseudoFocused,
+ 'is-searchable': this.props.searchable,
+ 'Select--multi': this.props.multi,
+ 'Select--rtl': this.props.rtl,
+ 'Select--single': !this.props.multi
+ });
-/**
- * Checks if `value` is a valid array-like length.
- *
- * **Note:** This method is loosely based on
- * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength).
- *
- * @static
- * @memberOf _
- * @since 4.0.0
- * @category Lang
- * @param {*} value The value to check.
- * @returns {boolean} Returns `true` if `value` is a valid length, else `false`.
- * @example
- *
- * _.isLength(3);
- * // => true
- *
- * _.isLength(Number.MIN_VALUE);
- * // => false
- *
- * _.isLength(Infinity);
- * // => false
- *
- * _.isLength('3');
- * // => false
- */
-function isLength(value) {
- return typeof value == 'number' &&
- value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;
-}
-
-/**
- * Checks if `value` is the
- * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)
- * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)
- *
- * @static
- * @memberOf _
- * @since 0.1.0
- * @category Lang
- * @param {*} value The value to check.
- * @returns {boolean} Returns `true` if `value` is an object, else `false`.
- * @example
- *
- * _.isObject({});
- * // => true
- *
- * _.isObject([1, 2, 3]);
- * // => true
- *
- * _.isObject(_.noop);
- * // => true
- *
- * _.isObject(null);
- * // => false
- */
-function isObject(value) {
- var type = typeof value;
- return !!value && (type == 'object' || type == 'function');
-}
-
-/**
- * Checks if `value` is object-like. A value is object-like if it's not `null`
- * and has a `typeof` result of "object".
- *
- * @static
- * @memberOf _
- * @since 4.0.0
- * @category Lang
- * @param {*} value The value to check.
- * @returns {boolean} Returns `true` if `value` is object-like, else `false`.
- * @example
- *
- * _.isObjectLike({});
- * // => true
- *
- * _.isObjectLike([1, 2, 3]);
- * // => true
- *
- * _.isObjectLike(_.noop);
- * // => false
- *
- * _.isObjectLike(null);
- * // => false
- */
-function isObjectLike(value) {
- return !!value && typeof value == 'object';
-}
+ var removeMessage = null;
+ if (this.props.multi && !this.props.disabled && valueArray.length && !this.state.inputValue && this.state.isFocused && this.props.backspaceRemoves) {
+ removeMessage = external_React_default.a.createElement(
+ 'span',
+ { id: this._instancePrefix + '-backspace-remove-message', className: 'Select-aria-only', 'aria-live': 'assertive' },
+ this.props.backspaceToRemoveMessage.replace('{label}', valueArray[valueArray.length - 1][this.props.labelKey])
+ );
+ }
-/**
- * Creates a function that returns the result of invoking the given functions
- * with the `this` binding of the created function, where each successive
- * invocation is supplied the return value of the previous.
- *
- * @static
- * @memberOf _
- * @since 3.0.0
- * @category Util
- * @param {...(Function|Function[])} [funcs] The functions to invoke.
- * @returns {Function} Returns the new composite function.
- * @see _.flowRight
- * @example
- *
- * function square(n) {
- * return n * n;
- * }
- *
- * var addSquare = _.flow([_.add, square]);
- * addSquare(1, 2);
- * // => 9
- */
-var flow = createFlow();
+ return external_React_default.a.createElement(
+ 'div',
+ { ref: function ref(_ref7) {
+ return _this9.wrapper = _ref7;
+ },
+ className: className,
+ style: this.props.wrapperStyle },
+ this.renderHiddenField(valueArray),
+ external_React_default.a.createElement(
+ 'div',
+ { ref: function ref(_ref6) {
+ return _this9.control = _ref6;
+ },
+ className: 'Select-control',
+ onKeyDown: this.handleKeyDown,
+ onMouseDown: this.handleMouseDown,
+ onTouchEnd: this.handleTouchEnd,
+ onTouchMove: this.handleTouchMove,
+ onTouchStart: this.handleTouchStart,
+ style: this.props.style
+ },
+ external_React_default.a.createElement(
+ 'div',
+ { className: 'Select-multi-value-wrapper', id: this._instancePrefix + '-value' },
+ this.renderValue(valueArray, isOpen),
+ this.renderInput(valueArray, focusedOptionIndex)
+ ),
+ removeMessage,
+ this.renderLoading(),
+ this.renderClear(),
+ this.renderArrow()
+ ),
+ isOpen ? this.renderOuter(options, valueArray, focusedOption) : null
+ );
+ }
+ }]);
+ return Select;
+}(external_React_default.a.Component);
-module.exports = flow;
+Select$1.propTypes = {
+ 'aria-describedby': prop_types_default.a.string, // html id(s) of element(s) that should be used to describe this input (for assistive tech)
+ 'aria-label': prop_types_default.a.string, // aria label (for assistive tech)
+ 'aria-labelledby': prop_types_default.a.string, // html id of an element that should be used as the label (for assistive tech)
+ arrowRenderer: prop_types_default.a.func, // create the drop-down caret element
+ autoBlur: prop_types_default.a.bool, // automatically blur the component when an option is selected
+ autoFocus: prop_types_default.a.bool, // autofocus the component on mount
+ autofocus: prop_types_default.a.bool, // deprecated; use autoFocus instead
+ autosize: prop_types_default.a.bool, // whether to enable autosizing or not
+ backspaceRemoves: prop_types_default.a.bool, // whether backspace removes an item if there is no text input
+ backspaceToRemoveMessage: prop_types_default.a.string, // message to use for screenreaders to press backspace to remove the current item - {label} is replaced with the item label
+ className: prop_types_default.a.string, // className for the outer element
+ clearAllText: stringOrNode, // title for the "clear" control when multi: true
+ clearRenderer: prop_types_default.a.func, // create clearable x element
+ clearValueText: stringOrNode, // title for the "clear" control
+ clearable: prop_types_default.a.bool, // should it be possible to reset value
+ closeOnSelect: prop_types_default.a.bool, // whether to close the menu when a value is selected
+ deleteRemoves: prop_types_default.a.bool, // whether delete removes an item if there is no text input
+ delimiter: prop_types_default.a.string, // delimiter to use to join multiple values for the hidden field value
+ disabled: prop_types_default.a.bool, // whether the Select is disabled or not
+ escapeClearsValue: prop_types_default.a.bool, // whether escape clears the value when the menu is closed
+ filterOption: prop_types_default.a.func, // method to filter a single option (option, filterString)
+ filterOptions: prop_types_default.a.any, // boolean to enable default filtering or function to filter the options array ([options], filterString, [values])
+ id: prop_types_default.a.string, // html id to set on the input element for accessibility or tests
+ ignoreAccents: prop_types_default.a.bool, // whether to strip diacritics when filtering
+ ignoreCase: prop_types_default.a.bool, // whether to perform case-insensitive filtering
+ inputProps: prop_types_default.a.object, // custom attributes for the Input
+ inputRenderer: prop_types_default.a.func, // returns a custom input component
+ instanceId: prop_types_default.a.string, // set the components instanceId
+ isLoading: prop_types_default.a.bool, // whether the Select is loading externally or not (such as options being loaded)
+ joinValues: prop_types_default.a.bool, // joins multiple values into a single form field with the delimiter (legacy mode)
+ labelKey: prop_types_default.a.string, // path of the label value in option objects
+ matchPos: prop_types_default.a.string, // (any|start) match the start or entire string when filtering
+ matchProp: prop_types_default.a.string, // (any|label|value) which option property to filter on
+ menuBuffer: prop_types_default.a.number, // optional buffer (in px) between the bottom of the viewport and the bottom of the menu
+ menuContainerStyle: prop_types_default.a.object, // optional style to apply to the menu container
+ menuRenderer: prop_types_default.a.func, // renders a custom menu with options
+ menuStyle: prop_types_default.a.object, // optional style to apply to the menu
+ multi: prop_types_default.a.bool, // multi-value input
+ name: prop_types_default.a.string, // generates a hidden tag with this field name for html forms
+ noResultsText: stringOrNode, // placeholder displayed when there are no matching search results
+ onBlur: prop_types_default.a.func, // onBlur handler: function (event) {}
+ onBlurResetsInput: prop_types_default.a.bool, // whether input is cleared on blur
+ onChange: prop_types_default.a.func, // onChange handler: function (newValue) {}
+ onClose: prop_types_default.a.func, // fires when the menu is closed
+ onCloseResetsInput: prop_types_default.a.bool, // whether input is cleared when menu is closed through the arrow
+ onFocus: prop_types_default.a.func, // onFocus handler: function (event) {}
+ onInputChange: prop_types_default.a.func, // onInputChange handler: function (inputValue) {}
+ onInputKeyDown: prop_types_default.a.func, // input keyDown handler: function (event) {}
+ onMenuScrollToBottom: prop_types_default.a.func, // fires when the menu is scrolled to the bottom; can be used to paginate options
+ onOpen: prop_types_default.a.func, // fires when the menu is opened
+ onSelectResetsInput: prop_types_default.a.bool, // whether input is cleared on select (works only for multiselect)
+ onValueClick: prop_types_default.a.func, // onClick handler for value labels: function (value, event) {}
+ openOnClick: prop_types_default.a.bool, // boolean to control opening the menu when the control is clicked
+ openOnFocus: prop_types_default.a.bool, // always open options menu on focus
+ optionClassName: prop_types_default.a.string, // additional class(es) to apply to the elements
+ optionComponent: prop_types_default.a.func, // option component to render in dropdown
+ optionRenderer: prop_types_default.a.func, // optionRenderer: function (option) {}
+ options: prop_types_default.a.array, // array of options
+ pageSize: prop_types_default.a.number, // number of entries to page when using page up/down keys
+ placeholder: stringOrNode, // field placeholder, displayed when there's no value
+ removeSelected: prop_types_default.a.bool, // whether the selected option is removed from the dropdown on multi selects
+ required: prop_types_default.a.bool, // applies HTML5 required attribute when needed
+ resetValue: prop_types_default.a.any, // value to use when you clear the control
+ rtl: prop_types_default.a.bool, // set to true in order to use react-select in right-to-left direction
+ scrollMenuIntoView: prop_types_default.a.bool, // boolean to enable the viewport to shift so that the full menu fully visible when engaged
+ searchable: prop_types_default.a.bool, // whether to enable searching feature or not
+ simpleValue: prop_types_default.a.bool, // pass the value to onChange as a simple value (legacy pre 1.0 mode), defaults to false
+ style: prop_types_default.a.object, // optional style to apply to the control
+ tabIndex: stringOrNumber, // optional tab index of the control
+ tabSelectsValue: prop_types_default.a.bool, // whether to treat tabbing out while focused to be value selection
+ trimFilter: prop_types_default.a.bool, // whether to trim whitespace around filter value
+ value: prop_types_default.a.any, // initial field value
+ valueComponent: prop_types_default.a.func, // value component to render
+ valueKey: prop_types_default.a.string, // path of the label value in option objects
+ valueRenderer: prop_types_default.a.func, // valueRenderer: function (option) {}
+ wrapperStyle: prop_types_default.a.object // optional style to apply to the component wrapper
+};
-/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(57)))
+Select$1.defaultProps = {
+ arrowRenderer: react_select_es_arrowRenderer,
+ autosize: true,
+ backspaceRemoves: true,
+ backspaceToRemoveMessage: 'Press backspace to remove {label}',
+ clearable: true,
+ clearAllText: 'Clear all',
+ clearRenderer: react_select_es_clearRenderer,
+ clearValueText: 'Clear value',
+ closeOnSelect: true,
+ deleteRemoves: true,
+ delimiter: ',',
+ disabled: false,
+ escapeClearsValue: true,
+ filterOptions: filterOptions,
+ ignoreAccents: true,
+ ignoreCase: true,
+ inputProps: {},
+ isLoading: false,
+ joinValues: false,
+ labelKey: 'label',
+ matchPos: 'any',
+ matchProp: 'any',
+ menuBuffer: 0,
+ menuRenderer: react_select_es_menuRenderer,
+ multi: false,
+ noResultsText: 'No results found',
+ onBlurResetsInput: true,
+ onCloseResetsInput: true,
+ onSelectResetsInput: true,
+ openOnClick: true,
+ optionComponent: react_select_es_Option,
+ pageSize: 5,
+ placeholder: 'Select...',
+ removeSelected: true,
+ required: false,
+ rtl: false,
+ scrollMenuIntoView: true,
+ searchable: true,
+ simpleValue: false,
+ tabSelectsValue: true,
+ trimFilter: true,
+ valueComponent: react_select_es_Value,
+ valueKey: 'value'
+};
-/***/ }),
-/* 169 */
-/***/ (function(module, exports, __webpack_require__) {
+var propTypes = {
+ autoload: prop_types_default.a.bool.isRequired, // automatically call the `loadOptions` prop on-mount; defaults to true
+ cache: prop_types_default.a.any, // object to use to cache results; set to null/false to disable caching
+ children: prop_types_default.a.func.isRequired, // Child function responsible for creating the inner Select component; (props: Object): PropTypes.element
+ ignoreAccents: prop_types_default.a.bool, // strip diacritics when filtering; defaults to true
+ ignoreCase: prop_types_default.a.bool, // perform case-insensitive filtering; defaults to true
+ loadOptions: prop_types_default.a.func.isRequired, // callback to load options asynchronously; (inputValue: string, callback: Function): ?Promise
+ loadingPlaceholder: prop_types_default.a.oneOfType([// replaces the placeholder while options are loading
+ prop_types_default.a.string, prop_types_default.a.node]),
+ multi: prop_types_default.a.bool, // multi-value input
+ noResultsText: prop_types_default.a.oneOfType([// field noResultsText, displayed when no options come back from the server
+ prop_types_default.a.string, prop_types_default.a.node]),
+ onChange: prop_types_default.a.func, // onChange handler: function (newValue) {}
+ onInputChange: prop_types_default.a.func, // optional for keeping track of what is being typed
+ options: prop_types_default.a.array.isRequired, // array of options
+ placeholder: prop_types_default.a.oneOfType([// field placeholder, displayed when there's no value (shared with Select)
+ prop_types_default.a.string, prop_types_default.a.node]),
+ searchPromptText: prop_types_default.a.oneOfType([// label to prompt for search input
+ prop_types_default.a.string, prop_types_default.a.node]),
+ value: prop_types_default.a.any // initial field value
+};
-"use strict";
+var defaultCache = {};
+var react_select_es_defaultChildren = function defaultChildren(props) {
+ return external_React_default.a.createElement(Select$1, props);
+};
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
-exports.yuv2rgb = yuv2rgb;
-exports.rgb2yuv = rgb2yuv;
-function yuv2rgb(yuv) {
- var y = yuv[0],
- u = yuv[1],
- v = yuv[2],
- r,
- g,
- b;
+var defaultProps = {
+ autoload: true,
+ cache: defaultCache,
+ children: react_select_es_defaultChildren,
+ ignoreAccents: true,
+ ignoreCase: true,
+ loadingPlaceholder: 'Loading...',
+ options: [],
+ searchPromptText: 'Type to search'
+};
- r = y * 1 + u * 0 + v * 1.13983;
- g = y * 1 + u * -0.39465 + v * -0.58060;
- b = y * 1 + u * 2.02311 + v * 0;
+var Async = function (_Component) {
+ inherits(Async, _Component);
- r = Math.min(Math.max(0, r), 1);
- g = Math.min(Math.max(0, g), 1);
- b = Math.min(Math.max(0, b), 1);
+ function Async(props, context) {
+ classCallCheck(this, Async);
- return [r * 255, g * 255, b * 255];
-}
+ var _this = possibleConstructorReturn(this, (Async.__proto__ || Object.getPrototypeOf(Async)).call(this, props, context));
-function rgb2yuv(rgb) {
- var r = rgb[0] / 255,
- g = rgb[1] / 255,
- b = rgb[2] / 255;
+ _this._cache = props.cache === defaultCache ? {} : props.cache;
- var y = r * 0.299 + g * 0.587 + b * 0.114;
- var u = r * -0.14713 + g * -0.28886 + b * 0.436;
- var v = r * 0.615 + g * -0.51499 + b * -0.10001;
+ _this.state = {
+ inputValue: '',
+ isLoading: false,
+ options: props.options
+ };
- return [y, u, v];
-};
+ _this.onInputChange = _this.onInputChange.bind(_this);
+ return _this;
+ }
-/***/ }),
-/* 170 */
-/***/ (function(module, exports, __webpack_require__) {
+ createClass(Async, [{
+ key: 'componentDidMount',
+ value: function componentDidMount() {
+ var autoload = this.props.autoload;
-"use strict";
+ if (autoload) {
+ this.loadOptions('');
+ }
+ }
+ }, {
+ key: 'componentWillReceiveProps',
+ value: function componentWillReceiveProps(nextProps) {
+ if (nextProps.options !== this.props.options) {
+ this.setState({
+ options: nextProps.options
+ });
+ }
+ }
+ }, {
+ key: 'componentWillUnmount',
+ value: function componentWillUnmount() {
+ this._callback = null;
+ }
+ }, {
+ key: 'loadOptions',
+ value: function loadOptions(inputValue) {
+ var _this2 = this;
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
-
-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 _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__(1);
+ var loadOptions = this.props.loadOptions;
-var _react2 = _interopRequireDefault(_react);
+ var cache = this._cache;
-var _DataTypeLabel = __webpack_require__(9);
+ if (cache && Object.prototype.hasOwnProperty.call(cache, inputValue)) {
+ this._callback = null;
-var _DataTypeLabel2 = _interopRequireDefault(_DataTypeLabel);
+ this.setState({
+ isLoading: false,
+ options: cache[inputValue]
+ });
-var _getStyle = __webpack_require__(2);
+ return;
+ }
-var _getStyle2 = _interopRequireDefault(_getStyle);
+ var callback = function callback(error, data) {
+ var options = data && data.options || [];
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+ if (cache) {
+ cache[inputValue] = options;
+ }
-function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
+ if (callback === _this2._callback) {
+ _this2._callback = null;
-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; }
+ _this2.setState({
+ isLoading: false,
+ options: options
+ });
+ }
+ };
-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; }
+ // Ignore all but the most recent request
+ this._callback = callback;
-//theme
+ var promise = loadOptions(inputValue, callback);
+ if (promise) {
+ promise.then(function (data) {
+ return callback(null, data);
+ }, function (error) {
+ return callback(error);
+ });
+ }
+ if (this._callback && !this.state.isLoading) {
+ this.setState({
+ isLoading: true
+ });
+ }
+ }
+ }, {
+ key: 'onInputChange',
+ value: function onInputChange(inputValue) {
+ var _props = this.props,
+ ignoreAccents = _props.ignoreAccents,
+ ignoreCase = _props.ignoreCase,
+ onInputChange = _props.onInputChange;
-var _class = function (_React$PureComponent) {
- _inherits(_class, _React$PureComponent);
+ var newInputValue = inputValue;
- function _class() {
- _classCallCheck(this, _class);
+ if (onInputChange) {
+ var value = onInputChange(newInputValue);
+ // Note: != used deliberately here to catch undefined and null
+ if (value != null && (typeof value === 'undefined' ? 'undefined' : react_select_es_typeof(value)) !== 'object') {
+ newInputValue = '' + value;
+ }
+ }
- return _possibleConstructorReturn(this, (_class.__proto__ || Object.getPrototypeOf(_class)).apply(this, arguments));
- }
+ var transformedInputValue = newInputValue;
- _createClass(_class, [{
- key: 'render',
- value: function render() {
- var type_name = 'date';
- var props = this.props;
+ if (ignoreAccents) {
+ transformedInputValue = stripDiacritics(transformedInputValue);
+ }
- var display_options = {
- weekday: 'short',
- year: 'numeric',
- month: 'short',
- day: 'numeric',
- hour: '2-digit',
- minute: '2-digit'
- };
- return _react2.default.createElement(
- 'div',
- (0, _getStyle2.default)(props.theme, 'date'),
- _react2.default.createElement(_DataTypeLabel2.default, _extends({ type_name: type_name }, props)),
- _react2.default.createElement(
- 'span',
- _extends({ className: 'date-value' }, (0, _getStyle2.default)(props.theme, 'date-value')),
- props.value.toLocaleTimeString('en-us', display_options)
- )
- );
- }
- }]);
+ if (ignoreCase) {
+ transformedInputValue = transformedInputValue.toLowerCase();
+ }
- return _class;
-}(_react2.default.PureComponent);
+ this.setState({ inputValue: newInputValue });
+ this.loadOptions(transformedInputValue);
-exports.default = _class;
+ // Return new input value, but without applying toLowerCase() to avoid modifying the user's view case of the input while typing.
+ return newInputValue;
+ }
+ }, {
+ key: 'noResultsText',
+ value: function noResultsText() {
+ var _props2 = this.props,
+ loadingPlaceholder = _props2.loadingPlaceholder,
+ noResultsText = _props2.noResultsText,
+ searchPromptText = _props2.searchPromptText;
+ var _state = this.state,
+ inputValue = _state.inputValue,
+ isLoading = _state.isLoading;
-/***/ }),
-/* 171 */
-/***/ (function(module, exports, __webpack_require__) {
-"use strict";
+ if (isLoading) {
+ return loadingPlaceholder;
+ }
+ if (inputValue && noResultsText) {
+ return noResultsText;
+ }
+ return searchPromptText;
+ }
+ }, {
+ key: 'focus',
+ value: function focus() {
+ this.select.focus();
+ }
+ }, {
+ key: 'render',
+ value: function render() {
+ var _this3 = this;
+ var _props3 = this.props,
+ children = _props3.children,
+ loadingPlaceholder = _props3.loadingPlaceholder,
+ placeholder = _props3.placeholder;
+ var _state2 = this.state,
+ isLoading = _state2.isLoading,
+ options = _state2.options;
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
-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 props = {
+ noResultsText: this.noResultsText(),
+ placeholder: isLoading ? loadingPlaceholder : placeholder,
+ options: isLoading && loadingPlaceholder ? [] : options,
+ ref: function ref(_ref) {
+ return _this3.select = _ref;
+ }
+ };
-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; }; }();
+ return children(_extends({}, this.props, props, {
+ isLoading: isLoading,
+ onInputChange: this.onInputChange
+ }));
+ }
+ }]);
+ return Async;
+}(external_React_["Component"]);
-var _react = __webpack_require__(1);
+Async.propTypes = propTypes;
+Async.defaultProps = defaultProps;
-var _react2 = _interopRequireDefault(_react);
+var CreatableSelect = function (_React$Component) {
+ inherits(CreatableSelect, _React$Component);
-var _DataTypeLabel = __webpack_require__(9);
+ function CreatableSelect(props, context) {
+ classCallCheck(this, CreatableSelect);
-var _DataTypeLabel2 = _interopRequireDefault(_DataTypeLabel);
+ var _this = possibleConstructorReturn(this, (CreatableSelect.__proto__ || Object.getPrototypeOf(CreatableSelect)).call(this, props, context));
-var _getStyle = __webpack_require__(2);
+ _this.filterOptions = _this.filterOptions.bind(_this);
+ _this.menuRenderer = _this.menuRenderer.bind(_this);
+ _this.onInputKeyDown = _this.onInputKeyDown.bind(_this);
+ _this.onInputChange = _this.onInputChange.bind(_this);
+ _this.onOptionSelect = _this.onOptionSelect.bind(_this);
+ return _this;
+ }
-var _getStyle2 = _interopRequireDefault(_getStyle);
+ createClass(CreatableSelect, [{
+ key: 'createNewOption',
+ value: function createNewOption() {
+ var _props = this.props,
+ isValidNewOption = _props.isValidNewOption,
+ newOptionCreator = _props.newOptionCreator,
+ onNewOptionClick = _props.onNewOptionClick,
+ _props$options = _props.options,
+ options = _props$options === undefined ? [] : _props$options;
-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"); } }
+ if (isValidNewOption({ label: this.inputValue })) {
+ var option = newOptionCreator({ label: this.inputValue, labelKey: this.labelKey, valueKey: this.valueKey });
+ var _isOptionUnique = this.isOptionUnique({ option: option, options: options });
-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; }
+ // Don't add the same option twice.
+ if (_isOptionUnique) {
+ if (onNewOptionClick) {
+ onNewOptionClick(option);
+ } else {
+ options.unshift(option);
-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; }
+ this.select.selectValue(option);
+ }
+ }
+ }
+ }
+ }, {
+ key: 'filterOptions',
+ value: function filterOptions$$1() {
+ var _props2 = this.props,
+ filterOptions$$1 = _props2.filterOptions,
+ isValidNewOption = _props2.isValidNewOption,
+ promptTextCreator = _props2.promptTextCreator,
+ showNewOptionAtTop = _props2.showNewOptionAtTop;
-//theme
+ // TRICKY Check currently selected options as well.
+ // Don't display a create-prompt for a value that's selected.
+ // This covers async edge-cases where a newly-created Option isn't yet in the async-loaded array.
+ var excludeOptions = (arguments.length <= 2 ? undefined : arguments[2]) || [];
-var _class = function (_React$PureComponent) {
- _inherits(_class, _React$PureComponent);
+ var filteredOptions = filterOptions$$1.apply(undefined, arguments) || [];
- function _class() {
- _classCallCheck(this, _class);
+ if (isValidNewOption({ label: this.inputValue })) {
+ var _newOptionCreator = this.props.newOptionCreator;
- return _possibleConstructorReturn(this, (_class.__proto__ || Object.getPrototypeOf(_class)).apply(this, arguments));
- }
- _createClass(_class, [{
- key: 'render',
- value: function render() {
- var type_name = 'float';
- var props = this.props;
+ var option = _newOptionCreator({
+ label: this.inputValue,
+ labelKey: this.labelKey,
+ valueKey: this.valueKey
+ });
- return _react2.default.createElement(
- 'div',
- (0, _getStyle2.default)(props.theme, 'float'),
- _react2.default.createElement(_DataTypeLabel2.default, _extends({ type_name: type_name }, props)),
- this.props.value
- );
- }
- }]);
+ // TRICKY Compare to all options (not just filtered options) in case option has already been selected).
+ // For multi-selects, this would remove it from the filtered list.
+ var _isOptionUnique2 = this.isOptionUnique({
+ option: option,
+ options: excludeOptions.concat(filteredOptions)
+ });
- return _class;
-}(_react2.default.PureComponent);
+ if (_isOptionUnique2) {
+ var prompt = promptTextCreator(this.inputValue);
-exports.default = _class;
+ this._createPlaceholderOption = _newOptionCreator({
+ label: prompt,
+ labelKey: this.labelKey,
+ valueKey: this.valueKey
+ });
-/***/ }),
-/* 172 */
-/***/ (function(module, exports, __webpack_require__) {
+ if (showNewOptionAtTop) {
+ filteredOptions.unshift(this._createPlaceholderOption);
+ } else {
+ filteredOptions.push(this._createPlaceholderOption);
+ }
+ }
+ }
-"use strict";
+ return filteredOptions;
+ }
+ }, {
+ key: 'isOptionUnique',
+ value: function isOptionUnique(_ref) {
+ var option = _ref.option,
+ options = _ref.options;
+ var isOptionUnique = this.props.isOptionUnique;
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
+ options = options || this.props.options;
-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 _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; }; }();
+ return isOptionUnique({
+ labelKey: this.labelKey,
+ option: option,
+ options: options,
+ valueKey: this.valueKey
+ });
+ }
+ }, {
+ key: 'menuRenderer',
+ value: function menuRenderer$$1(params) {
+ var menuRenderer$$1 = this.props.menuRenderer;
-var _react = __webpack_require__(1);
-var _react2 = _interopRequireDefault(_react);
+ return menuRenderer$$1(_extends({}, params, {
+ onSelect: this.onOptionSelect,
+ selectValue: this.onOptionSelect
+ }));
+ }
+ }, {
+ key: 'onInputChange',
+ value: function onInputChange(input) {
+ var onInputChange = this.props.onInputChange;
-var _DataTypeLabel = __webpack_require__(9);
+ // This value may be needed in between Select mounts (when this.select is null)
-var _DataTypeLabel2 = _interopRequireDefault(_DataTypeLabel);
+ this.inputValue = input;
-var _getStyle = __webpack_require__(2);
+ if (onInputChange) {
+ this.inputValue = onInputChange(input);
+ }
-var _getStyle2 = _interopRequireDefault(_getStyle);
+ return this.inputValue;
+ }
+ }, {
+ key: 'onInputKeyDown',
+ value: function onInputKeyDown(event) {
+ var _props3 = this.props,
+ shouldKeyDownEventCreateNewOption = _props3.shouldKeyDownEventCreateNewOption,
+ onInputKeyDown = _props3.onInputKeyDown;
-var _ObjectAttributes = __webpack_require__(16);
+ var focusedOption = this.select.getFocusedOption();
-var _ObjectAttributes2 = _interopRequireDefault(_ObjectAttributes);
+ if (focusedOption && focusedOption === this._createPlaceholderOption && shouldKeyDownEventCreateNewOption(event)) {
+ this.createNewOption();
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+ // Prevent decorated Select from doing anything additional with this keyDown event
+ event.preventDefault();
+ } else if (onInputKeyDown) {
+ onInputKeyDown(event);
+ }
+ }
+ }, {
+ key: 'onOptionSelect',
+ value: function onOptionSelect(option) {
+ if (option === this._createPlaceholderOption) {
+ this.createNewOption();
+ } else {
+ this.select.selectValue(option);
+ }
+ }
+ }, {
+ key: 'focus',
+ value: function focus() {
+ this.select.focus();
+ }
+ }, {
+ key: 'render',
+ value: function render() {
+ var _this2 = this;
-function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
+ var _props4 = this.props,
+ refProp = _props4.ref,
+ restProps = objectWithoutProperties(_props4, ['ref']);
+ var children = this.props.children;
-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; }
+ // We can't use destructuring default values to set the children,
+ // because it won't apply work if `children` is null. A falsy check is
+ // more reliable in real world use-cases.
-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; }
+ if (!children) {
+ children = defaultChildren$2;
+ }
-//theme
+ var props = _extends({}, restProps, {
+ allowCreate: true,
+ filterOptions: this.filterOptions,
+ menuRenderer: this.menuRenderer,
+ onInputChange: this.onInputChange,
+ onInputKeyDown: this.onInputKeyDown,
+ ref: function ref(_ref2) {
+ _this2.select = _ref2;
+ // These values may be needed in between Select mounts (when this.select is null)
+ if (_ref2) {
+ _this2.labelKey = _ref2.props.labelKey;
+ _this2.valueKey = _ref2.props.valueKey;
+ }
+ if (refProp) {
+ refProp(_ref2);
+ }
+ }
+ });
-//attribute store for storing collapsed state
+ return children(props);
+ }
+ }]);
+ return CreatableSelect;
+}(external_React_default.a.Component);
+var defaultChildren$2 = function defaultChildren(props) {
+ return external_React_default.a.createElement(Select$1, props);
+};
-var _class = function (_React$PureComponent) {
- _inherits(_class, _React$PureComponent);
+var isOptionUnique = function isOptionUnique(_ref3) {
+ var option = _ref3.option,
+ options = _ref3.options,
+ labelKey = _ref3.labelKey,
+ valueKey = _ref3.valueKey;
- function _class(props) {
- _classCallCheck(this, _class);
+ if (!options || !options.length) {
+ return true;
+ }
- var _this = _possibleConstructorReturn(this, (_class.__proto__ || Object.getPrototypeOf(_class)).call(this, props));
+ return options.filter(function (existingOption) {
+ return existingOption[labelKey] === option[labelKey] || existingOption[valueKey] === option[valueKey];
+ }).length === 0;
+};
- _initialiseProps.call(_this);
+var isValidNewOption = function isValidNewOption(_ref4) {
+ var label = _ref4.label;
+ return !!label;
+};
- _this.state = {
- collapsed: _ObjectAttributes2.default.get(props.rjvId, props.namespace, 'collapsed', true)
- };
- return _this;
- }
+var newOptionCreator = function newOptionCreator(_ref5) {
+ var label = _ref5.label,
+ labelKey = _ref5.labelKey,
+ valueKey = _ref5.valueKey;
- _createClass(_class, [{
- key: 'render',
- value: function render() {
- var type_name = 'function';
- var props = this.props;
- var collapsed = this.state.collapsed;
+ var option = {};
+ option[valueKey] = label;
+ option[labelKey] = label;
+ option.className = 'Select-create-option-placeholder';
+ return option;
+};
- return _react2.default.createElement(
- 'div',
- (0, _getStyle2.default)(props.theme, 'function'),
- _react2.default.createElement(_DataTypeLabel2.default, _extends({ type_name: type_name }, props)),
- _react2.default.createElement(
- 'span',
- _extends({}, (0, _getStyle2.default)(props.theme, 'function-value'), {
- className: 'rjv-function-container',
- onClick: this.toggleCollapsed
- }),
- this.getFunctionDisplay(collapsed)
- )
- );
- }
- }]);
+var promptTextCreator = function promptTextCreator(label) {
+ return 'Create option "' + label + '"';
+};
- return _class;
-}(_react2.default.PureComponent);
+var shouldKeyDownEventCreateNewOption = function shouldKeyDownEventCreateNewOption(_ref6) {
+ var keyCode = _ref6.keyCode;
-var _initialiseProps = function _initialiseProps() {
- var _this2 = this;
+ switch (keyCode) {
+ case 9: // TAB
+ case 13: // ENTER
+ case 188:
+ // COMMA
+ return true;
+ default:
+ return false;
+ }
+};
- this.toggleCollapsed = function () {
- _this2.setState({
- collapsed: !_this2.state.collapsed
- }, function () {
- // will be called after setState takes effect.
- _ObjectAttributes2.default.set(_this2.props.rjvId, _this2.props.namespace, 'collapsed', _this2.state.collapsed);
- });
- };
+// Default prop methods
+CreatableSelect.isOptionUnique = isOptionUnique;
+CreatableSelect.isValidNewOption = isValidNewOption;
+CreatableSelect.newOptionCreator = newOptionCreator;
+CreatableSelect.promptTextCreator = promptTextCreator;
+CreatableSelect.shouldKeyDownEventCreateNewOption = shouldKeyDownEventCreateNewOption;
- this.getFunctionDisplay = function (collapsed) {
- var props = _this2.props;
-
- if (collapsed) {
- return _react2.default.createElement(
- 'span',
- null,
- _this2.props.value.toString().slice(9, -1).replace(/\{[\s\S]+/, ''),
- _react2.default.createElement(
- 'span',
- {
- className: 'function-collapsed',
- style: { fontWeight: 'bold' }
- },
- _react2.default.createElement(
- 'span',
- null,
- '{'
- ),
- _react2.default.createElement(
- 'span',
- (0, _getStyle2.default)(props.theme, 'ellipsis'),
- '...'
- ),
- _react2.default.createElement(
- 'span',
- null,
- '}'
- )
- )
- );
- } else {
- return _this2.props.value.toString().slice(9, -1);
- }
- };
+CreatableSelect.defaultProps = {
+ filterOptions: filterOptions,
+ isOptionUnique: isOptionUnique,
+ isValidNewOption: isValidNewOption,
+ menuRenderer: react_select_es_menuRenderer,
+ newOptionCreator: newOptionCreator,
+ promptTextCreator: promptTextCreator,
+ shouldKeyDownEventCreateNewOption: shouldKeyDownEventCreateNewOption,
+ showNewOptionAtTop: true
};
-exports.default = _class;
+CreatableSelect.propTypes = {
+ // Child function responsible for creating the inner Select component
+ // This component can be used to compose HOCs (eg Creatable and Async)
+ // (props: Object): PropTypes.element
+ children: prop_types_default.a.func,
-/***/ }),
-/* 173 */
-/***/ (function(module, exports, __webpack_require__) {
+ // See Select.propTypes.filterOptions
+ filterOptions: prop_types_default.a.any,
-"use strict";
-// Copyright Joyent, Inc. and other Node contributors.
-//
-// Permission is hereby granted, free of charge, to any person obtaining a
-// copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to permit
-// persons to whom the Software is furnished to do so, subject to the
-// following conditions:
-//
-// The above copyright notice and this permission notice shall be included
-// in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
-// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
-// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
-// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
-// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
-// USE OR OTHER DEALINGS IN THE SOFTWARE.
+ // Searches for any matching option within the set of options.
+ // This function prevents duplicate options from being created.
+ // ({ option: Object, options: Array, labelKey: string, valueKey: string }): boolean
+ isOptionUnique: prop_types_default.a.func,
+ // Determines if the current input text represents a valid option.
+ // ({ label: string }): boolean
+ isValidNewOption: prop_types_default.a.func,
+ // See Select.propTypes.menuRenderer
+ menuRenderer: prop_types_default.a.any,
-var R = typeof Reflect === 'object' ? Reflect : null
-var ReflectApply = R && typeof R.apply === 'function'
- ? R.apply
- : function ReflectApply(target, receiver, args) {
- return Function.prototype.apply.call(target, receiver, args);
- }
+ // Factory to create new option.
+ // ({ label: string, labelKey: string, valueKey: string }): Object
+ newOptionCreator: prop_types_default.a.func,
-var ReflectOwnKeys
-if (R && typeof R.ownKeys === 'function') {
- ReflectOwnKeys = R.ownKeys
-} else if (Object.getOwnPropertySymbols) {
- ReflectOwnKeys = function ReflectOwnKeys(target) {
- return Object.getOwnPropertyNames(target)
- .concat(Object.getOwnPropertySymbols(target));
- };
-} else {
- ReflectOwnKeys = function ReflectOwnKeys(target) {
- return Object.getOwnPropertyNames(target);
- };
-}
+ // input change handler: function (inputValue) {}
+ onInputChange: prop_types_default.a.func,
-function ProcessEmitWarning(warning) {
- if (console && console.warn) console.warn(warning);
-}
+ // input keyDown handler: function (event) {}
+ onInputKeyDown: prop_types_default.a.func,
-var NumberIsNaN = Number.isNaN || function NumberIsNaN(value) {
- return value !== value;
-}
+ // new option click handler: function (option) {}
+ onNewOptionClick: prop_types_default.a.func,
-function EventEmitter() {
- EventEmitter.init.call(this);
-}
-module.exports = EventEmitter;
-module.exports.once = once;
+ // See Select.propTypes.options
+ options: prop_types_default.a.array,
-// Backwards-compat with node 0.10.x
-EventEmitter.EventEmitter = EventEmitter;
+ // Creates prompt/placeholder option text.
+ // (filterText: string): string
+ promptTextCreator: prop_types_default.a.func,
-EventEmitter.prototype._events = undefined;
-EventEmitter.prototype._eventsCount = 0;
-EventEmitter.prototype._maxListeners = undefined;
+ ref: prop_types_default.a.func,
-// By default EventEmitters will print a warning if more than 10 listeners are
-// added to it. This is a useful default which helps finding memory leaks.
-var defaultMaxListeners = 10;
+ // Decides if a keyDown event (eg its `keyCode`) should result in the creation of a new option.
+ shouldKeyDownEventCreateNewOption: prop_types_default.a.func,
-function checkListener(listener) {
- if (typeof listener !== 'function') {
- throw new TypeError('The "listener" argument must be of type Function. Received type ' + typeof listener);
- }
-}
+ // Where to show prompt/placeholder option text.
+ // true: new option prompt at top of list (default)
+ // false: new option prompt at bottom of list
+ showNewOptionAtTop: prop_types_default.a.bool
+};
-Object.defineProperty(EventEmitter, 'defaultMaxListeners', {
- enumerable: true,
- get: function() {
- return defaultMaxListeners;
- },
- set: function(arg) {
- if (typeof arg !== 'number' || arg < 0 || NumberIsNaN(arg)) {
- throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received ' + arg + '.');
- }
- defaultMaxListeners = arg;
- }
-});
+var react_select_es_AsyncCreatableSelect = function (_React$Component) {
+ inherits(AsyncCreatableSelect, _React$Component);
-EventEmitter.init = function() {
+ function AsyncCreatableSelect() {
+ classCallCheck(this, AsyncCreatableSelect);
+ return possibleConstructorReturn(this, (AsyncCreatableSelect.__proto__ || Object.getPrototypeOf(AsyncCreatableSelect)).apply(this, arguments));
+ }
- if (this._events === undefined ||
- this._events === Object.getPrototypeOf(this)._events) {
- this._events = Object.create(null);
- this._eventsCount = 0;
- }
+ createClass(AsyncCreatableSelect, [{
+ key: 'focus',
+ value: function focus() {
+ this.select.focus();
+ }
+ }, {
+ key: 'render',
+ value: function render() {
+ var _this2 = this;
- this._maxListeners = this._maxListeners || undefined;
-};
+ return external_React_default.a.createElement(
+ Async,
+ this.props,
+ function (_ref) {
+ var ref = _ref.ref,
+ asyncProps = objectWithoutProperties(_ref, ['ref']);
-// Obviously not all Emitters should be limited to 10. This function allows
-// that to be increased. Set to zero for unlimited.
-EventEmitter.prototype.setMaxListeners = function setMaxListeners(n) {
- if (typeof n !== 'number' || n < 0 || NumberIsNaN(n)) {
- throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received ' + n + '.');
- }
- this._maxListeners = n;
- return this;
-};
+ var asyncRef = ref;
+ return external_React_default.a.createElement(
+ CreatableSelect,
+ asyncProps,
+ function (_ref2) {
+ var ref = _ref2.ref,
+ creatableProps = objectWithoutProperties(_ref2, ['ref']);
-function _getMaxListeners(that) {
- if (that._maxListeners === undefined)
- return EventEmitter.defaultMaxListeners;
- return that._maxListeners;
-}
+ var creatableRef = ref;
+ return _this2.props.children(_extends({}, creatableProps, {
+ ref: function ref(select) {
+ creatableRef(select);
+ asyncRef(select);
+ _this2.select = select;
+ }
+ }));
+ }
+ );
+ }
+ );
+ }
+ }]);
+ return AsyncCreatableSelect;
+}(external_React_default.a.Component);
-EventEmitter.prototype.getMaxListeners = function getMaxListeners() {
- return _getMaxListeners(this);
+var defaultChildren$1 = function defaultChildren(props) {
+ return external_React_default.a.createElement(Select$1, props);
};
-EventEmitter.prototype.emit = function emit(type) {
- var args = [];
- for (var i = 1; i < arguments.length; i++) args.push(arguments[i]);
- var doError = (type === 'error');
+react_select_es_AsyncCreatableSelect.propTypes = {
+ children: prop_types_default.a.func.isRequired // Child function responsible for creating the inner Select component; (props: Object): PropTypes.element
+};
- var events = this._events;
- if (events !== undefined)
- doError = (doError && events.error === undefined);
- else if (!doError)
- return false;
+react_select_es_AsyncCreatableSelect.defaultProps = {
+ children: defaultChildren$1
+};
- // If there is no 'error' event listener then throw.
- if (doError) {
- var er;
- if (args.length > 0)
- er = args[0];
- if (er instanceof Error) {
- // Note: The comments on the `throw` lines are intentional, they show
- // up in Node's output if this results in an unhandled exception.
- throw er; // Unhandled 'error' event
- }
- // At least give some kind of context to the user
- var err = new Error('Unhandled error.' + (er ? ' (' + er.message + ')' : ''));
- err.context = er;
- throw err; // Unhandled 'error' event
- }
+Select$1.Async = Async;
+Select$1.AsyncCreatable = react_select_es_AsyncCreatableSelect;
+Select$1.Creatable = CreatableSelect;
+Select$1.Value = react_select_es_Value;
+Select$1.Option = react_select_es_Option;
- var handler = events[type];
- if (handler === undefined)
- return false;
+/* harmony default export */ var react_select_es = (Select$1);
- if (typeof handler === 'function') {
- ReflectApply(handler, this, args);
+// CONCATENATED MODULE: ./node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/defineProperty.js
+function _defineProperty(obj, key, value) {
+ if (key in obj) {
+ Object.defineProperty(obj, key, {
+ value: value,
+ enumerable: true,
+ configurable: true,
+ writable: true
+ });
} else {
- var len = handler.length;
- var listeners = arrayClone(handler, len);
- for (var i = 0; i < len; ++i)
- ReflectApply(listeners[i], this, args);
+ obj[key] = value;
}
- return true;
-};
-
-function _addListener(target, type, listener, prepend) {
- var m;
- var events;
- var existing;
+ return obj;
+}
+// CONCATENATED MODULE: ./node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/objectSpread2.js
- checkListener(listener);
- events = target._events;
- if (events === undefined) {
- events = target._events = Object.create(null);
- target._eventsCount = 0;
- } else {
- // To avoid recursion in the case that type === "newListener"! Before
- // adding it to the listeners, first emit "newListener".
- if (events.newListener !== undefined) {
- target.emit('newListener', type,
- listener.listener ? listener.listener : listener);
+function ownKeys(object, enumerableOnly) {
+ var keys = Object.keys(object);
- // Re-assign `events` because a newListener handler could have caused the
- // this._events to be assigned to a new object
- events = target._events;
- }
- existing = events[type];
+ if (Object.getOwnPropertySymbols) {
+ var symbols = Object.getOwnPropertySymbols(object);
+ if (enumerableOnly) symbols = symbols.filter(function (sym) {
+ return Object.getOwnPropertyDescriptor(object, sym).enumerable;
+ });
+ keys.push.apply(keys, symbols);
}
- if (existing === undefined) {
- // Optimize the case of one listener. Don't need the extra array object.
- existing = events[type] = listener;
- ++target._eventsCount;
- } else {
- if (typeof existing === 'function') {
- // Adding the second element, need to change to array.
- existing = events[type] =
- prepend ? [listener, existing] : [existing, listener];
- // If we've already got an array, just append.
- } else if (prepend) {
- existing.unshift(listener);
- } else {
- existing.push(listener);
- }
+ return keys;
+}
- // Check for listener leak
- m = _getMaxListeners(target);
- if (m > 0 && existing.length > m && !existing.warned) {
- existing.warned = true;
- // No error code for this since it is a Warning
- // eslint-disable-next-line no-restricted-syntax
- var w = new Error('Possible EventEmitter memory leak detected. ' +
- existing.length + ' ' + String(type) + ' listeners ' +
- 'added. Use emitter.setMaxListeners() to ' +
- 'increase limit');
- w.name = 'MaxListenersExceededWarning';
- w.emitter = target;
- w.type = type;
- w.count = existing.length;
- ProcessEmitWarning(w);
+function _objectSpread2(target) {
+ for (var i = 1; i < arguments.length; i++) {
+ var source = arguments[i] != null ? arguments[i] : {};
+
+ if (i % 2) {
+ ownKeys(Object(source), true).forEach(function (key) {
+ _defineProperty(target, key, source[key]);
+ });
+ } else if (Object.getOwnPropertyDescriptors) {
+ Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
+ } else {
+ ownKeys(Object(source)).forEach(function (key) {
+ Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
+ });
}
}
return target;
}
+// CONCATENATED MODULE: ./node_modules/react-lifecycles-compat/react-lifecycles-compat.es.js
+/**
+ * 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.
+ */
-EventEmitter.prototype.addListener = function addListener(type, listener) {
- return _addListener(this, type, listener, false);
-};
-
-EventEmitter.prototype.on = EventEmitter.prototype.addListener;
-
-EventEmitter.prototype.prependListener =
- function prependListener(type, listener) {
- return _addListener(this, type, listener, true);
- };
+function componentWillMount() {
+ // Call this.constructor.gDSFP to support sub-classes.
+ var state = this.constructor.getDerivedStateFromProps(this.props, this.state);
+ if (state !== null && state !== undefined) {
+ this.setState(state);
+ }
+}
-function onceWrapper() {
- if (!this.fired) {
- this.target.removeListener(this.type, this.wrapFn);
- this.fired = true;
- if (arguments.length === 0)
- return this.listener.call(this.target);
- return this.listener.apply(this.target, arguments);
+function componentWillReceiveProps(nextProps) {
+ // Call this.constructor.gDSFP to support sub-classes.
+ // Use the setState() updater to ensure state isn't stale in certain edge cases.
+ function updater(prevState) {
+ var state = this.constructor.getDerivedStateFromProps(nextProps, prevState);
+ return state !== null && state !== undefined ? state : null;
}
+ // Binding "this" is important for shallow renderer support.
+ this.setState(updater.bind(this));
}
-function _onceWrap(target, type, listener) {
- var state = { fired: false, wrapFn: undefined, target: target, type: type, listener: listener };
- var wrapped = onceWrapper.bind(state);
- wrapped.listener = listener;
- state.wrapFn = wrapped;
- return wrapped;
+function componentWillUpdate(nextProps, nextState) {
+ try {
+ var prevProps = this.props;
+ var prevState = this.state;
+ this.props = nextProps;
+ this.state = nextState;
+ this.__reactInternalSnapshotFlag = true;
+ this.__reactInternalSnapshot = this.getSnapshotBeforeUpdate(
+ prevProps,
+ prevState
+ );
+ } finally {
+ this.props = prevProps;
+ this.state = prevState;
+ }
}
-EventEmitter.prototype.once = function once(type, listener) {
- checkListener(listener);
- this.on(type, _onceWrap(this, type, listener));
- return this;
-};
+// React may warn about cWM/cWRP/cWU methods being deprecated.
+// Add a flag to suppress these warnings for this special case.
+componentWillMount.__suppressDeprecationWarning = true;
+componentWillReceiveProps.__suppressDeprecationWarning = true;
+componentWillUpdate.__suppressDeprecationWarning = true;
-EventEmitter.prototype.prependOnceListener =
- function prependOnceListener(type, listener) {
- checkListener(listener);
- this.prependListener(type, _onceWrap(this, type, listener));
- return this;
- };
-
-// Emits a 'removeListener' event if and only if the listener was removed.
-EventEmitter.prototype.removeListener =
- function removeListener(type, listener) {
- var list, events, position, i, originalListener;
+function polyfill(Component) {
+ var prototype = Component.prototype;
- checkListener(listener);
+ if (!prototype || !prototype.isReactComponent) {
+ throw new Error('Can only polyfill class components');
+ }
- events = this._events;
- if (events === undefined)
- return this;
+ if (
+ typeof Component.getDerivedStateFromProps !== 'function' &&
+ typeof prototype.getSnapshotBeforeUpdate !== 'function'
+ ) {
+ return Component;
+ }
- list = events[type];
- if (list === undefined)
- return this;
+ // If new component APIs are defined, "unsafe" lifecycles won't be called.
+ // Error if any of these lifecycles are present,
+ // Because they would work differently between older and newer (16.3+) versions of React.
+ var foundWillMountName = null;
+ var foundWillReceivePropsName = null;
+ var foundWillUpdateName = null;
+ if (typeof prototype.componentWillMount === 'function') {
+ foundWillMountName = 'componentWillMount';
+ } else if (typeof prototype.UNSAFE_componentWillMount === 'function') {
+ foundWillMountName = 'UNSAFE_componentWillMount';
+ }
+ if (typeof prototype.componentWillReceiveProps === 'function') {
+ foundWillReceivePropsName = 'componentWillReceiveProps';
+ } else if (typeof prototype.UNSAFE_componentWillReceiveProps === 'function') {
+ foundWillReceivePropsName = 'UNSAFE_componentWillReceiveProps';
+ }
+ if (typeof prototype.componentWillUpdate === 'function') {
+ foundWillUpdateName = 'componentWillUpdate';
+ } else if (typeof prototype.UNSAFE_componentWillUpdate === 'function') {
+ foundWillUpdateName = 'UNSAFE_componentWillUpdate';
+ }
+ if (
+ foundWillMountName !== null ||
+ foundWillReceivePropsName !== null ||
+ foundWillUpdateName !== null
+ ) {
+ var componentName = Component.displayName || Component.name;
+ var newApiName =
+ typeof Component.getDerivedStateFromProps === 'function'
+ ? 'getDerivedStateFromProps()'
+ : 'getSnapshotBeforeUpdate()';
- if (list === listener || list.listener === listener) {
- if (--this._eventsCount === 0)
- this._events = Object.create(null);
- else {
- delete events[type];
- if (events.removeListener)
- this.emit('removeListener', type, list.listener || listener);
- }
- } else if (typeof list !== 'function') {
- position = -1;
+ throw Error(
+ 'Unsafe legacy lifecycles will not be called for components using new component APIs.\n\n' +
+ componentName +
+ ' uses ' +
+ newApiName +
+ ' but also contains the following legacy lifecycles:' +
+ (foundWillMountName !== null ? '\n ' + foundWillMountName : '') +
+ (foundWillReceivePropsName !== null
+ ? '\n ' + foundWillReceivePropsName
+ : '') +
+ (foundWillUpdateName !== null ? '\n ' + foundWillUpdateName : '') +
+ '\n\nThe above lifecycles should be removed. Learn more about this warning here:\n' +
+ 'https://fb.me/react-async-component-lifecycle-hooks'
+ );
+ }
- for (i = list.length - 1; i >= 0; i--) {
- if (list[i] === listener || list[i].listener === listener) {
- originalListener = list[i].listener;
- position = i;
- break;
- }
- }
+ // React <= 16.2 does not support static getDerivedStateFromProps.
+ // As a workaround, use cWM and cWRP to invoke the new static lifecycle.
+ // Newer versions of React will ignore these lifecycles if gDSFP exists.
+ if (typeof Component.getDerivedStateFromProps === 'function') {
+ prototype.componentWillMount = componentWillMount;
+ prototype.componentWillReceiveProps = componentWillReceiveProps;
+ }
- if (position < 0)
- return this;
+ // React <= 16.2 does not support getSnapshotBeforeUpdate.
+ // As a workaround, use cWU to invoke the new lifecycle.
+ // Newer versions of React will ignore that lifecycle if gSBU exists.
+ if (typeof prototype.getSnapshotBeforeUpdate === 'function') {
+ if (typeof prototype.componentDidUpdate !== 'function') {
+ throw new Error(
+ 'Cannot polyfill getSnapshotBeforeUpdate() for components that do not define componentDidUpdate() on the prototype'
+ );
+ }
- if (position === 0)
- list.shift();
- else {
- spliceOne(list, position);
- }
+ prototype.componentWillUpdate = componentWillUpdate;
- if (list.length === 1)
- events[type] = list[0];
+ var componentDidUpdate = prototype.componentDidUpdate;
- if (events.removeListener !== undefined)
- this.emit('removeListener', type, originalListener || listener);
- }
+ prototype.componentDidUpdate = function componentDidUpdatePolyfill(
+ prevProps,
+ prevState,
+ maybeSnapshot
+ ) {
+ // 16.3+ will not execute our will-update method;
+ // It will pass a snapshot value to did-update though.
+ // Older versions will require our polyfilled will-update value.
+ // We need to handle both cases, but can't just check for the presence of "maybeSnapshot",
+ // Because for <= 15.x versions this might be a "prevContext" object.
+ // We also can't just check "__reactInternalSnapshot",
+ // Because get-snapshot might return a falsy value.
+ // So check for the explicit __reactInternalSnapshotFlag flag to determine behavior.
+ var snapshot = this.__reactInternalSnapshotFlag
+ ? this.__reactInternalSnapshot
+ : maybeSnapshot;
- return this;
+ componentDidUpdate.call(this, prevProps, prevState, snapshot);
};
+ }
-EventEmitter.prototype.off = EventEmitter.prototype.removeListener;
-
-EventEmitter.prototype.removeAllListeners =
- function removeAllListeners(type) {
- var listeners, events, i;
-
- events = this._events;
- if (events === undefined)
- return this;
-
- // not listening for removeListener, no need to emit
- if (events.removeListener === undefined) {
- if (arguments.length === 0) {
- this._events = Object.create(null);
- this._eventsCount = 0;
- } else if (events[type] !== undefined) {
- if (--this._eventsCount === 0)
- this._events = Object.create(null);
- else
- delete events[type];
- }
- return this;
- }
-
- // emit removeListener for all listeners on all events
- if (arguments.length === 0) {
- var keys = Object.keys(events);
- var key;
- for (i = 0; i < keys.length; ++i) {
- key = keys[i];
- if (key === 'removeListener') continue;
- this.removeAllListeners(key);
- }
- this.removeAllListeners('removeListener');
- this._events = Object.create(null);
- this._eventsCount = 0;
- return this;
- }
-
- listeners = events[type];
-
- if (typeof listeners === 'function') {
- this.removeListener(type, listeners);
- } else if (listeners !== undefined) {
- // LIFO order
- for (i = listeners.length - 1; i >= 0; i--) {
- this.removeListener(type, listeners[i]);
- }
- }
-
- return this;
- };
+ return Component;
+}
-function _listeners(target, type, unwrap) {
- var events = target._events;
- if (events === undefined)
- return [];
- var evlistener = events[type];
- if (evlistener === undefined)
- return [];
+// CONCATENATED MODULE: ./node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js
+function _objectWithoutPropertiesLoose(source, excluded) {
+ if (source == null) return {};
+ var target = {};
+ var sourceKeys = Object.keys(source);
+ var key, i;
- if (typeof evlistener === 'function')
- return unwrap ? [evlistener.listener || evlistener] : [evlistener];
+ for (i = 0; i < sourceKeys.length; i++) {
+ key = sourceKeys[i];
+ if (excluded.indexOf(key) >= 0) continue;
+ target[key] = source[key];
+ }
- return unwrap ?
- unwrapListeners(evlistener) : arrayClone(evlistener, evlistener.length);
+ return target;
}
+// CONCATENATED MODULE: ./node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js
-EventEmitter.prototype.listeners = function listeners(type) {
- return _listeners(this, type, true);
-};
-
-EventEmitter.prototype.rawListeners = function rawListeners(type) {
- return _listeners(this, type, false);
-};
-
-EventEmitter.listenerCount = function(emitter, type) {
- if (typeof emitter.listenerCount === 'function') {
- return emitter.listenerCount(type);
- } else {
- return listenerCount.call(emitter, type);
- }
-};
-
-EventEmitter.prototype.listenerCount = listenerCount;
-function listenerCount(type) {
- var events = this._events;
+function _objectWithoutProperties(source, excluded) {
+ if (source == null) return {};
+ var target = _objectWithoutPropertiesLoose(source, excluded);
+ var key, i;
- if (events !== undefined) {
- var evlistener = events[type];
+ if (Object.getOwnPropertySymbols) {
+ var sourceSymbolKeys = Object.getOwnPropertySymbols(source);
- if (typeof evlistener === 'function') {
- return 1;
- } else if (evlistener !== undefined) {
- return evlistener.length;
+ 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 0;
-}
-
-EventEmitter.prototype.eventNames = function eventNames() {
- return this._eventsCount > 0 ? ReflectOwnKeys(this._events) : [];
-};
-
-function arrayClone(arr, n) {
- var copy = new Array(n);
- for (var i = 0; i < n; ++i)
- copy[i] = arr[i];
- return copy;
+ return target;
}
+// CONCATENATED MODULE: ./src/js/helpers/util.js
+function cov_2gh831emd0() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/helpers/util.js";
+ var hash = "c4b962909e958ef8ce7865ced24f00c2adc5acfe";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/helpers/util.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 3,
+ column: 15
+ },
+ end: {
+ line: 3,
+ column: 27
+ }
+ },
+ "1": {
+ start: {
+ line: 5,
+ column: 4
+ },
+ end: {
+ line: 14,
+ column: 5
+ }
+ },
+ "2": {
+ start: {
+ line: 6,
+ column: 8
+ },
+ end: {
+ line: 13,
+ column: 9
+ }
+ },
+ "3": {
+ start: {
+ line: 7,
+ column: 12
+ },
+ end: {
+ line: 7,
+ column: 25
+ }
+ },
+ "4": {
+ start: {
+ line: 8,
+ column: 15
+ },
+ end: {
+ line: 13,
+ column: 9
+ }
+ },
+ "5": {
+ start: {
+ line: 10,
+ column: 12
+ },
+ end: {
+ line: 10,
+ column: 27
+ }
+ },
+ "6": {
+ start: {
+ line: 12,
+ column: 12
+ },
+ end: {
+ line: 12,
+ column: 29
+ }
+ },
+ "7": {
+ start: {
+ line: 15,
+ column: 4
+ },
+ end: {
+ line: 15,
+ column: 16
+ }
+ },
+ "8": {
+ start: {
+ line: 20,
+ column: 4
+ },
+ end: {
+ line: 23,
+ column: 23
+ }
+ },
+ "9": {
+ start: {
+ line: 28,
+ column: 23
+ },
+ end: {
+ line: 45,
+ column: 5
+ }
+ },
+ "10": {
+ start: {
+ line: 46,
+ column: 4
+ },
+ end: {
+ line: 53,
+ column: 5
+ }
+ },
+ "11": {
+ start: {
+ line: 47,
+ column: 8
+ },
+ end: {
+ line: 51,
+ column: 9
+ }
+ },
+ "12": {
+ start: {
+ line: 47,
+ column: 21
+ },
+ end: {
+ line: 47,
+ column: 22
+ }
+ },
+ "13": {
+ start: {
+ line: 48,
+ column: 12
+ },
+ end: {
+ line: 50,
+ column: 13
+ }
+ },
+ "14": {
+ start: {
+ line: 49,
+ column: 16
+ },
+ end: {
+ line: 49,
+ column: 29
+ }
+ },
+ "15": {
+ start: {
+ line: 52,
+ column: 8
+ },
+ end: {
+ line: 52,
+ column: 20
+ }
+ },
+ "16": {
+ start: {
+ line: 54,
+ column: 4
+ },
+ end: {
+ line: 54,
+ column: 17
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "toType",
+ decl: {
+ start: {
+ line: 2,
+ column: 16
+ },
+ end: {
+ line: 2,
+ column: 22
+ }
+ },
+ loc: {
+ start: {
+ line: 2,
+ column: 28
+ },
+ end: {
+ line: 16,
+ column: 1
+ }
+ },
+ line: 2
+ },
+ "1": {
+ name: "getType",
+ decl: {
+ start: {
+ line: 19,
+ column: 9
+ },
+ end: {
+ line: 19,
+ column: 16
+ }
+ },
+ loc: {
+ start: {
+ line: 19,
+ column: 22
+ },
+ end: {
+ line: 24,
+ column: 1
+ }
+ },
+ line: 19
+ },
+ "2": {
+ name: "isTheme",
+ decl: {
+ start: {
+ line: 27,
+ column: 16
+ },
+ end: {
+ line: 27,
+ column: 23
+ }
+ },
+ loc: {
+ start: {
+ line: 27,
+ column: 31
+ },
+ end: {
+ line: 55,
+ column: 1
+ }
+ },
+ line: 27
+ }
+ },
+ branchMap: {
+ "0": {
+ loc: {
+ start: {
+ line: 5,
+ column: 4
+ },
+ end: {
+ line: 14,
+ column: 5
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 5,
+ column: 4
+ },
+ end: {
+ line: 14,
+ column: 5
+ }
+ }, {
+ start: {
+ line: 5,
+ column: 4
+ },
+ end: {
+ line: 14,
+ column: 5
+ }
+ }],
+ line: 5
+ },
+ "1": {
+ loc: {
+ start: {
+ line: 6,
+ column: 8
+ },
+ end: {
+ line: 13,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 6,
+ column: 8
+ },
+ end: {
+ line: 13,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 6,
+ column: 8
+ },
+ end: {
+ line: 13,
+ column: 9
+ }
+ }],
+ line: 6
+ },
+ "2": {
+ loc: {
+ start: {
+ line: 8,
+ column: 15
+ },
+ end: {
+ line: 13,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 8,
+ column: 15
+ },
+ end: {
+ line: 13,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 8,
+ column: 15
+ },
+ end: {
+ line: 13,
+ column: 9
+ }
+ }],
+ line: 8
+ },
+ "3": {
+ loc: {
+ start: {
+ line: 46,
+ column: 4
+ },
+ end: {
+ line: 53,
+ column: 5
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 46,
+ column: 4
+ },
+ end: {
+ line: 53,
+ column: 5
+ }
+ }, {
+ start: {
+ line: 46,
+ column: 4
+ },
+ end: {
+ line: 53,
+ column: 5
+ }
+ }],
+ line: 46
+ },
+ "4": {
+ loc: {
+ start: {
+ line: 48,
+ column: 12
+ },
+ end: {
+ line: 50,
+ column: 13
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 48,
+ column: 12
+ },
+ end: {
+ line: 50,
+ column: 13
+ }
+ }, {
+ start: {
+ line: 48,
+ column: 12
+ },
+ end: {
+ line: 50,
+ column: 13
+ }
+ }],
+ line: 48
+ }
+ },
+ s: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0,
+ "7": 0,
+ "8": 0,
+ "9": 0,
+ "10": 0,
+ "11": 0,
+ "12": 0,
+ "13": 0,
+ "14": 0,
+ "15": 0,
+ "16": 0
+ },
+ f: {
+ "0": 0,
+ "1": 0,
+ "2": 0
+ },
+ b: {
+ "0": [0, 0],
+ "1": [0, 0],
+ "2": [0, 0],
+ "3": [0, 0],
+ "4": [0, 0]
+ },
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "c4b962909e958ef8ce7865ced24f00c2adc5acfe"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
-function spliceOne(list, index) {
- for (; index + 1 < list.length; index++)
- list[index] = list[index + 1];
- list.pop();
-}
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
-function unwrapListeners(arr) {
- var ret = new Array(arr.length);
- for (var i = 0; i < ret.length; ++i) {
- ret[i] = arr[i].listener || arr[i];
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_2gh831emd0 = function () {
+ return actualCoverage;
+ };
}
- return ret;
+ return actualCoverage;
}
-function once(emitter, name) {
- return new Promise(function (resolve, reject) {
- function eventListener() {
- if (errorListener !== undefined) {
- emitter.removeListener('error', errorListener);
- }
- resolve([].slice.call(arguments));
- };
- var errorListener;
+cov_2gh831emd0();
+//returns a string "type" of input object
+function toType(obj) {
+ cov_2gh831emd0().f[0]++;
+ var type = (cov_2gh831emd0().s[0]++, getType(obj)); // some extra disambiguation for numbers
- // Adding an error listener is not optional because
- // if an error is thrown on an event emitter we cannot
- // guarantee that the actual event we are waiting will
- // be fired. The result could be a silent way to create
- // memory or file descriptor leaks, which is something
- // we should avoid.
- if (name !== 'error') {
- errorListener = function errorListener(err) {
- emitter.removeListener(name, eventListener);
- reject(err);
- };
+ cov_2gh831emd0().s[1]++;
- emitter.once('error', errorListener);
+ if (type === 'number') {
+ cov_2gh831emd0().b[0][0]++;
+ cov_2gh831emd0().s[2]++;
+
+ if (isNaN(obj)) {
+ cov_2gh831emd0().b[1][0]++;
+ cov_2gh831emd0().s[3]++;
+ type = 'nan';
+ } else {
+ cov_2gh831emd0().b[1][1]++;
+ cov_2gh831emd0().s[4]++;
+
+ if ((obj | 0) != obj) {
+ cov_2gh831emd0().b[2][0]++;
+ cov_2gh831emd0().s[5]++;
+ //bitwise OR produces integers
+ type = 'float';
+ } else {
+ cov_2gh831emd0().b[2][1]++;
+ cov_2gh831emd0().s[6]++;
+ type = 'integer';
+ }
}
+ } else {
+ cov_2gh831emd0().b[0][1]++;
+ }
- emitter.once(name, eventListener);
- });
-}
+ cov_2gh831emd0().s[7]++;
+ return type;
+} //source: http://stackoverflow.com/questions/7390426/better-way-to-get-type-of-a-javascript-variable/7390612#7390612
+function getType(obj) {
+ cov_2gh831emd0().f[1]++;
+ cov_2gh831emd0().s[8]++;
+ return {}.toString.call(obj).match(/\s([a-zA-Z]+)/)[1].toLowerCase();
+} //validation for base-16 themes
-/***/ }),
-/* 174 */
-/***/ (function(module, exports, __webpack_require__) {
-/**
- * Copyright (c) 2014-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 isTheme(theme) {
+ cov_2gh831emd0().f[2]++;
+ var theme_keys = (cov_2gh831emd0().s[9]++, ['base00', 'base01', 'base02', 'base03', 'base04', 'base05', 'base06', 'base07', 'base08', 'base09', 'base0A', 'base0B', 'base0C', 'base0D', 'base0E', 'base0F']);
+ cov_2gh831emd0().s[10]++;
-module.exports.Dispatcher = __webpack_require__(175);
+ if (toType(theme) === 'object') {
+ cov_2gh831emd0().b[3][0]++;
+ cov_2gh831emd0().s[11]++;
+ for (var i = (cov_2gh831emd0().s[12]++, 0); i < theme_keys.length; i++) {
+ cov_2gh831emd0().s[13]++;
-/***/ }),
-/* 175 */
-/***/ (function(module, exports, __webpack_require__) {
+ if (!(theme_keys[i] in theme)) {
+ cov_2gh831emd0().b[4][0]++;
+ cov_2gh831emd0().s[14]++;
+ return false;
+ } else {
+ cov_2gh831emd0().b[4][1]++;
+ }
+ }
-"use strict";
-/**
- * Copyright (c) 2014-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.
- *
- * @providesModule Dispatcher
- *
- * @preventMunge
- */
+ cov_2gh831emd0().s[15]++;
+ return true;
+ } else {
+ cov_2gh831emd0().b[3][1]++;
+ }
+ cov_2gh831emd0().s[16]++;
+ return false;
+}
+// CONCATENATED MODULE: ./src/js/themes/base16/rjv-themes.js
+function cov_19m5wnj7fy() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/themes/base16/rjv-themes.js";
+ var hash = "e7b9c616f454810bdadf33b8f3dda6654e37dcb1";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/themes/base16/rjv-themes.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 1,
+ column: 27
+ },
+ end: {
+ line: 21,
+ column: 1
+ }
+ },
+ "1": {
+ start: {
+ line: 23,
+ column: 24
+ },
+ end: {
+ line: 42,
+ column: 1
+ }
+ }
+ },
+ fnMap: {},
+ branchMap: {},
+ s: {
+ "0": 0,
+ "1": 0
+ },
+ f: {},
+ b: {},
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "e7b9c616f454810bdadf33b8f3dda6654e37dcb1"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
-exports.__esModule = true;
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_19m5wnj7fy = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
-function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }
+cov_19m5wnj7fy();
+var rjv_default = (cov_19m5wnj7fy().s[0]++, {
+ scheme: 'rjv-default',
+ author: 'mac gainor',
+ //transparent main background
+ base00: 'rgba(0, 0, 0, 0)',
+ base01: 'rgb(245, 245, 245)',
+ base02: 'rgb(235, 235, 235)',
+ base03: '#93a1a1',
+ base04: 'rgba(0, 0, 0, 0.3)',
+ base05: '#586e75',
+ base06: '#073642',
+ base07: '#002b36',
+ base08: '#d33682',
+ base09: '#cb4b16',
+ base0A: '#dc322f',
+ base0B: '#859900',
+ base0C: '#6c71c4',
+ base0D: '#586e75',
+ base0E: '#2aa198',
+ base0F: '#268bd2'
+});
+var rjv_grey = (cov_19m5wnj7fy().s[1]++, {
+ scheme: 'rjv-grey',
+ author: 'mac gainor',
+ base00: 'rgba(1, 1, 1, 0)',
+ base01: 'rgba(1, 1, 1, 0.1)',
+ base02: 'rgba(0, 0, 0, 0.2)',
+ base03: 'rgba(1, 1, 1, 0.3)',
+ base04: 'rgba(0, 0, 0, 0.4)',
+ base05: 'rgba(1, 1, 1, 0.5)',
+ base06: 'rgba(1, 1, 1, 0.6)',
+ base07: 'rgba(1, 1, 1, 0.7)',
+ base08: 'rgba(1, 1, 1, 0.8)',
+ base09: 'rgba(1, 1, 1, 0.8)',
+ base0A: 'rgba(1, 1, 1, 0.8)',
+ base0B: 'rgba(1, 1, 1, 0.8)',
+ base0C: 'rgba(1, 1, 1, 0.8)',
+ base0D: 'rgba(1, 1, 1, 0.8)',
+ base0E: 'rgba(1, 1, 1, 0.8)',
+ base0F: 'rgba(1, 1, 1, 0.8)'
+});
+// CONCATENATED MODULE: ./src/js/themes/styleConstants.js
+function cov_133nuyam5v() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/themes/styleConstants.js";
+ var hash = "a17a719e25852cb3ceb2cfa32941c72a98790dfc";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/themes/styleConstants.js",
+ statementMap: {},
+ fnMap: {},
+ branchMap: {},
+ s: {},
+ f: {},
+ b: {},
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "a17a719e25852cb3ceb2cfa32941c72a98790dfc"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
-var invariant = __webpack_require__(176);
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
-var _prefix = 'ID_';
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_133nuyam5v = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
-/**
- * Dispatcher is used to broadcast payloads to registered callbacks. This is
- * different from generic pub-sub systems in two ways:
- *
- * 1) Callbacks are not subscribed to particular events. Every payload is
- * dispatched to every registered callback.
- * 2) Callbacks can be deferred in whole or part until other callbacks have
- * been executed.
- *
- * For example, consider this hypothetical flight destination form, which
- * selects a default city when a country is selected:
- *
- * var flightDispatcher = new Dispatcher();
- *
- * // Keeps track of which country is selected
- * var CountryStore = {country: null};
- *
- * // Keeps track of which city is selected
- * var CityStore = {city: null};
- *
- * // Keeps track of the base flight price of the selected city
- * var FlightPriceStore = {price: null}
- *
- * When a user changes the selected city, we dispatch the payload:
- *
- * flightDispatcher.dispatch({
- * actionType: 'city-update',
- * selectedCity: 'paris'
- * });
- *
- * This payload is digested by `CityStore`:
- *
- * flightDispatcher.register(function(payload) {
- * if (payload.actionType === 'city-update') {
- * CityStore.city = payload.selectedCity;
- * }
- * });
- *
- * When the user selects a country, we dispatch the payload:
- *
- * flightDispatcher.dispatch({
- * actionType: 'country-update',
- * selectedCountry: 'australia'
- * });
- *
- * This payload is digested by both stores:
- *
- * CountryStore.dispatchToken = flightDispatcher.register(function(payload) {
- * if (payload.actionType === 'country-update') {
- * CountryStore.country = payload.selectedCountry;
- * }
- * });
- *
- * When the callback to update `CountryStore` is registered, we save a reference
- * to the returned token. Using this token with `waitFor()`, we can guarantee
- * that `CountryStore` is updated before the callback that updates `CityStore`
- * needs to query its data.
- *
- * CityStore.dispatchToken = flightDispatcher.register(function(payload) {
- * if (payload.actionType === 'country-update') {
- * // `CountryStore.country` may not be updated.
- * flightDispatcher.waitFor([CountryStore.dispatchToken]);
- * // `CountryStore.country` is now guaranteed to be updated.
- *
- * // Select the default city for the new country
- * CityStore.city = getDefaultCityForCountry(CountryStore.country);
- * }
- * });
- *
- * The usage of `waitFor()` can be chained, for example:
- *
- * FlightPriceStore.dispatchToken =
- * flightDispatcher.register(function(payload) {
- * switch (payload.actionType) {
- * case 'country-update':
- * case 'city-update':
- * flightDispatcher.waitFor([CityStore.dispatchToken]);
- * FlightPriceStore.price =
- * getFlightPriceStore(CountryStore.country, CityStore.city);
- * break;
- * }
- * });
- *
- * The `country-update` payload will be guaranteed to invoke the stores'
- * registered callbacks in order: `CountryStore`, `CityStore`, then
- * `FlightPriceStore`.
- */
-
-var Dispatcher = (function () {
- function Dispatcher() {
- _classCallCheck(this, Dispatcher);
+cov_133nuyam5v();
+/* harmony default export */ var styleConstants = ({
+ white: '#fff',
+ black: '#000',
+ transparent: 'rgba(1, 1, 1, 0)',
+ globalFontFamily: 'monospace',
+ globalCursor: 'default',
+ indentBlockWidth: '5px',
+ braceFontWeight: 'bold',
+ braceCursor: 'pointer',
+ ellipsisFontSize: '18px',
+ ellipsisLineHeight: '10px',
+ ellipsisCursor: 'pointer',
+ keyMargin: '0px 5px',
+ keyLetterSpacing: '0.5px',
+ keyFontStyle: 'none',
+ keyBorderRadius: '3px',
+ keyColonWeight: 'bold',
+ keyVerticalAlign: 'top',
+ keyOpacity: '0.85',
+ keyOpacityHover: '1',
+ keyValPaddingTop: '3px',
+ keyValPaddingBottom: '3px',
+ keyValPaddingRight: '5px',
+ keyValBorderLeft: '1px solid',
+ keyValBorderHover: '2px solid',
+ keyValPaddingHover: '3px 5px 3px 4px',
+ pushedContentMarginLeft: '6px',
+ variableValuePaddingRight: '6px',
+ nullFontSize: '11px',
+ nullFontWeight: 'bold',
+ nullPadding: '1px 2px',
+ nullBorderRadius: '3px',
+ nanFontSize: '11px',
+ nanFontWeight: 'bold',
+ nanPadding: '1px 2px',
+ nanBorderRadius: '3px',
+ undefinedFontSize: '11px',
+ undefinedFontWeight: 'bold',
+ undefinedPadding: '1px 2px',
+ undefinedBorderRadius: '3px',
+ dataTypeFontSize: '11px',
+ dataTypeMarginRight: '4px',
+ datatypeOpacity: '0.8',
+ objectSizeBorderRadius: '3px',
+ objectSizeFontStyle: 'italic',
+ objectSizeMargin: '0px 6px 0px 0px',
+ clipboardCursor: 'pointer',
+ clipboardCheckMarginLeft: '-12px',
+ metaDataPadding: '0px 0px 0px 10px',
+ arrayGroupMetaPadding: '0px 0px 0px 4px',
+ iconContainerWidth: '17px',
+ tooltipPadding: '4px',
+ editInputHeight: '25px',
+ editInputMinWidth: '130px',
+ editInputBorderRadius: '2px',
+ editInputPadding: '5px',
+ editInputMarginRight: '4px',
+ editInputFontFamily: 'monospace',
+ iconCursor: 'pointer',
+ iconFontSize: '15px',
+ iconPaddingRight: '1px',
+ dateValueMarginLeft: '2px',
+ iconMarginRight: '3px',
+ detectedRowPaddingTop: '3px',
+ addKeyCoverBackground: 'rgba(255, 255, 255, 0.3)',
+ addKeyCoverPosition: 'absolute',
+ addKeyCoverPositionPx: '0px',
+ addKeyModalWidth: '200px',
+ addKeyModalMargin: 'auto',
+ addKeyModalPadding: '10px',
+ addKeyModalRadius: '3px'
+});
+// EXTERNAL MODULE: ./node_modules/react-base16-styling/lib/index.js
+var lib = __webpack_require__(51);
+
+// CONCATENATED MODULE: ./src/js/themes/getStyle.js
+
+
+function cov_141w5bll5g() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/themes/getStyle.js";
+ var hash = "22db93b38cbcf0d76e2c3177b67ee7ae14bbd7af";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/themes/getStyle.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 5,
+ column: 17
+ },
+ end: {
+ line: 51,
+ column: 2
+ }
+ },
+ "1": {
+ start: {
+ line: 5,
+ column: 27
+ },
+ end: {
+ line: 51,
+ column: 1
+ }
+ },
+ "2": {
+ start: {
+ line: 53,
+ column: 31
+ },
+ end: {
+ line: 391,
+ column: 1
+ }
+ },
+ "3": {
+ start: {
+ line: 54,
+ column: 19
+ },
+ end: {
+ line: 54,
+ column: 34
+ }
+ },
+ "4": {
+ start: {
+ line: 56,
+ column: 4
+ },
+ end: {
+ line: 390,
+ column: 6
+ }
+ },
+ "5": {
+ start: {
+ line: 93,
+ column: 12
+ },
+ end: {
+ line: 109,
+ column: 14
+ }
+ },
+ "6": {
+ start: {
+ line: 118,
+ column: 12
+ },
+ end: {
+ line: 125,
+ column: 14
+ }
+ },
+ "7": {
+ start: {
+ line: 393,
+ column: 17
+ },
+ end: {
+ line: 402,
+ column: 1
+ }
+ },
+ "8": {
+ start: {
+ line: 394,
+ column: 20
+ },
+ end: {
+ line: 394,
+ column: 31
+ }
+ },
+ "9": {
+ start: {
+ line: 395,
+ column: 4
+ },
+ end: {
+ line: 397,
+ column: 5
+ }
+ },
+ "10": {
+ start: {
+ line: 396,
+ column: 8
+ },
+ end: {
+ line: 396,
+ column: 29
+ }
+ },
+ "11": {
+ start: {
+ line: 399,
+ column: 4
+ },
+ end: {
+ line: 401,
+ column: 6
+ }
+ },
+ "12": {
+ start: {
+ line: 405,
+ column: 4
+ },
+ end: {
+ line: 407,
+ column: 5
+ }
+ },
+ "13": {
+ start: {
+ line: 406,
+ column: 8
+ },
+ end: {
+ line: 406,
+ column: 48
+ }
+ },
+ "14": {
+ start: {
+ line: 409,
+ column: 4
+ },
+ end: {
+ line: 409,
+ column: 44
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "(anonymous_0)",
+ decl: {
+ start: {
+ line: 5,
+ column: 17
+ },
+ end: {
+ line: 5,
+ column: 18
+ }
+ },
+ loc: {
+ start: {
+ line: 5,
+ column: 27
+ },
+ end: {
+ line: 51,
+ column: 1
+ }
+ },
+ line: 5
+ },
+ "1": {
+ name: "(anonymous_1)",
+ decl: {
+ start: {
+ line: 53,
+ column: 31
+ },
+ end: {
+ line: 53,
+ column: 32
+ }
+ },
+ loc: {
+ start: {
+ line: 53,
+ column: 40
+ },
+ end: {
+ line: 391,
+ column: 1
+ }
+ },
+ line: 53
+ },
+ "2": {
+ name: "(anonymous_2)",
+ decl: {
+ start: {
+ line: 92,
+ column: 22
+ },
+ end: {
+ line: 92,
+ column: 23
+ }
+ },
+ loc: {
+ start: {
+ line: 92,
+ column: 53
+ },
+ end: {
+ line: 110,
+ column: 9
+ }
+ },
+ line: 92
+ },
+ "3": {
+ name: "(anonymous_3)",
+ decl: {
+ start: {
+ line: 117,
+ column: 23
+ },
+ end: {
+ line: 117,
+ column: 24
+ }
+ },
+ loc: {
+ start: {
+ line: 117,
+ column: 54
+ },
+ end: {
+ line: 126,
+ column: 9
+ }
+ },
+ line: 117
+ },
+ "4": {
+ name: "(anonymous_4)",
+ decl: {
+ start: {
+ line: 393,
+ column: 17
+ },
+ end: {
+ line: 393,
+ column: 18
+ }
+ },
+ loc: {
+ start: {
+ line: 393,
+ column: 26
+ },
+ end: {
+ line: 402,
+ column: 1
+ }
+ },
+ line: 393
+ },
+ "5": {
+ name: "style",
+ decl: {
+ start: {
+ line: 404,
+ column: 24
+ },
+ end: {
+ line: 404,
+ column: 29
+ }
+ },
+ loc: {
+ start: {
+ line: 404,
+ column: 54
+ },
+ end: {
+ line: 410,
+ column: 1
+ }
+ },
+ line: 404
+ }
+ },
+ branchMap: {
+ "0": {
+ loc: {
+ start: {
+ line: 395,
+ column: 4
+ },
+ end: {
+ line: 397,
+ column: 5
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 395,
+ column: 4
+ },
+ end: {
+ line: 397,
+ column: 5
+ }
+ }, {
+ start: {
+ line: 395,
+ column: 4
+ },
+ end: {
+ line: 397,
+ column: 5
+ }
+ }],
+ line: 395
+ },
+ "1": {
+ loc: {
+ start: {
+ line: 395,
+ column: 8
+ },
+ end: {
+ line: 395,
+ column: 43
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 395,
+ column: 8
+ },
+ end: {
+ line: 395,
+ column: 23
+ }
+ }, {
+ start: {
+ line: 395,
+ column: 27
+ },
+ end: {
+ line: 395,
+ column: 43
+ }
+ }],
+ line: 395
+ },
+ "2": {
+ loc: {
+ start: {
+ line: 405,
+ column: 4
+ },
+ end: {
+ line: 407,
+ column: 5
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 405,
+ column: 4
+ },
+ end: {
+ line: 407,
+ column: 5
+ }
+ }, {
+ start: {
+ line: 405,
+ column: 4
+ },
+ end: {
+ line: 407,
+ column: 5
+ }
+ }],
+ line: 405
+ }
+ },
+ s: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0,
+ "7": 0,
+ "8": 0,
+ "9": 0,
+ "10": 0,
+ "11": 0,
+ "12": 0,
+ "13": 0,
+ "14": 0
+ },
+ f: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0
+ },
+ b: {
+ "0": [0, 0],
+ "1": [0, 0],
+ "2": [0, 0]
+ },
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "22db93b38cbcf0d76e2c3177b67ee7ae14bbd7af"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
- this._callbacks = {};
- this._isDispatching = false;
- this._isHandled = {};
- this._isPending = {};
- this._lastID = 1;
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
}
- /**
- * Registers a callback to be invoked with every dispatched payload. Returns
- * a token that can be used with `waitFor()`.
- */
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_141w5bll5g = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
- Dispatcher.prototype.register = function register(callback) {
- var id = _prefix + this._lastID++;
- this._callbacks[id] = callback;
- return id;
- };
+cov_141w5bll5g();
- /**
- * Removes a callback based on its token.
- */
- Dispatcher.prototype.unregister = function unregister(id) {
- !this._callbacks[id] ? false ? undefined : invariant(false) : undefined;
- delete this._callbacks[id];
- };
- /**
- * Waits for the callbacks specified to be invoked before continuing execution
- * of the current callback. This method should only be used by a callback in
- * response to a dispatched payload.
- */
+cov_141w5bll5g().s[0]++;
- Dispatcher.prototype.waitFor = function waitFor(ids) {
- !this._isDispatching ? false ? undefined : invariant(false) : undefined;
- for (var ii = 0; ii < ids.length; ii++) {
- var id = ids[ii];
- if (this._isPending[id]) {
- !this._isHandled[id] ? false ? undefined : invariant(false) : undefined;
- continue;
- }
- !this._callbacks[id] ? false ? undefined : invariant(false) : undefined;
- this._invokeCallback(id);
+var colorMap = function colorMap(theme) {
+ cov_141w5bll5g().f[0]++;
+ cov_141w5bll5g().s[1]++;
+ return {
+ backgroundColor: theme.base00,
+ ellipsisColor: theme.base09,
+ braceColor: theme.base07,
+ expandedIcon: theme.base0D,
+ collapsedIcon: theme.base0E,
+ keyColor: theme.base07,
+ arrayKeyColor: theme.base0C,
+ objectSize: theme.base04,
+ copyToClipboard: theme.base0F,
+ copyToClipboardCheck: theme.base0D,
+ objectBorder: theme.base02,
+ dataTypes: {
+ "boolean": theme.base0E,
+ date: theme.base0D,
+ "float": theme.base0B,
+ "function": theme.base0D,
+ integer: theme.base0F,
+ string: theme.base09,
+ nan: theme.base08,
+ "null": theme.base0A,
+ undefined: theme.base05,
+ regexp: theme.base0A,
+ background: theme.base02
+ },
+ editVariable: {
+ editIcon: theme.base0E,
+ cancelIcon: theme.base09,
+ removeIcon: theme.base09,
+ addIcon: theme.base0E,
+ checkIcon: theme.base0E,
+ background: theme.base01,
+ color: theme.base0A,
+ border: theme.base07
+ },
+ addKeyModal: {
+ background: theme.base05,
+ border: theme.base04,
+ color: theme.base0A,
+ labelColor: theme.base01
+ },
+ validationFailure: {
+ background: theme.base09,
+ iconColor: theme.base01,
+ fontColor: theme.base01
}
};
+};
- /**
- * Dispatches a payload to all registered callbacks.
- */
+cov_141w5bll5g().s[2]++;
- Dispatcher.prototype.dispatch = function dispatch(payload) {
- !!this._isDispatching ? false ? undefined : invariant(false) : undefined;
- this._startDispatching(payload);
- try {
- for (var id in this._callbacks) {
- if (this._isPending[id]) {
- continue;
- }
- this._invokeCallback(id);
+var getStyle_getDefaultThemeStyling = function getDefaultThemeStyling(theme) {
+ cov_141w5bll5g().f[1]++;
+ var colors = (cov_141w5bll5g().s[3]++, colorMap(theme));
+ cov_141w5bll5g().s[4]++;
+ return {
+ 'app-container': {
+ fontFamily: styleConstants.globalFontFamily,
+ cursor: styleConstants.globalCursor,
+ backgroundColor: colors.backgroundColor,
+ position: 'relative'
+ },
+ ellipsis: {
+ display: 'inline-block',
+ color: colors.ellipsisColor,
+ fontSize: styleConstants.ellipsisFontSize,
+ lineHeight: styleConstants.ellipsisLineHeight,
+ cursor: styleConstants.ellipsisCursor
+ },
+ 'brace-row': {
+ display: 'inline-block',
+ cursor: 'pointer'
+ },
+ brace: {
+ display: 'inline-block',
+ cursor: styleConstants.braceCursor,
+ fontWeight: styleConstants.braceFontWeight,
+ color: colors.braceColor
+ },
+ 'expanded-icon': {
+ color: colors.expandedIcon
+ },
+ 'collapsed-icon': {
+ color: colors.collapsedIcon
+ },
+ colon: {
+ display: 'inline-block',
+ margin: styleConstants.keyMargin,
+ color: colors.keyColor,
+ verticalAlign: 'top'
+ },
+ objectKeyVal: function objectKeyVal(component, variable_style) {
+ cov_141w5bll5g().f[2]++;
+ cov_141w5bll5g().s[5]++;
+ return {
+ style: _objectSpread2({
+ paddingTop: styleConstants.keyValPaddingTop,
+ paddingRight: styleConstants.keyValPaddingRight,
+ paddingBottom: styleConstants.keyValPaddingBottom,
+ borderLeft: styleConstants.keyValBorderLeft + ' ' + colors.objectBorder,
+ ':hover': {
+ paddingLeft: variable_style.paddingLeft - 1 + 'px',
+ borderLeft: styleConstants.keyValBorderHover + ' ' + colors.objectBorder
+ }
+ }, variable_style)
+ };
+ },
+ 'object-key-val-no-border': {
+ padding: styleConstants.keyValPadding
+ },
+ 'pushed-content': {
+ marginLeft: styleConstants.pushedContentMarginLeft
+ },
+ variableValue: function variableValue(component, variable_style) {
+ cov_141w5bll5g().f[3]++;
+ cov_141w5bll5g().s[6]++;
+ return {
+ style: _objectSpread2({
+ display: 'inline-block',
+ paddingRight: styleConstants.variableValuePaddingRight,
+ position: 'relative'
+ }, variable_style)
+ };
+ },
+ 'object-name': {
+ display: 'inline-block',
+ color: colors.keyColor,
+ letterSpacing: styleConstants.keyLetterSpacing,
+ fontStyle: styleConstants.keyFontStyle,
+ verticalAlign: styleConstants.keyVerticalAlign,
+ opacity: styleConstants.keyOpacity,
+ ':hover': {
+ opacity: styleConstants.keyOpacityHover
}
- } finally {
- this._stopDispatching();
+ },
+ 'array-key': {
+ display: 'inline-block',
+ color: colors.arrayKeyColor,
+ letterSpacing: styleConstants.keyLetterSpacing,
+ fontStyle: styleConstants.keyFontStyle,
+ verticalAlign: styleConstants.keyVerticalAlign,
+ opacity: styleConstants.keyOpacity,
+ ':hover': {
+ opacity: styleConstants.keyOpacityHover
+ }
+ },
+ 'object-size': {
+ color: colors.objectSize,
+ borderRadius: styleConstants.objectSizeBorderRadius,
+ fontStyle: styleConstants.objectSizeFontStyle,
+ margin: styleConstants.objectSizeMargin,
+ cursor: 'default'
+ },
+ 'data-type-label': {
+ fontSize: styleConstants.dataTypeFontSize,
+ marginRight: styleConstants.dataTypeMarginRight,
+ opacity: styleConstants.datatypeOpacity
+ },
+ "boolean": {
+ display: 'inline-block',
+ color: colors.dataTypes["boolean"]
+ },
+ date: {
+ display: 'inline-block',
+ color: colors.dataTypes.date
+ },
+ 'date-value': {
+ marginLeft: styleConstants.dateValueMarginLeft
+ },
+ "float": {
+ display: 'inline-block',
+ color: colors.dataTypes["float"]
+ },
+ "function": {
+ display: 'inline-block',
+ color: colors.dataTypes['function'],
+ cursor: 'pointer',
+ whiteSpace: 'pre-line'
+ },
+ 'function-value': {
+ fontStyle: 'italic'
+ },
+ integer: {
+ display: 'inline-block',
+ color: colors.dataTypes.integer
+ },
+ string: {
+ display: 'inline-block',
+ color: colors.dataTypes.string
+ },
+ nan: {
+ display: 'inline-block',
+ color: colors.dataTypes.nan,
+ fontSize: styleConstants.nanFontSize,
+ fontWeight: styleConstants.nanFontWeight,
+ backgroundColor: colors.dataTypes.background,
+ padding: styleConstants.nanPadding,
+ borderRadius: styleConstants.nanBorderRadius
+ },
+ "null": {
+ display: 'inline-block',
+ color: colors.dataTypes["null"],
+ fontSize: styleConstants.nullFontSize,
+ fontWeight: styleConstants.nullFontWeight,
+ backgroundColor: colors.dataTypes.background,
+ padding: styleConstants.nullPadding,
+ borderRadius: styleConstants.nullBorderRadius
+ },
+ undefined: {
+ display: 'inline-block',
+ color: colors.dataTypes.undefined,
+ fontSize: styleConstants.undefinedFontSize,
+ padding: styleConstants.undefinedPadding,
+ borderRadius: styleConstants.undefinedBorderRadius,
+ backgroundColor: colors.dataTypes.background
+ },
+ regexp: {
+ display: 'inline-block',
+ color: colors.dataTypes.regexp
+ },
+ 'copy-to-clipboard': {
+ cursor: styleConstants.clipboardCursor
+ },
+ 'copy-icon': {
+ color: colors.copyToClipboard,
+ fontSize: styleConstants.iconFontSize,
+ marginRight: styleConstants.iconMarginRight,
+ verticalAlign: 'top'
+ },
+ 'copy-icon-copied': {
+ color: colors.copyToClipboardCheck,
+ marginLeft: styleConstants.clipboardCheckMarginLeft
+ },
+ 'array-group-meta-data': {
+ display: 'inline-block',
+ padding: styleConstants.arrayGroupMetaPadding
+ },
+ 'object-meta-data': {
+ display: 'inline-block',
+ padding: styleConstants.metaDataPadding
+ },
+ 'icon-container': {
+ display: 'inline-block',
+ width: styleConstants.iconContainerWidth
+ },
+ tooltip: {
+ padding: styleConstants.tooltipPadding
+ },
+ removeVarIcon: {
+ verticalAlign: 'top',
+ display: 'inline-block',
+ color: colors.editVariable.removeIcon,
+ cursor: styleConstants.iconCursor,
+ fontSize: styleConstants.iconFontSize,
+ marginRight: styleConstants.iconMarginRight
+ },
+ addVarIcon: {
+ verticalAlign: 'top',
+ display: 'inline-block',
+ color: colors.editVariable.addIcon,
+ cursor: styleConstants.iconCursor,
+ fontSize: styleConstants.iconFontSize,
+ marginRight: styleConstants.iconMarginRight
+ },
+ editVarIcon: {
+ verticalAlign: 'top',
+ display: 'inline-block',
+ color: colors.editVariable.editIcon,
+ cursor: styleConstants.iconCursor,
+ fontSize: styleConstants.iconFontSize,
+ marginRight: styleConstants.iconMarginRight
+ },
+ 'edit-icon-container': {
+ display: 'inline-block',
+ verticalAlign: 'top'
+ },
+ 'check-icon': {
+ display: 'inline-block',
+ cursor: styleConstants.iconCursor,
+ color: colors.editVariable.checkIcon,
+ fontSize: styleConstants.iconFontSize,
+ paddingRight: styleConstants.iconPaddingRight
+ },
+ 'cancel-icon': {
+ display: 'inline-block',
+ cursor: styleConstants.iconCursor,
+ color: colors.editVariable.cancelIcon,
+ fontSize: styleConstants.iconFontSize,
+ paddingRight: styleConstants.iconPaddingRight
+ },
+ 'edit-input': {
+ display: 'inline-block',
+ minHeight: styleConstants.editInputHeight,
+ minWidth: styleConstants.editInputMinWidth,
+ borderRadius: styleConstants.editInputBorderRadius,
+ backgroundColor: colors.editVariable.background,
+ color: colors.editVariable.color,
+ padding: styleConstants.editInputPadding,
+ marginRight: styleConstants.editInputMarginRight,
+ fontFamily: styleConstants.editInputFontFamily
+ },
+ 'detected-row': {
+ paddingTop: styleConstants.detectedRowPaddingTop
+ },
+ 'key-modal-request': {
+ position: styleConstants.addKeyCoverPosition,
+ top: styleConstants.addKeyCoverPositionPx,
+ left: styleConstants.addKeyCoverPositionPx,
+ right: styleConstants.addKeyCoverPositionPx,
+ bottom: styleConstants.addKeyCoverPositionPx,
+ backgroundColor: styleConstants.addKeyCoverBackground
+ },
+ 'key-modal': {
+ width: styleConstants.addKeyModalWidth,
+ backgroundColor: colors.addKeyModal.background,
+ marginLeft: styleConstants.addKeyModalMargin,
+ marginRight: styleConstants.addKeyModalMargin,
+ padding: styleConstants.addKeyModalPadding,
+ borderRadius: styleConstants.addKeyModalRadius,
+ marginTop: '15px',
+ position: 'relative'
+ },
+ 'key-modal-label': {
+ color: colors.addKeyModal.labelColor,
+ marginLeft: '2px',
+ marginBottom: '5px',
+ fontSize: '11px'
+ },
+ 'key-modal-input-container': {
+ overflow: 'hidden'
+ },
+ 'key-modal-input': {
+ width: '100%',
+ padding: '3px 6px',
+ fontFamily: 'monospace',
+ color: colors.addKeyModal.color,
+ border: 'none',
+ boxSizing: 'border-box',
+ borderRadius: '2px'
+ },
+ 'key-modal-cancel': {
+ backgroundColor: colors.editVariable.removeIcon,
+ position: 'absolute',
+ top: '0px',
+ right: '0px',
+ borderRadius: '0px 3px 0px 3px',
+ cursor: 'pointer'
+ },
+ 'key-modal-cancel-icon': {
+ color: colors.addKeyModal.labelColor,
+ fontSize: styleConstants.iconFontSize,
+ transform: 'rotate(45deg)'
+ },
+ 'key-modal-submit': {
+ color: colors.editVariable.addIcon,
+ fontSize: styleConstants.iconFontSize,
+ position: 'absolute',
+ right: '2px',
+ top: '3px',
+ cursor: 'pointer'
+ },
+ 'function-ellipsis': {
+ display: 'inline-block',
+ color: colors.ellipsisColor,
+ fontSize: styleConstants.ellipsisFontSize,
+ lineHeight: styleConstants.ellipsisLineHeight,
+ cursor: styleConstants.ellipsisCursor
+ },
+ 'validation-failure': {
+ "float": 'right',
+ padding: '3px 6px',
+ borderRadius: '2px',
+ cursor: 'pointer',
+ color: colors.validationFailure.fontColor,
+ backgroundColor: colors.validationFailure.background
+ },
+ 'validation-failure-label': {
+ marginRight: '6px'
+ },
+ 'validation-failure-clear': {
+ position: 'relative',
+ verticalAlign: 'top',
+ cursor: 'pointer',
+ color: colors.validationFailure.iconColor,
+ fontSize: styleConstants.iconFontSize,
+ transform: 'rotate(45deg)'
}
};
+};
- /**
- * Is this Dispatcher currently dispatching.
- */
+cov_141w5bll5g().s[7]++;
- Dispatcher.prototype.isDispatching = function isDispatching() {
- return this._isDispatching;
- };
+var getStyle_getStyle = function getStyle(theme) {
+ cov_141w5bll5g().f[4]++;
+ var rjv_theme = (cov_141w5bll5g().s[8]++, rjv_default);
+ cov_141w5bll5g().s[9]++;
- /**
- * Call the callback stored with the given id. Also do some internal
- * bookkeeping.
- *
- * @internal
- */
+ if ((cov_141w5bll5g().b[1][0]++, theme === false) || (cov_141w5bll5g().b[1][1]++, theme === 'none')) {
+ cov_141w5bll5g().b[0][0]++;
+ cov_141w5bll5g().s[10]++;
+ rjv_theme = rjv_grey;
+ } else {
+ cov_141w5bll5g().b[0][1]++;
+ }
- Dispatcher.prototype._invokeCallback = function _invokeCallback(id) {
- this._isPending[id] = true;
- this._callbacks[id](this._pendingPayload);
- this._isHandled[id] = true;
- };
+ cov_141w5bll5g().s[11]++;
+ return Object(lib["createStyling"])(getStyle_getDefaultThemeStyling, {
+ defaultBase16: rjv_theme
+ })(theme);
+};
- /**
- * Set up bookkeeping needed when dispatching.
- *
- * @internal
- */
+function getStyle_style(theme, component, args) {
+ cov_141w5bll5g().f[5]++;
+ cov_141w5bll5g().s[12]++;
- Dispatcher.prototype._startDispatching = function _startDispatching(payload) {
- for (var id in this._callbacks) {
- this._isPending[id] = false;
- this._isHandled[id] = false;
- }
- this._pendingPayload = payload;
- this._isDispatching = true;
- };
+ if (!theme) {
+ cov_141w5bll5g().b[2][0]++;
+ cov_141w5bll5g().s[13]++;
+ console.error('theme has not been set');
+ } else {
+ cov_141w5bll5g().b[2][1]++;
+ }
- /**
- * Clear bookkeeping used for dispatching.
- *
- * @internal
- */
+ cov_141w5bll5g().s[14]++;
+ return getStyle_getStyle(theme)(component, args);
+}
+// CONCATENATED MODULE: ./src/js/components/DataTypes/DataTypeLabel.js
- Dispatcher.prototype._stopDispatching = function _stopDispatching() {
- delete this._pendingPayload;
- this._isDispatching = false;
- };
- return Dispatcher;
-})();
-module.exports = Dispatcher;
-/***/ }),
-/* 176 */
-/***/ (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.
- *
- */
+function cov_29cydb6rfo() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/components/DataTypes/DataTypeLabel.js";
+ var hash = "9d492531191ef184f28ea27105daebf214e87fb0";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/components/DataTypes/DataTypeLabel.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 8,
+ column: 62
+ },
+ end: {
+ line: 8,
+ column: 72
+ }
+ },
+ "1": {
+ start: {
+ line: 9,
+ column: 8
+ },
+ end: {
+ line: 18,
+ column: 9
+ }
+ },
+ "2": {
+ start: {
+ line: 10,
+ column: 12
+ },
+ end: {
+ line: 17,
+ column: 14
+ }
+ },
+ "3": {
+ start: {
+ line: 19,
+ column: 8
+ },
+ end: {
+ line: 19,
+ column: 20
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "(anonymous_0)",
+ decl: {
+ start: {
+ line: 7,
+ column: 4
+ },
+ end: {
+ line: 7,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 7,
+ column: 13
+ },
+ end: {
+ line: 20,
+ column: 5
+ }
+ },
+ line: 7
+ }
+ },
+ branchMap: {
+ "0": {
+ loc: {
+ start: {
+ line: 9,
+ column: 8
+ },
+ end: {
+ line: 18,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 9,
+ column: 8
+ },
+ end: {
+ line: 18,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 9,
+ column: 8
+ },
+ end: {
+ line: 18,
+ column: 9
+ }
+ }],
+ line: 9
+ }
+ },
+ s: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0
+ },
+ f: {
+ "0": 0
+ },
+ b: {
+ "0": [0, 0]
+ },
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "9d492531191ef184f28ea27105daebf214e87fb0"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_29cydb6rfo = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
-/**
- * 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.
- */
+cov_29cydb6rfo();
+ //theme
-var validateFormat = function validateFormat(format) {};
-if (false) {}
-function invariant(condition, format, a, b, c, d, e, f) {
- validateFormat(format);
+var DataTypeLabel_default = /*#__PURE__*/function (_React$PureComponent) {
+ _inherits(_default, _React$PureComponent);
- 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';
- }
+ var _super = _createSuper(_default);
- error.framesToPop = 1; // we don't care about invariant's own frame
- throw error;
- }
-}
+ function _default() {
+ _classCallCheck(this, _default);
-module.exports = invariant;
+ return _super.apply(this, arguments);
+ }
-/***/ }),
-/* 177 */
-/***/ (function(module, exports, __webpack_require__) {
+ _createClass(_default, [{
+ key: "render",
+ value: function render() {
+ cov_29cydb6rfo().f[0]++;
+
+ var _ref = (cov_29cydb6rfo().s[0]++, this.props),
+ rjvId = _ref.rjvId,
+ type_name = _ref.type_name,
+ displayDataTypes = _ref.displayDataTypes,
+ theme = _ref.theme;
+
+ cov_29cydb6rfo().s[1]++;
+
+ if (displayDataTypes) {
+ cov_29cydb6rfo().b[0][0]++;
+ cov_29cydb6rfo().s[2]++;
+ return /*#__PURE__*/external_React_default.a.createElement("span", Object.assign({
+ className: "data-type-label"
+ }, getStyle_style(theme, 'data-type-label')), type_name);
+ } else {
+ cov_29cydb6rfo().b[0][1]++;
+ }
-"use strict";
+ cov_29cydb6rfo().s[3]++;
+ return null;
+ }
+ }]);
+ return _default;
+}((external_React_default.a.PureComponent));
-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; }; }();
+// CONCATENATED MODULE: ./src/js/components/DataTypes/Boolean.js
-var _react = __webpack_require__(1);
-var _react2 = _interopRequireDefault(_react);
-var _getStyle = __webpack_require__(2);
-var _getStyle2 = _interopRequireDefault(_getStyle);
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+function cov_1nujknf54f() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/components/DataTypes/Boolean.js";
+ var hash = "04f041c01da2be0ef49274942d4779c71c5def2a";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/components/DataTypes/Boolean.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 9,
+ column: 26
+ },
+ end: {
+ line: 9,
+ column: 32
+ }
+ },
+ "1": {
+ start: {
+ line: 10,
+ column: 26
+ },
+ end: {
+ line: 10,
+ column: 30
+ }
+ },
+ "2": {
+ start: {
+ line: 12,
+ column: 8
+ },
+ end: {
+ line: 17,
+ column: 10
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "(anonymous_0)",
+ decl: {
+ start: {
+ line: 8,
+ column: 4
+ },
+ end: {
+ line: 8,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 8,
+ column: 13
+ },
+ end: {
+ line: 18,
+ column: 5
+ }
+ },
+ line: 8
+ }
+ },
+ branchMap: {
+ "0": {
+ loc: {
+ start: {
+ line: 15,
+ column: 17
+ },
+ end: {
+ line: 15,
+ column: 47
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 15,
+ column: 31
+ },
+ end: {
+ line: 15,
+ column: 37
+ }
+ }, {
+ start: {
+ line: 15,
+ column: 40
+ },
+ end: {
+ line: 15,
+ column: 47
+ }
+ }],
+ line: 15
+ }
+ },
+ s: {
+ "0": 0,
+ "1": 0,
+ "2": 0
+ },
+ f: {
+ "0": 0
+ },
+ b: {
+ "0": [0, 0]
+ },
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "04f041c01da2be0ef49274942d4779c71c5def2a"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
-function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
-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; }
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_1nujknf54f = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
-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; }
+cov_1nujknf54f();
-//theme
+ //theme
-var _class = function (_React$PureComponent) {
- _inherits(_class, _React$PureComponent);
- function _class() {
- _classCallCheck(this, _class);
+var Boolean_default = /*#__PURE__*/function (_React$PureComponent) {
+ _inherits(_default, _React$PureComponent);
- return _possibleConstructorReturn(this, (_class.__proto__ || Object.getPrototypeOf(_class)).apply(this, arguments));
- }
+ var _super = _createSuper(_default);
- _createClass(_class, [{
- key: 'render',
- value: function render() {
- return _react2.default.createElement(
- 'div',
- (0, _getStyle2.default)(this.props.theme, 'nan'),
- 'NaN'
- );
- }
- }]);
+ function _default() {
+ _classCallCheck(this, _default);
- return _class;
-}(_react2.default.PureComponent);
+ return _super.apply(this, arguments);
+ }
-exports.default = _class;
+ _createClass(_default, [{
+ key: "render",
+ value: function render() {
+ cov_1nujknf54f().f[0]++;
+ var type_name = (cov_1nujknf54f().s[0]++, 'bool');
-/***/ }),
-/* 178 */
-/***/ (function(module, exports, __webpack_require__) {
+ var _ref = (cov_1nujknf54f().s[1]++, this),
+ props = _ref.props;
-"use strict";
+ cov_1nujknf54f().s[2]++;
+ return /*#__PURE__*/external_React_default.a.createElement("div", getStyle_style(props.theme, 'boolean'), /*#__PURE__*/external_React_default.a.createElement(DataTypeLabel_default, Object.assign({
+ type_name: type_name
+ }, props)), props.value ? (cov_1nujknf54f().b[0][0]++, 'true') : (cov_1nujknf54f().b[0][1]++, 'false'));
+ }
+ }]);
+ return _default;
+}((external_React_default.a.PureComponent));
-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; }; }();
+// CONCATENATED MODULE: ./src/js/components/DataTypes/Date.js
-var _react = __webpack_require__(1);
-var _react2 = _interopRequireDefault(_react);
-var _getStyle = __webpack_require__(2);
-var _getStyle2 = _interopRequireDefault(_getStyle);
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+function cov_x3m1iwmnu() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/components/DataTypes/Date.js";
+ var hash = "97a99afa9fa9c2548095632f1be93adc431455a5";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/components/DataTypes/Date.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 9,
+ column: 26
+ },
+ end: {
+ line: 9,
+ column: 32
+ }
+ },
+ "1": {
+ start: {
+ line: 10,
+ column: 26
+ },
+ end: {
+ line: 10,
+ column: 30
+ }
+ },
+ "2": {
+ start: {
+ line: 11,
+ column: 32
+ },
+ end: {
+ line: 18,
+ column: 9
+ }
+ },
+ "3": {
+ start: {
+ line: 19,
+ column: 8
+ },
+ end: {
+ line: 26,
+ column: 10
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "(anonymous_0)",
+ decl: {
+ start: {
+ line: 8,
+ column: 4
+ },
+ end: {
+ line: 8,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 8,
+ column: 13
+ },
+ end: {
+ line: 27,
+ column: 5
+ }
+ },
+ line: 8
+ }
+ },
+ branchMap: {},
+ s: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0
+ },
+ f: {
+ "0": 0
+ },
+ b: {},
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "97a99afa9fa9c2548095632f1be93adc431455a5"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
-function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
-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; }
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_x3m1iwmnu = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
-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; }
+cov_x3m1iwmnu();
-//theme
+ //theme
-var _class = function (_React$PureComponent) {
- _inherits(_class, _React$PureComponent);
- function _class() {
- _classCallCheck(this, _class);
+var Date_default = /*#__PURE__*/function (_React$PureComponent) {
+ _inherits(_default, _React$PureComponent);
- return _possibleConstructorReturn(this, (_class.__proto__ || Object.getPrototypeOf(_class)).apply(this, arguments));
- }
+ var _super = _createSuper(_default);
- _createClass(_class, [{
- key: 'render',
- value: function render() {
- return _react2.default.createElement(
- 'div',
- (0, _getStyle2.default)(this.props.theme, 'null'),
- 'NULL'
- );
- }
- }]);
+ function _default() {
+ _classCallCheck(this, _default);
- return _class;
-}(_react2.default.PureComponent);
+ return _super.apply(this, arguments);
+ }
-exports.default = _class;
+ _createClass(_default, [{
+ key: "render",
+ value: function render() {
+ cov_x3m1iwmnu().f[0]++;
+ var type_name = (cov_x3m1iwmnu().s[0]++, 'date');
+
+ var _ref = (cov_x3m1iwmnu().s[1]++, this),
+ props = _ref.props;
+
+ var display_options = (cov_x3m1iwmnu().s[2]++, {
+ weekday: 'short',
+ year: 'numeric',
+ month: 'short',
+ day: 'numeric',
+ hour: '2-digit',
+ minute: '2-digit'
+ });
+ cov_x3m1iwmnu().s[3]++;
+ return /*#__PURE__*/external_React_default.a.createElement("div", getStyle_style(props.theme, 'date'), /*#__PURE__*/external_React_default.a.createElement(DataTypeLabel_default, Object.assign({
+ type_name: type_name
+ }, props)), /*#__PURE__*/external_React_default.a.createElement("span", Object.assign({
+ className: "date-value"
+ }, getStyle_style(props.theme, 'date-value')), props.value.toLocaleTimeString('en-us', display_options)));
+ }
+ }]);
-/***/ }),
-/* 179 */
-/***/ (function(module, exports, __webpack_require__) {
+ return _default;
+}((external_React_default.a.PureComponent));
-"use strict";
+// CONCATENATED MODULE: ./src/js/components/DataTypes/Float.js
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
-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 _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__(1);
-var _react2 = _interopRequireDefault(_react);
+function cov_2ex42zsz1s() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/components/DataTypes/Float.js";
+ var hash = "f28c5d1768c5e15c508cd366bfdb8bce60d77c7b";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/components/DataTypes/Float.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 9,
+ column: 26
+ },
+ end: {
+ line: 9,
+ column: 33
+ }
+ },
+ "1": {
+ start: {
+ line: 10,
+ column: 26
+ },
+ end: {
+ line: 10,
+ column: 30
+ }
+ },
+ "2": {
+ start: {
+ line: 11,
+ column: 8
+ },
+ end: {
+ line: 16,
+ column: 10
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "(anonymous_0)",
+ decl: {
+ start: {
+ line: 8,
+ column: 4
+ },
+ end: {
+ line: 8,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 8,
+ column: 13
+ },
+ end: {
+ line: 17,
+ column: 5
+ }
+ },
+ line: 8
+ }
+ },
+ branchMap: {},
+ s: {
+ "0": 0,
+ "1": 0,
+ "2": 0
+ },
+ f: {
+ "0": 0
+ },
+ b: {},
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "f28c5d1768c5e15c508cd366bfdb8bce60d77c7b"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
-var _DataTypeLabel = __webpack_require__(9);
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
-var _DataTypeLabel2 = _interopRequireDefault(_DataTypeLabel);
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_2ex42zsz1s = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
-var _getStyle = __webpack_require__(2);
+cov_2ex42zsz1s();
-var _getStyle2 = _interopRequireDefault(_getStyle);
+ //theme
-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; }
+var Float_default = /*#__PURE__*/function (_React$PureComponent) {
+ _inherits(_default, _React$PureComponent);
-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 _super = _createSuper(_default);
-//theme
+ function _default() {
+ _classCallCheck(this, _default);
+ return _super.apply(this, arguments);
+ }
-var _class = function (_React$PureComponent) {
- _inherits(_class, _React$PureComponent);
+ _createClass(_default, [{
+ key: "render",
+ value: function render() {
+ cov_2ex42zsz1s().f[0]++;
+ var type_name = (cov_2ex42zsz1s().s[0]++, 'float');
- function _class() {
- _classCallCheck(this, _class);
+ var _ref = (cov_2ex42zsz1s().s[1]++, this),
+ props = _ref.props;
- return _possibleConstructorReturn(this, (_class.__proto__ || Object.getPrototypeOf(_class)).apply(this, arguments));
+ cov_2ex42zsz1s().s[2]++;
+ return /*#__PURE__*/external_React_default.a.createElement("div", getStyle_style(props.theme, 'float'), /*#__PURE__*/external_React_default.a.createElement(DataTypeLabel_default, Object.assign({
+ type_name: type_name
+ }, props)), this.props.value);
}
+ }]);
- _createClass(_class, [{
- key: 'render',
- value: function render() {
- var type_name = 'int';
- var props = this.props;
+ return _default;
+}((external_React_default.a.PureComponent));
- return _react2.default.createElement(
- 'div',
- (0, _getStyle2.default)(props.theme, 'integer'),
- _react2.default.createElement(_DataTypeLabel2.default, _extends({ type_name: type_name }, props)),
- this.props.value
- );
- }
- }]);
- return _class;
-}(_react2.default.PureComponent);
+// CONCATENATED MODULE: ./node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/arrayLikeToArray.js
+function _arrayLikeToArray(arr, len) {
+ if (len == null || len > arr.length) len = arr.length;
-exports.default = _class;
+ for (var i = 0, arr2 = new Array(len); i < len; i++) {
+ arr2[i] = arr[i];
+ }
-/***/ }),
-/* 180 */
-/***/ (function(module, exports, __webpack_require__) {
+ return arr2;
+}
+// CONCATENATED MODULE: ./node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js
+
+function _unsupportedIterableToArray(o, minLen) {
+ if (!o) return;
+ if (typeof o === "string") return _arrayLikeToArray(o, minLen);
+ var n = Object.prototype.toString.call(o).slice(8, -1);
+ if (n === "Object" && o.constructor) n = o.constructor.name;
+ if (n === "Map" || n === "Set") return Array.from(o);
+ if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);
+}
+// CONCATENATED MODULE: ./node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/createForOfIteratorHelper.js
-"use strict";
+function _createForOfIteratorHelper(o, allowArrayLike) {
+ var it;
+ if (typeof Symbol === "undefined" || o[Symbol.iterator] == null) {
+ if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") {
+ if (it) o = it;
+ var i = 0;
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
+ var F = function F() {};
-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; };
+ return {
+ s: F,
+ n: function n() {
+ if (i >= o.length) return {
+ done: true
+ };
+ return {
+ done: false,
+ value: o[i++]
+ };
+ },
+ e: function e(_e) {
+ throw _e;
+ },
+ f: F
+ };
+ }
-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; }; }();
+ throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
+ }
-var _react = __webpack_require__(1);
+ var normalCompletion = true,
+ didErr = false,
+ err;
+ return {
+ s: function s() {
+ it = o[Symbol.iterator]();
+ },
+ n: function n() {
+ var step = it.next();
+ normalCompletion = step.done;
+ return step;
+ },
+ e: function e(_e2) {
+ didErr = true;
+ err = _e2;
+ },
+ f: function f() {
+ try {
+ if (!normalCompletion && it["return"] != null) it["return"]();
+ } finally {
+ if (didErr) throw err;
+ }
+ }
+ };
+}
+// CONCATENATED MODULE: ./node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/arrayWithoutHoles.js
-var _react2 = _interopRequireDefault(_react);
+function _arrayWithoutHoles(arr) {
+ if (Array.isArray(arr)) return _arrayLikeToArray(arr);
+}
+// CONCATENATED MODULE: ./node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/iterableToArray.js
+function _iterableToArray(iter) {
+ if (typeof Symbol !== "undefined" && Symbol.iterator in Object(iter)) return Array.from(iter);
+}
+// CONCATENATED MODULE: ./node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/nonIterableSpread.js
+function _nonIterableSpread() {
+ throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
+}
+// CONCATENATED MODULE: ./node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/toConsumableArray.js
-var _DataTypeLabel = __webpack_require__(9);
-var _DataTypeLabel2 = _interopRequireDefault(_DataTypeLabel);
-var _getStyle = __webpack_require__(2);
-var _getStyle2 = _interopRequireDefault(_getStyle);
+function _toConsumableArray(arr) {
+ return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread();
+}
+// EXTERNAL MODULE: ./node_modules/events/events.js
+var events = __webpack_require__(52);
+
+// EXTERNAL MODULE: ./node_modules/flux/index.js
+var flux = __webpack_require__(53);
+
+// CONCATENATED MODULE: ./src/js/helpers/dispatcher.js
+function cov_ym7636bbq() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/helpers/dispatcher.js";
+ var hash = "0750ae893e2da75d39c453d28bf118335227ab59";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/helpers/dispatcher.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 2,
+ column: 19
+ },
+ end: {
+ line: 2,
+ column: 35
+ }
+ }
+ },
+ fnMap: {},
+ branchMap: {},
+ s: {
+ "0": 0
+ },
+ f: {},
+ b: {},
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "0750ae893e2da75d39c453d28bf118335227ab59"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
-function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_ym7636bbq = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
-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; }
+cov_ym7636bbq();
-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 dispatcher = (cov_ym7636bbq().s[0]++, new flux["Dispatcher"]());
+/* harmony default export */ var helpers_dispatcher = (dispatcher);
+// CONCATENATED MODULE: ./src/js/stores/ObjectAttributes.js
-//theme
-var _class = function (_React$PureComponent) {
- _inherits(_class, _React$PureComponent);
- function _class() {
- _classCallCheck(this, _class);
- return _possibleConstructorReturn(this, (_class.__proto__ || Object.getPrototypeOf(_class)).apply(this, arguments));
- }
- _createClass(_class, [{
- key: 'render',
- value: function render() {
- var type_name = 'regexp';
- var props = this.props;
- return _react2.default.createElement(
- 'div',
- (0, _getStyle2.default)(props.theme, 'regexp'),
- _react2.default.createElement(_DataTypeLabel2.default, _extends({ type_name: type_name }, props)),
- this.props.value.toString()
- );
+function cov_27pkmm3h2i() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/stores/ObjectAttributes.js";
+ var hash = "65c9acabd36261c1c729ad70028e6d27ce20e981";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/stores/ObjectAttributes.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 7,
+ column: 14
+ },
+ end: {
+ line: 7,
+ column: 16
}
- }]);
-
- return _class;
-}(_react2.default.PureComponent);
-
-exports.default = _class;
-
-/***/ }),
-/* 181 */
-/***/ (function(module, exports, __webpack_require__) {
-
-"use strict";
+ },
+ "1": {
+ start: {
+ line: 9,
+ column: 10
+ },
+ end: {
+ line: 17,
+ column: 5
+ }
+ },
+ "2": {
+ start: {
+ line: 10,
+ column: 8
+ },
+ end: {
+ line: 12,
+ column: 9
+ }
+ },
+ "3": {
+ start: {
+ line: 11,
+ column: 12
+ },
+ end: {
+ line: 11,
+ column: 37
+ }
+ },
+ "4": {
+ start: {
+ line: 13,
+ column: 8
+ },
+ end: {
+ line: 15,
+ column: 9
+ }
+ },
+ "5": {
+ start: {
+ line: 14,
+ column: 12
+ },
+ end: {
+ line: 14,
+ column: 43
+ }
+ },
+ "6": {
+ start: {
+ line: 16,
+ column: 8
+ },
+ end: {
+ line: 16,
+ column: 47
+ }
+ },
+ "7": {
+ start: {
+ line: 19,
+ column: 10
+ },
+ end: {
+ line: 28,
+ column: 5
+ }
+ },
+ "8": {
+ start: {
+ line: 20,
+ column: 8
+ },
+ end: {
+ line: 26,
+ column: 9
+ }
+ },
+ "9": {
+ start: {
+ line: 25,
+ column: 12
+ },
+ end: {
+ line: 25,
+ column: 33
+ }
+ },
+ "10": {
+ start: {
+ line: 27,
+ column: 8
+ },
+ end: {
+ line: 27,
+ column: 46
+ }
+ },
+ "11": {
+ start: {
+ line: 30,
+ column: 19
+ },
+ end: {
+ line: 65,
+ column: 5
+ }
+ },
+ "12": {
+ start: {
+ line: 31,
+ column: 38
+ },
+ end: {
+ line: 31,
+ column: 44
+ }
+ },
+ "13": {
+ start: {
+ line: 32,
+ column: 8
+ },
+ end: {
+ line: 64,
+ column: 9
+ }
+ },
+ "14": {
+ start: {
+ line: 34,
+ column: 16
+ },
+ end: {
+ line: 34,
+ column: 44
+ }
+ },
+ "15": {
+ start: {
+ line: 35,
+ column: 16
+ },
+ end: {
+ line: 35,
+ column: 22
+ }
+ },
+ "16": {
+ start: {
+ line: 37,
+ column: 16
+ },
+ end: {
+ line: 37,
+ column: 70
+ }
+ },
+ "17": {
+ start: {
+ line: 38,
+ column: 16
+ },
+ end: {
+ line: 41,
+ column: 19
+ }
+ },
+ "18": {
+ start: {
+ line: 42,
+ column: 16
+ },
+ end: {
+ line: 42,
+ column: 54
+ }
+ },
+ "19": {
+ start: {
+ line: 43,
+ column: 16
+ },
+ end: {
+ line: 43,
+ column: 22
+ }
+ },
+ "20": {
+ start: {
+ line: 45,
+ column: 16
+ },
+ end: {
+ line: 45,
+ column: 70
+ }
+ },
+ "21": {
+ start: {
+ line: 46,
+ column: 16
+ },
+ end: {
+ line: 49,
+ column: 19
+ }
+ },
+ "22": {
+ start: {
+ line: 50,
+ column: 16
+ },
+ end: {
+ line: 50,
+ column: 54
+ }
+ },
+ "23": {
+ start: {
+ line: 51,
+ column: 16
+ },
+ end: {
+ line: 51,
+ column: 22
+ }
+ },
+ "24": {
+ start: {
+ line: 53,
+ column: 16
+ },
+ end: {
+ line: 53,
+ column: 70
+ }
+ },
+ "25": {
+ start: {
+ line: 54,
+ column: 16
+ },
+ end: {
+ line: 57,
+ column: 19
+ }
+ },
+ "26": {
+ start: {
+ line: 58,
+ column: 16
+ },
+ end: {
+ line: 58,
+ column: 54
+ }
+ },
+ "27": {
+ start: {
+ line: 59,
+ column: 16
+ },
+ end: {
+ line: 59,
+ column: 22
+ }
+ },
+ "28": {
+ start: {
+ line: 61,
+ column: 16
+ },
+ end: {
+ line: 61,
+ column: 67
+ }
+ },
+ "29": {
+ start: {
+ line: 62,
+ column: 16
+ },
+ end: {
+ line: 62,
+ column: 54
+ }
+ },
+ "30": {
+ start: {
+ line: 63,
+ column: 16
+ },
+ end: {
+ line: 63,
+ column: 22
+ }
+ },
+ "31": {
+ start: {
+ line: 67,
+ column: 16
+ },
+ end: {
+ line: 107,
+ column: 5
+ }
+ },
+ "32": {
+ start: {
+ line: 74,
+ column: 12
+ },
+ end: {
+ line: 74,
+ column: 19
+ }
+ },
+ "33": {
+ start: {
+ line: 76,
+ column: 8
+ },
+ end: {
+ line: 76,
+ column: 26
+ }
+ },
+ "34": {
+ start: {
+ line: 79,
+ column: 18
+ },
+ end: {
+ line: 79,
+ column: 50
+ }
+ },
+ "35": {
+ start: {
+ line: 81,
+ column: 26
+ },
+ end: {
+ line: 81,
+ column: 60
+ }
+ },
+ "36": {
+ start: {
+ line: 84,
+ column: 19
+ },
+ end: {
+ line: 84,
+ column: 30
+ }
+ },
+ "37": {
+ start: {
+ line: 85,
+ column: 8
+ },
+ end: {
+ line: 87,
+ column: 9
+ }
+ },
+ "38": {
+ start: {
+ line: 86,
+ column: 12
+ },
+ end: {
+ line: 86,
+ column: 29
+ }
+ },
+ "39": {
+ start: {
+ line: 89,
+ column: 8
+ },
+ end: {
+ line: 102,
+ column: 9
+ }
+ },
+ "40": {
+ start: {
+ line: 90,
+ column: 12
+ },
+ end: {
+ line: 94,
+ column: 13
+ }
+ },
+ "41": {
+ start: {
+ line: 91,
+ column: 16
+ },
+ end: {
+ line: 91,
+ column: 37
+ }
+ },
+ "42": {
+ start: {
+ line: 93,
+ column: 16
+ },
+ end: {
+ line: 93,
+ column: 34
+ }
+ },
+ "43": {
+ start: {
+ line: 97,
+ column: 12
+ },
+ end: {
+ line: 101,
+ column: 13
+ }
+ },
+ "44": {
+ start: {
+ line: 98,
+ column: 16
+ },
+ end: {
+ line: 98,
+ column: 39
+ }
+ },
+ "45": {
+ start: {
+ line: 100,
+ column: 16
+ },
+ end: {
+ line: 100,
+ column: 40
+ }
+ },
+ "46": {
+ start: {
+ line: 104,
+ column: 8
+ },
+ end: {
+ line: 104,
+ column: 54
+ }
+ },
+ "47": {
+ start: {
+ line: 106,
+ column: 8
+ },
+ end: {
+ line: 106,
+ column: 27
+ }
+ },
+ "48": {
+ start: {
+ line: 109,
+ column: 15
+ },
+ end: {
+ line: 122,
+ column: 5
+ }
+ },
+ "49": {
+ start: {
+ line: 110,
+ column: 21
+ },
+ end: {
+ line: 110,
+ column: 32
+ }
+ },
+ "50": {
+ start: {
+ line: 112,
+ column: 18
+ },
+ end: {
+ line: 112,
+ column: 40
+ }
+ },
+ "51": {
+ start: {
+ line: 113,
+ column: 8
+ },
+ end: {
+ line: 117,
+ column: 9
+ }
+ },
+ "52": {
+ start: {
+ line: 114,
+ column: 12
+ },
+ end: {
+ line: 114,
+ column: 30
+ }
+ },
+ "53": {
+ start: {
+ line: 115,
+ column: 15
+ },
+ end: {
+ line: 117,
+ column: 9
+ }
+ },
+ "54": {
+ start: {
+ line: 116,
+ column: 12
+ },
+ end: {
+ line: 116,
+ column: 32
+ }
+ },
+ "55": {
+ start: {
+ line: 118,
+ column: 8
+ },
+ end: {
+ line: 120,
+ column: 9
+ }
+ },
+ "56": {
+ start: {
+ line: 119,
+ column: 12
+ },
+ end: {
+ line: 119,
+ column: 66
+ }
+ },
+ "57": {
+ start: {
+ line: 121,
+ column: 8
+ },
+ end: {
+ line: 121,
+ column: 22
+ }
+ },
+ "58": {
+ start: {
+ line: 125,
+ column: 23
+ },
+ end: {
+ line: 125,
+ column: 45
+ }
+ },
+ "59": {
+ start: {
+ line: 126,
+ column: 0
+ },
+ end: {
+ line: 126,
+ column: 70
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "(anonymous_0)",
+ decl: {
+ start: {
+ line: 9,
+ column: 10
+ },
+ end: {
+ line: 9,
+ column: 11
+ }
+ },
+ loc: {
+ start: {
+ line: 9,
+ column: 39
+ },
+ end: {
+ line: 17,
+ column: 5
+ }
+ },
+ line: 9
+ },
+ "1": {
+ name: "(anonymous_1)",
+ decl: {
+ start: {
+ line: 19,
+ column: 10
+ },
+ end: {
+ line: 19,
+ column: 11
+ }
+ },
+ loc: {
+ start: {
+ line: 19,
+ column: 47
+ },
+ end: {
+ line: 28,
+ column: 5
+ }
+ },
+ line: 19
+ },
+ "2": {
+ name: "(anonymous_2)",
+ decl: {
+ start: {
+ line: 30,
+ column: 19
+ },
+ end: {
+ line: 30,
+ column: 20
+ }
+ },
+ loc: {
+ start: {
+ line: 30,
+ column: 29
+ },
+ end: {
+ line: 65,
+ column: 5
+ }
+ },
+ line: 30
+ },
+ "3": {
+ name: "(anonymous_3)",
+ decl: {
+ start: {
+ line: 67,
+ column: 16
+ },
+ end: {
+ line: 67,
+ column: 17
+ }
+ },
+ loc: {
+ start: {
+ line: 67,
+ column: 36
+ },
+ end: {
+ line: 107,
+ column: 5
+ }
+ },
+ line: 67
+ },
+ "4": {
+ name: "(anonymous_4)",
+ decl: {
+ start: {
+ line: 109,
+ column: 15
+ },
+ end: {
+ line: 109,
+ column: 16
+ }
+ },
+ loc: {
+ start: {
+ line: 109,
+ column: 40
+ },
+ end: {
+ line: 122,
+ column: 5
+ }
+ },
+ line: 109
+ }
+ },
+ branchMap: {
+ "0": {
+ loc: {
+ start: {
+ line: 10,
+ column: 8
+ },
+ end: {
+ line: 12,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 10,
+ column: 8
+ },
+ end: {
+ line: 12,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 10,
+ column: 8
+ },
+ end: {
+ line: 12,
+ column: 9
+ }
+ }],
+ line: 10
+ },
+ "1": {
+ loc: {
+ start: {
+ line: 13,
+ column: 8
+ },
+ end: {
+ line: 15,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 13,
+ column: 8
+ },
+ end: {
+ line: 15,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 13,
+ column: 8
+ },
+ end: {
+ line: 15,
+ column: 9
+ }
+ }],
+ line: 13
+ },
+ "2": {
+ loc: {
+ start: {
+ line: 20,
+ column: 8
+ },
+ end: {
+ line: 26,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 20,
+ column: 8
+ },
+ end: {
+ line: 26,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 20,
+ column: 8
+ },
+ end: {
+ line: 26,
+ column: 9
+ }
+ }],
+ line: 20
+ },
+ "3": {
+ loc: {
+ start: {
+ line: 21,
+ column: 12
+ },
+ end: {
+ line: 23,
+ column: 55
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 21,
+ column: 12
+ },
+ end: {
+ line: 21,
+ column: 45
+ }
+ }, {
+ start: {
+ line: 22,
+ column: 12
+ },
+ end: {
+ line: 22,
+ column: 51
+ }
+ }, {
+ start: {
+ line: 23,
+ column: 12
+ },
+ end: {
+ line: 23,
+ column: 55
+ }
+ }],
+ line: 21
+ },
+ "4": {
+ loc: {
+ start: {
+ line: 32,
+ column: 8
+ },
+ end: {
+ line: 64,
+ column: 9
+ }
+ },
+ type: "switch",
+ locations: [{
+ start: {
+ line: 33,
+ column: 12
+ },
+ end: {
+ line: 35,
+ column: 22
+ }
+ }, {
+ start: {
+ line: 36,
+ column: 12
+ },
+ end: {
+ line: 43,
+ column: 22
+ }
+ }, {
+ start: {
+ line: 44,
+ column: 12
+ },
+ end: {
+ line: 51,
+ column: 22
+ }
+ }, {
+ start: {
+ line: 52,
+ column: 12
+ },
+ end: {
+ line: 59,
+ column: 22
+ }
+ }, {
+ start: {
+ line: 60,
+ column: 12
+ },
+ end: {
+ line: 63,
+ column: 22
+ }
+ }],
+ line: 32
+ },
+ "5": {
+ loc: {
+ start: {
+ line: 89,
+ column: 8
+ },
+ end: {
+ line: 102,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 89,
+ column: 8
+ },
+ end: {
+ line: 102,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 89,
+ column: 8
+ },
+ end: {
+ line: 102,
+ column: 9
+ }
+ }],
+ line: 89
+ },
+ "6": {
+ loc: {
+ start: {
+ line: 90,
+ column: 12
+ },
+ end: {
+ line: 94,
+ column: 13
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 90,
+ column: 12
+ },
+ end: {
+ line: 94,
+ column: 13
+ }
+ }, {
+ start: {
+ line: 90,
+ column: 12
+ },
+ end: {
+ line: 94,
+ column: 13
+ }
+ }],
+ line: 90
+ },
+ "7": {
+ loc: {
+ start: {
+ line: 97,
+ column: 12
+ },
+ end: {
+ line: 101,
+ column: 13
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 97,
+ column: 12
+ },
+ end: {
+ line: 101,
+ column: 13
+ }
+ }, {
+ start: {
+ line: 97,
+ column: 12
+ },
+ end: {
+ line: 101,
+ column: 13
+ }
+ }],
+ line: 97
+ },
+ "8": {
+ loc: {
+ start: {
+ line: 113,
+ column: 8
+ },
+ end: {
+ line: 117,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 113,
+ column: 8
+ },
+ end: {
+ line: 117,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 113,
+ column: 8
+ },
+ end: {
+ line: 117,
+ column: 9
+ }
+ }],
+ line: 113
+ },
+ "9": {
+ loc: {
+ start: {
+ line: 115,
+ column: 15
+ },
+ end: {
+ line: 117,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 115,
+ column: 15
+ },
+ end: {
+ line: 117,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 115,
+ column: 15
+ },
+ end: {
+ line: 117,
+ column: 9
+ }
+ }],
+ line: 115
+ },
+ "10": {
+ loc: {
+ start: {
+ line: 118,
+ column: 8
+ },
+ end: {
+ line: 120,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 118,
+ column: 8
+ },
+ end: {
+ line: 120,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 118,
+ column: 8
+ },
+ end: {
+ line: 120,
+ column: 9
+ }
+ }],
+ line: 118
+ }
+ },
+ s: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0,
+ "7": 0,
+ "8": 0,
+ "9": 0,
+ "10": 0,
+ "11": 0,
+ "12": 0,
+ "13": 0,
+ "14": 0,
+ "15": 0,
+ "16": 0,
+ "17": 0,
+ "18": 0,
+ "19": 0,
+ "20": 0,
+ "21": 0,
+ "22": 0,
+ "23": 0,
+ "24": 0,
+ "25": 0,
+ "26": 0,
+ "27": 0,
+ "28": 0,
+ "29": 0,
+ "30": 0,
+ "31": 0,
+ "32": 0,
+ "33": 0,
+ "34": 0,
+ "35": 0,
+ "36": 0,
+ "37": 0,
+ "38": 0,
+ "39": 0,
+ "40": 0,
+ "41": 0,
+ "42": 0,
+ "43": 0,
+ "44": 0,
+ "45": 0,
+ "46": 0,
+ "47": 0,
+ "48": 0,
+ "49": 0,
+ "50": 0,
+ "51": 0,
+ "52": 0,
+ "53": 0,
+ "54": 0,
+ "55": 0,
+ "56": 0,
+ "57": 0,
+ "58": 0,
+ "59": 0
+ },
+ f: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0
+ },
+ b: {
+ "0": [0, 0],
+ "1": [0, 0],
+ "2": [0, 0],
+ "3": [0, 0, 0],
+ "4": [0, 0, 0, 0, 0],
+ "5": [0, 0],
+ "6": [0, 0],
+ "7": [0, 0],
+ "8": [0, 0],
+ "9": [0, 0],
+ "10": [0, 0]
+ },
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "65c9acabd36261c1c729ad70028e6d27ce20e981"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_27pkmm3h2i = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
-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; };
+cov_27pkmm3h2i();
-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__(1);
+ //store persistent display attributes for objects and arrays
-var _react2 = _interopRequireDefault(_react);
+var ObjectAttributes_ObjectAttributes = /*#__PURE__*/function (_EventEmitter) {
+ _inherits(ObjectAttributes, _EventEmitter);
-var _DataTypeLabel = __webpack_require__(9);
+ var _super = _createSuper(ObjectAttributes);
-var _DataTypeLabel2 = _interopRequireDefault(_DataTypeLabel);
+ function ObjectAttributes() {
+ var _this;
-var _util = __webpack_require__(5);
+ _classCallCheck(this, ObjectAttributes);
-var _getStyle = __webpack_require__(2);
+ for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
+ args[_key] = arguments[_key];
+ }
-var _getStyle2 = _interopRequireDefault(_getStyle);
+ _this = _super.call.apply(_super, [this].concat(args));
+ _this.objects = (cov_27pkmm3h2i().s[0]++, {});
+ _this.set = (cov_27pkmm3h2i().s[1]++, function (rjvId, name, key, value) {
+ cov_27pkmm3h2i().f[0]++;
+ cov_27pkmm3h2i().s[2]++;
-var _ObjectAttributes = __webpack_require__(16);
+ if (_this.objects[rjvId] === undefined) {
+ cov_27pkmm3h2i().b[0][0]++;
+ cov_27pkmm3h2i().s[3]++;
+ _this.objects[rjvId] = {};
+ } else {
+ cov_27pkmm3h2i().b[0][1]++;
+ }
-var _ObjectAttributes2 = _interopRequireDefault(_ObjectAttributes);
+ cov_27pkmm3h2i().s[4]++;
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+ if (_this.objects[rjvId][name] === undefined) {
+ cov_27pkmm3h2i().b[1][0]++;
+ cov_27pkmm3h2i().s[5]++;
+ _this.objects[rjvId][name] = {};
+ } else {
+ cov_27pkmm3h2i().b[1][1]++;
+ }
-function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
+ cov_27pkmm3h2i().s[6]++;
+ _this.objects[rjvId][name][key] = value;
+ });
+ _this.get = (cov_27pkmm3h2i().s[7]++, function (rjvId, name, key, default_value) {
+ cov_27pkmm3h2i().f[1]++;
+ cov_27pkmm3h2i().s[8]++;
+
+ if ((cov_27pkmm3h2i().b[3][0]++, _this.objects[rjvId] === undefined) || (cov_27pkmm3h2i().b[3][1]++, _this.objects[rjvId][name] === undefined) || (cov_27pkmm3h2i().b[3][2]++, _this.objects[rjvId][name][key] == undefined)) {
+ cov_27pkmm3h2i().b[2][0]++;
+ cov_27pkmm3h2i().s[9]++;
+ return default_value;
+ } else {
+ cov_27pkmm3h2i().b[2][1]++;
+ }
-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; }
+ cov_27pkmm3h2i().s[10]++;
+ return _this.objects[rjvId][name][key];
+ });
+ _this.handleAction = (cov_27pkmm3h2i().s[11]++, function (action) {
+ cov_27pkmm3h2i().f[2]++;
-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 _ref = (cov_27pkmm3h2i().s[12]++, action),
+ rjvId = _ref.rjvId,
+ data = _ref.data,
+ name = _ref.name;
-//theme
+ cov_27pkmm3h2i().s[13]++;
+ switch (name) {
+ case 'RESET':
+ cov_27pkmm3h2i().b[4][0]++;
+ cov_27pkmm3h2i().s[14]++;
-//attribute store for storing collapsed state
+ _this.emit('reset-' + rjvId);
+ cov_27pkmm3h2i().s[15]++;
+ break;
-var _class = function (_React$PureComponent) {
- _inherits(_class, _React$PureComponent);
+ case 'VARIABLE_UPDATED':
+ cov_27pkmm3h2i().b[4][1]++;
+ cov_27pkmm3h2i().s[16]++;
+ action.data.updated_src = _this.updateSrc(rjvId, data);
+ cov_27pkmm3h2i().s[17]++;
- function _class(props) {
- _classCallCheck(this, _class);
+ _this.set(rjvId, 'action', 'variable-update', _objectSpread2(_objectSpread2({}, data), {}, {
+ type: 'variable-edited'
+ }));
- var _this = _possibleConstructorReturn(this, (_class.__proto__ || Object.getPrototypeOf(_class)).call(this, props));
+ cov_27pkmm3h2i().s[18]++;
- _this.toggleCollapsed = function () {
- _this.setState({
- collapsed: !_this.state.collapsed
- }, function () {
- _ObjectAttributes2.default.set(_this.props.rjvId, _this.props.namespace, 'collapsed', _this.state.collapsed);
- });
- };
+ _this.emit('variable-update-' + rjvId);
- _this.state = {
- collapsed: _ObjectAttributes2.default.get(props.rjvId, props.namespace, 'collapsed', true)
- };
- return _this;
- }
-
- _createClass(_class, [{
- key: 'render',
- value: function render() {
- var type_name = 'string';
- var collapsed = this.state.collapsed;
- var props = this.props;
- var collapseStringsAfterLength = props.collapseStringsAfterLength,
- theme = props.theme;
- var value = props.value;
-
- var collapsible = (0, _util.toType)(collapseStringsAfterLength) === 'integer';
- var style = { style: { cursor: 'default' } };
-
- if (collapsible && value.length > collapseStringsAfterLength) {
- style.style.cursor = 'pointer';
- if (this.state.collapsed) {
- value = _react2.default.createElement(
- 'span',
- null,
- value.substring(0, collapseStringsAfterLength),
- _react2.default.createElement(
- 'span',
- (0, _getStyle2.default)(theme, 'ellipsis'),
- ' ...'
- )
- );
- }
- }
+ cov_27pkmm3h2i().s[19]++;
+ break;
- return _react2.default.createElement(
- 'div',
- (0, _getStyle2.default)(theme, 'string'),
- _react2.default.createElement(_DataTypeLabel2.default, _extends({ type_name: type_name }, props)),
- _react2.default.createElement(
- 'span',
- _extends({
- className: 'string-value'
- }, style, {
- onClick: this.toggleCollapsed
- }),
- '"',
- value,
- '"'
- )
- );
- }
- }]);
+ case 'VARIABLE_REMOVED':
+ cov_27pkmm3h2i().b[4][2]++;
+ cov_27pkmm3h2i().s[20]++;
+ action.data.updated_src = _this.updateSrc(rjvId, data);
+ cov_27pkmm3h2i().s[21]++;
- return _class;
-}(_react2.default.PureComponent);
+ _this.set(rjvId, 'action', 'variable-update', _objectSpread2(_objectSpread2({}, data), {}, {
+ type: 'variable-removed'
+ }));
-exports.default = _class;
+ cov_27pkmm3h2i().s[22]++;
-/***/ }),
-/* 182 */
-/***/ (function(module, exports, __webpack_require__) {
+ _this.emit('variable-update-' + rjvId);
-"use strict";
+ cov_27pkmm3h2i().s[23]++;
+ break;
+ case 'VARIABLE_ADDED':
+ cov_27pkmm3h2i().b[4][3]++;
+ cov_27pkmm3h2i().s[24]++;
+ action.data.updated_src = _this.updateSrc(rjvId, data);
+ cov_27pkmm3h2i().s[25]++;
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
+ _this.set(rjvId, 'action', 'variable-update', _objectSpread2(_objectSpread2({}, data), {}, {
+ type: 'variable-added'
+ }));
-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; }; }();
+ cov_27pkmm3h2i().s[26]++;
-var _react = __webpack_require__(1);
+ _this.emit('variable-update-' + rjvId);
-var _react2 = _interopRequireDefault(_react);
+ cov_27pkmm3h2i().s[27]++;
+ break;
-var _getStyle = __webpack_require__(2);
+ case 'ADD_VARIABLE_KEY_REQUEST':
+ cov_27pkmm3h2i().b[4][4]++;
+ cov_27pkmm3h2i().s[28]++;
-var _getStyle2 = _interopRequireDefault(_getStyle);
+ _this.set(rjvId, 'action', 'new-key-request', data);
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+ cov_27pkmm3h2i().s[29]++;
-function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
+ _this.emit('add-key-request-' + rjvId);
-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; }
+ cov_27pkmm3h2i().s[30]++;
+ break;
+ }
+ });
+ _this.updateSrc = (cov_27pkmm3h2i().s[31]++, function (rjvId, request) {
+ cov_27pkmm3h2i().f[3]++;
-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 _ref2 = (cov_27pkmm3h2i().s[32]++, request),
+ name = _ref2.name,
+ namespace = _ref2.namespace,
+ new_value = _ref2.new_value,
+ existing_value = _ref2.existing_value,
+ variable_removed = _ref2.variable_removed;
-//theme
+ cov_27pkmm3h2i().s[33]++;
+ namespace.shift(); //deepy copy src
+ var src = (cov_27pkmm3h2i().s[34]++, _this.get(rjvId, 'global', 'src')); //deep copy of src variable
-var _class = function (_React$PureComponent) {
- _inherits(_class, _React$PureComponent);
+ var updated_src = (cov_27pkmm3h2i().s[35]++, _this.deepCopy(src, _toConsumableArray(namespace))); //point at current index
- function _class() {
- _classCallCheck(this, _class);
+ var walk = (cov_27pkmm3h2i().s[36]++, updated_src);
+ cov_27pkmm3h2i().s[37]++;
- return _possibleConstructorReturn(this, (_class.__proto__ || Object.getPrototypeOf(_class)).apply(this, arguments));
- }
+ var _iterator = _createForOfIteratorHelper(namespace),
+ _step;
- _createClass(_class, [{
- key: 'render',
- value: function render() {
- return _react2.default.createElement(
- 'div',
- (0, _getStyle2.default)(this.props.theme, 'undefined'),
- 'undefined'
- );
+ try {
+ for (_iterator.s(); !(_step = _iterator.n()).done;) {
+ var idx = _step.value;
+ cov_27pkmm3h2i().s[38]++;
+ walk = walk[idx];
}
- }]);
-
- return _class;
-}(_react2.default.PureComponent);
-
-exports.default = _class;
-
-/***/ }),
-/* 183 */
-/***/ (function(module, exports, __webpack_require__) {
+ } catch (err) {
+ _iterator.e(err);
+ } finally {
+ _iterator.f();
+ }
-"use strict";
+ cov_27pkmm3h2i().s[39]++;
+ if (variable_removed) {
+ cov_27pkmm3h2i().b[5][0]++;
+ cov_27pkmm3h2i().s[40]++;
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
-
-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; };
+ if (toType(walk) == 'array') {
+ cov_27pkmm3h2i().b[6][0]++;
+ cov_27pkmm3h2i().s[41]++;
+ walk.splice(name, 1);
+ } else {
+ cov_27pkmm3h2i().b[6][1]++;
+ cov_27pkmm3h2i().s[42]++;
+ delete walk[name];
+ }
+ } else {
+ cov_27pkmm3h2i().b[5][1]++;
+ cov_27pkmm3h2i().s[43]++;
+
+ //update copied variable at specified namespace
+ if (name !== null) {
+ cov_27pkmm3h2i().b[7][0]++;
+ cov_27pkmm3h2i().s[44]++;
+ walk[name] = new_value;
+ } else {
+ cov_27pkmm3h2i().b[7][1]++;
+ cov_27pkmm3h2i().s[45]++;
+ updated_src = new_value;
+ }
+ }
-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; }; }();
+ cov_27pkmm3h2i().s[46]++;
-var _react = __webpack_require__(1);
+ _this.set(rjvId, 'global', 'src', updated_src);
-var _react2 = _interopRequireDefault(_react);
+ cov_27pkmm3h2i().s[47]++;
+ return updated_src;
+ });
+ _this.deepCopy = (cov_27pkmm3h2i().s[48]++, function (src, copy_namespace) {
+ cov_27pkmm3h2i().f[4]++;
+ var type = (cov_27pkmm3h2i().s[49]++, toType(src));
+ var result;
+ var idx = (cov_27pkmm3h2i().s[50]++, copy_namespace.shift());
+ cov_27pkmm3h2i().s[51]++;
+
+ if (type == 'array') {
+ cov_27pkmm3h2i().b[8][0]++;
+ cov_27pkmm3h2i().s[52]++;
+ result = _toConsumableArray(src);
+ } else {
+ cov_27pkmm3h2i().b[8][1]++;
+ cov_27pkmm3h2i().s[53]++;
-var _reactTextareaAutosize = __webpack_require__(184);
+ if (type == 'object') {
+ cov_27pkmm3h2i().b[9][0]++;
+ cov_27pkmm3h2i().s[54]++;
+ result = _objectSpread2({}, src);
+ } else {
+ cov_27pkmm3h2i().b[9][1]++;
+ }
+ }
-var _reactTextareaAutosize2 = _interopRequireDefault(_reactTextareaAutosize);
+ cov_27pkmm3h2i().s[55]++;
-var _util = __webpack_require__(5);
+ if (idx !== undefined) {
+ cov_27pkmm3h2i().b[10][0]++;
+ cov_27pkmm3h2i().s[56]++;
+ result[idx] = _this.deepCopy(src[idx], copy_namespace);
+ } else {
+ cov_27pkmm3h2i().b[10][1]++;
+ }
-var _dispatcher = __webpack_require__(17);
+ cov_27pkmm3h2i().s[57]++;
+ return result;
+ });
+ return _this;
+ }
-var _dispatcher2 = _interopRequireDefault(_dispatcher);
+ return ObjectAttributes;
+}(events["EventEmitter"]);
-var _parseInput = __webpack_require__(185);
+var attributeStore = (cov_27pkmm3h2i().s[58]++, new ObjectAttributes_ObjectAttributes());
+cov_27pkmm3h2i().s[59]++;
+helpers_dispatcher.register(attributeStore.handleAction.bind(attributeStore));
+/* harmony default export */ var stores_ObjectAttributes = (attributeStore);
+// CONCATENATED MODULE: ./src/js/components/DataTypes/Function.js
-var _parseInput2 = _interopRequireDefault(_parseInput);
-var _stringifyVariable = __webpack_require__(59);
-var _stringifyVariable2 = _interopRequireDefault(_stringifyVariable);
-var _CopyToClipboard = __webpack_require__(60);
-var _CopyToClipboard2 = _interopRequireDefault(_CopyToClipboard);
-var _DataTypes = __webpack_require__(47);
+function cov_1xf43byyz2() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/components/DataTypes/Function.js";
+ var hash = "2baf52c21fcf19dbf6829c5e8335dbc2f56fe3d8";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/components/DataTypes/Function.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 12,
+ column: 8
+ },
+ end: {
+ line: 12,
+ column: 21
+ }
+ },
+ "1": {
+ start: {
+ line: 13,
+ column: 8
+ },
+ end: {
+ line: 20,
+ column: 10
+ }
+ },
+ "2": {
+ start: {
+ line: 23,
+ column: 22
+ },
+ end: {
+ line: 38,
+ column: 5
+ }
+ },
+ "3": {
+ start: {
+ line: 24,
+ column: 8
+ },
+ end: {
+ line: 37,
+ column: 10
+ }
+ },
+ "4": {
+ start: {
+ line: 30,
+ column: 16
+ },
+ end: {
+ line: 35,
+ column: 18
+ }
+ },
+ "5": {
+ start: {
+ line: 41,
+ column: 26
+ },
+ end: {
+ line: 41,
+ column: 36
+ }
+ },
+ "6": {
+ start: {
+ line: 42,
+ column: 26
+ },
+ end: {
+ line: 42,
+ column: 30
+ }
+ },
+ "7": {
+ start: {
+ line: 43,
+ column: 30
+ },
+ end: {
+ line: 43,
+ column: 40
+ }
+ },
+ "8": {
+ start: {
+ line: 45,
+ column: 8
+ },
+ end: {
+ line: 56,
+ column: 10
+ }
+ },
+ "9": {
+ start: {
+ line: 59,
+ column: 25
+ },
+ end: {
+ line: 81,
+ column: 5
+ }
+ },
+ "10": {
+ start: {
+ line: 60,
+ column: 26
+ },
+ end: {
+ line: 60,
+ column: 30
+ }
+ },
+ "11": {
+ start: {
+ line: 61,
+ column: 8
+ },
+ end: {
+ line: 80,
+ column: 9
+ }
+ },
+ "12": {
+ start: {
+ line: 62,
+ column: 12
+ },
+ end: {
+ line: 77,
+ column: 14
+ }
+ },
+ "13": {
+ start: {
+ line: 79,
+ column: 12
+ },
+ end: {
+ line: 79,
+ column: 60
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "(anonymous_0)",
+ decl: {
+ start: {
+ line: 11,
+ column: 4
+ },
+ end: {
+ line: 11,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 11,
+ column: 23
+ },
+ end: {
+ line: 21,
+ column: 5
+ }
+ },
+ line: 11
+ },
+ "1": {
+ name: "(anonymous_1)",
+ decl: {
+ start: {
+ line: 23,
+ column: 22
+ },
+ end: {
+ line: 23,
+ column: 23
+ }
+ },
+ loc: {
+ start: {
+ line: 23,
+ column: 28
+ },
+ end: {
+ line: 38,
+ column: 5
+ }
+ },
+ line: 23
+ },
+ "2": {
+ name: "(anonymous_2)",
+ decl: {
+ start: {
+ line: 28,
+ column: 12
+ },
+ end: {
+ line: 28,
+ column: 13
+ }
+ },
+ loc: {
+ start: {
+ line: 28,
+ column: 18
+ },
+ end: {
+ line: 36,
+ column: 13
+ }
+ },
+ line: 28
+ },
+ "3": {
+ name: "(anonymous_3)",
+ decl: {
+ start: {
+ line: 40,
+ column: 4
+ },
+ end: {
+ line: 40,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 40,
+ column: 13
+ },
+ end: {
+ line: 57,
+ column: 5
+ }
+ },
+ line: 40
+ },
+ "4": {
+ name: "(anonymous_4)",
+ decl: {
+ start: {
+ line: 59,
+ column: 25
+ },
+ end: {
+ line: 59,
+ column: 26
+ }
+ },
+ loc: {
+ start: {
+ line: 59,
+ column: 38
+ },
+ end: {
+ line: 81,
+ column: 5
+ }
+ },
+ line: 59
+ }
+ },
+ branchMap: {
+ "0": {
+ loc: {
+ start: {
+ line: 61,
+ column: 8
+ },
+ end: {
+ line: 80,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 61,
+ column: 8
+ },
+ end: {
+ line: 80,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 61,
+ column: 8
+ },
+ end: {
+ line: 80,
+ column: 9
+ }
+ }],
+ line: 61
+ }
+ },
+ s: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0,
+ "7": 0,
+ "8": 0,
+ "9": 0,
+ "10": 0,
+ "11": 0,
+ "12": 0,
+ "13": 0
+ },
+ f: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0
+ },
+ b: {
+ "0": [0, 0]
+ },
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "2baf52c21fcf19dbf6829c5e8335dbc2f56fe3d8"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
-var _icons = __webpack_require__(18);
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
-var _getStyle = __webpack_require__(2);
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_1xf43byyz2 = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
-var _getStyle2 = _interopRequireDefault(_getStyle);
+cov_1xf43byyz2();
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+ //theme
-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); } }
+ //attribute store for storing collapsed state
-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 Function_default = /*#__PURE__*/function (_React$PureComponent) {
+ _inherits(_default, _React$PureComponent);
-//data type components
+ var _super = _createSuper(_default);
+ function _default(_props) {
+ var _this;
-//clibboard icon
+ _classCallCheck(this, _default);
+
+ cov_1xf43byyz2().f[0]++;
+ cov_1xf43byyz2().s[0]++;
+ _this = _super.call(this, _props);
+ _this.toggleCollapsed = (cov_1xf43byyz2().s[2]++, function () {
+ cov_1xf43byyz2().f[1]++;
+ cov_1xf43byyz2().s[3]++;
+
+ _this.setState({
+ collapsed: !_this.state.collapsed
+ }, function () {
+ cov_1xf43byyz2().f[2]++;
+ cov_1xf43byyz2().s[4]++;
+ // will be called after setState takes effect.
+ stores_ObjectAttributes.set(_this.props.rjvId, _this.props.namespace, 'collapsed', _this.state.collapsed);
+ });
+ });
+ _this.getFunctionDisplay = (cov_1xf43byyz2().s[9]++, function (collapsed) {
+ cov_1xf43byyz2().f[4]++;
+ var _ref = (cov_1xf43byyz2().s[10]++, _assertThisInitialized(_this)),
+ props = _ref.props;
-//theme
+ cov_1xf43byyz2().s[11]++;
+ if (collapsed) {
+ cov_1xf43byyz2().b[0][0]++;
+ cov_1xf43byyz2().s[12]++;
+ return /*#__PURE__*/external_React_default.a.createElement("span", null, _this.props.value.toString().slice(9, -1).replace(/\{[\s\S]+/, ''), /*#__PURE__*/external_React_default.a.createElement("span", {
+ className: "function-collapsed",
+ style: {
+ fontWeight: 'bold'
+ }
+ }, /*#__PURE__*/external_React_default.a.createElement("span", null, '{'), /*#__PURE__*/external_React_default.a.createElement("span", getStyle_style(props.theme, 'ellipsis'), "..."), /*#__PURE__*/external_React_default.a.createElement("span", null, '}')));
+ } else {
+ cov_1xf43byyz2().b[0][1]++;
+ cov_1xf43byyz2().s[13]++;
+ return _this.props.value.toString().slice(9, -1);
+ }
+ });
+ cov_1xf43byyz2().s[1]++;
+ _this.state = {
+ collapsed: stores_ObjectAttributes.get(_props.rjvId, _props.namespace, 'collapsed', true)
+ };
+ return _this;
+ }
-var VariableEditor = function (_React$PureComponent) {
- _inherits(VariableEditor, _React$PureComponent);
+ _createClass(_default, [{
+ key: "render",
+ value: function render() {
+ cov_1xf43byyz2().f[3]++;
+ var type_name = (cov_1xf43byyz2().s[5]++, 'function');
+
+ var _ref2 = (cov_1xf43byyz2().s[6]++, this),
+ props = _ref2.props;
+
+ var _ref3 = (cov_1xf43byyz2().s[7]++, this.state),
+ collapsed = _ref3.collapsed;
+
+ cov_1xf43byyz2().s[8]++;
+ return /*#__PURE__*/external_React_default.a.createElement("div", getStyle_style(props.theme, 'function'), /*#__PURE__*/external_React_default.a.createElement(DataTypeLabel_default, Object.assign({
+ type_name: type_name
+ }, props)), /*#__PURE__*/external_React_default.a.createElement("span", Object.assign({}, getStyle_style(props.theme, 'function-value'), {
+ className: "rjv-function-container",
+ onClick: this.toggleCollapsed
+ }), this.getFunctionDisplay(collapsed)));
+ }
+ }]);
- function VariableEditor(props) {
- _classCallCheck(this, VariableEditor);
+ return _default;
+}((external_React_default.a.PureComponent));
- var _this = _possibleConstructorReturn(this, (VariableEditor.__proto__ || Object.getPrototypeOf(VariableEditor)).call(this, props));
- _initialiseProps.call(_this);
+// CONCATENATED MODULE: ./src/js/components/DataTypes/Nan.js
- _this.state = {
- editMode: false,
- editValue: '',
- hovered: false,
- renameKey: false,
- parsedInput: {
- type: false,
- value: null
- }
- };
- return _this;
- }
-
- _createClass(VariableEditor, [{
- key: 'render',
- value: function render() {
- var _this2 = this;
-
- var _props = this.props,
- variable = _props.variable,
- src = _props.src,
- singleIndent = _props.singleIndent,
- type = _props.type,
- theme = _props.theme,
- namespace = _props.namespace,
- indentWidth = _props.indentWidth,
- enableClipboard = _props.enableClipboard,
- onEdit = _props.onEdit,
- onDelete = _props.onDelete,
- onSelect = _props.onSelect,
- rjvId = _props.rjvId;
- var editMode = this.state.editMode;
-
-
- return _react2.default.createElement(
- 'div',
- _extends({}, (0, _getStyle2.default)(theme, 'objectKeyVal', {
- paddingLeft: indentWidth * singleIndent
- }), {
- onMouseEnter: function onMouseEnter() {
- return _this2.setState(_extends({}, _this2.state, { hovered: true }));
- },
- onMouseLeave: function onMouseLeave() {
- return _this2.setState(_extends({}, _this2.state, { hovered: false }));
- },
- className: 'variable-row',
- key: variable.name
- }),
- type == 'array' ? _react2.default.createElement(
- 'span',
- _extends({}, (0, _getStyle2.default)(theme, 'array-key'), {
- key: variable.name + '_' + namespace
- }),
- variable.name,
- _react2.default.createElement(
- 'div',
- (0, _getStyle2.default)(theme, 'colon'),
- ':'
- )
- ) : _react2.default.createElement(
- 'span',
- null,
- _react2.default.createElement(
- 'span',
- _extends({}, (0, _getStyle2.default)(theme, 'object-name'), {
- className: 'object-key',
- key: variable.name + '_' + namespace
- }),
- _react2.default.createElement(
- 'span',
- { style: { verticalAlign: 'top' } },
- '"'
- ),
- _react2.default.createElement(
- 'span',
- { style: { display: 'inline-block' } },
- variable.name
- ),
- _react2.default.createElement(
- 'span',
- { style: { verticalAlign: 'top' } },
- '"'
- )
- ),
- _react2.default.createElement(
- 'span',
- (0, _getStyle2.default)(theme, 'colon'),
- ':'
- )
- ),
- _react2.default.createElement(
- 'div',
- _extends({
- className: 'variable-value',
- onClick: onSelect === false && onEdit === false ? null : function (e) {
- var location = [].concat(_toConsumableArray(namespace));
- if ((e.ctrlKey || e.metaKey) && onEdit !== false) {
- _this2.prepopInput(variable);
- } else if (onSelect !== false) {
- location.shift();
- onSelect(_extends({}, variable, {
- namespace: location
- }));
- }
- }
- }, (0, _getStyle2.default)(theme, 'variableValue', {
- cursor: onSelect === false ? 'default' : 'pointer'
- })),
- this.getValue(variable, editMode)
- ),
- enableClipboard ? _react2.default.createElement(_CopyToClipboard2.default, _extends({
- rowHovered: this.state.hovered,
- hidden: editMode,
- src: variable.value,
- clickCallback: enableClipboard
- }, { theme: theme, namespace: namespace })) : null,
- onEdit !== false && editMode == false ? this.getEditIcon() : null,
- onDelete !== false && editMode == false ? this.getRemoveIcon() : null
- );
- }
- }]);
-
- return VariableEditor;
-}(_react2.default.PureComponent);
-
-//export component
-
-
-var _initialiseProps = function _initialiseProps() {
- var _this3 = this;
- this.getEditIcon = function () {
- var _props2 = _this3.props,
- variable = _props2.variable,
- theme = _props2.theme;
-
-
- return _react2.default.createElement(
- 'div',
- { className: 'click-to-edit',
- style: {
- verticalAlign: 'top',
- display: _this3.state.hovered ? "inline-block" : "none"
- } },
- _react2.default.createElement(_icons.Edit, _extends({
- className: 'click-to-edit-icon'
- }, (0, _getStyle2.default)(theme, 'editVarIcon'), {
- onClick: function onClick() {
- _this3.prepopInput(variable);
- }
- }))
- );
- };
- this.prepopInput = function (variable) {
- if (_this3.props.onEdit !== false) {
- var stringifiedValue = (0, _stringifyVariable2.default)(variable.value);
- var detected = (0, _parseInput2.default)(stringifiedValue);
- _this3.setState({
- editMode: true,
- editValue: stringifiedValue,
- parsedInput: {
- type: detected.type,
- value: detected.value
- }
- });
- }
- };
- this.getRemoveIcon = function () {
- var _props3 = _this3.props,
- variable = _props3.variable,
- namespace = _props3.namespace,
- theme = _props3.theme,
- rjvId = _props3.rjvId;
-
-
- return _react2.default.createElement(
- 'div',
- { className: 'click-to-remove',
- style: {
- verticalAlign: 'top',
- display: _this3.state.hovered ? "inline-block" : "none"
- } },
- _react2.default.createElement(_icons.RemoveCircle, _extends({
- className: 'click-to-remove-icon'
- }, (0, _getStyle2.default)(theme, 'removeVarIcon'), {
- onClick: function onClick() {
- _dispatcher2.default.dispatch({
- name: 'VARIABLE_REMOVED',
- rjvId: rjvId,
- data: {
- name: variable.name,
- namespace: namespace,
- existing_value: variable.value,
- variable_removed: true
- }
- });
- }
- }))
- );
- };
- this.getValue = function (variable, editMode) {
- var type = editMode ? false : variable.type;
- var props = _this3.props;
-
- switch (type) {
- case false:
- return _this3.getEditInput();
- case 'string':
- return _react2.default.createElement(_DataTypes.JsonString, _extends({ value: variable.value }, props));
- case 'integer':
- return _react2.default.createElement(_DataTypes.JsonInteger, _extends({ value: variable.value }, props));
- case 'float':
- return _react2.default.createElement(_DataTypes.JsonFloat, _extends({ value: variable.value }, props));
- case 'boolean':
- return _react2.default.createElement(_DataTypes.JsonBoolean, _extends({ value: variable.value }, props));
- case 'function':
- return _react2.default.createElement(_DataTypes.JsonFunction, _extends({ value: variable.value }, props));
- case 'null':
- return _react2.default.createElement(_DataTypes.JsonNull, props);
- case 'nan':
- return _react2.default.createElement(_DataTypes.JsonNan, props);
- case 'undefined':
- return _react2.default.createElement(_DataTypes.JsonUndefined, props);
- case 'date':
- return _react2.default.createElement(_DataTypes.JsonDate, _extends({ value: variable.value }, props));
- case 'regexp':
- return _react2.default.createElement(_DataTypes.JsonRegexp, _extends({ value: variable.value }, props));
- default:
- // catch-all for types that weren't anticipated
- return _react2.default.createElement(
- 'div',
- { className: 'object-value' },
- JSON.stringify(variable.value)
- );
+function cov_vufgfj1qd() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/components/DataTypes/Nan.js";
+ var hash = "c2b7431863b1e94a7fdd19963ebc33e8bc9f374a";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/components/DataTypes/Nan.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 8,
+ column: 8
+ },
+ end: {
+ line: 8,
+ column: 66
}
- };
-
- this.getEditInput = function () {
- var theme = _this3.props.theme;
- var editValue = _this3.state.editValue;
-
-
- return _react2.default.createElement(
- 'div',
- null,
- _react2.default.createElement(_reactTextareaAutosize2.default, _extends({
- type: 'text',
- inputRef: function inputRef(input) {
- return input && input.focus();
- },
- value: editValue,
- className: 'variable-editor',
- onChange: function onChange(event) {
- var value = event.target.value;
- var detected = (0, _parseInput2.default)(value);
- _this3.setState({
- editValue: value,
- parsedInput: {
- type: detected.type,
- value: detected.value
- }
- });
- },
- onKeyDown: function onKeyDown(e) {
- switch (e.key) {
- case 'Escape':
- {
- _this3.setState({
- editMode: false,
- editValue: ''
- });
- break;
- }
- case 'Enter':
- {
- if (e.ctrlKey || e.metaKey) {
- _this3.submitEdit(true);
- }
- break;
- }
- }
- e.stopPropagation();
- },
- placeholder: 'update this value'
- }, (0, _getStyle2.default)(theme, 'edit-input'))),
- _react2.default.createElement(
- 'div',
- (0, _getStyle2.default)(theme, 'edit-icon-container'),
- _react2.default.createElement(_icons.RemoveCircle, _extends({
- className: 'edit-cancel'
- }, (0, _getStyle2.default)(theme, 'cancel-icon'), {
- onClick: function onClick() {
- _this3.setState({ editMode: false, editValue: '' });
- }
- })),
- _react2.default.createElement(_icons.CheckCircle, _extends({
- className: 'edit-check string-value'
- }, (0, _getStyle2.default)(theme, 'check-icon'), {
- onClick: function onClick() {
- _this3.submitEdit();
- }
- })),
- _react2.default.createElement(
- 'div',
- null,
- _this3.showDetected()
- )
- )
- );
- };
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "(anonymous_0)",
+ decl: {
+ start: {
+ line: 7,
+ column: 4
+ },
+ end: {
+ line: 7,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 7,
+ column: 13
+ },
+ end: {
+ line: 9,
+ column: 5
+ }
+ },
+ line: 7
+ }
+ },
+ branchMap: {},
+ s: {
+ "0": 0
+ },
+ f: {
+ "0": 0
+ },
+ b: {},
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "c2b7431863b1e94a7fdd19963ebc33e8bc9f374a"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
- this.submitEdit = function (submit_detected) {
- var _props4 = _this3.props,
- variable = _props4.variable,
- namespace = _props4.namespace,
- rjvId = _props4.rjvId;
- var _state = _this3.state,
- editValue = _state.editValue,
- parsedInput = _state.parsedInput;
-
- var new_value = editValue;
- if (submit_detected && parsedInput.type) {
- new_value = parsedInput.value;
- }
- _this3.setState({
- editMode: false
- });
- _dispatcher2.default.dispatch({
- name: 'VARIABLE_UPDATED',
- rjvId: rjvId,
- data: {
- name: variable.name,
- namespace: namespace,
- existing_value: variable.value,
- new_value: new_value,
- variable_removed: false
- }
- });
- };
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
- this.showDetected = function () {
- var _props5 = _this3.props,
- theme = _props5.theme,
- variable = _props5.variable,
- namespace = _props5.namespace,
- rjvId = _props5.rjvId;
- var _state$parsedInput = _this3.state.parsedInput,
- type = _state$parsedInput.type,
- value = _state$parsedInput.value;
-
- var detected = _this3.getDetectedInput();
- if (detected) {
- return _react2.default.createElement(
- 'div',
- null,
- _react2.default.createElement(
- 'div',
- (0, _getStyle2.default)(theme, 'detected-row'),
- detected,
- _react2.default.createElement(_icons.CheckCircle, {
- className: 'edit-check detected',
- style: _extends({
- verticalAlign: 'top',
- paddingLeft: '3px'
- }, (0, _getStyle2.default)(theme, 'check-icon').style),
- onClick: function onClick() {
- _this3.submitEdit(true);
- }
- })
- )
- );
- }
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_vufgfj1qd = function () {
+ return actualCoverage;
};
+ }
+ return actualCoverage;
+}
- this.getDetectedInput = function () {
- var parsedInput = _this3.state.parsedInput;
- var type = parsedInput.type,
- value = parsedInput.value;
- var props = _this3.props;
- var theme = props.theme;
-
-
- if (type !== false) {
- switch (type.toLowerCase()) {
- case 'object':
- return _react2.default.createElement(
- 'span',
- null,
- _react2.default.createElement(
- 'span',
- {
- style: _extends({}, (0, _getStyle2.default)(theme, 'brace').style, {
- cursor: 'default'
- })
- },
- '{'
- ),
- _react2.default.createElement(
- 'span',
- {
- style: _extends({}, (0, _getStyle2.default)(theme, 'ellipsis').style, {
- cursor: 'default'
- })
- },
- '...'
- ),
- _react2.default.createElement(
- 'span',
- {
- style: _extends({}, (0, _getStyle2.default)(theme, 'brace').style, {
- cursor: 'default'
- })
- },
- '}'
- )
- );
- case 'array':
- return _react2.default.createElement(
- 'span',
- null,
- _react2.default.createElement(
- 'span',
- {
- style: _extends({}, (0, _getStyle2.default)(theme, 'brace').style, {
- cursor: 'default'
- })
- },
- '['
- ),
- _react2.default.createElement(
- 'span',
- {
- style: _extends({}, (0, _getStyle2.default)(theme, 'ellipsis').style, {
- cursor: 'default'
- })
- },
- '...'
- ),
- _react2.default.createElement(
- 'span',
- {
- style: _extends({}, (0, _getStyle2.default)(theme, 'brace').style, {
- cursor: 'default'
- })
- },
- ']'
- )
- );
- case 'string':
- return _react2.default.createElement(_DataTypes.JsonString, _extends({ value: value }, props));
- case 'integer':
- return _react2.default.createElement(_DataTypes.JsonInteger, _extends({ value: value }, props));
- case 'float':
- return _react2.default.createElement(_DataTypes.JsonFloat, _extends({ value: value }, props));
- case 'boolean':
- return _react2.default.createElement(_DataTypes.JsonBoolean, _extends({ value: value }, props));
- case 'function':
- return _react2.default.createElement(_DataTypes.JsonFunction, _extends({ value: value }, props));
- case 'null':
- return _react2.default.createElement(_DataTypes.JsonNull, props);
- case 'nan':
- return _react2.default.createElement(_DataTypes.JsonNan, props);
- case 'undefined':
- return _react2.default.createElement(_DataTypes.JsonUndefined, props);
- case 'date':
- return _react2.default.createElement(_DataTypes.JsonDate, _extends({ value: new Date(value) }, props));
- }
- }
- };
-};
+cov_vufgfj1qd();
+ //theme
-exports.default = VariableEditor;
-/***/ }),
-/* 184 */
-/***/ (function(module, __webpack_exports__, __webpack_require__) {
-"use strict";
-__webpack_require__.r(__webpack_exports__);
-/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1);
-/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);
-/* harmony import */ var prop_types__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);
-/* harmony import */ var prop_types__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(prop_types__WEBPACK_IMPORTED_MODULE_1__);
+var Nan_default = /*#__PURE__*/function (_React$PureComponent) {
+ _inherits(_default, _React$PureComponent);
+ var _super = _createSuper(_default);
+ function _default() {
+ _classCallCheck(this, _default);
-function _extends() {
- _extends = Object.assign || function (target) {
- for (var i = 1; i < arguments.length; i++) {
- var source = arguments[i];
+ return _super.apply(this, arguments);
+ }
- for (var key in source) {
- if (Object.prototype.hasOwnProperty.call(source, key)) {
- target[key] = source[key];
- }
- }
+ _createClass(_default, [{
+ key: "render",
+ value: function render() {
+ cov_vufgfj1qd().f[0]++;
+ cov_vufgfj1qd().s[0]++;
+ return /*#__PURE__*/external_React_default.a.createElement("div", getStyle_style(this.props.theme, 'nan'), "NaN");
}
+ }]);
- return target;
- };
+ return _default;
+}((external_React_default.a.PureComponent));
- return _extends.apply(this, arguments);
-}
-function _inheritsLoose(subClass, superClass) {
- subClass.prototype = Object.create(superClass.prototype);
- subClass.prototype.constructor = subClass;
- subClass.__proto__ = superClass;
-}
+// CONCATENATED MODULE: ./src/js/components/DataTypes/Null.js
-var _sPO = Object.setPrototypeOf || function _sPO(o, p) {
- o.__proto__ = p;
- return o;
-};
-var _construct = typeof Reflect === "object" && Reflect.construct || function _construct(Parent, args, Class) {
- var Constructor,
- a = [null];
- a.push.apply(a, args);
- Constructor = Parent.bind.apply(Parent, a);
- return _sPO(new Constructor(), Class.prototype);
-};
-function _objectWithoutProperties(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];
- }
- if (Object.getOwnPropertySymbols) {
- var sourceSymbolKeys = Object.getOwnPropertySymbols(source);
+function cov_2n7byxkuxh() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/components/DataTypes/Null.js";
+ var hash = "7bd4fbe16ede8266fcbadcf72399a86045df3ff9";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/components/DataTypes/Null.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 8,
+ column: 8
+ },
+ end: {
+ line: 8,
+ column: 68
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "(anonymous_0)",
+ decl: {
+ start: {
+ line: 7,
+ column: 4
+ },
+ end: {
+ line: 7,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 7,
+ column: 13
+ },
+ end: {
+ line: 9,
+ column: 5
+ }
+ },
+ line: 7
+ }
+ },
+ branchMap: {},
+ s: {
+ "0": 0
+ },
+ f: {
+ "0": 0
+ },
+ b: {},
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "7bd4fbe16ede8266fcbadcf72399a86045df3ff9"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
- 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];
- }
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
}
- return target;
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_2n7byxkuxh = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
}
-var isBrowser = typeof window !== 'undefined' && typeof document !== 'undefined';
+cov_2n7byxkuxh();
+ //theme
-var isIE = isBrowser ? !!document.documentElement.currentStyle : false;
-var HIDDEN_TEXTAREA_STYLE = {
- 'min-height': '0',
- 'max-height': 'none',
- height: '0',
- visibility: 'hidden',
- overflow: 'hidden',
- position: 'absolute',
- 'z-index': '-1000',
- top: '0',
- right: '0'
-};
-var SIZING_STYLE = ['letter-spacing', 'line-height', 'font-family', 'font-weight', 'font-size', 'font-style', 'tab-size', 'text-rendering', 'text-transform', 'width', 'text-indent', 'padding-top', 'padding-right', 'padding-bottom', 'padding-left', 'border-top-width', 'border-right-width', 'border-bottom-width', 'border-left-width', 'box-sizing'];
-var computedStyleCache = {};
-var hiddenTextarea = isBrowser && document.createElement('textarea');
-var forceHiddenStyles = function forceHiddenStyles(node) {
- Object.keys(HIDDEN_TEXTAREA_STYLE).forEach(function (key) {
- node.style.setProperty(key, HIDDEN_TEXTAREA_STYLE[key], 'important');
- });
-};
-if (isBrowser) {
- forceHiddenStyles(hiddenTextarea);
-}
+var Null_default = /*#__PURE__*/function (_React$PureComponent) {
+ _inherits(_default, _React$PureComponent);
-function calculateNodeHeight(uiTextNode, uid, useCache, minRows, maxRows) {
- if (useCache === void 0) {
- useCache = false;
- }
+ var _super = _createSuper(_default);
- if (minRows === void 0) {
- minRows = null;
- }
+ function _default() {
+ _classCallCheck(this, _default);
- if (maxRows === void 0) {
- maxRows = null;
+ return _super.apply(this, arguments);
}
- if (hiddenTextarea.parentNode === null) {
- document.body.appendChild(hiddenTextarea);
- } // Copy all CSS properties that have an impact on the height of the content in
- // the textbox
+ _createClass(_default, [{
+ key: "render",
+ value: function render() {
+ cov_2n7byxkuxh().f[0]++;
+ cov_2n7byxkuxh().s[0]++;
+ return /*#__PURE__*/external_React_default.a.createElement("div", getStyle_style(this.props.theme, 'null'), "NULL");
+ }
+ }]);
+ return _default;
+}((external_React_default.a.PureComponent));
- var nodeStyling = calculateNodeStyling(uiTextNode, uid, useCache);
- if (nodeStyling === null) {
- return null;
- }
+// CONCATENATED MODULE: ./src/js/components/DataTypes/Integer.js
- var paddingSize = nodeStyling.paddingSize,
- borderSize = nodeStyling.borderSize,
- boxSizing = nodeStyling.boxSizing,
- sizingStyle = nodeStyling.sizingStyle; // Need to have the overflow attribute to hide the scrollbar otherwise
- // text-lines will not calculated properly as the shadow will technically be
- // narrower for content
-
- Object.keys(sizingStyle).forEach(function (key) {
- hiddenTextarea.style[key] = sizingStyle[key];
- });
- forceHiddenStyles(hiddenTextarea);
- hiddenTextarea.value = uiTextNode.value || uiTextNode.placeholder || 'x';
- var minHeight = -Infinity;
- var maxHeight = Infinity;
- var height = hiddenTextarea.scrollHeight;
-
- if (boxSizing === 'border-box') {
- // border-box: add border, since height = content + padding + border
- height = height + borderSize;
- } else if (boxSizing === 'content-box') {
- // remove padding, since height = content
- height = height - paddingSize;
- } // measure height of a textarea with a single row
- hiddenTextarea.value = 'x';
- var singleRowHeight = hiddenTextarea.scrollHeight - paddingSize;
- if (minRows !== null || maxRows !== null) {
- if (minRows !== null) {
- minHeight = singleRowHeight * minRows;
- if (boxSizing === 'border-box') {
- minHeight = minHeight + paddingSize + borderSize;
+function cov_1apyx3akwk() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/components/DataTypes/Integer.js";
+ var hash = "dfe533dbf6cbcd5861afaf1a68a37f2c6e03bcb9";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/components/DataTypes/Integer.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 9,
+ column: 26
+ },
+ end: {
+ line: 9,
+ column: 31
+ }
+ },
+ "1": {
+ start: {
+ line: 10,
+ column: 26
+ },
+ end: {
+ line: 10,
+ column: 30
+ }
+ },
+ "2": {
+ start: {
+ line: 11,
+ column: 8
+ },
+ end: {
+ line: 16,
+ column: 10
+ }
}
-
- height = Math.max(minHeight, height);
- }
-
- if (maxRows !== null) {
- maxHeight = singleRowHeight * maxRows;
-
- if (boxSizing === 'border-box') {
- maxHeight = maxHeight + paddingSize + borderSize;
+ },
+ fnMap: {
+ "0": {
+ name: "(anonymous_0)",
+ decl: {
+ start: {
+ line: 8,
+ column: 4
+ },
+ end: {
+ line: 8,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 8,
+ column: 13
+ },
+ end: {
+ line: 17,
+ column: 5
+ }
+ },
+ line: 8
}
-
- height = Math.min(maxHeight, height);
- }
- }
-
- var rowCount = Math.floor(height / singleRowHeight);
- return {
- height: height,
- minHeight: minHeight,
- maxHeight: maxHeight,
- rowCount: rowCount
+ },
+ branchMap: {},
+ s: {
+ "0": 0,
+ "1": 0,
+ "2": 0
+ },
+ f: {
+ "0": 0
+ },
+ b: {},
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "dfe533dbf6cbcd5861afaf1a68a37f2c6e03bcb9"
};
-}
-
-function calculateNodeStyling(node, uid, useCache) {
- if (useCache === void 0) {
- useCache = false;
- }
+ var coverage = global[gcv] || (global[gcv] = {});
- if (useCache && computedStyleCache[uid]) {
- return computedStyleCache[uid];
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
}
- var style = window.getComputedStyle(node);
-
- if (style === null) {
- return null;
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_1apyx3akwk = function () {
+ return actualCoverage;
+ };
}
+ return actualCoverage;
+}
- var sizingStyle = SIZING_STYLE.reduce(function (obj, name) {
- obj[name] = style.getPropertyValue(name);
- return obj;
- }, {});
- var boxSizing = sizingStyle['box-sizing']; // probably node is detached from DOM, can't read computed dimensions
-
- if (boxSizing === '') {
- return null;
- } // IE (Edge has already correct behaviour) returns content width as computed width
- // so we need to add manually padding and border widths
+cov_1apyx3akwk();
+ //theme
- if (isIE && boxSizing === 'border-box') {
- sizingStyle.width = parseFloat(sizingStyle.width) + parseFloat(style['border-right-width']) + parseFloat(style['border-left-width']) + parseFloat(style['padding-right']) + parseFloat(style['padding-left']) + 'px';
- }
- var paddingSize = parseFloat(sizingStyle['padding-bottom']) + parseFloat(sizingStyle['padding-top']);
- var borderSize = parseFloat(sizingStyle['border-bottom-width']) + parseFloat(sizingStyle['border-top-width']);
- var nodeInfo = {
- sizingStyle: sizingStyle,
- paddingSize: paddingSize,
- borderSize: borderSize,
- boxSizing: boxSizing
- };
- if (useCache) {
- computedStyleCache[uid] = nodeInfo;
- }
+var Integer_default = /*#__PURE__*/function (_React$PureComponent) {
+ _inherits(_default, _React$PureComponent);
- return nodeInfo;
-}
+ var _super = _createSuper(_default);
-var purgeCache = function purgeCache(uid) {
- return delete computedStyleCache[uid];
-};
+ function _default() {
+ _classCallCheck(this, _default);
-function autoInc(seed) {
- if (seed === void 0) {
- seed = 0;
+ return _super.apply(this, arguments);
}
- return function () {
- return ++seed;
- };
-}
-
-var uid = autoInc();
-
-/**
- *
- */
-var noop = function noop() {}; // IE11 has a problem with eval source maps, can be reproduced with:
-// eval('"use strict"; var onNextFrame = window.cancelAnimationFrame; onNextFrame(4);')
-// so we bind window as context in dev modes
-
-
-var _ref = isBrowser && window.requestAnimationFrame ? true ? [window.requestAnimationFrame, window.cancelAnimationFrame] : undefined : [setTimeout, clearTimeout];
-var onNextFrame = _ref[0];
-var clearNextFrameAction = _ref[1];
-
-var TextareaAutosize =
-/*#__PURE__*/
-function (_React$Component) {
- _inheritsLoose(TextareaAutosize, _React$Component);
+ _createClass(_default, [{
+ key: "render",
+ value: function render() {
+ cov_1apyx3akwk().f[0]++;
+ var type_name = (cov_1apyx3akwk().s[0]++, 'int');
- function TextareaAutosize(props) {
- var _this;
+ var _ref = (cov_1apyx3akwk().s[1]++, this),
+ props = _ref.props;
- _this = _React$Component.call(this, props) || this;
- _this._resizeLock = false;
+ cov_1apyx3akwk().s[2]++;
+ return /*#__PURE__*/external_React_default.a.createElement("div", getStyle_style(props.theme, 'integer'), /*#__PURE__*/external_React_default.a.createElement(DataTypeLabel_default, Object.assign({
+ type_name: type_name
+ }, props)), this.props.value);
+ }
+ }]);
- _this._onRootDOMNode = function (node) {
- _this._rootDOMNode = node;
+ return _default;
+}((external_React_default.a.PureComponent));
- _this.props.inputRef(node);
- };
- _this._onChange = function (event) {
- if (!_this._controlled) {
- _this._resizeComponent();
- }
+// CONCATENATED MODULE: ./src/js/components/DataTypes/Regexp.js
- _this.props.onChange(event);
- };
- _this._resizeComponent = function (callback) {
- if (callback === void 0) {
- callback = noop;
- }
- if (typeof _this._rootDOMNode === 'undefined') {
- callback();
- return;
- }
- var nodeHeight = calculateNodeHeight(_this._rootDOMNode, _this._uid, _this.props.useCacheForDOMMeasurements, _this.props.minRows, _this.props.maxRows);
- if (nodeHeight === null) {
- callback();
- return;
+function cov_1hqpzonkum() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/components/DataTypes/Regexp.js";
+ var hash = "f60dcb357d435fbb45f76155295df2cbb28dd85f";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/components/DataTypes/Regexp.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 9,
+ column: 26
+ },
+ end: {
+ line: 9,
+ column: 34
+ }
+ },
+ "1": {
+ start: {
+ line: 10,
+ column: 26
+ },
+ end: {
+ line: 10,
+ column: 30
+ }
+ },
+ "2": {
+ start: {
+ line: 11,
+ column: 8
+ },
+ end: {
+ line: 16,
+ column: 10
+ }
}
-
- var height = nodeHeight.height,
- minHeight = nodeHeight.minHeight,
- maxHeight = nodeHeight.maxHeight,
- rowCount = nodeHeight.rowCount;
- _this.rowCount = rowCount;
-
- if (_this.state.height !== height || _this.state.minHeight !== minHeight || _this.state.maxHeight !== maxHeight) {
- _this.setState({
- height: height,
- minHeight: minHeight,
- maxHeight: maxHeight
- }, callback);
-
- return;
+ },
+ fnMap: {
+ "0": {
+ name: "(anonymous_0)",
+ decl: {
+ start: {
+ line: 8,
+ column: 4
+ },
+ end: {
+ line: 8,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 8,
+ column: 13
+ },
+ end: {
+ line: 17,
+ column: 5
+ }
+ },
+ line: 8
}
+ },
+ branchMap: {},
+ s: {
+ "0": 0,
+ "1": 0,
+ "2": 0
+ },
+ f: {
+ "0": 0
+ },
+ b: {},
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "f60dcb357d435fbb45f76155295df2cbb28dd85f"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
- callback();
- };
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
- _this.state = {
- height: props.style && props.style.height || 0,
- minHeight: -Infinity,
- maxHeight: Infinity
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_1hqpzonkum = function () {
+ return actualCoverage;
};
- _this._uid = uid();
- _this._controlled = typeof props.value === 'string';
- return _this;
}
+ return actualCoverage;
+}
- var _proto = TextareaAutosize.prototype;
-
- _proto.render = function render() {
- var _props = this.props,
- _inputRef = _props.inputRef,
- _maxRows = _props.maxRows,
- _minRows = _props.minRows,
- _onHeightChange = _props.onHeightChange,
- _useCacheForDOMMeasurements = _props.useCacheForDOMMeasurements,
- props = _objectWithoutProperties(_props, ["inputRef", "maxRows", "minRows", "onHeightChange", "useCacheForDOMMeasurements"]);
+cov_1hqpzonkum();
- props.style = _extends({}, props.style, {
- height: this.state.height
- });
- var maxHeight = Math.max(props.style.maxHeight || Infinity, this.state.maxHeight);
+ //theme
- if (maxHeight < this.state.height) {
- props.style.overflow = 'hidden';
- }
- return react__WEBPACK_IMPORTED_MODULE_0___default.a.createElement("textarea", _extends({}, props, {
- onChange: this._onChange,
- ref: this._onRootDOMNode
- }));
- };
- _proto.componentDidMount = function componentDidMount() {
- var _this2 = this;
+var Regexp_default = /*#__PURE__*/function (_React$PureComponent) {
+ _inherits(_default, _React$PureComponent);
- this._resizeComponent(); // Working around Firefox bug which runs resize listeners even when other JS is running at the same moment
- // causing competing rerenders (due to setState in the listener) in React.
- // More can be found here - facebook/react#6324
+ var _super = _createSuper(_default);
+ function _default() {
+ _classCallCheck(this, _default);
- this._resizeListener = function () {
- if (_this2._resizeLock) {
- return;
- }
+ return _super.apply(this, arguments);
+ }
- _this2._resizeLock = true;
+ _createClass(_default, [{
+ key: "render",
+ value: function render() {
+ cov_1hqpzonkum().f[0]++;
+ var type_name = (cov_1hqpzonkum().s[0]++, 'regexp');
- _this2._resizeComponent(function () {
- return _this2._resizeLock = false;
- });
- };
+ var _ref = (cov_1hqpzonkum().s[1]++, this),
+ props = _ref.props;
- window.addEventListener('resize', this._resizeListener);
- };
+ cov_1hqpzonkum().s[2]++;
+ return /*#__PURE__*/external_React_default.a.createElement("div", getStyle_style(props.theme, 'regexp'), /*#__PURE__*/external_React_default.a.createElement(DataTypeLabel_default, Object.assign({
+ type_name: type_name
+ }, props)), this.props.value.toString());
+ }
+ }]);
- _proto.componentDidUpdate = function componentDidUpdate(prevProps, prevState) {
- var _this3 = this;
+ return _default;
+}((external_React_default.a.PureComponent));
- if (prevProps !== this.props) {
- this._clearNextFrame();
- this._onNextFrameActionId = onNextFrame(function () {
- return _this3._resizeComponent();
- });
- }
+// CONCATENATED MODULE: ./src/js/components/DataTypes/String.js
- if (this.state.height !== prevState.height) {
- this.props.onHeightChange(this.state.height, this);
- }
- };
- _proto.componentWillUnmount = function componentWillUnmount() {
- this._clearNextFrame();
- window.removeEventListener('resize', this._resizeListener);
- purgeCache(this._uid);
- };
- _proto._clearNextFrame = function _clearNextFrame() {
- clearNextFrameAction(this._onNextFrameActionId);
- };
- return TextareaAutosize;
-}(react__WEBPACK_IMPORTED_MODULE_0___default.a.Component);
-
-TextareaAutosize.propTypes = {
- inputRef: prop_types__WEBPACK_IMPORTED_MODULE_1___default.a.func,
- maxRows: prop_types__WEBPACK_IMPORTED_MODULE_1___default.a.number,
- minRows: prop_types__WEBPACK_IMPORTED_MODULE_1___default.a.number,
- onChange: prop_types__WEBPACK_IMPORTED_MODULE_1___default.a.func,
- onHeightChange: prop_types__WEBPACK_IMPORTED_MODULE_1___default.a.func,
- useCacheForDOMMeasurements: prop_types__WEBPACK_IMPORTED_MODULE_1___default.a.bool,
- value: prop_types__WEBPACK_IMPORTED_MODULE_1___default.a.string
-};
-TextareaAutosize.defaultProps = {
- inputRef: noop,
- onChange: noop,
- onHeightChange: noop,
- useCacheForDOMMeasurements: false
-};
+function cov_21a57g5452() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/components/DataTypes/String.js";
+ var hash = "2e3e5b3ac73ddc270c798e0ede66e43fc7f0c917";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/components/DataTypes/String.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 13,
+ column: 8
+ },
+ end: {
+ line: 13,
+ column: 21
+ }
+ },
+ "1": {
+ start: {
+ line: 14,
+ column: 8
+ },
+ end: {
+ line: 21,
+ column: 10
+ }
+ },
+ "2": {
+ start: {
+ line: 24,
+ column: 22
+ },
+ end: {
+ line: 38,
+ column: 5
+ }
+ },
+ "3": {
+ start: {
+ line: 25,
+ column: 8
+ },
+ end: {
+ line: 37,
+ column: 10
+ }
+ },
+ "4": {
+ start: {
+ line: 30,
+ column: 16
+ },
+ end: {
+ line: 35,
+ column: 18
+ }
+ },
+ "5": {
+ start: {
+ line: 41,
+ column: 26
+ },
+ end: {
+ line: 41,
+ column: 34
+ }
+ },
+ "6": {
+ start: {
+ line: 42,
+ column: 30
+ },
+ end: {
+ line: 42,
+ column: 40
+ }
+ },
+ "7": {
+ start: {
+ line: 43,
+ column: 26
+ },
+ end: {
+ line: 43,
+ column: 30
+ }
+ },
+ "8": {
+ start: {
+ line: 44,
+ column: 54
+ },
+ end: {
+ line: 44,
+ column: 59
+ }
+ },
+ "9": {
+ start: {
+ line: 45,
+ column: 24
+ },
+ end: {
+ line: 45,
+ column: 29
+ }
+ },
+ "10": {
+ start: {
+ line: 46,
+ column: 26
+ },
+ end: {
+ line: 46,
+ column: 74
+ }
+ },
+ "11": {
+ start: {
+ line: 47,
+ column: 20
+ },
+ end: {
+ line: 47,
+ column: 52
+ }
+ },
+ "12": {
+ start: {
+ line: 49,
+ column: 8
+ },
+ end: {
+ line: 59,
+ column: 9
+ }
+ },
+ "13": {
+ start: {
+ line: 50,
+ column: 12
+ },
+ end: {
+ line: 50,
+ column: 43
+ }
+ },
+ "14": {
+ start: {
+ line: 51,
+ column: 12
+ },
+ end: {
+ line: 58,
+ column: 13
+ }
+ },
+ "15": {
+ start: {
+ line: 52,
+ column: 16
+ },
+ end: {
+ line: 57,
+ column: 18
+ }
+ },
+ "16": {
+ start: {
+ line: 61,
+ column: 8
+ },
+ end: {
+ line: 72,
+ column: 10
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "(anonymous_0)",
+ decl: {
+ start: {
+ line: 12,
+ column: 4
+ },
+ end: {
+ line: 12,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 12,
+ column: 23
+ },
+ end: {
+ line: 22,
+ column: 5
+ }
+ },
+ line: 12
+ },
+ "1": {
+ name: "(anonymous_1)",
+ decl: {
+ start: {
+ line: 24,
+ column: 22
+ },
+ end: {
+ line: 24,
+ column: 23
+ }
+ },
+ loc: {
+ start: {
+ line: 24,
+ column: 28
+ },
+ end: {
+ line: 38,
+ column: 5
+ }
+ },
+ line: 24
+ },
+ "2": {
+ name: "(anonymous_2)",
+ decl: {
+ start: {
+ line: 29,
+ column: 12
+ },
+ end: {
+ line: 29,
+ column: 13
+ }
+ },
+ loc: {
+ start: {
+ line: 29,
+ column: 18
+ },
+ end: {
+ line: 36,
+ column: 13
+ }
+ },
+ line: 29
+ },
+ "3": {
+ name: "(anonymous_3)",
+ decl: {
+ start: {
+ line: 40,
+ column: 4
+ },
+ end: {
+ line: 40,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 40,
+ column: 13
+ },
+ end: {
+ line: 73,
+ column: 5
+ }
+ },
+ line: 40
+ }
+ },
+ branchMap: {
+ "0": {
+ loc: {
+ start: {
+ line: 49,
+ column: 8
+ },
+ end: {
+ line: 59,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 49,
+ column: 8
+ },
+ end: {
+ line: 59,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 49,
+ column: 8
+ },
+ end: {
+ line: 59,
+ column: 9
+ }
+ }],
+ line: 49
+ },
+ "1": {
+ loc: {
+ start: {
+ line: 49,
+ column: 12
+ },
+ end: {
+ line: 49,
+ column: 68
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 49,
+ column: 12
+ },
+ end: {
+ line: 49,
+ column: 23
+ }
+ }, {
+ start: {
+ line: 49,
+ column: 27
+ },
+ end: {
+ line: 49,
+ column: 68
+ }
+ }],
+ line: 49
+ },
+ "2": {
+ loc: {
+ start: {
+ line: 51,
+ column: 12
+ },
+ end: {
+ line: 58,
+ column: 13
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 51,
+ column: 12
+ },
+ end: {
+ line: 58,
+ column: 13
+ }
+ }, {
+ start: {
+ line: 51,
+ column: 12
+ },
+ end: {
+ line: 58,
+ column: 13
+ }
+ }],
+ line: 51
+ }
+ },
+ s: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0,
+ "7": 0,
+ "8": 0,
+ "9": 0,
+ "10": 0,
+ "11": 0,
+ "12": 0,
+ "13": 0,
+ "14": 0,
+ "15": 0,
+ "16": 0
+ },
+ f: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0
+ },
+ b: {
+ "0": [0, 0],
+ "1": [0, 0],
+ "2": [0, 0]
+ },
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "2e3e5b3ac73ddc270c798e0ede66e43fc7f0c917"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
-/* harmony default export */ __webpack_exports__["default"] = (TextareaAutosize);
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_21a57g5452 = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
-/***/ }),
-/* 185 */
-/***/ (function(module, exports, __webpack_require__) {
+cov_21a57g5452();
-"use strict";
+ //theme
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
-exports.default = parseInput;
-function parseInput(input) {
+ //attribute store for storing collapsed state
- //following code is to make a best guess at
- //the type for a variable being submitted.
- //we are working with a serialized data representation
- input = input.trim();
- try {
- input = JSON.stringify(JSON.parse(input));
- if (input[0] === '[') {
- //array
- return formatResponse('array', JSON.parse(input));
- } else if (input[0] === '{') {
- //object
- return formatResponse('object', JSON.parse(input));
- } else if (input.match(/\-?\d+\.\d+/) && input.match(/\-?\d+\.\d+/)[0] === input) {
- //integer
- return formatResponse('float', parseFloat(input));
- } else if (input.match(/\-?\d+/) && input.match(/\-?\d+/)[0] === input) {
- //float
- return formatResponse('integer', parseInt(input));
- }
- } catch (e) {}
- // no-op
+var String_default = /*#__PURE__*/function (_React$PureComponent) {
+ _inherits(_default, _React$PureComponent);
- //run in case input was not serializable
- input = input.toLowerCase();
- switch (input) {
- case 'undefined':
- {
- return formatResponse('undefined', undefined);
- }
- case 'nan':
- {
- return formatResponse('nan', NaN);
- }
- case 'null':
- {
- return formatResponse('null', null);
- }
- case 'true':
- {
- return formatResponse('boolean', true);
- }
- case 'false':
- {
- return formatResponse('boolean', false);
- }
- default:
- {
- //check to see if this is a date
- input = Date.parse(input);
- if (input) {
- return formatResponse('date', new Date(input));
- }
- }
- }
+ var _super = _createSuper(_default);
- return formatResponse(false, null);
-}
+ function _default(props) {
+ var _this;
-function formatResponse(type, value) {
- return {
- type: type,
- value: value
+ _classCallCheck(this, _default);
+
+ cov_21a57g5452().f[0]++;
+ cov_21a57g5452().s[0]++;
+ _this = _super.call(this, props);
+ _this.toggleCollapsed = (cov_21a57g5452().s[2]++, function () {
+ cov_21a57g5452().f[1]++;
+ cov_21a57g5452().s[3]++;
+
+ _this.setState({
+ collapsed: !_this.state.collapsed
+ }, function () {
+ cov_21a57g5452().f[2]++;
+ cov_21a57g5452().s[4]++;
+ stores_ObjectAttributes.set(_this.props.rjvId, _this.props.namespace, 'collapsed', _this.state.collapsed);
+ });
+ });
+ cov_21a57g5452().s[1]++;
+ _this.state = {
+ collapsed: stores_ObjectAttributes.get(props.rjvId, props.namespace, 'collapsed', true)
};
-}
+ return _this;
+ }
-/***/ }),
-/* 186 */
-/***/ (function(module, exports, __webpack_require__) {
+ _createClass(_default, [{
+ key: "render",
+ value: function render() {
+ cov_21a57g5452().f[3]++;
+ var type_name = (cov_21a57g5452().s[5]++, 'string');
-"use strict";
+ var _ref = (cov_21a57g5452().s[6]++, this.state),
+ collapsed = _ref.collapsed;
+ var _ref2 = (cov_21a57g5452().s[7]++, this),
+ props = _ref2.props;
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
+ var _ref3 = (cov_21a57g5452().s[8]++, props),
+ collapseStringsAfterLength = _ref3.collapseStringsAfterLength,
+ theme = _ref3.theme;
-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 _ref4 = (cov_21a57g5452().s[9]++, props),
+ value = _ref4.value;
-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 collapsible = (cov_21a57g5452().s[10]++, toType(collapseStringsAfterLength) === 'integer');
+ var style = (cov_21a57g5452().s[11]++, {
+ style: {
+ cursor: 'default'
+ }
+ });
+ cov_21a57g5452().s[12]++;
+
+ if ((cov_21a57g5452().b[1][0]++, collapsible) && (cov_21a57g5452().b[1][1]++, value.length > collapseStringsAfterLength)) {
+ cov_21a57g5452().b[0][0]++;
+ cov_21a57g5452().s[13]++;
+ style.style.cursor = 'pointer';
+ cov_21a57g5452().s[14]++;
+
+ if (this.state.collapsed) {
+ cov_21a57g5452().b[2][0]++;
+ cov_21a57g5452().s[15]++;
+ value = /*#__PURE__*/external_React_default.a.createElement("span", null, value.substring(0, collapseStringsAfterLength), /*#__PURE__*/external_React_default.a.createElement("span", getStyle_style(theme, 'ellipsis'), " ..."));
+ } else {
+ cov_21a57g5452().b[2][1]++;
+ }
+ } else {
+ cov_21a57g5452().b[0][1]++;
+ }
-var _react = __webpack_require__(1);
+ cov_21a57g5452().s[16]++;
+ return /*#__PURE__*/external_React_default.a.createElement("div", getStyle_style(theme, 'string'), /*#__PURE__*/external_React_default.a.createElement(DataTypeLabel_default, Object.assign({
+ type_name: type_name
+ }, props)), /*#__PURE__*/external_React_default.a.createElement("span", Object.assign({
+ className: "string-value"
+ }, style, {
+ onClick: this.toggleCollapsed
+ }), "\"", value, "\""));
+ }
+ }]);
-var _react2 = _interopRequireDefault(_react);
+ return _default;
+}((external_React_default.a.PureComponent));
-var _dispatcher = __webpack_require__(17);
-var _dispatcher2 = _interopRequireDefault(_dispatcher);
+// CONCATENATED MODULE: ./src/js/components/DataTypes/Undefined.js
-var _ObjectAttributes = __webpack_require__(16);
-var _ObjectAttributes2 = _interopRequireDefault(_ObjectAttributes);
-var _ObjectKeyModal = __webpack_require__(187);
-var _ObjectKeyModal2 = _interopRequireDefault(_ObjectKeyModal);
-var _getStyle = __webpack_require__(2);
+function cov_3519ezfuh() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/components/DataTypes/Undefined.js";
+ var hash = "a13cb613efcd934280abba17657a656b7dabe36d";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/components/DataTypes/Undefined.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 8,
+ column: 8
+ },
+ end: {
+ line: 8,
+ column: 78
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "(anonymous_0)",
+ decl: {
+ start: {
+ line: 7,
+ column: 4
+ },
+ end: {
+ line: 7,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 7,
+ column: 13
+ },
+ end: {
+ line: 9,
+ column: 5
+ }
+ },
+ line: 7
+ }
+ },
+ branchMap: {},
+ s: {
+ "0": 0
+ },
+ f: {
+ "0": 0
+ },
+ b: {},
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "a13cb613efcd934280abba17657a656b7dabe36d"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
-var _getStyle2 = _interopRequireDefault(_getStyle);
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_3519ezfuh = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
-function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
+cov_3519ezfuh();
+ //theme
-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; }
-//global theme
+var Undefined_default = /*#__PURE__*/function (_React$PureComponent) {
+ _inherits(_default, _React$PureComponent);
+ var _super = _createSuper(_default);
-//this input appears when adding a new value to an object
-var _class = function (_React$PureComponent) {
- _inherits(_class, _React$PureComponent);
+ function _default() {
+ _classCallCheck(this, _default);
- function _class() {
- var _ref;
+ return _super.apply(this, arguments);
+ }
- var _temp, _this, _ret;
+ _createClass(_default, [{
+ key: "render",
+ value: function render() {
+ cov_3519ezfuh().f[0]++;
+ cov_3519ezfuh().s[0]++;
+ return /*#__PURE__*/external_React_default.a.createElement("div", getStyle_style(this.props.theme, 'undefined'), "undefined");
+ }
+ }]);
+
+ return _default;
+}((external_React_default.a.PureComponent));
+
+
+// CONCATENATED MODULE: ./src/js/components/DataTypes/DataTypes.js
+function cov_d14x4rjxj() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/components/DataTypes/DataTypes.js";
+ var hash = "ff4d14b535d221449a969f969e59cd16223b5d19";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/components/DataTypes/DataTypes.js",
+ statementMap: {},
+ fnMap: {},
+ branchMap: {},
+ s: {},
+ f: {},
+ b: {},
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "ff4d14b535d221449a969f969e59cd16223b5d19"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
- _classCallCheck(this, _class);
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
- for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {
- args[_key] = arguments[_key];
- }
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_d14x4rjxj = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
- return _ret = (_temp = (_this = _possibleConstructorReturn(this, (_ref = _class.__proto__ || Object.getPrototypeOf(_class)).call.apply(_ref, [this].concat(args))), _this), _this.isValid = function (input) {
- var rjvId = _this.props.rjvId;
+cov_d14x4rjxj();
- var request = _ObjectAttributes2.default.get(rjvId, 'action', 'new-key-request');
- return input != '' && Object.keys(request.existing_value).indexOf(input) === -1;
- }, _this.submit = function (input) {
- var rjvId = _this.props.rjvId;
- var request = _ObjectAttributes2.default.get(rjvId, 'action', 'new-key-request');
- request.new_value = _extends({}, request.existing_value);
- request.new_value[input] = _this.props.defaultValue;
- _dispatcher2.default.dispatch({
- name: 'VARIABLE_ADDED',
- rjvId: rjvId,
- data: request
- });
- }, _temp), _possibleConstructorReturn(_this, _ret);
- }
- _createClass(_class, [{
- key: 'render',
- value: function render() {
- var _props = this.props,
- active = _props.active,
- theme = _props.theme,
- rjvId = _props.rjvId;
- return active ? _react2.default.createElement(_ObjectKeyModal2.default, {
- rjvId: rjvId,
- theme: theme,
- isValid: this.isValid,
- submit: this.submit
- }) : null;
- }
- }]);
- return _class;
-}(_react2.default.PureComponent);
-exports.default = _class;
-/***/ }),
-/* 187 */
-/***/ (function(module, exports, __webpack_require__) {
-"use strict";
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
+// CONCATENATED MODULE: ./node_modules/react-textarea-autosize/dist/react-textarea-autosize.es.js
-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 _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__(1);
+function react_textarea_autosize_es_extends() {
+ react_textarea_autosize_es_extends = Object.assign || function (target) {
+ for (var i = 1; i < arguments.length; i++) {
+ var source = arguments[i];
-var _react2 = _interopRequireDefault(_react);
+ for (var key in source) {
+ if (Object.prototype.hasOwnProperty.call(source, key)) {
+ target[key] = source[key];
+ }
+ }
+ }
-var _dispatcher = __webpack_require__(17);
+ return target;
+ };
-var _dispatcher2 = _interopRequireDefault(_dispatcher);
+ return react_textarea_autosize_es_extends.apply(this, arguments);
+}
-var _icons = __webpack_require__(18);
+function _inheritsLoose(subClass, superClass) {
+ subClass.prototype = Object.create(superClass.prototype);
+ subClass.prototype.constructor = subClass;
+ subClass.__proto__ = superClass;
+}
-var _getStyle = __webpack_require__(2);
+var _sPO = Object.setPrototypeOf || function _sPO(o, p) {
+ o.__proto__ = p;
+ return o;
+};
-var _getStyle2 = _interopRequireDefault(_getStyle);
+var _construct = typeof Reflect === "object" && Reflect.construct || function _construct(Parent, args, Class) {
+ var Constructor,
+ a = [null];
+ a.push.apply(a, args);
+ Constructor = Parent.bind.apply(Parent, a);
+ return _sPO(new Constructor(), Class.prototype);
+};
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+function react_textarea_autosize_es_objectWithoutProperties(source, excluded) {
+ if (source == null) return {};
+ var target = {};
+ var sourceKeys = Object.keys(source);
+ var key, i;
-function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
+ for (i = 0; i < sourceKeys.length; i++) {
+ key = sourceKeys[i];
+ if (excluded.indexOf(key) >= 0) continue;
+ target[key] = source[key];
+ }
-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; }
+ if (Object.getOwnPropertySymbols) {
+ var sourceSymbolKeys = Object.getOwnPropertySymbols(source);
-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; }
+ 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];
+ }
+ }
-//global theme
+ return target;
+}
+var isBrowser = typeof window !== 'undefined' && typeof document !== 'undefined';
-//this input appears when adding a new value to an object
-var _class = function (_React$PureComponent) {
- _inherits(_class, _React$PureComponent);
+var isIE = isBrowser ? !!document.documentElement.currentStyle : false;
+var HIDDEN_TEXTAREA_STYLE = {
+ 'min-height': '0',
+ 'max-height': 'none',
+ height: '0',
+ visibility: 'hidden',
+ overflow: 'hidden',
+ position: 'absolute',
+ 'z-index': '-1000',
+ top: '0',
+ right: '0'
+};
+var SIZING_STYLE = ['letter-spacing', 'line-height', 'font-family', 'font-weight', 'font-size', 'font-style', 'tab-size', 'text-rendering', 'text-transform', 'width', 'text-indent', 'padding-top', 'padding-right', 'padding-bottom', 'padding-left', 'border-top-width', 'border-right-width', 'border-bottom-width', 'border-left-width', 'box-sizing'];
+var computedStyleCache = {};
+var hiddenTextarea = isBrowser && document.createElement('textarea');
- function _class(props) {
- _classCallCheck(this, _class);
+var forceHiddenStyles = function forceHiddenStyles(node) {
+ Object.keys(HIDDEN_TEXTAREA_STYLE).forEach(function (key) {
+ node.style.setProperty(key, HIDDEN_TEXTAREA_STYLE[key], 'important');
+ });
+};
- var _this = _possibleConstructorReturn(this, (_class.__proto__ || Object.getPrototypeOf(_class)).call(this, props));
+if (isBrowser) {
+ forceHiddenStyles(hiddenTextarea);
+}
- _this.closeModal = function () {
- _dispatcher2.default.dispatch({
- rjvId: _this.props.rjvId,
- name: 'RESET'
- });
- };
+function calculateNodeHeight(uiTextNode, uid, useCache, minRows, maxRows) {
+ if (useCache === void 0) {
+ useCache = false;
+ }
- _this.submit = function () {
- _this.props.submit(_this.state.input);
- };
+ if (minRows === void 0) {
+ minRows = null;
+ }
- _this.state = {
- input: props.input ? props.input : ''
- };
- return _this;
- }
-
- _createClass(_class, [{
- key: 'render',
- value: function render() {
- var _this2 = this;
-
- var _props = this.props,
- theme = _props.theme,
- rjvId = _props.rjvId,
- isValid = _props.isValid;
- var input = this.state.input;
-
-
- var valid = isValid(input);
-
- return _react2.default.createElement(
- 'div',
- _extends({
- className: 'key-modal-request'
- }, (0, _getStyle2.default)(theme, 'key-modal-request'), {
- onClick: this.closeModal
- }),
- _react2.default.createElement(
- 'div',
- _extends({}, (0, _getStyle2.default)(theme, 'key-modal'), {
- onClick: function onClick(e) {
- e.stopPropagation();
- }
- }),
- _react2.default.createElement(
- 'div',
- (0, _getStyle2.default)(theme, 'key-modal-label'),
- 'Key Name:'
- ),
- _react2.default.createElement(
- 'div',
- { style: { position: 'relative' } },
- _react2.default.createElement('input', _extends({}, (0, _getStyle2.default)(theme, 'key-modal-input'), {
- className: 'key-modal-input',
- ref: function ref(el) {
- return el && el.focus();
- },
- spellCheck: false,
- value: input,
- placeholder: '...',
- onChange: function onChange(e) {
- _this2.setState({
- input: e.target.value
- });
- },
- onKeyPress: function onKeyPress(e) {
- if (valid && e.key === 'Enter') {
- _this2.submit();
- } else if (e.key === 'Escape') {
- _this2.closeModal();
- }
- }
- })),
- valid ? _react2.default.createElement(_icons.CheckCircle, _extends({}, (0, _getStyle2.default)(theme, 'key-modal-submit'), {
- className: 'key-modal-submit',
- onClick: function onClick(e) {
- return _this2.submit();
- }
- })) : null
- ),
- _react2.default.createElement(
- 'span',
- (0, _getStyle2.default)(theme, 'key-modal-cancel'),
- _react2.default.createElement(_icons.Add, _extends({}, (0, _getStyle2.default)(theme, 'key-modal-cancel-icon'), {
- className: 'key-modal-cancel',
- onClick: function onClick() {
- _dispatcher2.default.dispatch({
- rjvId: rjvId,
- name: 'RESET'
- });
- } }))
- )
- )
- );
- }
- }]);
-
- return _class;
-}(_react2.default.PureComponent);
-
-exports.default = _class;
-
-/***/ }),
-/* 188 */
-/***/ (function(module, exports, __webpack_require__) {
-
-"use strict";
+ if (maxRows === void 0) {
+ maxRows = null;
+ }
+ if (hiddenTextarea.parentNode === null) {
+ document.body.appendChild(hiddenTextarea);
+ } // Copy all CSS properties that have an impact on the height of the content in
+ // the textbox
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
-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 nodeStyling = calculateNodeStyling(uiTextNode, uid, useCache);
-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; }; }();
+ if (nodeStyling === null) {
+ return null;
+ }
-var _react = __webpack_require__(1);
+ var paddingSize = nodeStyling.paddingSize,
+ borderSize = nodeStyling.borderSize,
+ boxSizing = nodeStyling.boxSizing,
+ sizingStyle = nodeStyling.sizingStyle; // Need to have the overflow attribute to hide the scrollbar otherwise
+ // text-lines will not calculated properly as the shadow will technically be
+ // narrower for content
-var _react2 = _interopRequireDefault(_react);
+ Object.keys(sizingStyle).forEach(function (key) {
+ hiddenTextarea.style[key] = sizingStyle[key];
+ });
+ forceHiddenStyles(hiddenTextarea);
+ hiddenTextarea.value = uiTextNode.value || uiTextNode.placeholder || 'x';
+ var minHeight = -Infinity;
+ var maxHeight = Infinity;
+ var height = hiddenTextarea.scrollHeight;
-var _dispatcher = __webpack_require__(17);
+ if (boxSizing === 'border-box') {
+ // border-box: add border, since height = content + padding + border
+ height = height + borderSize;
+ } else if (boxSizing === 'content-box') {
+ // remove padding, since height = content
+ height = height - paddingSize;
+ } // measure height of a textarea with a single row
-var _dispatcher2 = _interopRequireDefault(_dispatcher);
-var _ObjectAttributes = __webpack_require__(16);
+ hiddenTextarea.value = 'x';
+ var singleRowHeight = hiddenTextarea.scrollHeight - paddingSize;
-var _ObjectAttributes2 = _interopRequireDefault(_ObjectAttributes);
+ if (minRows !== null || maxRows !== null) {
+ if (minRows !== null) {
+ minHeight = singleRowHeight * minRows;
-var _icons = __webpack_require__(18);
+ if (boxSizing === 'border-box') {
+ minHeight = minHeight + paddingSize + borderSize;
+ }
-var _getStyle = __webpack_require__(2);
+ height = Math.max(minHeight, height);
+ }
-var _getStyle2 = _interopRequireDefault(_getStyle);
+ if (maxRows !== null) {
+ maxHeight = singleRowHeight * maxRows;
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+ if (boxSizing === 'border-box') {
+ maxHeight = maxHeight + paddingSize + borderSize;
+ }
-function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
+ height = Math.min(maxHeight, height);
+ }
+ }
-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; }
+ var rowCount = Math.floor(height / singleRowHeight);
+ return {
+ height: height,
+ minHeight: minHeight,
+ maxHeight: maxHeight,
+ rowCount: rowCount
+ };
+}
-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; }
+function calculateNodeStyling(node, uid, useCache) {
+ if (useCache === void 0) {
+ useCache = false;
+ }
-//global theme
+ if (useCache && computedStyleCache[uid]) {
+ return computedStyleCache[uid];
+ }
+ var style = window.getComputedStyle(node);
-//this input appears when adding a new value to an object
-var _class = function (_React$PureComponent) {
- _inherits(_class, _React$PureComponent);
+ if (style === null) {
+ return null;
+ }
- function _class() {
- _classCallCheck(this, _class);
+ var sizingStyle = SIZING_STYLE.reduce(function (obj, name) {
+ obj[name] = style.getPropertyValue(name);
+ return obj;
+ }, {});
+ var boxSizing = sizingStyle['box-sizing']; // probably node is detached from DOM, can't read computed dimensions
- return _possibleConstructorReturn(this, (_class.__proto__ || Object.getPrototypeOf(_class)).apply(this, arguments));
- }
+ if (boxSizing === '') {
+ return null;
+ } // IE (Edge has already correct behaviour) returns content width as computed width
+ // so we need to add manually padding and border widths
- _createClass(_class, [{
- key: 'render',
- value: function render() {
- var _props = this.props,
- message = _props.message,
- active = _props.active,
- theme = _props.theme,
- rjvId = _props.rjvId;
+ if (isIE && boxSizing === 'border-box') {
+ sizingStyle.width = parseFloat(sizingStyle.width) + parseFloat(style['border-right-width']) + parseFloat(style['border-left-width']) + parseFloat(style['padding-right']) + parseFloat(style['padding-left']) + 'px';
+ }
- return active ? _react2.default.createElement(
- 'div',
- _extends({
- className: 'validation-failure'
- }, (0, _getStyle2.default)(theme, 'validation-failure'), {
- onClick: function onClick() {
- _dispatcher2.default.dispatch({
- rjvId: rjvId,
- name: 'RESET'
- });
- }
- }),
- _react2.default.createElement(
- 'span',
- (0, _getStyle2.default)(theme, 'validation-failure-label'),
- message
- ),
- _react2.default.createElement(_icons.Add, (0, _getStyle2.default)(theme, 'validation-failure-clear'))
- ) : null;
- }
- }]);
+ var paddingSize = parseFloat(sizingStyle['padding-bottom']) + parseFloat(sizingStyle['padding-top']);
+ var borderSize = parseFloat(sizingStyle['border-bottom-width']) + parseFloat(sizingStyle['border-top-width']);
+ var nodeInfo = {
+ sizingStyle: sizingStyle,
+ paddingSize: paddingSize,
+ borderSize: borderSize,
+ boxSizing: boxSizing
+ };
- return _class;
-}(_react2.default.PureComponent);
+ if (useCache) {
+ computedStyleCache[uid] = nodeInfo;
+ }
-exports.default = _class;
+ return nodeInfo;
+}
-/***/ }),
-/* 189 */
-/***/ (function(module, exports, __webpack_require__) {
+var purgeCache = function purgeCache(uid) {
+ return delete computedStyleCache[uid];
+};
-"use strict";
+function autoInc(seed) {
+ if (seed === void 0) {
+ seed = 0;
+ }
+ return function () {
+ return ++seed;
+ };
+}
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
+var uid = autoInc();
-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 noop = function noop() {}; // IE11 has a problem with eval source maps, can be reproduced with:
+// eval('"use strict"; var onNextFrame = window.cancelAnimationFrame; onNextFrame(4);')
+// so we bind window as context in dev modes
-var _react = __webpack_require__(1);
-var _react2 = _interopRequireDefault(_react);
+var react_textarea_autosize_es_ref = isBrowser && window.requestAnimationFrame ? true ? [window.requestAnimationFrame, window.cancelAnimationFrame] : undefined : [setTimeout, clearTimeout];
+var onNextFrame = react_textarea_autosize_es_ref[0];
+var clearNextFrameAction = react_textarea_autosize_es_ref[1];
-var _propTypes = __webpack_require__(0);
+var react_textarea_autosize_es_TextareaAutosize =
+/*#__PURE__*/
+function (_React$Component) {
+ _inheritsLoose(TextareaAutosize, _React$Component);
-var _propTypes2 = _interopRequireDefault(_propTypes);
+ function TextareaAutosize(props) {
+ var _this;
-var _ajaxGet = __webpack_require__(190);
+ _this = _React$Component.call(this, props) || this;
+ _this._resizeLock = false;
-var _ajaxGet2 = _interopRequireDefault(_ajaxGet);
+ _this._onRootDOMNode = function (node) {
+ _this._rootDOMNode = node;
-var _utils = __webpack_require__(191);
+ _this.props.inputRef(node);
+ };
-var utils = _interopRequireWildcard(_utils);
+ _this._onChange = function (event) {
+ if (!_this._controlled) {
+ _this._resizeComponent();
+ }
-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; } }
+ _this.props.onChange(event);
+ };
-function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
+ _this._resizeComponent = function (callback) {
+ if (callback === void 0) {
+ callback = noop;
+ }
-function _defaults(obj, defaults) { var keys = Object.getOwnPropertyNames(defaults); for (var i = 0; i < keys.length; i++) { var key = keys[i]; var value = Object.getOwnPropertyDescriptor(defaults, key); if (value && value.configurable && obj[key] === undefined) { Object.defineProperty(obj, key, value); } } return obj; }
+ if (typeof _this._rootDOMNode === 'undefined') {
+ callback();
+ return;
+ }
-function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
+ var nodeHeight = calculateNodeHeight(_this._rootDOMNode, _this._uid, _this.props.useCacheForDOMMeasurements, _this.props.minRows, _this.props.maxRows);
-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; }
+ if (nodeHeight === null) {
+ callback();
+ return;
+ }
-function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
+ var height = nodeHeight.height,
+ minHeight = nodeHeight.minHeight,
+ maxHeight = nodeHeight.maxHeight,
+ rowCount = nodeHeight.rowCount;
+ _this.rowCount = rowCount;
-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; }
+ if (_this.state.height !== height || _this.state.minHeight !== minHeight || _this.state.maxHeight !== maxHeight) {
+ _this.setState({
+ height: height,
+ minHeight: minHeight,
+ maxHeight: maxHeight
+ }, callback);
-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) : _defaults(subClass, superClass); }
+ return;
+ }
-var typeToLabel = {
- stargazers: 'Star',
- watchers: 'Watch',
- forks: 'Fork'
-};
+ callback();
+ };
-var typeToPath = {
- forks: 'network'
-};
+ _this.state = {
+ height: props.style && props.style.height || 0,
+ minHeight: -Infinity,
+ maxHeight: Infinity
+ };
+ _this._uid = uid();
+ _this._controlled = typeof props.value === 'string';
+ return _this;
+ }
-var GitHubButton = function (_React$Component) {
- _inherits(GitHubButton, _React$Component);
+ var _proto = TextareaAutosize.prototype;
- function GitHubButton() {
- var _temp, _this, _ret;
+ _proto.render = function render() {
+ var _props = this.props,
+ _inputRef = _props.inputRef,
+ _maxRows = _props.maxRows,
+ _minRows = _props.minRows,
+ _onHeightChange = _props.onHeightChange,
+ _useCacheForDOMMeasurements = _props.useCacheForDOMMeasurements,
+ props = react_textarea_autosize_es_objectWithoutProperties(_props, ["inputRef", "maxRows", "minRows", "onHeightChange", "useCacheForDOMMeasurements"]);
- _classCallCheck(this, GitHubButton);
+ props.style = react_textarea_autosize_es_extends({}, props.style, {
+ height: this.state.height
+ });
+ var maxHeight = Math.max(props.style.maxHeight || Infinity, this.state.maxHeight);
- for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {
- args[_key] = arguments[_key];
+ if (maxHeight < this.state.height) {
+ props.style.overflow = 'hidden';
}
- return _ret = (_temp = (_this = _possibleConstructorReturn(this, _React$Component.call.apply(_React$Component, [this].concat(args))), _this), _this.state = {
- count: null
- }, _temp), _possibleConstructorReturn(_this, _ret);
- }
+ return external_React_default.a.createElement("textarea", react_textarea_autosize_es_extends({}, props, {
+ onChange: this._onChange,
+ ref: this._onRootDOMNode
+ }));
+ };
- GitHubButton.prototype.componentDidMount = function componentDidMount() {
+ _proto.componentDidMount = function componentDidMount() {
var _this2 = this;
- this.xhr = (0, _ajaxGet2["default"])(this.getRequestUrl(), function (response) {
- _this2.setCount(response);
- });
- };
+ this._resizeComponent(); // Working around Firefox bug which runs resize listeners even when other JS is running at the same moment
+ // causing competing rerenders (due to setState in the listener) in React.
+ // More can be found here - facebook/react#6324
- GitHubButton.prototype.componentWillUnmount = function componentWillUnmount() {
- if (this.xhr) {
- this.xhr.abort();
- }
- };
- GitHubButton.prototype.setCount = function setCount(data) {
- if (!data) return;
- var count = data[this.props.type + '_count'];
- this.setState({ count: count });
- };
+ this._resizeListener = function () {
+ if (_this2._resizeLock) {
+ return;
+ }
- GitHubButton.prototype.getRequestUrl = function getRequestUrl() {
- var _props = this.props,
- namespace = _props.namespace,
- repo = _props.repo;
-
- return '//api.github.com/repos/' + namespace + '/' + repo;
- };
+ _this2._resizeLock = true;
- GitHubButton.prototype.getRepoUrl = function getRepoUrl() {
- var _props2 = this.props,
- namespace = _props2.namespace,
- repo = _props2.repo;
+ _this2._resizeComponent(function () {
+ return _this2._resizeLock = false;
+ });
+ };
- return '//github.com/' + namespace + '/' + repo + '/';
+ window.addEventListener('resize', this._resizeListener);
};
- GitHubButton.prototype.getCountUrl = function getCountUrl() {
- var _props3 = this.props,
- namespace = _props3.namespace,
- repo = _props3.repo,
- type = _props3.type;
+ _proto.componentDidUpdate = function componentDidUpdate(prevProps, prevState) {
+ var _this3 = this;
- return '//github.com/' + namespace + '/' + repo + '/' + (typeToPath[type] || type) + '/';
- };
+ if (prevProps !== this.props) {
+ this._clearNextFrame();
- GitHubButton.prototype.getCountStyle = function getCountStyle() {
- var count = this.state.count;
- if (count !== null) {
- return {
- display: 'block'
- };
+ this._onNextFrameActionId = onNextFrame(function () {
+ return _this3._resizeComponent();
+ });
+ }
+
+ if (this.state.height !== prevState.height) {
+ this.props.onHeightChange(this.state.height, this);
}
- return null;
};
- GitHubButton.prototype.render = function render() {
- var _props4 = this.props,
- className = _props4.className,
- type = _props4.type,
- size = _props4.size,
- rest = _objectWithoutProperties(_props4, ['className', 'type', 'size']);
+ _proto.componentWillUnmount = function componentWillUnmount() {
+ this._clearNextFrame();
- delete rest.namespace;
- delete rest.repo;
+ window.removeEventListener('resize', this._resizeListener);
+ purgeCache(this._uid);
+ };
- var count = this.state.count;
+ _proto._clearNextFrame = function _clearNextFrame() {
+ clearNextFrameAction(this._onNextFrameActionId);
+ };
- var buttonClassName = utils.classNames(_defineProperty({
- 'github-btn': true,
- 'github-btn-large': size === 'large'
- }, className, className));
+ return TextareaAutosize;
+}(external_React_default.a.Component);
+
+react_textarea_autosize_es_TextareaAutosize.propTypes = {
+ inputRef: prop_types_default.a.func,
+ maxRows: prop_types_default.a.number,
+ minRows: prop_types_default.a.number,
+ onChange: prop_types_default.a.func,
+ onHeightChange: prop_types_default.a.func,
+ useCacheForDOMMeasurements: prop_types_default.a.bool,
+ value: prop_types_default.a.string
+};
+react_textarea_autosize_es_TextareaAutosize.defaultProps = {
+ inputRef: noop,
+ onChange: noop,
+ onHeightChange: noop,
+ useCacheForDOMMeasurements: false
+};
- return _react2["default"].createElement(
- 'span',
- _extends({}, rest, { className: buttonClassName }),
- _react2["default"].createElement(
- 'a',
- { className: 'gh-btn', href: this.getRepoUrl(), target: '_blank' },
- _react2["default"].createElement('span', { className: 'gh-ico', 'aria-hidden': 'true' }),
- _react2["default"].createElement(
- 'span',
- { className: 'gh-text' },
- typeToLabel[type]
- )
- ),
- _react2["default"].createElement(
- 'a',
- { className: 'gh-count', target: '_blank',
- href: this.getCountUrl(),
- style: this.getCountStyle()
+/* harmony default export */ var react_textarea_autosize_es = (react_textarea_autosize_es_TextareaAutosize);
+
+// CONCATENATED MODULE: ./src/js/helpers/parseInput.js
+function cov_1mrtjfgg40() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/helpers/parseInput.js";
+ var hash = "3d4ea75adeccf5ca9974c2d4f55442292629c460";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/helpers/parseInput.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 6,
+ column: 4
},
- count
- )
- );
+ end: {
+ line: 6,
+ column: 25
+ }
+ },
+ "1": {
+ start: {
+ line: 7,
+ column: 4
+ },
+ end: {
+ line: 42,
+ column: 5
+ }
+ },
+ "2": {
+ start: {
+ line: 8,
+ column: 8
+ },
+ end: {
+ line: 8,
+ column: 50
+ }
+ },
+ "3": {
+ start: {
+ line: 9,
+ column: 8
+ },
+ end: {
+ line: 39,
+ column: 9
+ }
+ },
+ "4": {
+ start: {
+ line: 11,
+ column: 12
+ },
+ end: {
+ line: 11,
+ column: 62
+ }
+ },
+ "5": {
+ start: {
+ line: 12,
+ column: 15
+ },
+ end: {
+ line: 39,
+ column: 9
+ }
+ },
+ "6": {
+ start: {
+ line: 14,
+ column: 12
+ },
+ end: {
+ line: 14,
+ column: 63
+ }
+ },
+ "7": {
+ start: {
+ line: 15,
+ column: 15
+ },
+ end: {
+ line: 39,
+ column: 9
+ }
+ },
+ "8": {
+ start: {
+ line: 20,
+ column: 12
+ },
+ end: {
+ line: 20,
+ column: 62
+ }
+ },
+ "9": {
+ start: {
+ line: 21,
+ column: 15
+ },
+ end: {
+ line: 39,
+ column: 9
+ }
+ },
+ "10": {
+ start: {
+ line: 26,
+ column: 12
+ },
+ end: {
+ line: 26,
+ column: 58
+ }
+ },
+ "11": {
+ start: {
+ line: 27,
+ column: 15
+ },
+ end: {
+ line: 39,
+ column: 9
+ }
+ },
+ "12": {
+ start: {
+ line: 32,
+ column: 12
+ },
+ end: {
+ line: 32,
+ column: 62
+ }
+ },
+ "13": {
+ start: {
+ line: 33,
+ column: 15
+ },
+ end: {
+ line: 39,
+ column: 9
+ }
+ },
+ "14": {
+ start: {
+ line: 38,
+ column: 12
+ },
+ end: {
+ line: 38,
+ column: 60
+ }
+ },
+ "15": {
+ start: {
+ line: 45,
+ column: 4
+ },
+ end: {
+ line: 45,
+ column: 32
+ }
+ },
+ "16": {
+ start: {
+ line: 46,
+ column: 4
+ },
+ end: {
+ line: 69,
+ column: 5
+ }
+ },
+ "17": {
+ start: {
+ line: 48,
+ column: 12
+ },
+ end: {
+ line: 48,
+ column: 58
+ }
+ },
+ "18": {
+ start: {
+ line: 51,
+ column: 12
+ },
+ end: {
+ line: 51,
+ column: 46
+ }
+ },
+ "19": {
+ start: {
+ line: 54,
+ column: 12
+ },
+ end: {
+ line: 54,
+ column: 48
+ }
+ },
+ "20": {
+ start: {
+ line: 57,
+ column: 12
+ },
+ end: {
+ line: 57,
+ column: 51
+ }
+ },
+ "21": {
+ start: {
+ line: 60,
+ column: 12
+ },
+ end: {
+ line: 60,
+ column: 52
+ }
+ },
+ "22": {
+ start: {
+ line: 64,
+ column: 12
+ },
+ end: {
+ line: 64,
+ column: 38
+ }
+ },
+ "23": {
+ start: {
+ line: 65,
+ column: 12
+ },
+ end: {
+ line: 67,
+ column: 13
+ }
+ },
+ "24": {
+ start: {
+ line: 66,
+ column: 16
+ },
+ end: {
+ line: 66,
+ column: 63
+ }
+ },
+ "25": {
+ start: {
+ line: 71,
+ column: 4
+ },
+ end: {
+ line: 71,
+ column: 39
+ }
+ },
+ "26": {
+ start: {
+ line: 75,
+ column: 4
+ },
+ end: {
+ line: 78,
+ column: 6
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "parseInput",
+ decl: {
+ start: {
+ line: 1,
+ column: 24
+ },
+ end: {
+ line: 1,
+ column: 34
+ }
+ },
+ loc: {
+ start: {
+ line: 1,
+ column: 42
+ },
+ end: {
+ line: 72,
+ column: 1
+ }
+ },
+ line: 1
+ },
+ "1": {
+ name: "formatResponse",
+ decl: {
+ start: {
+ line: 74,
+ column: 9
+ },
+ end: {
+ line: 74,
+ column: 23
+ }
+ },
+ loc: {
+ start: {
+ line: 74,
+ column: 37
+ },
+ end: {
+ line: 79,
+ column: 1
+ }
+ },
+ line: 74
+ }
+ },
+ branchMap: {
+ "0": {
+ loc: {
+ start: {
+ line: 9,
+ column: 8
+ },
+ end: {
+ line: 39,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 9,
+ column: 8
+ },
+ end: {
+ line: 39,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 9,
+ column: 8
+ },
+ end: {
+ line: 39,
+ column: 9
+ }
+ }],
+ line: 9
+ },
+ "1": {
+ loc: {
+ start: {
+ line: 12,
+ column: 15
+ },
+ end: {
+ line: 39,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 12,
+ column: 15
+ },
+ end: {
+ line: 39,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 12,
+ column: 15
+ },
+ end: {
+ line: 39,
+ column: 9
+ }
+ }],
+ line: 12
+ },
+ "2": {
+ loc: {
+ start: {
+ line: 15,
+ column: 15
+ },
+ end: {
+ line: 39,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 15,
+ column: 15
+ },
+ end: {
+ line: 39,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 15,
+ column: 15
+ },
+ end: {
+ line: 39,
+ column: 9
+ }
+ }],
+ line: 15
+ },
+ "3": {
+ loc: {
+ start: {
+ line: 16,
+ column: 12
+ },
+ end: {
+ line: 17,
+ column: 51
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 16,
+ column: 12
+ },
+ end: {
+ line: 16,
+ column: 38
+ }
+ }, {
+ start: {
+ line: 17,
+ column: 12
+ },
+ end: {
+ line: 17,
+ column: 51
+ }
+ }],
+ line: 16
+ },
+ "4": {
+ loc: {
+ start: {
+ line: 21,
+ column: 15
+ },
+ end: {
+ line: 39,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 21,
+ column: 15
+ },
+ end: {
+ line: 39,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 21,
+ column: 15
+ },
+ end: {
+ line: 39,
+ column: 9
+ }
+ }],
+ line: 21
+ },
+ "5": {
+ loc: {
+ start: {
+ line: 22,
+ column: 12
+ },
+ end: {
+ line: 23,
+ column: 51
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 22,
+ column: 12
+ },
+ end: {
+ line: 22,
+ column: 38
+ }
+ }, {
+ start: {
+ line: 23,
+ column: 12
+ },
+ end: {
+ line: 23,
+ column: 51
+ }
+ }],
+ line: 22
+ },
+ "6": {
+ loc: {
+ start: {
+ line: 27,
+ column: 15
+ },
+ end: {
+ line: 39,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 27,
+ column: 15
+ },
+ end: {
+ line: 39,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 27,
+ column: 15
+ },
+ end: {
+ line: 39,
+ column: 9
+ }
+ }],
+ line: 27
+ },
+ "7": {
+ loc: {
+ start: {
+ line: 28,
+ column: 12
+ },
+ end: {
+ line: 29,
+ column: 46
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 28,
+ column: 12
+ },
+ end: {
+ line: 28,
+ column: 33
+ }
+ }, {
+ start: {
+ line: 29,
+ column: 12
+ },
+ end: {
+ line: 29,
+ column: 46
+ }
+ }],
+ line: 28
+ },
+ "8": {
+ loc: {
+ start: {
+ line: 33,
+ column: 15
+ },
+ end: {
+ line: 39,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 33,
+ column: 15
+ },
+ end: {
+ line: 39,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 33,
+ column: 15
+ },
+ end: {
+ line: 39,
+ column: 9
+ }
+ }],
+ line: 33
+ },
+ "9": {
+ loc: {
+ start: {
+ line: 34,
+ column: 12
+ },
+ end: {
+ line: 35,
+ column: 52
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 34,
+ column: 12
+ },
+ end: {
+ line: 34,
+ column: 39
+ }
+ }, {
+ start: {
+ line: 35,
+ column: 12
+ },
+ end: {
+ line: 35,
+ column: 52
+ }
+ }],
+ line: 34
+ },
+ "10": {
+ loc: {
+ start: {
+ line: 46,
+ column: 4
+ },
+ end: {
+ line: 69,
+ column: 5
+ }
+ },
+ type: "switch",
+ locations: [{
+ start: {
+ line: 47,
+ column: 8
+ },
+ end: {
+ line: 49,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 50,
+ column: 8
+ },
+ end: {
+ line: 52,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 53,
+ column: 8
+ },
+ end: {
+ line: 55,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 56,
+ column: 8
+ },
+ end: {
+ line: 58,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 59,
+ column: 8
+ },
+ end: {
+ line: 61,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 62,
+ column: 8
+ },
+ end: {
+ line: 68,
+ column: 9
+ }
+ }],
+ line: 46
+ },
+ "11": {
+ loc: {
+ start: {
+ line: 65,
+ column: 12
+ },
+ end: {
+ line: 67,
+ column: 13
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 65,
+ column: 12
+ },
+ end: {
+ line: 67,
+ column: 13
+ }
+ }, {
+ start: {
+ line: 65,
+ column: 12
+ },
+ end: {
+ line: 67,
+ column: 13
+ }
+ }],
+ line: 65
+ }
+ },
+ s: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0,
+ "7": 0,
+ "8": 0,
+ "9": 0,
+ "10": 0,
+ "11": 0,
+ "12": 0,
+ "13": 0,
+ "14": 0,
+ "15": 0,
+ "16": 0,
+ "17": 0,
+ "18": 0,
+ "19": 0,
+ "20": 0,
+ "21": 0,
+ "22": 0,
+ "23": 0,
+ "24": 0,
+ "25": 0,
+ "26": 0
+ },
+ f: {
+ "0": 0,
+ "1": 0
+ },
+ b: {
+ "0": [0, 0],
+ "1": [0, 0],
+ "2": [0, 0],
+ "3": [0, 0],
+ "4": [0, 0],
+ "5": [0, 0],
+ "6": [0, 0],
+ "7": [0, 0],
+ "8": [0, 0],
+ "9": [0, 0],
+ "10": [0, 0, 0, 0, 0, 0],
+ "11": [0, 0]
+ },
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "3d4ea75adeccf5ca9974c2d4f55442292629c460"
};
+ var coverage = global[gcv] || (global[gcv] = {});
- return GitHubButton;
-}(_react2["default"].Component);
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
-GitHubButton.displayName = 'GitHubButton';
-GitHubButton.propTypes = {
- className: _propTypes2["default"].string,
- type: _propTypes2["default"].oneOf(['stargazers', 'watchers', 'forks']).isRequired,
- namespace: _propTypes2["default"].string.isRequired,
- repo: _propTypes2["default"].string.isRequired,
- size: _propTypes2["default"].oneOf(['large'])
-};
-exports["default"] = GitHubButton;
-module.exports = exports['default'];
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_1mrtjfgg40 = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
-/***/ }),
-/* 190 */
-/***/ (function(module, exports, __webpack_require__) {
+cov_1mrtjfgg40();
+function parseInput(input) {
+ cov_1mrtjfgg40().f[0]++;
+ cov_1mrtjfgg40().s[0]++;
+ //following code is to make a best guess at
+ //the type for a variable being submitted.
+ //we are working with a serialized data representation
+ input = input.trim();
+ cov_1mrtjfgg40().s[1]++;
-"use strict";
+ try {
+ cov_1mrtjfgg40().s[2]++;
+ input = JSON.stringify(JSON.parse(input));
+ cov_1mrtjfgg40().s[3]++;
+
+ if (input[0] === '[') {
+ cov_1mrtjfgg40().b[0][0]++;
+ cov_1mrtjfgg40().s[4]++;
+ //array
+ return formatResponse('array', JSON.parse(input));
+ } else {
+ cov_1mrtjfgg40().b[0][1]++;
+ cov_1mrtjfgg40().s[5]++;
+
+ if (input[0] === '{') {
+ cov_1mrtjfgg40().b[1][0]++;
+ cov_1mrtjfgg40().s[6]++;
+ //object
+ return formatResponse('object', JSON.parse(input));
+ } else {
+ cov_1mrtjfgg40().b[1][1]++;
+ cov_1mrtjfgg40().s[7]++;
+
+ if ((cov_1mrtjfgg40().b[3][0]++, input.match(/\-?\d+\.\d+/)) && (cov_1mrtjfgg40().b[3][1]++, input.match(/\-?\d+\.\d+/)[0] === input)) {
+ cov_1mrtjfgg40().b[2][0]++;
+ cov_1mrtjfgg40().s[8]++;
+ //float
+ return formatResponse('float', parseFloat(input));
+ } else {
+ cov_1mrtjfgg40().b[2][1]++;
+ cov_1mrtjfgg40().s[9]++;
+
+ if ((cov_1mrtjfgg40().b[5][0]++, input.match(/\-?\d+e-\d+/)) && (cov_1mrtjfgg40().b[5][1]++, input.match(/\-?\d+e-\d+/)[0] === input)) {
+ cov_1mrtjfgg40().b[4][0]++;
+ cov_1mrtjfgg40().s[10]++;
+ //scientific float
+ return formatResponse('float', Number(input));
+ } else {
+ cov_1mrtjfgg40().b[4][1]++;
+ cov_1mrtjfgg40().s[11]++;
+
+ if ((cov_1mrtjfgg40().b[7][0]++, input.match(/\-?\d+/)) && (cov_1mrtjfgg40().b[7][1]++, input.match(/\-?\d+/)[0] === input)) {
+ cov_1mrtjfgg40().b[6][0]++;
+ cov_1mrtjfgg40().s[12]++;
+ //integer
+ return formatResponse('integer', parseInt(input));
+ } else {
+ cov_1mrtjfgg40().b[6][1]++;
+ cov_1mrtjfgg40().s[13]++;
+
+ if ((cov_1mrtjfgg40().b[9][0]++, input.match(/\-?\d+e\+\d+/)) && (cov_1mrtjfgg40().b[9][1]++, input.match(/\-?\d+e\+\d+/)[0] === input)) {
+ cov_1mrtjfgg40().b[8][0]++;
+ cov_1mrtjfgg40().s[14]++;
+ //scientific integer
+ return formatResponse('integer', Number(input));
+ } else {
+ cov_1mrtjfgg40().b[8][1]++;
+ }
+ }
+ }
+ }
+ }
+ }
+ } catch (e) {// no-op
+ } //run in case input was not serializable
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
-exports["default"] = ajaxGet;
-function ajaxGet(url, callback) {
- if (typeof XDomainRequest !== 'undefined') {
- callback(null);
- return null;
- }
+ cov_1mrtjfgg40().s[15]++;
+ input = input.toLowerCase();
+ cov_1mrtjfgg40().s[16]++;
- var xhr = new XMLHttpRequest();
- xhr.onreadystatechange = function () {
- if (xhr.readyState === XMLHttpRequest.DONE && xhr.status === 200) {
- callback(JSON.parse(xhr.responseText));
- }
+ switch (input) {
+ case 'undefined':
+ cov_1mrtjfgg40().b[10][0]++;
+ {
+ cov_1mrtjfgg40().s[17]++;
+ return formatResponse('undefined', undefined);
+ }
+
+ case 'nan':
+ cov_1mrtjfgg40().b[10][1]++;
+ {
+ cov_1mrtjfgg40().s[18]++;
+ return formatResponse('nan', NaN);
+ }
+
+ case 'null':
+ cov_1mrtjfgg40().b[10][2]++;
+ {
+ cov_1mrtjfgg40().s[19]++;
+ return formatResponse('null', null);
+ }
+
+ case 'true':
+ cov_1mrtjfgg40().b[10][3]++;
+ {
+ cov_1mrtjfgg40().s[20]++;
+ return formatResponse('boolean', true);
+ }
+
+ case 'false':
+ cov_1mrtjfgg40().b[10][4]++;
+ {
+ cov_1mrtjfgg40().s[21]++;
+ return formatResponse('boolean', false);
+ }
+
+ default:
+ cov_1mrtjfgg40().b[10][5]++;
+ {
+ cov_1mrtjfgg40().s[22]++;
+ //check to see if this is a date
+ input = Date.parse(input);
+ cov_1mrtjfgg40().s[23]++;
+
+ if (input) {
+ cov_1mrtjfgg40().b[11][0]++;
+ cov_1mrtjfgg40().s[24]++;
+ return formatResponse('date', new Date(input));
+ } else {
+ cov_1mrtjfgg40().b[11][1]++;
+ }
+ }
+ }
+
+ cov_1mrtjfgg40().s[25]++;
+ return formatResponse(false, null);
+}
+
+function formatResponse(type, value) {
+ cov_1mrtjfgg40().f[1]++;
+ cov_1mrtjfgg40().s[26]++;
+ return {
+ type: type,
+ value: value
+ };
+}
+// CONCATENATED MODULE: ./src/js/helpers/stringifyVariable.js
+function cov_1w6fh64ele() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/helpers/stringifyVariable.js";
+ var hash = "266b7221c7dc27fc7a6bb1487826e67f9e92e661";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/helpers/stringifyVariable.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 4,
+ column: 17
+ },
+ end: {
+ line: 4,
+ column: 30
+ }
+ },
+ "1": {
+ start: {
+ line: 6,
+ column: 4
+ },
+ end: {
+ line: 33,
+ column: 5
+ }
+ },
+ "2": {
+ start: {
+ line: 8,
+ column: 12
+ },
+ end: {
+ line: 8,
+ column: 39
+ }
+ },
+ "3": {
+ start: {
+ line: 9,
+ column: 12
+ },
+ end: {
+ line: 9,
+ column: 18
+ }
+ },
+ "4": {
+ start: {
+ line: 12,
+ column: 12
+ },
+ end: {
+ line: 12,
+ column: 33
+ }
+ },
+ "5": {
+ start: {
+ line: 13,
+ column: 12
+ },
+ end: {
+ line: 13,
+ column: 18
+ }
+ },
+ "6": {
+ start: {
+ line: 15,
+ column: 12
+ },
+ end: {
+ line: 15,
+ column: 33
+ }
+ },
+ "7": {
+ start: {
+ line: 16,
+ column: 12
+ },
+ end: {
+ line: 16,
+ column: 18
+ }
+ },
+ "8": {
+ start: {
+ line: 18,
+ column: 12
+ },
+ end: {
+ line: 18,
+ column: 44
+ }
+ },
+ "9": {
+ start: {
+ line: 19,
+ column: 12
+ },
+ end: {
+ line: 19,
+ column: 18
+ }
+ },
+ "10": {
+ start: {
+ line: 21,
+ column: 12
+ },
+ end: {
+ line: 21,
+ column: 44
+ }
+ },
+ "11": {
+ start: {
+ line: 22,
+ column: 12
+ },
+ end: {
+ line: 22,
+ column: 18
+ }
+ },
+ "12": {
+ start: {
+ line: 24,
+ column: 12
+ },
+ end: {
+ line: 24,
+ column: 44
+ }
+ },
+ "13": {
+ start: {
+ line: 25,
+ column: 12
+ },
+ end: {
+ line: 25,
+ column: 18
+ }
+ },
+ "14": {
+ start: {
+ line: 27,
+ column: 12
+ },
+ end: {
+ line: 31,
+ column: 13
+ }
+ },
+ "15": {
+ start: {
+ line: 28,
+ column: 16
+ },
+ end: {
+ line: 28,
+ column: 65
+ }
+ },
+ "16": {
+ start: {
+ line: 30,
+ column: 16
+ },
+ end: {
+ line: 30,
+ column: 34
+ }
+ },
+ "17": {
+ start: {
+ line: 35,
+ column: 4
+ },
+ end: {
+ line: 35,
+ column: 24
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "(anonymous_0)",
+ decl: {
+ start: {
+ line: 3,
+ column: 15
+ },
+ end: {
+ line: 3,
+ column: 16
+ }
+ },
+ loc: {
+ start: {
+ line: 3,
+ column: 24
+ },
+ end: {
+ line: 36,
+ column: 1
+ }
+ },
+ line: 3
+ }
+ },
+ branchMap: {
+ "0": {
+ loc: {
+ start: {
+ line: 6,
+ column: 4
+ },
+ end: {
+ line: 33,
+ column: 5
+ }
+ },
+ type: "switch",
+ locations: [{
+ start: {
+ line: 7,
+ column: 8
+ },
+ end: {
+ line: 10,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 11,
+ column: 8
+ },
+ end: {
+ line: 13,
+ column: 18
+ }
+ }, {
+ start: {
+ line: 14,
+ column: 8
+ },
+ end: {
+ line: 16,
+ column: 18
+ }
+ }, {
+ start: {
+ line: 17,
+ column: 8
+ },
+ end: {
+ line: 19,
+ column: 18
+ }
+ }, {
+ start: {
+ line: 20,
+ column: 8
+ },
+ end: {
+ line: 22,
+ column: 18
+ }
+ }, {
+ start: {
+ line: 23,
+ column: 8
+ },
+ end: {
+ line: 25,
+ column: 18
+ }
+ }, {
+ start: {
+ line: 26,
+ column: 8
+ },
+ end: {
+ line: 32,
+ column: 9
+ }
+ }],
+ line: 6
+ }
+ },
+ s: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0,
+ "7": 0,
+ "8": 0,
+ "9": 0,
+ "10": 0,
+ "11": 0,
+ "12": 0,
+ "13": 0,
+ "14": 0,
+ "15": 0,
+ "16": 0,
+ "17": 0
+ },
+ f: {
+ "0": 0
+ },
+ b: {
+ "0": [0, 0, 0, 0, 0, 0, 0]
+ },
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "266b7221c7dc27fc7a6bb1487826e67f9e92e661"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
+
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
+
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_1w6fh64ele = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
+
+cov_1w6fh64ele();
+
+/* harmony default export */ var stringifyVariable = (function (value) {
+ cov_1w6fh64ele().f[0]++;
+ var type = (cov_1w6fh64ele().s[0]++, toType(value));
+ var string_value;
+ cov_1w6fh64ele().s[1]++;
+
+ switch (type) {
+ case 'undefined':
+ cov_1w6fh64ele().b[0][0]++;
+ {
+ cov_1w6fh64ele().s[2]++;
+ string_value = 'undefined';
+ cov_1w6fh64ele().s[3]++;
+ break;
+ }
+
+ case 'nan':
+ cov_1w6fh64ele().b[0][1]++;
+ cov_1w6fh64ele().s[4]++;
+ string_value = 'NaN';
+ cov_1w6fh64ele().s[5]++;
+ break;
+
+ case 'string':
+ cov_1w6fh64ele().b[0][2]++;
+ cov_1w6fh64ele().s[6]++;
+ string_value = value;
+ cov_1w6fh64ele().s[7]++;
+ break;
+
+ case 'date':
+ cov_1w6fh64ele().b[0][3]++;
+ cov_1w6fh64ele().s[8]++;
+ string_value = value.toString();
+ cov_1w6fh64ele().s[9]++;
+ break;
+
+ case 'function':
+ cov_1w6fh64ele().b[0][4]++;
+ cov_1w6fh64ele().s[10]++;
+ string_value = value.toString();
+ cov_1w6fh64ele().s[11]++;
+ break;
+
+ case 'regexp':
+ cov_1w6fh64ele().b[0][5]++;
+ cov_1w6fh64ele().s[12]++;
+ string_value = value.toString();
+ cov_1w6fh64ele().s[13]++;
+ break;
+
+ default:
+ cov_1w6fh64ele().b[0][6]++;
+ {
+ cov_1w6fh64ele().s[14]++;
+
+ try {
+ cov_1w6fh64ele().s[15]++;
+ string_value = JSON.stringify(value, null, ' ');
+ } catch (e) {
+ cov_1w6fh64ele().s[16]++;
+ string_value = '';
+ }
+ }
+ }
+
+ cov_1w6fh64ele().s[17]++;
+ return string_value;
+});
+// CONCATENATED MODULE: ./src/js/components/icons.js
+
+
+
+
+
+
+
+function cov_1a7hkspd76() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/components/icons.js";
+ var hash = "88b835750854bad6948f6d059e181f52afe0914a";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/components/icons.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 3,
+ column: 22
+ },
+ end: {
+ line: 3,
+ column: 24
+ }
+ },
+ "1": {
+ start: {
+ line: 4,
+ column: 23
+ },
+ end: {
+ line: 4,
+ column: 25
+ }
+ },
+ "2": {
+ start: {
+ line: 5,
+ column: 22
+ },
+ end: {
+ line: 5,
+ column: 31
+ }
+ },
+ "3": {
+ start: {
+ line: 9,
+ column: 26
+ },
+ end: {
+ line: 9,
+ column: 30
+ }
+ },
+ "4": {
+ start: {
+ line: 10,
+ column: 35
+ },
+ end: {
+ line: 10,
+ column: 40
+ }
+ },
+ "5": {
+ start: {
+ line: 12,
+ column: 8
+ },
+ end: {
+ line: 23,
+ column: 10
+ }
+ },
+ "6": {
+ start: {
+ line: 29,
+ column: 26
+ },
+ end: {
+ line: 29,
+ column: 30
+ }
+ },
+ "7": {
+ start: {
+ line: 30,
+ column: 35
+ },
+ end: {
+ line: 30,
+ column: 40
+ }
+ },
+ "8": {
+ start: {
+ line: 32,
+ column: 8
+ },
+ end: {
+ line: 43,
+ column: 10
+ }
+ },
+ "9": {
+ start: {
+ line: 49,
+ column: 26
+ },
+ end: {
+ line: 49,
+ column: 30
+ }
+ },
+ "10": {
+ start: {
+ line: 50,
+ column: 35
+ },
+ end: {
+ line: 50,
+ column: 40
+ }
+ },
+ "11": {
+ start: {
+ line: 51,
+ column: 25
+ },
+ end: {
+ line: 51,
+ column: 50
+ }
+ },
+ "12": {
+ start: {
+ line: 53,
+ column: 8
+ },
+ end: {
+ line: 65,
+ column: 10
+ }
+ },
+ "13": {
+ start: {
+ line: 71,
+ column: 26
+ },
+ end: {
+ line: 71,
+ column: 30
+ }
+ },
+ "14": {
+ start: {
+ line: 72,
+ column: 35
+ },
+ end: {
+ line: 72,
+ column: 40
+ }
+ },
+ "15": {
+ start: {
+ line: 73,
+ column: 25
+ },
+ end: {
+ line: 73,
+ column: 50
+ }
+ },
+ "16": {
+ start: {
+ line: 75,
+ column: 8
+ },
+ end: {
+ line: 87,
+ column: 10
+ }
+ },
+ "17": {
+ start: {
+ line: 93,
+ column: 26
+ },
+ end: {
+ line: 93,
+ column: 30
+ }
+ },
+ "18": {
+ start: {
+ line: 94,
+ column: 35
+ },
+ end: {
+ line: 94,
+ column: 40
+ }
+ },
+ "19": {
+ start: {
+ line: 96,
+ column: 8
+ },
+ end: {
+ line: 110,
+ column: 10
+ }
+ },
+ "20": {
+ start: {
+ line: 116,
+ column: 26
+ },
+ end: {
+ line: 116,
+ column: 30
+ }
+ },
+ "21": {
+ start: {
+ line: 117,
+ column: 35
+ },
+ end: {
+ line: 117,
+ column: 40
+ }
+ },
+ "22": {
+ start: {
+ line: 119,
+ column: 8
+ },
+ end: {
+ line: 133,
+ column: 10
+ }
+ },
+ "23": {
+ start: {
+ line: 139,
+ column: 26
+ },
+ end: {
+ line: 139,
+ column: 30
+ }
+ },
+ "24": {
+ start: {
+ line: 140,
+ column: 35
+ },
+ end: {
+ line: 140,
+ column: 40
+ }
+ },
+ "25": {
+ start: {
+ line: 142,
+ column: 8
+ },
+ end: {
+ line: 155,
+ column: 10
+ }
+ },
+ "26": {
+ start: {
+ line: 161,
+ column: 26
+ },
+ end: {
+ line: 161,
+ column: 30
+ }
+ },
+ "27": {
+ start: {
+ line: 162,
+ column: 35
+ },
+ end: {
+ line: 162,
+ column: 40
+ }
+ },
+ "28": {
+ start: {
+ line: 164,
+ column: 8
+ },
+ end: {
+ line: 177,
+ column: 10
+ }
+ },
+ "29": {
+ start: {
+ line: 183,
+ column: 26
+ },
+ end: {
+ line: 183,
+ column: 30
+ }
+ },
+ "30": {
+ start: {
+ line: 184,
+ column: 35
+ },
+ end: {
+ line: 184,
+ column: 40
+ }
+ },
+ "31": {
+ start: {
+ line: 186,
+ column: 8
+ },
+ end: {
+ line: 199,
+ column: 10
+ }
+ },
+ "32": {
+ start: {
+ line: 205,
+ column: 26
+ },
+ end: {
+ line: 205,
+ column: 30
+ }
+ },
+ "33": {
+ start: {
+ line: 206,
+ column: 35
+ },
+ end: {
+ line: 206,
+ column: 40
+ }
+ },
+ "34": {
+ start: {
+ line: 208,
+ column: 8
+ },
+ end: {
+ line: 221,
+ column: 10
+ }
+ },
+ "35": {
+ start: {
+ line: 227,
+ column: 26
+ },
+ end: {
+ line: 227,
+ column: 30
+ }
+ },
+ "36": {
+ start: {
+ line: 228,
+ column: 35
+ },
+ end: {
+ line: 228,
+ column: 40
+ }
+ },
+ "37": {
+ start: {
+ line: 230,
+ column: 8
+ },
+ end: {
+ line: 243,
+ column: 10
+ }
+ },
+ "38": {
+ start: {
+ line: 249,
+ column: 26
+ },
+ end: {
+ line: 249,
+ column: 30
+ }
+ },
+ "39": {
+ start: {
+ line: 250,
+ column: 35
+ },
+ end: {
+ line: 250,
+ column: 40
+ }
+ },
+ "40": {
+ start: {
+ line: 252,
+ column: 8
+ },
+ end: {
+ line: 265,
+ column: 10
+ }
+ },
+ "41": {
+ start: {
+ line: 270,
+ column: 4
+ },
+ end: {
+ line: 272,
+ column: 5
+ }
+ },
+ "42": {
+ start: {
+ line: 271,
+ column: 8
+ },
+ end: {
+ line: 271,
+ column: 19
+ }
+ },
+ "43": {
+ start: {
+ line: 273,
+ column: 4
+ },
+ end: {
+ line: 281,
+ column: 6
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "(anonymous_0)",
+ decl: {
+ start: {
+ line: 8,
+ column: 4
+ },
+ end: {
+ line: 8,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 8,
+ column: 13
+ },
+ end: {
+ line: 24,
+ column: 5
+ }
+ },
+ line: 8
+ },
+ "1": {
+ name: "(anonymous_1)",
+ decl: {
+ start: {
+ line: 28,
+ column: 4
+ },
+ end: {
+ line: 28,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 28,
+ column: 13
+ },
+ end: {
+ line: 44,
+ column: 5
+ }
+ },
+ line: 28
+ },
+ "2": {
+ name: "(anonymous_2)",
+ decl: {
+ start: {
+ line: 48,
+ column: 4
+ },
+ end: {
+ line: 48,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 48,
+ column: 13
+ },
+ end: {
+ line: 66,
+ column: 5
+ }
+ },
+ line: 48
+ },
+ "3": {
+ name: "(anonymous_3)",
+ decl: {
+ start: {
+ line: 70,
+ column: 4
+ },
+ end: {
+ line: 70,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 70,
+ column: 13
+ },
+ end: {
+ line: 88,
+ column: 5
+ }
+ },
+ line: 70
+ },
+ "4": {
+ name: "(anonymous_4)",
+ decl: {
+ start: {
+ line: 92,
+ column: 4
+ },
+ end: {
+ line: 92,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 92,
+ column: 13
+ },
+ end: {
+ line: 111,
+ column: 5
+ }
+ },
+ line: 92
+ },
+ "5": {
+ name: "(anonymous_5)",
+ decl: {
+ start: {
+ line: 115,
+ column: 4
+ },
+ end: {
+ line: 115,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 115,
+ column: 13
+ },
+ end: {
+ line: 134,
+ column: 5
+ }
+ },
+ line: 115
+ },
+ "6": {
+ name: "(anonymous_6)",
+ decl: {
+ start: {
+ line: 138,
+ column: 4
+ },
+ end: {
+ line: 138,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 138,
+ column: 13
+ },
+ end: {
+ line: 156,
+ column: 5
+ }
+ },
+ line: 138
+ },
+ "7": {
+ name: "(anonymous_7)",
+ decl: {
+ start: {
+ line: 160,
+ column: 4
+ },
+ end: {
+ line: 160,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 160,
+ column: 13
+ },
+ end: {
+ line: 178,
+ column: 5
+ }
+ },
+ line: 160
+ },
+ "8": {
+ name: "(anonymous_8)",
+ decl: {
+ start: {
+ line: 182,
+ column: 4
+ },
+ end: {
+ line: 182,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 182,
+ column: 13
+ },
+ end: {
+ line: 200,
+ column: 5
+ }
+ },
+ line: 182
+ },
+ "9": {
+ name: "(anonymous_9)",
+ decl: {
+ start: {
+ line: 204,
+ column: 4
+ },
+ end: {
+ line: 204,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 204,
+ column: 13
+ },
+ end: {
+ line: 222,
+ column: 5
+ }
+ },
+ line: 204
+ },
+ "10": {
+ name: "(anonymous_10)",
+ decl: {
+ start: {
+ line: 226,
+ column: 4
+ },
+ end: {
+ line: 226,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 226,
+ column: 13
+ },
+ end: {
+ line: 244,
+ column: 5
+ }
+ },
+ line: 226
+ },
+ "11": {
+ name: "(anonymous_11)",
+ decl: {
+ start: {
+ line: 248,
+ column: 4
+ },
+ end: {
+ line: 248,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 248,
+ column: 13
+ },
+ end: {
+ line: 266,
+ column: 5
+ }
+ },
+ line: 248
+ },
+ "12": {
+ name: "getIconStyle",
+ decl: {
+ start: {
+ line: 269,
+ column: 9
+ },
+ end: {
+ line: 269,
+ column: 21
+ }
+ },
+ loc: {
+ start: {
+ line: 269,
+ column: 29
+ },
+ end: {
+ line: 282,
+ column: 1
+ }
+ },
+ line: 269
+ }
+ },
+ branchMap: {
+ "0": {
+ loc: {
+ start: {
+ line: 270,
+ column: 4
+ },
+ end: {
+ line: 272,
+ column: 5
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 270,
+ column: 4
+ },
+ end: {
+ line: 272,
+ column: 5
+ }
+ }, {
+ start: {
+ line: 270,
+ column: 4
+ },
+ end: {
+ line: 272,
+ column: 5
+ }
+ }],
+ line: 270
+ },
+ "1": {
+ loc: {
+ start: {
+ line: 277,
+ column: 19
+ },
+ end: {
+ line: 277,
+ column: 60
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 277,
+ column: 33
+ },
+ end: {
+ line: 277,
+ column: 44
+ }
+ }, {
+ start: {
+ line: 277,
+ column: 47
+ },
+ end: {
+ line: 277,
+ column: 60
+ }
+ }],
+ line: 277
+ }
+ },
+ s: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0,
+ "7": 0,
+ "8": 0,
+ "9": 0,
+ "10": 0,
+ "11": 0,
+ "12": 0,
+ "13": 0,
+ "14": 0,
+ "15": 0,
+ "16": 0,
+ "17": 0,
+ "18": 0,
+ "19": 0,
+ "20": 0,
+ "21": 0,
+ "22": 0,
+ "23": 0,
+ "24": 0,
+ "25": 0,
+ "26": 0,
+ "27": 0,
+ "28": 0,
+ "29": 0,
+ "30": 0,
+ "31": 0,
+ "32": 0,
+ "33": 0,
+ "34": 0,
+ "35": 0,
+ "36": 0,
+ "37": 0,
+ "38": 0,
+ "39": 0,
+ "40": 0,
+ "41": 0,
+ "42": 0,
+ "43": 0
+ },
+ f: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0,
+ "7": 0,
+ "8": 0,
+ "9": 0,
+ "10": 0,
+ "11": 0,
+ "12": 0
+ },
+ b: {
+ "0": [0, 0],
+ "1": [0, 0]
+ },
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "88b835750854bad6948f6d059e181f52afe0914a"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
+
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
+
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_1a7hkspd76 = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
+
+cov_1a7hkspd76();
+
+var DEFAULT_WIDTH = (cov_1a7hkspd76().s[0]++, 24);
+var DEFAULT_HEIGHT = (cov_1a7hkspd76().s[1]++, 24);
+var DEFAULT_COLOR = (cov_1a7hkspd76().s[2]++, '#000000');
+var icons_CircleMinus = /*#__PURE__*/function (_React$PureComponent) {
+ _inherits(CircleMinus, _React$PureComponent);
+
+ var _super = _createSuper(CircleMinus);
+
+ function CircleMinus() {
+ _classCallCheck(this, CircleMinus);
+
+ return _super.apply(this, arguments);
+ }
+
+ _createClass(CircleMinus, [{
+ key: "render",
+ value: function render() {
+ cov_1a7hkspd76().f[0]++;
+
+ var _ref = (cov_1a7hkspd76().s[3]++, this),
+ props = _ref.props;
+
+ var _ref2 = (cov_1a7hkspd76().s[4]++, props),
+ style = _ref2.style,
+ rest = _objectWithoutProperties(_ref2, ["style"]);
+
+ cov_1a7hkspd76().s[5]++;
+ return /*#__PURE__*/external_React_default.a.createElement("span", rest, /*#__PURE__*/external_React_default.a.createElement("svg", Object.assign({}, getIconStyle(style), {
+ viewBox: "0 0 24 24",
+ fill: "currentColor",
+ preserveAspectRatio: "xMidYMid meet"
+ }), /*#__PURE__*/external_React_default.a.createElement("path", {
+ d: "M12,20C7.59,20 4,16.41 4,12C4,7.59 7.59,4 12,4C16.41,4 20,7.59 20,12C20,16.41 16.41,20 12,20M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2M7,13H17V11H7"
+ })));
+ }
+ }]);
+
+ return CircleMinus;
+}((external_React_default.a.PureComponent));
+var icons_CirclePlus = /*#__PURE__*/function (_React$PureComponent2) {
+ _inherits(CirclePlus, _React$PureComponent2);
+
+ var _super2 = _createSuper(CirclePlus);
+
+ function CirclePlus() {
+ _classCallCheck(this, CirclePlus);
+
+ return _super2.apply(this, arguments);
+ }
+
+ _createClass(CirclePlus, [{
+ key: "render",
+ value: function render() {
+ cov_1a7hkspd76().f[1]++;
+
+ var _ref3 = (cov_1a7hkspd76().s[6]++, this),
+ props = _ref3.props;
+
+ var _ref4 = (cov_1a7hkspd76().s[7]++, props),
+ style = _ref4.style,
+ rest = _objectWithoutProperties(_ref4, ["style"]);
+
+ cov_1a7hkspd76().s[8]++;
+ return /*#__PURE__*/external_React_default.a.createElement("span", rest, /*#__PURE__*/external_React_default.a.createElement("svg", Object.assign({}, getIconStyle(style), {
+ viewBox: "0 0 24 24",
+ fill: "currentColor",
+ preserveAspectRatio: "xMidYMid meet"
+ }), /*#__PURE__*/external_React_default.a.createElement("path", {
+ d: "M12,20C7.59,20 4,16.41 4,12C4,7.59 7.59,4 12,4C16.41,4 20,7.59 20,12C20,16.41 16.41,20 12,20M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2M13,7H11V11H7V13H11V17H13V13H17V11H13V7Z"
+ })));
+ }
+ }]);
+
+ return CirclePlus;
+}((external_React_default.a.PureComponent));
+var icons_SquareMinus = /*#__PURE__*/function (_React$PureComponent3) {
+ _inherits(SquareMinus, _React$PureComponent3);
+
+ var _super3 = _createSuper(SquareMinus);
+
+ function SquareMinus() {
+ _classCallCheck(this, SquareMinus);
+
+ return _super3.apply(this, arguments);
+ }
+
+ _createClass(SquareMinus, [{
+ key: "render",
+ value: function render() {
+ cov_1a7hkspd76().f[2]++;
+
+ var _ref5 = (cov_1a7hkspd76().s[9]++, this),
+ props = _ref5.props;
+
+ var _ref6 = (cov_1a7hkspd76().s[10]++, props),
+ style = _ref6.style,
+ rest = _objectWithoutProperties(_ref6, ["style"]);
+
+ var svgStyle = (cov_1a7hkspd76().s[11]++, getIconStyle(style).style);
+ cov_1a7hkspd76().s[12]++;
+ return /*#__PURE__*/external_React_default.a.createElement("span", rest, /*#__PURE__*/external_React_default.a.createElement("svg", {
+ fill: svgStyle.color,
+ width: svgStyle.height,
+ height: svgStyle.width,
+ style: svgStyle,
+ viewBox: "0 0 1792 1792"
+ }, /*#__PURE__*/external_React_default.a.createElement("path", {
+ d: "M1344 800v64q0 14-9 23t-23 9h-832q-14 0-23-9t-9-23v-64q0-14 9-23t23-9h832q14 0 23 9t9 23zm128 448v-832q0-66-47-113t-113-47h-832q-66 0-113 47t-47 113v832q0 66 47 113t113 47h832q66 0 113-47t47-113zm128-832v832q0 119-84.5 203.5t-203.5 84.5h-832q-119 0-203.5-84.5t-84.5-203.5v-832q0-119 84.5-203.5t203.5-84.5h832q119 0 203.5 84.5t84.5 203.5z"
+ })));
+ }
+ }]);
+
+ return SquareMinus;
+}((external_React_default.a.PureComponent));
+var icons_SquarePlus = /*#__PURE__*/function (_React$PureComponent4) {
+ _inherits(SquarePlus, _React$PureComponent4);
+
+ var _super4 = _createSuper(SquarePlus);
+
+ function SquarePlus() {
+ _classCallCheck(this, SquarePlus);
+
+ return _super4.apply(this, arguments);
+ }
+
+ _createClass(SquarePlus, [{
+ key: "render",
+ value: function render() {
+ cov_1a7hkspd76().f[3]++;
+
+ var _ref7 = (cov_1a7hkspd76().s[13]++, this),
+ props = _ref7.props;
+
+ var _ref8 = (cov_1a7hkspd76().s[14]++, props),
+ style = _ref8.style,
+ rest = _objectWithoutProperties(_ref8, ["style"]);
+
+ var svgStyle = (cov_1a7hkspd76().s[15]++, getIconStyle(style).style);
+ cov_1a7hkspd76().s[16]++;
+ return /*#__PURE__*/external_React_default.a.createElement("span", rest, /*#__PURE__*/external_React_default.a.createElement("svg", {
+ fill: svgStyle.color,
+ width: svgStyle.height,
+ height: svgStyle.width,
+ style: svgStyle,
+ viewBox: "0 0 1792 1792"
+ }, /*#__PURE__*/external_React_default.a.createElement("path", {
+ d: "M1344 800v64q0 14-9 23t-23 9h-352v352q0 14-9 23t-23 9h-64q-14 0-23-9t-9-23v-352h-352q-14 0-23-9t-9-23v-64q0-14 9-23t23-9h352v-352q0-14 9-23t23-9h64q14 0 23 9t9 23v352h352q14 0 23 9t9 23zm128 448v-832q0-66-47-113t-113-47h-832q-66 0-113 47t-47 113v832q0 66 47 113t113 47h832q66 0 113-47t47-113zm128-832v832q0 119-84.5 203.5t-203.5 84.5h-832q-119 0-203.5-84.5t-84.5-203.5v-832q0-119 84.5-203.5t203.5-84.5h832q119 0 203.5 84.5t84.5 203.5z"
+ })));
+ }
+ }]);
+
+ return SquarePlus;
+}((external_React_default.a.PureComponent));
+var icons_ArrowRight = /*#__PURE__*/function (_React$PureComponent5) {
+ _inherits(ArrowRight, _React$PureComponent5);
+
+ var _super5 = _createSuper(ArrowRight);
+
+ function ArrowRight() {
+ _classCallCheck(this, ArrowRight);
+
+ return _super5.apply(this, arguments);
+ }
+
+ _createClass(ArrowRight, [{
+ key: "render",
+ value: function render() {
+ cov_1a7hkspd76().f[4]++;
+
+ var _ref9 = (cov_1a7hkspd76().s[17]++, this),
+ props = _ref9.props;
+
+ var _ref10 = (cov_1a7hkspd76().s[18]++, props),
+ style = _ref10.style,
+ rest = _objectWithoutProperties(_ref10, ["style"]);
+
+ cov_1a7hkspd76().s[19]++;
+ return /*#__PURE__*/external_React_default.a.createElement("span", rest, /*#__PURE__*/external_React_default.a.createElement("svg", {
+ style: _objectSpread2(_objectSpread2({}, getIconStyle(style).style), {}, {
+ paddingLeft: '2px',
+ verticalAlign: 'top'
+ }),
+ viewBox: "0 0 15 15",
+ fill: "currentColor"
+ }, /*#__PURE__*/external_React_default.a.createElement("path", {
+ d: "M0 14l6-6-6-6z"
+ })));
+ }
+ }]);
+
+ return ArrowRight;
+}((external_React_default.a.PureComponent));
+var icons_ArrowDown = /*#__PURE__*/function (_React$PureComponent6) {
+ _inherits(ArrowDown, _React$PureComponent6);
+
+ var _super6 = _createSuper(ArrowDown);
+
+ function ArrowDown() {
+ _classCallCheck(this, ArrowDown);
+
+ return _super6.apply(this, arguments);
+ }
+
+ _createClass(ArrowDown, [{
+ key: "render",
+ value: function render() {
+ cov_1a7hkspd76().f[5]++;
+
+ var _ref11 = (cov_1a7hkspd76().s[20]++, this),
+ props = _ref11.props;
+
+ var _ref12 = (cov_1a7hkspd76().s[21]++, props),
+ style = _ref12.style,
+ rest = _objectWithoutProperties(_ref12, ["style"]);
+
+ cov_1a7hkspd76().s[22]++;
+ return /*#__PURE__*/external_React_default.a.createElement("span", rest, /*#__PURE__*/external_React_default.a.createElement("svg", {
+ style: _objectSpread2(_objectSpread2({}, getIconStyle(style).style), {}, {
+ paddingLeft: '2px',
+ verticalAlign: 'top'
+ }),
+ viewBox: "0 0 15 15",
+ fill: "currentColor"
+ }, /*#__PURE__*/external_React_default.a.createElement("path", {
+ d: "M0 5l6 6 6-6z"
+ })));
+ }
+ }]);
+
+ return ArrowDown;
+}((external_React_default.a.PureComponent));
+var icons_Clippy = /*#__PURE__*/function (_React$PureComponent7) {
+ _inherits(Clippy, _React$PureComponent7);
+
+ var _super7 = _createSuper(Clippy);
+
+ function Clippy() {
+ _classCallCheck(this, Clippy);
+
+ return _super7.apply(this, arguments);
+ }
+
+ _createClass(Clippy, [{
+ key: "render",
+ value: function render() {
+ cov_1a7hkspd76().f[6]++;
+
+ var _ref13 = (cov_1a7hkspd76().s[23]++, this),
+ props = _ref13.props;
+
+ var _ref14 = (cov_1a7hkspd76().s[24]++, props),
+ style = _ref14.style,
+ rest = _objectWithoutProperties(_ref14, ["style"]);
+
+ cov_1a7hkspd76().s[25]++;
+ return /*#__PURE__*/external_React_default.a.createElement("span", rest, /*#__PURE__*/external_React_default.a.createElement("svg", Object.assign({}, getIconStyle(style), {
+ viewBox: "0 0 40 40",
+ fill: "currentColor",
+ preserveAspectRatio: "xMidYMid meet"
+ }), /*#__PURE__*/external_React_default.a.createElement("g", null, /*#__PURE__*/external_React_default.a.createElement("path", {
+ d: "m30 35h-25v-22.5h25v7.5h2.5v-12.5c0-1.4-1.1-2.5-2.5-2.5h-7.5c0-2.8-2.2-5-5-5s-5 2.2-5 5h-7.5c-1.4 0-2.5 1.1-2.5 2.5v27.5c0 1.4 1.1 2.5 2.5 2.5h25c1.4 0 2.5-1.1 2.5-2.5v-5h-2.5v5z m-20-27.5h2.5s2.5-1.1 2.5-2.5 1.1-2.5 2.5-2.5 2.5 1.1 2.5 2.5 1.3 2.5 2.5 2.5h2.5s2.5 1.1 2.5 2.5h-20c0-1.5 1.1-2.5 2.5-2.5z m-2.5 20h5v-2.5h-5v2.5z m17.5-5v-5l-10 7.5 10 7.5v-5h12.5v-5h-12.5z m-17.5 10h7.5v-2.5h-7.5v2.5z m12.5-17.5h-12.5v2.5h12.5v-2.5z m-7.5 5h-5v2.5h5v-2.5z"
+ }))));
+ }
+ }]);
+
+ return Clippy;
+}((external_React_default.a.PureComponent));
+var icons_RemoveCircle = /*#__PURE__*/function (_React$PureComponent8) {
+ _inherits(RemoveCircle, _React$PureComponent8);
+
+ var _super8 = _createSuper(RemoveCircle);
+
+ function RemoveCircle() {
+ _classCallCheck(this, RemoveCircle);
+
+ return _super8.apply(this, arguments);
+ }
+
+ _createClass(RemoveCircle, [{
+ key: "render",
+ value: function render() {
+ cov_1a7hkspd76().f[7]++;
+
+ var _ref15 = (cov_1a7hkspd76().s[26]++, this),
+ props = _ref15.props;
+
+ var _ref16 = (cov_1a7hkspd76().s[27]++, props),
+ style = _ref16.style,
+ rest = _objectWithoutProperties(_ref16, ["style"]);
+
+ cov_1a7hkspd76().s[28]++;
+ return /*#__PURE__*/external_React_default.a.createElement("span", rest, /*#__PURE__*/external_React_default.a.createElement("svg", Object.assign({}, getIconStyle(style), {
+ viewBox: "0 0 40 40",
+ fill: "currentColor",
+ preserveAspectRatio: "xMidYMid meet"
+ }), /*#__PURE__*/external_React_default.a.createElement("g", null, /*#__PURE__*/external_React_default.a.createElement("path", {
+ d: "m28.6 25q0-0.5-0.4-1l-4-4 4-4q0.4-0.5 0.4-1 0-0.6-0.4-1.1l-2-2q-0.4-0.4-1-0.4-0.6 0-1 0.4l-4.1 4.1-4-4.1q-0.4-0.4-1-0.4-0.6 0-1 0.4l-2 2q-0.5 0.5-0.5 1.1 0 0.5 0.5 1l4 4-4 4q-0.5 0.5-0.5 1 0 0.7 0.5 1.1l2 2q0.4 0.4 1 0.4 0.6 0 1-0.4l4-4.1 4.1 4.1q0.4 0.4 1 0.4 0.6 0 1-0.4l2-2q0.4-0.4 0.4-1z m8.7-5q0 4.7-2.3 8.6t-6.3 6.2-8.6 2.3-8.6-2.3-6.2-6.2-2.3-8.6 2.3-8.6 6.2-6.2 8.6-2.3 8.6 2.3 6.3 6.2 2.3 8.6z"
+ }))));
+ }
+ }]);
+
+ return RemoveCircle;
+}((external_React_default.a.PureComponent));
+var icons_AddCircle = /*#__PURE__*/function (_React$PureComponent9) {
+ _inherits(AddCircle, _React$PureComponent9);
+
+ var _super9 = _createSuper(AddCircle);
+
+ function AddCircle() {
+ _classCallCheck(this, AddCircle);
+
+ return _super9.apply(this, arguments);
+ }
+
+ _createClass(AddCircle, [{
+ key: "render",
+ value: function render() {
+ cov_1a7hkspd76().f[8]++;
+
+ var _ref17 = (cov_1a7hkspd76().s[29]++, this),
+ props = _ref17.props;
+
+ var _ref18 = (cov_1a7hkspd76().s[30]++, props),
+ style = _ref18.style,
+ rest = _objectWithoutProperties(_ref18, ["style"]);
+
+ cov_1a7hkspd76().s[31]++;
+ return /*#__PURE__*/external_React_default.a.createElement("span", rest, /*#__PURE__*/external_React_default.a.createElement("svg", Object.assign({}, getIconStyle(style), {
+ viewBox: "0 0 40 40",
+ fill: "currentColor",
+ preserveAspectRatio: "xMidYMid meet"
+ }), /*#__PURE__*/external_React_default.a.createElement("g", null, /*#__PURE__*/external_React_default.a.createElement("path", {
+ d: "m30.1 21.4v-2.8q0-0.6-0.4-1t-1-0.5h-5.7v-5.7q0-0.6-0.4-1t-1-0.4h-2.9q-0.6 0-1 0.4t-0.4 1v5.7h-5.7q-0.6 0-1 0.5t-0.5 1v2.8q0 0.6 0.5 1t1 0.5h5.7v5.7q0 0.5 0.4 1t1 0.4h2.9q0.6 0 1-0.4t0.4-1v-5.7h5.7q0.6 0 1-0.5t0.4-1z m7.2-1.4q0 4.7-2.3 8.6t-6.3 6.2-8.6 2.3-8.6-2.3-6.2-6.2-2.3-8.6 2.3-8.6 6.2-6.2 8.6-2.3 8.6 2.3 6.3 6.2 2.3 8.6z"
+ }))));
+ }
+ }]);
+
+ return AddCircle;
+}((external_React_default.a.PureComponent));
+var icons_Add = /*#__PURE__*/function (_React$PureComponent10) {
+ _inherits(Add, _React$PureComponent10);
+
+ var _super10 = _createSuper(Add);
+
+ function Add() {
+ _classCallCheck(this, Add);
+
+ return _super10.apply(this, arguments);
+ }
+
+ _createClass(Add, [{
+ key: "render",
+ value: function render() {
+ cov_1a7hkspd76().f[9]++;
+
+ var _ref19 = (cov_1a7hkspd76().s[32]++, this),
+ props = _ref19.props;
+
+ var _ref20 = (cov_1a7hkspd76().s[33]++, props),
+ style = _ref20.style,
+ rest = _objectWithoutProperties(_ref20, ["style"]);
+
+ cov_1a7hkspd76().s[34]++;
+ return /*#__PURE__*/external_React_default.a.createElement("span", rest, /*#__PURE__*/external_React_default.a.createElement("svg", Object.assign({}, getIconStyle(style), {
+ viewBox: "0 0 40 40",
+ fill: "currentColor",
+ preserveAspectRatio: "xMidYMid meet"
+ }), /*#__PURE__*/external_React_default.a.createElement("g", null, /*#__PURE__*/external_React_default.a.createElement("path", {
+ d: "m31.6 21.6h-10v10h-3.2v-10h-10v-3.2h10v-10h3.2v10h10v3.2z"
+ }))));
+ }
+ }]);
+
+ return Add;
+}((external_React_default.a.PureComponent));
+var icons_Edit = /*#__PURE__*/function (_React$PureComponent11) {
+ _inherits(Edit, _React$PureComponent11);
+
+ var _super11 = _createSuper(Edit);
+
+ function Edit() {
+ _classCallCheck(this, Edit);
+
+ return _super11.apply(this, arguments);
+ }
+
+ _createClass(Edit, [{
+ key: "render",
+ value: function render() {
+ cov_1a7hkspd76().f[10]++;
+
+ var _ref21 = (cov_1a7hkspd76().s[35]++, this),
+ props = _ref21.props;
+
+ var _ref22 = (cov_1a7hkspd76().s[36]++, props),
+ style = _ref22.style,
+ rest = _objectWithoutProperties(_ref22, ["style"]);
+
+ cov_1a7hkspd76().s[37]++;
+ return /*#__PURE__*/external_React_default.a.createElement("span", rest, /*#__PURE__*/external_React_default.a.createElement("svg", Object.assign({}, getIconStyle(style), {
+ viewBox: "0 0 40 40",
+ fill: "currentColor",
+ preserveAspectRatio: "xMidYMid meet"
+ }), /*#__PURE__*/external_React_default.a.createElement("g", null, /*#__PURE__*/external_React_default.a.createElement("path", {
+ d: "m19.8 26.4l2.6-2.6-3.4-3.4-2.6 2.6v1.3h2.2v2.1h1.2z m9.8-16q-0.3-0.4-0.7 0l-7.8 7.8q-0.4 0.4 0 0.7t0.7 0l7.8-7.8q0.4-0.4 0-0.7z m1.8 13.2v4.3q0 2.6-1.9 4.5t-4.5 1.9h-18.6q-2.6 0-4.5-1.9t-1.9-4.5v-18.6q0-2.7 1.9-4.6t4.5-1.8h18.6q1.4 0 2.6 0.5 0.3 0.2 0.4 0.5 0.1 0.4-0.2 0.7l-1.1 1.1q-0.3 0.3-0.7 0.1-0.5-0.1-1-0.1h-18.6q-1.4 0-2.5 1.1t-1 2.5v18.6q0 1.4 1 2.5t2.5 1h18.6q1.5 0 2.5-1t1.1-2.5v-2.9q0-0.2 0.2-0.4l1.4-1.5q0.3-0.3 0.8-0.1t0.4 0.6z m-2.1-16.5l6.4 6.5-15 15h-6.4v-6.5z m9.9 3l-2.1 2-6.4-6.4 2.1-2q0.6-0.7 1.5-0.7t1.5 0.7l3.4 3.4q0.6 0.6 0.6 1.5t-0.6 1.5z"
+ }))));
+ }
+ }]);
+
+ return Edit;
+}((external_React_default.a.PureComponent));
+var icons_CheckCircle = /*#__PURE__*/function (_React$PureComponent12) {
+ _inherits(CheckCircle, _React$PureComponent12);
+
+ var _super12 = _createSuper(CheckCircle);
+
+ function CheckCircle() {
+ _classCallCheck(this, CheckCircle);
+
+ return _super12.apply(this, arguments);
+ }
+
+ _createClass(CheckCircle, [{
+ key: "render",
+ value: function render() {
+ cov_1a7hkspd76().f[11]++;
+
+ var _ref23 = (cov_1a7hkspd76().s[38]++, this),
+ props = _ref23.props;
+
+ var _ref24 = (cov_1a7hkspd76().s[39]++, props),
+ style = _ref24.style,
+ rest = _objectWithoutProperties(_ref24, ["style"]);
+
+ cov_1a7hkspd76().s[40]++;
+ return /*#__PURE__*/external_React_default.a.createElement("span", rest, /*#__PURE__*/external_React_default.a.createElement("svg", Object.assign({}, getIconStyle(style), {
+ viewBox: "0 0 40 40",
+ fill: "currentColor",
+ preserveAspectRatio: "xMidYMid meet"
+ }), /*#__PURE__*/external_React_default.a.createElement("g", null, /*#__PURE__*/external_React_default.a.createElement("path", {
+ d: "m31.7 16.4q0-0.6-0.4-1l-2.1-2.1q-0.4-0.4-1-0.4t-1 0.4l-9.1 9.1-5-5q-0.5-0.4-1-0.4t-1 0.4l-2.1 2q-0.4 0.4-0.4 1 0 0.6 0.4 1l8.1 8.1q0.4 0.4 1 0.4 0.6 0 1-0.4l12.2-12.1q0.4-0.4 0.4-1z m5.6 3.6q0 4.7-2.3 8.6t-6.3 6.2-8.6 2.3-8.6-2.3-6.2-6.2-2.3-8.6 2.3-8.6 6.2-6.2 8.6-2.3 8.6 2.3 6.3 6.2 2.3 8.6z"
+ }))));
+ }
+ }]);
+
+ return CheckCircle;
+}((external_React_default.a.PureComponent));
+
+function getIconStyle(style) {
+ cov_1a7hkspd76().f[12]++;
+ cov_1a7hkspd76().s[41]++;
+
+ if (!style) {
+ cov_1a7hkspd76().b[0][0]++;
+ cov_1a7hkspd76().s[42]++;
+ style = {};
+ } else {
+ cov_1a7hkspd76().b[0][1]++;
+ }
+
+ cov_1a7hkspd76().s[43]++;
+ return {
+ style: _objectSpread2(_objectSpread2({
+ verticalAlign: 'middle'
+ }, style), {}, {
+ color: style.color ? (cov_1a7hkspd76().b[1][0]++, style.color) : (cov_1a7hkspd76().b[1][1]++, DEFAULT_COLOR),
+ height: '1em',
+ width: '1em'
+ })
+ };
+}
+// CONCATENATED MODULE: ./src/js/components/CopyToClipboard.js
+
+
+
+
+
+
+function cov_246ea5oie6() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/components/CopyToClipboard.js";
+ var hash = "6e73cf60e739958132558418e746ac0aa4292300";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/components/CopyToClipboard.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 13,
+ column: 8
+ },
+ end: {
+ line: 13,
+ column: 21
+ }
+ },
+ "1": {
+ start: {
+ line: 14,
+ column: 8
+ },
+ end: {
+ line: 16,
+ column: 10
+ }
+ },
+ "2": {
+ start: {
+ line: 19,
+ column: 18
+ },
+ end: {
+ line: 19,
+ column: 22
+ }
+ },
+ "3": {
+ start: {
+ line: 22,
+ column: 8
+ },
+ end: {
+ line: 25,
+ column: 9
+ }
+ },
+ "4": {
+ start: {
+ line: 23,
+ column: 12
+ },
+ end: {
+ line: 23,
+ column: 43
+ }
+ },
+ "5": {
+ start: {
+ line: 24,
+ column: 12
+ },
+ end: {
+ line: 24,
+ column: 36
+ }
+ },
+ "6": {
+ start: {
+ line: 28,
+ column: 17
+ },
+ end: {
+ line: 61,
+ column: 5
+ }
+ },
+ "7": {
+ start: {
+ line: 29,
+ column: 26
+ },
+ end: {
+ line: 29,
+ column: 60
+ }
+ },
+ "8": {
+ start: {
+ line: 30,
+ column: 50
+ },
+ end: {
+ line: 30,
+ column: 60
+ }
+ },
+ "9": {
+ start: {
+ line: 32,
+ column: 8
+ },
+ end: {
+ line: 36,
+ column: 10
+ }
+ },
+ "10": {
+ start: {
+ line: 38,
+ column: 8
+ },
+ end: {
+ line: 38,
+ column: 45
+ }
+ },
+ "11": {
+ start: {
+ line: 39,
+ column: 8
+ },
+ end: {
+ line: 39,
+ column: 27
+ }
+ },
+ "12": {
+ start: {
+ line: 40,
+ column: 8
+ },
+ end: {
+ line: 40,
+ column: 37
+ }
+ },
+ "13": {
+ start: {
+ line: 42,
+ column: 8
+ },
+ end: {
+ line: 42,
+ column: 45
+ }
+ },
+ "14": {
+ start: {
+ line: 44,
+ column: 8
+ },
+ end: {
+ line: 48,
+ column: 17
+ }
+ },
+ "15": {
+ start: {
+ line: 45,
+ column: 12
+ },
+ end: {
+ line: 47,
+ column: 15
+ }
+ },
+ "16": {
+ start: {
+ line: 50,
+ column: 8
+ },
+ end: {
+ line: 60,
+ column: 11
+ }
+ },
+ "17": {
+ start: {
+ line: 51,
+ column: 12
+ },
+ end: {
+ line: 53,
+ column: 13
+ }
+ },
+ "18": {
+ start: {
+ line: 52,
+ column: 16
+ },
+ end: {
+ line: 52,
+ column: 23
+ }
+ },
+ "19": {
+ start: {
+ line: 55,
+ column: 12
+ },
+ end: {
+ line: 59,
+ column: 15
+ }
+ },
+ "20": {
+ start: {
+ line: 63,
+ column: 20
+ },
+ end: {
+ line: 76,
+ column: 5
+ }
+ },
+ "21": {
+ start: {
+ line: 64,
+ column: 26
+ },
+ end: {
+ line: 64,
+ column: 36
+ }
+ },
+ "22": {
+ start: {
+ line: 66,
+ column: 8
+ },
+ end: {
+ line: 73,
+ column: 9
+ }
+ },
+ "23": {
+ start: {
+ line: 67,
+ column: 12
+ },
+ end: {
+ line: 72,
+ column: 14
+ }
+ },
+ "24": {
+ start: {
+ line: 75,
+ column: 8
+ },
+ end: {
+ line: 75,
+ column: 75
+ }
+ },
+ "25": {
+ start: {
+ line: 78,
+ column: 21
+ },
+ end: {
+ line: 87,
+ column: 5
+ }
+ },
+ "26": {
+ start: {
+ line: 79,
+ column: 21
+ },
+ end: {
+ line: 79,
+ column: 34
+ }
+ },
+ "27": {
+ start: {
+ line: 80,
+ column: 8
+ },
+ end: {
+ line: 86,
+ column: 9
+ }
+ },
+ "28": {
+ start: {
+ line: 83,
+ column: 16
+ },
+ end: {
+ line: 83,
+ column: 40
+ }
+ },
+ "29": {
+ start: {
+ line: 85,
+ column: 16
+ },
+ end: {
+ line: 85,
+ column: 29
+ }
+ },
+ "30": {
+ start: {
+ line: 90,
+ column: 51
+ },
+ end: {
+ line: 90,
+ column: 61
+ }
+ },
+ "31": {
+ start: {
+ line: 91,
+ column: 20
+ },
+ end: {
+ line: 91,
+ column: 59
+ }
+ },
+ "32": {
+ start: {
+ line: 92,
+ column: 22
+ },
+ end: {
+ line: 92,
+ column: 30
+ }
+ },
+ "33": {
+ start: {
+ line: 94,
+ column: 8
+ },
+ end: {
+ line: 96,
+ column: 9
+ }
+ },
+ "34": {
+ start: {
+ line: 95,
+ column: 12
+ },
+ end: {
+ line: 95,
+ column: 29
+ }
+ },
+ "35": {
+ start: {
+ line: 98,
+ column: 8
+ },
+ end: {
+ line: 117,
+ column: 10
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "(anonymous_0)",
+ decl: {
+ start: {
+ line: 12,
+ column: 4
+ },
+ end: {
+ line: 12,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 12,
+ column: 23
+ },
+ end: {
+ line: 17,
+ column: 5
+ }
+ },
+ line: 12
+ },
+ "1": {
+ name: "(anonymous_1)",
+ decl: {
+ start: {
+ line: 21,
+ column: 4
+ },
+ end: {
+ line: 21,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 21,
+ column: 27
+ },
+ end: {
+ line: 26,
+ column: 5
+ }
+ },
+ line: 21
+ },
+ "2": {
+ name: "(anonymous_2)",
+ decl: {
+ start: {
+ line: 28,
+ column: 17
+ },
+ end: {
+ line: 28,
+ column: 18
+ }
+ },
+ loc: {
+ start: {
+ line: 28,
+ column: 23
+ },
+ end: {
+ line: 61,
+ column: 5
+ }
+ },
+ line: 28
+ },
+ "3": {
+ name: "(anonymous_3)",
+ decl: {
+ start: {
+ line: 44,
+ column: 38
+ },
+ end: {
+ line: 44,
+ column: 39
+ }
+ },
+ loc: {
+ start: {
+ line: 44,
+ column: 44
+ },
+ end: {
+ line: 48,
+ column: 9
+ }
+ },
+ line: 44
+ },
+ "4": {
+ name: "(anonymous_4)",
+ decl: {
+ start: {
+ line: 50,
+ column: 40
+ },
+ end: {
+ line: 50,
+ column: 41
+ }
+ },
+ loc: {
+ start: {
+ line: 50,
+ column: 46
+ },
+ end: {
+ line: 60,
+ column: 9
+ }
+ },
+ line: 50
+ },
+ "5": {
+ name: "(anonymous_5)",
+ decl: {
+ start: {
+ line: 63,
+ column: 20
+ },
+ end: {
+ line: 63,
+ column: 21
+ }
+ },
+ loc: {
+ start: {
+ line: 63,
+ column: 26
+ },
+ end: {
+ line: 76,
+ column: 5
+ }
+ },
+ line: 63
+ },
+ "6": {
+ name: "(anonymous_6)",
+ decl: {
+ start: {
+ line: 78,
+ column: 21
+ },
+ end: {
+ line: 78,
+ column: 22
+ }
+ },
+ loc: {
+ start: {
+ line: 78,
+ column: 30
+ },
+ end: {
+ line: 87,
+ column: 5
+ }
+ },
+ line: 78
+ },
+ "7": {
+ name: "(anonymous_7)",
+ decl: {
+ start: {
+ line: 89,
+ column: 4
+ },
+ end: {
+ line: 89,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 89,
+ column: 13
+ },
+ end: {
+ line: 118,
+ column: 5
+ }
+ },
+ line: 89
+ }
+ },
+ branchMap: {
+ "0": {
+ loc: {
+ start: {
+ line: 22,
+ column: 8
+ },
+ end: {
+ line: 25,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 22,
+ column: 8
+ },
+ end: {
+ line: 25,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 22,
+ column: 8
+ },
+ end: {
+ line: 25,
+ column: 9
+ }
+ }],
+ line: 22
+ },
+ "1": {
+ loc: {
+ start: {
+ line: 51,
+ column: 12
+ },
+ end: {
+ line: 53,
+ column: 13
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 51,
+ column: 12
+ },
+ end: {
+ line: 53,
+ column: 13
+ }
+ }, {
+ start: {
+ line: 51,
+ column: 12
+ },
+ end: {
+ line: 53,
+ column: 13
+ }
+ }],
+ line: 51
+ },
+ "2": {
+ loc: {
+ start: {
+ line: 66,
+ column: 8
+ },
+ end: {
+ line: 73,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 66,
+ column: 8
+ },
+ end: {
+ line: 73,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 66,
+ column: 8
+ },
+ end: {
+ line: 73,
+ column: 9
+ }
+ }],
+ line: 66
+ },
+ "3": {
+ loc: {
+ start: {
+ line: 80,
+ column: 8
+ },
+ end: {
+ line: 86,
+ column: 9
+ }
+ },
+ type: "switch",
+ locations: [{
+ start: {
+ line: 81,
+ column: 12
+ },
+ end: {
+ line: 81,
+ column: 28
+ }
+ }, {
+ start: {
+ line: 82,
+ column: 12
+ },
+ end: {
+ line: 83,
+ column: 40
+ }
+ }, {
+ start: {
+ line: 84,
+ column: 12
+ },
+ end: {
+ line: 85,
+ column: 29
+ }
+ }],
+ line: 80
+ },
+ "4": {
+ loc: {
+ start: {
+ line: 94,
+ column: 8
+ },
+ end: {
+ line: 96,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 94,
+ column: 8
+ },
+ end: {
+ line: 96,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 94,
+ column: 8
+ },
+ end: {
+ line: 96,
+ column: 9
+ }
+ }],
+ line: 94
+ },
+ "5": {
+ loc: {
+ start: {
+ line: 104,
+ column: 29
+ },
+ end: {
+ line: 104,
+ column: 65
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 104,
+ column: 42
+ },
+ end: {
+ line: 104,
+ column: 56
+ }
+ }, {
+ start: {
+ line: 104,
+ column: 59
+ },
+ end: {
+ line: 104,
+ column: 65
+ }
+ }],
+ line: 104
+ }
+ },
+ s: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0,
+ "7": 0,
+ "8": 0,
+ "9": 0,
+ "10": 0,
+ "11": 0,
+ "12": 0,
+ "13": 0,
+ "14": 0,
+ "15": 0,
+ "16": 0,
+ "17": 0,
+ "18": 0,
+ "19": 0,
+ "20": 0,
+ "21": 0,
+ "22": 0,
+ "23": 0,
+ "24": 0,
+ "25": 0,
+ "26": 0,
+ "27": 0,
+ "28": 0,
+ "29": 0,
+ "30": 0,
+ "31": 0,
+ "32": 0,
+ "33": 0,
+ "34": 0,
+ "35": 0
+ },
+ f: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0,
+ "7": 0
+ },
+ b: {
+ "0": [0, 0],
+ "1": [0, 0],
+ "2": [0, 0],
+ "3": [0, 0, 0],
+ "4": [0, 0],
+ "5": [0, 0]
+ },
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "6e73cf60e739958132558418e746ac0aa4292300"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
+
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
+
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_246ea5oie6 = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
+
+cov_246ea5oie6();
+
+ //clibboard icon
+
+ //theme
+
+
+
+var CopyToClipboard_default = /*#__PURE__*/function (_React$PureComponent) {
+ _inherits(_default, _React$PureComponent);
+
+ var _super = _createSuper(_default);
+
+ function _default(props) {
+ var _this;
+
+ _classCallCheck(this, _default);
+
+ cov_246ea5oie6().f[0]++;
+ cov_246ea5oie6().s[0]++;
+ _this = _super.call(this, props);
+ _this.copiedTimer = (cov_246ea5oie6().s[2]++, null);
+ _this.handleCopy = (cov_246ea5oie6().s[6]++, function () {
+ cov_246ea5oie6().f[2]++;
+ var container = (cov_246ea5oie6().s[7]++, document.createElement('textarea'));
+
+ var _ref = (cov_246ea5oie6().s[8]++, _this.props),
+ clickCallback = _ref.clickCallback,
+ src = _ref.src,
+ namespace = _ref.namespace;
+
+ cov_246ea5oie6().s[9]++;
+ container.innerHTML = JSON.stringify(_this.clipboardValue(src), null, ' ');
+ cov_246ea5oie6().s[10]++;
+ document.body.appendChild(container);
+ cov_246ea5oie6().s[11]++;
+ container.select();
+ cov_246ea5oie6().s[12]++;
+ document.execCommand('copy');
+ cov_246ea5oie6().s[13]++;
+ document.body.removeChild(container);
+ cov_246ea5oie6().s[14]++;
+ _this.copiedTimer = setTimeout(function () {
+ cov_246ea5oie6().f[3]++;
+ cov_246ea5oie6().s[15]++;
+
+ _this.setState({
+ copied: false
+ });
+ }, 5500);
+ cov_246ea5oie6().s[16]++;
+
+ _this.setState({
+ copied: true
+ }, function () {
+ cov_246ea5oie6().f[4]++;
+ cov_246ea5oie6().s[17]++;
+
+ if (typeof clickCallback !== 'function') {
+ cov_246ea5oie6().b[1][0]++;
+ cov_246ea5oie6().s[18]++;
+ return;
+ } else {
+ cov_246ea5oie6().b[1][1]++;
+ }
+
+ cov_246ea5oie6().s[19]++;
+ clickCallback({
+ src: src,
+ namespace: namespace,
+ name: namespace[namespace.length - 1]
+ });
+ });
+ });
+ _this.getClippyIcon = (cov_246ea5oie6().s[20]++, function () {
+ cov_246ea5oie6().f[5]++;
+
+ var _ref2 = (cov_246ea5oie6().s[21]++, _this.props),
+ theme = _ref2.theme;
+
+ cov_246ea5oie6().s[22]++;
+
+ if (_this.state.copied) {
+ cov_246ea5oie6().b[2][0]++;
+ cov_246ea5oie6().s[23]++;
+ return /*#__PURE__*/external_React_default.a.createElement("span", null, /*#__PURE__*/external_React_default.a.createElement(icons_Clippy, Object.assign({
+ className: "copy-icon"
+ }, getStyle_style(theme, 'copy-icon'))), /*#__PURE__*/external_React_default.a.createElement("span", getStyle_style(theme, 'copy-icon-copied'), "\u2714"));
+ } else {
+ cov_246ea5oie6().b[2][1]++;
+ }
+
+ cov_246ea5oie6().s[24]++;
+ return /*#__PURE__*/external_React_default.a.createElement(icons_Clippy, Object.assign({
+ className: "copy-icon"
+ }, getStyle_style(theme, 'copy-icon')));
+ });
+ _this.clipboardValue = (cov_246ea5oie6().s[25]++, function (value) {
+ cov_246ea5oie6().f[6]++;
+ var type = (cov_246ea5oie6().s[26]++, toType(value));
+ cov_246ea5oie6().s[27]++;
+
+ switch (type) {
+ case 'function':
+ cov_246ea5oie6().b[3][0]++;
+
+ case 'regexp':
+ cov_246ea5oie6().b[3][1]++;
+ cov_246ea5oie6().s[28]++;
+ return value.toString();
+
+ default:
+ cov_246ea5oie6().b[3][2]++;
+ cov_246ea5oie6().s[29]++;
+ return value;
+ }
+ });
+ cov_246ea5oie6().s[1]++;
+ _this.state = {
+ copied: false
+ };
+ return _this;
+ }
+
+ _createClass(_default, [{
+ key: "componentWillUnmount",
+ value: function componentWillUnmount() {
+ cov_246ea5oie6().f[1]++;
+ cov_246ea5oie6().s[3]++;
+
+ if (this.copiedTimer) {
+ cov_246ea5oie6().b[0][0]++;
+ cov_246ea5oie6().s[4]++;
+ clearTimeout(this.copiedTimer);
+ cov_246ea5oie6().s[5]++;
+ this.copiedTimer = null;
+ } else {
+ cov_246ea5oie6().b[0][1]++;
+ }
+ }
+ }, {
+ key: "render",
+ value: function render() {
+ cov_246ea5oie6().f[7]++;
+
+ var _ref3 = (cov_246ea5oie6().s[30]++, this.props),
+ src = _ref3.src,
+ theme = _ref3.theme,
+ hidden = _ref3.hidden,
+ rowHovered = _ref3.rowHovered;
+
+ var style = (cov_246ea5oie6().s[31]++, getStyle_style(theme, 'copy-to-clipboard').style);
+ var display = (cov_246ea5oie6().s[32]++, 'inline');
+ cov_246ea5oie6().s[33]++;
+
+ if (hidden) {
+ cov_246ea5oie6().b[4][0]++;
+ cov_246ea5oie6().s[34]++;
+ display = 'none';
+ } else {
+ cov_246ea5oie6().b[4][1]++;
+ }
+
+ cov_246ea5oie6().s[35]++;
+ return /*#__PURE__*/external_React_default.a.createElement("span", {
+ className: "copy-to-clipboard-container",
+ title: "Copy to clipboard",
+ style: {
+ verticalAlign: 'top',
+ display: rowHovered ? (cov_246ea5oie6().b[5][0]++, 'inline-block') : (cov_246ea5oie6().b[5][1]++, 'none')
+ }
+ }, /*#__PURE__*/external_React_default.a.createElement("span", {
+ style: _objectSpread2(_objectSpread2({}, style), {}, {
+ display: display
+ }),
+ onClick: this.handleCopy
+ }, this.getClippyIcon()));
+ }
+ }]);
+
+ return _default;
+}((external_React_default.a.PureComponent));
+
+
+// CONCATENATED MODULE: ./src/js/components/VariableEditor.js
+
+
+
+
+
+
+
+
+function cov_16cg0gp3o4() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/components/VariableEditor.js";
+ var hash = "e84b7be1aea6861951687e8aef03ab5a0a6dccaf";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/components/VariableEditor.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 32,
+ column: 8
+ },
+ end: {
+ line: 32,
+ column: 21
+ }
+ },
+ "1": {
+ start: {
+ line: 33,
+ column: 8
+ },
+ end: {
+ line: 42,
+ column: 10
+ }
+ },
+ "2": {
+ start: {
+ line: 59,
+ column: 12
+ },
+ end: {
+ line: 59,
+ column: 22
+ }
+ },
+ "3": {
+ start: {
+ line: 60,
+ column: 29
+ },
+ end: {
+ line: 60,
+ column: 39
+ }
+ },
+ "4": {
+ start: {
+ line: 62,
+ column: 8
+ },
+ end: {
+ line: 143,
+ column: 10
+ }
+ },
+ "5": {
+ start: {
+ line: 68,
+ column: 20
+ },
+ end: {
+ line: 68,
+ column: 67
+ }
+ },
+ "6": {
+ start: {
+ line: 71,
+ column: 20
+ },
+ end: {
+ line: 71,
+ column: 68
+ }
+ },
+ "7": {
+ start: {
+ line: 106,
+ column: 49
+ },
+ end: {
+ line: 106,
+ column: 63
+ }
+ },
+ "8": {
+ start: {
+ line: 107,
+ column: 34
+ },
+ end: {
+ line: 118,
+ column: 35
+ }
+ },
+ "9": {
+ start: {
+ line: 111,
+ column: 38
+ },
+ end: {
+ line: 111,
+ column: 65
+ }
+ },
+ "10": {
+ start: {
+ line: 112,
+ column: 41
+ },
+ end: {
+ line: 118,
+ column: 35
+ }
+ },
+ "11": {
+ start: {
+ line: 113,
+ column: 38
+ },
+ end: {
+ line: 113,
+ column: 55
+ }
+ },
+ "12": {
+ start: {
+ line: 114,
+ column: 38
+ },
+ end: {
+ line: 117,
+ column: 41
+ }
+ },
+ "13": {
+ start: {
+ line: 146,
+ column: 18
+ },
+ end: {
+ line: 166,
+ column: 5
+ }
+ },
+ "14": {
+ start: {
+ line: 147,
+ column: 36
+ },
+ end: {
+ line: 147,
+ column: 46
+ }
+ },
+ "15": {
+ start: {
+ line: 149,
+ column: 8
+ },
+ end: {
+ line: 165,
+ column: 10
+ }
+ },
+ "16": {
+ start: {
+ line: 161,
+ column: 24
+ },
+ end: {
+ line: 161,
+ column: 51
+ }
+ },
+ "17": {
+ start: {
+ line: 168,
+ column: 18
+ },
+ end: {
+ line: 181,
+ column: 5
+ }
+ },
+ "18": {
+ start: {
+ line: 169,
+ column: 8
+ },
+ end: {
+ line: 180,
+ column: 9
+ }
+ },
+ "19": {
+ start: {
+ line: 170,
+ column: 37
+ },
+ end: {
+ line: 170,
+ column: 70
+ }
+ },
+ "20": {
+ start: {
+ line: 171,
+ column: 29
+ },
+ end: {
+ line: 171,
+ column: 57
+ }
+ },
+ "21": {
+ start: {
+ line: 172,
+ column: 12
+ },
+ end: {
+ line: 179,
+ column: 15
+ }
+ },
+ "22": {
+ start: {
+ line: 183,
+ column: 20
+ },
+ end: {
+ line: 212,
+ column: 5
+ }
+ },
+ "23": {
+ start: {
+ line: 184,
+ column: 54
+ },
+ end: {
+ line: 184,
+ column: 64
+ }
+ },
+ "24": {
+ start: {
+ line: 186,
+ column: 8
+ },
+ end: {
+ line: 211,
+ column: 10
+ }
+ },
+ "25": {
+ start: {
+ line: 198,
+ column: 24
+ },
+ end: {
+ line: 207,
+ column: 27
+ }
+ },
+ "26": {
+ start: {
+ line: 214,
+ column: 15
+ },
+ end: {
+ line: 248,
+ column: 5
+ }
+ },
+ "27": {
+ start: {
+ line: 215,
+ column: 21
+ },
+ end: {
+ line: 215,
+ column: 53
+ }
+ },
+ "28": {
+ start: {
+ line: 216,
+ column: 26
+ },
+ end: {
+ line: 216,
+ column: 30
+ }
+ },
+ "29": {
+ start: {
+ line: 217,
+ column: 8
+ },
+ end: {
+ line: 247,
+ column: 9
+ }
+ },
+ "30": {
+ start: {
+ line: 219,
+ column: 16
+ },
+ end: {
+ line: 219,
+ column: 43
+ }
+ },
+ "31": {
+ start: {
+ line: 221,
+ column: 16
+ },
+ end: {
+ line: 221,
+ column: 72
+ }
+ },
+ "32": {
+ start: {
+ line: 223,
+ column: 16
+ },
+ end: {
+ line: 223,
+ column: 73
+ }
+ },
+ "33": {
+ start: {
+ line: 225,
+ column: 16
+ },
+ end: {
+ line: 225,
+ column: 71
+ }
+ },
+ "34": {
+ start: {
+ line: 227,
+ column: 16
+ },
+ end: {
+ line: 227,
+ column: 73
+ }
+ },
+ "35": {
+ start: {
+ line: 229,
+ column: 16
+ },
+ end: {
+ line: 229,
+ column: 74
+ }
+ },
+ "36": {
+ start: {
+ line: 231,
+ column: 16
+ },
+ end: {
+ line: 231,
+ column: 47
+ }
+ },
+ "37": {
+ start: {
+ line: 233,
+ column: 16
+ },
+ end: {
+ line: 233,
+ column: 46
+ }
+ },
+ "38": {
+ start: {
+ line: 235,
+ column: 16
+ },
+ end: {
+ line: 235,
+ column: 52
+ }
+ },
+ "39": {
+ start: {
+ line: 237,
+ column: 16
+ },
+ end: {
+ line: 237,
+ column: 70
+ }
+ },
+ "40": {
+ start: {
+ line: 239,
+ column: 16
+ },
+ end: {
+ line: 239,
+ column: 72
+ }
+ },
+ "41": {
+ start: {
+ line: 242,
+ column: 16
+ },
+ end: {
+ line: 246,
+ column: 18
+ }
+ },
+ "42": {
+ start: {
+ line: 250,
+ column: 19
+ },
+ end: {
+ line: 312,
+ column: 5
+ }
+ },
+ "43": {
+ start: {
+ line: 251,
+ column: 26
+ },
+ end: {
+ line: 251,
+ column: 36
+ }
+ },
+ "44": {
+ start: {
+ line: 252,
+ column: 30
+ },
+ end: {
+ line: 252,
+ column: 40
+ }
+ },
+ "45": {
+ start: {
+ line: 254,
+ column: 8
+ },
+ end: {
+ line: 311,
+ column: 10
+ }
+ },
+ "46": {
+ start: {
+ line: 258,
+ column: 39
+ },
+ end: {
+ line: 258,
+ column: 61
+ }
+ },
+ "47": {
+ start: {
+ line: 262,
+ column: 38
+ },
+ end: {
+ line: 262,
+ column: 56
+ }
+ },
+ "48": {
+ start: {
+ line: 263,
+ column: 41
+ },
+ end: {
+ line: 263,
+ column: 58
+ }
+ },
+ "49": {
+ start: {
+ line: 264,
+ column: 24
+ },
+ end: {
+ line: 270,
+ column: 27
+ }
+ },
+ "50": {
+ start: {
+ line: 273,
+ column: 24
+ },
+ end: {
+ line: 287,
+ column: 25
+ }
+ },
+ "51": {
+ start: {
+ line: 275,
+ column: 32
+ },
+ end: {
+ line: 278,
+ column: 35
+ }
+ },
+ "52": {
+ start: {
+ line: 279,
+ column: 32
+ },
+ end: {
+ line: 279,
+ column: 38
+ }
+ },
+ "53": {
+ start: {
+ line: 282,
+ column: 32
+ },
+ end: {
+ line: 284,
+ column: 33
+ }
+ },
+ "54": {
+ start: {
+ line: 283,
+ column: 36
+ },
+ end: {
+ line: 283,
+ column: 58
+ }
+ },
+ "55": {
+ start: {
+ line: 285,
+ column: 32
+ },
+ end: {
+ line: 285,
+ column: 38
+ }
+ },
+ "56": {
+ start: {
+ line: 288,
+ column: 24
+ },
+ end: {
+ line: 288,
+ column: 44
+ }
+ },
+ "57": {
+ start: {
+ line: 298,
+ column: 28
+ },
+ end: {
+ line: 298,
+ column: 78
+ }
+ },
+ "58": {
+ start: {
+ line: 305,
+ column: 28
+ },
+ end: {
+ line: 305,
+ column: 46
+ }
+ },
+ "59": {
+ start: {
+ line: 314,
+ column: 17
+ },
+ end: {
+ line: 335,
+ column: 5
+ }
+ },
+ "60": {
+ start: {
+ line: 315,
+ column: 47
+ },
+ end: {
+ line: 315,
+ column: 57
+ }
+ },
+ "61": {
+ start: {
+ line: 316,
+ column: 43
+ },
+ end: {
+ line: 316,
+ column: 53
+ }
+ },
+ "62": {
+ start: {
+ line: 317,
+ column: 24
+ },
+ end: {
+ line: 317,
+ column: 33
+ }
+ },
+ "63": {
+ start: {
+ line: 318,
+ column: 8
+ },
+ end: {
+ line: 320,
+ column: 9
+ }
+ },
+ "64": {
+ start: {
+ line: 319,
+ column: 12
+ },
+ end: {
+ line: 319,
+ column: 42
+ }
+ },
+ "65": {
+ start: {
+ line: 321,
+ column: 8
+ },
+ end: {
+ line: 323,
+ column: 11
+ }
+ },
+ "66": {
+ start: {
+ line: 324,
+ column: 8
+ },
+ end: {
+ line: 334,
+ column: 11
+ }
+ },
+ "67": {
+ start: {
+ line: 337,
+ column: 19
+ },
+ end: {
+ line: 361,
+ column: 5
+ }
+ },
+ "68": {
+ start: {
+ line: 338,
+ column: 54
+ },
+ end: {
+ line: 338,
+ column: 64
+ }
+ },
+ "69": {
+ start: {
+ line: 339,
+ column: 32
+ },
+ end: {
+ line: 339,
+ column: 54
+ }
+ },
+ "70": {
+ start: {
+ line: 340,
+ column: 25
+ },
+ end: {
+ line: 340,
+ column: 48
+ }
+ },
+ "71": {
+ start: {
+ line: 341,
+ column: 8
+ },
+ end: {
+ line: 360,
+ column: 9
+ }
+ },
+ "72": {
+ start: {
+ line: 342,
+ column: 12
+ },
+ end: {
+ line: 359,
+ column: 14
+ }
+ },
+ "73": {
+ start: {
+ line: 354,
+ column: 32
+ },
+ end: {
+ line: 354,
+ column: 54
+ }
+ },
+ "74": {
+ start: {
+ line: 363,
+ column: 23
+ },
+ end: {
+ line: 449,
+ column: 5
+ }
+ },
+ "75": {
+ start: {
+ line: 364,
+ column: 32
+ },
+ end: {
+ line: 364,
+ column: 42
+ }
+ },
+ "76": {
+ start: {
+ line: 365,
+ column: 32
+ },
+ end: {
+ line: 365,
+ column: 43
+ }
+ },
+ "77": {
+ start: {
+ line: 366,
+ column: 26
+ },
+ end: {
+ line: 366,
+ column: 30
+ }
+ },
+ "78": {
+ start: {
+ line: 367,
+ column: 26
+ },
+ end: {
+ line: 367,
+ column: 31
+ }
+ },
+ "79": {
+ start: {
+ line: 369,
+ column: 8
+ },
+ end: {
+ line: 448,
+ column: 9
+ }
+ },
+ "80": {
+ start: {
+ line: 370,
+ column: 12
+ },
+ end: {
+ line: 447,
+ column: 13
+ }
+ },
+ "81": {
+ start: {
+ line: 372,
+ column: 20
+ },
+ end: {
+ line: 399,
+ column: 22
+ }
+ },
+ "82": {
+ start: {
+ line: 401,
+ column: 20
+ },
+ end: {
+ line: 428,
+ column: 22
+ }
+ },
+ "83": {
+ start: {
+ line: 430,
+ column: 20
+ },
+ end: {
+ line: 430,
+ column: 67
+ }
+ },
+ "84": {
+ start: {
+ line: 432,
+ column: 20
+ },
+ end: {
+ line: 432,
+ column: 68
+ }
+ },
+ "85": {
+ start: {
+ line: 434,
+ column: 20
+ },
+ end: {
+ line: 434,
+ column: 66
+ }
+ },
+ "86": {
+ start: {
+ line: 436,
+ column: 20
+ },
+ end: {
+ line: 436,
+ column: 68
+ }
+ },
+ "87": {
+ start: {
+ line: 438,
+ column: 20
+ },
+ end: {
+ line: 438,
+ column: 69
+ }
+ },
+ "88": {
+ start: {
+ line: 440,
+ column: 20
+ },
+ end: {
+ line: 440,
+ column: 51
+ }
+ },
+ "89": {
+ start: {
+ line: 442,
+ column: 20
+ },
+ end: {
+ line: 442,
+ column: 50
+ }
+ },
+ "90": {
+ start: {
+ line: 444,
+ column: 20
+ },
+ end: {
+ line: 444,
+ column: 56
+ }
+ },
+ "91": {
+ start: {
+ line: 446,
+ column: 20
+ },
+ end: {
+ line: 446,
+ column: 75
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "(anonymous_0)",
+ decl: {
+ start: {
+ line: 31,
+ column: 4
+ },
+ end: {
+ line: 31,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 31,
+ column: 23
+ },
+ end: {
+ line: 43,
+ column: 5
+ }
+ },
+ line: 31
+ },
+ "1": {
+ name: "(anonymous_1)",
+ decl: {
+ start: {
+ line: 45,
+ column: 4
+ },
+ end: {
+ line: 45,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 45,
+ column: 13
+ },
+ end: {
+ line: 144,
+ column: 5
+ }
+ },
+ line: 45
+ },
+ "2": {
+ name: "(anonymous_2)",
+ decl: {
+ start: {
+ line: 67,
+ column: 30
+ },
+ end: {
+ line: 67,
+ column: 31
+ }
+ },
+ loc: {
+ start: {
+ line: 68,
+ column: 20
+ },
+ end: {
+ line: 68,
+ column: 67
+ }
+ },
+ line: 68
+ },
+ "3": {
+ name: "(anonymous_3)",
+ decl: {
+ start: {
+ line: 70,
+ column: 30
+ },
+ end: {
+ line: 70,
+ column: 31
+ }
+ },
+ loc: {
+ start: {
+ line: 71,
+ column: 20
+ },
+ end: {
+ line: 71,
+ column: 68
+ }
+ },
+ line: 71
+ },
+ "4": {
+ name: "(anonymous_4)",
+ decl: {
+ start: {
+ line: 105,
+ column: 30
+ },
+ end: {
+ line: 105,
+ column: 31
+ }
+ },
+ loc: {
+ start: {
+ line: 105,
+ column: 35
+ },
+ end: {
+ line: 119,
+ column: 31
+ }
+ },
+ line: 105
+ },
+ "5": {
+ name: "(anonymous_5)",
+ decl: {
+ start: {
+ line: 146,
+ column: 18
+ },
+ end: {
+ line: 146,
+ column: 19
+ }
+ },
+ loc: {
+ start: {
+ line: 146,
+ column: 24
+ },
+ end: {
+ line: 166,
+ column: 5
+ }
+ },
+ line: 146
+ },
+ "6": {
+ name: "(anonymous_6)",
+ decl: {
+ start: {
+ line: 160,
+ column: 29
+ },
+ end: {
+ line: 160,
+ column: 30
+ }
+ },
+ loc: {
+ start: {
+ line: 160,
+ column: 35
+ },
+ end: {
+ line: 162,
+ column: 21
+ }
+ },
+ line: 160
+ },
+ "7": {
+ name: "(anonymous_7)",
+ decl: {
+ start: {
+ line: 168,
+ column: 18
+ },
+ end: {
+ line: 168,
+ column: 19
+ }
+ },
+ loc: {
+ start: {
+ line: 168,
+ column: 30
+ },
+ end: {
+ line: 181,
+ column: 5
+ }
+ },
+ line: 168
+ },
+ "8": {
+ name: "(anonymous_8)",
+ decl: {
+ start: {
+ line: 183,
+ column: 20
+ },
+ end: {
+ line: 183,
+ column: 21
+ }
+ },
+ loc: {
+ start: {
+ line: 183,
+ column: 26
+ },
+ end: {
+ line: 212,
+ column: 5
+ }
+ },
+ line: 183
+ },
+ "9": {
+ name: "(anonymous_9)",
+ decl: {
+ start: {
+ line: 197,
+ column: 29
+ },
+ end: {
+ line: 197,
+ column: 30
+ }
+ },
+ loc: {
+ start: {
+ line: 197,
+ column: 35
+ },
+ end: {
+ line: 208,
+ column: 21
+ }
+ },
+ line: 197
+ },
+ "10": {
+ name: "(anonymous_10)",
+ decl: {
+ start: {
+ line: 214,
+ column: 15
+ },
+ end: {
+ line: 214,
+ column: 16
+ }
+ },
+ loc: {
+ start: {
+ line: 214,
+ column: 39
+ },
+ end: {
+ line: 248,
+ column: 5
+ }
+ },
+ line: 214
+ },
+ "11": {
+ name: "(anonymous_11)",
+ decl: {
+ start: {
+ line: 250,
+ column: 19
+ },
+ end: {
+ line: 250,
+ column: 20
+ }
+ },
+ loc: {
+ start: {
+ line: 250,
+ column: 25
+ },
+ end: {
+ line: 312,
+ column: 5
+ }
+ },
+ line: 250
+ },
+ "12": {
+ name: "(anonymous_12)",
+ decl: {
+ start: {
+ line: 258,
+ column: 30
+ },
+ end: {
+ line: 258,
+ column: 31
+ }
+ },
+ loc: {
+ start: {
+ line: 258,
+ column: 39
+ },
+ end: {
+ line: 258,
+ column: 61
+ }
+ },
+ line: 258
+ },
+ "13": {
+ name: "(anonymous_13)",
+ decl: {
+ start: {
+ line: 261,
+ column: 30
+ },
+ end: {
+ line: 261,
+ column: 31
+ }
+ },
+ loc: {
+ start: {
+ line: 261,
+ column: 39
+ },
+ end: {
+ line: 271,
+ column: 21
+ }
+ },
+ line: 261
+ },
+ "14": {
+ name: "(anonymous_14)",
+ decl: {
+ start: {
+ line: 272,
+ column: 31
+ },
+ end: {
+ line: 272,
+ column: 32
+ }
+ },
+ loc: {
+ start: {
+ line: 272,
+ column: 36
+ },
+ end: {
+ line: 289,
+ column: 21
+ }
+ },
+ line: 272
+ },
+ "15": {
+ name: "(anonymous_15)",
+ decl: {
+ start: {
+ line: 297,
+ column: 33
+ },
+ end: {
+ line: 297,
+ column: 34
+ }
+ },
+ loc: {
+ start: {
+ line: 297,
+ column: 39
+ },
+ end: {
+ line: 299,
+ column: 25
+ }
+ },
+ line: 297
+ },
+ "16": {
+ name: "(anonymous_16)",
+ decl: {
+ start: {
+ line: 304,
+ column: 33
+ },
+ end: {
+ line: 304,
+ column: 34
+ }
+ },
+ loc: {
+ start: {
+ line: 304,
+ column: 39
+ },
+ end: {
+ line: 306,
+ column: 25
+ }
+ },
+ line: 304
+ },
+ "17": {
+ name: "(anonymous_17)",
+ decl: {
+ start: {
+ line: 314,
+ column: 17
+ },
+ end: {
+ line: 314,
+ column: 18
+ }
+ },
+ loc: {
+ start: {
+ line: 314,
+ column: 36
+ },
+ end: {
+ line: 335,
+ column: 5
+ }
+ },
+ line: 314
+ },
+ "18": {
+ name: "(anonymous_18)",
+ decl: {
+ start: {
+ line: 337,
+ column: 19
+ },
+ end: {
+ line: 337,
+ column: 20
+ }
+ },
+ loc: {
+ start: {
+ line: 337,
+ column: 25
+ },
+ end: {
+ line: 361,
+ column: 5
+ }
+ },
+ line: 337
+ },
+ "19": {
+ name: "(anonymous_19)",
+ decl: {
+ start: {
+ line: 353,
+ column: 37
+ },
+ end: {
+ line: 353,
+ column: 38
+ }
+ },
+ loc: {
+ start: {
+ line: 353,
+ column: 43
+ },
+ end: {
+ line: 355,
+ column: 29
+ }
+ },
+ line: 353
+ },
+ "20": {
+ name: "(anonymous_20)",
+ decl: {
+ start: {
+ line: 363,
+ column: 23
+ },
+ end: {
+ line: 363,
+ column: 24
+ }
+ },
+ loc: {
+ start: {
+ line: 363,
+ column: 29
+ },
+ end: {
+ line: 449,
+ column: 5
+ }
+ },
+ line: 363
+ }
+ },
+ branchMap: {
+ "0": {
+ loc: {
+ start: {
+ line: 76,
+ column: 17
+ },
+ end: {
+ line: 99,
+ column: 17
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 77,
+ column: 20
+ },
+ end: {
+ line: 83,
+ column: 27
+ }
+ }, {
+ start: {
+ line: 85,
+ column: 20
+ },
+ end: {
+ line: 98,
+ column: 27
+ }
+ }],
+ line: 76
+ },
+ "1": {
+ loc: {
+ start: {
+ line: 103,
+ column: 24
+ },
+ end: {
+ line: 119,
+ column: 31
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 104,
+ column: 30
+ },
+ end: {
+ line: 104,
+ column: 34
+ }
+ }, {
+ start: {
+ line: 105,
+ column: 30
+ },
+ end: {
+ line: 119,
+ column: 31
+ }
+ }],
+ line: 103
+ },
+ "2": {
+ loc: {
+ start: {
+ line: 103,
+ column: 24
+ },
+ end: {
+ line: 103,
+ column: 62
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 103,
+ column: 24
+ },
+ end: {
+ line: 103,
+ column: 42
+ }
+ }, {
+ start: {
+ line: 103,
+ column: 46
+ },
+ end: {
+ line: 103,
+ column: 62
+ }
+ }],
+ line: 103
+ },
+ "3": {
+ loc: {
+ start: {
+ line: 107,
+ column: 34
+ },
+ end: {
+ line: 118,
+ column: 35
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 107,
+ column: 34
+ },
+ end: {
+ line: 118,
+ column: 35
+ }
+ }, {
+ start: {
+ line: 107,
+ column: 34
+ },
+ end: {
+ line: 118,
+ column: 35
+ }
+ }],
+ line: 107
+ },
+ "4": {
+ loc: {
+ start: {
+ line: 108,
+ column: 38
+ },
+ end: {
+ line: 109,
+ column: 54
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 108,
+ column: 39
+ },
+ end: {
+ line: 108,
+ column: 48
+ }
+ }, {
+ start: {
+ line: 108,
+ column: 52
+ },
+ end: {
+ line: 108,
+ column: 61
+ }
+ }, {
+ start: {
+ line: 109,
+ column: 38
+ },
+ end: {
+ line: 109,
+ column: 54
+ }
+ }],
+ line: 108
+ },
+ "5": {
+ loc: {
+ start: {
+ line: 112,
+ column: 41
+ },
+ end: {
+ line: 118,
+ column: 35
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 112,
+ column: 41
+ },
+ end: {
+ line: 118,
+ column: 35
+ }
+ }, {
+ start: {
+ line: 112,
+ column: 41
+ },
+ end: {
+ line: 118,
+ column: 35
+ }
+ }],
+ line: 112
+ },
+ "6": {
+ loc: {
+ start: {
+ line: 122,
+ column: 32
+ },
+ end: {
+ line: 122,
+ column: 74
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 122,
+ column: 53
+ },
+ end: {
+ line: 122,
+ column: 62
+ }
+ }, {
+ start: {
+ line: 122,
+ column: 65
+ },
+ end: {
+ line: 122,
+ column: 74
+ }
+ }],
+ line: 122
+ },
+ "7": {
+ loc: {
+ start: {
+ line: 127,
+ column: 17
+ },
+ end: {
+ line: 135,
+ column: 24
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 128,
+ column: 20
+ },
+ end: {
+ line: 134,
+ column: 22
+ }
+ }, {
+ start: {
+ line: 135,
+ column: 20
+ },
+ end: {
+ line: 135,
+ column: 24
+ }
+ }],
+ line: 127
+ },
+ "8": {
+ loc: {
+ start: {
+ line: 136,
+ column: 17
+ },
+ end: {
+ line: 138,
+ column: 26
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 137,
+ column: 22
+ },
+ end: {
+ line: 137,
+ column: 40
+ }
+ }, {
+ start: {
+ line: 138,
+ column: 22
+ },
+ end: {
+ line: 138,
+ column: 26
+ }
+ }],
+ line: 136
+ },
+ "9": {
+ loc: {
+ start: {
+ line: 136,
+ column: 17
+ },
+ end: {
+ line: 136,
+ column: 54
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 136,
+ column: 17
+ },
+ end: {
+ line: 136,
+ column: 33
+ }
+ }, {
+ start: {
+ line: 136,
+ column: 37
+ },
+ end: {
+ line: 136,
+ column: 54
+ }
+ }],
+ line: 136
+ },
+ "10": {
+ loc: {
+ start: {
+ line: 139,
+ column: 17
+ },
+ end: {
+ line: 141,
+ column: 26
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 140,
+ column: 22
+ },
+ end: {
+ line: 140,
+ column: 42
+ }
+ }, {
+ start: {
+ line: 141,
+ column: 22
+ },
+ end: {
+ line: 141,
+ column: 26
+ }
+ }],
+ line: 139
+ },
+ "11": {
+ loc: {
+ start: {
+ line: 139,
+ column: 17
+ },
+ end: {
+ line: 139,
+ column: 56
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 139,
+ column: 17
+ },
+ end: {
+ line: 139,
+ column: 35
+ }
+ }, {
+ start: {
+ line: 139,
+ column: 39
+ },
+ end: {
+ line: 139,
+ column: 56
+ }
+ }],
+ line: 139
+ },
+ "12": {
+ loc: {
+ start: {
+ line: 154,
+ column: 29
+ },
+ end: {
+ line: 154,
+ column: 73
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 154,
+ column: 50
+ },
+ end: {
+ line: 154,
+ column: 64
+ }
+ }, {
+ start: {
+ line: 154,
+ column: 67
+ },
+ end: {
+ line: 154,
+ column: 73
+ }
+ }],
+ line: 154
+ },
+ "13": {
+ loc: {
+ start: {
+ line: 169,
+ column: 8
+ },
+ end: {
+ line: 180,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 169,
+ column: 8
+ },
+ end: {
+ line: 180,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 169,
+ column: 8
+ },
+ end: {
+ line: 180,
+ column: 9
+ }
+ }],
+ line: 169
+ },
+ "14": {
+ loc: {
+ start: {
+ line: 191,
+ column: 29
+ },
+ end: {
+ line: 191,
+ column: 73
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 191,
+ column: 50
+ },
+ end: {
+ line: 191,
+ column: 64
+ }
+ }, {
+ start: {
+ line: 191,
+ column: 67
+ },
+ end: {
+ line: 191,
+ column: 73
+ }
+ }],
+ line: 191
+ },
+ "15": {
+ loc: {
+ start: {
+ line: 215,
+ column: 21
+ },
+ end: {
+ line: 215,
+ column: 53
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 215,
+ column: 32
+ },
+ end: {
+ line: 215,
+ column: 37
+ }
+ }, {
+ start: {
+ line: 215,
+ column: 40
+ },
+ end: {
+ line: 215,
+ column: 53
+ }
+ }],
+ line: 215
+ },
+ "16": {
+ loc: {
+ start: {
+ line: 217,
+ column: 8
+ },
+ end: {
+ line: 247,
+ column: 9
+ }
+ },
+ type: "switch",
+ locations: [{
+ start: {
+ line: 218,
+ column: 12
+ },
+ end: {
+ line: 219,
+ column: 43
+ }
+ }, {
+ start: {
+ line: 220,
+ column: 12
+ },
+ end: {
+ line: 221,
+ column: 72
+ }
+ }, {
+ start: {
+ line: 222,
+ column: 12
+ },
+ end: {
+ line: 223,
+ column: 73
+ }
+ }, {
+ start: {
+ line: 224,
+ column: 12
+ },
+ end: {
+ line: 225,
+ column: 71
+ }
+ }, {
+ start: {
+ line: 226,
+ column: 12
+ },
+ end: {
+ line: 227,
+ column: 73
+ }
+ }, {
+ start: {
+ line: 228,
+ column: 12
+ },
+ end: {
+ line: 229,
+ column: 74
+ }
+ }, {
+ start: {
+ line: 230,
+ column: 12
+ },
+ end: {
+ line: 231,
+ column: 47
+ }
+ }, {
+ start: {
+ line: 232,
+ column: 12
+ },
+ end: {
+ line: 233,
+ column: 46
+ }
+ }, {
+ start: {
+ line: 234,
+ column: 12
+ },
+ end: {
+ line: 235,
+ column: 52
+ }
+ }, {
+ start: {
+ line: 236,
+ column: 12
+ },
+ end: {
+ line: 237,
+ column: 70
+ }
+ }, {
+ start: {
+ line: 238,
+ column: 12
+ },
+ end: {
+ line: 239,
+ column: 72
+ }
+ }, {
+ start: {
+ line: 240,
+ column: 12
+ },
+ end: {
+ line: 246,
+ column: 18
+ }
+ }],
+ line: 217
+ },
+ "17": {
+ loc: {
+ start: {
+ line: 258,
+ column: 39
+ },
+ end: {
+ line: 258,
+ column: 61
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 258,
+ column: 39
+ },
+ end: {
+ line: 258,
+ column: 44
+ }
+ }, {
+ start: {
+ line: 258,
+ column: 48
+ },
+ end: {
+ line: 258,
+ column: 61
+ }
+ }],
+ line: 258
+ },
+ "18": {
+ loc: {
+ start: {
+ line: 273,
+ column: 24
+ },
+ end: {
+ line: 287,
+ column: 25
+ }
+ },
+ type: "switch",
+ locations: [{
+ start: {
+ line: 274,
+ column: 28
+ },
+ end: {
+ line: 280,
+ column: 29
+ }
+ }, {
+ start: {
+ line: 281,
+ column: 28
+ },
+ end: {
+ line: 286,
+ column: 29
+ }
+ }],
+ line: 273
+ },
+ "19": {
+ loc: {
+ start: {
+ line: 282,
+ column: 32
+ },
+ end: {
+ line: 284,
+ column: 33
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 282,
+ column: 32
+ },
+ end: {
+ line: 284,
+ column: 33
+ }
+ }, {
+ start: {
+ line: 282,
+ column: 32
+ },
+ end: {
+ line: 284,
+ column: 33
+ }
+ }],
+ line: 282
+ },
+ "20": {
+ loc: {
+ start: {
+ line: 282,
+ column: 36
+ },
+ end: {
+ line: 282,
+ column: 58
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 282,
+ column: 36
+ },
+ end: {
+ line: 282,
+ column: 45
+ }
+ }, {
+ start: {
+ line: 282,
+ column: 49
+ },
+ end: {
+ line: 282,
+ column: 58
+ }
+ }],
+ line: 282
+ },
+ "21": {
+ loc: {
+ start: {
+ line: 318,
+ column: 8
+ },
+ end: {
+ line: 320,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 318,
+ column: 8
+ },
+ end: {
+ line: 320,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 318,
+ column: 8
+ },
+ end: {
+ line: 320,
+ column: 9
+ }
+ }],
+ line: 318
+ },
+ "22": {
+ loc: {
+ start: {
+ line: 318,
+ column: 12
+ },
+ end: {
+ line: 318,
+ column: 47
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 318,
+ column: 12
+ },
+ end: {
+ line: 318,
+ column: 27
+ }
+ }, {
+ start: {
+ line: 318,
+ column: 31
+ },
+ end: {
+ line: 318,
+ column: 47
+ }
+ }],
+ line: 318
+ },
+ "23": {
+ loc: {
+ start: {
+ line: 341,
+ column: 8
+ },
+ end: {
+ line: 360,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 341,
+ column: 8
+ },
+ end: {
+ line: 360,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 341,
+ column: 8
+ },
+ end: {
+ line: 360,
+ column: 9
+ }
+ }],
+ line: 341
+ },
+ "24": {
+ loc: {
+ start: {
+ line: 369,
+ column: 8
+ },
+ end: {
+ line: 448,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 369,
+ column: 8
+ },
+ end: {
+ line: 448,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 369,
+ column: 8
+ },
+ end: {
+ line: 448,
+ column: 9
+ }
+ }],
+ line: 369
+ },
+ "25": {
+ loc: {
+ start: {
+ line: 370,
+ column: 12
+ },
+ end: {
+ line: 447,
+ column: 13
+ }
+ },
+ type: "switch",
+ locations: [{
+ start: {
+ line: 371,
+ column: 16
+ },
+ end: {
+ line: 399,
+ column: 22
+ }
+ }, {
+ start: {
+ line: 400,
+ column: 16
+ },
+ end: {
+ line: 428,
+ column: 22
+ }
+ }, {
+ start: {
+ line: 429,
+ column: 16
+ },
+ end: {
+ line: 430,
+ column: 67
+ }
+ }, {
+ start: {
+ line: 431,
+ column: 16
+ },
+ end: {
+ line: 432,
+ column: 68
+ }
+ }, {
+ start: {
+ line: 433,
+ column: 16
+ },
+ end: {
+ line: 434,
+ column: 66
+ }
+ }, {
+ start: {
+ line: 435,
+ column: 16
+ },
+ end: {
+ line: 436,
+ column: 68
+ }
+ }, {
+ start: {
+ line: 437,
+ column: 16
+ },
+ end: {
+ line: 438,
+ column: 69
+ }
+ }, {
+ start: {
+ line: 439,
+ column: 16
+ },
+ end: {
+ line: 440,
+ column: 51
+ }
+ }, {
+ start: {
+ line: 441,
+ column: 16
+ },
+ end: {
+ line: 442,
+ column: 50
+ }
+ }, {
+ start: {
+ line: 443,
+ column: 16
+ },
+ end: {
+ line: 444,
+ column: 56
+ }
+ }, {
+ start: {
+ line: 445,
+ column: 16
+ },
+ end: {
+ line: 446,
+ column: 75
+ }
+ }],
+ line: 370
+ }
+ },
+ s: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0,
+ "7": 0,
+ "8": 0,
+ "9": 0,
+ "10": 0,
+ "11": 0,
+ "12": 0,
+ "13": 0,
+ "14": 0,
+ "15": 0,
+ "16": 0,
+ "17": 0,
+ "18": 0,
+ "19": 0,
+ "20": 0,
+ "21": 0,
+ "22": 0,
+ "23": 0,
+ "24": 0,
+ "25": 0,
+ "26": 0,
+ "27": 0,
+ "28": 0,
+ "29": 0,
+ "30": 0,
+ "31": 0,
+ "32": 0,
+ "33": 0,
+ "34": 0,
+ "35": 0,
+ "36": 0,
+ "37": 0,
+ "38": 0,
+ "39": 0,
+ "40": 0,
+ "41": 0,
+ "42": 0,
+ "43": 0,
+ "44": 0,
+ "45": 0,
+ "46": 0,
+ "47": 0,
+ "48": 0,
+ "49": 0,
+ "50": 0,
+ "51": 0,
+ "52": 0,
+ "53": 0,
+ "54": 0,
+ "55": 0,
+ "56": 0,
+ "57": 0,
+ "58": 0,
+ "59": 0,
+ "60": 0,
+ "61": 0,
+ "62": 0,
+ "63": 0,
+ "64": 0,
+ "65": 0,
+ "66": 0,
+ "67": 0,
+ "68": 0,
+ "69": 0,
+ "70": 0,
+ "71": 0,
+ "72": 0,
+ "73": 0,
+ "74": 0,
+ "75": 0,
+ "76": 0,
+ "77": 0,
+ "78": 0,
+ "79": 0,
+ "80": 0,
+ "81": 0,
+ "82": 0,
+ "83": 0,
+ "84": 0,
+ "85": 0,
+ "86": 0,
+ "87": 0,
+ "88": 0,
+ "89": 0,
+ "90": 0,
+ "91": 0
+ },
+ f: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0,
+ "7": 0,
+ "8": 0,
+ "9": 0,
+ "10": 0,
+ "11": 0,
+ "12": 0,
+ "13": 0,
+ "14": 0,
+ "15": 0,
+ "16": 0,
+ "17": 0,
+ "18": 0,
+ "19": 0,
+ "20": 0
+ },
+ b: {
+ "0": [0, 0],
+ "1": [0, 0],
+ "2": [0, 0],
+ "3": [0, 0],
+ "4": [0, 0, 0],
+ "5": [0, 0],
+ "6": [0, 0],
+ "7": [0, 0],
+ "8": [0, 0],
+ "9": [0, 0],
+ "10": [0, 0],
+ "11": [0, 0],
+ "12": [0, 0],
+ "13": [0, 0],
+ "14": [0, 0],
+ "15": [0, 0],
+ "16": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0],
+ "17": [0, 0],
+ "18": [0, 0],
+ "19": [0, 0],
+ "20": [0, 0],
+ "21": [0, 0],
+ "22": [0, 0],
+ "23": [0, 0],
+ "24": [0, 0],
+ "25": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
+ },
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "e84b7be1aea6861951687e8aef03ab5a0a6dccaf"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
+
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
+
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_16cg0gp3o4 = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
+
+cov_16cg0gp3o4();
+
+
+
+
+
+
+ //data type components
+
+ //clibboard icon
+
+ //theme
+
+
+
+var VariableEditor_VariableEditor = /*#__PURE__*/function (_React$PureComponent) {
+ _inherits(VariableEditor, _React$PureComponent);
+
+ var _super = _createSuper(VariableEditor);
+
+ function VariableEditor(_props) {
+ var _this;
+
+ _classCallCheck(this, VariableEditor);
+
+ cov_16cg0gp3o4().f[0]++;
+ cov_16cg0gp3o4().s[0]++;
+ _this = _super.call(this, _props);
+ _this.getEditIcon = (cov_16cg0gp3o4().s[13]++, function () {
+ cov_16cg0gp3o4().f[5]++;
+
+ var _ref = (cov_16cg0gp3o4().s[14]++, _this.props),
+ variable = _ref.variable,
+ theme = _ref.theme;
+
+ cov_16cg0gp3o4().s[15]++;
+ return /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "click-to-edit",
+ style: {
+ verticalAlign: 'top',
+ display: _this.state.hovered ? (cov_16cg0gp3o4().b[12][0]++, 'inline-block') : (cov_16cg0gp3o4().b[12][1]++, 'none')
+ }
+ }, /*#__PURE__*/external_React_default.a.createElement(icons_Edit, Object.assign({
+ className: "click-to-edit-icon"
+ }, getStyle_style(theme, 'editVarIcon'), {
+ onClick: function onClick() {
+ cov_16cg0gp3o4().f[6]++;
+ cov_16cg0gp3o4().s[16]++;
+
+ _this.prepopInput(variable);
+ }
+ })));
+ });
+ _this.prepopInput = (cov_16cg0gp3o4().s[17]++, function (variable) {
+ cov_16cg0gp3o4().f[7]++;
+ cov_16cg0gp3o4().s[18]++;
+
+ if (_this.props.onEdit !== false) {
+ cov_16cg0gp3o4().b[13][0]++;
+ var stringifiedValue = (cov_16cg0gp3o4().s[19]++, stringifyVariable(variable.value));
+ var detected = (cov_16cg0gp3o4().s[20]++, parseInput(stringifiedValue));
+ cov_16cg0gp3o4().s[21]++;
+
+ _this.setState({
+ editMode: true,
+ editValue: stringifiedValue,
+ parsedInput: {
+ type: detected.type,
+ value: detected.value
+ }
+ });
+ } else {
+ cov_16cg0gp3o4().b[13][1]++;
+ }
+ });
+ _this.getRemoveIcon = (cov_16cg0gp3o4().s[22]++, function () {
+ cov_16cg0gp3o4().f[8]++;
+
+ var _ref2 = (cov_16cg0gp3o4().s[23]++, _this.props),
+ variable = _ref2.variable,
+ namespace = _ref2.namespace,
+ theme = _ref2.theme,
+ rjvId = _ref2.rjvId;
+
+ cov_16cg0gp3o4().s[24]++;
+ return /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "click-to-remove",
+ style: {
+ verticalAlign: 'top',
+ display: _this.state.hovered ? (cov_16cg0gp3o4().b[14][0]++, 'inline-block') : (cov_16cg0gp3o4().b[14][1]++, 'none')
+ }
+ }, /*#__PURE__*/external_React_default.a.createElement(icons_RemoveCircle, Object.assign({
+ className: "click-to-remove-icon"
+ }, getStyle_style(theme, 'removeVarIcon'), {
+ onClick: function onClick() {
+ cov_16cg0gp3o4().f[9]++;
+ cov_16cg0gp3o4().s[25]++;
+ helpers_dispatcher.dispatch({
+ name: 'VARIABLE_REMOVED',
+ rjvId: rjvId,
+ data: {
+ name: variable.name,
+ namespace: namespace,
+ existing_value: variable.value,
+ variable_removed: true
+ }
+ });
+ }
+ })));
+ });
+ _this.getValue = (cov_16cg0gp3o4().s[26]++, function (variable, editMode) {
+ cov_16cg0gp3o4().f[10]++;
+ var type = (cov_16cg0gp3o4().s[27]++, editMode ? (cov_16cg0gp3o4().b[15][0]++, false) : (cov_16cg0gp3o4().b[15][1]++, variable.type));
+
+ var _ref3 = (cov_16cg0gp3o4().s[28]++, _assertThisInitialized(_this)),
+ props = _ref3.props;
+
+ cov_16cg0gp3o4().s[29]++;
+
+ switch (type) {
+ case false:
+ cov_16cg0gp3o4().b[16][0]++;
+ cov_16cg0gp3o4().s[30]++;
+ return _this.getEditInput();
+
+ case 'string':
+ cov_16cg0gp3o4().b[16][1]++;
+ cov_16cg0gp3o4().s[31]++;
+ return /*#__PURE__*/external_React_default.a.createElement(String_default, Object.assign({
+ value: variable.value
+ }, props));
+
+ case 'integer':
+ cov_16cg0gp3o4().b[16][2]++;
+ cov_16cg0gp3o4().s[32]++;
+ return /*#__PURE__*/external_React_default.a.createElement(Integer_default, Object.assign({
+ value: variable.value
+ }, props));
+
+ case 'float':
+ cov_16cg0gp3o4().b[16][3]++;
+ cov_16cg0gp3o4().s[33]++;
+ return /*#__PURE__*/external_React_default.a.createElement(Float_default, Object.assign({
+ value: variable.value
+ }, props));
+
+ case 'boolean':
+ cov_16cg0gp3o4().b[16][4]++;
+ cov_16cg0gp3o4().s[34]++;
+ return /*#__PURE__*/external_React_default.a.createElement(Boolean_default, Object.assign({
+ value: variable.value
+ }, props));
+
+ case 'function':
+ cov_16cg0gp3o4().b[16][5]++;
+ cov_16cg0gp3o4().s[35]++;
+ return /*#__PURE__*/external_React_default.a.createElement(Function_default, Object.assign({
+ value: variable.value
+ }, props));
+
+ case 'null':
+ cov_16cg0gp3o4().b[16][6]++;
+ cov_16cg0gp3o4().s[36]++;
+ return /*#__PURE__*/external_React_default.a.createElement(Null_default, props);
+
+ case 'nan':
+ cov_16cg0gp3o4().b[16][7]++;
+ cov_16cg0gp3o4().s[37]++;
+ return /*#__PURE__*/external_React_default.a.createElement(Nan_default, props);
+
+ case 'undefined':
+ cov_16cg0gp3o4().b[16][8]++;
+ cov_16cg0gp3o4().s[38]++;
+ return /*#__PURE__*/external_React_default.a.createElement(Undefined_default, props);
+
+ case 'date':
+ cov_16cg0gp3o4().b[16][9]++;
+ cov_16cg0gp3o4().s[39]++;
+ return /*#__PURE__*/external_React_default.a.createElement(Date_default, Object.assign({
+ value: variable.value
+ }, props));
+
+ case 'regexp':
+ cov_16cg0gp3o4().b[16][10]++;
+ cov_16cg0gp3o4().s[40]++;
+ return /*#__PURE__*/external_React_default.a.createElement(Regexp_default, Object.assign({
+ value: variable.value
+ }, props));
+
+ default:
+ cov_16cg0gp3o4().b[16][11]++;
+ cov_16cg0gp3o4().s[41]++;
+ // catch-all for types that weren't anticipated
+ return /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "object-value"
+ }, JSON.stringify(variable.value));
+ }
+ });
+ _this.getEditInput = (cov_16cg0gp3o4().s[42]++, function () {
+ cov_16cg0gp3o4().f[11]++;
+
+ var _ref4 = (cov_16cg0gp3o4().s[43]++, _this.props),
+ theme = _ref4.theme;
+
+ var _ref5 = (cov_16cg0gp3o4().s[44]++, _this.state),
+ editValue = _ref5.editValue;
+
+ cov_16cg0gp3o4().s[45]++;
+ return /*#__PURE__*/external_React_default.a.createElement("div", null, /*#__PURE__*/external_React_default.a.createElement(react_textarea_autosize_es, Object.assign({
+ type: "text",
+ inputRef: function inputRef(input) {
+ cov_16cg0gp3o4().f[12]++;
+ cov_16cg0gp3o4().s[46]++;
+ return (cov_16cg0gp3o4().b[17][0]++, input) && (cov_16cg0gp3o4().b[17][1]++, input.focus());
+ },
+ value: editValue,
+ className: "variable-editor",
+ onChange: function onChange(event) {
+ cov_16cg0gp3o4().f[13]++;
+ var value = (cov_16cg0gp3o4().s[47]++, event.target.value);
+ var detected = (cov_16cg0gp3o4().s[48]++, parseInput(value));
+ cov_16cg0gp3o4().s[49]++;
+
+ _this.setState({
+ editValue: value,
+ parsedInput: {
+ type: detected.type,
+ value: detected.value
+ }
+ });
+ },
+ onKeyDown: function onKeyDown(e) {
+ cov_16cg0gp3o4().f[14]++;
+ cov_16cg0gp3o4().s[50]++;
+
+ switch (e.key) {
+ case 'Escape':
+ cov_16cg0gp3o4().b[18][0]++;
+ {
+ cov_16cg0gp3o4().s[51]++;
+
+ _this.setState({
+ editMode: false,
+ editValue: ''
+ });
+
+ cov_16cg0gp3o4().s[52]++;
+ break;
+ }
+
+ case 'Enter':
+ cov_16cg0gp3o4().b[18][1]++;
+ {
+ cov_16cg0gp3o4().s[53]++;
+
+ if ((cov_16cg0gp3o4().b[20][0]++, e.ctrlKey) || (cov_16cg0gp3o4().b[20][1]++, e.metaKey)) {
+ cov_16cg0gp3o4().b[19][0]++;
+ cov_16cg0gp3o4().s[54]++;
+
+ _this.submitEdit(true);
+ } else {
+ cov_16cg0gp3o4().b[19][1]++;
+ }
+
+ cov_16cg0gp3o4().s[55]++;
+ break;
+ }
+ }
+
+ cov_16cg0gp3o4().s[56]++;
+ e.stopPropagation();
+ },
+ placeholder: "update this value"
+ }, getStyle_style(theme, 'edit-input'))), /*#__PURE__*/external_React_default.a.createElement("div", getStyle_style(theme, 'edit-icon-container'), /*#__PURE__*/external_React_default.a.createElement(icons_RemoveCircle, Object.assign({
+ className: "edit-cancel"
+ }, getStyle_style(theme, 'cancel-icon'), {
+ onClick: function onClick() {
+ cov_16cg0gp3o4().f[15]++;
+ cov_16cg0gp3o4().s[57]++;
+
+ _this.setState({
+ editMode: false,
+ editValue: ''
+ });
+ }
+ })), /*#__PURE__*/external_React_default.a.createElement(icons_CheckCircle, Object.assign({
+ className: "edit-check string-value"
+ }, getStyle_style(theme, 'check-icon'), {
+ onClick: function onClick() {
+ cov_16cg0gp3o4().f[16]++;
+ cov_16cg0gp3o4().s[58]++;
+
+ _this.submitEdit();
+ }
+ })), /*#__PURE__*/external_React_default.a.createElement("div", null, _this.showDetected())));
+ });
+ _this.submitEdit = (cov_16cg0gp3o4().s[59]++, function (submit_detected) {
+ cov_16cg0gp3o4().f[17]++;
+
+ var _ref6 = (cov_16cg0gp3o4().s[60]++, _this.props),
+ variable = _ref6.variable,
+ namespace = _ref6.namespace,
+ rjvId = _ref6.rjvId;
+
+ var _ref7 = (cov_16cg0gp3o4().s[61]++, _this.state),
+ editValue = _ref7.editValue,
+ parsedInput = _ref7.parsedInput;
+
+ var new_value = (cov_16cg0gp3o4().s[62]++, editValue);
+ cov_16cg0gp3o4().s[63]++;
+
+ if ((cov_16cg0gp3o4().b[22][0]++, submit_detected) && (cov_16cg0gp3o4().b[22][1]++, parsedInput.type)) {
+ cov_16cg0gp3o4().b[21][0]++;
+ cov_16cg0gp3o4().s[64]++;
+ new_value = parsedInput.value;
+ } else {
+ cov_16cg0gp3o4().b[21][1]++;
+ }
+
+ cov_16cg0gp3o4().s[65]++;
+
+ _this.setState({
+ editMode: false
+ });
+
+ cov_16cg0gp3o4().s[66]++;
+ helpers_dispatcher.dispatch({
+ name: 'VARIABLE_UPDATED',
+ rjvId: rjvId,
+ data: {
+ name: variable.name,
+ namespace: namespace,
+ existing_value: variable.value,
+ new_value: new_value,
+ variable_removed: false
+ }
+ });
+ });
+ _this.showDetected = (cov_16cg0gp3o4().s[67]++, function () {
+ cov_16cg0gp3o4().f[18]++;
+
+ var _ref8 = (cov_16cg0gp3o4().s[68]++, _this.props),
+ theme = _ref8.theme,
+ variable = _ref8.variable,
+ namespace = _ref8.namespace,
+ rjvId = _ref8.rjvId;
+
+ var _ref9 = (cov_16cg0gp3o4().s[69]++, _this.state.parsedInput),
+ type = _ref9.type,
+ value = _ref9.value;
+
+ var detected = (cov_16cg0gp3o4().s[70]++, _this.getDetectedInput());
+ cov_16cg0gp3o4().s[71]++;
+
+ if (detected) {
+ cov_16cg0gp3o4().b[23][0]++;
+ cov_16cg0gp3o4().s[72]++;
+ return /*#__PURE__*/external_React_default.a.createElement("div", null, /*#__PURE__*/external_React_default.a.createElement("div", getStyle_style(theme, 'detected-row'), detected, /*#__PURE__*/external_React_default.a.createElement(icons_CheckCircle, {
+ className: "edit-check detected",
+ style: _objectSpread2({
+ verticalAlign: 'top',
+ paddingLeft: '3px'
+ }, getStyle_style(theme, 'check-icon').style),
+ onClick: function onClick() {
+ cov_16cg0gp3o4().f[19]++;
+ cov_16cg0gp3o4().s[73]++;
+
+ _this.submitEdit(true);
+ }
+ })));
+ } else {
+ cov_16cg0gp3o4().b[23][1]++;
+ }
+ });
+ _this.getDetectedInput = (cov_16cg0gp3o4().s[74]++, function () {
+ cov_16cg0gp3o4().f[20]++;
+
+ var _ref10 = (cov_16cg0gp3o4().s[75]++, _this.state),
+ parsedInput = _ref10.parsedInput;
+
+ var _ref11 = (cov_16cg0gp3o4().s[76]++, parsedInput),
+ type = _ref11.type,
+ value = _ref11.value;
+
+ var _ref12 = (cov_16cg0gp3o4().s[77]++, _assertThisInitialized(_this)),
+ props = _ref12.props;
+
+ var _ref13 = (cov_16cg0gp3o4().s[78]++, props),
+ theme = _ref13.theme;
+
+ cov_16cg0gp3o4().s[79]++;
+
+ if (type !== false) {
+ cov_16cg0gp3o4().b[24][0]++;
+ cov_16cg0gp3o4().s[80]++;
+
+ switch (type.toLowerCase()) {
+ case 'object':
+ cov_16cg0gp3o4().b[25][0]++;
+ cov_16cg0gp3o4().s[81]++;
+ return /*#__PURE__*/external_React_default.a.createElement("span", null, /*#__PURE__*/external_React_default.a.createElement("span", {
+ style: _objectSpread2(_objectSpread2({}, getStyle_style(theme, 'brace').style), {}, {
+ cursor: 'default'
+ })
+ }, '{'), /*#__PURE__*/external_React_default.a.createElement("span", {
+ style: _objectSpread2(_objectSpread2({}, getStyle_style(theme, 'ellipsis').style), {}, {
+ cursor: 'default'
+ })
+ }, "..."), /*#__PURE__*/external_React_default.a.createElement("span", {
+ style: _objectSpread2(_objectSpread2({}, getStyle_style(theme, 'brace').style), {}, {
+ cursor: 'default'
+ })
+ }, '}'));
+
+ case 'array':
+ cov_16cg0gp3o4().b[25][1]++;
+ cov_16cg0gp3o4().s[82]++;
+ return /*#__PURE__*/external_React_default.a.createElement("span", null, /*#__PURE__*/external_React_default.a.createElement("span", {
+ style: _objectSpread2(_objectSpread2({}, getStyle_style(theme, 'brace').style), {}, {
+ cursor: 'default'
+ })
+ }, '['), /*#__PURE__*/external_React_default.a.createElement("span", {
+ style: _objectSpread2(_objectSpread2({}, getStyle_style(theme, 'ellipsis').style), {}, {
+ cursor: 'default'
+ })
+ }, "..."), /*#__PURE__*/external_React_default.a.createElement("span", {
+ style: _objectSpread2(_objectSpread2({}, getStyle_style(theme, 'brace').style), {}, {
+ cursor: 'default'
+ })
+ }, ']'));
+
+ case 'string':
+ cov_16cg0gp3o4().b[25][2]++;
+ cov_16cg0gp3o4().s[83]++;
+ return /*#__PURE__*/external_React_default.a.createElement(String_default, Object.assign({
+ value: value
+ }, props));
+
+ case 'integer':
+ cov_16cg0gp3o4().b[25][3]++;
+ cov_16cg0gp3o4().s[84]++;
+ return /*#__PURE__*/external_React_default.a.createElement(Integer_default, Object.assign({
+ value: value
+ }, props));
+
+ case 'float':
+ cov_16cg0gp3o4().b[25][4]++;
+ cov_16cg0gp3o4().s[85]++;
+ return /*#__PURE__*/external_React_default.a.createElement(Float_default, Object.assign({
+ value: value
+ }, props));
+
+ case 'boolean':
+ cov_16cg0gp3o4().b[25][5]++;
+ cov_16cg0gp3o4().s[86]++;
+ return /*#__PURE__*/external_React_default.a.createElement(Boolean_default, Object.assign({
+ value: value
+ }, props));
+
+ case 'function':
+ cov_16cg0gp3o4().b[25][6]++;
+ cov_16cg0gp3o4().s[87]++;
+ return /*#__PURE__*/external_React_default.a.createElement(Function_default, Object.assign({
+ value: value
+ }, props));
+
+ case 'null':
+ cov_16cg0gp3o4().b[25][7]++;
+ cov_16cg0gp3o4().s[88]++;
+ return /*#__PURE__*/external_React_default.a.createElement(Null_default, props);
+
+ case 'nan':
+ cov_16cg0gp3o4().b[25][8]++;
+ cov_16cg0gp3o4().s[89]++;
+ return /*#__PURE__*/external_React_default.a.createElement(Nan_default, props);
+
+ case 'undefined':
+ cov_16cg0gp3o4().b[25][9]++;
+ cov_16cg0gp3o4().s[90]++;
+ return /*#__PURE__*/external_React_default.a.createElement(Undefined_default, props);
+
+ case 'date':
+ cov_16cg0gp3o4().b[25][10]++;
+ cov_16cg0gp3o4().s[91]++;
+ return /*#__PURE__*/external_React_default.a.createElement(Date_default, Object.assign({
+ value: new Date(value)
+ }, props));
+ }
+ } else {
+ cov_16cg0gp3o4().b[24][1]++;
+ }
+ });
+ cov_16cg0gp3o4().s[1]++;
+ _this.state = {
+ editMode: false,
+ editValue: '',
+ hovered: false,
+ renameKey: false,
+ parsedInput: {
+ type: false,
+ value: null
+ }
+ };
+ return _this;
+ }
+
+ _createClass(VariableEditor, [{
+ key: "render",
+ value: function render() {
+ var _this2 = this;
+
+ cov_16cg0gp3o4().f[1]++;
+
+ var _ref14 = (cov_16cg0gp3o4().s[2]++, this.props),
+ variable = _ref14.variable,
+ src = _ref14.src,
+ singleIndent = _ref14.singleIndent,
+ type = _ref14.type,
+ theme = _ref14.theme,
+ namespace = _ref14.namespace,
+ indentWidth = _ref14.indentWidth,
+ enableClipboard = _ref14.enableClipboard,
+ onEdit = _ref14.onEdit,
+ onDelete = _ref14.onDelete,
+ onSelect = _ref14.onSelect,
+ rjvId = _ref14.rjvId;
+
+ var _ref15 = (cov_16cg0gp3o4().s[3]++, this.state),
+ editMode = _ref15.editMode;
+
+ cov_16cg0gp3o4().s[4]++;
+ return /*#__PURE__*/external_React_default.a.createElement("div", Object.assign({}, getStyle_style(theme, 'objectKeyVal', {
+ paddingLeft: indentWidth * singleIndent
+ }), {
+ onMouseEnter: function onMouseEnter() {
+ cov_16cg0gp3o4().f[2]++;
+ cov_16cg0gp3o4().s[5]++;
+ return _this2.setState(_objectSpread2(_objectSpread2({}, _this2.state), {}, {
+ hovered: true
+ }));
+ },
+ onMouseLeave: function onMouseLeave() {
+ cov_16cg0gp3o4().f[3]++;
+ cov_16cg0gp3o4().s[6]++;
+ return _this2.setState(_objectSpread2(_objectSpread2({}, _this2.state), {}, {
+ hovered: false
+ }));
+ },
+ className: "variable-row",
+ key: variable.name
+ }), type == 'array' ? (cov_16cg0gp3o4().b[0][0]++, /*#__PURE__*/external_React_default.a.createElement("span", Object.assign({}, getStyle_style(theme, 'array-key'), {
+ key: variable.name + '_' + namespace
+ }), variable.name, /*#__PURE__*/external_React_default.a.createElement("div", getStyle_style(theme, 'colon'), ":"))) : (cov_16cg0gp3o4().b[0][1]++, /*#__PURE__*/external_React_default.a.createElement("span", null, /*#__PURE__*/external_React_default.a.createElement("span", Object.assign({}, getStyle_style(theme, 'object-name'), {
+ className: "object-key",
+ key: variable.name + '_' + namespace
+ }), /*#__PURE__*/external_React_default.a.createElement("span", {
+ style: {
+ verticalAlign: 'top'
+ }
+ }, "\""), /*#__PURE__*/external_React_default.a.createElement("span", {
+ style: {
+ display: 'inline-block'
+ }
+ }, variable.name), /*#__PURE__*/external_React_default.a.createElement("span", {
+ style: {
+ verticalAlign: 'top'
+ }
+ }, "\"")), /*#__PURE__*/external_React_default.a.createElement("span", getStyle_style(theme, 'colon'), ":"))), /*#__PURE__*/external_React_default.a.createElement("div", Object.assign({
+ className: "variable-value",
+ onClick: (cov_16cg0gp3o4().b[2][0]++, onSelect === false) && (cov_16cg0gp3o4().b[2][1]++, onEdit === false) ? (cov_16cg0gp3o4().b[1][0]++, null) : (cov_16cg0gp3o4().b[1][1]++, function (e) {
+ cov_16cg0gp3o4().f[4]++;
+ var location = (cov_16cg0gp3o4().s[7]++, _toConsumableArray(namespace));
+ cov_16cg0gp3o4().s[8]++;
+
+ if (((cov_16cg0gp3o4().b[4][0]++, e.ctrlKey) || (cov_16cg0gp3o4().b[4][1]++, e.metaKey)) && (cov_16cg0gp3o4().b[4][2]++, onEdit !== false)) {
+ cov_16cg0gp3o4().b[3][0]++;
+ cov_16cg0gp3o4().s[9]++;
+
+ _this2.prepopInput(variable);
+ } else {
+ cov_16cg0gp3o4().b[3][1]++;
+ cov_16cg0gp3o4().s[10]++;
+
+ if (onSelect !== false) {
+ cov_16cg0gp3o4().b[5][0]++;
+ cov_16cg0gp3o4().s[11]++;
+ location.shift();
+ cov_16cg0gp3o4().s[12]++;
+ onSelect(_objectSpread2(_objectSpread2({}, variable), {}, {
+ namespace: location
+ }));
+ } else {
+ cov_16cg0gp3o4().b[5][1]++;
+ }
+ }
+ })
+ }, getStyle_style(theme, 'variableValue', {
+ cursor: onSelect === false ? (cov_16cg0gp3o4().b[6][0]++, 'default') : (cov_16cg0gp3o4().b[6][1]++, 'pointer')
+ })), this.getValue(variable, editMode)), enableClipboard ? (cov_16cg0gp3o4().b[7][0]++, /*#__PURE__*/external_React_default.a.createElement(CopyToClipboard_default, Object.assign({
+ rowHovered: this.state.hovered,
+ hidden: editMode,
+ src: variable.value,
+ clickCallback: enableClipboard
+ }, {
+ theme: theme,
+ namespace: namespace
+ }))) : (cov_16cg0gp3o4().b[7][1]++, null), (cov_16cg0gp3o4().b[9][0]++, onEdit !== false) && (cov_16cg0gp3o4().b[9][1]++, editMode == false) ? (cov_16cg0gp3o4().b[8][0]++, this.getEditIcon()) : (cov_16cg0gp3o4().b[8][1]++, null), (cov_16cg0gp3o4().b[11][0]++, onDelete !== false) && (cov_16cg0gp3o4().b[11][1]++, editMode == false) ? (cov_16cg0gp3o4().b[10][0]++, this.getRemoveIcon()) : (cov_16cg0gp3o4().b[10][1]++, null));
+ }
+ }]);
+
+ return VariableEditor;
+}((external_React_default.a.PureComponent)); //export component
+
+
+/* harmony default export */ var components_VariableEditor = (VariableEditor_VariableEditor);
+// CONCATENATED MODULE: ./src/js/components/VariableMeta.js
+
+
+
+
+
+
+function cov_ubs4mv4hf() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/components/VariableMeta.js";
+ var hash = "338f6c0ba2bcffb1cb1d2723d6333b5bd1d8837c";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/components/VariableMeta.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 14,
+ column: 20
+ },
+ end: {
+ line: 23,
+ column: 5
+ }
+ },
+ "1": {
+ start: {
+ line: 15,
+ column: 51
+ },
+ end: {
+ line: 15,
+ column: 61
+ }
+ },
+ "2": {
+ start: {
+ line: 16,
+ column: 8
+ },
+ end: {
+ line: 22,
+ column: 9
+ }
+ },
+ "3": {
+ start: {
+ line: 17,
+ column: 12
+ },
+ end: {
+ line: 21,
+ column: 14
+ }
+ },
+ "4": {
+ start: {
+ line: 25,
+ column: 22
+ },
+ end: {
+ line: 70,
+ column: 5
+ }
+ },
+ "5": {
+ start: {
+ line: 26,
+ column: 62
+ },
+ end: {
+ line: 26,
+ column: 72
+ }
+ },
+ "6": {
+ start: {
+ line: 28,
+ column: 8
+ },
+ end: {
+ line: 69,
+ column: 10
+ }
+ },
+ "7": {
+ start: {
+ line: 40,
+ column: 40
+ },
+ end: {
+ line: 49,
+ column: 25
+ }
+ },
+ "8": {
+ start: {
+ line: 50,
+ column: 24
+ },
+ end: {
+ line: 65,
+ column: 25
+ }
+ },
+ "9": {
+ start: {
+ line: 51,
+ column: 28
+ },
+ end: {
+ line: 55,
+ column: 31
+ }
+ },
+ "10": {
+ start: {
+ line: 57,
+ column: 28
+ },
+ end: {
+ line: 64,
+ column: 31
+ }
+ },
+ "11": {
+ start: {
+ line: 72,
+ column: 22
+ },
+ end: {
+ line: 107,
+ column: 5
+ }
+ },
+ "12": {
+ start: {
+ line: 73,
+ column: 62
+ },
+ end: {
+ line: 73,
+ column: 72
+ }
+ },
+ "13": {
+ start: {
+ line: 76,
+ column: 8
+ },
+ end: {
+ line: 78,
+ column: 9
+ }
+ },
+ "14": {
+ start: {
+ line: 77,
+ column: 12
+ },
+ end: {
+ line: 77,
+ column: 19
+ }
+ },
+ "15": {
+ start: {
+ line: 79,
+ column: 8
+ },
+ end: {
+ line: 106,
+ column: 10
+ }
+ },
+ "16": {
+ start: {
+ line: 90,
+ column: 24
+ },
+ end: {
+ line: 102,
+ column: 27
+ }
+ },
+ "17": {
+ start: {
+ line: 109,
+ column: 13
+ },
+ end: {
+ line: 142,
+ column: 5
+ }
+ },
+ "18": {
+ start: {
+ line: 118,
+ column: 12
+ },
+ end: {
+ line: 118,
+ column: 22
+ }
+ },
+ "19": {
+ start: {
+ line: 119,
+ column: 8
+ },
+ end: {
+ line: 141,
+ column: 10
+ }
+ },
+ "20": {
+ start: {
+ line: 124,
+ column: 20
+ },
+ end: {
+ line: 124,
+ column: 40
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "(anonymous_0)",
+ decl: {
+ start: {
+ line: 14,
+ column: 20
+ },
+ end: {
+ line: 14,
+ column: 21
+ }
+ },
+ loc: {
+ start: {
+ line: 14,
+ column: 26
+ },
+ end: {
+ line: 23,
+ column: 5
+ }
+ },
+ line: 14
+ },
+ "1": {
+ name: "(anonymous_1)",
+ decl: {
+ start: {
+ line: 25,
+ column: 22
+ },
+ end: {
+ line: 25,
+ column: 23
+ }
+ },
+ loc: {
+ start: {
+ line: 25,
+ column: 36
+ },
+ end: {
+ line: 70,
+ column: 5
+ }
+ },
+ line: 25
+ },
+ "2": {
+ name: "(anonymous_2)",
+ decl: {
+ start: {
+ line: 39,
+ column: 29
+ },
+ end: {
+ line: 39,
+ column: 30
+ }
+ },
+ loc: {
+ start: {
+ line: 39,
+ column: 35
+ },
+ end: {
+ line: 66,
+ column: 21
+ }
+ },
+ line: 39
+ },
+ "3": {
+ name: "(anonymous_3)",
+ decl: {
+ start: {
+ line: 72,
+ column: 22
+ },
+ end: {
+ line: 72,
+ column: 23
+ }
+ },
+ loc: {
+ start: {
+ line: 72,
+ column: 36
+ },
+ end: {
+ line: 107,
+ column: 5
+ }
+ },
+ line: 72
+ },
+ "4": {
+ name: "(anonymous_4)",
+ decl: {
+ start: {
+ line: 89,
+ column: 29
+ },
+ end: {
+ line: 89,
+ column: 30
+ }
+ },
+ loc: {
+ start: {
+ line: 89,
+ column: 35
+ },
+ end: {
+ line: 103,
+ column: 21
+ }
+ },
+ line: 89
+ },
+ "5": {
+ name: "(anonymous_5)",
+ decl: {
+ start: {
+ line: 109,
+ column: 13
+ },
+ end: {
+ line: 109,
+ column: 14
+ }
+ },
+ loc: {
+ start: {
+ line: 109,
+ column: 19
+ },
+ end: {
+ line: 142,
+ column: 5
+ }
+ },
+ line: 109
+ },
+ "6": {
+ name: "(anonymous_6)",
+ decl: {
+ start: {
+ line: 123,
+ column: 25
+ },
+ end: {
+ line: 123,
+ column: 26
+ }
+ },
+ loc: {
+ start: {
+ line: 123,
+ column: 30
+ },
+ end: {
+ line: 125,
+ column: 17
+ }
+ },
+ line: 123
+ }
+ },
+ branchMap: {
+ "0": {
+ loc: {
+ start: {
+ line: 16,
+ column: 8
+ },
+ end: {
+ line: 22,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 16,
+ column: 8
+ },
+ end: {
+ line: 22,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 16,
+ column: 8
+ },
+ end: {
+ line: 22,
+ column: 9
+ }
+ }],
+ line: 16
+ },
+ "1": {
+ loc: {
+ start: {
+ line: 19,
+ column: 32
+ },
+ end: {
+ line: 19,
+ column: 53
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 19,
+ column: 45
+ },
+ end: {
+ line: 19,
+ column: 47
+ }
+ }, {
+ start: {
+ line: 19,
+ column: 50
+ },
+ end: {
+ line: 19,
+ column: 53
+ }
+ }],
+ line: 19
+ },
+ "2": {
+ loc: {
+ start: {
+ line: 33,
+ column: 29
+ },
+ end: {
+ line: 33,
+ column: 65
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 33,
+ column: 42
+ },
+ end: {
+ line: 33,
+ column: 56
+ }
+ }, {
+ start: {
+ line: 33,
+ column: 59
+ },
+ end: {
+ line: 33,
+ column: 65
+ }
+ }],
+ line: 33
+ },
+ "3": {
+ loc: {
+ start: {
+ line: 41,
+ column: 34
+ },
+ end: {
+ line: 41,
+ column: 57
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 41,
+ column: 46
+ },
+ end: {
+ line: 41,
+ column: 50
+ }
+ }, {
+ start: {
+ line: 41,
+ column: 53
+ },
+ end: {
+ line: 41,
+ column: 57
+ }
+ }],
+ line: 41
+ },
+ "4": {
+ loc: {
+ start: {
+ line: 50,
+ column: 24
+ },
+ end: {
+ line: 65,
+ column: 25
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 50,
+ column: 24
+ },
+ end: {
+ line: 65,
+ column: 25
+ }
+ }, {
+ start: {
+ line: 50,
+ column: 24
+ },
+ end: {
+ line: 65,
+ column: 25
+ }
+ }],
+ line: 50
+ },
+ "5": {
+ loc: {
+ start: {
+ line: 76,
+ column: 8
+ },
+ end: {
+ line: 78,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 76,
+ column: 8
+ },
+ end: {
+ line: 78,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 76,
+ column: 8
+ },
+ end: {
+ line: 78,
+ column: 9
+ }
+ }],
+ line: 76
+ },
+ "6": {
+ loc: {
+ start: {
+ line: 83,
+ column: 29
+ },
+ end: {
+ line: 83,
+ column: 65
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 83,
+ column: 42
+ },
+ end: {
+ line: 83,
+ column: 56
+ }
+ }, {
+ start: {
+ line: 83,
+ column: 59
+ },
+ end: {
+ line: 83,
+ column: 65
+ }
+ }],
+ line: 83
+ },
+ "7": {
+ loc: {
+ start: {
+ line: 130,
+ column: 17
+ },
+ end: {
+ line: 136,
+ column: 24
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 131,
+ column: 20
+ },
+ end: {
+ line: 135,
+ column: 22
+ }
+ }, {
+ start: {
+ line: 136,
+ column: 20
+ },
+ end: {
+ line: 136,
+ column: 24
+ }
+ }],
+ line: 130
+ },
+ "8": {
+ loc: {
+ start: {
+ line: 138,
+ column: 17
+ },
+ end: {
+ line: 138,
+ column: 74
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 138,
+ column: 35
+ },
+ end: {
+ line: 138,
+ column: 67
+ }
+ }, {
+ start: {
+ line: 138,
+ column: 70
+ },
+ end: {
+ line: 138,
+ column: 74
+ }
+ }],
+ line: 138
+ },
+ "9": {
+ loc: {
+ start: {
+ line: 139,
+ column: 17
+ },
+ end: {
+ line: 139,
+ column: 77
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 139,
+ column: 38
+ },
+ end: {
+ line: 139,
+ column: 70
+ }
+ }, {
+ start: {
+ line: 139,
+ column: 73
+ },
+ end: {
+ line: 139,
+ column: 77
+ }
+ }],
+ line: 139
+ }
+ },
+ s: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0,
+ "7": 0,
+ "8": 0,
+ "9": 0,
+ "10": 0,
+ "11": 0,
+ "12": 0,
+ "13": 0,
+ "14": 0,
+ "15": 0,
+ "16": 0,
+ "17": 0,
+ "18": 0,
+ "19": 0,
+ "20": 0
+ },
+ f: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0
+ },
+ b: {
+ "0": [0, 0],
+ "1": [0, 0],
+ "2": [0, 0],
+ "3": [0, 0],
+ "4": [0, 0],
+ "5": [0, 0],
+ "6": [0, 0],
+ "7": [0, 0],
+ "8": [0, 0],
+ "9": [0, 0]
+ },
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "338f6c0ba2bcffb1cb1d2723d6333b5bd1d8837c"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
+
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
+
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_ubs4mv4hf = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
+
+cov_ubs4mv4hf();
+
+
+
+ //icons
+
+ //theme
+
+
+
+var VariableMeta_default = /*#__PURE__*/function (_React$PureComponent) {
+ _inherits(_default, _React$PureComponent);
+
+ var _super = _createSuper(_default);
+
+ function _default() {
+ var _this;
+
+ _classCallCheck(this, _default);
+
+ for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
+ args[_key] = arguments[_key];
+ }
+
+ _this = _super.call.apply(_super, [this].concat(args));
+ _this.getObjectSize = (cov_ubs4mv4hf().s[0]++, function () {
+ cov_ubs4mv4hf().f[0]++;
+
+ var _ref = (cov_ubs4mv4hf().s[1]++, _this.props),
+ size = _ref.size,
+ theme = _ref.theme,
+ displayObjectSize = _ref.displayObjectSize;
+
+ cov_ubs4mv4hf().s[2]++;
+
+ if (displayObjectSize) {
+ cov_ubs4mv4hf().b[0][0]++;
+ cov_ubs4mv4hf().s[3]++;
+ return /*#__PURE__*/external_React_default.a.createElement("span", Object.assign({
+ className: "object-size"
+ }, getStyle_style(theme, 'object-size')), size, " item", size === 1 ? (cov_ubs4mv4hf().b[1][0]++, '') : (cov_ubs4mv4hf().b[1][1]++, 's'));
+ } else {
+ cov_ubs4mv4hf().b[0][1]++;
+ }
+ });
+ _this.getAddAttribute = (cov_ubs4mv4hf().s[4]++, function (rowHovered) {
+ cov_ubs4mv4hf().f[1]++;
+
+ var _ref2 = (cov_ubs4mv4hf().s[5]++, _this.props),
+ theme = _ref2.theme,
+ namespace = _ref2.namespace,
+ name = _ref2.name,
+ src = _ref2.src,
+ rjvId = _ref2.rjvId,
+ depth = _ref2.depth;
+
+ cov_ubs4mv4hf().s[6]++;
+ return /*#__PURE__*/external_React_default.a.createElement("span", {
+ className: "click-to-add",
+ style: {
+ verticalAlign: 'top',
+ display: rowHovered ? (cov_ubs4mv4hf().b[2][0]++, 'inline-block') : (cov_ubs4mv4hf().b[2][1]++, 'none')
+ }
+ }, /*#__PURE__*/external_React_default.a.createElement(icons_AddCircle, Object.assign({
+ className: "click-to-add-icon"
+ }, getStyle_style(theme, 'addVarIcon'), {
+ onClick: function onClick() {
+ cov_ubs4mv4hf().f[2]++;
+ var request = (cov_ubs4mv4hf().s[7]++, {
+ name: depth > 0 ? (cov_ubs4mv4hf().b[3][0]++, name) : (cov_ubs4mv4hf().b[3][1]++, null),
+ namespace: namespace.splice(0, namespace.length - 1),
+ existing_value: src,
+ variable_removed: false,
+ key_name: null
+ });
+ cov_ubs4mv4hf().s[8]++;
+
+ if (toType(src) === 'object') {
+ cov_ubs4mv4hf().b[4][0]++;
+ cov_ubs4mv4hf().s[9]++;
+ helpers_dispatcher.dispatch({
+ name: 'ADD_VARIABLE_KEY_REQUEST',
+ rjvId: rjvId,
+ data: request
+ });
+ } else {
+ cov_ubs4mv4hf().b[4][1]++;
+ cov_ubs4mv4hf().s[10]++;
+ helpers_dispatcher.dispatch({
+ name: 'VARIABLE_ADDED',
+ rjvId: rjvId,
+ data: _objectSpread2(_objectSpread2({}, request), {}, {
+ new_value: [].concat(_toConsumableArray(src), [null])
+ })
+ });
+ }
+ }
+ })));
+ });
+ _this.getRemoveObject = (cov_ubs4mv4hf().s[11]++, function (rowHovered) {
+ cov_ubs4mv4hf().f[3]++;
+
+ var _ref3 = (cov_ubs4mv4hf().s[12]++, _this.props),
+ theme = _ref3.theme,
+ hover = _ref3.hover,
+ namespace = _ref3.namespace,
+ name = _ref3.name,
+ src = _ref3.src,
+ rjvId = _ref3.rjvId; //don't allow deleting of root node
+
+
+ cov_ubs4mv4hf().s[13]++;
+
+ if (namespace.length === 1) {
+ cov_ubs4mv4hf().b[5][0]++;
+ cov_ubs4mv4hf().s[14]++;
+ return;
+ } else {
+ cov_ubs4mv4hf().b[5][1]++;
+ }
+
+ cov_ubs4mv4hf().s[15]++;
+ return /*#__PURE__*/external_React_default.a.createElement("span", {
+ className: "click-to-remove",
+ style: {
+ display: rowHovered ? (cov_ubs4mv4hf().b[6][0]++, 'inline-block') : (cov_ubs4mv4hf().b[6][1]++, 'none')
+ }
+ }, /*#__PURE__*/external_React_default.a.createElement(icons_RemoveCircle, Object.assign({
+ className: "click-to-remove-icon"
+ }, getStyle_style(theme, 'removeVarIcon'), {
+ onClick: function onClick() {
+ cov_ubs4mv4hf().f[4]++;
+ cov_ubs4mv4hf().s[16]++;
+ helpers_dispatcher.dispatch({
+ name: 'VARIABLE_REMOVED',
+ rjvId: rjvId,
+ data: {
+ name: name,
+ namespace: namespace.splice(0, namespace.length - 1),
+ existing_value: src,
+ variable_removed: true
+ }
+ });
+ }
+ })));
+ });
+ _this.render = (cov_ubs4mv4hf().s[17]++, function () {
+ cov_ubs4mv4hf().f[5]++;
+
+ var _ref4 = (cov_ubs4mv4hf().s[18]++, _this.props),
+ theme = _ref4.theme,
+ onDelete = _ref4.onDelete,
+ onAdd = _ref4.onAdd,
+ enableClipboard = _ref4.enableClipboard,
+ src = _ref4.src,
+ namespace = _ref4.namespace,
+ rowHovered = _ref4.rowHovered;
+
+ cov_ubs4mv4hf().s[19]++;
+ return /*#__PURE__*/external_React_default.a.createElement("div", Object.assign({}, getStyle_style(theme, 'object-meta-data'), {
+ className: "object-meta-data",
+ onClick: function onClick(e) {
+ cov_ubs4mv4hf().f[6]++;
+ cov_ubs4mv4hf().s[20]++;
+ e.stopPropagation();
+ }
+ }), _this.getObjectSize(), enableClipboard ? (cov_ubs4mv4hf().b[7][0]++, /*#__PURE__*/external_React_default.a.createElement(CopyToClipboard_default, Object.assign({
+ rowHovered: rowHovered,
+ clickCallback: enableClipboard
+ }, {
+ src: src,
+ theme: theme,
+ namespace: namespace
+ }))) : (cov_ubs4mv4hf().b[7][1]++, null), onAdd !== false ? (cov_ubs4mv4hf().b[8][0]++, _this.getAddAttribute(rowHovered)) : (cov_ubs4mv4hf().b[8][1]++, null), onDelete !== false ? (cov_ubs4mv4hf().b[9][0]++, _this.getRemoveObject(rowHovered)) : (cov_ubs4mv4hf().b[9][1]++, null));
+ });
+ return _this;
+ }
+
+ return _default;
+}((external_React_default.a.PureComponent));
+
+
+// CONCATENATED MODULE: ./src/js/components/ObjectName.js
+function cov_17le1f8mqd() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/components/ObjectName.js";
+ var hash = "1facedd9e9d1c74a467bafdbc45a2924e93e1645";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/components/ObjectName.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 12,
+ column: 8
+ },
+ end: {
+ line: 12,
+ column: 13
+ }
+ },
+ "1": {
+ start: {
+ line: 14,
+ column: 25
+ },
+ end: {
+ line: 14,
+ column: 53
+ }
+ },
+ "2": {
+ start: {
+ line: 16,
+ column: 4
+ },
+ end: {
+ line: 40,
+ column: 5
+ }
+ },
+ "3": {
+ start: {
+ line: 17,
+ column: 8
+ },
+ end: {
+ line: 17,
+ column: 24
+ }
+ },
+ "4": {
+ start: {
+ line: 18,
+ column: 11
+ },
+ end: {
+ line: 40,
+ column: 5
+ }
+ },
+ "5": {
+ start: {
+ line: 19,
+ column: 8
+ },
+ end: {
+ line: 24,
+ column: 10
+ }
+ },
+ "6": {
+ start: {
+ line: 26,
+ column: 8
+ },
+ end: {
+ line: 39,
+ column: 10
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "getObjectName",
+ decl: {
+ start: {
+ line: 4,
+ column: 24
+ },
+ end: {
+ line: 4,
+ column: 37
+ }
+ },
+ loc: {
+ start: {
+ line: 4,
+ column: 45
+ },
+ end: {
+ line: 41,
+ column: 1
+ }
+ },
+ line: 4
+ }
+ },
+ branchMap: {
+ "0": {
+ loc: {
+ start: {
+ line: 14,
+ column: 25
+ },
+ end: {
+ line: 14,
+ column: 53
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 14,
+ column: 38
+ },
+ end: {
+ line: 14,
+ column: 48
+ }
+ }, {
+ start: {
+ line: 14,
+ column: 51
+ },
+ end: {
+ line: 14,
+ column: 53
+ }
+ }],
+ line: 14
+ },
+ "1": {
+ loc: {
+ start: {
+ line: 16,
+ column: 4
+ },
+ end: {
+ line: 40,
+ column: 5
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 16,
+ column: 4
+ },
+ end: {
+ line: 40,
+ column: 5
+ }
+ }, {
+ start: {
+ line: 16,
+ column: 4
+ },
+ end: {
+ line: 40,
+ column: 5
+ }
+ }],
+ line: 16
+ },
+ "2": {
+ loc: {
+ start: {
+ line: 16,
+ column: 8
+ },
+ end: {
+ line: 16,
+ column: 52
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 16,
+ column: 8
+ },
+ end: {
+ line: 16,
+ column: 15
+ }
+ }, {
+ start: {
+ line: 16,
+ column: 20
+ },
+ end: {
+ line: 16,
+ column: 34
+ }
+ }, {
+ start: {
+ line: 16,
+ column: 38
+ },
+ end: {
+ line: 16,
+ column: 51
+ }
+ }],
+ line: 16
+ },
+ "3": {
+ loc: {
+ start: {
+ line: 18,
+ column: 11
+ },
+ end: {
+ line: 40,
+ column: 5
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 18,
+ column: 11
+ },
+ end: {
+ line: 40,
+ column: 5
+ }
+ }, {
+ start: {
+ line: 18,
+ column: 11
+ },
+ end: {
+ line: 40,
+ column: 5
+ }
+ }],
+ line: 18
+ },
+ "4": {
+ loc: {
+ start: {
+ line: 29,
+ column: 21
+ },
+ end: {
+ line: 31,
+ column: 21
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 29,
+ column: 21
+ },
+ end: {
+ line: 29,
+ column: 33
+ }
+ }, {
+ start: {
+ line: 30,
+ column: 24
+ },
+ end: {
+ line: 30,
+ column: 71
+ }
+ }],
+ line: 29
+ },
+ "5": {
+ loc: {
+ start: {
+ line: 33,
+ column: 21
+ },
+ end: {
+ line: 35,
+ column: 21
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 33,
+ column: 21
+ },
+ end: {
+ line: 33,
+ column: 33
+ }
+ }, {
+ start: {
+ line: 34,
+ column: 24
+ },
+ end: {
+ line: 34,
+ column: 71
+ }
+ }],
+ line: 33
+ }
+ },
+ s: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0
+ },
+ f: {
+ "0": 0
+ },
+ b: {
+ "0": [0, 0],
+ "1": [0, 0],
+ "2": [0, 0, 0],
+ "3": [0, 0],
+ "4": [0, 0],
+ "5": [0, 0]
+ },
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "1facedd9e9d1c74a467bafdbc45a2924e93e1645"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
+
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
+
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_17le1f8mqd = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
+
+cov_17le1f8mqd();
+
+
+function getObjectName(props) {
+ cov_17le1f8mqd().f[0]++;
+
+ var _ref = (cov_17le1f8mqd().s[0]++, props),
+ parent_type = _ref.parent_type,
+ namespace = _ref.namespace,
+ quotesOnKeys = _ref.quotesOnKeys,
+ theme = _ref.theme,
+ jsvRoot = _ref.jsvRoot,
+ name = _ref.name;
+
+ var display_name = (cov_17le1f8mqd().s[1]++, props.name ? (cov_17le1f8mqd().b[0][0]++, props.name) : (cov_17le1f8mqd().b[0][1]++, ''));
+ cov_17le1f8mqd().s[2]++;
+
+ if ((cov_17le1f8mqd().b[2][0]++, jsvRoot) && ((cov_17le1f8mqd().b[2][1]++, name === false) || (cov_17le1f8mqd().b[2][2]++, name === null))) {
+ cov_17le1f8mqd().b[1][0]++;
+ cov_17le1f8mqd().s[3]++;
+ return /*#__PURE__*/external_React_default.a.createElement("span", null);
+ } else {
+ cov_17le1f8mqd().b[1][1]++;
+ cov_17le1f8mqd().s[4]++;
+
+ if (parent_type == 'array') {
+ cov_17le1f8mqd().b[3][0]++;
+ cov_17le1f8mqd().s[5]++;
+ return /*#__PURE__*/external_React_default.a.createElement("span", Object.assign({}, getStyle_style(theme, 'array-key'), {
+ key: namespace
+ }), /*#__PURE__*/external_React_default.a.createElement("span", {
+ className: "array-key"
+ }, display_name), /*#__PURE__*/external_React_default.a.createElement("span", getStyle_style(theme, 'colon'), ":"));
+ } else {
+ cov_17le1f8mqd().b[3][1]++;
+ cov_17le1f8mqd().s[6]++;
+ return /*#__PURE__*/external_React_default.a.createElement("span", Object.assign({}, getStyle_style(theme, 'object-name'), {
+ key: namespace
+ }), /*#__PURE__*/external_React_default.a.createElement("span", {
+ className: "object-key"
+ }, (cov_17le1f8mqd().b[4][0]++, quotesOnKeys) && (cov_17le1f8mqd().b[4][1]++, /*#__PURE__*/external_React_default.a.createElement("span", {
+ style: {
+ verticalAlign: 'top'
+ }
+ }, "\"")), /*#__PURE__*/external_React_default.a.createElement("span", null, display_name), (cov_17le1f8mqd().b[5][0]++, quotesOnKeys) && (cov_17le1f8mqd().b[5][1]++, /*#__PURE__*/external_React_default.a.createElement("span", {
+ style: {
+ verticalAlign: 'top'
+ }
+ }, "\""))), /*#__PURE__*/external_React_default.a.createElement("span", getStyle_style(theme, 'colon'), ":"));
+ }
+ }
+}
+// CONCATENATED MODULE: ./src/js/components/ToggleIcons.js
+function cov_1gfkno6nej() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/components/ToggleIcons.js";
+ var hash = "06402b5625757974ffcae082905eb0d40d5ada9f";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/components/ToggleIcons.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 14,
+ column: 33
+ },
+ end: {
+ line: 14,
+ column: 38
+ }
+ },
+ "1": {
+ start: {
+ line: 15,
+ column: 4
+ },
+ end: {
+ line: 37,
+ column: 5
+ }
+ },
+ "2": {
+ start: {
+ line: 17,
+ column: 12
+ },
+ end: {
+ line: 22,
+ column: 14
+ }
+ },
+ "3": {
+ start: {
+ line: 24,
+ column: 12
+ },
+ end: {
+ line: 29,
+ column: 14
+ }
+ },
+ "4": {
+ start: {
+ line: 31,
+ column: 12
+ },
+ end: {
+ line: 36,
+ column: 14
+ }
+ },
+ "5": {
+ start: {
+ line: 41,
+ column: 33
+ },
+ end: {
+ line: 41,
+ column: 38
+ }
+ },
+ "6": {
+ start: {
+ line: 42,
+ column: 4
+ },
+ end: {
+ line: 64,
+ column: 5
+ }
+ },
+ "7": {
+ start: {
+ line: 44,
+ column: 12
+ },
+ end: {
+ line: 49,
+ column: 14
+ }
+ },
+ "8": {
+ start: {
+ line: 51,
+ column: 12
+ },
+ end: {
+ line: 56,
+ column: 14
+ }
+ },
+ "9": {
+ start: {
+ line: 58,
+ column: 12
+ },
+ end: {
+ line: 63,
+ column: 14
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "ExpandedIcon",
+ decl: {
+ start: {
+ line: 13,
+ column: 16
+ },
+ end: {
+ line: 13,
+ column: 28
+ }
+ },
+ loc: {
+ start: {
+ line: 13,
+ column: 36
+ },
+ end: {
+ line: 38,
+ column: 1
+ }
+ },
+ line: 13
+ },
+ "1": {
+ name: "CollapsedIcon",
+ decl: {
+ start: {
+ line: 40,
+ column: 16
+ },
+ end: {
+ line: 40,
+ column: 29
+ }
+ },
+ loc: {
+ start: {
+ line: 40,
+ column: 37
+ },
+ end: {
+ line: 65,
+ column: 1
+ }
+ },
+ line: 40
+ }
+ },
+ branchMap: {
+ "0": {
+ loc: {
+ start: {
+ line: 15,
+ column: 4
+ },
+ end: {
+ line: 37,
+ column: 5
+ }
+ },
+ type: "switch",
+ locations: [{
+ start: {
+ line: 16,
+ column: 8
+ },
+ end: {
+ line: 22,
+ column: 14
+ }
+ }, {
+ start: {
+ line: 23,
+ column: 8
+ },
+ end: {
+ line: 29,
+ column: 14
+ }
+ }, {
+ start: {
+ line: 30,
+ column: 8
+ },
+ end: {
+ line: 36,
+ column: 14
+ }
+ }],
+ line: 15
+ },
+ "1": {
+ loc: {
+ start: {
+ line: 42,
+ column: 4
+ },
+ end: {
+ line: 64,
+ column: 5
+ }
+ },
+ type: "switch",
+ locations: [{
+ start: {
+ line: 43,
+ column: 8
+ },
+ end: {
+ line: 49,
+ column: 14
+ }
+ }, {
+ start: {
+ line: 50,
+ column: 8
+ },
+ end: {
+ line: 56,
+ column: 14
+ }
+ }, {
+ start: {
+ line: 57,
+ column: 8
+ },
+ end: {
+ line: 63,
+ column: 14
+ }
+ }],
+ line: 42
+ }
+ },
+ s: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0,
+ "7": 0,
+ "8": 0,
+ "9": 0
+ },
+ f: {
+ "0": 0,
+ "1": 0
+ },
+ b: {
+ "0": [0, 0, 0],
+ "1": [0, 0, 0]
+ },
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "06402b5625757974ffcae082905eb0d40d5ada9f"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
+
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
+
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_1gfkno6nej = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
+
+cov_1gfkno6nej();
+
+
+
+function ExpandedIcon(props) {
+ cov_1gfkno6nej().f[0]++;
+
+ var _ref = (cov_1gfkno6nej().s[0]++, props),
+ theme = _ref.theme,
+ iconStyle = _ref.iconStyle;
+
+ cov_1gfkno6nej().s[1]++;
+
+ switch (iconStyle) {
+ case 'triangle':
+ cov_1gfkno6nej().b[0][0]++;
+ cov_1gfkno6nej().s[2]++;
+ return /*#__PURE__*/external_React_default.a.createElement(icons_ArrowDown, Object.assign({}, getStyle_style(theme, 'expanded-icon'), {
+ className: "expanded-icon"
+ }));
+
+ case 'square':
+ cov_1gfkno6nej().b[0][1]++;
+ cov_1gfkno6nej().s[3]++;
+ return /*#__PURE__*/external_React_default.a.createElement(icons_SquareMinus, Object.assign({}, getStyle_style(theme, 'expanded-icon'), {
+ className: "expanded-icon"
+ }));
+
+ default:
+ cov_1gfkno6nej().b[0][2]++;
+ cov_1gfkno6nej().s[4]++;
+ return /*#__PURE__*/external_React_default.a.createElement(icons_CircleMinus, Object.assign({}, getStyle_style(theme, 'expanded-icon'), {
+ className: "expanded-icon"
+ }));
+ }
+}
+function CollapsedIcon(props) {
+ cov_1gfkno6nej().f[1]++;
+
+ var _ref2 = (cov_1gfkno6nej().s[5]++, props),
+ theme = _ref2.theme,
+ iconStyle = _ref2.iconStyle;
+
+ cov_1gfkno6nej().s[6]++;
+
+ switch (iconStyle) {
+ case 'triangle':
+ cov_1gfkno6nej().b[1][0]++;
+ cov_1gfkno6nej().s[7]++;
+ return /*#__PURE__*/external_React_default.a.createElement(icons_ArrowRight, Object.assign({}, getStyle_style(theme, 'collapsed-icon'), {
+ className: "collapsed-icon"
+ }));
+
+ case 'square':
+ cov_1gfkno6nej().b[1][1]++;
+ cov_1gfkno6nej().s[8]++;
+ return /*#__PURE__*/external_React_default.a.createElement(icons_SquarePlus, Object.assign({}, getStyle_style(theme, 'collapsed-icon'), {
+ className: "collapsed-icon"
+ }));
+
+ default:
+ cov_1gfkno6nej().b[1][2]++;
+ cov_1gfkno6nej().s[9]++;
+ return /*#__PURE__*/external_React_default.a.createElement(icons_CirclePlus, Object.assign({}, getStyle_style(theme, 'collapsed-icon'), {
+ className: "collapsed-icon"
+ }));
+ }
+}
+// CONCATENATED MODULE: ./src/js/components/ArrayGroup.js
+
+
+
+
+
+
+
+function cov_30e5qjl1o() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/components/ArrayGroup.js";
+ var hash = "8615a2e53494fc046848618ce88ecae0c0bd3754";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/components/ArrayGroup.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 12,
+ column: 22
+ },
+ end: {
+ line: 12,
+ column: 23
+ }
+ },
+ "1": {
+ start: {
+ line: 16,
+ column: 8
+ },
+ end: {
+ line: 16,
+ column: 21
+ }
+ },
+ "2": {
+ start: {
+ line: 17,
+ column: 8
+ },
+ end: {
+ line: 19,
+ column: 10
+ }
+ },
+ "3": {
+ start: {
+ line: 22,
+ column: 22
+ },
+ end: {
+ line: 31,
+ column: 5
+ }
+ },
+ "4": {
+ start: {
+ line: 23,
+ column: 28
+ },
+ end: {
+ line: 23,
+ column: 30
+ }
+ },
+ "5": {
+ start: {
+ line: 24,
+ column: 8
+ },
+ end: {
+ line: 26,
+ column: 9
+ }
+ },
+ "6": {
+ start: {
+ line: 25,
+ column: 12
+ },
+ end: {
+ line: 25,
+ column: 53
+ }
+ },
+ "7": {
+ start: {
+ line: 27,
+ column: 8
+ },
+ end: {
+ line: 27,
+ column: 41
+ }
+ },
+ "8": {
+ start: {
+ line: 28,
+ column: 8
+ },
+ end: {
+ line: 30,
+ column: 11
+ }
+ },
+ "9": {
+ start: {
+ line: 34,
+ column: 37
+ },
+ end: {
+ line: 34,
+ column: 47
+ }
+ },
+ "10": {
+ start: {
+ line: 36,
+ column: 8
+ },
+ end: {
+ line: 38,
+ column: 9
+ }
+ },
+ "11": {
+ start: {
+ line: 37,
+ column: 12
+ },
+ end: {
+ line: 37,
+ column: 62
+ }
+ },
+ "12": {
+ start: {
+ line: 40,
+ column: 8
+ },
+ end: {
+ line: 40,
+ column: 59
+ }
+ },
+ "13": {
+ start: {
+ line: 54,
+ column: 12
+ },
+ end: {
+ line: 54,
+ column: 22
+ }
+ },
+ "14": {
+ start: {
+ line: 56,
+ column: 34
+ },
+ end: {
+ line: 56,
+ column: 35
+ }
+ },
+ "15": {
+ start: {
+ line: 58,
+ column: 41
+ },
+ end: {
+ line: 58,
+ column: 79
+ }
+ },
+ "16": {
+ start: {
+ line: 60,
+ column: 8
+ },
+ end: {
+ line: 62,
+ column: 9
+ }
+ },
+ "17": {
+ start: {
+ line: 61,
+ column: 12
+ },
+ end: {
+ line: 61,
+ column: 73
+ }
+ },
+ "18": {
+ start: {
+ line: 64,
+ column: 21
+ },
+ end: {
+ line: 64,
+ column: 43
+ }
+ },
+ "19": {
+ start: {
+ line: 65,
+ column: 23
+ },
+ end: {
+ line: 65,
+ column: 51
+ }
+ },
+ "20": {
+ start: {
+ line: 67,
+ column: 8
+ },
+ end: {
+ line: 147,
+ column: 10
+ }
+ },
+ "21": {
+ start: {
+ line: 80,
+ column: 20
+ },
+ end: {
+ line: 144,
+ column: 26
+ }
+ },
+ "22": {
+ start: {
+ line: 93,
+ column: 36
+ },
+ end: {
+ line: 93,
+ column: 60
+ }
+ },
+ "23": {
+ start: {
+ line: 117,
+ column: 40
+ },
+ end: {
+ line: 117,
+ column: 64
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "(anonymous_0)",
+ decl: {
+ start: {
+ line: 15,
+ column: 4
+ },
+ end: {
+ line: 15,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 15,
+ column: 23
+ },
+ end: {
+ line: 20,
+ column: 5
+ }
+ },
+ line: 15
+ },
+ "1": {
+ name: "(anonymous_1)",
+ decl: {
+ start: {
+ line: 22,
+ column: 22
+ },
+ end: {
+ line: 22,
+ column: 23
+ }
+ },
+ loc: {
+ start: {
+ line: 22,
+ column: 27
+ },
+ end: {
+ line: 31,
+ column: 5
+ }
+ },
+ line: 22
+ },
+ "2": {
+ name: "(anonymous_2)",
+ decl: {
+ start: {
+ line: 33,
+ column: 4
+ },
+ end: {
+ line: 33,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 33,
+ column: 23
+ },
+ end: {
+ line: 41,
+ column: 5
+ }
+ },
+ line: 33
+ },
+ "3": {
+ name: "(anonymous_3)",
+ decl: {
+ start: {
+ line: 43,
+ column: 4
+ },
+ end: {
+ line: 43,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 43,
+ column: 13
+ },
+ end: {
+ line: 148,
+ column: 5
+ }
+ },
+ line: 43
+ },
+ "4": {
+ name: "(anonymous_4)",
+ decl: {
+ start: {
+ line: 79,
+ column: 40
+ },
+ end: {
+ line: 79,
+ column: 41
+ }
+ },
+ loc: {
+ start: {
+ line: 80,
+ column: 20
+ },
+ end: {
+ line: 144,
+ column: 26
+ }
+ },
+ line: 80
+ },
+ "5": {
+ name: "(anonymous_5)",
+ decl: {
+ start: {
+ line: 92,
+ column: 41
+ },
+ end: {
+ line: 92,
+ column: 42
+ }
+ },
+ loc: {
+ start: {
+ line: 92,
+ column: 46
+ },
+ end: {
+ line: 94,
+ column: 33
+ }
+ },
+ line: 92
+ },
+ "6": {
+ name: "(anonymous_6)",
+ decl: {
+ start: {
+ line: 116,
+ column: 45
+ },
+ end: {
+ line: 116,
+ column: 46
+ }
+ },
+ loc: {
+ start: {
+ line: 116,
+ column: 50
+ },
+ end: {
+ line: 118,
+ column: 37
+ }
+ },
+ line: 116
+ }
+ },
+ branchMap: {
+ "0": {
+ loc: {
+ start: {
+ line: 36,
+ column: 8
+ },
+ end: {
+ line: 38,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 36,
+ column: 8
+ },
+ end: {
+ line: 38,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 36,
+ column: 8
+ },
+ end: {
+ line: 38,
+ column: 9
+ }
+ }],
+ line: 36
+ },
+ "1": {
+ loc: {
+ start: {
+ line: 60,
+ column: 8
+ },
+ end: {
+ line: 62,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 60,
+ column: 8
+ },
+ end: {
+ line: 62,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 60,
+ column: 8
+ },
+ end: {
+ line: 62,
+ column: 9
+ }
+ }],
+ line: 60
+ },
+ "2": {
+ loc: {
+ start: {
+ line: 70,
+ column: 33
+ },
+ end: {
+ line: 70,
+ column: 70
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 70,
+ column: 43
+ },
+ end: {
+ line: 70,
+ column: 53
+ }
+ }, {
+ start: {
+ line: 70,
+ column: 56
+ },
+ end: {
+ line: 70,
+ column: 70
+ }
+ }],
+ line: 70
+ },
+ "3": {
+ loc: {
+ start: {
+ line: 98,
+ column: 29
+ },
+ end: {
+ line: 142,
+ column: 29
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 99,
+ column: 32
+ },
+ end: {
+ line: 112,
+ column: 34
+ }
+ }, {
+ start: {
+ line: 114,
+ column: 32
+ },
+ end: {
+ line: 141,
+ column: 39
+ }
+ }],
+ line: 98
+ },
+ "4": {
+ loc: {
+ start: {
+ line: 135,
+ column: 45
+ },
+ end: {
+ line: 137,
+ column: 65
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 136,
+ column: 50
+ },
+ end: {
+ line: 136,
+ column: 60
+ }
+ }, {
+ start: {
+ line: 137,
+ column: 50
+ },
+ end: {
+ line: 137,
+ column: 65
+ }
+ }],
+ line: 135
+ }
+ },
+ s: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0,
+ "7": 0,
+ "8": 0,
+ "9": 0,
+ "10": 0,
+ "11": 0,
+ "12": 0,
+ "13": 0,
+ "14": 0,
+ "15": 0,
+ "16": 0,
+ "17": 0,
+ "18": 0,
+ "19": 0,
+ "20": 0,
+ "21": 0,
+ "22": 0,
+ "23": 0
+ },
+ f: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0
+ },
+ b: {
+ "0": [0, 0],
+ "1": [0, 0],
+ "2": [0, 0],
+ "3": [0, 0],
+ "4": [0, 0]
+ },
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "8615a2e53494fc046848618ce88ecae0c0bd3754"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
+
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
+
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_30e5qjl1o = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
+
+cov_30e5qjl1o();
+
+
+
+
+ //icons
+
+ //single indent is 5px
+
+var SINGLE_INDENT = (cov_30e5qjl1o().s[0]++, 5);
+
+var ArrayGroup_default = /*#__PURE__*/function (_React$PureComponent) {
+ _inherits(_default, _React$PureComponent);
+
+ var _super = _createSuper(_default);
+
+ function _default(props) {
+ var _this;
+
+ _classCallCheck(this, _default);
+
+ cov_30e5qjl1o().f[0]++;
+ cov_30e5qjl1o().s[1]++;
+ _this = _super.call(this, props);
+ _this.toggleCollapsed = (cov_30e5qjl1o().s[3]++, function (i) {
+ cov_30e5qjl1o().f[1]++;
+ var newExpanded = (cov_30e5qjl1o().s[4]++, []);
+ cov_30e5qjl1o().s[5]++;
+
+ for (var j in _this.state.expanded) {
+ cov_30e5qjl1o().s[6]++;
+ newExpanded.push(_this.state.expanded[j]);
+ }
+
+ cov_30e5qjl1o().s[7]++;
+ newExpanded[i] = !newExpanded[i];
+ cov_30e5qjl1o().s[8]++;
+
+ _this.setState({
+ expanded: newExpanded
+ });
+ });
+ cov_30e5qjl1o().s[2]++;
+ _this.state = {
+ expanded: []
+ };
+ return _this;
+ }
+
+ _createClass(_default, [{
+ key: "getExpandedIcon",
+ value: function getExpandedIcon(i) {
+ cov_30e5qjl1o().f[2]++;
+
+ var _ref = (cov_30e5qjl1o().s[9]++, this.props),
+ theme = _ref.theme,
+ iconStyle = _ref.iconStyle;
+
+ cov_30e5qjl1o().s[10]++;
+
+ if (this.state.expanded[i]) {
+ cov_30e5qjl1o().b[0][0]++;
+ cov_30e5qjl1o().s[11]++;
+ return /*#__PURE__*/external_React_default.a.createElement(ExpandedIcon, {
+ theme: theme,
+ iconStyle: iconStyle
+ });
+ } else {
+ cov_30e5qjl1o().b[0][1]++;
+ }
+
+ cov_30e5qjl1o().s[12]++;
+ return /*#__PURE__*/external_React_default.a.createElement(CollapsedIcon, {
+ theme: theme,
+ iconStyle: iconStyle
+ });
+ }
+ }, {
+ key: "render",
+ value: function render() {
+ var _this2 = this;
+
+ cov_30e5qjl1o().f[3]++;
+
+ var _ref2 = (cov_30e5qjl1o().s[13]++, this.props),
+ src = _ref2.src,
+ groupArraysAfterLength = _ref2.groupArraysAfterLength,
+ depth = _ref2.depth,
+ name = _ref2.name,
+ theme = _ref2.theme,
+ jsvRoot = _ref2.jsvRoot,
+ namespace = _ref2.namespace,
+ parent_type = _ref2.parent_type,
+ rest = _objectWithoutProperties(_ref2, ["src", "groupArraysAfterLength", "depth", "name", "theme", "jsvRoot", "namespace", "parent_type"]);
+
+ var object_padding_left = (cov_30e5qjl1o().s[14]++, 0);
+ var array_group_padding_left = (cov_30e5qjl1o().s[15]++, this.props.indentWidth * SINGLE_INDENT);
+ cov_30e5qjl1o().s[16]++;
+
+ if (!jsvRoot) {
+ cov_30e5qjl1o().b[1][0]++;
+ cov_30e5qjl1o().s[17]++;
+ object_padding_left = this.props.indentWidth * SINGLE_INDENT;
+ } else {
+ cov_30e5qjl1o().b[1][1]++;
+ }
+
+ var size = (cov_30e5qjl1o().s[18]++, groupArraysAfterLength);
+ var groups = (cov_30e5qjl1o().s[19]++, Math.ceil(src.length / size));
+ cov_30e5qjl1o().s[20]++;
+ return /*#__PURE__*/external_React_default.a.createElement("div", Object.assign({
+ className: "object-key-val"
+ }, getStyle_style(theme, jsvRoot ? (cov_30e5qjl1o().b[2][0]++, 'jsv-root') : (cov_30e5qjl1o().b[2][1]++, 'objectKeyVal'), {
+ paddingLeft: object_padding_left
+ })), /*#__PURE__*/external_React_default.a.createElement(getObjectName, this.props), /*#__PURE__*/external_React_default.a.createElement("span", null, /*#__PURE__*/external_React_default.a.createElement(VariableMeta_default, Object.assign({
+ size: src.length
+ }, this.props))), _toConsumableArray(Array(groups)).map(function (_, i) {
+ cov_30e5qjl1o().f[4]++;
+ cov_30e5qjl1o().s[21]++;
+ return /*#__PURE__*/external_React_default.a.createElement("div", Object.assign({
+ key: i,
+ className: "object-key-val array-group"
+ }, getStyle_style(theme, 'objectKeyVal', {
+ marginLeft: 6,
+ paddingLeft: array_group_padding_left
+ })), /*#__PURE__*/external_React_default.a.createElement("span", getStyle_style(theme, 'brace-row'), /*#__PURE__*/external_React_default.a.createElement("div", Object.assign({
+ className: "icon-container"
+ }, getStyle_style(theme, 'icon-container'), {
+ onClick: function onClick(e) {
+ cov_30e5qjl1o().f[5]++;
+ cov_30e5qjl1o().s[22]++;
+
+ _this2.toggleCollapsed(i);
+ }
+ }), _this2.getExpandedIcon(i)), _this2.state.expanded[i] ? (cov_30e5qjl1o().b[3][0]++, /*#__PURE__*/external_React_default.a.createElement(DataTypes_Object, Object.assign({
+ key: name + i,
+ depth: 0,
+ name: false,
+ collapsed: false,
+ groupArraysAfterLength: size,
+ index_offset: i * size,
+ src: src.slice(i * size, i * size + size),
+ namespace: namespace,
+ type: "array",
+ parent_type: "array_group",
+ theme: theme
+ }, rest))) : (cov_30e5qjl1o().b[3][1]++, /*#__PURE__*/external_React_default.a.createElement("span", Object.assign({}, getStyle_style(theme, 'brace'), {
+ onClick: function onClick(e) {
+ cov_30e5qjl1o().f[6]++;
+ cov_30e5qjl1o().s[23]++;
+
+ _this2.toggleCollapsed(i);
+ },
+ className: "array-group-brace"
+ }), "[", /*#__PURE__*/external_React_default.a.createElement("div", Object.assign({}, getStyle_style(theme, 'array-group-meta-data'), {
+ className: "array-group-meta-data"
+ }), /*#__PURE__*/external_React_default.a.createElement("span", Object.assign({
+ className: "object-size"
+ }, getStyle_style(theme, 'object-size')), i * size, ' - ', i * size + size > src.length ? (cov_30e5qjl1o().b[4][0]++, src.length) : (cov_30e5qjl1o().b[4][1]++, i * size + size))), "]"))));
+ }));
+ }
+ }]);
+
+ return _default;
+}((external_React_default.a.PureComponent));
+
+
+// CONCATENATED MODULE: ./src/js/components/DataTypes/Object.js
+
+
+
+
+
+
+
+function cov_t9govpp1w() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/components/DataTypes/Object.js";
+ var hash = "0eabea7bd07313fdf91cc88525517f4760af52f8";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/components/DataTypes/Object.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 23,
+ column: 24
+ },
+ end: {
+ line: 23,
+ column: 25
+ }
+ },
+ "1": {
+ start: {
+ line: 25,
+ column: 22
+ },
+ end: {
+ line: 25,
+ column: 23
+ }
+ },
+ "2": {
+ start: {
+ line: 29,
+ column: 8
+ },
+ end: {
+ line: 29,
+ column: 21
+ }
+ },
+ "3": {
+ start: {
+ line: 30,
+ column: 22
+ },
+ end: {
+ line: 30,
+ column: 47
+ }
+ },
+ "4": {
+ start: {
+ line: 31,
+ column: 8
+ },
+ end: {
+ line: 34,
+ column: 10
+ }
+ },
+ "5": {
+ start: {
+ line: 37,
+ column: 22
+ },
+ end: {
+ line: 64,
+ column: 5
+ }
+ },
+ "6": {
+ start: {
+ line: 38,
+ column: 21
+ },
+ end: {
+ line: 38,
+ column: 50
+ }
+ },
+ "7": {
+ start: {
+ line: 40,
+ column: 12
+ },
+ end: {
+ line: 50,
+ column: 22
+ }
+ },
+ "8": {
+ start: {
+ line: 51,
+ column: 22
+ },
+ end: {
+ line: 62,
+ column: 9
+ }
+ },
+ "9": {
+ start: {
+ line: 63,
+ column: 8
+ },
+ end: {
+ line: 63,
+ column: 21
+ }
+ },
+ "10": {
+ start: {
+ line: 67,
+ column: 30
+ },
+ end: {
+ line: 67,
+ column: 39
+ }
+ },
+ "11": {
+ start: {
+ line: 68,
+ column: 8
+ },
+ end: {
+ line: 80,
+ column: 9
+ }
+ },
+ "12": {
+ start: {
+ line: 75,
+ column: 29
+ },
+ end: {
+ line: 75,
+ column: 58
+ }
+ },
+ "13": {
+ start: {
+ line: 76,
+ column: 12
+ },
+ end: {
+ line: 79,
+ column: 14
+ }
+ },
+ "14": {
+ start: {
+ line: 81,
+ column: 8
+ },
+ end: {
+ line: 81,
+ column: 20
+ }
+ },
+ "15": {
+ start: {
+ line: 84,
+ column: 22
+ },
+ end: {
+ line: 98,
+ column: 5
+ }
+ },
+ "16": {
+ start: {
+ line: 85,
+ column: 8
+ },
+ end: {
+ line: 97,
+ column: 10
+ }
+ },
+ "17": {
+ start: {
+ line: 90,
+ column: 16
+ },
+ end: {
+ line: 95,
+ column: 18
+ }
+ },
+ "18": {
+ start: {
+ line: 100,
+ column: 23
+ },
+ end: {
+ line: 111,
+ column: 5
+ }
+ },
+ "19": {
+ start: {
+ line: 101,
+ column: 8
+ },
+ end: {
+ line: 110,
+ column: 10
+ }
+ },
+ "20": {
+ start: {
+ line: 113,
+ column: 18
+ },
+ end: {
+ line: 130,
+ column: 5
+ }
+ },
+ "21": {
+ start: {
+ line: 114,
+ column: 25
+ },
+ end: {
+ line: 114,
+ column: 35
+ }
+ },
+ "22": {
+ start: {
+ line: 116,
+ column: 8
+ },
+ end: {
+ line: 129,
+ column: 9
+ }
+ },
+ "23": {
+ start: {
+ line: 118,
+ column: 12
+ },
+ end: {
+ line: 118,
+ column: 24
+ }
+ },
+ "24": {
+ start: {
+ line: 120,
+ column: 12
+ },
+ end: {
+ line: 128,
+ column: 14
+ }
+ },
+ "25": {
+ start: {
+ line: 132,
+ column: 24
+ },
+ end: {
+ line: 138,
+ column: 5
+ }
+ },
+ "26": {
+ start: {
+ line: 133,
+ column: 33
+ },
+ end: {
+ line: 133,
+ column: 43
+ }
+ },
+ "27": {
+ start: {
+ line: 134,
+ column: 34
+ },
+ end: {
+ line: 134,
+ column: 44
+ }
+ },
+ "28": {
+ start: {
+ line: 135,
+ column: 8
+ },
+ end: {
+ line: 137,
+ column: 10
+ }
+ },
+ "29": {
+ start: {
+ line: 141,
+ column: 55
+ },
+ end: {
+ line: 141,
+ column: 65
+ }
+ },
+ "30": {
+ start: {
+ line: 143,
+ column: 8
+ },
+ end: {
+ line: 152,
+ column: 9
+ }
+ },
+ "31": {
+ start: {
+ line: 144,
+ column: 12
+ },
+ end: {
+ line: 151,
+ column: 14
+ }
+ },
+ "32": {
+ start: {
+ line: 154,
+ column: 30
+ },
+ end: {
+ line: 154,
+ column: 69
+ }
+ },
+ "33": {
+ start: {
+ line: 156,
+ column: 8
+ },
+ end: {
+ line: 177,
+ column: 10
+ }
+ },
+ "34": {
+ start: {
+ line: 160,
+ column: 24
+ },
+ end: {
+ line: 160,
+ column: 47
+ }
+ },
+ "35": {
+ start: {
+ line: 194,
+ column: 12
+ },
+ end: {
+ line: 194,
+ column: 22
+ }
+ },
+ "36": {
+ start: {
+ line: 196,
+ column: 42
+ },
+ end: {
+ line: 196,
+ column: 52
+ }
+ },
+ "37": {
+ start: {
+ line: 198,
+ column: 21
+ },
+ end: {
+ line: 198,
+ column: 23
+ }
+ },
+ "38": {
+ start: {
+ line: 199,
+ column: 8
+ },
+ end: {
+ line: 204,
+ column: 9
+ }
+ },
+ "39": {
+ start: {
+ line: 200,
+ column: 12
+ },
+ end: {
+ line: 200,
+ column: 72
+ }
+ },
+ "40": {
+ start: {
+ line: 201,
+ column: 15
+ },
+ end: {
+ line: 204,
+ column: 9
+ }
+ },
+ "41": {
+ start: {
+ line: 202,
+ column: 12
+ },
+ end: {
+ line: 202,
+ column: 34
+ }
+ },
+ "42": {
+ start: {
+ line: 203,
+ column: 12
+ },
+ end: {
+ line: 203,
+ column: 38
+ }
+ },
+ "43": {
+ start: {
+ line: 206,
+ column: 8
+ },
+ end: {
+ line: 237,
+ column: 10
+ }
+ },
+ "44": {
+ start: {
+ line: 210,
+ column: 20
+ },
+ end: {
+ line: 210,
+ column: 67
+ }
+ },
+ "45": {
+ start: {
+ line: 213,
+ column: 20
+ },
+ end: {
+ line: 213,
+ column: 68
+ }
+ },
+ "46": {
+ start: {
+ line: 240,
+ column: 27
+ },
+ end: {
+ line: 313,
+ column: 5
+ }
+ },
+ "47": {
+ start: {
+ line: 247,
+ column: 12
+ },
+ end: {
+ line: 247,
+ column: 22
+ }
+ },
+ "48": {
+ start: {
+ line: 248,
+ column: 32
+ },
+ end: {
+ line: 248,
+ column: 42
+ }
+ },
+ "49": {
+ start: {
+ line: 249,
+ column: 23
+ },
+ end: {
+ line: 249,
+ column: 25
+ }
+ },
+ "50": {
+ start: {
+ line: 251,
+ column: 19
+ },
+ end: {
+ line: 251,
+ column: 47
+ }
+ },
+ "51": {
+ start: {
+ line: 252,
+ column: 8
+ },
+ end: {
+ line: 254,
+ column: 9
+ }
+ },
+ "52": {
+ start: {
+ line: 253,
+ column: 12
+ },
+ end: {
+ line: 253,
+ column: 31
+ }
+ },
+ "53": {
+ start: {
+ line: 256,
+ column: 8
+ },
+ end: {
+ line: 310,
+ column: 11
+ }
+ },
+ "54": {
+ start: {
+ line: 257,
+ column: 12
+ },
+ end: {
+ line: 257,
+ column: 63
+ }
+ },
+ "55": {
+ start: {
+ line: 259,
+ column: 12
+ },
+ end: {
+ line: 261,
+ column: 13
+ }
+ },
+ "56": {
+ start: {
+ line: 260,
+ column: 16
+ },
+ end: {
+ line: 260,
+ column: 71
+ }
+ },
+ "57": {
+ start: {
+ line: 262,
+ column: 12
+ },
+ end: {
+ line: 309,
+ column: 13
+ }
+ },
+ "58": {
+ start: {
+ line: 263,
+ column: 16
+ },
+ end: {
+ line: 263,
+ column: 23
+ }
+ },
+ "59": {
+ start: {
+ line: 264,
+ column: 19
+ },
+ end: {
+ line: 309,
+ column: 13
+ }
+ },
+ "60": {
+ start: {
+ line: 265,
+ column: 16
+ },
+ end: {
+ line: 275,
+ column: 18
+ }
+ },
+ "61": {
+ start: {
+ line: 276,
+ column: 19
+ },
+ end: {
+ line: 309,
+ column: 13
+ }
+ },
+ "62": {
+ start: {
+ line: 277,
+ column: 38
+ },
+ end: {
+ line: 277,
+ column: 48
+ }
+ },
+ "63": {
+ start: {
+ line: 279,
+ column: 16
+ },
+ end: {
+ line: 284,
+ column: 17
+ }
+ },
+ "64": {
+ start: {
+ line: 283,
+ column: 20
+ },
+ end: {
+ line: 283,
+ column: 49
+ }
+ },
+ "65": {
+ start: {
+ line: 286,
+ column: 16
+ },
+ end: {
+ line: 297,
+ column: 18
+ }
+ },
+ "66": {
+ start: {
+ line: 299,
+ column: 16
+ },
+ end: {
+ line: 308,
+ column: 18
+ }
+ },
+ "67": {
+ start: {
+ line: 312,
+ column: 8
+ },
+ end: {
+ line: 312,
+ column: 24
+ }
+ },
+ "68": {
+ start: {
+ line: 319,
+ column: 8
+ },
+ end: {
+ line: 319,
+ column: 25
+ }
+ },
+ "69": {
+ start: {
+ line: 320,
+ column: 8
+ },
+ end: {
+ line: 320,
+ column: 27
+ }
+ },
+ "70": {
+ start: {
+ line: 321,
+ column: 8
+ },
+ end: {
+ line: 321,
+ column: 34
+ }
+ },
+ "71": {
+ start: {
+ line: 325,
+ column: 0
+ },
+ end: {
+ line: 325,
+ column: 20
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "(anonymous_0)",
+ decl: {
+ start: {
+ line: 28,
+ column: 4
+ },
+ end: {
+ line: 28,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 28,
+ column: 23
+ },
+ end: {
+ line: 35,
+ column: 5
+ }
+ },
+ line: 28
+ },
+ "1": {
+ name: "(anonymous_1)",
+ decl: {
+ start: {
+ line: 37,
+ column: 22
+ },
+ end: {
+ line: 37,
+ column: 23
+ }
+ },
+ loc: {
+ start: {
+ line: 37,
+ column: 31
+ },
+ end: {
+ line: 64,
+ column: 5
+ }
+ },
+ line: 37
+ },
+ "2": {
+ name: "(anonymous_2)",
+ decl: {
+ start: {
+ line: 66,
+ column: 4
+ },
+ end: {
+ line: 66,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 66,
+ column: 58
+ },
+ end: {
+ line: 82,
+ column: 5
+ }
+ },
+ line: 66
+ },
+ "3": {
+ name: "(anonymous_3)",
+ decl: {
+ start: {
+ line: 84,
+ column: 22
+ },
+ end: {
+ line: 84,
+ column: 23
+ }
+ },
+ loc: {
+ start: {
+ line: 84,
+ column: 28
+ },
+ end: {
+ line: 98,
+ column: 5
+ }
+ },
+ line: 84
+ },
+ "4": {
+ name: "(anonymous_4)",
+ decl: {
+ start: {
+ line: 89,
+ column: 12
+ },
+ end: {
+ line: 89,
+ column: 13
+ }
+ },
+ loc: {
+ start: {
+ line: 89,
+ column: 18
+ },
+ end: {
+ line: 96,
+ column: 13
+ }
+ },
+ line: 89
+ },
+ "5": {
+ name: "(anonymous_5)",
+ decl: {
+ start: {
+ line: 100,
+ column: 23
+ },
+ end: {
+ line: 100,
+ column: 24
+ }
+ },
+ loc: {
+ start: {
+ line: 100,
+ column: 46
+ },
+ end: {
+ line: 111,
+ column: 5
+ }
+ },
+ line: 100
+ },
+ "6": {
+ name: "(anonymous_6)",
+ decl: {
+ start: {
+ line: 113,
+ column: 18
+ },
+ end: {
+ line: 113,
+ column: 19
+ }
+ },
+ loc: {
+ start: {
+ line: 113,
+ column: 24
+ },
+ end: {
+ line: 130,
+ column: 5
+ }
+ },
+ line: 113
+ },
+ "7": {
+ name: "(anonymous_7)",
+ decl: {
+ start: {
+ line: 132,
+ column: 24
+ },
+ end: {
+ line: 132,
+ column: 25
+ }
+ },
+ loc: {
+ start: {
+ line: 132,
+ column: 31
+ },
+ end: {
+ line: 138,
+ column: 5
+ }
+ },
+ line: 132
+ },
+ "8": {
+ name: "(anonymous_8)",
+ decl: {
+ start: {
+ line: 140,
+ column: 4
+ },
+ end: {
+ line: 140,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 140,
+ column: 41
+ },
+ end: {
+ line: 178,
+ column: 5
+ }
+ },
+ line: 140
+ },
+ "9": {
+ name: "(anonymous_9)",
+ decl: {
+ start: {
+ line: 159,
+ column: 29
+ },
+ end: {
+ line: 159,
+ column: 30
+ }
+ },
+ loc: {
+ start: {
+ line: 159,
+ column: 34
+ },
+ end: {
+ line: 161,
+ column: 21
+ }
+ },
+ line: 159
+ },
+ "10": {
+ name: "(anonymous_10)",
+ decl: {
+ start: {
+ line: 180,
+ column: 4
+ },
+ end: {
+ line: 180,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 180,
+ column: 13
+ },
+ end: {
+ line: 238,
+ column: 5
+ }
+ },
+ line: 180
+ },
+ "11": {
+ name: "(anonymous_11)",
+ decl: {
+ start: {
+ line: 209,
+ column: 30
+ },
+ end: {
+ line: 209,
+ column: 31
+ }
+ },
+ loc: {
+ start: {
+ line: 210,
+ column: 20
+ },
+ end: {
+ line: 210,
+ column: 67
+ }
+ },
+ line: 210
+ },
+ "12": {
+ name: "(anonymous_12)",
+ decl: {
+ start: {
+ line: 212,
+ column: 30
+ },
+ end: {
+ line: 212,
+ column: 31
+ }
+ },
+ loc: {
+ start: {
+ line: 213,
+ column: 20
+ },
+ end: {
+ line: 213,
+ column: 68
+ }
+ },
+ line: 213
+ },
+ "13": {
+ name: "(anonymous_13)",
+ decl: {
+ start: {
+ line: 240,
+ column: 27
+ },
+ end: {
+ line: 240,
+ column: 28
+ }
+ },
+ loc: {
+ start: {
+ line: 240,
+ column: 49
+ },
+ end: {
+ line: 313,
+ column: 5
+ }
+ },
+ line: 240
+ },
+ "14": {
+ name: "(anonymous_14)",
+ decl: {
+ start: {
+ line: 256,
+ column: 21
+ },
+ end: {
+ line: 256,
+ column: 22
+ }
+ },
+ loc: {
+ start: {
+ line: 256,
+ column: 29
+ },
+ end: {
+ line: 310,
+ column: 9
+ }
+ },
+ line: 256
+ },
+ "15": {
+ name: "(anonymous_15)",
+ decl: {
+ start: {
+ line: 318,
+ column: 4
+ },
+ end: {
+ line: 318,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 318,
+ column: 29
+ },
+ end: {
+ line: 322,
+ column: 5
+ }
+ },
+ line: 318
+ }
+ },
+ branchMap: {
+ "0": {
+ loc: {
+ start: {
+ line: 40,
+ column: 12
+ },
+ end: {
+ line: 50,
+ column: 22
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 40,
+ column: 13
+ },
+ end: {
+ line: 40,
+ column: 38
+ }
+ }, {
+ start: {
+ line: 41,
+ column: 17
+ },
+ end: {
+ line: 41,
+ column: 41
+ }
+ }, {
+ start: {
+ line: 41,
+ column: 45
+ },
+ end: {
+ line: 41,
+ column: 74
+ }
+ }, {
+ start: {
+ line: 42,
+ column: 13
+ },
+ end: {
+ line: 42,
+ column: 34
+ }
+ }, {
+ start: {
+ line: 43,
+ column: 16
+ },
+ end: {
+ line: 48,
+ column: 28
+ }
+ }, {
+ start: {
+ line: 50,
+ column: 12
+ },
+ end: {
+ line: 50,
+ column: 22
+ }
+ }],
+ line: 40
+ },
+ "1": {
+ loc: {
+ start: {
+ line: 58,
+ column: 25
+ },
+ end: {
+ line: 58,
+ column: 68
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 58,
+ column: 50
+ },
+ end: {
+ line: 58,
+ column: 57
+ }
+ }, {
+ start: {
+ line: 58,
+ column: 60
+ },
+ end: {
+ line: 58,
+ column: 68
+ }
+ }],
+ line: 58
+ },
+ "2": {
+ loc: {
+ start: {
+ line: 59,
+ column: 25
+ },
+ end: {
+ line: 59,
+ column: 68
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 59,
+ column: 50
+ },
+ end: {
+ line: 59,
+ column: 57
+ }
+ }, {
+ start: {
+ line: 59,
+ column: 60
+ },
+ end: {
+ line: 59,
+ column: 68
+ }
+ }],
+ line: 59
+ },
+ "3": {
+ loc: {
+ start: {
+ line: 68,
+ column: 8
+ },
+ end: {
+ line: 80,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 68,
+ column: 8
+ },
+ end: {
+ line: 80,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 68,
+ column: 8
+ },
+ end: {
+ line: 80,
+ column: 9
+ }
+ }],
+ line: 68
+ },
+ "4": {
+ loc: {
+ start: {
+ line: 69,
+ column: 12
+ },
+ end: {
+ line: 73,
+ column: 47
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 69,
+ column: 12
+ },
+ end: {
+ line: 69,
+ column: 43
+ }
+ }, {
+ start: {
+ line: 70,
+ column: 12
+ },
+ end: {
+ line: 70,
+ column: 55
+ }
+ }, {
+ start: {
+ line: 71,
+ column: 12
+ },
+ end: {
+ line: 71,
+ column: 45
+ }
+ }, {
+ start: {
+ line: 72,
+ column: 12
+ },
+ end: {
+ line: 72,
+ column: 55
+ }
+ }, {
+ start: {
+ line: 73,
+ column: 12
+ },
+ end: {
+ line: 73,
+ column: 47
+ }
+ }],
+ line: 69
+ },
+ "5": {
+ loc: {
+ start: {
+ line: 116,
+ column: 8
+ },
+ end: {
+ line: 129,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 116,
+ column: 8
+ },
+ end: {
+ line: 129,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 116,
+ column: 8
+ },
+ end: {
+ line: 129,
+ column: 9
+ }
+ }],
+ line: 116
+ },
+ "6": {
+ loc: {
+ start: {
+ line: 143,
+ column: 8
+ },
+ end: {
+ line: 152,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 143,
+ column: 8
+ },
+ end: {
+ line: 152,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 143,
+ column: 8
+ },
+ end: {
+ line: 152,
+ column: 9
+ }
+ }],
+ line: 143
+ },
+ "7": {
+ loc: {
+ start: {
+ line: 147,
+ column: 25
+ },
+ end: {
+ line: 147,
+ column: 60
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 147,
+ column: 51
+ },
+ end: {
+ line: 147,
+ column: 54
+ }
+ }, {
+ start: {
+ line: 147,
+ column: 57
+ },
+ end: {
+ line: 147,
+ column: 60
+ }
+ }],
+ line: 147
+ },
+ "8": {
+ loc: {
+ start: {
+ line: 149,
+ column: 21
+ },
+ end: {
+ line: 149,
+ column: 66
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 149,
+ column: 32
+ },
+ end: {
+ line: 149,
+ column: 59
+ }
+ }, {
+ start: {
+ line: 149,
+ column: 62
+ },
+ end: {
+ line: 149,
+ column: 66
+ }
+ }],
+ line: 149
+ },
+ "9": {
+ loc: {
+ start: {
+ line: 154,
+ column: 30
+ },
+ end: {
+ line: 154,
+ column: 69
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 154,
+ column: 41
+ },
+ end: {
+ line: 154,
+ column: 53
+ }
+ }, {
+ start: {
+ line: 154,
+ column: 56
+ },
+ end: {
+ line: 154,
+ column: 69
+ }
+ }],
+ line: 154
+ },
+ "10": {
+ loc: {
+ start: {
+ line: 172,
+ column: 25
+ },
+ end: {
+ line: 172,
+ column: 60
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 172,
+ column: 51
+ },
+ end: {
+ line: 172,
+ column: 54
+ }
+ }, {
+ start: {
+ line: 172,
+ column: 57
+ },
+ end: {
+ line: 172,
+ column: 60
+ }
+ }],
+ line: 172
+ },
+ "11": {
+ loc: {
+ start: {
+ line: 175,
+ column: 17
+ },
+ end: {
+ line: 175,
+ column: 62
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 175,
+ column: 28
+ },
+ end: {
+ line: 175,
+ column: 55
+ }
+ }, {
+ start: {
+ line: 175,
+ column: 58
+ },
+ end: {
+ line: 175,
+ column: 62
+ }
+ }],
+ line: 175
+ },
+ "12": {
+ loc: {
+ start: {
+ line: 199,
+ column: 8
+ },
+ end: {
+ line: 204,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 199,
+ column: 8
+ },
+ end: {
+ line: 204,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 199,
+ column: 8
+ },
+ end: {
+ line: 204,
+ column: 9
+ }
+ }],
+ line: 199
+ },
+ "13": {
+ loc: {
+ start: {
+ line: 199,
+ column: 12
+ },
+ end: {
+ line: 199,
+ column: 53
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 199,
+ column: 12
+ },
+ end: {
+ line: 199,
+ column: 20
+ }
+ }, {
+ start: {
+ line: 199,
+ column: 24
+ },
+ end: {
+ line: 199,
+ column: 53
+ }
+ }],
+ line: 199
+ },
+ "14": {
+ loc: {
+ start: {
+ line: 201,
+ column: 15
+ },
+ end: {
+ line: 204,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 201,
+ column: 15
+ },
+ end: {
+ line: 204,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 201,
+ column: 15
+ },
+ end: {
+ line: 204,
+ column: 9
+ }
+ }],
+ line: 201
+ },
+ "15": {
+ loc: {
+ start: {
+ line: 215,
+ column: 33
+ },
+ end: {
+ line: 215,
+ column: 70
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 215,
+ column: 43
+ },
+ end: {
+ line: 215,
+ column: 53
+ }
+ }, {
+ start: {
+ line: 215,
+ column: 56
+ },
+ end: {
+ line: 215,
+ column: 70
+ }
+ }],
+ line: 215
+ },
+ "16": {
+ loc: {
+ start: {
+ line: 218,
+ column: 17
+ },
+ end: {
+ line: 224,
+ column: 40
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 219,
+ column: 22
+ },
+ end: {
+ line: 223,
+ column: 24
+ }
+ }, {
+ start: {
+ line: 224,
+ column: 22
+ },
+ end: {
+ line: 224,
+ column: 40
+ }
+ }],
+ line: 218
+ },
+ "17": {
+ loc: {
+ start: {
+ line: 229,
+ column: 41
+ },
+ end: {
+ line: 229,
+ column: 65
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 229,
+ column: 52
+ },
+ end: {
+ line: 229,
+ column: 57
+ }
+ }, {
+ start: {
+ line: 229,
+ column: 60
+ },
+ end: {
+ line: 229,
+ column: 65
+ }
+ }],
+ line: 229
+ },
+ "18": {
+ loc: {
+ start: {
+ line: 232,
+ column: 25
+ },
+ end: {
+ line: 232,
+ column: 60
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 232,
+ column: 51
+ },
+ end: {
+ line: 232,
+ column: 54
+ }
+ }, {
+ start: {
+ line: 232,
+ column: 57
+ },
+ end: {
+ line: 232,
+ column: 60
+ }
+ }],
+ line: 232
+ },
+ "19": {
+ loc: {
+ start: {
+ line: 234,
+ column: 21
+ },
+ end: {
+ line: 234,
+ column: 66
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 234,
+ column: 32
+ },
+ end: {
+ line: 234,
+ column: 36
+ }
+ }, {
+ start: {
+ line: 234,
+ column: 39
+ },
+ end: {
+ line: 234,
+ column: 66
+ }
+ }],
+ line: 234
+ },
+ "20": {
+ loc: {
+ start: {
+ line: 251,
+ column: 31
+ },
+ end: {
+ line: 251,
+ column: 46
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 251,
+ column: 31
+ },
+ end: {
+ line: 251,
+ column: 40
+ }
+ }, {
+ start: {
+ line: 251,
+ column: 44
+ },
+ end: {
+ line: 251,
+ column: 46
+ }
+ }],
+ line: 251
+ },
+ "21": {
+ loc: {
+ start: {
+ line: 252,
+ column: 8
+ },
+ end: {
+ line: 254,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 252,
+ column: 8
+ },
+ end: {
+ line: 254,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 252,
+ column: 8
+ },
+ end: {
+ line: 254,
+ column: 9
+ }
+ }],
+ line: 252
+ },
+ "22": {
+ loc: {
+ start: {
+ line: 259,
+ column: 12
+ },
+ end: {
+ line: 261,
+ column: 13
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 259,
+ column: 12
+ },
+ end: {
+ line: 261,
+ column: 13
+ }
+ }, {
+ start: {
+ line: 259,
+ column: 12
+ },
+ end: {
+ line: 261,
+ column: 13
+ }
+ }],
+ line: 259
+ },
+ "23": {
+ loc: {
+ start: {
+ line: 259,
+ column: 16
+ },
+ end: {
+ line: 259,
+ column: 61
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 259,
+ column: 16
+ },
+ end: {
+ line: 259,
+ column: 45
+ }
+ }, {
+ start: {
+ line: 259,
+ column: 49
+ },
+ end: {
+ line: 259,
+ column: 61
+ }
+ }],
+ line: 259
+ },
+ "24": {
+ loc: {
+ start: {
+ line: 262,
+ column: 12
+ },
+ end: {
+ line: 309,
+ column: 13
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 262,
+ column: 12
+ },
+ end: {
+ line: 309,
+ column: 13
+ }
+ }, {
+ start: {
+ line: 262,
+ column: 12
+ },
+ end: {
+ line: 309,
+ column: 13
+ }
+ }],
+ line: 262
+ },
+ "25": {
+ loc: {
+ start: {
+ line: 264,
+ column: 19
+ },
+ end: {
+ line: 309,
+ column: 13
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 264,
+ column: 19
+ },
+ end: {
+ line: 309,
+ column: 13
+ }
+ }, {
+ start: {
+ line: 264,
+ column: 19
+ },
+ end: {
+ line: 309,
+ column: 13
+ }
+ }],
+ line: 264
+ },
+ "26": {
+ loc: {
+ start: {
+ line: 276,
+ column: 19
+ },
+ end: {
+ line: 309,
+ column: 13
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 276,
+ column: 19
+ },
+ end: {
+ line: 309,
+ column: 13
+ }
+ }, {
+ start: {
+ line: 276,
+ column: 19
+ },
+ end: {
+ line: 309,
+ column: 13
+ }
+ }],
+ line: 276
+ },
+ "27": {
+ loc: {
+ start: {
+ line: 279,
+ column: 16
+ },
+ end: {
+ line: 284,
+ column: 17
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 279,
+ column: 16
+ },
+ end: {
+ line: 284,
+ column: 17
+ }
+ }, {
+ start: {
+ line: 279,
+ column: 16
+ },
+ end: {
+ line: 284,
+ column: 17
+ }
+ }],
+ line: 279
+ },
+ "28": {
+ loc: {
+ start: {
+ line: 280,
+ column: 20
+ },
+ end: {
+ line: 281,
+ column: 66
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 280,
+ column: 20
+ },
+ end: {
+ line: 280,
+ column: 42
+ }
+ }, {
+ start: {
+ line: 281,
+ column: 20
+ },
+ end: {
+ line: 281,
+ column: 66
+ }
+ }],
+ line: 280
+ }
+ },
+ s: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0,
+ "7": 0,
+ "8": 0,
+ "9": 0,
+ "10": 0,
+ "11": 0,
+ "12": 0,
+ "13": 0,
+ "14": 0,
+ "15": 0,
+ "16": 0,
+ "17": 0,
+ "18": 0,
+ "19": 0,
+ "20": 0,
+ "21": 0,
+ "22": 0,
+ "23": 0,
+ "24": 0,
+ "25": 0,
+ "26": 0,
+ "27": 0,
+ "28": 0,
+ "29": 0,
+ "30": 0,
+ "31": 0,
+ "32": 0,
+ "33": 0,
+ "34": 0,
+ "35": 0,
+ "36": 0,
+ "37": 0,
+ "38": 0,
+ "39": 0,
+ "40": 0,
+ "41": 0,
+ "42": 0,
+ "43": 0,
+ "44": 0,
+ "45": 0,
+ "46": 0,
+ "47": 0,
+ "48": 0,
+ "49": 0,
+ "50": 0,
+ "51": 0,
+ "52": 0,
+ "53": 0,
+ "54": 0,
+ "55": 0,
+ "56": 0,
+ "57": 0,
+ "58": 0,
+ "59": 0,
+ "60": 0,
+ "61": 0,
+ "62": 0,
+ "63": 0,
+ "64": 0,
+ "65": 0,
+ "66": 0,
+ "67": 0,
+ "68": 0,
+ "69": 0,
+ "70": 0,
+ "71": 0
+ },
+ f: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0,
+ "7": 0,
+ "8": 0,
+ "9": 0,
+ "10": 0,
+ "11": 0,
+ "12": 0,
+ "13": 0,
+ "14": 0,
+ "15": 0
+ },
+ b: {
+ "0": [0, 0, 0, 0, 0, 0],
+ "1": [0, 0],
+ "2": [0, 0],
+ "3": [0, 0],
+ "4": [0, 0, 0, 0, 0],
+ "5": [0, 0],
+ "6": [0, 0],
+ "7": [0, 0],
+ "8": [0, 0],
+ "9": [0, 0],
+ "10": [0, 0],
+ "11": [0, 0],
+ "12": [0, 0],
+ "13": [0, 0],
+ "14": [0, 0],
+ "15": [0, 0],
+ "16": [0, 0],
+ "17": [0, 0],
+ "18": [0, 0],
+ "19": [0, 0],
+ "20": [0, 0],
+ "21": [0, 0],
+ "22": [0, 0],
+ "23": [0, 0],
+ "24": [0, 0],
+ "25": [0, 0],
+ "26": [0, 0],
+ "27": [0, 0],
+ "28": [0, 0]
+ },
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "0eabea7bd07313fdf91cc88525517f4760af52f8"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
+
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
+
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_t9govpp1w = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
+
+cov_t9govpp1w();
+
+
+ //data type components
+
+
+
+
+
+ //attribute store
+
+ //icons
+
+ //theme
+
+ //increment 1 with each nested object & array
+
+var DEPTH_INCREMENT = (cov_t9govpp1w().s[0]++, 1); //single indent is 5px
+
+var Object_SINGLE_INDENT = (cov_t9govpp1w().s[1]++, 5);
+
+var Object_RjvObject = /*#__PURE__*/function (_React$PureComponent) {
+ _inherits(RjvObject, _React$PureComponent);
+
+ var _super = _createSuper(RjvObject);
+
+ function RjvObject(_props) {
+ var _this;
+
+ _classCallCheck(this, RjvObject);
+
+ cov_t9govpp1w().f[0]++;
+ cov_t9govpp1w().s[2]++;
+ _this = _super.call(this, _props);
+ _this.toggleCollapsed = (cov_t9govpp1w().s[15]++, function () {
+ cov_t9govpp1w().f[3]++;
+ cov_t9govpp1w().s[16]++;
+
+ _this.setState({
+ expanded: !_this.state.expanded
+ }, function () {
+ cov_t9govpp1w().f[4]++;
+ cov_t9govpp1w().s[17]++;
+ stores_ObjectAttributes.set(_this.props.rjvId, _this.props.namespace, 'expanded', _this.state.expanded);
+ });
+ });
+ _this.getObjectContent = (cov_t9govpp1w().s[18]++, function (depth, src, props) {
+ cov_t9govpp1w().f[5]++;
+ cov_t9govpp1w().s[19]++;
+ return /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "pushed-content object-container"
+ }, /*#__PURE__*/external_React_default.a.createElement("div", Object.assign({
+ className: "object-content"
+ }, getStyle_style(_this.props.theme, 'pushed-content')), _this.renderObjectContents(src, props)));
+ });
+ _this.getEllipsis = (cov_t9govpp1w().s[20]++, function () {
+ cov_t9govpp1w().f[6]++;
+
+ var _ref = (cov_t9govpp1w().s[21]++, _this.state),
+ size = _ref.size;
+
+ cov_t9govpp1w().s[22]++;
+
+ if (size === 0) {
+ cov_t9govpp1w().b[5][0]++;
+ cov_t9govpp1w().s[23]++;
+ //don't render an ellipsis when an object has no items
+ return null;
+ } else {
+ cov_t9govpp1w().b[5][1]++;
+ cov_t9govpp1w().s[24]++;
+ return /*#__PURE__*/external_React_default.a.createElement("div", Object.assign({}, getStyle_style(_this.props.theme, 'ellipsis'), {
+ className: "node-ellipsis",
+ onClick: _this.toggleCollapsed
+ }), "...");
+ }
+ });
+ _this.getObjectMetaData = (cov_t9govpp1w().s[25]++, function (src) {
+ cov_t9govpp1w().f[7]++;
+
+ var _ref2 = (cov_t9govpp1w().s[26]++, _this.props),
+ rjvId = _ref2.rjvId,
+ theme = _ref2.theme;
+
+ var _ref3 = (cov_t9govpp1w().s[27]++, _this.state),
+ size = _ref3.size,
+ hovered = _ref3.hovered;
+
+ cov_t9govpp1w().s[28]++;
+ return /*#__PURE__*/external_React_default.a.createElement(VariableMeta_default, Object.assign({
+ rowHovered: hovered,
+ size: size
+ }, _this.props));
+ });
+ _this.renderObjectContents = (cov_t9govpp1w().s[46]++, function (variables, props) {
+ cov_t9govpp1w().f[13]++;
+
+ var _ref4 = (cov_t9govpp1w().s[47]++, _this.props),
+ depth = _ref4.depth,
+ parent_type = _ref4.parent_type,
+ index_offset = _ref4.index_offset,
+ groupArraysAfterLength = _ref4.groupArraysAfterLength,
+ namespace = _ref4.namespace;
+
+ var _ref5 = (cov_t9govpp1w().s[48]++, _this.state),
+ object_type = _ref5.object_type;
+
+ var elements = (cov_t9govpp1w().s[49]++, []),
+ variable;
+ var keys = (cov_t9govpp1w().s[50]++, Object.keys((cov_t9govpp1w().b[20][0]++, variables) || (cov_t9govpp1w().b[20][1]++, {})));
+ cov_t9govpp1w().s[51]++;
+
+ if (_this.props.sortKeys) {
+ cov_t9govpp1w().b[21][0]++;
+ cov_t9govpp1w().s[52]++;
+ keys = keys.sort();
+ } else {
+ cov_t9govpp1w().b[21][1]++;
+ }
+
+ cov_t9govpp1w().s[53]++;
+ keys.forEach(function (name) {
+ cov_t9govpp1w().f[14]++;
+ cov_t9govpp1w().s[54]++;
+ variable = new Object_JsonVariable(name, variables[name]);
+ cov_t9govpp1w().s[55]++;
+
+ if ((cov_t9govpp1w().b[23][0]++, parent_type === 'array_group') && (cov_t9govpp1w().b[23][1]++, index_offset)) {
+ cov_t9govpp1w().b[22][0]++;
+ cov_t9govpp1w().s[56]++;
+ variable.name = parseInt(variable.name) + index_offset;
+ } else {
+ cov_t9govpp1w().b[22][1]++;
+ }
+
+ cov_t9govpp1w().s[57]++;
+
+ if (!variables.hasOwnProperty(name)) {
+ cov_t9govpp1w().b[24][0]++;
+ cov_t9govpp1w().s[58]++;
+ return;
+ } else {
+ cov_t9govpp1w().b[24][1]++;
+ cov_t9govpp1w().s[59]++;
+
+ if (variable.type === 'object') {
+ cov_t9govpp1w().b[25][0]++;
+ cov_t9govpp1w().s[60]++;
+ elements.push( /*#__PURE__*/external_React_default.a.createElement(DataTypes_Object, Object.assign({
+ key: variable.name,
+ depth: depth + DEPTH_INCREMENT,
+ name: variable.name,
+ src: variable.value,
+ namespace: namespace.concat(variable.name),
+ parent_type: object_type
+ }, props)));
+ } else {
+ cov_t9govpp1w().b[25][1]++;
+ cov_t9govpp1w().s[61]++;
+
+ if (variable.type === 'array') {
+ cov_t9govpp1w().b[26][0]++;
+ var ObjectComponent = (cov_t9govpp1w().s[62]++, DataTypes_Object);
+ cov_t9govpp1w().s[63]++;
+
+ if ((cov_t9govpp1w().b[28][0]++, groupArraysAfterLength) && (cov_t9govpp1w().b[28][1]++, variable.value.length > groupArraysAfterLength)) {
+ cov_t9govpp1w().b[27][0]++;
+ cov_t9govpp1w().s[64]++;
+ ObjectComponent = ArrayGroup_default;
+ } else {
+ cov_t9govpp1w().b[27][1]++;
+ }
+
+ cov_t9govpp1w().s[65]++;
+ elements.push( /*#__PURE__*/external_React_default.a.createElement(ObjectComponent, Object.assign({
+ key: variable.name,
+ depth: depth + DEPTH_INCREMENT,
+ name: variable.name,
+ src: variable.value,
+ namespace: namespace.concat(variable.name),
+ type: "array",
+ parent_type: object_type
+ }, props)));
+ } else {
+ cov_t9govpp1w().b[26][1]++;
+ cov_t9govpp1w().s[66]++;
+ elements.push( /*#__PURE__*/external_React_default.a.createElement(components_VariableEditor, Object.assign({
+ key: variable.name + '_' + namespace,
+ variable: variable,
+ singleIndent: Object_SINGLE_INDENT,
+ namespace: namespace,
+ type: _this.props.type
+ }, props)));
+ }
+ }
+ }
+ });
+ cov_t9govpp1w().s[67]++;
+ return elements;
+ });
+ var state = (cov_t9govpp1w().s[3]++, RjvObject.getState(_props));
+ cov_t9govpp1w().s[4]++;
+ _this.state = _objectSpread2(_objectSpread2({}, state), {}, {
+ prevProps: {}
+ });
+ return _this;
+ }
+
+ _createClass(RjvObject, [{
+ key: "getBraceStart",
+ value: function getBraceStart(object_type, expanded) {
+ var _this2 = this;
+
+ cov_t9govpp1w().f[8]++;
+
+ var _ref6 = (cov_t9govpp1w().s[29]++, this.props),
+ src = _ref6.src,
+ theme = _ref6.theme,
+ iconStyle = _ref6.iconStyle,
+ parent_type = _ref6.parent_type;
+
+ cov_t9govpp1w().s[30]++;
+
+ if (parent_type === 'array_group') {
+ cov_t9govpp1w().b[6][0]++;
+ cov_t9govpp1w().s[31]++;
+ return /*#__PURE__*/external_React_default.a.createElement("span", null, /*#__PURE__*/external_React_default.a.createElement("span", getStyle_style(theme, 'brace'), object_type === 'array' ? (cov_t9govpp1w().b[7][0]++, '[') : (cov_t9govpp1w().b[7][1]++, '{')), expanded ? (cov_t9govpp1w().b[8][0]++, this.getObjectMetaData(src)) : (cov_t9govpp1w().b[8][1]++, null));
+ } else {
+ cov_t9govpp1w().b[6][1]++;
+ }
+
+ var IconComponent = (cov_t9govpp1w().s[32]++, expanded ? (cov_t9govpp1w().b[9][0]++, ExpandedIcon) : (cov_t9govpp1w().b[9][1]++, CollapsedIcon));
+ cov_t9govpp1w().s[33]++;
+ return /*#__PURE__*/external_React_default.a.createElement("span", null, /*#__PURE__*/external_React_default.a.createElement("span", Object.assign({
+ onClick: function onClick(e) {
+ cov_t9govpp1w().f[9]++;
+ cov_t9govpp1w().s[34]++;
+
+ _this2.toggleCollapsed();
+ }
+ }, getStyle_style(theme, 'brace-row')), /*#__PURE__*/external_React_default.a.createElement("div", Object.assign({
+ className: "icon-container"
+ }, getStyle_style(theme, 'icon-container')), /*#__PURE__*/external_React_default.a.createElement(IconComponent, {
+ theme: theme,
+ iconStyle: iconStyle
+ })), /*#__PURE__*/external_React_default.a.createElement(getObjectName, this.props), /*#__PURE__*/external_React_default.a.createElement("span", getStyle_style(theme, 'brace'), object_type === 'array' ? (cov_t9govpp1w().b[10][0]++, '[') : (cov_t9govpp1w().b[10][1]++, '{'))), expanded ? (cov_t9govpp1w().b[11][0]++, this.getObjectMetaData(src)) : (cov_t9govpp1w().b[11][1]++, null));
+ }
+ }, {
+ key: "render",
+ value: function render() {
+ var _this3 = this;
+
+ cov_t9govpp1w().f[10]++;
+
+ // `indentWidth` and `collapsed` props will
+ // perpetuate to children via `...rest`
+ var _ref7 = (cov_t9govpp1w().s[35]++, this.props),
+ depth = _ref7.depth,
+ src = _ref7.src,
+ namespace = _ref7.namespace,
+ name = _ref7.name,
+ type = _ref7.type,
+ parent_type = _ref7.parent_type,
+ theme = _ref7.theme,
+ jsvRoot = _ref7.jsvRoot,
+ iconStyle = _ref7.iconStyle,
+ rest = _objectWithoutProperties(_ref7, ["depth", "src", "namespace", "name", "type", "parent_type", "theme", "jsvRoot", "iconStyle"]);
+
+ var _ref8 = (cov_t9govpp1w().s[36]++, this.state),
+ object_type = _ref8.object_type,
+ expanded = _ref8.expanded;
+
+ var styles = (cov_t9govpp1w().s[37]++, {});
+ cov_t9govpp1w().s[38]++;
+
+ if ((cov_t9govpp1w().b[13][0]++, !jsvRoot) && (cov_t9govpp1w().b[13][1]++, parent_type !== 'array_group')) {
+ cov_t9govpp1w().b[12][0]++;
+ cov_t9govpp1w().s[39]++;
+ styles.paddingLeft = this.props.indentWidth * Object_SINGLE_INDENT;
+ } else {
+ cov_t9govpp1w().b[12][1]++;
+ cov_t9govpp1w().s[40]++;
+
+ if (parent_type === 'array_group') {
+ cov_t9govpp1w().b[14][0]++;
+ cov_t9govpp1w().s[41]++;
+ styles.borderLeft = 0;
+ cov_t9govpp1w().s[42]++;
+ styles.display = 'inline';
+ } else {
+ cov_t9govpp1w().b[14][1]++;
+ }
+ }
+
+ cov_t9govpp1w().s[43]++;
+ return /*#__PURE__*/external_React_default.a.createElement("div", Object.assign({
+ className: "object-key-val",
+ onMouseEnter: function onMouseEnter() {
+ cov_t9govpp1w().f[11]++;
+ cov_t9govpp1w().s[44]++;
+ return _this3.setState(_objectSpread2(_objectSpread2({}, _this3.state), {}, {
+ hovered: true
+ }));
+ },
+ onMouseLeave: function onMouseLeave() {
+ cov_t9govpp1w().f[12]++;
+ cov_t9govpp1w().s[45]++;
+ return _this3.setState(_objectSpread2(_objectSpread2({}, _this3.state), {}, {
+ hovered: false
+ }));
+ }
+ }, getStyle_style(theme, jsvRoot ? (cov_t9govpp1w().b[15][0]++, 'jsv-root') : (cov_t9govpp1w().b[15][1]++, 'objectKeyVal'), styles)), this.getBraceStart(object_type, expanded), expanded ? (cov_t9govpp1w().b[16][0]++, this.getObjectContent(depth, src, _objectSpread2({
+ theme: theme,
+ iconStyle: iconStyle
+ }, rest))) : (cov_t9govpp1w().b[16][1]++, this.getEllipsis()), /*#__PURE__*/external_React_default.a.createElement("span", {
+ className: "brace-row"
+ }, /*#__PURE__*/external_React_default.a.createElement("span", {
+ style: _objectSpread2(_objectSpread2({}, getStyle_style(theme, 'brace').style), {}, {
+ paddingLeft: expanded ? (cov_t9govpp1w().b[17][0]++, '3px') : (cov_t9govpp1w().b[17][1]++, '0px')
+ })
+ }, object_type === 'array' ? (cov_t9govpp1w().b[18][0]++, ']') : (cov_t9govpp1w().b[18][1]++, '}')), expanded ? (cov_t9govpp1w().b[19][0]++, null) : (cov_t9govpp1w().b[19][1]++, this.getObjectMetaData(src))));
+ }
+ }], [{
+ key: "getDerivedStateFromProps",
+ value: function getDerivedStateFromProps(nextProps, prevState) {
+ cov_t9govpp1w().f[2]++;
+
+ var _ref9 = (cov_t9govpp1w().s[10]++, prevState),
+ prevProps = _ref9.prevProps;
+
+ cov_t9govpp1w().s[11]++;
+
+ if ((cov_t9govpp1w().b[4][0]++, nextProps.src !== prevProps.src) || (cov_t9govpp1w().b[4][1]++, nextProps.collapsed !== prevProps.collapsed) || (cov_t9govpp1w().b[4][2]++, nextProps.name !== prevProps.name) || (cov_t9govpp1w().b[4][3]++, nextProps.namespace !== prevProps.namespace) || (cov_t9govpp1w().b[4][4]++, nextProps.rjvId !== prevProps.rjvId)) {
+ cov_t9govpp1w().b[3][0]++;
+ var newState = (cov_t9govpp1w().s[12]++, RjvObject.getState(nextProps));
+ cov_t9govpp1w().s[13]++;
+ return _objectSpread2(_objectSpread2({}, newState), {}, {
+ prevProps: nextProps
+ });
+ } else {
+ cov_t9govpp1w().b[3][1]++;
+ }
+
+ cov_t9govpp1w().s[14]++;
+ return null;
+ }
+ }]);
+
+ return RjvObject;
+}((external_React_default.a.PureComponent)); //just store name, value and type with a variable
+
+
+Object_RjvObject.getState = (cov_t9govpp1w().s[5]++, function (props) {
+ cov_t9govpp1w().f[1]++;
+ var size = (cov_t9govpp1w().s[6]++, Object.keys(props.src).length);
+ var expanded = (cov_t9govpp1w().s[7]++, ((cov_t9govpp1w().b[0][0]++, props.collapsed === false) || (cov_t9govpp1w().b[0][1]++, props.collapsed !== true) && (cov_t9govpp1w().b[0][2]++, props.collapsed > props.depth)) && ((cov_t9govpp1w().b[0][3]++, !props.shouldCollapse) || (cov_t9govpp1w().b[0][4]++, props.shouldCollapse({
+ name: props.name,
+ src: props.src,
+ type: toType(props.src),
+ namespace: props.namespace
+ }) === false)) && (cov_t9govpp1w().b[0][5]++, //initialize closed if object has no items
+ size !== 0));
+ var state = (cov_t9govpp1w().s[8]++, {
+ expanded: stores_ObjectAttributes.get(props.rjvId, props.namespace, 'expanded', expanded),
+ object_type: props.type === 'array' ? (cov_t9govpp1w().b[1][0]++, 'array') : (cov_t9govpp1w().b[1][1]++, 'object'),
+ parent_type: props.type === 'array' ? (cov_t9govpp1w().b[2][0]++, 'array') : (cov_t9govpp1w().b[2][1]++, 'object'),
+ size: size,
+ hovered: false
+ });
+ cov_t9govpp1w().s[9]++;
+ return state;
+});
+
+var Object_JsonVariable = function JsonVariable(name, value) {
+ _classCallCheck(this, JsonVariable);
+
+ cov_t9govpp1w().f[15]++;
+ cov_t9govpp1w().s[68]++;
+ this.name = name;
+ cov_t9govpp1w().s[69]++;
+ this.value = value;
+ cov_t9govpp1w().s[70]++;
+ this.type = toType(value);
+};
+
+cov_t9govpp1w().s[71]++;
+polyfill(Object_RjvObject); //export component
+
+/* harmony default export */ var DataTypes_Object = (Object_RjvObject);
+// CONCATENATED MODULE: ./src/js/components/JsonViewer.js
+
+
+
+
+
+function cov_h3pox4ris() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/components/JsonViewer.js";
+ var hash = "b101517f5ced64e42f9840323093a11dd1c047a3";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/components/JsonViewer.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 6,
+ column: 13
+ },
+ end: {
+ line: 30,
+ column: 5
+ }
+ },
+ "1": {
+ start: {
+ line: 7,
+ column: 26
+ },
+ end: {
+ line: 7,
+ column: 30
+ }
+ },
+ "2": {
+ start: {
+ line: 8,
+ column: 26
+ },
+ end: {
+ line: 8,
+ column: 38
+ }
+ },
+ "3": {
+ start: {
+ line: 9,
+ column: 30
+ },
+ end: {
+ line: 9,
+ column: 40
+ }
+ },
+ "4": {
+ start: {
+ line: 11,
+ column: 8
+ },
+ end: {
+ line: 16,
+ column: 9
+ }
+ },
+ "5": {
+ start: {
+ line: 15,
+ column: 12
+ },
+ end: {
+ line: 15,
+ column: 41
+ }
+ },
+ "6": {
+ start: {
+ line: 18,
+ column: 8
+ },
+ end: {
+ line: 29,
+ column: 10
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "(anonymous_0)",
+ decl: {
+ start: {
+ line: 6,
+ column: 13
+ },
+ end: {
+ line: 6,
+ column: 14
+ }
+ },
+ loc: {
+ start: {
+ line: 6,
+ column: 19
+ },
+ end: {
+ line: 30,
+ column: 5
+ }
+ },
+ line: 6
+ }
+ },
+ branchMap: {
+ "0": {
+ loc: {
+ start: {
+ line: 11,
+ column: 8
+ },
+ end: {
+ line: 16,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 11,
+ column: 8
+ },
+ end: {
+ line: 16,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 11,
+ column: 8
+ },
+ end: {
+ line: 16,
+ column: 9
+ }
+ }],
+ line: 11
+ },
+ "1": {
+ loc: {
+ start: {
+ line: 12,
+ column: 12
+ },
+ end: {
+ line: 13,
+ column: 59
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 12,
+ column: 12
+ },
+ end: {
+ line: 12,
+ column: 40
+ }
+ }, {
+ start: {
+ line: 13,
+ column: 12
+ },
+ end: {
+ line: 13,
+ column: 59
+ }
+ }],
+ line: 12
+ }
+ },
+ s: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0
+ },
+ f: {
+ "0": 0
+ },
+ b: {
+ "0": [0, 0],
+ "1": [0, 0]
+ },
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "b101517f5ced64e42f9840323093a11dd1c047a3"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
+
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
+
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_h3pox4ris = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
+
+cov_h3pox4ris();
+
+
+
+
+var JsonViewer_default = /*#__PURE__*/function (_React$PureComponent) {
+ _inherits(_default, _React$PureComponent);
+
+ var _super = _createSuper(_default);
+
+ function _default() {
+ var _this;
+
+ _classCallCheck(this, _default);
+
+ for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
+ args[_key] = arguments[_key];
+ }
+
+ _this = _super.call.apply(_super, [this].concat(args));
+ _this.render = (cov_h3pox4ris().s[0]++, function () {
+ cov_h3pox4ris().f[0]++;
+
+ var _ref = (cov_h3pox4ris().s[1]++, _assertThisInitialized(_this)),
+ props = _ref.props;
+
+ var namespace = (cov_h3pox4ris().s[2]++, [props.name]);
+ var ObjectComponent = (cov_h3pox4ris().s[3]++, DataTypes_Object);
+ cov_h3pox4ris().s[4]++;
+
+ if ((cov_h3pox4ris().b[1][0]++, props.groupArraysAfterLength) && (cov_h3pox4ris().b[1][1]++, props.src.length > props.groupArraysAfterLength)) {
+ cov_h3pox4ris().b[0][0]++;
+ cov_h3pox4ris().s[5]++;
+ ObjectComponent = ArrayGroup_default;
+ } else {
+ cov_h3pox4ris().b[0][1]++;
+ }
+
+ cov_h3pox4ris().s[6]++;
+ return /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "pretty-json-container object-container"
+ }, /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "object-content"
+ }, /*#__PURE__*/external_React_default.a.createElement(ObjectComponent, Object.assign({
+ namespace: namespace,
+ depth: 0,
+ jsvRoot: true
+ }, props))));
+ });
+ return _this;
+ }
+
+ return _default;
+}((external_React_default.a.PureComponent));
+
+
+// CONCATENATED MODULE: ./src/js/components/ObjectKeyModal/ObjectKeyModal.js
+
+
+
+
+
+function cov_icdxbuq6d() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/components/ObjectKeyModal/ObjectKeyModal.js";
+ var hash = "2e4f3b8a3b8edb4ed2beb0bac3a4772c46cb0066";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/components/ObjectKeyModal/ObjectKeyModal.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 12,
+ column: 8
+ },
+ end: {
+ line: 12,
+ column: 21
+ }
+ },
+ "1": {
+ start: {
+ line: 13,
+ column: 8
+ },
+ end: {
+ line: 15,
+ column: 10
+ }
+ },
+ "2": {
+ start: {
+ line: 19,
+ column: 42
+ },
+ end: {
+ line: 19,
+ column: 52
+ }
+ },
+ "3": {
+ start: {
+ line: 20,
+ column: 26
+ },
+ end: {
+ line: 20,
+ column: 36
+ }
+ },
+ "4": {
+ start: {
+ line: 22,
+ column: 22
+ },
+ end: {
+ line: 22,
+ column: 36
+ }
+ },
+ "5": {
+ start: {
+ line: 24,
+ column: 8
+ },
+ end: {
+ line: 80,
+ column: 10
+ }
+ },
+ "6": {
+ start: {
+ line: 33,
+ column: 24
+ },
+ end: {
+ line: 33,
+ column: 44
+ }
+ },
+ "7": {
+ start: {
+ line: 41,
+ column: 39
+ },
+ end: {
+ line: 41,
+ column: 55
+ }
+ },
+ "8": {
+ start: {
+ line: 46,
+ column: 32
+ },
+ end: {
+ line: 48,
+ column: 35
+ }
+ },
+ "9": {
+ start: {
+ line: 51,
+ column: 32
+ },
+ end: {
+ line: 55,
+ column: 33
+ }
+ },
+ "10": {
+ start: {
+ line: 52,
+ column: 36
+ },
+ end: {
+ line: 52,
+ column: 50
+ }
+ },
+ "11": {
+ start: {
+ line: 53,
+ column: 39
+ },
+ end: {
+ line: 55,
+ column: 33
+ }
+ },
+ "12": {
+ start: {
+ line: 54,
+ column: 36
+ },
+ end: {
+ line: 54,
+ column: 54
+ }
+ },
+ "13": {
+ start: {
+ line: 62,
+ column: 46
+ },
+ end: {
+ line: 62,
+ column: 59
+ }
+ },
+ "14": {
+ start: {
+ line: 71,
+ column: 32
+ },
+ end: {
+ line: 74,
+ column: 35
+ }
+ },
+ "15": {
+ start: {
+ line: 83,
+ column: 17
+ },
+ end: {
+ line: 88,
+ column: 5
+ }
+ },
+ "16": {
+ start: {
+ line: 84,
+ column: 8
+ },
+ end: {
+ line: 87,
+ column: 11
+ }
+ },
+ "17": {
+ start: {
+ line: 90,
+ column: 13
+ },
+ end: {
+ line: 92,
+ column: 5
+ }
+ },
+ "18": {
+ start: {
+ line: 91,
+ column: 8
+ },
+ end: {
+ line: 91,
+ column: 44
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "(anonymous_0)",
+ decl: {
+ start: {
+ line: 11,
+ column: 4
+ },
+ end: {
+ line: 11,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 11,
+ column: 23
+ },
+ end: {
+ line: 16,
+ column: 5
+ }
+ },
+ line: 11
+ },
+ "1": {
+ name: "(anonymous_1)",
+ decl: {
+ start: {
+ line: 18,
+ column: 4
+ },
+ end: {
+ line: 18,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 18,
+ column: 13
+ },
+ end: {
+ line: 81,
+ column: 5
+ }
+ },
+ line: 18
+ },
+ "2": {
+ name: "(anonymous_2)",
+ decl: {
+ start: {
+ line: 32,
+ column: 29
+ },
+ end: {
+ line: 32,
+ column: 30
+ }
+ },
+ loc: {
+ start: {
+ line: 32,
+ column: 34
+ },
+ end: {
+ line: 34,
+ column: 21
+ }
+ },
+ line: 32
+ },
+ "3": {
+ name: "(anonymous_3)",
+ decl: {
+ start: {
+ line: 41,
+ column: 33
+ },
+ end: {
+ line: 41,
+ column: 34
+ }
+ },
+ loc: {
+ start: {
+ line: 41,
+ column: 39
+ },
+ end: {
+ line: 41,
+ column: 55
+ }
+ },
+ line: 41
+ },
+ "4": {
+ name: "(anonymous_4)",
+ decl: {
+ start: {
+ line: 45,
+ column: 38
+ },
+ end: {
+ line: 45,
+ column: 39
+ }
+ },
+ loc: {
+ start: {
+ line: 45,
+ column: 43
+ },
+ end: {
+ line: 49,
+ column: 29
+ }
+ },
+ line: 45
+ },
+ "5": {
+ name: "(anonymous_5)",
+ decl: {
+ start: {
+ line: 50,
+ column: 40
+ },
+ end: {
+ line: 50,
+ column: 41
+ }
+ },
+ loc: {
+ start: {
+ line: 50,
+ column: 45
+ },
+ end: {
+ line: 56,
+ column: 29
+ }
+ },
+ line: 50
+ },
+ "6": {
+ name: "(anonymous_6)",
+ decl: {
+ start: {
+ line: 62,
+ column: 41
+ },
+ end: {
+ line: 62,
+ column: 42
+ }
+ },
+ loc: {
+ start: {
+ line: 62,
+ column: 46
+ },
+ end: {
+ line: 62,
+ column: 59
+ }
+ },
+ line: 62
+ },
+ "7": {
+ name: "(anonymous_7)",
+ decl: {
+ start: {
+ line: 70,
+ column: 37
+ },
+ end: {
+ line: 70,
+ column: 38
+ }
+ },
+ loc: {
+ start: {
+ line: 70,
+ column: 43
+ },
+ end: {
+ line: 75,
+ column: 29
+ }
+ },
+ line: 70
+ },
+ "8": {
+ name: "(anonymous_8)",
+ decl: {
+ start: {
+ line: 83,
+ column: 17
+ },
+ end: {
+ line: 83,
+ column: 18
+ }
+ },
+ loc: {
+ start: {
+ line: 83,
+ column: 23
+ },
+ end: {
+ line: 88,
+ column: 5
+ }
+ },
+ line: 83
+ },
+ "9": {
+ name: "(anonymous_9)",
+ decl: {
+ start: {
+ line: 90,
+ column: 13
+ },
+ end: {
+ line: 90,
+ column: 14
+ }
+ },
+ loc: {
+ start: {
+ line: 90,
+ column: 19
+ },
+ end: {
+ line: 92,
+ column: 5
+ }
+ },
+ line: 90
+ }
+ },
+ branchMap: {
+ "0": {
+ loc: {
+ start: {
+ line: 14,
+ column: 19
+ },
+ end: {
+ line: 14,
+ column: 49
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 14,
+ column: 33
+ },
+ end: {
+ line: 14,
+ column: 44
+ }
+ }, {
+ start: {
+ line: 14,
+ column: 47
+ },
+ end: {
+ line: 14,
+ column: 49
+ }
+ }],
+ line: 14
+ },
+ "1": {
+ loc: {
+ start: {
+ line: 41,
+ column: 39
+ },
+ end: {
+ line: 41,
+ column: 55
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 41,
+ column: 39
+ },
+ end: {
+ line: 41,
+ column: 41
+ }
+ }, {
+ start: {
+ line: 41,
+ column: 45
+ },
+ end: {
+ line: 41,
+ column: 55
+ }
+ }],
+ line: 41
+ },
+ "2": {
+ loc: {
+ start: {
+ line: 51,
+ column: 32
+ },
+ end: {
+ line: 55,
+ column: 33
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 51,
+ column: 32
+ },
+ end: {
+ line: 55,
+ column: 33
+ }
+ }, {
+ start: {
+ line: 51,
+ column: 32
+ },
+ end: {
+ line: 55,
+ column: 33
+ }
+ }],
+ line: 51
+ },
+ "3": {
+ loc: {
+ start: {
+ line: 51,
+ column: 36
+ },
+ end: {
+ line: 51,
+ column: 62
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 51,
+ column: 36
+ },
+ end: {
+ line: 51,
+ column: 41
+ }
+ }, {
+ start: {
+ line: 51,
+ column: 45
+ },
+ end: {
+ line: 51,
+ column: 62
+ }
+ }],
+ line: 51
+ },
+ "4": {
+ loc: {
+ start: {
+ line: 53,
+ column: 39
+ },
+ end: {
+ line: 55,
+ column: 33
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 53,
+ column: 39
+ },
+ end: {
+ line: 55,
+ column: 33
+ }
+ }, {
+ start: {
+ line: 53,
+ column: 39
+ },
+ end: {
+ line: 55,
+ column: 33
+ }
+ }],
+ line: 53
+ },
+ "5": {
+ loc: {
+ start: {
+ line: 58,
+ column: 25
+ },
+ end: {
+ line: 64,
+ column: 32
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 59,
+ column: 28
+ },
+ end: {
+ line: 63,
+ column: 30
+ }
+ }, {
+ start: {
+ line: 64,
+ column: 28
+ },
+ end: {
+ line: 64,
+ column: 32
+ }
+ }],
+ line: 58
+ }
+ },
+ s: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0,
+ "7": 0,
+ "8": 0,
+ "9": 0,
+ "10": 0,
+ "11": 0,
+ "12": 0,
+ "13": 0,
+ "14": 0,
+ "15": 0,
+ "16": 0,
+ "17": 0,
+ "18": 0
+ },
+ f: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0,
+ "7": 0,
+ "8": 0,
+ "9": 0
+ },
+ b: {
+ "0": [0, 0],
+ "1": [0, 0],
+ "2": [0, 0],
+ "3": [0, 0],
+ "4": [0, 0],
+ "5": [0, 0]
+ },
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "2e4f3b8a3b8edb4ed2beb0bac3a4772c46cb0066"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
+
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
+
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_icdxbuq6d = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
+
+cov_icdxbuq6d();
+
+
+ //global theme
+
+ //this input appears when adding a new value to an object
+
+var ObjectKeyModal_default = /*#__PURE__*/function (_React$PureComponent) {
+ _inherits(_default, _React$PureComponent);
+
+ var _super = _createSuper(_default);
+
+ function _default(props) {
+ var _this;
+
+ _classCallCheck(this, _default);
+
+ cov_icdxbuq6d().f[0]++;
+ cov_icdxbuq6d().s[0]++;
+ _this = _super.call(this, props);
+ _this.closeModal = (cov_icdxbuq6d().s[15]++, function () {
+ cov_icdxbuq6d().f[8]++;
+ cov_icdxbuq6d().s[16]++;
+ helpers_dispatcher.dispatch({
+ rjvId: _this.props.rjvId,
+ name: 'RESET'
+ });
+ });
+ _this.submit = (cov_icdxbuq6d().s[17]++, function () {
+ cov_icdxbuq6d().f[9]++;
+ cov_icdxbuq6d().s[18]++;
+
+ _this.props.submit(_this.state.input);
+ });
+ cov_icdxbuq6d().s[1]++;
+ _this.state = {
+ input: props.input ? (cov_icdxbuq6d().b[0][0]++, props.input) : (cov_icdxbuq6d().b[0][1]++, '')
+ };
+ return _this;
+ }
+
+ _createClass(_default, [{
+ key: "render",
+ value: function render() {
+ var _this2 = this;
+
+ cov_icdxbuq6d().f[1]++;
+
+ var _ref = (cov_icdxbuq6d().s[2]++, this.props),
+ theme = _ref.theme,
+ rjvId = _ref.rjvId,
+ isValid = _ref.isValid;
+
+ var _ref2 = (cov_icdxbuq6d().s[3]++, this.state),
+ input = _ref2.input;
+
+ var valid = (cov_icdxbuq6d().s[4]++, isValid(input));
+ cov_icdxbuq6d().s[5]++;
+ return /*#__PURE__*/external_React_default.a.createElement("div", Object.assign({
+ className: "key-modal-request"
+ }, getStyle_style(theme, 'key-modal-request'), {
+ onClick: this.closeModal
+ }), /*#__PURE__*/external_React_default.a.createElement("div", Object.assign({}, getStyle_style(theme, 'key-modal'), {
+ onClick: function onClick(e) {
+ cov_icdxbuq6d().f[2]++;
+ cov_icdxbuq6d().s[6]++;
+ e.stopPropagation();
+ }
+ }), /*#__PURE__*/external_React_default.a.createElement("div", getStyle_style(theme, 'key-modal-label'), "Key Name:"), /*#__PURE__*/external_React_default.a.createElement("div", {
+ style: {
+ position: 'relative'
+ }
+ }, /*#__PURE__*/external_React_default.a.createElement("input", Object.assign({}, getStyle_style(theme, 'key-modal-input'), {
+ className: "key-modal-input",
+ ref: function ref(el) {
+ cov_icdxbuq6d().f[3]++;
+ cov_icdxbuq6d().s[7]++;
+ return (cov_icdxbuq6d().b[1][0]++, el) && (cov_icdxbuq6d().b[1][1]++, el.focus());
+ },
+ spellCheck: false,
+ value: input,
+ placeholder: "...",
+ onChange: function onChange(e) {
+ cov_icdxbuq6d().f[4]++;
+ cov_icdxbuq6d().s[8]++;
+
+ _this2.setState({
+ input: e.target.value
+ });
+ },
+ onKeyPress: function onKeyPress(e) {
+ cov_icdxbuq6d().f[5]++;
+ cov_icdxbuq6d().s[9]++;
+
+ if ((cov_icdxbuq6d().b[3][0]++, valid) && (cov_icdxbuq6d().b[3][1]++, e.key === 'Enter')) {
+ cov_icdxbuq6d().b[2][0]++;
+ cov_icdxbuq6d().s[10]++;
+
+ _this2.submit();
+ } else {
+ cov_icdxbuq6d().b[2][1]++;
+ cov_icdxbuq6d().s[11]++;
+
+ if (e.key === 'Escape') {
+ cov_icdxbuq6d().b[4][0]++;
+ cov_icdxbuq6d().s[12]++;
+
+ _this2.closeModal();
+ } else {
+ cov_icdxbuq6d().b[4][1]++;
+ }
+ }
+ }
+ })), valid ? (cov_icdxbuq6d().b[5][0]++, /*#__PURE__*/external_React_default.a.createElement(icons_CheckCircle, Object.assign({}, getStyle_style(theme, 'key-modal-submit'), {
+ className: "key-modal-submit",
+ onClick: function onClick(e) {
+ cov_icdxbuq6d().f[6]++;
+ cov_icdxbuq6d().s[13]++;
+ return _this2.submit();
+ }
+ }))) : (cov_icdxbuq6d().b[5][1]++, null)), /*#__PURE__*/external_React_default.a.createElement("span", getStyle_style(theme, 'key-modal-cancel'), /*#__PURE__*/external_React_default.a.createElement(icons_Add, Object.assign({}, getStyle_style(theme, 'key-modal-cancel-icon'), {
+ className: "key-modal-cancel",
+ onClick: function onClick() {
+ cov_icdxbuq6d().f[7]++;
+ cov_icdxbuq6d().s[14]++;
+ helpers_dispatcher.dispatch({
+ rjvId: rjvId,
+ name: 'RESET'
+ });
+ }
+ })))));
+ }
+ }]);
+
+ return _default;
+}((external_React_default.a.PureComponent));
+
+
+// CONCATENATED MODULE: ./src/js/components/ObjectKeyModal/AddKeyRequest.js
+
+
+
+
+
+
+function cov_16g6fskju() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/components/ObjectKeyModal/AddKeyRequest.js";
+ var hash = "7c8d46cdbb179d76bb454e8104a613f5b9b99f80";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/components/ObjectKeyModal/AddKeyRequest.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 12,
+ column: 41
+ },
+ end: {
+ line: 12,
+ column: 51
+ }
+ },
+ "1": {
+ start: {
+ line: 14,
+ column: 8
+ },
+ end: {
+ line: 21,
+ column: 17
+ }
+ },
+ "2": {
+ start: {
+ line: 24,
+ column: 14
+ },
+ end: {
+ line: 35,
+ column: 5
+ }
+ },
+ "3": {
+ start: {
+ line: 25,
+ column: 26
+ },
+ end: {
+ line: 25,
+ column: 36
+ }
+ },
+ "4": {
+ start: {
+ line: 26,
+ column: 24
+ },
+ end: {
+ line: 30,
+ column: 9
+ }
+ },
+ "5": {
+ start: {
+ line: 31,
+ column: 8
+ },
+ end: {
+ line: 34,
+ column: 10
+ }
+ },
+ "6": {
+ start: {
+ line: 37,
+ column: 13
+ },
+ end: {
+ line: 47,
+ column: 5
+ }
+ },
+ "7": {
+ start: {
+ line: 38,
+ column: 26
+ },
+ end: {
+ line: 38,
+ column: 36
+ }
+ },
+ "8": {
+ start: {
+ line: 39,
+ column: 22
+ },
+ end: {
+ line: 39,
+ column: 78
+ }
+ },
+ "9": {
+ start: {
+ line: 40,
+ column: 8
+ },
+ end: {
+ line: 40,
+ column: 58
+ }
+ },
+ "10": {
+ start: {
+ line: 41,
+ column: 8
+ },
+ end: {
+ line: 41,
+ column: 59
+ }
+ },
+ "11": {
+ start: {
+ line: 42,
+ column: 8
+ },
+ end: {
+ line: 46,
+ column: 11
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "(anonymous_0)",
+ decl: {
+ start: {
+ line: 11,
+ column: 4
+ },
+ end: {
+ line: 11,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 11,
+ column: 13
+ },
+ end: {
+ line: 22,
+ column: 5
+ }
+ },
+ line: 11
+ },
+ "1": {
+ name: "(anonymous_1)",
+ decl: {
+ start: {
+ line: 24,
+ column: 14
+ },
+ end: {
+ line: 24,
+ column: 15
+ }
+ },
+ loc: {
+ start: {
+ line: 24,
+ column: 23
+ },
+ end: {
+ line: 35,
+ column: 5
+ }
+ },
+ line: 24
+ },
+ "2": {
+ name: "(anonymous_2)",
+ decl: {
+ start: {
+ line: 37,
+ column: 13
+ },
+ end: {
+ line: 37,
+ column: 14
+ }
+ },
+ loc: {
+ start: {
+ line: 37,
+ column: 22
+ },
+ end: {
+ line: 47,
+ column: 5
+ }
+ },
+ line: 37
+ }
+ },
+ branchMap: {
+ "0": {
+ loc: {
+ start: {
+ line: 14,
+ column: 15
+ },
+ end: {
+ line: 21,
+ column: 16
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 15,
+ column: 12
+ },
+ end: {
+ line: 20,
+ column: 14
+ }
+ }, {
+ start: {
+ line: 21,
+ column: 12
+ },
+ end: {
+ line: 21,
+ column: 16
+ }
+ }],
+ line: 14
+ },
+ "1": {
+ loc: {
+ start: {
+ line: 32,
+ column: 12
+ },
+ end: {
+ line: 33,
+ column: 69
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 32,
+ column: 12
+ },
+ end: {
+ line: 32,
+ column: 23
+ }
+ }, {
+ start: {
+ line: 33,
+ column: 12
+ },
+ end: {
+ line: 33,
+ column: 69
+ }
+ }],
+ line: 32
+ }
+ },
+ s: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0,
+ "7": 0,
+ "8": 0,
+ "9": 0,
+ "10": 0,
+ "11": 0
+ },
+ f: {
+ "0": 0,
+ "1": 0,
+ "2": 0
+ },
+ b: {
+ "0": [0, 0],
+ "1": [0, 0]
+ },
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "7c8d46cdbb179d76bb454e8104a613f5b9b99f80"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
+
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
+
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_16g6fskju = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
+
+cov_16g6fskju();
+
+
+
+ //global theme
+
+ //this input appears when adding a new value to an object
+
+var AddKeyRequest_default = /*#__PURE__*/function (_React$PureComponent) {
+ _inherits(_default, _React$PureComponent);
+
+ var _super = _createSuper(_default);
+
+ function _default() {
+ var _this;
+
+ _classCallCheck(this, _default);
+
+ for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
+ args[_key] = arguments[_key];
+ }
+
+ _this = _super.call.apply(_super, [this].concat(args));
+ _this.isValid = (cov_16g6fskju().s[2]++, function (input) {
+ cov_16g6fskju().f[1]++;
+
+ var _ref = (cov_16g6fskju().s[3]++, _this.props),
+ rjvId = _ref.rjvId;
+
+ var request = (cov_16g6fskju().s[4]++, stores_ObjectAttributes.get(rjvId, 'action', 'new-key-request'));
+ cov_16g6fskju().s[5]++;
+ return (cov_16g6fskju().b[1][0]++, input != '') && (cov_16g6fskju().b[1][1]++, Object.keys(request.existing_value).indexOf(input) === -1);
+ });
+ _this.submit = (cov_16g6fskju().s[6]++, function (input) {
+ cov_16g6fskju().f[2]++;
+
+ var _ref2 = (cov_16g6fskju().s[7]++, _this.props),
+ rjvId = _ref2.rjvId;
+
+ var request = (cov_16g6fskju().s[8]++, stores_ObjectAttributes.get(rjvId, 'action', 'new-key-request'));
+ cov_16g6fskju().s[9]++;
+ request.new_value = _objectSpread2({}, request.existing_value);
+ cov_16g6fskju().s[10]++;
+ request.new_value[input] = _this.props.defaultValue;
+ cov_16g6fskju().s[11]++;
+ helpers_dispatcher.dispatch({
+ name: 'VARIABLE_ADDED',
+ rjvId: rjvId,
+ data: request
+ });
+ });
+ return _this;
+ }
+
+ _createClass(_default, [{
+ key: "render",
+ value: function render() {
+ cov_16g6fskju().f[0]++;
+
+ var _ref3 = (cov_16g6fskju().s[0]++, this.props),
+ active = _ref3.active,
+ theme = _ref3.theme,
+ rjvId = _ref3.rjvId;
+
+ cov_16g6fskju().s[1]++;
+ return active ? (cov_16g6fskju().b[0][0]++, /*#__PURE__*/external_React_default.a.createElement(ObjectKeyModal_default, {
+ rjvId: rjvId,
+ theme: theme,
+ isValid: this.isValid,
+ submit: this.submit
+ })) : (cov_16g6fskju().b[0][1]++, null);
+ }
+ }]);
+
+ return _default;
+}((external_React_default.a.PureComponent));
+
+
+// CONCATENATED MODULE: ./src/js/components/ValidationFailure.js
+
+
+
+
+
+function cov_2oaxewsoss() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/components/ValidationFailure.js";
+ var hash = "25bb5589a1a3d1834ed049aff698d0428914ff11";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/components/ValidationFailure.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 13,
+ column: 50
+ },
+ end: {
+ line: 13,
+ column: 60
+ }
+ },
+ "1": {
+ start: {
+ line: 15,
+ column: 8
+ },
+ end: {
+ line: 31,
+ column: 17
+ }
+ },
+ "2": {
+ start: {
+ line: 20,
+ column: 20
+ },
+ end: {
+ line: 23,
+ column: 23
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "(anonymous_0)",
+ decl: {
+ start: {
+ line: 12,
+ column: 4
+ },
+ end: {
+ line: 12,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 12,
+ column: 13
+ },
+ end: {
+ line: 32,
+ column: 5
+ }
+ },
+ line: 12
+ },
+ "1": {
+ name: "(anonymous_1)",
+ decl: {
+ start: {
+ line: 19,
+ column: 25
+ },
+ end: {
+ line: 19,
+ column: 26
+ }
+ },
+ loc: {
+ start: {
+ line: 19,
+ column: 31
+ },
+ end: {
+ line: 24,
+ column: 17
+ }
+ },
+ line: 19
+ }
+ },
+ branchMap: {
+ "0": {
+ loc: {
+ start: {
+ line: 15,
+ column: 15
+ },
+ end: {
+ line: 31,
+ column: 16
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 16,
+ column: 12
+ },
+ end: {
+ line: 30,
+ column: 18
+ }
+ }, {
+ start: {
+ line: 31,
+ column: 12
+ },
+ end: {
+ line: 31,
+ column: 16
+ }
+ }],
+ line: 15
+ }
+ },
+ s: {
+ "0": 0,
+ "1": 0,
+ "2": 0
+ },
+ f: {
+ "0": 0,
+ "1": 0
+ },
+ b: {
+ "0": [0, 0]
+ },
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "25bb5589a1a3d1834ed049aff698d0428914ff11"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
+
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
+
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_2oaxewsoss = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
+
+cov_2oaxewsoss();
+
+
+
+ //global theme
+
+ //this input appears when adding a new value to an object
+
+var ValidationFailure_default = /*#__PURE__*/function (_React$PureComponent) {
+ _inherits(_default, _React$PureComponent);
+
+ var _super = _createSuper(_default);
+
+ function _default() {
+ _classCallCheck(this, _default);
+
+ return _super.apply(this, arguments);
+ }
+
+ _createClass(_default, [{
+ key: "render",
+ value: function render() {
+ cov_2oaxewsoss().f[0]++;
+
+ var _ref = (cov_2oaxewsoss().s[0]++, this.props),
+ message = _ref.message,
+ active = _ref.active,
+ theme = _ref.theme,
+ rjvId = _ref.rjvId;
+
+ cov_2oaxewsoss().s[1]++;
+ return active ? (cov_2oaxewsoss().b[0][0]++, /*#__PURE__*/external_React_default.a.createElement("div", Object.assign({
+ className: "validation-failure"
+ }, getStyle_style(theme, 'validation-failure'), {
+ onClick: function onClick() {
+ cov_2oaxewsoss().f[1]++;
+ cov_2oaxewsoss().s[2]++;
+ helpers_dispatcher.dispatch({
+ rjvId: rjvId,
+ name: 'RESET'
+ });
+ }
+ }), /*#__PURE__*/external_React_default.a.createElement("span", getStyle_style(theme, 'validation-failure-label'), message), /*#__PURE__*/external_React_default.a.createElement(icons_Add, getStyle_style(theme, 'validation-failure-clear')))) : (cov_2oaxewsoss().b[0][1]++, null);
+ }
+ }]);
+
+ return _default;
+}((external_React_default.a.PureComponent));
+
+
+// CONCATENATED MODULE: ./src/js/index.js
+
+
+
+
+
+
+function cov_1vne3bvkgq() {
+ var path = "/home/mac/dev/git/personal/react-json-view/src/js/index.js";
+ var hash = "6704b1d0d7cd80e434a4a0427bb217e92f618f28";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/src/js/index.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 15,
+ column: 8
+ },
+ end: {
+ line: 15,
+ column: 21
+ }
+ },
+ "1": {
+ start: {
+ line: 16,
+ column: 8
+ },
+ end: {
+ line: 30,
+ column: 10
+ }
+ },
+ "2": {
+ start: {
+ line: 34,
+ column: 12
+ },
+ end: {
+ line: 34,
+ column: 33
+ }
+ },
+ "3": {
+ start: {
+ line: 37,
+ column: 26
+ },
+ end: {
+ line: 59,
+ column: 5
+ }
+ },
+ "4": {
+ start: {
+ line: 63,
+ column: 8
+ },
+ end: {
+ line: 79,
+ column: 9
+ }
+ },
+ "5": {
+ start: {
+ line: 69,
+ column: 36
+ },
+ end: {
+ line: 77,
+ column: 13
+ }
+ },
+ "6": {
+ start: {
+ line: 78,
+ column: 12
+ },
+ end: {
+ line: 78,
+ column: 64
+ }
+ },
+ "7": {
+ start: {
+ line: 80,
+ column: 8
+ },
+ end: {
+ line: 80,
+ column: 20
+ }
+ },
+ "8": {
+ start: {
+ line: 85,
+ column: 8
+ },
+ end: {
+ line: 85,
+ column: 74
+ }
+ },
+ "9": {
+ start: {
+ line: 87,
+ column: 26
+ },
+ end: {
+ line: 87,
+ column: 45
+ }
+ },
+ "10": {
+ start: {
+ line: 88,
+ column: 8
+ },
+ end: {
+ line: 90,
+ column: 9
+ }
+ },
+ "11": {
+ start: {
+ line: 89,
+ column: 12
+ },
+ end: {
+ line: 89,
+ column: 68
+ }
+ },
+ "12": {
+ start: {
+ line: 92,
+ column: 8
+ },
+ end: {
+ line: 95,
+ column: 11
+ }
+ },
+ "13": {
+ start: {
+ line: 100,
+ column: 8
+ },
+ end: {
+ line: 104,
+ column: 9
+ }
+ },
+ "14": {
+ start: {
+ line: 101,
+ column: 12
+ },
+ end: {
+ line: 103,
+ column: 15
+ }
+ },
+ "15": {
+ start: {
+ line: 105,
+ column: 8
+ },
+ end: {
+ line: 109,
+ column: 9
+ }
+ },
+ "16": {
+ start: {
+ line: 106,
+ column: 12
+ },
+ end: {
+ line: 108,
+ column: 15
+ }
+ },
+ "17": {
+ start: {
+ line: 110,
+ column: 8
+ },
+ end: {
+ line: 112,
+ column: 9
+ }
+ },
+ "18": {
+ start: {
+ line: 111,
+ column: 12
+ },
+ end: {
+ line: 111,
+ column: 78
+ }
+ },
+ "19": {
+ start: {
+ line: 116,
+ column: 26
+ },
+ end: {
+ line: 116,
+ column: 45
+ }
+ },
+ "20": {
+ start: {
+ line: 117,
+ column: 8
+ },
+ end: {
+ line: 119,
+ column: 9
+ }
+ },
+ "21": {
+ start: {
+ line: 118,
+ column: 12
+ },
+ end: {
+ line: 118,
+ column: 80
+ }
+ },
+ "22": {
+ start: {
+ line: 122,
+ column: 19
+ },
+ end: {
+ line: 128,
+ column: 5
+ }
+ },
+ "23": {
+ start: {
+ line: 123,
+ column: 8
+ },
+ end: {
+ line: 127,
+ column: 10
+ }
+ },
+ "24": {
+ start: {
+ line: 130,
+ column: 27
+ },
+ end: {
+ line: 158,
+ column: 5
+ }
+ },
+ "25": {
+ start: {
+ line: 131,
+ column: 31
+ },
+ end: {
+ line: 131,
+ column: 33
+ }
+ },
+ "26": {
+ start: {
+ line: 133,
+ column: 8
+ },
+ end: {
+ line: 140,
+ column: 9
+ }
+ },
+ "27": {
+ start: {
+ line: 134,
+ column: 12
+ },
+ end: {
+ line: 138,
+ column: 14
+ }
+ },
+ "28": {
+ start: {
+ line: 139,
+ column: 12
+ },
+ end: {
+ line: 139,
+ column: 49
+ }
+ },
+ "29": {
+ start: {
+ line: 142,
+ column: 8
+ },
+ end: {
+ line: 151,
+ column: 9
+ }
+ },
+ "30": {
+ start: {
+ line: 143,
+ column: 12
+ },
+ end: {
+ line: 146,
+ column: 14
+ }
+ },
+ "31": {
+ start: {
+ line: 147,
+ column: 12
+ },
+ end: {
+ line: 147,
+ column: 42
+ }
+ },
+ "32": {
+ start: {
+ line: 148,
+ column: 12
+ },
+ end: {
+ line: 150,
+ column: 14
+ }
+ },
+ "33": {
+ start: {
+ line: 152,
+ column: 8
+ },
+ end: {
+ line: 157,
+ column: 10
+ }
+ },
+ "34": {
+ start: {
+ line: 168,
+ column: 12
+ },
+ end: {
+ line: 168,
+ column: 22
+ }
+ },
+ "35": {
+ start: {
+ line: 170,
+ column: 40
+ },
+ end: {
+ line: 170,
+ column: 50
+ }
+ },
+ "36": {
+ start: {
+ line: 172,
+ column: 8
+ },
+ end: {
+ line: 198,
+ column: 10
+ }
+ },
+ "37": {
+ start: {
+ line: 201,
+ column: 16
+ },
+ end: {
+ line: 248,
+ column: 5
+ }
+ },
+ "38": {
+ start: {
+ line: 210,
+ column: 12
+ },
+ end: {
+ line: 210,
+ column: 73
+ }
+ },
+ "39": {
+ start: {
+ line: 211,
+ column: 44
+ },
+ end: {
+ line: 211,
+ column: 54
+ }
+ },
+ "40": {
+ start: {
+ line: 213,
+ column: 24
+ },
+ end: {
+ line: 213,
+ column: 34
+ }
+ },
+ "41": {
+ start: {
+ line: 217,
+ column: 32
+ },
+ end: {
+ line: 224,
+ column: 9
+ }
+ },
+ "42": {
+ start: {
+ line: 226,
+ column: 8
+ },
+ end: {
+ line: 236,
+ column: 9
+ }
+ },
+ "43": {
+ start: {
+ line: 228,
+ column: 16
+ },
+ end: {
+ line: 228,
+ column: 48
+ }
+ },
+ "44": {
+ start: {
+ line: 229,
+ column: 16
+ },
+ end: {
+ line: 229,
+ column: 22
+ }
+ },
+ "45": {
+ start: {
+ line: 231,
+ column: 16
+ },
+ end: {
+ line: 231,
+ column: 49
+ }
+ },
+ "46": {
+ start: {
+ line: 232,
+ column: 16
+ },
+ end: {
+ line: 232,
+ column: 22
+ }
+ },
+ "47": {
+ start: {
+ line: 234,
+ column: 16
+ },
+ end: {
+ line: 234,
+ column: 51
+ }
+ },
+ "48": {
+ start: {
+ line: 235,
+ column: 16
+ },
+ end: {
+ line: 235,
+ column: 22
+ }
+ },
+ "49": {
+ start: {
+ line: 238,
+ column: 8
+ },
+ end: {
+ line: 247,
+ column: 9
+ }
+ },
+ "50": {
+ start: {
+ line: 239,
+ column: 12
+ },
+ end: {
+ line: 239,
+ column: 75
+ }
+ },
+ "51": {
+ start: {
+ line: 240,
+ column: 12
+ },
+ end: {
+ line: 242,
+ column: 15
+ }
+ },
+ "52": {
+ start: {
+ line: 244,
+ column: 12
+ },
+ end: {
+ line: 246,
+ column: 15
+ }
+ },
+ "53": {
+ start: {
+ line: 250,
+ column: 20
+ },
+ end: {
+ line: 254,
+ column: 5
+ }
+ },
+ "54": {
+ start: {
+ line: 251,
+ column: 8
+ },
+ end: {
+ line: 253,
+ column: 11
+ }
+ },
+ "55": {
+ start: {
+ line: 256,
+ column: 17
+ },
+ end: {
+ line: 261,
+ column: 5
+ }
+ },
+ "56": {
+ start: {
+ line: 257,
+ column: 8
+ },
+ end: {
+ line: 260,
+ column: 11
+ }
+ },
+ "57": {
+ start: {
+ line: 264,
+ column: 0
+ },
+ end: {
+ line: 264,
+ column: 24
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "(anonymous_0)",
+ decl: {
+ start: {
+ line: 14,
+ column: 4
+ },
+ end: {
+ line: 14,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 14,
+ column: 23
+ },
+ end: {
+ line: 31,
+ column: 5
+ }
+ },
+ line: 14
+ },
+ "1": {
+ name: "(anonymous_1)",
+ decl: {
+ start: {
+ line: 62,
+ column: 4
+ },
+ end: {
+ line: 62,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 62,
+ column: 58
+ },
+ end: {
+ line: 81,
+ column: 5
+ }
+ },
+ line: 62
+ },
+ "2": {
+ name: "(anonymous_2)",
+ decl: {
+ start: {
+ line: 83,
+ column: 4
+ },
+ end: {
+ line: 83,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 83,
+ column: 24
+ },
+ end: {
+ line: 96,
+ column: 5
+ }
+ },
+ line: 83
+ },
+ "3": {
+ name: "(anonymous_3)",
+ decl: {
+ start: {
+ line: 98,
+ column: 4
+ },
+ end: {
+ line: 98,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 98,
+ column: 45
+ },
+ end: {
+ line: 113,
+ column: 5
+ }
+ },
+ line: 98
+ },
+ "4": {
+ name: "(anonymous_4)",
+ decl: {
+ start: {
+ line: 115,
+ column: 4
+ },
+ end: {
+ line: 115,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 115,
+ column: 27
+ },
+ end: {
+ line: 120,
+ column: 5
+ }
+ },
+ line: 115
+ },
+ "5": {
+ name: "(anonymous_5)",
+ decl: {
+ start: {
+ line: 122,
+ column: 19
+ },
+ end: {
+ line: 122,
+ column: 20
+ }
+ },
+ loc: {
+ start: {
+ line: 122,
+ column: 25
+ },
+ end: {
+ line: 128,
+ column: 5
+ }
+ },
+ line: 122
+ },
+ "6": {
+ name: "(anonymous_6)",
+ decl: {
+ start: {
+ line: 130,
+ column: 27
+ },
+ end: {
+ line: 130,
+ column: 28
+ }
+ },
+ loc: {
+ start: {
+ line: 130,
+ column: 36
+ },
+ end: {
+ line: 158,
+ column: 5
+ }
+ },
+ line: 130
+ },
+ "7": {
+ name: "(anonymous_7)",
+ decl: {
+ start: {
+ line: 160,
+ column: 4
+ },
+ end: {
+ line: 160,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 160,
+ column: 13
+ },
+ end: {
+ line: 199,
+ column: 5
+ }
+ },
+ line: 160
+ },
+ "8": {
+ name: "(anonymous_8)",
+ decl: {
+ start: {
+ line: 201,
+ column: 16
+ },
+ end: {
+ line: 201,
+ column: 17
+ }
+ },
+ loc: {
+ start: {
+ line: 201,
+ column: 22
+ },
+ end: {
+ line: 248,
+ column: 5
+ }
+ },
+ line: 201
+ },
+ "9": {
+ name: "(anonymous_9)",
+ decl: {
+ start: {
+ line: 250,
+ column: 20
+ },
+ end: {
+ line: 250,
+ column: 21
+ }
+ },
+ loc: {
+ start: {
+ line: 250,
+ column: 26
+ },
+ end: {
+ line: 254,
+ column: 5
+ }
+ },
+ line: 250
+ },
+ "10": {
+ name: "(anonymous_10)",
+ decl: {
+ start: {
+ line: 256,
+ column: 17
+ },
+ end: {
+ line: 256,
+ column: 18
+ }
+ },
+ loc: {
+ start: {
+ line: 256,
+ column: 23
+ },
+ end: {
+ line: 261,
+ column: 5
+ }
+ },
+ line: 256
+ }
+ },
+ branchMap: {
+ "0": {
+ loc: {
+ start: {
+ line: 63,
+ column: 8
+ },
+ end: {
+ line: 79,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 63,
+ column: 8
+ },
+ end: {
+ line: 79,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 63,
+ column: 8
+ },
+ end: {
+ line: 79,
+ column: 9
+ }
+ }],
+ line: 63
+ },
+ "1": {
+ loc: {
+ start: {
+ line: 64,
+ column: 12
+ },
+ end: {
+ line: 66,
+ column: 51
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 64,
+ column: 12
+ },
+ end: {
+ line: 64,
+ column: 47
+ }
+ }, {
+ start: {
+ line: 65,
+ column: 12
+ },
+ end: {
+ line: 65,
+ column: 49
+ }
+ }, {
+ start: {
+ line: 66,
+ column: 12
+ },
+ end: {
+ line: 66,
+ column: 51
+ }
+ }],
+ line: 64
+ },
+ "2": {
+ loc: {
+ start: {
+ line: 100,
+ column: 8
+ },
+ end: {
+ line: 104,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 100,
+ column: 8
+ },
+ end: {
+ line: 104,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 100,
+ column: 8
+ },
+ end: {
+ line: 104,
+ column: 9
+ }
+ }],
+ line: 100
+ },
+ "3": {
+ loc: {
+ start: {
+ line: 105,
+ column: 8
+ },
+ end: {
+ line: 109,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 105,
+ column: 8
+ },
+ end: {
+ line: 109,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 105,
+ column: 8
+ },
+ end: {
+ line: 109,
+ column: 9
+ }
+ }],
+ line: 105
+ },
+ "4": {
+ loc: {
+ start: {
+ line: 110,
+ column: 8
+ },
+ end: {
+ line: 112,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 110,
+ column: 8
+ },
+ end: {
+ line: 112,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 110,
+ column: 8
+ },
+ end: {
+ line: 112,
+ column: 9
+ }
+ }],
+ line: 110
+ },
+ "5": {
+ loc: {
+ start: {
+ line: 133,
+ column: 8
+ },
+ end: {
+ line: 140,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 133,
+ column: 8
+ },
+ end: {
+ line: 140,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 133,
+ column: 8
+ },
+ end: {
+ line: 140,
+ column: 9
+ }
+ }],
+ line: 133
+ },
+ "6": {
+ loc: {
+ start: {
+ line: 133,
+ column: 12
+ },
+ end: {
+ line: 133,
+ column: 69
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 133,
+ column: 12
+ },
+ end: {
+ line: 133,
+ column: 44
+ }
+ }, {
+ start: {
+ line: 133,
+ column: 48
+ },
+ end: {
+ line: 133,
+ column: 69
+ }
+ }],
+ line: 133
+ },
+ "7": {
+ loc: {
+ start: {
+ line: 142,
+ column: 8
+ },
+ end: {
+ line: 151,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 142,
+ column: 8
+ },
+ end: {
+ line: 151,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 142,
+ column: 8
+ },
+ end: {
+ line: 151,
+ column: 9
+ }
+ }],
+ line: 142
+ },
+ "8": {
+ loc: {
+ start: {
+ line: 142,
+ column: 12
+ },
+ end: {
+ line: 142,
+ column: 75
+ }
+ },
+ type: "binary-expr",
+ locations: [{
+ start: {
+ line: 142,
+ column: 12
+ },
+ end: {
+ line: 142,
+ column: 42
+ }
+ }, {
+ start: {
+ line: 142,
+ column: 46
+ },
+ end: {
+ line: 142,
+ column: 75
+ }
+ }],
+ line: 142
+ },
+ "9": {
+ loc: {
+ start: {
+ line: 226,
+ column: 8
+ },
+ end: {
+ line: 236,
+ column: 9
+ }
+ },
+ type: "switch",
+ locations: [{
+ start: {
+ line: 227,
+ column: 12
+ },
+ end: {
+ line: 229,
+ column: 22
+ }
+ }, {
+ start: {
+ line: 230,
+ column: 12
+ },
+ end: {
+ line: 232,
+ column: 22
+ }
+ }, {
+ start: {
+ line: 233,
+ column: 12
+ },
+ end: {
+ line: 235,
+ column: 22
+ }
+ }],
+ line: 226
+ },
+ "10": {
+ loc: {
+ start: {
+ line: 238,
+ column: 8
+ },
+ end: {
+ line: 247,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 238,
+ column: 8
+ },
+ end: {
+ line: 247,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 238,
+ column: 8
+ },
+ end: {
+ line: 247,
+ column: 9
+ }
+ }],
+ line: 238
+ }
+ },
+ s: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0,
+ "7": 0,
+ "8": 0,
+ "9": 0,
+ "10": 0,
+ "11": 0,
+ "12": 0,
+ "13": 0,
+ "14": 0,
+ "15": 0,
+ "16": 0,
+ "17": 0,
+ "18": 0,
+ "19": 0,
+ "20": 0,
+ "21": 0,
+ "22": 0,
+ "23": 0,
+ "24": 0,
+ "25": 0,
+ "26": 0,
+ "27": 0,
+ "28": 0,
+ "29": 0,
+ "30": 0,
+ "31": 0,
+ "32": 0,
+ "33": 0,
+ "34": 0,
+ "35": 0,
+ "36": 0,
+ "37": 0,
+ "38": 0,
+ "39": 0,
+ "40": 0,
+ "41": 0,
+ "42": 0,
+ "43": 0,
+ "44": 0,
+ "45": 0,
+ "46": 0,
+ "47": 0,
+ "48": 0,
+ "49": 0,
+ "50": 0,
+ "51": 0,
+ "52": 0,
+ "53": 0,
+ "54": 0,
+ "55": 0,
+ "56": 0,
+ "57": 0
+ },
+ f: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0,
+ "7": 0,
+ "8": 0,
+ "9": 0,
+ "10": 0
+ },
+ b: {
+ "0": [0, 0],
+ "1": [0, 0, 0],
+ "2": [0, 0],
+ "3": [0, 0],
+ "4": [0, 0],
+ "5": [0, 0],
+ "6": [0, 0],
+ "7": [0, 0],
+ "8": [0, 0],
+ "9": [0, 0, 0],
+ "10": [0, 0]
+ },
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "6704b1d0d7cd80e434a4a0427bb217e92f618f28"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
+
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
+
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_1vne3bvkgq = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
+
+cov_1vne3bvkgq();
+
+
+
+
+
+
+ //global theme
+
+ //forward src through to JsonObject component
+
+var js_ReactJsonView = /*#__PURE__*/function (_React$PureComponent) {
+ _inherits(ReactJsonView, _React$PureComponent);
+
+ var _super = _createSuper(ReactJsonView);
+
+ function ReactJsonView(props) {
+ var _this;
+
+ _classCallCheck(this, ReactJsonView);
+
+ cov_1vne3bvkgq().f[0]++;
+ cov_1vne3bvkgq().s[0]++;
+ _this = _super.call(this, props);
+ _this.rjvId = (cov_1vne3bvkgq().s[2]++, Date.now().toString());
+ _this.getListeners = (cov_1vne3bvkgq().s[22]++, function () {
+ cov_1vne3bvkgq().f[5]++;
+ cov_1vne3bvkgq().s[23]++;
+ return {
+ reset: _this.resetState,
+ 'variable-update': _this.updateSrc,
+ 'add-key-request': _this.addKeyRequest
+ };
+ });
+ _this.updateSrc = (cov_1vne3bvkgq().s[37]++, function () {
+ cov_1vne3bvkgq().f[8]++;
+
+ var _ref = (cov_1vne3bvkgq().s[38]++, stores_ObjectAttributes.get(_this.rjvId, 'action', 'variable-update')),
+ name = _ref.name,
+ namespace = _ref.namespace,
+ new_value = _ref.new_value,
+ existing_value = _ref.existing_value,
+ variable_removed = _ref.variable_removed,
+ updated_src = _ref.updated_src,
+ type = _ref.type;
+
+ var _ref2 = (cov_1vne3bvkgq().s[39]++, _this.props),
+ onEdit = _ref2.onEdit,
+ onDelete = _ref2.onDelete,
+ onAdd = _ref2.onAdd;
+
+ var _ref3 = (cov_1vne3bvkgq().s[40]++, _this.state),
+ src = _ref3.src;
+
+ var result;
+ var on_edit_payload = (cov_1vne3bvkgq().s[41]++, {
+ existing_src: src,
+ new_value: new_value,
+ updated_src: updated_src,
+ name: name,
+ namespace: namespace,
+ existing_value: existing_value
+ });
+ cov_1vne3bvkgq().s[42]++;
+
+ switch (type) {
+ case 'variable-added':
+ cov_1vne3bvkgq().b[9][0]++;
+ cov_1vne3bvkgq().s[43]++;
+ result = onAdd(on_edit_payload);
+ cov_1vne3bvkgq().s[44]++;
+ break;
+
+ case 'variable-edited':
+ cov_1vne3bvkgq().b[9][1]++;
+ cov_1vne3bvkgq().s[45]++;
+ result = onEdit(on_edit_payload);
+ cov_1vne3bvkgq().s[46]++;
+ break;
+
+ case 'variable-removed':
+ cov_1vne3bvkgq().b[9][2]++;
+ cov_1vne3bvkgq().s[47]++;
+ result = onDelete(on_edit_payload);
+ cov_1vne3bvkgq().s[48]++;
+ break;
+ }
+
+ cov_1vne3bvkgq().s[49]++;
+
+ if (result !== false) {
+ cov_1vne3bvkgq().b[10][0]++;
+ cov_1vne3bvkgq().s[50]++;
+ stores_ObjectAttributes.set(_this.rjvId, 'global', 'src', updated_src);
+ cov_1vne3bvkgq().s[51]++;
+
+ _this.setState({
+ src: updated_src
+ });
+ } else {
+ cov_1vne3bvkgq().b[10][1]++;
+ cov_1vne3bvkgq().s[52]++;
+
+ _this.setState({
+ validationFailure: true
+ });
+ }
+ });
+ _this.addKeyRequest = (cov_1vne3bvkgq().s[53]++, function () {
+ cov_1vne3bvkgq().f[9]++;
+ cov_1vne3bvkgq().s[54]++;
+
+ _this.setState({
+ addKeyRequest: true
+ });
+ });
+ _this.resetState = (cov_1vne3bvkgq().s[55]++, function () {
+ cov_1vne3bvkgq().f[10]++;
+ cov_1vne3bvkgq().s[56]++;
+
+ _this.setState({
+ validationFailure: false,
+ addKeyRequest: false
+ });
+ });
+ cov_1vne3bvkgq().s[1]++;
+ _this.state = {
+ //listen to request to add/edit a key to an object
+ addKeyRequest: false,
+ editKeyRequest: false,
+ validationFailure: false,
+ src: ReactJsonView.defaultProps.src,
+ name: ReactJsonView.defaultProps.name,
+ theme: ReactJsonView.defaultProps.theme,
+ validationMessage: ReactJsonView.defaultProps.validationMessage,
+ // the state object also needs to remember the prev prop values, because we need to compare
+ // old and new props in getDerivedStateFromProps().
+ prevSrc: ReactJsonView.defaultProps.src,
+ prevName: ReactJsonView.defaultProps.name,
+ prevTheme: ReactJsonView.defaultProps.theme
+ };
+ return _this;
+ } //reference id for this instance
+
+
+ _createClass(ReactJsonView, [{
+ key: "componentDidMount",
+ value: function componentDidMount() {
+ cov_1vne3bvkgq().f[2]++;
+ cov_1vne3bvkgq().s[8]++;
+ // initialize
+ stores_ObjectAttributes.set(this.rjvId, 'global', 'src', this.state.src); // bind to events
+
+ var listeners = (cov_1vne3bvkgq().s[9]++, this.getListeners());
+ cov_1vne3bvkgq().s[10]++;
+
+ for (var i in listeners) {
+ cov_1vne3bvkgq().s[11]++;
+ stores_ObjectAttributes.on(i + '-' + this.rjvId, listeners[i]);
+ } //reset key request to false once it's observed
+
+
+ cov_1vne3bvkgq().s[12]++;
+ this.setState({
+ addKeyRequest: false,
+ editKeyRequest: false
+ });
+ }
+ }, {
+ key: "componentDidUpdate",
+ value: function componentDidUpdate(prevProps, prevState) {
+ cov_1vne3bvkgq().f[3]++;
+ cov_1vne3bvkgq().s[13]++;
+
+ //reset key request to false once it's observed
+ if (prevState.addKeyRequest !== false) {
+ cov_1vne3bvkgq().b[2][0]++;
+ cov_1vne3bvkgq().s[14]++;
+ this.setState({
+ addKeyRequest: false
+ });
+ } else {
+ cov_1vne3bvkgq().b[2][1]++;
+ }
+
+ cov_1vne3bvkgq().s[15]++;
+
+ if (prevState.editKeyRequest !== false) {
+ cov_1vne3bvkgq().b[3][0]++;
+ cov_1vne3bvkgq().s[16]++;
+ this.setState({
+ editKeyRequest: false
+ });
+ } else {
+ cov_1vne3bvkgq().b[3][1]++;
+ }
+
+ cov_1vne3bvkgq().s[17]++;
+
+ if (prevProps.src !== this.state.src) {
+ cov_1vne3bvkgq().b[4][0]++;
+ cov_1vne3bvkgq().s[18]++;
+ stores_ObjectAttributes.set(this.rjvId, 'global', 'src', this.state.src);
+ } else {
+ cov_1vne3bvkgq().b[4][1]++;
+ }
+ }
+ }, {
+ key: "componentWillUnmount",
+ value: function componentWillUnmount() {
+ cov_1vne3bvkgq().f[4]++;
+ var listeners = (cov_1vne3bvkgq().s[19]++, this.getListeners());
+ cov_1vne3bvkgq().s[20]++;
+
+ for (var i in listeners) {
+ cov_1vne3bvkgq().s[21]++;
+ stores_ObjectAttributes.removeListener(i + '-' + this.rjvId, listeners[i]);
+ }
+ }
+ }, {
+ key: "render",
+ value: function render() {
+ cov_1vne3bvkgq().f[7]++;
+
+ var _ref4 = (cov_1vne3bvkgq().s[34]++, this.state),
+ validationFailure = _ref4.validationFailure,
+ validationMessage = _ref4.validationMessage,
+ addKeyRequest = _ref4.addKeyRequest,
+ theme = _ref4.theme,
+ src = _ref4.src,
+ name = _ref4.name;
+
+ var _ref5 = (cov_1vne3bvkgq().s[35]++, this.props),
+ style = _ref5.style,
+ defaultValue = _ref5.defaultValue;
+
+ cov_1vne3bvkgq().s[36]++;
+ return /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "react-json-view",
+ style: _objectSpread2(_objectSpread2({}, getStyle_style(theme, 'app-container').style), style)
+ }, /*#__PURE__*/external_React_default.a.createElement(ValidationFailure_default, {
+ message: validationMessage,
+ active: validationFailure,
+ theme: theme,
+ rjvId: this.rjvId
+ }), /*#__PURE__*/external_React_default.a.createElement(JsonViewer_default, Object.assign({}, this.props, {
+ src: src,
+ name: name,
+ theme: theme,
+ type: toType(src),
+ rjvId: this.rjvId
+ })), /*#__PURE__*/external_React_default.a.createElement(AddKeyRequest_default, {
+ active: addKeyRequest,
+ theme: theme,
+ rjvId: this.rjvId,
+ defaultValue: defaultValue
+ }));
+ }
+ }], [{
+ key: "getDerivedStateFromProps",
+ // will trigger whenever setState() is called, or parent passes in new props.
+ value: function getDerivedStateFromProps(nextProps, prevState) {
+ cov_1vne3bvkgq().f[1]++;
+ cov_1vne3bvkgq().s[4]++;
+
+ if ((cov_1vne3bvkgq().b[1][0]++, nextProps.src !== prevState.prevSrc) || (cov_1vne3bvkgq().b[1][1]++, nextProps.name !== prevState.prevName) || (cov_1vne3bvkgq().b[1][2]++, nextProps.theme !== prevState.prevTheme)) {
+ cov_1vne3bvkgq().b[0][0]++;
+ // if we pass in new props, we re-validate
+ var newPartialState = (cov_1vne3bvkgq().s[5]++, {
+ src: nextProps.src,
+ name: nextProps.name,
+ theme: nextProps.theme,
+ validationMessage: nextProps.validationMessage,
+ prevSrc: nextProps.src,
+ prevName: nextProps.name,
+ prevTheme: nextProps.theme
+ });
+ cov_1vne3bvkgq().s[6]++;
+ return ReactJsonView.validateState(newPartialState);
+ } else {
+ cov_1vne3bvkgq().b[0][1]++;
+ }
+
+ cov_1vne3bvkgq().s[7]++;
+ return null;
+ }
+ }]);
+
+ return ReactJsonView;
+}((external_React_default.a.PureComponent));
+
+js_ReactJsonView.defaultProps = (cov_1vne3bvkgq().s[3]++, {
+ src: {},
+ name: 'root',
+ theme: 'rjv-default',
+ collapsed: false,
+ collapseStringsAfterLength: false,
+ shouldCollapse: false,
+ sortKeys: false,
+ quotesOnKeys: true,
+ groupArraysAfterLength: 100,
+ indentWidth: 4,
+ enableClipboard: true,
+ displayObjectSize: true,
+ displayDataTypes: true,
+ onEdit: false,
+ onDelete: false,
+ onAdd: false,
+ onSelect: false,
+ iconStyle: 'triangle',
+ style: {},
+ validationMessage: 'Validation Error',
+ defaultValue: null
+});
+js_ReactJsonView.validateState = (cov_1vne3bvkgq().s[24]++, function (state) {
+ cov_1vne3bvkgq().f[6]++;
+ var validatedState = (cov_1vne3bvkgq().s[25]++, {}); //make sure theme is valid
+
+ cov_1vne3bvkgq().s[26]++;
+
+ if ((cov_1vne3bvkgq().b[6][0]++, toType(state.theme) === 'object') && (cov_1vne3bvkgq().b[6][1]++, !isTheme(state.theme))) {
+ cov_1vne3bvkgq().b[5][0]++;
+ cov_1vne3bvkgq().s[27]++;
+ console.error('react-json-view error:', 'theme prop must be a theme name or valid base-16 theme object.', 'defaulting to "rjv-default" theme');
+ cov_1vne3bvkgq().s[28]++;
+ validatedState.theme = 'rjv-default';
+ } else {
+ cov_1vne3bvkgq().b[5][1]++;
+ } //make sure `src` prop is valid
+
+
+ cov_1vne3bvkgq().s[29]++;
+
+ if ((cov_1vne3bvkgq().b[8][0]++, toType(state.src) !== 'object') && (cov_1vne3bvkgq().b[8][1]++, toType(state.src) !== 'array')) {
+ cov_1vne3bvkgq().b[7][0]++;
+ cov_1vne3bvkgq().s[30]++;
+ console.error('react-json-view error:', 'src property must be a valid json object');
+ cov_1vne3bvkgq().s[31]++;
+ validatedState.name = 'ERROR';
+ cov_1vne3bvkgq().s[32]++;
+ validatedState.src = {
+ message: 'src property must be a valid json object'
+ };
+ } else {
+ cov_1vne3bvkgq().b[7][1]++;
+ }
+
+ cov_1vne3bvkgq().s[33]++;
+ return _objectSpread2(_objectSpread2({}, state), validatedState);
+});
+cov_1vne3bvkgq().s[57]++;
+polyfill(js_ReactJsonView);
+/* harmony default export */ var js = (js_ReactJsonView);
+// EXTERNAL MODULE: ./node_modules/react-github-button/lib/index.js
+var react_github_button_lib = __webpack_require__(54);
+var react_github_button_lib_default = /*#__PURE__*/__webpack_require__.n(react_github_button_lib);
+
+// CONCATENATED MODULE: ./demo/src/js/helpers/Code.js
+
+
+
+
+
+function cov_1p9tyqfe8r() {
+ var path = "/home/mac/dev/git/personal/react-json-view/demo/src/js/helpers/Code.js";
+ var hash = "0c08f5a097d059f021d78e31e6dcc741627e90ac";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/demo/src/js/helpers/Code.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 6,
+ column: 8
+ },
+ end: {
+ line: 16,
+ column: 14
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "(anonymous_0)",
+ decl: {
+ start: {
+ line: 5,
+ column: 4
+ },
+ end: {
+ line: 5,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 5,
+ column: 14
+ },
+ end: {
+ line: 17,
+ column: 5
+ }
+ },
+ line: 5
+ }
+ },
+ branchMap: {},
+ s: {
+ "0": 0
+ },
+ f: {
+ "0": 0
+ },
+ b: {},
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "0c08f5a097d059f021d78e31e6dcc741627e90ac"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
+
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
+
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_1p9tyqfe8r = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
+
+cov_1p9tyqfe8r();
+
+
+var Code_default = /*#__PURE__*/function (_React$PureComponent) {
+ _inherits(_default, _React$PureComponent);
+
+ var _super = _createSuper(_default);
+
+ function _default() {
+ _classCallCheck(this, _default);
+
+ return _super.apply(this, arguments);
+ }
+
+ _createClass(_default, [{
+ key: "render",
+ value: function render() {
+ cov_1p9tyqfe8r().f[0]++;
+ cov_1p9tyqfe8r().s[0]++;
+ return /*#__PURE__*/external_React_default.a.createElement("div", {
+ style: {
+ display: "inline-block",
+ backgroundColor: "rgb(229, 229, 229)",
+ padding: "2px 4px",
+ color: 'rgb(153,68,68)',
+ fontFamily: 'monospace',
+ letterSpacing: '0.8px',
+ fontStyle: 'normal'
+ }
+ }, /*#__PURE__*/external_React_default.a.createElement("span", null, this.props.children));
+ }
+ }]);
+
+ return _default;
+}((external_React_default.a.PureComponent));
+
+
+// EXTERNAL MODULE: ./demo/src/style/scss/rjv-demo.scss
+var rjv_demo = __webpack_require__(153);
+
+// EXTERNAL MODULE: ./node_modules/react-select/dist/react-select.css
+var react_select = __webpack_require__(155);
+
+// EXTERNAL MODULE: ./node_modules/react-github-button/assets/style.css
+var assets_style = __webpack_require__(157);
+
+// CONCATENATED MODULE: ./demo/src/js/components/Demo.js
+
+
+
+
+
+function cov_2jiapirmli() {
+ var path = "/home/mac/dev/git/personal/react-json-view/demo/src/js/components/Demo.js";
+ var hash = "7e9bc79b8d9f921bc9cdaa93e6285cffa852e6b8";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/demo/src/js/components/Demo.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 14,
+ column: 8
+ },
+ end: {
+ line: 14,
+ column: 21
+ }
+ },
+ "1": {
+ start: {
+ line: 15,
+ column: 8
+ },
+ end: {
+ line: 17,
+ column: 10
+ }
+ },
+ "2": {
+ start: {
+ line: 20,
+ column: 26
+ },
+ end: {
+ line: 33,
+ column: 5
+ }
+ },
+ "3": {
+ start: {
+ line: 48,
+ column: 12
+ },
+ end: {
+ line: 48,
+ column: 22
+ }
+ },
+ "4": {
+ start: {
+ line: 49,
+ column: 24
+ },
+ end: {
+ line: 49,
+ column: 34
+ }
+ },
+ "5": {
+ start: {
+ line: 50,
+ column: 22
+ },
+ end: {
+ line: 54,
+ column: 9
+ }
+ },
+ "6": {
+ start: {
+ line: 56,
+ column: 8
+ },
+ end: {
+ line: 169,
+ column: 9
+ }
+ },
+ "7": {
+ start: {
+ line: 65,
+ column: 28
+ },
+ end: {
+ line: 68,
+ column: 29
+ }
+ },
+ "8": {
+ start: {
+ line: 87,
+ column: 34
+ },
+ end: {
+ line: 87,
+ column: 48
+ }
+ },
+ "9": {
+ start: {
+ line: 88,
+ column: 34
+ },
+ end: {
+ line: 88,
+ column: 71
+ }
+ },
+ "10": {
+ start: {
+ line: 95,
+ column: 34
+ },
+ end: {
+ line: 95,
+ column: 48
+ }
+ },
+ "11": {
+ start: {
+ line: 96,
+ column: 34
+ },
+ end: {
+ line: 96,
+ column: 71
+ }
+ },
+ "12": {
+ start: {
+ line: 103,
+ column: 34
+ },
+ end: {
+ line: 103,
+ column: 48
+ }
+ },
+ "13": {
+ start: {
+ line: 104,
+ column: 34
+ },
+ end: {
+ line: 104,
+ column: 71
+ }
+ },
+ "14": {
+ start: {
+ line: 172,
+ column: 15
+ },
+ end: {
+ line: 220,
+ column: 5
+ }
+ },
+ "15": {
+ start: {
+ line: 173,
+ column: 20
+ },
+ end: {
+ line: 173,
+ column: 22
+ }
+ },
+ "16": {
+ start: {
+ line: 174,
+ column: 8
+ },
+ end: {
+ line: 192,
+ column: 9
+ }
+ },
+ "17": {
+ start: {
+ line: 175,
+ column: 12
+ },
+ end: {
+ line: 180,
+ column: 13
+ }
+ },
+ "18": {
+ start: {
+ line: 181,
+ column: 12
+ },
+ end: {
+ line: 186,
+ column: 13
+ }
+ },
+ "19": {
+ start: {
+ line: 187,
+ column: 12
+ },
+ end: {
+ line: 191,
+ column: 13
+ }
+ },
+ "20": {
+ start: {
+ line: 193,
+ column: 8
+ },
+ end: {
+ line: 204,
+ column: 9
+ }
+ },
+ "21": {
+ start: {
+ line: 194,
+ column: 12
+ },
+ end: {
+ line: 198,
+ column: 13
+ }
+ },
+ "22": {
+ start: {
+ line: 199,
+ column: 12
+ },
+ end: {
+ line: 203,
+ column: 13
+ }
+ },
+ "23": {
+ start: {
+ line: 206,
+ column: 8
+ },
+ end: {
+ line: 208,
+ column: 9
+ }
+ },
+ "24": {
+ start: {
+ line: 207,
+ column: 12
+ },
+ end: {
+ line: 207,
+ column: 23
+ }
+ },
+ "25": {
+ start: {
+ line: 210,
+ column: 8
+ },
+ end: {
+ line: 219,
+ column: 9
+ }
+ },
+ "26": {
+ start: {
+ line: 215,
+ column: 24
+ },
+ end: {
+ line: 215,
+ column: 46
+ }
+ },
+ "27": {
+ start: {
+ line: 222,
+ column: 24
+ },
+ end: {
+ line: 237,
+ column: 5
+ }
+ },
+ "28": {
+ start: {
+ line: 223,
+ column: 8
+ },
+ end: {
+ line: 236,
+ column: 9
+ }
+ },
+ "29": {
+ start: {
+ line: 233,
+ column: 20
+ },
+ end: {
+ line: 233,
+ column: 46
+ }
+ },
+ "30": {
+ start: {
+ line: 239,
+ column: 19
+ },
+ end: {
+ line: 253,
+ column: 5
+ }
+ },
+ "31": {
+ start: {
+ line: 240,
+ column: 8
+ },
+ end: {
+ line: 252,
+ column: 9
+ }
+ },
+ "32": {
+ start: {
+ line: 249,
+ column: 20
+ },
+ end: {
+ line: 249,
+ column: 43
+ }
+ },
+ "33": {
+ start: {
+ line: 255,
+ column: 18
+ },
+ end: {
+ line: 269,
+ column: 5
+ }
+ },
+ "34": {
+ start: {
+ line: 256,
+ column: 8
+ },
+ end: {
+ line: 268,
+ column: 9
+ }
+ },
+ "35": {
+ start: {
+ line: 265,
+ column: 20
+ },
+ end: {
+ line: 265,
+ column: 42
+ }
+ },
+ "36": {
+ start: {
+ line: 271,
+ column: 21
+ },
+ end: {
+ line: 285,
+ column: 5
+ }
+ },
+ "37": {
+ start: {
+ line: 272,
+ column: 8
+ },
+ end: {
+ line: 284,
+ column: 9
+ }
+ },
+ "38": {
+ start: {
+ line: 281,
+ column: 20
+ },
+ end: {
+ line: 281,
+ column: 45
+ }
+ },
+ "39": {
+ start: {
+ line: 287,
+ column: 30
+ },
+ end: {
+ line: 301,
+ column: 5
+ }
+ },
+ "40": {
+ start: {
+ line: 288,
+ column: 8
+ },
+ end: {
+ line: 300,
+ column: 9
+ }
+ },
+ "41": {
+ start: {
+ line: 297,
+ column: 20
+ },
+ end: {
+ line: 297,
+ column: 52
+ }
+ },
+ "42": {
+ start: {
+ line: 303,
+ column: 25
+ },
+ end: {
+ line: 317,
+ column: 5
+ }
+ },
+ "43": {
+ start: {
+ line: 304,
+ column: 8
+ },
+ end: {
+ line: 316,
+ column: 9
+ }
+ },
+ "44": {
+ start: {
+ line: 313,
+ column: 20
+ },
+ end: {
+ line: 313,
+ column: 54
+ }
+ },
+ "45": {
+ start: {
+ line: 319,
+ column: 24
+ },
+ end: {
+ line: 333,
+ column: 5
+ }
+ },
+ "46": {
+ start: {
+ line: 320,
+ column: 8
+ },
+ end: {
+ line: 332,
+ column: 9
+ }
+ },
+ "47": {
+ start: {
+ line: 329,
+ column: 20
+ },
+ end: {
+ line: 329,
+ column: 53
+ }
+ },
+ "48": {
+ start: {
+ line: 335,
+ column: 31
+ },
+ end: {
+ line: 352,
+ column: 5
+ }
+ },
+ "49": {
+ start: {
+ line: 336,
+ column: 8
+ },
+ end: {
+ line: 351,
+ column: 9
+ }
+ },
+ "50": {
+ start: {
+ line: 348,
+ column: 20
+ },
+ end: {
+ line: 348,
+ column: 57
+ }
+ },
+ "51": {
+ start: {
+ line: 354,
+ column: 24
+ },
+ end: {
+ line: 370,
+ column: 5
+ }
+ },
+ "52": {
+ start: {
+ line: 355,
+ column: 8
+ },
+ end: {
+ line: 369,
+ column: 9
+ }
+ },
+ "53": {
+ start: {
+ line: 366,
+ column: 20
+ },
+ end: {
+ line: 366,
+ column: 46
+ }
+ },
+ "54": {
+ start: {
+ line: 372,
+ column: 26
+ },
+ end: {
+ line: 395,
+ column: 5
+ }
+ },
+ "55": {
+ start: {
+ line: 373,
+ column: 8
+ },
+ end: {
+ line: 394,
+ column: 9
+ }
+ },
+ "56": {
+ start: {
+ line: 391,
+ column: 20
+ },
+ end: {
+ line: 391,
+ column: 48
+ }
+ },
+ "57": {
+ start: {
+ line: 397,
+ column: 20
+ },
+ end: {
+ line: 455,
+ column: 5
+ }
+ },
+ "58": {
+ start: {
+ line: 398,
+ column: 8
+ },
+ end: {
+ line: 454,
+ column: 9
+ }
+ },
+ "59": {
+ start: {
+ line: 451,
+ column: 20
+ },
+ end: {
+ line: 451,
+ column: 42
+ }
+ },
+ "60": {
+ start: {
+ line: 457,
+ column: 10
+ },
+ end: {
+ line: 461,
+ column: 5
+ }
+ },
+ "61": {
+ start: {
+ line: 458,
+ column: 20
+ },
+ end: {
+ line: 458,
+ column: 22
+ }
+ },
+ "62": {
+ start: {
+ line: 459,
+ column: 8
+ },
+ end: {
+ line: 459,
+ column: 34
+ }
+ },
+ "63": {
+ start: {
+ line: 460,
+ column: 8
+ },
+ end: {
+ line: 460,
+ column: 28
+ }
+ },
+ "64": {
+ start: {
+ line: 464,
+ column: 21
+ },
+ end: {
+ line: 479,
+ column: 5
+ }
+ },
+ "65": {
+ start: {
+ line: 465,
+ column: 8
+ },
+ end: {
+ line: 478,
+ column: 9
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "(anonymous_0)",
+ decl: {
+ start: {
+ line: 13,
+ column: 4
+ },
+ end: {
+ line: 13,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 13,
+ column: 23
+ },
+ end: {
+ line: 18,
+ column: 5
+ }
+ },
+ line: 13
+ },
+ "1": {
+ name: "(anonymous_1)",
+ decl: {
+ start: {
+ line: 35,
+ column: 4
+ },
+ end: {
+ line: 35,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 35,
+ column: 13
+ },
+ end: {
+ line: 170,
+ column: 5
+ }
+ },
+ line: 35
+ },
+ "2": {
+ name: "(anonymous_2)",
+ decl: {
+ start: {
+ line: 64,
+ column: 33
+ },
+ end: {
+ line: 64,
+ column: 34
+ }
+ },
+ loc: {
+ start: {
+ line: 64,
+ column: 39
+ },
+ end: {
+ line: 69,
+ column: 25
+ }
+ },
+ line: 64
+ },
+ "3": {
+ name: "(anonymous_3)",
+ decl: {
+ start: {
+ line: 86,
+ column: 30
+ },
+ end: {
+ line: 86,
+ column: 31
+ }
+ },
+ loc: {
+ start: {
+ line: 86,
+ column: 35
+ },
+ end: {
+ line: 89,
+ column: 31
+ }
+ },
+ line: 86
+ },
+ "4": {
+ name: "(anonymous_4)",
+ decl: {
+ start: {
+ line: 94,
+ column: 30
+ },
+ end: {
+ line: 94,
+ column: 31
+ }
+ },
+ loc: {
+ start: {
+ line: 94,
+ column: 35
+ },
+ end: {
+ line: 97,
+ column: 31
+ }
+ },
+ line: 94
+ },
+ "5": {
+ name: "(anonymous_5)",
+ decl: {
+ start: {
+ line: 102,
+ column: 30
+ },
+ end: {
+ line: 102,
+ column: 31
+ }
+ },
+ loc: {
+ start: {
+ line: 102,
+ column: 35
+ },
+ end: {
+ line: 105,
+ column: 31
+ }
+ },
+ line: 102
+ },
+ "6": {
+ name: "(anonymous_6)",
+ decl: {
+ start: {
+ line: 172,
+ column: 15
+ },
+ end: {
+ line: 172,
+ column: 16
+ }
+ },
+ loc: {
+ start: {
+ line: 172,
+ column: 52
+ },
+ end: {
+ line: 220,
+ column: 5
+ }
+ },
+ line: 172
+ },
+ "7": {
+ name: "(anonymous_7)",
+ decl: {
+ start: {
+ line: 214,
+ column: 31
+ },
+ end: {
+ line: 214,
+ column: 32
+ }
+ },
+ loc: {
+ start: {
+ line: 214,
+ column: 39
+ },
+ end: {
+ line: 216,
+ column: 21
+ }
+ },
+ line: 214
+ },
+ "8": {
+ name: "(anonymous_8)",
+ decl: {
+ start: {
+ line: 222,
+ column: 24
+ },
+ end: {
+ line: 222,
+ column: 25
+ }
+ },
+ loc: {
+ start: {
+ line: 222,
+ column: 37
+ },
+ end: {
+ line: 237,
+ column: 5
+ }
+ },
+ line: 222
+ },
+ "9": {
+ name: "(anonymous_9)",
+ decl: {
+ start: {
+ line: 232,
+ column: 26
+ },
+ end: {
+ line: 232,
+ column: 27
+ }
+ },
+ loc: {
+ start: {
+ line: 232,
+ column: 33
+ },
+ end: {
+ line: 234,
+ column: 17
+ }
+ },
+ line: 232
+ },
+ "10": {
+ name: "(anonymous_10)",
+ decl: {
+ start: {
+ line: 239,
+ column: 19
+ },
+ end: {
+ line: 239,
+ column: 20
+ }
+ },
+ loc: {
+ start: {
+ line: 239,
+ column: 29
+ },
+ end: {
+ line: 253,
+ column: 5
+ }
+ },
+ line: 239
+ },
+ "11": {
+ name: "(anonymous_11)",
+ decl: {
+ start: {
+ line: 248,
+ column: 26
+ },
+ end: {
+ line: 248,
+ column: 27
+ }
+ },
+ loc: {
+ start: {
+ line: 248,
+ column: 33
+ },
+ end: {
+ line: 250,
+ column: 17
+ }
+ },
+ line: 248
+ },
+ "12": {
+ name: "(anonymous_12)",
+ decl: {
+ start: {
+ line: 255,
+ column: 18
+ },
+ end: {
+ line: 255,
+ column: 19
+ }
+ },
+ loc: {
+ start: {
+ line: 255,
+ column: 27
+ },
+ end: {
+ line: 269,
+ column: 5
+ }
+ },
+ line: 255
+ },
+ "13": {
+ name: "(anonymous_13)",
+ decl: {
+ start: {
+ line: 264,
+ column: 26
+ },
+ end: {
+ line: 264,
+ column: 27
+ }
+ },
+ loc: {
+ start: {
+ line: 264,
+ column: 33
+ },
+ end: {
+ line: 266,
+ column: 17
+ }
+ },
+ line: 264
+ },
+ "14": {
+ name: "(anonymous_14)",
+ decl: {
+ start: {
+ line: 271,
+ column: 21
+ },
+ end: {
+ line: 271,
+ column: 22
+ }
+ },
+ loc: {
+ start: {
+ line: 271,
+ column: 33
+ },
+ end: {
+ line: 285,
+ column: 5
+ }
+ },
+ line: 271
+ },
+ "15": {
+ name: "(anonymous_15)",
+ decl: {
+ start: {
+ line: 280,
+ column: 26
+ },
+ end: {
+ line: 280,
+ column: 27
+ }
+ },
+ loc: {
+ start: {
+ line: 280,
+ column: 33
+ },
+ end: {
+ line: 282,
+ column: 17
+ }
+ },
+ line: 280
+ },
+ "16": {
+ name: "(anonymous_16)",
+ decl: {
+ start: {
+ line: 287,
+ column: 30
+ },
+ end: {
+ line: 287,
+ column: 31
+ }
+ },
+ loc: {
+ start: {
+ line: 287,
+ column: 49
+ },
+ end: {
+ line: 301,
+ column: 5
+ }
+ },
+ line: 287
+ },
+ "17": {
+ name: "(anonymous_17)",
+ decl: {
+ start: {
+ line: 296,
+ column: 26
+ },
+ end: {
+ line: 296,
+ column: 27
+ }
+ },
+ loc: {
+ start: {
+ line: 296,
+ column: 33
+ },
+ end: {
+ line: 298,
+ column: 17
+ }
+ },
+ line: 296
+ },
+ "18": {
+ name: "(anonymous_18)",
+ decl: {
+ start: {
+ line: 303,
+ column: 25
+ },
+ end: {
+ line: 303,
+ column: 26
+ }
+ },
+ loc: {
+ start: {
+ line: 303,
+ column: 46
+ },
+ end: {
+ line: 317,
+ column: 5
+ }
+ },
+ line: 303
+ },
+ "19": {
+ name: "(anonymous_19)",
+ decl: {
+ start: {
+ line: 312,
+ column: 26
+ },
+ end: {
+ line: 312,
+ column: 27
+ }
+ },
+ loc: {
+ start: {
+ line: 312,
+ column: 33
+ },
+ end: {
+ line: 314,
+ column: 17
+ }
+ },
+ line: 312
+ },
+ "20": {
+ name: "(anonymous_20)",
+ decl: {
+ start: {
+ line: 319,
+ column: 24
+ },
+ end: {
+ line: 319,
+ column: 25
+ }
+ },
+ loc: {
+ start: {
+ line: 319,
+ column: 44
+ },
+ end: {
+ line: 333,
+ column: 5
+ }
+ },
+ line: 319
+ },
+ "21": {
+ name: "(anonymous_21)",
+ decl: {
+ start: {
+ line: 328,
+ column: 26
+ },
+ end: {
+ line: 328,
+ column: 27
+ }
+ },
+ loc: {
+ start: {
+ line: 328,
+ column: 33
+ },
+ end: {
+ line: 330,
+ column: 17
+ }
+ },
+ line: 328
+ },
+ "22": {
+ name: "(anonymous_22)",
+ decl: {
+ start: {
+ line: 335,
+ column: 31
+ },
+ end: {
+ line: 335,
+ column: 32
+ }
+ },
+ loc: {
+ start: {
+ line: 335,
+ column: 55
+ },
+ end: {
+ line: 352,
+ column: 5
+ }
+ },
+ line: 335
+ },
+ "23": {
+ name: "(anonymous_23)",
+ decl: {
+ start: {
+ line: 347,
+ column: 26
+ },
+ end: {
+ line: 347,
+ column: 27
+ }
+ },
+ loc: {
+ start: {
+ line: 347,
+ column: 33
+ },
+ end: {
+ line: 349,
+ column: 17
+ }
+ },
+ line: 347
+ },
+ "24": {
+ name: "(anonymous_24)",
+ decl: {
+ start: {
+ line: 354,
+ column: 24
+ },
+ end: {
+ line: 354,
+ column: 25
+ }
+ },
+ loc: {
+ start: {
+ line: 354,
+ column: 37
+ },
+ end: {
+ line: 370,
+ column: 5
+ }
+ },
+ line: 354
+ },
+ "25": {
+ name: "(anonymous_25)",
+ decl: {
+ start: {
+ line: 365,
+ column: 26
+ },
+ end: {
+ line: 365,
+ column: 27
+ }
+ },
+ loc: {
+ start: {
+ line: 365,
+ column: 33
+ },
+ end: {
+ line: 367,
+ column: 17
+ }
+ },
+ line: 365
+ },
+ "26": {
+ name: "(anonymous_26)",
+ decl: {
+ start: {
+ line: 372,
+ column: 26
+ },
+ end: {
+ line: 372,
+ column: 27
+ }
+ },
+ loc: {
+ start: {
+ line: 372,
+ column: 41
+ },
+ end: {
+ line: 395,
+ column: 5
+ }
+ },
+ line: 372
+ },
+ "27": {
+ name: "(anonymous_27)",
+ decl: {
+ start: {
+ line: 390,
+ column: 26
+ },
+ end: {
+ line: 390,
+ column: 27
+ }
+ },
+ loc: {
+ start: {
+ line: 390,
+ column: 33
+ },
+ end: {
+ line: 392,
+ column: 17
+ }
+ },
+ line: 390
+ },
+ "28": {
+ name: "(anonymous_28)",
+ decl: {
+ start: {
+ line: 397,
+ column: 20
+ },
+ end: {
+ line: 397,
+ column: 21
+ }
+ },
+ loc: {
+ start: {
+ line: 397,
+ column: 29
+ },
+ end: {
+ line: 455,
+ column: 5
+ }
+ },
+ line: 397
+ },
+ "29": {
+ name: "(anonymous_29)",
+ decl: {
+ start: {
+ line: 450,
+ column: 26
+ },
+ end: {
+ line: 450,
+ column: 27
+ }
+ },
+ loc: {
+ start: {
+ line: 450,
+ column: 33
+ },
+ end: {
+ line: 452,
+ column: 17
+ }
+ },
+ line: 450
+ },
+ "30": {
+ name: "(anonymous_30)",
+ decl: {
+ start: {
+ line: 457,
+ column: 10
+ },
+ end: {
+ line: 457,
+ column: 11
+ }
+ },
+ loc: {
+ start: {
+ line: 457,
+ column: 28
+ },
+ end: {
+ line: 461,
+ column: 5
+ }
+ },
+ line: 457
+ },
+ "31": {
+ name: "(anonymous_31)",
+ decl: {
+ start: {
+ line: 464,
+ column: 21
+ },
+ end: {
+ line: 464,
+ column: 22
+ }
+ },
+ loc: {
+ start: {
+ line: 464,
+ column: 27
+ },
+ end: {
+ line: 479,
+ column: 5
+ }
+ },
+ line: 464
+ }
+ },
+ branchMap: {
+ "0": {
+ loc: {
+ start: {
+ line: 85,
+ column: 24
+ },
+ end: {
+ line: 90,
+ column: 35
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 86,
+ column: 30
+ },
+ end: {
+ line: 89,
+ column: 31
+ }
+ }, {
+ start: {
+ line: 90,
+ column: 30
+ },
+ end: {
+ line: 90,
+ column: 35
+ }
+ }],
+ line: 85
+ },
+ "1": {
+ loc: {
+ start: {
+ line: 93,
+ column: 24
+ },
+ end: {
+ line: 98,
+ column: 35
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 94,
+ column: 30
+ },
+ end: {
+ line: 97,
+ column: 31
+ }
+ }, {
+ start: {
+ line: 98,
+ column: 30
+ },
+ end: {
+ line: 98,
+ column: 35
+ }
+ }],
+ line: 93
+ },
+ "2": {
+ loc: {
+ start: {
+ line: 101,
+ column: 24
+ },
+ end: {
+ line: 106,
+ column: 35
+ }
+ },
+ type: "cond-expr",
+ locations: [{
+ start: {
+ line: 102,
+ column: 30
+ },
+ end: {
+ line: 105,
+ column: 31
+ }
+ }, {
+ start: {
+ line: 106,
+ column: 30
+ },
+ end: {
+ line: 106,
+ column: 35
+ }
+ }],
+ line: 101
+ },
+ "3": {
+ loc: {
+ start: {
+ line: 174,
+ column: 8
+ },
+ end: {
+ line: 192,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 174,
+ column: 8
+ },
+ end: {
+ line: 192,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 174,
+ column: 8
+ },
+ end: {
+ line: 192,
+ column: 9
+ }
+ }],
+ line: 174
+ },
+ "4": {
+ loc: {
+ start: {
+ line: 193,
+ column: 8
+ },
+ end: {
+ line: 204,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 193,
+ column: 8
+ },
+ end: {
+ line: 204,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 193,
+ column: 8
+ },
+ end: {
+ line: 204,
+ column: 9
+ }
+ }],
+ line: 193
+ },
+ "5": {
+ loc: {
+ start: {
+ line: 206,
+ column: 8
+ },
+ end: {
+ line: 208,
+ column: 9
+ }
+ },
+ type: "if",
+ locations: [{
+ start: {
+ line: 206,
+ column: 8
+ },
+ end: {
+ line: 208,
+ column: 9
+ }
+ }, {
+ start: {
+ line: 206,
+ column: 8
+ },
+ end: {
+ line: 208,
+ column: 9
+ }
+ }],
+ line: 206
+ }
+ },
+ s: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0,
+ "7": 0,
+ "8": 0,
+ "9": 0,
+ "10": 0,
+ "11": 0,
+ "12": 0,
+ "13": 0,
+ "14": 0,
+ "15": 0,
+ "16": 0,
+ "17": 0,
+ "18": 0,
+ "19": 0,
+ "20": 0,
+ "21": 0,
+ "22": 0,
+ "23": 0,
+ "24": 0,
+ "25": 0,
+ "26": 0,
+ "27": 0,
+ "28": 0,
+ "29": 0,
+ "30": 0,
+ "31": 0,
+ "32": 0,
+ "33": 0,
+ "34": 0,
+ "35": 0,
+ "36": 0,
+ "37": 0,
+ "38": 0,
+ "39": 0,
+ "40": 0,
+ "41": 0,
+ "42": 0,
+ "43": 0,
+ "44": 0,
+ "45": 0,
+ "46": 0,
+ "47": 0,
+ "48": 0,
+ "49": 0,
+ "50": 0,
+ "51": 0,
+ "52": 0,
+ "53": 0,
+ "54": 0,
+ "55": 0,
+ "56": 0,
+ "57": 0,
+ "58": 0,
+ "59": 0,
+ "60": 0,
+ "61": 0,
+ "62": 0,
+ "63": 0,
+ "64": 0,
+ "65": 0
+ },
+ f: {
+ "0": 0,
+ "1": 0,
+ "2": 0,
+ "3": 0,
+ "4": 0,
+ "5": 0,
+ "6": 0,
+ "7": 0,
+ "8": 0,
+ "9": 0,
+ "10": 0,
+ "11": 0,
+ "12": 0,
+ "13": 0,
+ "14": 0,
+ "15": 0,
+ "16": 0,
+ "17": 0,
+ "18": 0,
+ "19": 0,
+ "20": 0,
+ "21": 0,
+ "22": 0,
+ "23": 0,
+ "24": 0,
+ "25": 0,
+ "26": 0,
+ "27": 0,
+ "28": 0,
+ "29": 0,
+ "30": 0,
+ "31": 0
+ },
+ b: {
+ "0": [0, 0],
+ "1": [0, 0],
+ "2": [0, 0],
+ "3": [0, 0],
+ "4": [0, 0],
+ "5": [0, 0]
+ },
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "7e9bc79b8d9f921bc9cdaa93e6285cffa852e6b8"
};
- xhr.open('GET', url, true);
- xhr.send();
- return xhr;
-}
-module.exports = exports['default'];
-
-/***/ }),
-/* 191 */
-/***/ (function(module, exports, __webpack_require__) {
-
-"use strict";
+ var coverage = global[gcv] || (global[gcv] = {});
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
-Object.defineProperty(exports, "__esModule", {
- value: true
-});
-exports.classNames = classNames;
-function classNames(classSet) {
- return Object.keys(classSet).filter(function (key) {
- return classSet[key];
- }).join(' ');
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_2jiapirmli = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
}
-/***/ }),
-/* 192 */
-/***/ (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__(1);
-
-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 _class = function (_React$PureComponent) {
- _inherits(_class, _React$PureComponent);
-
- function _class() {
- _classCallCheck(this, _class);
-
- return _possibleConstructorReturn(this, (_class.__proto__ || Object.getPrototypeOf(_class)).apply(this, arguments));
- }
-
- _createClass(_class, [{
- key: "render",
- value: function render() {
- return _react2.default.createElement(
- "div",
- { style: {
- display: "inline-block",
- backgroundColor: "rgb(229, 229, 229)",
- padding: "2px 4px",
- color: 'rgb(153,68,68)',
- fontFamily: 'monospace',
- letterSpacing: '0.8px',
- fontStyle: 'normal'
- } },
- _react2.default.createElement(
- "span",
- null,
- this.props.children
- )
- );
- }
- }]);
-
- return _class;
-}(_react2.default.PureComponent);
-
-exports.default = _class;
-
-/***/ }),
-/* 193 */
-/***/ (function(module, exports, __webpack_require__) {
-
-var api = __webpack_require__(30);
- var content = __webpack_require__(194);
+cov_2jiapirmli();
- content = content.__esModule ? content.default : content;
-
- if (typeof content === 'string') {
- content = [[module.i, content, '']];
- }
-
-var options = {};
-
-options.insert = "head";
-options.singleton = false;
-
-var update = api(content, options);
-
-
-
-module.exports = content.locals || {};
-
-/***/ }),
-/* 194 */
-/***/ (function(module, __webpack_exports__, __webpack_require__) {
-
-"use strict";
-__webpack_require__.r(__webpack_exports__);
-/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7);
-/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0__);
-// Imports
-
-var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default()(false);
-// Module
-___CSS_LOADER_EXPORT___.push([module.i, ".rjv-demo .rjv-settings,.rjv-demo .rjv-source{vertical-align:top;display:inline-block;margin-top:5px;margin-right:10px;min-width:300px;max-width:400px}.rjv-demo .rjv-settings .rjv-input,.rjv-demo .rjv-source .rjv-input{margin-bottom:5px}.rjv-demo .rjv-settings .rjv-input .rjv-label,.rjv-demo .rjv-source .rjv-input .rjv-label{font-size:14px;font-weight:bold}.rjv-demo .rjv-header{position:relative}.rjv-demo .rjv-header .rjv-logo{width:100px;position:absolute;right:0px;top:0px;cursor:pointer}.rjv-demo .rjv-header .github-btn{display:block;position:absolute;right:0px;top:48px}\n", ""]);
-// Exports
-/* harmony default export */ __webpack_exports__["default"] = (___CSS_LOADER_EXPORT___);
-
-
-/***/ }),
-/* 195 */
-/***/ (function(module, exports, __webpack_require__) {
-var api = __webpack_require__(30);
- var content = __webpack_require__(196);
- content = content.__esModule ? content.default : content;
- if (typeof content === 'string') {
- content = [[module.i, content, '']];
- }
-var options = {};
-options.insert = "head";
-options.singleton = false;
-var update = api(content, options);
+ //index entrypoint component
+var Demo_default = /*#__PURE__*/function (_React$PureComponent) {
+ _inherits(_default, _React$PureComponent);
+ var _super = _createSuper(_default);
-module.exports = content.locals || {};
+ function _default(props) {
+ var _this;
-/***/ }),
-/* 196 */
-/***/ (function(module, __webpack_exports__, __webpack_require__) {
+ _classCallCheck(this, _default);
+
+ cov_2jiapirmli().f[0]++;
+ cov_2jiapirmli().s[0]++;
+ _this = _super.call(this, props);
+ _this.getNotes = (cov_2jiapirmli().s[14]++, function (on_edit_enabled, on_add_enabled) {
+ cov_2jiapirmli().f[6]++;
+ var notes = (cov_2jiapirmli().s[15]++, []);
+ cov_2jiapirmli().s[16]++;
+
+ if (on_edit_enabled) {
+ cov_2jiapirmli().b[3][0]++;
+ cov_2jiapirmli().s[17]++;
+ notes.push( /*#__PURE__*/external_React_default.a.createElement("span", null, "To edit a value, try ", /*#__PURE__*/external_React_default.a.createElement(Code_default, null, "ctrl/cmd + click"), " enter edit mode"));
+ cov_2jiapirmli().s[18]++;
+ notes.push( /*#__PURE__*/external_React_default.a.createElement("span", null, "When editing a value, try ", /*#__PURE__*/external_React_default.a.createElement(Code_default, null, "ctrl/cmd + Enter"), " to submit changes"));
+ cov_2jiapirmli().s[19]++;
+ notes.push( /*#__PURE__*/external_React_default.a.createElement("span", null, "When editing a value, try ", /*#__PURE__*/external_React_default.a.createElement(Code_default, null, "Escape"), " key to cancel"));
+ } else {
+ cov_2jiapirmli().b[3][1]++;
+ }
-"use strict";
-__webpack_require__.r(__webpack_exports__);
-/* harmony import */ var _css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7);
-/* harmony import */ var _css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0__);
-// Imports
+ cov_2jiapirmli().s[20]++;
-var ___CSS_LOADER_EXPORT___ = _css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default()(false);
-// Module
-___CSS_LOADER_EXPORT___.push([module.i, ".Select{position:relative}.Select input::-webkit-contacts-auto-fill-button,.Select input::-webkit-credentials-auto-fill-button{display:none !important}.Select input::-ms-clear{display:none !important}.Select input::-ms-reveal{display:none !important}.Select,.Select div,.Select input,.Select span{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.Select.is-disabled .Select-arrow-zone{cursor:default;pointer-events:none;opacity:0.35}.Select.is-disabled>.Select-control{background-color:#f9f9f9}.Select.is-disabled>.Select-control:hover{box-shadow:none}.Select.is-open>.Select-control{border-bottom-right-radius:0;border-bottom-left-radius:0;background:#fff;border-color:#b3b3b3 #ccc #d9d9d9}.Select.is-open>.Select-control .Select-arrow{top:-2px;border-color:transparent transparent #999;border-width:0 5px 5px}.Select.is-searchable.is-open>.Select-control{cursor:text}.Select.is-searchable.is-focused:not(.is-open)>.Select-control{cursor:text}.Select.is-focused>.Select-control{background:#fff}.Select.is-focused:not(.is-open)>.Select-control{border-color:#007eff;box-shadow:inset 0 1px 1px rgba(0,0,0,0.075),0 0 0 3px rgba(0,126,255,0.1);background:#fff}.Select.has-value.is-clearable.Select--single>.Select-control .Select-value{padding-right:42px}.Select.has-value.Select--single>.Select-control .Select-value .Select-value-label,.Select.has-value.is-pseudo-focused.Select--single>.Select-control .Select-value .Select-value-label{color:#333}.Select.has-value.Select--single>.Select-control .Select-value a.Select-value-label,.Select.has-value.is-pseudo-focused.Select--single>.Select-control .Select-value a.Select-value-label{cursor:pointer;text-decoration:none}.Select.has-value.Select--single>.Select-control .Select-value a.Select-value-label:hover,.Select.has-value.is-pseudo-focused.Select--single>.Select-control .Select-value a.Select-value-label:hover,.Select.has-value.Select--single>.Select-control .Select-value a.Select-value-label:focus,.Select.has-value.is-pseudo-focused.Select--single>.Select-control .Select-value a.Select-value-label:focus{color:#007eff;outline:none;text-decoration:underline}.Select.has-value.Select--single>.Select-control .Select-value a.Select-value-label:focus,.Select.has-value.is-pseudo-focused.Select--single>.Select-control .Select-value a.Select-value-label:focus{background:#fff}.Select.has-value.is-pseudo-focused .Select-input{opacity:0}.Select.is-open .Select-arrow,.Select .Select-arrow-zone:hover>.Select-arrow{border-top-color:#666}.Select.Select--rtl{direction:rtl;text-align:right}.Select-control{background-color:#fff;border-color:#d9d9d9 #ccc #b3b3b3;border-radius:4px;border:1px solid #ccc;color:#333;cursor:default;display:table;border-spacing:0;border-collapse:separate;height:36px;outline:none;overflow:hidden;position:relative;width:100%}.Select-control:hover{box-shadow:0 1px 0 rgba(0,0,0,0.06)}.Select-control .Select-input:focus{outline:none;background:#fff}.Select-placeholder,.Select--single>.Select-control .Select-value{bottom:0;color:#aaa;left:0;line-height:34px;padding-left:10px;padding-right:10px;position:absolute;right:0;top:0;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.Select-input{height:34px;padding-left:10px;padding-right:10px;vertical-align:middle}.Select-input>input{width:100%;background:none transparent;border:0 none;box-shadow:none;cursor:default;display:inline-block;font-family:inherit;font-size:inherit;margin:0;outline:none;line-height:17px;padding:8px 0 12px;-webkit-appearance:none}.is-focused .Select-input>input{cursor:text}.has-value.is-pseudo-focused .Select-input{opacity:0}.Select-control:not(.is-searchable)>.Select-input{outline:none}.Select-loading-zone{cursor:pointer;display:table-cell;position:relative;text-align:center;vertical-align:middle;width:16px}.Select-loading{-webkit-animation:Select-animation-spin 400ms infinite linear;-o-animation:Select-animation-spin 400ms infinite linear;animation:Select-animation-spin 400ms infinite linear;width:16px;height:16px;box-sizing:border-box;border-radius:50%;border:2px solid #ccc;border-right-color:#333;display:inline-block;position:relative;vertical-align:middle}.Select-clear-zone{-webkit-animation:Select-animation-fadeIn 200ms;-o-animation:Select-animation-fadeIn 200ms;animation:Select-animation-fadeIn 200ms;color:#999;cursor:pointer;display:table-cell;position:relative;text-align:center;vertical-align:middle;width:17px}.Select-clear-zone:hover{color:#D0021B}.Select-clear{display:inline-block;font-size:18px;line-height:1}.Select--multi .Select-clear-zone{width:17px}.Select-arrow-zone{cursor:pointer;display:table-cell;position:relative;text-align:center;vertical-align:middle;width:25px;padding-right:5px}.Select--rtl .Select-arrow-zone{padding-right:0;padding-left:5px}.Select-arrow{border-color:#999 transparent transparent;border-style:solid;border-width:5px 5px 2.5px;display:inline-block;height:0;width:0;position:relative}.Select-control>*:last-child{padding-right:5px}.Select--multi .Select-multi-value-wrapper{display:inline-block}.Select .Select-aria-only{position:absolute;display:inline-block;height:1px;width:1px;margin:-1px;clip:rect(0, 0, 0, 0);overflow:hidden;float:left}@-webkit-keyframes Select-animation-fadeIn{from{opacity:0}to{opacity:1}}@keyframes Select-animation-fadeIn{from{opacity:0}to{opacity:1}}.Select-menu-outer{border-bottom-right-radius:4px;border-bottom-left-radius:4px;background-color:#fff;border:1px solid #ccc;border-top-color:#e6e6e6;box-shadow:0 1px 0 rgba(0,0,0,0.06);box-sizing:border-box;margin-top:-1px;max-height:200px;position:absolute;left:0;top:100%;width:100%;z-index:1;-webkit-overflow-scrolling:touch}.Select-menu{max-height:198px;overflow-y:auto}.Select-option{box-sizing:border-box;background-color:#fff;color:#666666;cursor:pointer;display:block;padding:8px 10px}.Select-option:last-child{border-bottom-right-radius:4px;border-bottom-left-radius:4px}.Select-option.is-selected{background-color:#f5faff;background-color:rgba(0,126,255,0.04);color:#333}.Select-option.is-focused{background-color:#ebf5ff;background-color:rgba(0,126,255,0.08);color:#333}.Select-option.is-disabled{color:#cccccc;cursor:default}.Select-noresults{box-sizing:border-box;color:#999999;cursor:default;display:block;padding:8px 10px}.Select--multi .Select-input{vertical-align:middle;margin-left:10px;padding:0}.Select--multi.Select--rtl .Select-input{margin-left:0;margin-right:10px}.Select--multi.has-value .Select-input{margin-left:5px}.Select--multi .Select-value{background-color:#ebf5ff;background-color:rgba(0,126,255,0.08);border-radius:2px;border:1px solid #c2e0ff;border:1px solid rgba(0,126,255,0.24);color:#007eff;display:inline-block;font-size:0.9em;line-height:1.4;margin-left:5px;margin-top:5px;vertical-align:top}.Select--multi .Select-value-icon,.Select--multi .Select-value-label{display:inline-block;vertical-align:middle}.Select--multi .Select-value-label{border-bottom-right-radius:2px;border-top-right-radius:2px;cursor:default;padding:2px 5px}.Select--multi a.Select-value-label{color:#007eff;cursor:pointer;text-decoration:none}.Select--multi a.Select-value-label:hover{text-decoration:underline}.Select--multi .Select-value-icon{cursor:pointer;border-bottom-left-radius:2px;border-top-left-radius:2px;border-right:1px solid #c2e0ff;border-right:1px solid rgba(0,126,255,0.24);padding:1px 5px 3px}.Select--multi .Select-value-icon:hover,.Select--multi .Select-value-icon:focus{background-color:#d8eafd;background-color:rgba(0,113,230,0.08);color:#0071e6}.Select--multi .Select-value-icon:active{background-color:#c2e0ff;background-color:rgba(0,126,255,0.24)}.Select--multi.Select--rtl .Select-value{margin-left:0;margin-right:5px}.Select--multi.Select--rtl .Select-value-icon{border-right:none;border-left:1px solid #c2e0ff;border-left:1px solid rgba(0,126,255,0.24)}.Select--multi.is-disabled .Select-value{background-color:#fcfcfc;border:1px solid #e3e3e3;color:#333}.Select--multi.is-disabled .Select-value-icon{cursor:not-allowed;border-right:1px solid #e3e3e3}.Select--multi.is-disabled .Select-value-icon:hover,.Select--multi.is-disabled .Select-value-icon:focus,.Select--multi.is-disabled .Select-value-icon:active{background-color:#fcfcfc}@keyframes Select-animation-spin{to{transform:rotate(1turn)}}@-webkit-keyframes Select-animation-spin{to{-webkit-transform:rotate(1turn)}}\n", ""]);
-// Exports
-/* harmony default export */ __webpack_exports__["default"] = (___CSS_LOADER_EXPORT___);
+ if (on_add_enabled) {
+ cov_2jiapirmli().b[4][0]++;
+ cov_2jiapirmli().s[21]++;
+ notes.push( /*#__PURE__*/external_React_default.a.createElement("span", null, "When adding a new key, try ", /*#__PURE__*/external_React_default.a.createElement(Code_default, null, "Enter"), " to submit"));
+ cov_2jiapirmli().s[22]++;
+ notes.push( /*#__PURE__*/external_React_default.a.createElement("span", null, "When adding a new key, try ", /*#__PURE__*/external_React_default.a.createElement(Code_default, null, "Escape"), " to cancel"));
+ } else {
+ cov_2jiapirmli().b[4][1]++;
+ }
+ cov_2jiapirmli().s[23]++;
-/***/ }),
-/* 197 */
-/***/ (function(module, exports, __webpack_require__) {
+ if (notes.length === 0) {
+ cov_2jiapirmli().b[5][0]++;
+ cov_2jiapirmli().s[24]++;
+ return null;
+ } else {
+ cov_2jiapirmli().b[5][1]++;
+ }
-var api = __webpack_require__(30);
- var content = __webpack_require__(198);
+ cov_2jiapirmli().s[25]++;
+ return /*#__PURE__*/external_React_default.a.createElement("div", {
+ style: {
+ marginTop: "20px",
+ fontStyle: "italic"
+ }
+ }, "Keyboard Shortcuts", /*#__PURE__*/external_React_default.a.createElement("ul", null, notes.map(function (note) {
+ cov_2jiapirmli().f[7]++;
+ cov_2jiapirmli().s[26]++;
+ return /*#__PURE__*/external_React_default.a.createElement("li", null, note);
+ })));
+ });
+ _this.getIconStyleInput = (cov_2jiapirmli().s[27]++, function (iconStyle) {
+ cov_2jiapirmli().f[8]++;
+ cov_2jiapirmli().s[28]++;
+ return /*#__PURE__*/external_React_default.a.createElement(react_select_es, {
+ name: "icon-style",
+ value: iconStyle,
+ options: [{
+ value: "circle",
+ label: "circle"
+ }, {
+ value: "square",
+ label: "square"
+ }, {
+ value: "triangle",
+ label: "triangle"
+ }],
+ onChange: function onChange(val) {
+ cov_2jiapirmli().f[9]++;
+ cov_2jiapirmli().s[29]++;
+
+ _this.set("iconStyle", val);
+ }
+ });
+ });
+ _this.getEditInput = (cov_2jiapirmli().s[30]++, function (onEdit) {
+ cov_2jiapirmli().f[10]++;
+ cov_2jiapirmli().s[31]++;
+ return /*#__PURE__*/external_React_default.a.createElement(react_select_es, {
+ name: "enable-edit",
+ value: onEdit,
+ options: [{
+ value: true,
+ label: "true"
+ }, {
+ value: false,
+ label: "false"
+ }],
+ onChange: function onChange(val) {
+ cov_2jiapirmli().f[11]++;
+ cov_2jiapirmli().s[32]++;
+
+ _this.set("onEdit", val);
+ }
+ });
+ });
+ _this.getAddInput = (cov_2jiapirmli().s[33]++, function (onAdd) {
+ cov_2jiapirmli().f[12]++;
+ cov_2jiapirmli().s[34]++;
+ return /*#__PURE__*/external_React_default.a.createElement(react_select_es, {
+ name: "enable-add",
+ value: onAdd,
+ options: [{
+ value: true,
+ label: "true"
+ }, {
+ value: false,
+ label: "false"
+ }],
+ onChange: function onChange(val) {
+ cov_2jiapirmli().f[13]++;
+ cov_2jiapirmli().s[35]++;
+
+ _this.set("onAdd", val);
+ }
+ });
+ });
+ _this.getDeleteInput = (cov_2jiapirmli().s[36]++, function (onDelete) {
+ cov_2jiapirmli().f[14]++;
+ cov_2jiapirmli().s[37]++;
+ return /*#__PURE__*/external_React_default.a.createElement(react_select_es, {
+ name: "enable-delete",
+ value: onDelete,
+ options: [{
+ value: true,
+ label: "true"
+ }, {
+ value: false,
+ label: "false"
+ }],
+ onChange: function onChange(val) {
+ cov_2jiapirmli().f[15]++;
+ cov_2jiapirmli().s[38]++;
+
+ _this.set("onDelete", val);
+ }
+ });
+ });
+ _this.getEnableClipboardInput = (cov_2jiapirmli().s[39]++, function (enableClipboard) {
+ cov_2jiapirmli().f[16]++;
+ cov_2jiapirmli().s[40]++;
+ return /*#__PURE__*/external_React_default.a.createElement(react_select_es, {
+ name: "enable-clipboard",
+ value: enableClipboard,
+ options: [{
+ value: true,
+ label: "true"
+ }, {
+ value: false,
+ label: "false"
+ }],
+ onChange: function onChange(val) {
+ cov_2jiapirmli().f[17]++;
+ cov_2jiapirmli().s[41]++;
+
+ _this.set("enableClipboard", val);
+ }
+ });
+ });
+ _this.getObjectSizeInput = (cov_2jiapirmli().s[42]++, function (displayObjectSize) {
+ cov_2jiapirmli().f[18]++;
+ cov_2jiapirmli().s[43]++;
+ return /*#__PURE__*/external_React_default.a.createElement(react_select_es, {
+ name: "display-object-size",
+ value: displayObjectSize,
+ options: [{
+ value: true,
+ label: "true"
+ }, {
+ value: false,
+ label: "false"
+ }],
+ onChange: function onChange(val) {
+ cov_2jiapirmli().f[19]++;
+ cov_2jiapirmli().s[44]++;
+
+ _this.set("displayObjectSize", val);
+ }
+ });
+ });
+ _this.getDataTypesInput = (cov_2jiapirmli().s[45]++, function (displayDataTypes) {
+ cov_2jiapirmli().f[20]++;
+ cov_2jiapirmli().s[46]++;
+ return /*#__PURE__*/external_React_default.a.createElement(react_select_es, {
+ name: "display-data-types",
+ value: displayDataTypes,
+ options: [{
+ value: true,
+ label: "true"
+ }, {
+ value: false,
+ label: "false"
+ }],
+ onChange: function onChange(val) {
+ cov_2jiapirmli().f[21]++;
+ cov_2jiapirmli().s[47]++;
+
+ _this.set("displayDataTypes", val);
+ }
+ });
+ });
+ _this.getCollapsedStringsInput = (cov_2jiapirmli().s[48]++, function (collapseStringsAfter) {
+ cov_2jiapirmli().f[22]++;
+ cov_2jiapirmli().s[49]++;
+ return /*#__PURE__*/external_React_default.a.createElement(react_select_es, {
+ name: "collapse-strings",
+ value: collapseStringsAfter,
+ options: [{
+ value: false,
+ label: "false"
+ }, {
+ value: 5,
+ label: 5
+ }, {
+ value: 10,
+ label: 10
+ }, {
+ value: 15,
+ label: 15
+ }, {
+ value: 20,
+ label: 20
+ }],
+ onChange: function onChange(val) {
+ cov_2jiapirmli().f[23]++;
+ cov_2jiapirmli().s[50]++;
+
+ _this.set("collapseStringsAfter", val);
+ }
+ });
+ });
+ _this.getCollapsedInput = (cov_2jiapirmli().s[51]++, function (collapsed) {
+ cov_2jiapirmli().f[24]++;
+ cov_2jiapirmli().s[52]++;
+ return /*#__PURE__*/external_React_default.a.createElement(react_select_es, {
+ name: "collapsed",
+ value: collapsed,
+ options: [{
+ value: true,
+ label: "true"
+ }, {
+ value: false,
+ label: "false"
+ }, {
+ value: 1,
+ label: 1
+ }, {
+ value: 2,
+ label: 2
+ }],
+ onChange: function onChange(val) {
+ cov_2jiapirmli().f[25]++;
+ cov_2jiapirmli().s[53]++;
+
+ _this.set("collapsed", val);
+ }
+ });
+ });
+ _this.getIndentWidthInput = (cov_2jiapirmli().s[54]++, function (indentWidth) {
+ cov_2jiapirmli().f[26]++;
+ cov_2jiapirmli().s[55]++;
+ return /*#__PURE__*/external_React_default.a.createElement(react_select_es, {
+ name: "indent-width",
+ value: indentWidth,
+ options: [{
+ value: 0,
+ label: 0
+ }, {
+ value: 1,
+ label: 1
+ }, {
+ value: 2,
+ label: 2
+ }, {
+ value: 3,
+ label: 3
+ }, {
+ value: 4,
+ label: 4
+ }, {
+ value: 5,
+ label: 5
+ }, {
+ value: 6,
+ label: 6
+ }, {
+ value: 7,
+ label: 7
+ }, {
+ value: 8,
+ label: 8
+ }, {
+ value: 9,
+ label: 9
+ }, {
+ value: 10,
+ label: 10
+ }],
+ onChange: function onChange(val) {
+ cov_2jiapirmli().f[27]++;
+ cov_2jiapirmli().s[56]++;
+
+ _this.set("indentWidth", val);
+ }
+ });
+ });
+ _this.getThemeInput = (cov_2jiapirmli().s[57]++, function (theme) {
+ cov_2jiapirmli().f[28]++;
+ cov_2jiapirmli().s[58]++;
+ return /*#__PURE__*/external_React_default.a.createElement(react_select_es, {
+ name: "theme-select",
+ value: theme,
+ options: [{
+ value: "apathy",
+ label: "apathy"
+ }, {
+ value: "apathy:inverted",
+ label: "apathy:inverted"
+ }, {
+ value: "ashes",
+ label: "ashes"
+ }, {
+ value: "bespin",
+ label: "bespin"
+ }, {
+ value: "brewer",
+ label: "brewer"
+ }, {
+ value: "bright:inverted",
+ label: "bright:inverted"
+ }, {
+ value: "bright",
+ label: "bright"
+ }, {
+ value: "chalk",
+ label: "chalk"
+ }, {
+ value: "codeschool",
+ label: "codeschool"
+ }, {
+ value: "colors",
+ label: "colors"
+ }, {
+ value: "eighties",
+ label: "eighties"
+ }, {
+ value: "embers",
+ label: "embers"
+ }, {
+ value: "flat",
+ label: "flat"
+ }, {
+ value: "google",
+ label: "google"
+ }, {
+ value: "grayscale",
+ label: "grayscale"
+ }, {
+ value: "grayscale:inverted",
+ label: "grayscale:inverted"
+ }, {
+ value: "greenscreen",
+ label: "greenscreen"
+ }, {
+ value: "harmonic",
+ label: "harmonic"
+ }, {
+ value: "hopscotch",
+ label: "hopscotch"
+ }, {
+ value: "isotope",
+ label: "isotope"
+ }, {
+ value: "marrakesh",
+ label: "marrakesh"
+ }, {
+ value: "mocha",
+ label: "mocha"
+ }, {
+ value: "monokai",
+ label: "monokai"
+ }, {
+ value: "ocean",
+ label: "ocean"
+ }, {
+ value: "paraiso",
+ label: "paraiso"
+ }, {
+ value: "pop",
+ label: "pop"
+ }, {
+ value: "railscasts",
+ label: "railscasts"
+ }, {
+ value: "rjv-default",
+ label: "rjv-default"
+ }, {
+ value: "shapeshifter",
+ label: "shapeshifter"
+ }, {
+ value: "shapeshifter:inverted",
+ label: "shapeshifter:inverted"
+ }, {
+ value: "solarized",
+ label: "solarized"
+ }, {
+ value: "summerfruit",
+ label: "summerfruit"
+ }, {
+ value: "summerfruit:inverted",
+ label: "summerfruit:inverted"
+ }, {
+ value: "threezerotwofour",
+ label: "threezerotwofour"
+ }, {
+ value: "tomorrow",
+ label: "tomorrow"
+ }, {
+ value: "tube",
+ label: "tube"
+ }, {
+ value: "twilight",
+ label: "twilight"
+ }],
+ onChange: function onChange(val) {
+ cov_2jiapirmli().f[29]++;
+ cov_2jiapirmli().s[59]++;
+
+ _this.set("theme", val);
+ }
+ });
+ });
+ _this.set = (cov_2jiapirmli().s[60]++, function (field, value) {
+ cov_2jiapirmli().f[30]++;
+ var state = (cov_2jiapirmli().s[61]++, {});
+ cov_2jiapirmli().s[62]++;
+ state[field] = value.value;
+ cov_2jiapirmli().s[63]++;
+
+ _this.setState(state);
+ });
+ _this.getExampleJson = (cov_2jiapirmli().s[64]++, function () {
+ cov_2jiapirmli().f[31]++;
+ cov_2jiapirmli().s[65]++;
+ return {
+ string: "this is a test string",
+ integer: 42,
+ array: [1, 2, 3, "test", NaN],
+ "float": 3.14159,
+ undefined: undefined,
+ object: {
+ "first-child": true,
+ "second-child": false,
+ "last-child": null
+ },
+ string_number: "1234",
+ date: new Date()
+ };
+ });
+ cov_2jiapirmli().s[1]++;
+ _this.state = {
+ src: _this.getExampleJson()
+ };
+ return _this;
+ }
- content = content.__esModule ? content.default : content;
+ _createClass(_default, [{
+ key: "render",
+ value: function render() {
+ var _this2 = this;
+
+ cov_2jiapirmli().f[1]++;
+
+ var _ref = (cov_2jiapirmli().s[3]++, this.props),
+ collapseStringsAfter = _ref.collapseStringsAfter,
+ onAdd = _ref.onAdd,
+ onEdit = _ref.onEdit,
+ onDelete = _ref.onDelete,
+ displayObjectSize = _ref.displayObjectSize,
+ enableClipboard = _ref.enableClipboard,
+ theme = _ref.theme,
+ iconStyle = _ref.iconStyle,
+ collapsed = _ref.collapsed,
+ indentWidth = _ref.indentWidth,
+ displayDataTypes = _ref.displayDataTypes;
+
+ var _ref2 = (cov_2jiapirmli().s[4]++, this.state),
+ src = _ref2.src;
+
+ var style = (cov_2jiapirmli().s[5]++, {
+ padding: "10px",
+ borderRadius: "3px",
+ margin: "10px 0px"
+ });
+ cov_2jiapirmli().s[6]++;
+ return /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "rjv-demo"
+ }, /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "rjv-header"
+ }, /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "header-1"
+ }, "react-json-view"), /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "header-2"
+ }, "component demo"), /*#__PURE__*/external_React_default.a.createElement("img", {
+ className: "rjv-logo",
+ src: "https://github.com/mac-s-g/react-json-view/blob/master/doc/rjv-icon-alt.png?raw=true",
+ onClick: function onClick() {
+ cov_2jiapirmli().f[2]++;
+ cov_2jiapirmli().s[7]++;
+ window.open("https://github.com/mac-s-g/react-json-view", "_blank");
+ }
+ }), /*#__PURE__*/external_React_default.a.createElement(react_github_button_lib_default.a, {
+ type: "stargazers",
+ namespace: "mac-s-g",
+ repo: "react-json-view"
+ })), /*#__PURE__*/external_React_default.a.createElement(js, {
+ name: false,
+ collapsed: collapsed,
+ style: style,
+ theme: theme,
+ src: src,
+ collapseStringsAfterLength: collapseStringsAfter,
+ onEdit: onEdit ? (cov_2jiapirmli().b[0][0]++, function (e) {
+ cov_2jiapirmli().f[3]++;
+ cov_2jiapirmli().s[8]++;
+ console.log(e);
+ cov_2jiapirmli().s[9]++;
+
+ _this2.setState({
+ src: e.updated_src
+ });
+ }) : (cov_2jiapirmli().b[0][1]++, false),
+ onDelete: onDelete ? (cov_2jiapirmli().b[1][0]++, function (e) {
+ cov_2jiapirmli().f[4]++;
+ cov_2jiapirmli().s[10]++;
+ console.log(e);
+ cov_2jiapirmli().s[11]++;
+
+ _this2.setState({
+ src: e.updated_src
+ });
+ }) : (cov_2jiapirmli().b[1][1]++, false),
+ onAdd: onAdd ? (cov_2jiapirmli().b[2][0]++, function (e) {
+ cov_2jiapirmli().f[5]++;
+ cov_2jiapirmli().s[12]++;
+ console.log(e);
+ cov_2jiapirmli().s[13]++;
+
+ _this2.setState({
+ src: e.updated_src
+ });
+ }) : (cov_2jiapirmli().b[2][1]++, false),
+ displayObjectSize: displayObjectSize,
+ enableClipboard: enableClipboard,
+ indentWidth: indentWidth,
+ displayDataTypes: displayDataTypes,
+ iconStyle: iconStyle
+ }), /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "rjv-settings"
+ }, /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "rjv-input"
+ }, /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "rjv-label"
+ }, "Theme:"), this.getThemeInput(theme)), /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "rjv-input"
+ }, /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "rjv-label"
+ }, "Icon Style:"), this.getIconStyleInput(iconStyle)), /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "rjv-input"
+ }, /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "rjv-label"
+ }, "Enable Edit:"), this.getEditInput(onEdit)), /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "rjv-input"
+ }, /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "rjv-label"
+ }, "Enable Add:"), this.getAddInput(onAdd)), /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "rjv-input"
+ }, /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "rjv-label"
+ }, "Enable Delete:"), this.getDeleteInput(onDelete)), /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "rjv-input"
+ }, /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "rjv-label"
+ }, "Enable Clipboard:"), this.getEnableClipboardInput(enableClipboard))), /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "rjv-settings"
+ }, /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "rjv-input"
+ }, /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "rjv-label"
+ }, "Display Data Types:"), this.getDataTypesInput(displayDataTypes)), /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "rjv-input"
+ }, /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "rjv-label"
+ }, "Display Object Size:"), this.getObjectSizeInput(displayObjectSize)), /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "rjv-input"
+ }, /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "rjv-label"
+ }, "Indent Width:"), this.getIndentWidthInput(indentWidth)), /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "rjv-input"
+ }, /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "rjv-label"
+ }, "Collapsed:"), this.getCollapsedInput(collapsed)), /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "rjv-input"
+ }, /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "rjv-label"
+ }, "Collapse Strings After Length:"), this.getCollapsedStringsInput(collapseStringsAfter))), this.getNotes(onEdit, onAdd));
+ }
+ }]);
+
+ return _default;
+}((external_React_default.a.PureComponent));
+
+Demo_default.defaultProps = (cov_2jiapirmli().s[2]++, {
+ theme: "monokai",
+ src: null,
+ collapsed: false,
+ collapseStringsAfter: 15,
+ onAdd: true,
+ onEdit: true,
+ onDelete: true,
+ displayObjectSize: true,
+ enableClipboard: true,
+ indentWidth: 4,
+ displayDataTypes: true,
+ iconStyle: "triangle"
+});
- if (typeof content === 'string') {
- content = [[module.i, content, '']];
- }
+// CONCATENATED MODULE: ./demo/src/js/index.js
-var options = {};
-options.insert = "head";
-options.singleton = false;
-var update = api(content, options);
+function cov_2biny5boq7() {
+ var path = "/home/mac/dev/git/personal/react-json-view/demo/src/js/index.js";
+ var hash = "a15911444bc3a2b1c6c45b44c92bfe19adbb9a46";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/demo/src/js/index.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 8,
+ column: 27
+ },
+ end: {
+ line: 8,
+ column: 37
+ }
+ },
+ "1": {
+ start: {
+ line: 9,
+ column: 8
+ },
+ end: {
+ line: 11,
+ column: 16
+ }
+ }
+ },
+ fnMap: {
+ "0": {
+ name: "(anonymous_0)",
+ decl: {
+ start: {
+ line: 7,
+ column: 4
+ },
+ end: {
+ line: 7,
+ column: 5
+ }
+ },
+ loc: {
+ start: {
+ line: 7,
+ column: 13
+ },
+ end: {
+ line: 12,
+ column: 5
+ }
+ },
+ line: 7
+ }
+ },
+ branchMap: {},
+ s: {
+ "0": 0,
+ "1": 0
+ },
+ f: {
+ "0": 0
+ },
+ b: {},
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "a15911444bc3a2b1c6c45b44c92bfe19adbb9a46"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
-module.exports = content.locals || {};
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
-/***/ }),
-/* 198 */
-/***/ (function(module, __webpack_exports__, __webpack_require__) {
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_2biny5boq7 = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
-"use strict";
-__webpack_require__.r(__webpack_exports__);
-/* harmony import */ var _css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7);
-/* harmony import */ var _css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0__);
-// Imports
+cov_2biny5boq7();
-var ___CSS_LOADER_EXPORT___ = _css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default()(false);
-// Module
-___CSS_LOADER_EXPORT___.push([module.i, ".github-btn{font:bold 11px/14px 'Helvetica Neue', Helvetica, Arial, sans-serif;height:20px;overflow:hidden}.gh-btn,.gh-count,.gh-ico{float:left}.gh-btn,.gh-count{padding:2px 5px 2px 4px;color:#333;text-decoration:none;white-space:nowrap;cursor:pointer;border-radius:3px}.gh-btn{background-color:#eee;background-image:-webkit-gradient(linear, left top, left bottom, color-stop(0, #fcfcfc), color-stop(100%, #eee));background-image:-webkit-linear-gradient(top, #fcfcfc 0, #eee 100%);background-image:-moz-linear-gradient(top, #fcfcfc 0, #eee 100%);background-image:-ms-linear-gradient(top, #fcfcfc 0, #eee 100%);background-image:-o-linear-gradient(top, #fcfcfc 0, #eee 100%);background-image:linear-gradient(to bottom, #fcfcfc 0, #eee 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fcfcfc', endColorstr='#eeeeee', GradientType=0);background-repeat:no-repeat;border:1px solid #d5d5d5}.gh-btn:hover,.gh-btn:focus{text-decoration:none;background-color:#ddd;background-image:-webkit-gradient(linear, left top, left bottom, color-stop(0, #eee), color-stop(100%, #ddd));background-image:-webkit-linear-gradient(top, #eee 0, #ddd 100%);background-image:-moz-linear-gradient(top, #eee 0, #ddd 100%);background-image:-ms-linear-gradient(top, #eee 0, #ddd 100%);background-image:-o-linear-gradient(top, #eee 0, #ddd 100%);background-image:linear-gradient(to bottom, #eee 0, #ddd 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#eeeeee', endColorstr='#dddddd', GradientType=0);border-color:#ccc}.gh-btn:active{background-image:none;background-color:#dcdcdc;border-color:#b5b5b5;box-shadow:inset 0 2px 4px rgba(0,0,0,0.15)}.gh-ico{width:14px;height:14px;margin-right:4px;background-image:url(\"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB2ZXJzaW9uPSIxLjEiIGlkPSJMYXllcl8xIiB4PSIwcHgiIHk9IjBweCIgd2lkdGg9IjQwcHgiIGhlaWdodD0iNDBweCIgdmlld0JveD0iMTIgMTIgNDAgNDAiIGVuYWJsZS1iYWNrZ3JvdW5kPSJuZXcgMTIgMTIgNDAgNDAiIHhtbDpzcGFjZT0icHJlc2VydmUiPjxwYXRoIGZpbGw9IiMzMzMzMzMiIGQ9Ik0zMiAxMy40Yy0xMC41IDAtMTkgOC41LTE5IDE5YzAgOC40IDUuNSAxNS41IDEzIDE4YzEgMC4yIDEuMy0wLjQgMS4zLTAuOWMwLTAuNSAwLTEuNyAwLTMuMiBjLTUuMyAxLjEtNi40LTIuNi02LjQtMi42QzIwIDQxLjYgMTguOCA0MSAxOC44IDQxYy0xLjctMS4yIDAuMS0xLjEgMC4xLTEuMWMxLjkgMC4xIDIuOSAyIDIuOSAyYzEuNyAyLjkgNC41IDIuMSA1LjUgMS42IGMwLjItMS4yIDAuNy0yLjEgMS4yLTIuNmMtNC4yLTAuNS04LjctMi4xLTguNy05LjRjMC0yLjEgMC43LTMuNyAyLTUuMWMtMC4yLTAuNS0wLjgtMi40IDAuMi01YzAgMCAxLjYtMC41IDUuMiAyIGMxLjUtMC40IDMuMS0wLjcgNC44LTAuN2MxLjYgMCAzLjMgMC4yIDQuNyAwLjdjMy42LTIuNCA1LjItMiA1LjItMmMxIDIuNiAwLjQgNC42IDAuMiA1YzEuMiAxLjMgMiAzIDIgNS4xYzAgNy4zLTQuNSA4LjktOC43IDkuNCBjMC43IDAuNiAxLjMgMS43IDEuMyAzLjVjMCAyLjYgMCA0LjYgMCA1LjJjMCAwLjUgMC40IDEuMSAxLjMgMC45YzcuNS0yLjYgMTMtOS43IDEzLTE4LjFDNTEgMjEuOSA0Mi41IDEzLjQgMzIgMTMuNHoiLz48L3N2Zz4=\");background-size:100% 100%;background-repeat:no-repeat}.gh-count{position:relative;display:none;margin-left:4px;background-color:#fafafa;border:1px solid #d4d4d4}.gh-count:hover,.gh-count:focus{color:#4183C4}.gh-count:before,.gh-count:after{content:'';position:absolute;display:inline-block;width:0;height:0;border-color:transparent;border-style:solid}.gh-count:before{top:50%;left:-3px;margin-top:-4px;border-width:4px 4px 4px 0;border-right-color:#fafafa}.gh-count:after{top:50%;left:-4px;z-index:-1;margin-top:-5px;border-width:5px 5px 5px 0;border-right-color:#d4d4d4}.github-btn-large{height:30px}.github-btn-large .gh-btn,.github-btn-large .gh-count{padding:3px 10px 3px 8px;font-size:16px;line-height:22px;border-radius:4px}.github-btn-large .gh-ico{width:20px;height:20px}.github-btn-large .gh-count{margin-left:6px}.github-btn-large .gh-count:before{left:-5px;margin-top:-6px;border-width:6px 6px 6px 0}.github-btn-large .gh-count:after{left:-6px;margin-top:-7px;border-width:7px 7px 7px 0}\n", ""]);
-// Exports
-/* harmony default export */ __webpack_exports__["default"] = (___CSS_LOADER_EXPORT___);
+ //index entrypoint component
+var js_default = /*#__PURE__*/function (_React$PureComponent) {
+ _inherits(_default, _React$PureComponent);
-/***/ }),
-/* 199 */
-/***/ (function(module, exports, __webpack_require__) {
+ var _super = _createSuper(_default);
-var api = __webpack_require__(30);
- var content = __webpack_require__(200);
+ function _default() {
+ _classCallCheck(this, _default);
- content = content.__esModule ? content.default : content;
+ return _super.apply(this, arguments);
+ }
- if (typeof content === 'string') {
- content = [[module.i, content, '']];
- }
+ _createClass(_default, [{
+ key: "render",
+ value: function render() {
+ cov_2biny5boq7().f[0]++;
-var options = {};
+ var _ref = (cov_2biny5boq7().s[0]++, this.state),
+ props = Object.assign({}, _ref);
-options.insert = "head";
-options.singleton = false;
+ cov_2biny5boq7().s[1]++;
+ return /*#__PURE__*/external_React_default.a.createElement("div", {
+ className: "mac-react"
+ }, /*#__PURE__*/external_React_default.a.createElement(Demo_default, null));
+ }
+ }]);
+
+ return _default;
+}((external_React_default.a.PureComponent));
+
+
+// CONCATENATED MODULE: ./demo/src/js/entry.js
+function cov_qd7mu9cbc() {
+ var path = "/home/mac/dev/git/personal/react-json-view/demo/src/js/entry.js";
+ var hash = "ffff75fb6cebd3bbfca34dbf705536a5bf7b8dd2";
+ var global = new Function("return this")();
+ var gcv = "__coverage__";
+ var coverageData = {
+ path: "/home/mac/dev/git/personal/react-json-view/demo/src/js/entry.js",
+ statementMap: {
+ "0": {
+ start: {
+ line: 4,
+ column: 0
+ },
+ end: {
+ line: 4,
+ column: 39
+ }
+ },
+ "1": {
+ start: {
+ line: 6,
+ column: 12
+ },
+ end: {
+ line: 6,
+ column: 58
+ }
+ },
+ "2": {
+ start: {
+ line: 9,
+ column: 0
+ },
+ end: {
+ line: 14,
+ column: 2
+ }
+ }
+ },
+ fnMap: {},
+ branchMap: {},
+ s: {
+ "0": 0,
+ "1": 0,
+ "2": 0
+ },
+ f: {},
+ b: {},
+ _coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
+ hash: "ffff75fb6cebd3bbfca34dbf705536a5bf7b8dd2"
+ };
+ var coverage = global[gcv] || (global[gcv] = {});
-var update = api(content, options);
+ if (!coverage[path] || coverage[path].hash !== hash) {
+ coverage[path] = coverageData;
+ }
+ var actualCoverage = coverage[path];
+ {
+ // @ts-ignore
+ cov_qd7mu9cbc = function () {
+ return actualCoverage;
+ };
+ }
+ return actualCoverage;
+}
+cov_qd7mu9cbc();
-module.exports = content.locals || {};
-/***/ }),
-/* 200 */
-/***/ (function(module, __webpack_exports__, __webpack_require__) {
+cov_qd7mu9cbc().s[0]++;
-"use strict";
-__webpack_require__.r(__webpack_exports__);
-/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7);
-/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0__);
-// Imports
+__webpack_require__(159);
-var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default()(false);
-___CSS_LOADER_EXPORT___.push([module.i, "@import url(https://fonts.googleapis.com/css?family=Open+Sans);"]);
-// Module
-___CSS_LOADER_EXPORT___.push([module.i, "#mac-react-container{font-family:\"Open Sans\";padding:20px}#mac-react-container .header-1{font-size:28px;margin-right:5px;margin-bottom:3px}#mac-react-container .header-2{font-size:22px;margin-right:5px;margin-bottom:5px;font-style:italic}\n", ""]);
-// Exports
-/* harmony default export */ __webpack_exports__["default"] = (___CSS_LOADER_EXPORT___);
+var app = (cov_qd7mu9cbc().s[1]++, document.getElementById('mac-react-container')); //app entrypoint
+cov_qd7mu9cbc().s[2]++;
+external_ReactDOM_default.a.render( /*#__PURE__*/React.createElement("div", {
+ className: "app-entry"
+}, /*#__PURE__*/React.createElement(js_default, null)), app);
/***/ })
/******/ ]);
diff --git a/docker/entrypoints/demo.sh b/docker/entrypoints/demo.sh
index 6617f707..2f2ac599 100755
--- a/docker/entrypoints/demo.sh
+++ b/docker/entrypoints/demo.sh
@@ -14,6 +14,7 @@ fi
# now, build the app
cd /react
+
npm run build:demo
echo Copied distribution to /demo/dist
diff --git a/package-lock.json b/package-lock.json
index 1592e8a6..5d20698b 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -1,6 +1,6 @@
{
"name": "react-json-view",
- "version": "1.19.1",
+ "version": "1.20.0",
"lockfileVersion": 1,
"requires": true,
"dependencies": {
@@ -15769,28 +15769,6 @@
"lower-case": "^1.1.1"
}
},
- "node": {
- "version": "10.23.0",
- "resolved": "https://registry.npmjs.org/node/-/node-10.23.0.tgz",
- "integrity": "sha512-iC4soH/Ej+F/ncc5s1vs5w1rp/iIKym2p8CM05VsfLHkj0FFMUoYbsTSXtICFmFeou9FCGNs0XrPImhP3xlAPA==",
- "dev": true,
- "requires": {
- "node-bin-setup": "^1.0.0"
- },
- "dependencies": {
- "node-linux-x64": {
- "version": "10.23.0",
- "resolved": "https://registry.npmjs.org/node-linux-x64/-/node-linux-x64-10.23.0.tgz",
- "integrity": "sha512-KuUWzD+jGcycoKQ1+9slLfgMSBRAysXYq9jI/YtjtdYS/j2wFAgu+9AEhlxzA3VocM6xv8QMS2SHoIknd+wl8g=="
- }
- }
- },
- "node-bin-setup": {
- "version": "1.0.6",
- "resolved": "https://registry.npmjs.org/node-bin-setup/-/node-bin-setup-1.0.6.tgz",
- "integrity": "sha512-uPIxXNis1CRbv1DwqAxkgBk5NFV3s7cMN/Gf556jSw6jBvV7ca4F9lRL/8cALcZecRibeqU+5dFYqFFmzv5a0Q==",
- "dev": true
- },
"node-fetch": {
"version": "1.7.3",
"resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-1.7.3.tgz",
diff --git a/package.json b/package.json
index c796f6b5..1532a848 100644
--- a/package.json
+++ b/package.json
@@ -1,7 +1,7 @@
{
"name": "react-json-view",
"description": "Interactive react component for displaying javascript arrays and JSON objects.",
- "version": "1.19.1",
+ "version": "1.20.0",
"main": "dist/main.js",
"dependencies": {
"flux": "^3.1.3",
@@ -28,7 +28,6 @@
"jsdom": "^16.4.0",
"mocha": "^8.2.1",
"moment": "^2.29.1",
- "node": "^10.23.0",
"node-sass": "^4.14.1",
"nyc": "^15.1.0",
"prettier": "^2.2.1",
@@ -49,13 +48,14 @@
"webpack-dev-server": "^3.11.2"
},
"peerDependencies": {
+ "node": "^10.23.0",
"react": "^17.0.0 || ^16.3.0 || ^15.5.4",
"react-dom": "^17.0.0 || ^16.3.0 || ^15.5.4"
},
"scripts": {
- "build": "webpack --config webpack/webpack.config.js -p --display-error-details --progress --optimize-minimize",
- "prebuild": "npm run test:unit",
- "build:demo": "webpack --config webpack/webpack.config-demo.js -p --display-error-details --progress --optimize-minimize",
+ "build": "NODE_ENV=production webpack --config webpack/webpack.config.js -p --display-error-details --progress --optimize-minimize",
+ "prebuild": "NODE_ENV=test npm run test:unit",
+ "build:demo": "NODE_ENV=production webpack --config webpack/webpack.config-demo.js -p --display-error-details --progress --optimize-minimize",
"dev": "NODE_ENV=development webpack-dev-server --config webpack/webpack.config-dev.js --open",
"modules:debug": "./docker/debug.sh",
"modules:tree": "webpack --config webpack/webpack.config.js --json ",