From ede5116076b614347d5d554486eed8607eda98c6 Mon Sep 17 00:00:00 2001 From: Stefan Verhoeven Date: Thu, 16 Apr 2020 14:57:14 +0200 Subject: [PATCH 1/6] Mock Oracle queries and mock workflow api --- server.js | 56 ++++++++++++++++++++++++++++++++++++++++++++++++++----- 1 file changed, 51 insertions(+), 5 deletions(-) diff --git a/server.js b/server.js index e974701..d3a6366 100644 --- a/server.js +++ b/server.js @@ -2,13 +2,13 @@ let express = require('express'), compression = require('compression'), - products = require('./server/products'), - database = require('./server/database.js'), + // products = require('./server/products'), + // database = require('./server/database.js'), app = express(); try { console.log('Initializing database module'); - database.initialize(); + // database.initialize(); } catch (err) { console.error(err); process.exit(1); // Non-zero failure code @@ -37,8 +37,54 @@ app.all('*', function (req, res, next) { } }); -app.get('/products', products.findAll); -app.get('/product/:lid', products.findByProdId); +// app.get('/products', products.findAll); +// app.get('/product/:lid', products.findByProdId); +app.get('/products', function(req,res) { + const products = [{ + NR_SUBBANDS: 123, OBSERVATIONID: 'obsid1', LID: 'lid1', DECLINATION: 32.1, RIGHTASCENSION: 56.7, STARTTIME: new Date(2020,4,4), ENDTIME: new Date(2020,4,10) + }, { + NR_SUBBANDS: 123, OBSERVATIONID: 'obsid2', LID: 'lid2', DECLINATION: 32.1, RIGHTASCENSION: 56.7, STARTTIME: new Date(2020,4,4), ENDTIME: new Date(2020,4,10) + }, { + NR_SUBBANDS: 123, OBSERVATIONID: 'obsid3', LID: 'lid3', DECLINATION: 32.1, RIGHTASCENSION: 56.7, STARTTIME: new Date(2020,4,4), ENDTIME: new Date(2020,4,10) + }] + res.json({products}); +}); +app.get('/product/:lid', function(res, req) { + const products = [{ + URI: 'https://someuri/' + req.params.lid + }]; + res.json({"products": products}); +}); +app.get('/pipelineschemas', function(req,res) { + const pipelineschemas = { + pipeline1: { + label: 'Pipeline 1', + id: 'pipeline1', + schema: { + "type": "object", + "title": "Configuration Parameters:", + "description": "This is the LOFAR GRID Pre-Processing Pipeline. Here we print a description of the pipeline.", + "properties": { + "avg_freq_step": { + "type": "integer", + "title": "avg_freq_step", + "description": "corresponds to .freqstep in NDPPP .type=average , or in case of .type=demixer it is the demixer.freqstep", + "default": 2, + "minimum": 0, + "exclusiveMinimum": true, + "maximum": 1000, + "exclusiveMaximum": true, + "propertyOrder": 1 + }, + }, + "required": [ + "avg_freq_step", + ] + } + } + }; + res.json({pipelineschemas}); +}); app.listen(app.get('port'), function () { console.log('Express server listening on port ' + app.get('port')); From 71c56b6554916d2d469ee4963c5014f99830cbde Mon Sep 17 00:00:00 2001 From: souley Date: Wed, 22 Apr 2020 07:20:16 -0400 Subject: [PATCH 2/6] adding double table --- app/components/ProductList/index.js | 191 +++++++++++++++++++++++----- 1 file changed, 159 insertions(+), 32 deletions(-) diff --git a/app/components/ProductList/index.js b/app/components/ProductList/index.js index cb44f79..a591791 100644 --- a/app/components/ProductList/index.js +++ b/app/components/ProductList/index.js @@ -253,6 +253,7 @@ class PipelineConfigurator extends React.Component { const email = this.props.email const description = this.props.description const submitEndpoint = '/sessions' + let observation fetch('/product/' + this.props.lid, { headers: { 'content-type': 'application/json' @@ -262,20 +263,31 @@ class PipelineConfigurator extends React.Component { else throw 'Server returned ' + response.statusText}) .then(srmuris => { - const body = {pipeline, email, description, config: this.state.config, observation: srmuris.products.map((d) => d.URI).join('|')}; - return fetch(submitEndpoint, { - body: JSON.stringify(body), - method: 'POST', // *GET, POST, PUT, DELETE, etc. - mode: 'cors', // no-cors, cors, *same-origin - headers: { - 'content-type': 'application/json' - }, - }) + observation = srmuris.products.map((d) => d.URI).join('|'); }) + fetch('/product/' + this.props.lid2, { + headers: { + 'content-type': 'application/json' + } + }).then(response => {if (response.ok) + return response.json() + else + throw 'Server returned ' + response.statusText}) + .then(srmuris => { + const body = {pipeline, email, description, config: this.state.config, observation, observation2: srmuris.products.map((d) => d.URI).join('|')}; + return fetch(submitEndpoint, { + body: JSON.stringify(body), + method: 'POST', // *GET, POST, PUT, DELETE, etc. + mode: 'cors', // no-cors, cors, *same-origin + headers: { + 'content-type': 'application/json' + }, + }) + }) .then(response => {if (response.ok) - return response.json() - else - throw 'Server returned ' + response.statusText}) + return response.json() + else + throw 'Server returned ' + response.statusText}) .then(this.processResponse) // parses response to JSON .catch(this.handleError) } @@ -515,11 +527,42 @@ class RangeFilter extends React.Component { } }; */ + +class ProductChooser extends React.Component { + constructor(props) { + super(props); + } + + render() { + let selectRow = { + mode: 'radio', + clickToSelect: true, + hideSelectAll: true, + onSelect: this.props.onSelect + }; + + const pagination = paginationFactory({ + page: 1, + sizePerPage: 5 + }); + + return ( + + ); + } +} + export default class FRBTable extends React.Component { constructor(props) { super(props); this.state = { showModal: false, meas: {}, + meas2: {}, page: 1, sizePerPage: 25, // dropdown @@ -542,7 +585,10 @@ export default class FRBTable extends React.Component { this.getPipelines = this.getPipelines.bind(this); this.updateEmail = this.updateEmail.bind(this); this.updateJobDescription = this.updateJobDescription.bind(this); + this.handleSelect = this.handleSelect.bind(this); + this.handleSelect2 = this.handleSelect2.bind(this); } + componentDidMount() { this.getPipelines(); } @@ -605,6 +651,10 @@ export default class FRBTable extends React.Component { meas }); } + openProcessingDialog(e) { + this.setState({ showModal: true }); + } + changeStateAttributeValue(stateName, attributeKey, attributeValue) { // changes a single attributes on a given state var newState = this.state; @@ -700,18 +750,29 @@ export default class FRBTable extends React.Component { { props.exportCSVBtn } ); } + + handleSelect(row) { + console.log('Table1 selected row: ') + console.log(row) + this.setState({meas: row}); + } + + handleSelect2(row) { + this.setState({meas2: row}); + } render() { const columns = [ - { - dataField: 'button', - formatter: this.customInfoButton.bind(this), - text: '', - headerTitle: false, - headerStyle: (colum, colIndex) => { - return { width: '60px', textAlign: 'center' }; - } - }, { +// { +// dataField: 'button', +// formatter: this.customInfoButton.bind(this), +// text: '', +// headerTitle: false, +// headerStyle: (colum, colIndex) => { +// return { width: '60px', textAlign: 'center' }; +// } +// }, + { dataField: 'OBSERVATIONID', text: 'OBSERVATIONID', sort: false, @@ -754,11 +815,11 @@ export default class FRBTable extends React.Component { page: this.state.page, sizePerPage: this.state.sizePerPage, sizePerPageList: [ { + text: '5', value: 5 + }, { text: '10', value: 10 }, { text: '25', value: 25 - }, { - text: '50', value: 50 } ], prePage: 'Prev', // Previous page button text nextPage: 'Next', // Next page button text @@ -787,6 +848,18 @@ export default class FRBTable extends React.Component { ); } +// const selectRow = { +// mode: 'radio', +// clickToSelect: true, +// hideSelectAll: true, +// onSelect: (row, isSelect, rowIndex, e) => { +//// if (this.state.meas == {}) { +//// this.setState({meas: row}); +//// } else { +//// this.setState({meas2: row}); +//// } +// } +// }; // Define select column modal entries // don't recall db for each overview for now, too slow // @@ -795,7 +868,7 @@ export default class FRBTable extends React.Component {
- Observation overview + Observations overview @@ -804,7 +877,7 @@ export default class FRBTable extends React.Component { + + +
- + @@ -833,6 +906,39 @@ export default class FRBTable extends React.Component {
Product Parameters
Calibrator Parameters
Observation ID {this.state.meas.OBSERVATIONID}
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Target Parameters
Observation ID{this.state.meas2.OBSERVATIONID}
Start time{this.state.meas2.STARTTIME}
End time{this.state.meas2.ENDTIME}
Right Ascension{this.state.meas2.RIGHTASCENSION}
Declination{this.state.meas2.DECLINATION}
Nr subbands{this.state.meas2.NR_SUBBANDS}
+
@@ -867,7 +973,7 @@ export default class FRBTable extends React.Component {
Select processing pipeline: { pipelineSelect } - { this.state.selectedPipeline && } + { this.state.selectedPipeline && } @@ -879,12 +985,33 @@ export default class FRBTable extends React.Component {
- + +
+ Choose Calibrator + this.handleSelect(row) + } /> +
+
+ Choose Target + this.handleSelect2(row) + } /> +
+
+ +
+

); } From 2b7bdfb5f01719649c88b76afe1ede908e36e63a Mon Sep 17 00:00:00 2001 From: Stefan Verhoeven Date: Wed, 22 Apr 2020 14:27:35 +0200 Subject: [PATCH 3/6] More mocks and use number of obs id --- server.js | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/server.js b/server.js index d3a6366..6efe86a 100644 --- a/server.js +++ b/server.js @@ -41,12 +41,24 @@ app.all('*', function (req, res, next) { // app.get('/product/:lid', products.findByProdId); app.get('/products', function(req,res) { const products = [{ - NR_SUBBANDS: 123, OBSERVATIONID: 'obsid1', LID: 'lid1', DECLINATION: 32.1, RIGHTASCENSION: 56.7, STARTTIME: new Date(2020,4,4), ENDTIME: new Date(2020,4,10) + NR_SUBBANDS: 123, OBSERVATIONID: 1, LID: 'lid1', DECLINATION: 32.1, RIGHTASCENSION: 56.7, STARTTIME: new Date(2020,4,4), ENDTIME: new Date(2020,4,10) }, { - NR_SUBBANDS: 123, OBSERVATIONID: 'obsid2', LID: 'lid2', DECLINATION: 32.1, RIGHTASCENSION: 56.7, STARTTIME: new Date(2020,4,4), ENDTIME: new Date(2020,4,10) + NR_SUBBANDS: 123, OBSERVATIONID: 2, LID: 'lid2', DECLINATION: 32.1, RIGHTASCENSION: 56.7, STARTTIME: new Date(2020,4,4), ENDTIME: new Date(2020,4,10) }, { - NR_SUBBANDS: 123, OBSERVATIONID: 'obsid3', LID: 'lid3', DECLINATION: 32.1, RIGHTASCENSION: 56.7, STARTTIME: new Date(2020,4,4), ENDTIME: new Date(2020,4,10) - }] + NR_SUBBANDS: 123, OBSERVATIONID: 3, LID: 'lid3', DECLINATION: 32.1, RIGHTASCENSION: 56.7, STARTTIME: new Date(2020,4,4), ENDTIME: new Date(2020,4,10) + }, { + NR_SUBBANDS: 123, OBSERVATIONID: 4, LID: 'lid4', DECLINATION: 32.1, RIGHTASCENSION: 56.7, STARTTIME: new Date(2020,4,4), ENDTIME: new Date(2020,4,10) + }, { + NR_SUBBANDS: 123, OBSERVATIONID: 5, LID: 'lid5', DECLINATION: 32.1, RIGHTASCENSION: 56.7, STARTTIME: new Date(2020,4,4), ENDTIME: new Date(2020,4,10) + }, { + NR_SUBBANDS: 123, OBSERVATIONID: 6, LID: 'lid6', DECLINATION: 32.1, RIGHTASCENSION: 56.7, STARTTIME: new Date(2020,4,4), ENDTIME: new Date(2020,4,10) + }, { + NR_SUBBANDS: 123, OBSERVATIONID: 7, LID: 'lid7', DECLINATION: 32.1, RIGHTASCENSION: 56.7, STARTTIME: new Date(2020,4,4), ENDTIME: new Date(2020,4,10) + }, { + NR_SUBBANDS: 123, OBSERVATIONID: 8, LID: 'lid8', DECLINATION: 32.1, RIGHTASCENSION: 56.7, STARTTIME: new Date(2020,4,4), ENDTIME: new Date(2020,4,10) + }, { + NR_SUBBANDS: 123, OBSERVATIONID: 9, LID: 'lid9', DECLINATION: 32.1, RIGHTASCENSION: 56.7, STARTTIME: new Date(2020,4,4), ENDTIME: new Date(2020,4,10) + }] res.json({products}); }); app.get('/product/:lid', function(res, req) { From c6c3d894bcadd3c3ea76ad7ed08c044689023f58 Mon Sep 17 00:00:00 2001 From: Stefan Verhoeven Date: Wed, 22 Apr 2020 14:31:21 +0200 Subject: [PATCH 4/6] Store selected LID as state in ProductList and pass to ProductTable --- app/components/ProductList/index.js | 24 +++++++++++++++++------- 1 file changed, 17 insertions(+), 7 deletions(-) diff --git a/app/components/ProductList/index.js b/app/components/ProductList/index.js index a591791..574e4ea 100644 --- a/app/components/ProductList/index.js +++ b/app/components/ProductList/index.js @@ -538,8 +538,12 @@ class ProductChooser extends React.Component { mode: 'radio', clickToSelect: true, hideSelectAll: true, - onSelect: this.props.onSelect + onSelect: this.props.onSelect, + selected: [] }; + if (this.props.selected !== undefined) { + selectRow.selected.push(this.props.selected); + } const pagination = paginationFactory({ page: 1, @@ -562,7 +566,9 @@ export default class FRBTable extends React.Component { super(props); this.state = { showModal: false, meas: {}, + meas_index: undefined, meas2: {}, + meas2_index: undefined, page: 1, sizePerPage: 25, // dropdown @@ -754,11 +760,11 @@ export default class FRBTable extends React.Component { handleSelect(row) { console.log('Table1 selected row: ') console.log(row) - this.setState({meas: row}); + this.setState({meas: row, meas_index: row.LID}); } handleSelect2(row) { - this.setState({meas2: row}); + this.setState({meas2: row, meas2_index: row.LID}); } render() { @@ -991,16 +997,20 @@ export default class FRBTable extends React.Component { this.handleSelect(row) - } /> + onSelect = { (row) => this.handleSelect(row) + } + selected = {this.state.meas_index} + />
Choose Target this.handleSelect2(row) - } /> + onSelect = { (row) => this.handleSelect2(row) + } + selected = {this.state.meas2_index} + />
\n *
\n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state and\n * stay there for 500ms (the value of `timeout`) when finally switches to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from `'exiting'` to `'exited'`.\n */\n\nvar Transition = function (_React$Component) {\n _inherits(Transition, _React$Component);\n\n function Transition(props, context) {\n _classCallCheck(this, Transition);\n\n var _this = _possibleConstructorReturn(this, _React$Component.call(this, props, context));\n\n var parentGroup = context.transitionGroup;\n // In the context of a TransitionGroup all enters are really appears\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n\n var initialStatus = void 0;\n _this.nextStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.nextStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = { status: initialStatus };\n\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.prototype.getChildContext = function getChildContext() {\n return { transitionGroup: null }; // allows for nested Transitions\n };\n\n Transition.prototype.componentDidMount = function componentDidMount() {\n this.updateStatus(true);\n };\n\n Transition.prototype.componentWillReceiveProps = function componentWillReceiveProps(nextProps) {\n var _ref = this.pendingState || this.state,\n status = _ref.status;\n\n if (nextProps.in) {\n if (status === UNMOUNTED) {\n this.setState({ status: EXITED });\n }\n if (status !== ENTERING && status !== ENTERED) {\n this.nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n this.nextStatus = EXITING;\n }\n }\n };\n\n Transition.prototype.componentDidUpdate = function componentDidUpdate() {\n this.updateStatus();\n };\n\n Transition.prototype.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n Transition.prototype.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n\n var exit = void 0,\n enter = void 0,\n appear = void 0;\n\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter;\n appear = timeout.appear;\n }\n return { exit: exit, enter: enter, appear: appear };\n };\n\n Transition.prototype.updateStatus = function updateStatus() {\n var mounting = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;\n\n var nextStatus = this.nextStatus;\n\n if (nextStatus !== null) {\n this.nextStatus = null;\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n var node = _reactDom2.default.findDOMNode(this);\n\n if (nextStatus === ENTERING) {\n this.performEnter(node, mounting);\n } else {\n this.performExit(node);\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({ status: UNMOUNTED });\n }\n };\n\n Transition.prototype.performEnter = function performEnter(node, mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n\n var appearing = this.context.transitionGroup ? this.context.transitionGroup.isMounting : mounting;\n\n var timeouts = this.getTimeouts();\n\n // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n if (!mounting && !enter) {\n this.safeSetState({ status: ENTERED }, function () {\n _this2.props.onEntered(node);\n });\n return;\n }\n\n this.props.onEnter(node, appearing);\n\n this.safeSetState({ status: ENTERING }, function () {\n _this2.props.onEntering(node, appearing);\n\n // FIXME: appear timeout?\n _this2.onTransitionEnd(node, timeouts.enter, function () {\n _this2.safeSetState({ status: ENTERED }, function () {\n _this2.props.onEntered(node, appearing);\n });\n });\n });\n };\n\n Transition.prototype.performExit = function performExit(node) {\n var _this3 = this;\n\n var exit = this.props.exit;\n\n var timeouts = this.getTimeouts();\n\n // no exit animation skip right to EXITED\n if (!exit) {\n this.safeSetState({ status: EXITED }, function () {\n _this3.props.onExited(node);\n });\n return;\n }\n this.props.onExit(node);\n\n this.safeSetState({ status: EXITING }, function () {\n _this3.props.onExiting(node);\n\n _this3.onTransitionEnd(node, timeouts.exit, function () {\n _this3.safeSetState({ status: EXITED }, function () {\n _this3.props.onExited(node);\n });\n });\n });\n };\n\n Transition.prototype.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n Transition.prototype.safeSetState = function safeSetState(nextState, callback) {\n var _this4 = this;\n\n // We need to track pending updates for instances where a cWRP fires quickly\n // after cDM and before the state flushes, which would double trigger a\n // transition\n this.pendingState = nextState;\n\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, function () {\n _this4.pendingState = null;\n callback();\n });\n };\n\n Transition.prototype.setNextCallback = function setNextCallback(callback) {\n var _this5 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this5.nextCallback = null;\n\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n Transition.prototype.onTransitionEnd = function onTransitionEnd(node, timeout, handler) {\n this.setNextCallback(handler);\n\n if (node) {\n if (this.props.addEndListener) {\n this.props.addEndListener(node, this.nextCallback);\n }\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n } else {\n setTimeout(this.nextCallback, 0);\n }\n };\n\n Transition.prototype.render = function render() {\n var status = this.state.status;\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _props = this.props,\n children = _props.children,\n childProps = _objectWithoutProperties(_props, ['children']);\n // filter props for Transtition\n\n\n delete childProps.in;\n delete childProps.mountOnEnter;\n delete childProps.unmountOnExit;\n delete childProps.appear;\n delete childProps.enter;\n delete childProps.exit;\n delete childProps.timeout;\n delete childProps.addEndListener;\n delete childProps.onEnter;\n delete childProps.onEntering;\n delete childProps.onEntered;\n delete childProps.onExit;\n delete childProps.onExiting;\n delete childProps.onExited;\n\n if (typeof children === 'function') {\n return children(status, childProps);\n }\n\n var child = _react2.default.Children.only(children);\n return _react2.default.cloneElement(child, childProps);\n };\n\n return Transition;\n}(_react2.default.Component);\n\nTransition.contextTypes = {\n transitionGroup: PropTypes.object\n};\nTransition.childContextTypes = {\n transitionGroup: function transitionGroup() {}\n};\n\n\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A `function` child can be used instead of a React element.\n * This function is called with the current transition status\n * ('entering', 'entered', 'exiting', 'exited', 'unmounted'), which can used\n * to apply context specific props to a component.\n *\n * ```jsx\n * \n * {(status) => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * Normally a component is not transitioned if it is shown when the `` component mounts.\n * If you want to transition on the first mount set `appear` to `true`, and the\n * component will transition in as soon as the `` mounts.\n *\n * > Note: there are no specific \"appear\" states. `appear` only adds an additional `enter` transition.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEventListener` is provided\n *\n * You may specify a single timeout for all transitions like: `timeout={500}`,\n * or individually like:\n *\n * ```jsx\n * timeout={{\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * @type {number | { enter?: number, exit?: number }}\n */\n timeout: function timeout(props) {\n for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n var pt = _PropTypes.timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n return pt.apply(undefined, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. **Note:** Timeouts are still used as a fallback if provided.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {};\n\n// Name the function so it is clearer in the documentation\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\n\nTransition.UNMOUNTED = 0;\nTransition.EXITED = 1;\nTransition.ENTERING = 2;\nTransition.ENTERED = 3;\nTransition.EXITING = 4;\n\nexports.default = Transition;","export default function capitalize(string) {\n return \"\" + string.charAt(0).toUpperCase() + string.slice(1);\n}","'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = camelizeStyleName;\n\nvar _camelize = require('./camelize');\n\nvar _camelize2 = _interopRequireDefault(_camelize);\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nvar msPattern = /^-ms-/; /**\n * Copyright 2014-2015, Facebook, Inc.\n * All rights reserved.\n * https://github.com/facebook/react/blob/2aeb8a2a6beb00617a4217f7f8284924fa2ad819/src/vendor/core/camelizeStyleName.js\n */\nfunction camelizeStyleName(string) {\n return (0, _camelize2.default)(string.replace(msPattern, 'ms-'));\n}\nmodule.exports = exports['default'];","import _extends from 'babel-runtime/helpers/extends';\nimport _objectWithoutProperties from 'babel-runtime/helpers/objectWithoutProperties';\nimport _classCallCheck from 'babel-runtime/helpers/classCallCheck';\nimport _possibleConstructorReturn from 'babel-runtime/helpers/possibleConstructorReturn';\nimport _inherits from 'babel-runtime/helpers/inherits';\nimport classNames from 'classnames';\nimport React from 'react';\nimport PropTypes from 'prop-types';\nimport ReactDOM from 'react-dom';\nimport transition from 'dom-helpers/transition';\n\nvar propTypes = {\n direction: PropTypes.oneOf(['prev', 'next']),\n onAnimateOutEnd: PropTypes.func,\n active: PropTypes.bool,\n animateIn: PropTypes.bool,\n animateOut: PropTypes.bool,\n index: PropTypes.number\n};\n\nvar defaultProps = {\n active: false,\n animateIn: false,\n animateOut: false\n};\n\nvar CarouselItem = function (_React$Component) {\n _inherits(CarouselItem, _React$Component);\n\n function CarouselItem(props, context) {\n _classCallCheck(this, CarouselItem);\n\n var _this = _possibleConstructorReturn(this, _React$Component.call(this, props, context));\n\n _this.handleAnimateOutEnd = _this.handleAnimateOutEnd.bind(_this);\n\n _this.state = {\n direction: null\n };\n\n _this.isUnmounted = false;\n return _this;\n }\n\n CarouselItem.prototype.componentWillReceiveProps = function componentWillReceiveProps(nextProps) {\n if (this.props.active !== nextProps.active) {\n this.setState({ direction: null });\n }\n };\n\n CarouselItem.prototype.componentDidUpdate = function componentDidUpdate(prevProps) {\n var _this2 = this;\n\n var active = this.props.active;\n\n var prevActive = prevProps.active;\n\n if (!active && prevActive) {\n transition.end(ReactDOM.findDOMNode(this), this.handleAnimateOutEnd);\n }\n\n if (active !== prevActive) {\n setTimeout(function () {\n return _this2.startAnimation();\n }, 20);\n }\n };\n\n CarouselItem.prototype.componentWillUnmount = function componentWillUnmount() {\n this.isUnmounted = true;\n };\n\n CarouselItem.prototype.handleAnimateOutEnd = function handleAnimateOutEnd() {\n if (this.isUnmounted) {\n return;\n }\n\n if (this.props.onAnimateOutEnd) {\n this.props.onAnimateOutEnd(this.props.index);\n }\n };\n\n CarouselItem.prototype.startAnimation = function startAnimation() {\n if (this.isUnmounted) {\n return;\n }\n\n this.setState({\n direction: this.props.direction === 'prev' ? 'right' : 'left'\n });\n };\n\n CarouselItem.prototype.render = function render() {\n var _props = this.props,\n direction = _props.direction,\n active = _props.active,\n animateIn = _props.animateIn,\n animateOut = _props.animateOut,\n className = _props.className,\n props = _objectWithoutProperties(_props, ['direction', 'active', 'animateIn', 'animateOut', 'className']);\n\n delete props.onAnimateOutEnd;\n delete props.index;\n\n var classes = {\n item: true,\n active: active && !animateIn || animateOut\n };\n if (direction && active && animateIn) {\n classes[direction] = true;\n }\n if (this.state.direction && (animateIn || animateOut)) {\n classes[this.state.direction] = true;\n }\n\n return React.createElement('div', _extends({}, props, { className: classNames(className, classes) }));\n };\n\n return CarouselItem;\n}(React.Component);\n\nCarouselItem.propTypes = propTypes;\nCarouselItem.defaultProps = defaultProps;\n\nexport default CarouselItem;","import _extends from 'babel-runtime/helpers/extends';\nimport _objectWithoutProperties from 'babel-runtime/helpers/objectWithoutProperties';\nimport _classCallCheck from 'babel-runtime/helpers/classCallCheck';\nimport _possibleConstructorReturn from 'babel-runtime/helpers/possibleConstructorReturn';\nimport _inherits from 'babel-runtime/helpers/inherits';\nimport classNames from 'classnames';\nimport React from 'react';\nimport PropTypes from 'prop-types';\n\nimport SafeAnchor from './SafeAnchor';\n\nvar propTypes = {\n /**\n * If set to true, renders `span` instead of `a`\n */\n active: PropTypes.bool,\n /**\n * `href` attribute for the inner `a` element\n */\n href: PropTypes.string,\n /**\n * `title` attribute for the inner `a` element\n */\n title: PropTypes.node,\n /**\n * `target` attribute for the inner `a` element\n */\n target: PropTypes.string\n};\n\nvar defaultProps = {\n active: false\n};\n\nvar BreadcrumbItem = function (_React$Component) {\n _inherits(BreadcrumbItem, _React$Component);\n\n function BreadcrumbItem() {\n _classCallCheck(this, BreadcrumbItem);\n\n return _possibleConstructorReturn(this, _React$Component.apply(this, arguments));\n }\n\n BreadcrumbItem.prototype.render = function render() {\n var _props = this.props,\n active = _props.active,\n href = _props.href,\n title = _props.title,\n target = _props.target,\n className = _props.className,\n props = _objectWithoutProperties(_props, ['active', 'href', 'title', 'target', 'className']);\n\n // Don't try to render these props on non-active .\n\n\n var linkProps = { href: href, title: title, target: target };\n\n return React.createElement(\n 'li',\n { className: classNames(className, { active: active }) },\n active ? React.createElement('span', props) : React.createElement(SafeAnchor, _extends({}, props, linkProps))\n );\n };\n\n return BreadcrumbItem;\n}(React.Component);\n\nBreadcrumbItem.propTypes = propTypes;\nBreadcrumbItem.defaultProps = defaultProps;\n\nexport default BreadcrumbItem;","import PropTypes from 'prop-types';\nimport createChainableTypeChecker from 'prop-types-extra/lib/utils/createChainableTypeChecker';\n\nimport ValidComponentChildren from './ValidComponentChildren';\n\nvar idPropType = PropTypes.oneOfType([PropTypes.string, PropTypes.number]);\n\nexport function generatedId(name) {\n return function (props) {\n for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n var error = null;\n\n if (!props.generateChildId) {\n error = idPropType.apply(undefined, [props].concat(args));\n\n if (!error && !props.id) {\n error = new Error('In order to properly initialize the ' + name + ' in a way that is accessible to assistive technologies ' + ('(such as screen readers) an `id` or a `generateChildId` prop to ' + name + ' is required'));\n }\n }\n return error;\n };\n}\n\nexport function requiredRoles() {\n for (var _len2 = arguments.length, roles = Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {\n roles[_key2] = arguments[_key2];\n }\n\n return createChainableTypeChecker(function (props, propName, component) {\n var missing = void 0;\n\n roles.every(function (role) {\n if (!ValidComponentChildren.some(props.children, function (child) {\n return child.props.bsRole === role;\n })) {\n missing = role;\n return false;\n }\n\n return true;\n });\n\n if (missing) {\n return new Error('(children) ' + component + ' - Missing a required child with bsRole: ' + (missing + '. ' + component + ' must have at least one child of each of ') + ('the following bsRoles: ' + roles.join(', ')));\n }\n\n return null;\n });\n}\n\nexport function exclusiveRoles() {\n for (var _len3 = arguments.length, roles = Array(_len3), _key3 = 0; _key3 < _len3; _key3++) {\n roles[_key3] = arguments[_key3];\n }\n\n return createChainableTypeChecker(function (props, propName, component) {\n var duplicate = void 0;\n\n roles.every(function (role) {\n var childrenWithRole = ValidComponentChildren.filter(props.children, function (child) {\n return child.props.bsRole === role;\n });\n\n if (childrenWithRole.length > 1) {\n duplicate = role;\n return false;\n }\n\n return true;\n });\n\n if (duplicate) {\n return new Error('(children) ' + component + ' - Duplicate children detected of bsRole: ' + (duplicate + '. Only one child each allowed with the following ') + ('bsRoles: ' + roles.join(', ')));\n }\n\n return null;\n });\n}","var getKeys = require('./_object-keys');\nvar toIObject = require('./_to-iobject');\nvar isEnum = require('./_object-pie').f;\nmodule.exports = function (isEntries) {\n return function (it) {\n var O = toIObject(it);\n var keys = getKeys(O);\n var length = keys.length;\n var i = 0;\n var result = [];\n var key;\n while (length > i) if (isEnum.call(O, key = keys[i++])) {\n result.push(isEntries ? [key, O[key]] : O[key]);\n } return result;\n };\n};\n","module.exports = { \"default\": require(\"core-js/library/fn/object/entries\"), __esModule: true };","/* globals __webpack_amd_options__ */\r\nmodule.exports = __webpack_amd_options__;\r\n","import _objectWithoutProperties from 'babel-runtime/helpers/objectWithoutProperties';\nimport _extends from 'babel-runtime/helpers/extends';\nimport _classCallCheck from 'babel-runtime/helpers/classCallCheck';\nimport _possibleConstructorReturn from 'babel-runtime/helpers/possibleConstructorReturn';\nimport _inherits from 'babel-runtime/helpers/inherits';\nimport classNames from 'classnames';\nimport PropTypes from 'prop-types';\nimport React, { cloneElement } from 'react';\nimport uncontrollable from 'uncontrollable';\n\nimport { bsClass, getClassSet, splitBsPropsAndOmit } from './utils/bootstrapUtils';\nimport ValidComponentChildren from './utils/ValidComponentChildren';\nimport { generatedId } from './utils/PropTypes';\n\nvar propTypes = {\n accordion: PropTypes.bool,\n /**\n * When `accordion` is enabled, `activeKey` controls the which child `Panel` is expanded. `activeKey` should\n * match a child Panel `eventKey` prop exactly.\n *\n * @controllable onSelect\n */\n activeKey: PropTypes.any,\n\n /**\n * A callback fired when a child Panel collapse state changes. It's called with the next expanded `activeKey`\n *\n * @controllable activeKey\n */\n onSelect: PropTypes.func,\n\n /**\n * An HTML role attribute\n */\n role: PropTypes.string,\n\n /**\n * A function that takes an eventKey and type and returns a\n * unique id for each Panel heading and Panel Collapse. The function _must_ be a pure function,\n * meaning it should always return the _same_ id for the same set of inputs. The default\n * value requires that an `id` to be set for the PanelGroup.\n *\n * The `type` argument will either be `\"body\"` or `\"heading\"`.\n *\n * @defaultValue (eventKey, type) => `${this.props.id}-${type}-${key}`\n */\n generateChildId: PropTypes.func,\n\n /**\n * HTML id attribute, required if no `generateChildId` prop\n * is specified.\n */\n id: generatedId('PanelGroup')\n};\n\nvar defaultProps = {\n accordion: false\n};\n\nvar childContextTypes = {\n $bs_panelGroup: PropTypes.shape({\n getId: PropTypes.func,\n headerRole: PropTypes.string,\n panelRole: PropTypes.string,\n activeKey: PropTypes.any,\n onToggle: PropTypes.func\n })\n};\n\nvar PanelGroup = function (_React$Component) {\n _inherits(PanelGroup, _React$Component);\n\n function PanelGroup() {\n var _temp, _this, _ret;\n\n _classCallCheck(this, PanelGroup);\n\n for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return _ret = (_temp = (_this = _possibleConstructorReturn(this, _React$Component.call.apply(_React$Component, [this].concat(args))), _this), _this.handleSelect = function (key, expanded, e) {\n if (expanded) {\n _this.props.onSelect(key, e);\n } else if (_this.props.activeKey === key) {\n _this.props.onSelect(null, e);\n }\n }, _temp), _possibleConstructorReturn(_this, _ret);\n }\n\n PanelGroup.prototype.getChildContext = function getChildContext() {\n var _props = this.props,\n activeKey = _props.activeKey,\n accordion = _props.accordion,\n generateChildId = _props.generateChildId,\n id = _props.id;\n\n var getId = null;\n\n if (accordion) {\n getId = generateChildId || function (key, type) {\n return id ? id + '-' + type + '-' + key : null;\n };\n }\n\n return {\n $bs_panelGroup: _extends({\n getId: getId,\n headerRole: 'tab',\n panelRole: 'tabpanel'\n }, accordion && {\n activeKey: activeKey,\n onToggle: this.handleSelect\n })\n };\n };\n\n PanelGroup.prototype.render = function render() {\n var _props2 = this.props,\n accordion = _props2.accordion,\n className = _props2.className,\n children = _props2.children,\n props = _objectWithoutProperties(_props2, ['accordion', 'className', 'children']);\n\n var _splitBsPropsAndOmit = splitBsPropsAndOmit(props, ['onSelect', 'activeKey']),\n bsProps = _splitBsPropsAndOmit[0],\n elementProps = _splitBsPropsAndOmit[1];\n\n if (accordion) {\n elementProps.role = elementProps.role || 'tablist';\n }\n\n var classes = getClassSet(bsProps);\n\n return React.createElement(\n 'div',\n _extends({}, elementProps, { className: classNames(className, classes) }),\n ValidComponentChildren.map(children, function (child) {\n return cloneElement(child, {\n bsStyle: child.props.bsStyle || bsProps.bsStyle\n });\n })\n );\n };\n\n return PanelGroup;\n}(React.Component);\n\nPanelGroup.propTypes = propTypes;\nPanelGroup.defaultProps = defaultProps;\nPanelGroup.childContextTypes = childContextTypes;\n\nexport default uncontrollable(bsClass('panel-group', PanelGroup), {\n activeKey: 'onSelect'\n});","var pIE = require('./_object-pie');\nvar createDesc = require('./_property-desc');\nvar toIObject = require('./_to-iobject');\nvar toPrimitive = require('./_to-primitive');\nvar has = require('./_has');\nvar IE8_DOM_DEFINE = require('./_ie8-dom-define');\nvar gOPD = Object.getOwnPropertyDescriptor;\n\nexports.f = require('./_descriptors') ? gOPD : function getOwnPropertyDescriptor(O, P) {\n O = toIObject(O);\n P = toPrimitive(P, true);\n if (IE8_DOM_DEFINE) try {\n return gOPD(O, P);\n } catch (e) { /* empty */ }\n if (has(O, P)) return createDesc(!pIE.f.call(O, P), O[P]);\n};\n","// 19.1.2.7 / 15.2.3.4 Object.getOwnPropertyNames(O)\nvar $keys = require('./_object-keys-internal');\nvar hiddenKeys = require('./_enum-bug-keys').concat('length', 'prototype');\n\nexports.f = Object.getOwnPropertyNames || function getOwnPropertyNames(O) {\n return $keys(O, hiddenKeys);\n};\n","module.exports = require('./_hide');\n","'use strict';\nvar LIBRARY = require('./_library');\nvar $export = require('./_export');\nvar redefine = require('./_redefine');\nvar hide = require('./_hide');\nvar has = require('./_has');\nvar Iterators = require('./_iterators');\nvar $iterCreate = require('./_iter-create');\nvar setToStringTag = require('./_set-to-string-tag');\nvar getPrototypeOf = require('./_object-gpo');\nvar ITERATOR = require('./_wks')('iterator');\nvar BUGGY = !([].keys && 'next' in [].keys()); // Safari has buggy iterators w/o `next`\nvar FF_ITERATOR = '@@iterator';\nvar KEYS = 'keys';\nvar VALUES = 'values';\n\nvar returnThis = function () { return this; };\n\nmodule.exports = function (Base, NAME, Constructor, next, DEFAULT, IS_SET, FORCED) {\n $iterCreate(Constructor, NAME, next);\n var getMethod = function (kind) {\n if (!BUGGY && kind in proto) return proto[kind];\n switch (kind) {\n case KEYS: return function keys() { return new Constructor(this, kind); };\n case VALUES: return function values() { return new Constructor(this, kind); };\n } return function entries() { return new Constructor(this, kind); };\n };\n var TAG = NAME + ' Iterator';\n var DEF_VALUES = DEFAULT == VALUES;\n var VALUES_BUG = false;\n var proto = Base.prototype;\n var $native = proto[ITERATOR] || proto[FF_ITERATOR] || DEFAULT && proto[DEFAULT];\n var $default = (!BUGGY && $native) || getMethod(DEFAULT);\n var $entries = DEFAULT ? !DEF_VALUES ? $default : getMethod('entries') : undefined;\n var $anyNative = NAME == 'Array' ? proto.entries || $native : $native;\n var methods, key, IteratorPrototype;\n // Fix native\n if ($anyNative) {\n IteratorPrototype = getPrototypeOf($anyNative.call(new Base()));\n if (IteratorPrototype !== Object.prototype && IteratorPrototype.next) {\n // Set @@toStringTag to native iterators\n setToStringTag(IteratorPrototype, TAG, true);\n // fix for some old engines\n if (!LIBRARY && !has(IteratorPrototype, ITERATOR)) hide(IteratorPrototype, ITERATOR, returnThis);\n }\n }\n // fix Array#{values, @@iterator}.name in V8 / FF\n if (DEF_VALUES && $native && $native.name !== VALUES) {\n VALUES_BUG = true;\n $default = function values() { return $native.call(this); };\n }\n // Define iterator\n if ((!LIBRARY || FORCED) && (BUGGY || VALUES_BUG || !proto[ITERATOR])) {\n hide(proto, ITERATOR, $default);\n }\n // Plug for library\n Iterators[NAME] = $default;\n Iterators[TAG] = returnThis;\n if (DEFAULT) {\n methods = {\n values: DEF_VALUES ? $default : getMethod(VALUES),\n keys: IS_SET ? $default : getMethod(KEYS),\n entries: $entries\n };\n if (FORCED) for (key in methods) {\n if (!(key in proto)) redefine(proto, key, methods[key]);\n } else $export($export.P + $export.F * (BUGGY || VALUES_BUG), NAME, methods);\n }\n return methods;\n};\n","'use strict';\nvar $at = require('./_string-at')(true);\n\n// 21.1.3.27 String.prototype[@@iterator]()\nrequire('./_iter-define')(String, 'String', function (iterated) {\n this._t = String(iterated); // target\n this._i = 0; // next index\n// 21.1.5.2.1 %StringIteratorPrototype%.next()\n}, function () {\n var O = this._t;\n var index = this._i;\n var point;\n if (index >= O.length) return { value: undefined, done: true };\n point = $at(O, index);\n this._i += point.length;\n return { value: point, done: false };\n});\n","// 7.1.15 ToLength\nvar toInteger = require('./_to-integer');\nvar min = Math.min;\nmodule.exports = function (it) {\n return it > 0 ? min(toInteger(it), 0x1fffffffffffff) : 0; // pow(2, 53) - 1 == 9007199254740991\n};\n","// fallback for non-array-like ES3 and non-enumerable old V8 strings\nvar cof = require('./_cof');\n// eslint-disable-next-line no-prototype-builtins\nmodule.exports = Object('z').propertyIsEnumerable(0) ? Object : function (it) {\n return cof(it) == 'String' ? it.split('') : Object(it);\n};\n","var has = require('./_has');\nvar toIObject = require('./_to-iobject');\nvar arrayIndexOf = require('./_array-includes')(false);\nvar IE_PROTO = require('./_shared-key')('IE_PROTO');\n\nmodule.exports = function (object, names) {\n var O = toIObject(object);\n var i = 0;\n var result = [];\n var key;\n for (key in O) if (key != IE_PROTO) has(O, key) && result.push(key);\n // Don't enum bug & hidden keys\n while (names.length > i) if (has(O, key = names[i++])) {\n ~arrayIndexOf(result, key) || result.push(key);\n }\n return result;\n};\n","var isObject = require('./_is-object');\nvar document = require('./_global').document;\n// typeof document.createElement is 'object' in old IE\nvar is = isObject(document) && isObject(document.createElement);\nmodule.exports = function (it) {\n return is ? document.createElement(it) : {};\n};\n","module.exports = !require('./_descriptors') && !require('./_fails')(function () {\n return Object.defineProperty(require('./_dom-create')('div'), 'a', { get: function () { return 7; } }).a != 7;\n});\n","module.exports = { \"default\": require(\"core-js/library/fn/object/assign\"), __esModule: true };","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n */\n\n'use strict';\n\nvar emptyObject = {};\n\nif (process.env.NODE_ENV !== 'production') {\n Object.freeze(emptyObject);\n}\n\nmodule.exports = emptyObject;","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","import * as tslib_1 from \"tslib\";\nimport * as React from 'react';\nimport * as common from 'file-uploader-component';\nexport * from 'file-uploader-component';\n/**\n * @public\n */\nvar FileUploader = /** @class */ (function (_super) {\n tslib_1.__extends(FileUploader, _super);\n function FileUploader() {\n var _this = _super !== null && _super.apply(this, arguments) || this;\n _this.requests = [];\n return _this;\n }\n FileUploader.prototype.render = function () {\n var _this = this;\n var locale = common.getLocale(this.props.locale);\n var progress = this.requests.map(function (request, i) { return (React.createElement(\"div\", { className: 'file-uploader-progress', title: request.file.name, key: i },\n React.createElement(\"div\", { style: { width: request.percent + '%' } },\n request.percent,\n \"%\"))); });\n return (React.createElement(\"div\", { onDrop: function (e) { _this.onDrop(e); }, onPaste: function (e) { _this.onPaste(e); } },\n progress,\n React.createElement(\"p\", { className: 'file-uploader-container' },\n locale.dragAndDrop,\n React.createElement(\"span\", null, locale.selectFile),\n locale.pasteFromClipboard,\n React.createElement(\"input\", { type: 'file', multiple: this.props.multiple, accept: this.props.accept, onChange: function (e) { _this.onFileUploaded(e); } }))));\n };\n FileUploader.prototype.onDrop = function (e) {\n var _this = this;\n common.onDrop(e, this.props.name, this.props.url, this.props.method, function (file) {\n if (_this.props.fileGot) {\n _this.props.fileGot(file);\n }\n }, function (request) {\n if (_this.props.fileUploaded) {\n _this.props.fileUploaded(request.response);\n }\n common.removeRequest(_this.requests, request);\n _this.setState({ requests: _this.requests });\n }, function (percent) {\n _this.setState({ requests: _this.requests });\n }, function (request) {\n _this.requests.push(request);\n });\n };\n FileUploader.prototype.onPaste = function (e) {\n var _this = this;\n common.onPaste(e, this.props.name, this.props.url, this.props.method, function (file) {\n if (_this.props.fileGot) {\n _this.props.fileGot(file);\n }\n }, function (request) {\n if (_this.props.fileUploaded) {\n _this.props.fileUploaded(request.response);\n }\n common.removeRequest(_this.requests, request);\n _this.setState({ requests: _this.requests });\n }, function (percent) {\n _this.setState({ requests: _this.requests });\n }, function (request) {\n _this.requests.push(request);\n });\n };\n FileUploader.prototype.onFileUploaded = function (e) {\n var _this = this;\n common.onFileUploaded(e, this.props.name, this.props.url, this.props.method, function (file) {\n if (_this.props.fileGot) {\n _this.props.fileGot(file);\n }\n }, function (request) {\n if (_this.props.fileUploaded) {\n _this.props.fileUploaded(request.response);\n }\n common.removeRequest(_this.requests, request);\n _this.setState({ requests: _this.requests });\n }, function (percent) {\n _this.setState({ requests: _this.requests });\n }, function (request) {\n _this.requests.push(request);\n });\n };\n return FileUploader;\n}(React.Component));\nexport { FileUploader };\n","import * as tslib_1 from \"tslib\";\nimport * as React from 'react';\nimport * as common from 'markdown-tip';\nexport * from 'markdown-tip';\n/**\n * @public\n */\nvar MarkdownTip = /** @class */ (function (_super) {\n tslib_1.__extends(MarkdownTip, _super);\n function MarkdownTip() {\n var _this = _super !== null && _super.apply(this, arguments) || this;\n _this.visibleText = null;\n _this.titleClass = common.defaultTitleClass;\n return _this;\n }\n MarkdownTip.prototype.render = function () {\n var _this = this;\n var datas = common.getLocale(this.props.locale);\n var items = datas.map(function (data, i) {\n var title = data.text === _this.visibleText ? React.createElement(\"pre\", { className: _this.titleClass }, data.title) : null;\n return (React.createElement(\"div\", { className: 'markdown-tip-item', key: i, onMouseEnter: function (e) { return _this.mouseenter(data, e); }, onMouseLeave: function (e) { return _this.mouseleave(data); } },\n React.createElement(\"span\", { className: 'markdown-tip-item-text' }, data.text),\n title));\n });\n return (React.createElement(\"div\", { className: 'markdown-tip' }, items));\n };\n MarkdownTip.prototype.mouseenter = function (data, event) {\n this.visibleText = data.text;\n this.titleClass = common.getTitleClass(event.target);\n this.setState({ visibleText: this.visibleText, titleClass: this.titleClass });\n };\n MarkdownTip.prototype.mouseleave = function (data) {\n this.visibleText = null;\n this.setState({ visibleText: this.visibleText });\n };\n return MarkdownTip;\n}(React.PureComponent));\nexport { MarkdownTip };\n","import * as tslib_1 from \"tslib\";\nimport * as React from 'react';\nimport * as common from 'schema-based-json-editor';\nimport { Icon } from './icon';\nimport { Optional } from './optional';\nimport { Description } from './description';\nimport { MarkdownTip } from 'markdown-tip-react';\nimport { Select2 } from 'select2-react-component';\nimport { FileUploader } from 'file-uploader-react-component';\nvar StringEditor = /** @class */ (function (_super) {\n tslib_1.__extends(StringEditor, _super);\n function StringEditor(props) {\n var _this = _super.call(this, props) || this;\n _this.collapsed = false;\n _this.willRender = false;\n _this.onChange = function (e) {\n _this.value = e.currentTarget.value;\n _this.validate();\n _this.setState({ value: _this.value });\n _this.props.updateValue(_this.value, !_this.errorMessage);\n };\n _this.toggleOptional = function () {\n _this.value = common.toggleOptional(_this.value, _this.props.schema, _this.props.initialValue);\n _this.validate();\n _this.willRender = true;\n _this.setState({ value: _this.value });\n _this.props.updateValue(_this.value, !_this.errorMessage);\n };\n _this.collapseOrExpand = function () {\n _this.willRender = true;\n _this.collapsed = !_this.collapsed;\n _this.setState({ collapsed: _this.collapsed });\n };\n _this.value = common.getDefaultValue(_this.props.required, _this.props.schema, _this.props.initialValue);\n _this.validate();\n return _this;\n }\n StringEditor.prototype.componentDidMount = function () {\n this.props.updateValue(this.value, !this.errorMessage);\n };\n StringEditor.prototype.shouldComponentUpdate = function (nextProps, nextState) {\n if (this.willRender) {\n this.willRender = false;\n return true;\n }\n return this.props.initialValue !== nextProps.initialValue;\n };\n // tslint:disable-next-line:cognitive-complexity\n StringEditor.prototype.render = function () {\n var _this = this;\n var fileUploader = this.canUpload ? (React.createElement(FileUploader, { locale: this.props.locale.fileUploaderLocale, fileGot: function (e) { return _this.fileGot(e); } })) : null;\n var textarea = this.useTextArea ? (React.createElement(\"textarea\", { className: this.errorMessage ? this.props.theme.errorTextarea : this.props.theme.textarea, onChange: this.onChange, defaultValue: this.value, rows: 10, readOnly: this.isReadOnly, disabled: this.isReadOnly })) : null;\n var input = this.useInput ? (React.createElement(\"input\", { className: this.errorMessage ? this.props.theme.errorInput : this.props.theme.input, type: this.props.schema.format, onChange: this.onChange, defaultValue: this.value, readOnly: this.isReadOnly, disabled: this.isReadOnly })) : null;\n var select = null;\n if (this.useSelect) {\n if (this.useSelectComponent) {\n var options = this.options.map(function (op) { return React.createElement(\"option\", { key: op.value, value: op.value }, op.label); });\n select = React.createElement(\"select\", { value: this.value, className: this.props.theme.select, disabled: this.isReadOnly, onChange: function (e) { return _this.updateSelection(e.target.value); } }, options);\n }\n else if (this.useSelect2Component) {\n select = React.createElement(Select2, { data: this.options, value: this.value, disabled: this.isReadOnly, update: function (e) { return _this.updateSelection(e); } });\n }\n else if (this.useRadioBoxComponent) {\n var options = this.options.map(function (option) { return React.createElement(\"span\", { key: option.value, className: _this.props.theme.radiobox },\n React.createElement(\"label\", null,\n React.createElement(\"input\", { type: 'radio', onChange: function () { return _this.updateSelection(option.value); }, checked: _this.value === option.value, disabled: _this.isReadOnly }),\n option.label)); });\n select = React.createElement(\"div\", null, options);\n }\n }\n var imagePreview = this.willPreviewImage ? React.createElement(\"img\", { style: common.imagePreviewStyle, src: this.getImageUrl }) : null;\n var markdownTip = this.useTextArea && this.willPreviewMarkdown ? React.createElement(MarkdownTip, { locale: this.props.locale.markdownTipLocale }) : null;\n var markdownPreview = this.willPreviewMarkdown ? React.createElement(\"div\", { dangerouslySetInnerHTML: { __html: this.getMarkdown } }) : null;\n var codePreview = this.willPreviewCode ? React.createElement(\"pre\", null,\n React.createElement(\"code\", { dangerouslySetInnerHTML: { __html: this.getCode } })) : null;\n return (React.createElement(\"div\", { className: this.className },\n React.createElement(\"label\", { className: this.props.theme.title },\n this.titleToShow,\n React.createElement(\"div\", { className: this.props.theme.buttonGroup, style: common.buttonGroupStyle },\n React.createElement(Optional, { required: this.props.required, value: this.value, isReadOnly: this.isReadOnly, theme: this.props.theme, locale: this.props.locale, toggleOptional: this.toggleOptional }),\n React.createElement(Icon, { valid: this.hasDeleteButtonFunction, onClick: this.props.onDelete, text: this.props.icon.delete, theme: this.props.theme, icon: this.props.icon }),\n React.createElement(Icon, { valid: this.canPreview, onClick: this.collapseOrExpand, text: this.collapsed ? this.props.icon.expand : this.props.icon.collapse, theme: this.props.theme, icon: this.props.icon }))),\n fileUploader,\n textarea,\n input,\n select,\n imagePreview,\n markdownTip,\n markdownPreview,\n codePreview,\n React.createElement(Description, { theme: this.props.theme, message: this.props.schema.description }),\n React.createElement(Description, { theme: this.props.theme, message: this.errorMessage })));\n };\n Object.defineProperty(StringEditor.prototype, \"isReadOnly\", {\n get: function () {\n return this.props.readonly || this.props.schema.readonly;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(StringEditor.prototype, \"hasDeleteButtonFunction\", {\n get: function () {\n return this.props.onDelete && !this.isReadOnly;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(StringEditor.prototype, \"useTextArea\", {\n get: function () {\n return this.value !== undefined\n && !this.collapsed\n && (this.props.schema.enum === undefined || this.isReadOnly)\n && (this.props.schema.format === 'textarea' || this.props.schema.format === 'code' || this.props.schema.format === 'markdown');\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(StringEditor.prototype, \"useInput\", {\n get: function () {\n return this.value !== undefined\n && !this.collapsed\n && (this.props.schema.enum === undefined || this.isReadOnly)\n && (this.props.schema.format !== 'textarea' && this.props.schema.format !== 'code' && this.props.schema.format !== 'markdown');\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(StringEditor.prototype, \"useSelect\", {\n get: function () {\n return this.value !== undefined && this.props.schema.enum !== undefined && !this.isReadOnly;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(StringEditor.prototype, \"useSelect2Component\", {\n get: function () {\n return this.useSelect && !this.props.noSelect2 && this.props.schema.format !== 'select' && this.props.schema.format !== 'radiobox';\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(StringEditor.prototype, \"useSelectComponent\", {\n get: function () {\n return this.useSelect && (this.props.schema.format === 'select' || this.props.noSelect2);\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(StringEditor.prototype, \"useRadioBoxComponent\", {\n get: function () {\n return this.useSelect && this.props.schema.format === 'radiobox';\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(StringEditor.prototype, \"canPreviewImage\", {\n get: function () {\n return common.isImageUrl(this.value) || common.isBase64Image(this.value);\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(StringEditor.prototype, \"canPreviewMarkdown\", {\n get: function () {\n return this.props.md && this.props.schema.format === 'markdown';\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(StringEditor.prototype, \"canPreviewCode\", {\n get: function () {\n return this.props.hljs && this.props.schema.format === 'code';\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(StringEditor.prototype, \"canPreview\", {\n get: function () {\n return (!!this.value) && (this.canPreviewImage || this.canPreviewMarkdown || this.canPreviewCode);\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(StringEditor.prototype, \"getImageUrl\", {\n get: function () {\n return this.props.forceHttps ? common.replaceProtocal(this.value) : this.value;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(StringEditor.prototype, \"getMarkdown\", {\n get: function () {\n return this.props.md.render(this.value);\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(StringEditor.prototype, \"getCode\", {\n get: function () {\n return this.props.hljs.highlightAuto(this.value).value;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(StringEditor.prototype, \"willPreviewImage\", {\n get: function () {\n return this.value && !this.collapsed && this.canPreviewImage;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(StringEditor.prototype, \"willPreviewMarkdown\", {\n get: function () {\n return this.value && !this.collapsed && this.canPreviewMarkdown;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(StringEditor.prototype, \"willPreviewCode\", {\n get: function () {\n return this.value && !this.collapsed && this.canPreviewCode;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(StringEditor.prototype, \"titleToShow\", {\n get: function () {\n return common.getTitle(this.props.title, this.props.schema.title);\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(StringEditor.prototype, \"options\", {\n get: function () {\n return common.getOptions(this.props.schema);\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(StringEditor.prototype, \"canUpload\", {\n get: function () {\n return this.props.schema.format === 'base64';\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(StringEditor.prototype, \"className\", {\n get: function () {\n var rowClass = this.errorMessage ? this.props.theme.errorRow : this.props.theme.row;\n return this.props.schema.className ? rowClass + ' ' + this.props.schema.className : rowClass;\n },\n enumerable: true,\n configurable: true\n });\n StringEditor.prototype.updateSelection = function (value) {\n this.value = value.toString();\n this.validate();\n this.setState({ value: this.value });\n this.props.updateValue(this.value, !this.errorMessage);\n };\n StringEditor.prototype.fileGot = function (file) {\n var _this = this;\n var reader = new FileReader();\n reader.readAsDataURL(file);\n reader.onload = function () {\n _this.value = reader.result;\n _this.validate();\n _this.setState({ value: _this.value });\n _this.props.updateValue(_this.value, !_this.errorMessage);\n };\n reader.onerror = function (error) {\n console.log(error);\n };\n };\n StringEditor.prototype.validate = function () {\n this.errorMessage = common.getErrorMessageOfString(this.value, this.props.schema, this.props.locale);\n };\n return StringEditor;\n}(React.Component));\nexport { StringEditor };\n","import * as tslib_1 from \"tslib\";\nimport * as React from 'react';\nimport * as common from 'schema-based-json-editor';\nimport { Icon } from './icon';\nimport { Optional } from './optional';\nimport { Description } from './description';\nvar NullEditor = /** @class */ (function (_super) {\n tslib_1.__extends(NullEditor, _super);\n function NullEditor(props) {\n var _this = _super.call(this, props) || this;\n _this.toggleOptional = function () {\n _this.value = common.toggleOptional(_this.value, _this.props.schema, _this.props.initialValue);\n _this.setState({ value: _this.value });\n _this.props.updateValue(_this.value, true);\n };\n _this.value = common.getDefaultValue(_this.props.required, _this.props.schema, _this.props.initialValue);\n return _this;\n }\n NullEditor.prototype.componentDidMount = function () {\n this.props.updateValue(this.value, true);\n };\n NullEditor.prototype.shouldComponentUpdate = function (nextProps, nextState) {\n return this.props.initialValue !== nextProps.initialValue;\n };\n NullEditor.prototype.render = function () {\n return (React.createElement(\"div\", { className: this.props.theme.row },\n React.createElement(\"label\", { className: this.props.theme.title },\n this.titleToShow,\n React.createElement(\"div\", { className: this.props.theme.buttonGroup, style: common.buttonGroupStyle },\n React.createElement(Optional, { required: this.props.required, value: this.value, isReadOnly: this.isReadOnly, theme: this.props.theme, locale: this.props.locale, toggleOptional: this.toggleOptional }),\n React.createElement(Icon, { valid: this.hasDeleteButtonFunction, onClick: this.props.onDelete, text: this.props.icon.delete, theme: this.props.theme, icon: this.props.icon }))),\n React.createElement(Description, { theme: this.props.theme, message: this.props.schema.description })));\n };\n Object.defineProperty(NullEditor.prototype, \"isReadOnly\", {\n get: function () {\n return this.props.readonly || this.props.schema.readonly;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(NullEditor.prototype, \"hasDeleteButtonFunction\", {\n get: function () {\n return this.props.onDelete && !this.isReadOnly;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(NullEditor.prototype, \"titleToShow\", {\n get: function () {\n return common.getTitle(this.props.title, this.props.schema.title);\n },\n enumerable: true,\n configurable: true\n });\n return NullEditor;\n}(React.Component));\nexport { NullEditor };\n","import * as tslib_1 from \"tslib\";\nimport * as React from 'react';\nimport * as common from 'schema-based-json-editor';\nimport { Icon } from './icon';\nimport { Optional } from './optional';\nimport { Description } from './description';\nimport { Select2 } from 'select2-react-component';\nvar BooleanEditor = /** @class */ (function (_super) {\n tslib_1.__extends(BooleanEditor, _super);\n function BooleanEditor(props) {\n var _this = _super.call(this, props) || this;\n _this.willRender = false;\n _this.onChange = function () {\n _this.value = !_this.value;\n _this.setState({ value: _this.value });\n _this.props.updateValue(_this.value, true);\n };\n _this.toggleOptional = function () {\n _this.value = common.toggleOptional(_this.value, _this.props.schema, _this.props.initialValue);\n _this.willRender = true;\n _this.setState({ value: _this.value });\n _this.props.updateValue(_this.value, true);\n };\n _this.value = common.getDefaultValue(_this.props.required, _this.props.schema, _this.props.initialValue);\n return _this;\n }\n BooleanEditor.prototype.componentDidMount = function () {\n this.props.updateValue(this.value, true);\n };\n BooleanEditor.prototype.shouldComponentUpdate = function (nextProps, nextState) {\n if (this.willRender) {\n this.willRender = false;\n return true;\n }\n return this.props.initialValue !== nextProps.initialValue;\n };\n BooleanEditor.prototype.render = function () {\n var _this = this;\n var control = null;\n if (this.value !== undefined) {\n if (this.props.schema.format === 'checkbox') {\n control = (React.createElement(\"div\", null,\n React.createElement(\"span\", { className: this.props.theme.checkbox },\n React.createElement(\"label\", null,\n React.createElement(\"input\", { type: 'checkbox', onChange: this.onChange, checked: this.value, disabled: this.isReadOnly }),\n this.props.locale.info.true))));\n }\n else if (this.props.schema.format === 'select') {\n control = (React.createElement(\"select\", { value: String(this.value), className: this.props.theme.select, disabled: this.isReadOnly, onChange: function (e) { return _this.onChange(); } },\n React.createElement(\"option\", { value: 'true' }, this.props.locale.info.true),\n React.createElement(\"option\", { value: 'false' }, this.props.locale.info.false)));\n }\n else if (this.props.schema.format === 'select2') {\n control = (React.createElement(Select2, { data: this.booleanOptions, value: this.value, disabled: this.isReadOnly, update: function (e) { return _this.onChange(); } }));\n }\n else {\n control = (React.createElement(\"div\", null,\n React.createElement(\"span\", { className: this.props.theme.radiobox },\n React.createElement(\"label\", null,\n React.createElement(\"input\", { type: 'radio', onChange: this.onChange, checked: this.value, disabled: this.isReadOnly }),\n this.props.locale.info.true)),\n React.createElement(\"span\", { className: this.props.theme.radiobox },\n React.createElement(\"label\", null,\n React.createElement(\"input\", { type: 'radio', onChange: this.onChange, checked: !this.value, disabled: this.isReadOnly }),\n this.props.locale.info.false))));\n }\n }\n return (React.createElement(\"div\", { className: this.className },\n React.createElement(\"label\", { className: this.props.theme.title },\n this.titleToShow,\n React.createElement(\"div\", { className: this.props.theme.buttonGroup, style: common.buttonGroupStyle },\n React.createElement(Optional, { required: this.props.required, value: this.value, isReadOnly: this.isReadOnly, theme: this.props.theme, locale: this.props.locale, toggleOptional: this.toggleOptional }),\n React.createElement(Icon, { valid: this.hasDeleteButtonFunction, onClick: this.props.onDelete, text: this.props.icon.delete, theme: this.props.theme, icon: this.props.icon }))),\n control,\n React.createElement(Description, { theme: this.props.theme, message: this.props.schema.description })));\n };\n Object.defineProperty(BooleanEditor.prototype, \"isReadOnly\", {\n get: function () {\n return this.props.readonly || this.props.schema.readonly;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(BooleanEditor.prototype, \"hasDeleteButtonFunction\", {\n get: function () {\n return this.props.onDelete && !this.isReadOnly;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(BooleanEditor.prototype, \"titleToShow\", {\n get: function () {\n return common.getTitle(this.props.title, this.props.schema.title);\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(BooleanEditor.prototype, \"booleanOptions\", {\n get: function () {\n return [\n {\n value: true,\n label: this.props.locale.info.true\n },\n {\n value: false,\n label: this.props.locale.info.false\n }\n ];\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(BooleanEditor.prototype, \"className\", {\n get: function () {\n var rowClass = this.props.theme.row;\n return this.props.schema.className ? rowClass + ' ' + this.props.schema.className : rowClass;\n },\n enumerable: true,\n configurable: true\n });\n return BooleanEditor;\n}(React.Component));\nexport { BooleanEditor };\n","import * as tslib_1 from \"tslib\";\nimport * as React from 'react';\nimport * as common from 'schema-based-json-editor';\nimport { Icon } from './icon';\nimport { Optional } from './optional';\nimport { Description } from './description';\nimport { Select2 } from 'select2-react-component';\nvar NumberEditor = /** @class */ (function (_super) {\n tslib_1.__extends(NumberEditor, _super);\n function NumberEditor(props) {\n var _this = _super.call(this, props) || this;\n _this.willRender = false;\n _this.onChange = function (e) {\n _this.value = _this.props.schema.type === 'integer' ? common.toInteger(e.currentTarget.value) : common.toNumber(e.currentTarget.value);\n _this.validate();\n _this.setState({ value: _this.value });\n _this.props.updateValue(_this.value, !_this.errorMessage);\n };\n _this.toggleOptional = function () {\n _this.value = common.toggleOptional(_this.value, _this.props.schema, _this.props.initialValue);\n _this.validate();\n _this.willRender = true;\n _this.setState({ value: _this.value });\n _this.props.updateValue(_this.value, !_this.errorMessage);\n };\n _this.value = common.getDefaultValue(_this.props.required, _this.props.schema, _this.props.initialValue);\n _this.validate();\n return _this;\n }\n NumberEditor.prototype.componentDidMount = function () {\n this.props.updateValue(this.value, !this.errorMessage);\n };\n NumberEditor.prototype.shouldComponentUpdate = function (nextProps, nextState) {\n if (this.willRender) {\n this.willRender = false;\n return true;\n }\n return this.props.initialValue !== nextProps.initialValue;\n };\n NumberEditor.prototype.render = function () {\n var _this = this;\n var input = this.useInput ? (React.createElement(\"input\", { className: this.errorMessage ? this.props.theme.errorInput : this.props.theme.input, type: 'number', onChange: this.onChange, defaultValue: String(this.value), readOnly: this.isReadOnly, disabled: this.isReadOnly })) : null;\n var select = null;\n if (this.useSelect) {\n if (this.useSelectComponent) {\n var options = this.options.map(function (op) { return React.createElement(\"option\", { key: op.value, value: op.value }, op.label); });\n select = React.createElement(\"select\", { value: this.value, className: this.props.theme.select, disabled: this.isReadOnly, onChange: function (e) { return _this.updateSelection(+e.target.value); } }, options);\n }\n else if (this.useSelect2Component) {\n select = React.createElement(Select2, { data: this.options, value: this.value, disabled: this.isReadOnly, update: function (e) { return _this.updateSelection(e); } });\n }\n else if (this.useRadioBoxComponent) {\n var options = this.options.map(function (option) { return React.createElement(\"span\", { key: option.value, className: _this.props.theme.radiobox },\n React.createElement(\"label\", null,\n React.createElement(\"input\", { type: 'radio', onChange: function () { return _this.updateSelection(option.value); }, checked: _this.value === option.value, disabled: _this.isReadOnly }),\n option.label)); });\n select = React.createElement(\"div\", null, options);\n }\n }\n return (React.createElement(\"div\", { className: this.className },\n React.createElement(\"label\", { className: this.props.theme.title },\n this.titleToShow,\n React.createElement(\"div\", { className: this.props.theme.buttonGroup, style: common.buttonGroupStyle },\n React.createElement(Optional, { required: this.props.required, value: this.value, isReadOnly: this.isReadOnly, theme: this.props.theme, locale: this.props.locale, toggleOptional: this.toggleOptional }),\n React.createElement(Icon, { valid: this.hasDeleteButtonFunction, onClick: this.props.onDelete, text: this.props.icon.delete, theme: this.props.theme, icon: this.props.icon }))),\n input,\n select,\n React.createElement(Description, { theme: this.props.theme, message: this.props.schema.description }),\n React.createElement(Description, { theme: this.props.theme, message: this.errorMessage })));\n };\n NumberEditor.prototype.validate = function () {\n this.errorMessage = common.getErrorMessageOfNumber(this.value, this.props.schema, this.props.locale);\n };\n Object.defineProperty(NumberEditor.prototype, \"useInput\", {\n get: function () {\n return this.value !== undefined && (this.props.schema.enum === undefined || this.isReadOnly);\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(NumberEditor.prototype, \"useSelect\", {\n get: function () {\n return this.value !== undefined && (this.props.schema.enum !== undefined && !this.isReadOnly);\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(NumberEditor.prototype, \"useSelect2Component\", {\n get: function () {\n return this.useSelect && !this.props.noSelect2 && this.props.schema.format !== 'select' && this.props.schema.format !== 'radiobox';\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(NumberEditor.prototype, \"useSelectComponent\", {\n get: function () {\n return this.useSelect && (this.props.schema.format === 'select' || this.props.noSelect2);\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(NumberEditor.prototype, \"useRadioBoxComponent\", {\n get: function () {\n return this.useSelect && this.props.schema.format === 'radiobox';\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(NumberEditor.prototype, \"isReadOnly\", {\n get: function () {\n return this.props.readonly || this.props.schema.readonly;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(NumberEditor.prototype, \"hasDeleteButtonFunction\", {\n get: function () {\n return this.props.onDelete && !this.isReadOnly;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(NumberEditor.prototype, \"titleToShow\", {\n get: function () {\n return common.getTitle(this.props.title, this.props.schema.title);\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(NumberEditor.prototype, \"options\", {\n get: function () {\n return common.getOptions(this.props.schema);\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(NumberEditor.prototype, \"className\", {\n get: function () {\n var rowClass = this.errorMessage ? this.props.theme.errorRow : this.props.theme.row;\n return this.props.schema.className ? rowClass + ' ' + this.props.schema.className : rowClass;\n },\n enumerable: true,\n configurable: true\n });\n NumberEditor.prototype.updateSelection = function (value) {\n this.value = +value;\n this.validate();\n this.setState({ value: this.value });\n this.props.updateValue(this.value, !this.errorMessage);\n };\n return NumberEditor;\n}(React.Component));\nexport { NumberEditor };\n","import * as tslib_1 from \"tslib\";\nexport var timeout = 200;\nvar unicodePatterns = [\n { l: 'a', s: /[ⓐaẚàáâầấẫẩãāăằắẵẳȧǡäǟảåǻǎȁȃạậặḁąⱥɐ]/gi },\n { l: 'aa', s: /ꜳ/gi },\n { l: 'ae', s: /[æǽǣ]/gi },\n { l: 'ao', s: /ꜵ/gi },\n { l: 'au', s: /ꜷ/gi },\n { l: 'av', s: /[ꜹꜻ]/gi },\n { l: 'ay', s: /ꜽ/gi },\n { l: 'b', s: /[ⓑbḃḅḇƀƃɓ]/gi },\n { l: 'c', s: /[ⓒcćĉċčçḉƈȼꜿↄ]/gi },\n { l: 'd', s: /[ⓓdḋďḍḑḓḏđƌɖɗꝺ]/gi },\n { l: 'dz', s: /[dzdž]/gi },\n { l: 'e', s: /[ⓔeèéêềếễểẽēḕḗĕėëẻěȅȇẹệȩḝęḙḛɇɛǝ]/gi },\n { l: 'f', s: /[ⓕfḟƒꝼ]/gi },\n { l: 'g', s: /[ⓖgǵĝḡğġǧģǥɠꞡᵹꝿ]/gi },\n { l: 'h', s: /[ⓗhĥḣḧȟḥḩḫẖħⱨⱶɥ]/gi },\n { l: 'hv', s: /ƕ/gi },\n { l: 'i', s: /[ⓘiìíîĩīĭİïḯỉǐȉȋịįḭɨı]/gi },\n { l: 'j', s: /[ⓙjĵǰɉ]/gi },\n { l: 'k', s: /[ⓚkḱǩḳķḵƙⱪꝁꝃꝅꞣ]/gi },\n { l: 'l', s: /[ⓛlŀĺľḷḹļḽḻſłƚɫⱡꝉꞁꝇꝆ]/gi },\n { l: 'lj', s: /lj/gi },\n { l: 'm', s: /[ⓜmḿṁṃɱɯ]/gi },\n { l: 'n', s: /[ⓝnǹńñṅňṇņṋṉƞɲʼnꞑꞥ]/gi },\n { l: 'nj', s: /nj/gi },\n { l: 'o', s: /[ⓞoòóôồốỗổõṍȭṏōṑṓŏȯȱöȫỏőǒȍȏơờớỡởợọộǫǭøǿɔƟꝋꝍɵ]/gi },\n { l: 'oi', s: /ƣ/gi },\n { l: 'oe', s: /œ/gi },\n { l: 'oo', s: /ꝏ/gi },\n { l: 'ou', s: /ȣ/gi },\n { l: 'p', s: /[ⓟpṕṗƥᵽꝑꝓꝕ]/gi },\n { l: 'q', s: /[ⓠqɋꝗꝙ]/gi },\n { l: 'r', s: /[ⓡrŕṙřȑȓṛṝŗṟɍɽꝛꞧꞃ]/gi },\n { l: 's', s: /[ⓢsßẞśṥŝṡšṧṣṩșşȿꞩꞅẛ]/gi },\n { l: 't', s: /[ⓣtṫẗťṭțţṱṯŧƭʈⱦꞇ]/gi },\n { l: 'tz', s: /ꜩ/gi },\n { l: 'u', s: /[ⓤuùúûũṹūṻŭüǜǘǖǚủůűǔȕȗưừứữửựụṳųṷṵʉ]/gi },\n { l: 'v', s: /[ⓥvṽṿʋꝟʌ]/gi },\n { l: 'vy', s: /ꝡ/gi },\n { l: 'w', s: /[ⓦwẁẃŵẇẅẘẉⱳ]/gi },\n { l: 'x', s: /[ⓧxẋẍ]/gi },\n { l: 'y', s: /[ⓨyỳýŷỹȳẏÿỷẙỵƴɏỿ]/gi },\n { l: 'z', s: /[ⓩzźẑżžẓẕƶȥɀⱬꝣ]/gi }\n];\nfunction getScrollUpIndex(data, value) {\n var index = 0;\n try {\n for (var data_1 = tslib_1.__values(data), data_1_1 = data_1.next(); !data_1_1.done; data_1_1 = data_1.next()) {\n var groupOrOption = data_1_1.value;\n var options = groupOrOption.options;\n if (options) {\n index++;\n try {\n for (var options_1 = tslib_1.__values(options), options_1_1 = options_1.next(); !options_1_1.done; options_1_1 = options_1.next()) {\n var option = options_1_1.value;\n if (option.value === value) {\n return index;\n }\n else {\n index++;\n }\n }\n }\n catch (e_1_1) { e_1 = { error: e_1_1 }; }\n finally {\n try {\n if (options_1_1 && !options_1_1.done && (_a = options_1.return)) _a.call(options_1);\n }\n finally { if (e_1) throw e_1.error; }\n }\n }\n else {\n if (groupOrOption.value === value) {\n return index;\n }\n else {\n index++;\n }\n }\n }\n }\n catch (e_2_1) { e_2 = { error: e_2_1 }; }\n finally {\n try {\n if (data_1_1 && !data_1_1.done && (_b = data_1.return)) _b.call(data_1);\n }\n finally { if (e_2) throw e_2.error; }\n }\n return 0;\n var e_2, _b, e_1, _a;\n}\nexport function getOptionByValue(data, value) {\n try {\n for (var data_2 = tslib_1.__values(data), data_2_1 = data_2.next(); !data_2_1.done; data_2_1 = data_2.next()) {\n var groupOrOption = data_2_1.value;\n var options = groupOrOption.options;\n if (options) {\n try {\n for (var options_2 = tslib_1.__values(options), options_2_1 = options_2.next(); !options_2_1.done; options_2_1 = options_2.next()) {\n var option = options_2_1.value;\n if (option.value === value) {\n return option;\n }\n }\n }\n catch (e_3_1) { e_3 = { error: e_3_1 }; }\n finally {\n try {\n if (options_2_1 && !options_2_1.done && (_a = options_2.return)) _a.call(options_2);\n }\n finally { if (e_3) throw e_3.error; }\n }\n }\n else {\n if (groupOrOption.value === value) {\n return groupOrOption;\n }\n }\n }\n }\n catch (e_4_1) { e_4 = { error: e_4_1 }; }\n finally {\n try {\n if (data_2_1 && !data_2_1.done && (_b = data_2.return)) _b.call(data_2);\n }\n finally { if (e_4) throw e_4.error; }\n }\n return null;\n var e_4, _b, e_3, _a;\n}\nexport function getOptionsByValue(data, value, multiple) {\n if (multiple) {\n var values = Array.isArray(value) ? value : [];\n var result = [];\n try {\n for (var values_1 = tslib_1.__values(values), values_1_1 = values_1.next(); !values_1_1.done; values_1_1 = values_1.next()) {\n var v = values_1_1.value;\n var option = getOptionByValue(data, v);\n if (option) {\n result.push(option);\n }\n }\n }\n catch (e_5_1) { e_5 = { error: e_5_1 }; }\n finally {\n try {\n if (values_1_1 && !values_1_1.done && (_a = values_1.return)) _a.call(values_1);\n }\n finally { if (e_5) throw e_5.error; }\n }\n return result;\n }\n return getOptionByValue(data, value);\n var e_5, _a;\n}\nexport function getFirstAvailableOption(data) {\n try {\n for (var data_3 = tslib_1.__values(data), data_3_1 = data_3.next(); !data_3_1.done; data_3_1 = data_3.next()) {\n var groupOrOption = data_3_1.value;\n var options = groupOrOption.options;\n if (options) {\n try {\n for (var options_3 = tslib_1.__values(options), options_3_1 = options_3.next(); !options_3_1.done; options_3_1 = options_3.next()) {\n var option = options_3_1.value;\n if (!option.disabled) {\n return option.value;\n }\n }\n }\n catch (e_6_1) { e_6 = { error: e_6_1 }; }\n finally {\n try {\n if (options_3_1 && !options_3_1.done && (_a = options_3.return)) _a.call(options_3);\n }\n finally { if (e_6) throw e_6.error; }\n }\n }\n else {\n var option = groupOrOption;\n if (!option.disabled) {\n return option.value;\n }\n }\n }\n }\n catch (e_7_1) { e_7 = { error: e_7_1 }; }\n finally {\n try {\n if (data_3_1 && !data_3_1.done && (_b = data_3.return)) _b.call(data_3);\n }\n finally { if (e_7) throw e_7.error; }\n }\n return null;\n var e_7, _b, e_6, _a;\n}\nfunction getOptionsCount(data) {\n var count = 0;\n try {\n for (var data_4 = tslib_1.__values(data), data_4_1 = data_4.next(); !data_4_1.done; data_4_1 = data_4.next()) {\n var groupOrOption = data_4_1.value;\n var options = groupOrOption.options;\n if (options) {\n count += options.length;\n }\n else {\n count++;\n }\n }\n }\n catch (e_8_1) { e_8 = { error: e_8_1 }; }\n finally {\n try {\n if (data_4_1 && !data_4_1.done && (_a = data_4.return)) _a.call(data_4);\n }\n finally { if (e_8) throw e_8.error; }\n }\n return count;\n var e_8, _a;\n}\nexport function valueIsNotInFilteredData(filteredData, value) {\n if (value === null || value === undefined) {\n return true;\n }\n try {\n for (var filteredData_1 = tslib_1.__values(filteredData), filteredData_1_1 = filteredData_1.next(); !filteredData_1_1.done; filteredData_1_1 = filteredData_1.next()) {\n var groupOrOption = filteredData_1_1.value;\n var options = groupOrOption.options;\n if (options) {\n try {\n for (var options_4 = tslib_1.__values(options), options_4_1 = options_4.next(); !options_4_1.done; options_4_1 = options_4.next()) {\n var option = options_4_1.value;\n if (option.value === value) {\n return false;\n }\n }\n }\n catch (e_9_1) { e_9 = { error: e_9_1 }; }\n finally {\n try {\n if (options_4_1 && !options_4_1.done && (_a = options_4.return)) _a.call(options_4);\n }\n finally { if (e_9) throw e_9.error; }\n }\n }\n else {\n if (groupOrOption.value === value) {\n return false;\n }\n }\n }\n }\n catch (e_10_1) { e_10 = { error: e_10_1 }; }\n finally {\n try {\n if (filteredData_1_1 && !filteredData_1_1.done && (_b = filteredData_1.return)) _b.call(filteredData_1);\n }\n finally { if (e_10) throw e_10.error; }\n }\n return true;\n var e_10, _b, e_9, _a;\n}\nexport function getPreviousOption(filteredData, hoveringValue) {\n var findIt = hoveringValue === null || hoveringValue === undefined;\n for (var i = filteredData.length - 1; i >= 0; i--) {\n var groupOrOption = filteredData[i];\n var options = groupOrOption.options;\n if (options) {\n for (var j = options.length - 1; j >= 0; j--) {\n var option = options[j];\n if (findIt) {\n if (!option.disabled) {\n return option.value;\n }\n }\n findIt = option.value === hoveringValue;\n }\n }\n else {\n var option = groupOrOption;\n if (findIt) {\n if (!option.disabled) {\n return option.value;\n }\n }\n findIt = option.value === hoveringValue;\n }\n }\n return findIt ? hoveringValue : null;\n}\nexport function getNextOption(filteredData, hoveringValue) {\n var findIt = hoveringValue === null || hoveringValue === undefined;\n try {\n for (var filteredData_2 = tslib_1.__values(filteredData), filteredData_2_1 = filteredData_2.next(); !filteredData_2_1.done; filteredData_2_1 = filteredData_2.next()) {\n var groupOrOption = filteredData_2_1.value;\n var options = groupOrOption.options;\n if (options) {\n try {\n for (var options_5 = tslib_1.__values(options), options_5_1 = options_5.next(); !options_5_1.done; options_5_1 = options_5.next()) {\n var option = options_5_1.value;\n if (findIt) {\n if (!option.disabled) {\n return option.value;\n }\n }\n else {\n findIt = option.value === hoveringValue;\n }\n }\n }\n catch (e_11_1) { e_11 = { error: e_11_1 }; }\n finally {\n try {\n if (options_5_1 && !options_5_1.done && (_a = options_5.return)) _a.call(options_5);\n }\n finally { if (e_11) throw e_11.error; }\n }\n }\n else {\n var option = groupOrOption;\n if (findIt) {\n if (!option.disabled) {\n return option.value;\n }\n }\n else {\n findIt = option.value === hoveringValue;\n }\n }\n }\n }\n catch (e_12_1) { e_12 = { error: e_12_1 }; }\n finally {\n try {\n if (filteredData_2_1 && !filteredData_2_1.done && (_b = filteredData_2.return)) _b.call(filteredData_2);\n }\n finally { if (e_12) throw e_12.error; }\n }\n return findIt ? hoveringValue : null;\n var e_12, _b, e_11, _a;\n}\nexport function getLastScrollTopIndex(hoveringValue, results, filteredData, lastScrollTopIndex) {\n if (hoveringValue === null || hoveringValue === undefined) {\n results.scrollTop = 0;\n return 0;\n }\n else {\n var scrollTop = getScrollUpIndex(filteredData, hoveringValue);\n if (scrollTop - lastScrollTopIndex > 5) {\n lastScrollTopIndex += scrollTop - lastScrollTopIndex - 5;\n var item = results.querySelectorAll('li').item(scrollTop);\n if (item) {\n results.scrollTop = item.offsetTop - results.offsetHeight;\n }\n return lastScrollTopIndex;\n }\n if (lastScrollTopIndex - scrollTop > 0) {\n lastScrollTopIndex -= lastScrollTopIndex - scrollTop;\n var item = results.querySelectorAll('li').item(lastScrollTopIndex - 1);\n if (item) {\n results.scrollTop = item.offsetTop;\n }\n return lastScrollTopIndex;\n }\n return null;\n }\n}\nfunction containSearchText(label, searchText, editPattern) {\n return searchText\n ? formatSansUnicode(label).match(new RegExp(formatPattern(searchText, editPattern), 'i')) !== null\n : true;\n}\nfunction protectPattern(str) {\n return str.replace(/[\\-\\[\\]\\/\\{\\}\\(\\)\\*\\+\\?\\.\\\\\\^\\$\\|]/g, '\\\\$&');\n}\nfunction formatSansUnicode(str) {\n try {\n for (var unicodePatterns_1 = tslib_1.__values(unicodePatterns), unicodePatterns_1_1 = unicodePatterns_1.next(); !unicodePatterns_1_1.done; unicodePatterns_1_1 = unicodePatterns_1.next()) {\n var unicodePattern = unicodePatterns_1_1.value;\n str = str.replace(unicodePattern.s, unicodePattern.l);\n }\n }\n catch (e_13_1) { e_13 = { error: e_13_1 }; }\n finally {\n try {\n if (unicodePatterns_1_1 && !unicodePatterns_1_1.done && (_a = unicodePatterns_1.return)) _a.call(unicodePatterns_1);\n }\n finally { if (e_13) throw e_13.error; }\n }\n return str;\n var e_13, _a;\n}\nfunction formatPattern(str, editPattern) {\n str = formatSansUnicode(protectPattern(str));\n if (editPattern && typeof editPattern === 'function') {\n str = editPattern(str);\n }\n return str;\n}\nexport function getFilteredData(data, searchText, editPattern) {\n if (searchText) {\n var result = [];\n try {\n for (var data_5 = tslib_1.__values(data), data_5_1 = data_5.next(); !data_5_1.done; data_5_1 = data_5.next()) {\n var groupOrOption = data_5_1.value;\n var options = groupOrOption.options;\n if (options) {\n if (options.some(function (group) { return containSearchText(group.label, searchText, editPattern); })) {\n var filteredOptions = options.filter(function (group) { return containSearchText(group.label, searchText, editPattern); });\n result.push({\n label: groupOrOption.label,\n options: filteredOptions\n });\n }\n }\n else if (containSearchText(groupOrOption.label, searchText, editPattern)) {\n result.push(groupOrOption);\n }\n }\n }\n catch (e_14_1) { e_14 = { error: e_14_1 }; }\n finally {\n try {\n if (data_5_1 && !data_5_1.done && (_a = data_5.return)) _a.call(data_5);\n }\n finally { if (e_14) throw e_14.error; }\n }\n return result;\n }\n else {\n return data;\n }\n var e_14, _a;\n}\nexport function getOptionStyle(value, hoveringValue) {\n return value === hoveringValue\n ? 'select2-results__option select2-results__option--highlighted'\n : 'select2-results__option';\n}\nexport function getDropdownStyle(isOpen) {\n return isOpen\n ? 'select2-container select2-container--default select2-container-dropdown select2-container--open'\n : 'select2-container select2-container--default select2-container-dropdown';\n}\nexport function getContainerStyle(disabled, isOpen) {\n return \"select2 select2-container select2-container--default \" + (disabled ? 'select2-container--disabled' : '') + \" \"\n + ((isOpen ? 'select2-container--open' : '') + \" select2-container--below select2-container--focus\");\n}\nexport function getSelectionStyle(multiple) {\n return \"select2-selection select2-selection--\" + (multiple ? 'multiple' : 'single');\n}\nvar defaultMinCountForSearch = 6;\nexport function isSearchboxHiddex(data, minCountForSearch) {\n if (typeof minCountForSearch !== 'number') {\n minCountForSearch = defaultMinCountForSearch;\n }\n var optionCount = getOptionsCount(data);\n return optionCount < minCountForSearch;\n}\nexport function getSearchStyle(isHidden) {\n return isHidden\n ? 'select2-search select2-search--dropdown select2-search--hide'\n : 'select2-search select2-search--dropdown';\n}\nexport function isSelected(options, option, multiple) {\n if (multiple) {\n return options && options.some(function (op) { return op.value === option.value; }) ? 'true' : 'false';\n }\n else {\n return options && option.value === options.value ? 'true' : 'false';\n }\n}\nexport function removeSelection(options, option) {\n for (var i = 0; i < options.length; i++) {\n if (options[i].value === option.value) {\n options.splice(i, 1);\n return;\n }\n }\n}\n","import * as tslib_1 from \"tslib\";\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport * as common from 'schema-based-json-editor';\nimport { Select2 } from 'select2-react-component';\nimport { Editor } from './editor';\nimport { Icon } from './icon';\nimport { Optional } from './optional';\nimport { Description } from './description';\nvar ArrayEditor = /** @class */ (function (_super) {\n tslib_1.__extends(ArrayEditor, _super);\n function ArrayEditor(props) {\n var _this = _super.call(this, props) || this;\n _this.renderSwitch = 1;\n _this.collapsed = _this.props.schema.collapsed;\n _this.invalidIndexes = [];\n _this.filter = '';\n _this.collapseOrExpand = function () {\n _this.collapsed = !_this.collapsed;\n _this.setState({ collapsed: _this.collapsed });\n };\n _this.toggleOptional = function () {\n _this.value = common.toggleOptional(_this.value, _this.props.schema, _this.props.initialValue);\n _this.validate();\n _this.setState({ value: _this.value });\n _this.props.updateValue(_this.value, !_this.errorMessage && _this.invalidIndexes.length === 0);\n };\n _this.addItem = function () {\n _this.value.push(common.getDefaultValue(true, _this.props.schema.items, undefined));\n _this.setState({ value: _this.value });\n _this.props.updateValue(_this.value, !_this.errorMessage && _this.invalidIndexes.length === 0);\n };\n _this.onChange = function (i, value, isValid) {\n _this.value[i] = value;\n _this.setState({ value: _this.value });\n _this.validate();\n common.recordInvalidIndexesOfArray(_this.invalidIndexes, isValid, i);\n _this.props.updateValue(_this.value, !_this.errorMessage && _this.invalidIndexes.length === 0);\n };\n _this.onFilterChange = function (e) {\n _this.filter = e.currentTarget.value;\n _this.setState({ filter: _this.filter });\n };\n _this.onDeleteFunction = function (i) {\n _this.value.splice(i, 1);\n _this.renderSwitch = -_this.renderSwitch;\n _this.setState({ value: _this.value, renderSwitch: _this.renderSwitch });\n _this.validate();\n _this.props.updateValue(_this.value, !_this.errorMessage && _this.invalidIndexes.length === 0);\n };\n _this.isChecked = function (value) {\n return _this.value && _this.value.indexOf(value) !== -1;\n };\n _this.onChangeCheckbox = function (value) {\n if (_this.value) {\n var index = _this.value.indexOf(value);\n if (index !== -1) {\n _this.value.splice(index, 1);\n }\n else {\n _this.value.push(value);\n }\n _this.validate();\n _this.props.updateValue(_this.value, !_this.errorMessage && _this.invalidIndexes.length === 0);\n }\n };\n _this.onChangeSelect2 = function (value) {\n _this.value = value;\n _this.validate();\n _this.props.updateValue(_this.value, !_this.errorMessage && _this.invalidIndexes.length === 0);\n };\n _this.value = common.getDefaultValue(_this.props.required, _this.props.schema, _this.props.initialValue);\n _this.validate();\n return _this;\n }\n ArrayEditor.prototype.componentDidMount = function () {\n var _this = this;\n this.props.updateValue(this.value, !this.errorMessage && this.invalidIndexes.length === 0);\n if (this.props.dragula) {\n var container = common.findContainer(ReactDOM.findDOMNode(this).childNodes);\n this.drak = this.props.dragula([container]);\n this.drak.on('drop', function (el, target, source, sibling) {\n if (_this.value) {\n common.switchItem(_this.value, el, sibling);\n _this.renderSwitch = -_this.renderSwitch;\n _this.setState({ value: _this.value, renderSwitch: _this.renderSwitch });\n _this.props.updateValue(_this.value, !_this.errorMessage && _this.invalidIndexes.length === 0);\n }\n });\n }\n };\n ArrayEditor.prototype.componentWillUnmount = function () {\n if (this.drak) {\n this.drak.destroy();\n }\n };\n ArrayEditor.prototype.render = function () {\n var _this = this;\n var childrenElement = this.getValue.map(function (p, i) { return ({ p: p, i: i }); })\n .filter(function (_a) {\n var p = _a.p, i = _a.i;\n return common.filterArray(p, i, _this.props.schema.items, _this.filter);\n })\n .map(function (_a) {\n var p = _a.p, i = _a.i;\n return (React.createElement(\"div\", { key: (1 + i) * _this.renderSwitch, \"data-index\": i, className: _this.props.theme.card },\n React.createElement(Editor, { schema: _this.props.schema.items, title: String(i), initialValue: _this.getValue[i], updateValue: function (value, isValid) { return _this.onChange(i, value, isValid); }, theme: _this.props.theme, icon: _this.props.icon, locale: _this.props.locale, required: true, readonly: _this.isReadOnly, onDelete: function () { return _this.onDeleteFunction(i); }, dragula: _this.props.dragula, md: _this.props.md, hljs: _this.props.hljs, forceHttps: _this.props.forceHttps, disableCollapse: _this.props.disableCollapse, noSelect2: _this.props.noSelect2 })));\n });\n var filterElement = (!this.collapsed && this.value !== undefined && this.showFilter)\n ? React.createElement(\"div\", { className: this.props.theme.row },\n React.createElement(\"input\", { className: this.props.theme.input, onChange: this.onFilterChange, defaultValue: this.filter }))\n : null;\n var element;\n if (this.props.schema.enum) {\n var format = void 0;\n if (this.props.schema.format === 'select2' && !this.props.noSelect2) {\n format = (React.createElement(Select2, { data: this.options, value: this.value, disabled: this.isReadOnly, multiple: true, update: function ($event) { return _this.onChangeSelect2($event); } }));\n }\n else {\n format = this.options.map(function (option) { return (React.createElement(\"span\", { key: option.value, className: _this.props.theme.checkbox },\n React.createElement(\"label\", null,\n React.createElement(\"input\", { type: 'checkbox', onChange: function () { return _this.onChangeCheckbox(option.value); }, checked: _this.isChecked(option.value), disabled: _this.isReadOnly }),\n option.label))); });\n }\n element = (React.createElement(\"div\", null, format));\n }\n else {\n element = (React.createElement(\"div\", { className: this.props.theme.card },\n filterElement,\n childrenElement));\n }\n return (React.createElement(\"div\", { className: this.className },\n React.createElement(\"h3\", null,\n this.titleToShow,\n React.createElement(\"div\", { className: this.props.theme.buttonGroup, style: common.buttonGroupStyle },\n React.createElement(Optional, { required: this.props.required, value: this.value, isReadOnly: this.isReadOnly, theme: this.props.theme, locale: this.props.locale, toggleOptional: this.toggleOptional }),\n React.createElement(Icon, { valid: !this.props.disableCollapse && this.value && this.value.length > 0 && !this.props.schema.enum, onClick: this.collapseOrExpand, text: this.collapsed ? this.props.icon.expand : this.props.icon.collapse, theme: this.props.theme, icon: this.props.icon }),\n React.createElement(Icon, { valid: this.hasAddButton, onClick: this.addItem, text: this.props.icon.add, theme: this.props.theme, icon: this.props.icon }),\n React.createElement(Icon, { valid: this.hasDeleteButtonFunction, onClick: this.props.onDelete, text: this.props.icon.delete, theme: this.props.theme, icon: this.props.icon }))),\n React.createElement(Description, { theme: this.props.theme, message: this.props.schema.description }),\n element,\n React.createElement(Description, { theme: this.props.theme, message: this.errorMessage })));\n };\n ArrayEditor.prototype.validate = function () {\n this.errorMessage = common.getErrorMessageOfArray(this.value, this.props.schema, this.props.locale);\n };\n Object.defineProperty(ArrayEditor.prototype, \"isReadOnly\", {\n get: function () {\n return this.props.readonly || this.props.schema.readonly;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(ArrayEditor.prototype, \"hasDeleteButtonFunction\", {\n get: function () {\n return this.props.onDelete && !this.isReadOnly;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(ArrayEditor.prototype, \"hasAddButton\", {\n get: function () {\n return !this.isReadOnly && this.value !== undefined && !this.props.schema.enum;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(ArrayEditor.prototype, \"getValue\", {\n get: function () {\n if (this.value !== undefined && !this.collapsed) {\n return this.value;\n }\n return [];\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(ArrayEditor.prototype, \"titleToShow\", {\n get: function () {\n return common.getTitle(this.props.title, this.props.schema.title);\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(ArrayEditor.prototype, \"showFilter\", {\n get: function () {\n var minItemCountIfNeedFilter = typeof this.props.minItemCountIfNeedFilter === 'number' ? this.props.minItemCountIfNeedFilter : common.minItemCountIfNeedFilter;\n return this.getValue.length >= minItemCountIfNeedFilter;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(ArrayEditor.prototype, \"className\", {\n get: function () {\n var rowClass = this.errorMessage ? this.props.theme.errorRow : this.props.theme.row;\n return this.props.schema.className ? rowClass + ' ' + this.props.schema.className : rowClass;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(ArrayEditor.prototype, \"options\", {\n get: function () {\n return common.getOptions(this.props.schema);\n },\n enumerable: true,\n configurable: true\n });\n return ArrayEditor;\n}(React.Component));\nexport { ArrayEditor };\n","import * as tslib_1 from \"tslib\";\nimport * as React from 'react';\nimport * as common from 'schema-based-json-editor';\nimport { Editor } from './editor';\nimport { Icon } from './icon';\nimport { Optional } from './optional';\nimport { Description } from './description';\nvar ObjectEditor = /** @class */ (function (_super) {\n tslib_1.__extends(ObjectEditor, _super);\n function ObjectEditor(props) {\n var _this = _super.call(this, props) || this;\n _this.collapsed = _this.props.schema.collapsed;\n _this.invalidProperties = [];\n _this.properties = [];\n _this.filter = '';\n _this.collapseOrExpand = function () {\n _this.collapsed = !_this.collapsed;\n _this.setState({ collapsed: _this.collapsed });\n };\n _this.toggleOptional = function () {\n _this.value = common.toggleOptional(_this.value, _this.props.schema, _this.props.initialValue);\n _this.validate();\n _this.setState({ value: _this.value });\n _this.props.updateValue(_this.value, _this.invalidProperties.length === 0);\n };\n _this.onFilterChange = function (e) {\n _this.filter = e.currentTarget.value;\n _this.setState({ filter: _this.filter });\n };\n _this.onChange = function (property, value, isValid) {\n _this.value[property] = value;\n for (var p in _this.props.schema.properties) {\n if (_this.isRequired(p) === false) {\n _this.value[p] = undefined;\n }\n }\n _this.validate();\n _this.setState({ value: _this.value });\n common.recordInvalidPropertiesOfObject(_this.invalidProperties, isValid, property);\n _this.props.updateValue(_this.value, !_this.errorMessage && _this.invalidProperties.length === 0);\n };\n _this.value = common.getDefaultValue(_this.props.required, _this.props.schema, _this.props.initialValue);\n _this.validate();\n if (_this.value !== undefined) {\n var _loop_1 = function (property) {\n if (this_1.props.schema.properties.hasOwnProperty(property)) {\n var schema = this_1.props.schema.properties[property];\n var required = this_1.props.schema.required && this_1.props.schema.required.some(function (r) { return r === property; });\n this_1.value[property] = common.getDefaultValue(required, schema, this_1.value[property]);\n this_1.properties.push({\n property: property,\n schema: schema\n });\n }\n };\n var this_1 = this;\n for (var property in _this.props.schema.properties) {\n _loop_1(property);\n }\n _this.properties = _this.properties.sort(common.compare);\n }\n return _this;\n }\n ObjectEditor.prototype.componentDidMount = function () {\n this.props.updateValue(this.value, this.invalidProperties.length === 0);\n };\n ObjectEditor.prototype.render = function () {\n var _this = this;\n var childrenElement = (!this.collapsed && this.value !== undefined)\n ? this.properties.filter(function (p) { return common.filterObject(p, _this.filter) && _this.isRequired(p.property) !== false; })\n .map(function (_a) {\n var property = _a.property, schema = _a.schema;\n return React.createElement(Editor, { key: property + _this.isRequired(property), schema: schema, title: schema.title || property, initialValue: _this.value[property], updateValue: function (value, isValid) { return _this.onChange(property, value, isValid); }, theme: _this.props.theme, icon: _this.props.icon, locale: _this.props.locale, required: _this.isRequired(property), readonly: _this.isReadOnly, dragula: _this.props.dragula, md: _this.props.md, hljs: _this.props.hljs, forceHttps: _this.props.forceHttps, disableCollapse: _this.props.disableCollapse, noSelect2: _this.props.noSelect2 });\n })\n : [];\n var filterElement = (!this.collapsed && this.value !== undefined && this.showFilter)\n ? React.createElement(\"div\", { className: this.props.theme.row },\n React.createElement(\"input\", { className: this.props.theme.input, onChange: this.onFilterChange, placeholder: this.props.locale.info.search, defaultValue: this.filter }))\n : null;\n return (React.createElement(\"div\", { className: this.className },\n React.createElement(\"h3\", null,\n this.titleToShow,\n React.createElement(\"div\", { className: this.props.theme.buttonGroup, style: common.buttonGroupStyle },\n React.createElement(Optional, { required: this.props.required, value: this.value, isReadOnly: this.isReadOnly, theme: this.props.theme, locale: this.props.locale, toggleOptional: this.toggleOptional }),\n React.createElement(Icon, { valid: !this.props.disableCollapse, onClick: this.collapseOrExpand, text: this.collapsed ? this.props.icon.expand : this.props.icon.collapse, theme: this.props.theme, icon: this.props.icon }),\n React.createElement(Icon, { valid: this.hasDeleteButtonFunction, onClick: this.props.onDelete, text: this.props.icon.delete, theme: this.props.theme, icon: this.props.icon }))),\n React.createElement(Description, { theme: this.props.theme, message: this.props.schema.description }),\n React.createElement(\"div\", { className: this.props.theme.card },\n filterElement,\n childrenElement),\n React.createElement(Description, { theme: this.props.theme, message: this.errorMessage })));\n };\n ObjectEditor.prototype.isRequired = function (property) {\n return common.isRequired(this.props.schema.required, this.value, this.props.schema, property);\n };\n ObjectEditor.prototype.validate = function () {\n this.errorMessage = common.getErrorMessageOfObject(this.value, this.props.schema, this.props.locale);\n };\n Object.defineProperty(ObjectEditor.prototype, \"isReadOnly\", {\n get: function () {\n return this.props.readonly || this.props.schema.readonly;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(ObjectEditor.prototype, \"hasDeleteButtonFunction\", {\n get: function () {\n return this.props.onDelete && !this.isReadOnly;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(ObjectEditor.prototype, \"titleToShow\", {\n get: function () {\n if (this.props.onDelete) {\n return common.getTitle(common.findTitle(this.value, this.properties), this.props.title, this.props.schema.title);\n }\n return common.getTitle(this.props.title, this.props.schema.title);\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(ObjectEditor.prototype, \"showFilter\", {\n get: function () {\n var _this = this;\n var propertyCount = this.properties.filter(function (p) { return _this.isRequired(p.property) !== false; }).length;\n var minItemCountIfNeedFilter = typeof this.props.minItemCountIfNeedFilter === 'number' ? this.props.minItemCountIfNeedFilter : common.minItemCountIfNeedFilter;\n return propertyCount >= minItemCountIfNeedFilter;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(ObjectEditor.prototype, \"className\", {\n get: function () {\n var rowClass = this.errorMessage ? this.props.theme.errorRow : this.props.theme.row;\n return this.props.schema.className ? rowClass + ' ' + this.props.schema.className : rowClass;\n },\n enumerable: true,\n configurable: true\n });\n return ObjectEditor;\n}(React.Component));\nexport { ObjectEditor };\n","/**\n * lodash (Custom Build) \n * Build: `lodash modularize exports=\"npm\" -o ./`\n * Copyright jQuery Foundation and other contributors \n * Released under MIT license \n * Based on Underscore.js 1.8.3 \n * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors\n */\n\n/** Used as references for various `Number` constants. */\nvar INFINITY = 1 / 0,\n MAX_INTEGER = 1.7976931348623157e+308,\n NAN = 0 / 0;\n\n/** `Object#toString` result references. */\nvar symbolTag = '[object Symbol]';\n\n/** Used to match leading and trailing whitespace. */\nvar reTrim = /^\\s+|\\s+$/g;\n\n/** Used to detect bad signed hexadecimal string values. */\nvar reIsBadHex = /^[-+]0x[0-9a-f]+$/i;\n\n/** Used to detect binary string values. */\nvar reIsBinary = /^0b[01]+$/i;\n\n/** Used to detect octal string values. */\nvar reIsOctal = /^0o[0-7]+$/i;\n\n/** Built-in method references without a dependency on `root`. */\nvar freeParseInt = parseInt;\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar objectToString = objectProto.toString;\n\n/**\n * Checks if `value` is an integer.\n *\n * **Note:** This method is based on\n * [`Number.isInteger`](https://mdn.io/Number/isInteger).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an integer, else `false`.\n * @example\n *\n * _.isInteger(3);\n * // => true\n *\n * _.isInteger(Number.MIN_VALUE);\n * // => false\n *\n * _.isInteger(Infinity);\n * // => false\n *\n * _.isInteger('3');\n * // => false\n */\nfunction isInteger(value) {\n return typeof value == 'number' && value == toInteger(value);\n}\n\n/**\n * Checks if `value` is the\n * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)\n * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an object, else `false`.\n * @example\n *\n * _.isObject({});\n * // => true\n *\n * _.isObject([1, 2, 3]);\n * // => true\n *\n * _.isObject(_.noop);\n * // => true\n *\n * _.isObject(null);\n * // => false\n */\nfunction isObject(value) {\n var type = typeof value;\n return !!value && (type == 'object' || type == 'function');\n}\n\n/**\n * Checks if `value` is object-like. A value is object-like if it's not `null`\n * and has a `typeof` result of \"object\".\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is object-like, else `false`.\n * @example\n *\n * _.isObjectLike({});\n * // => true\n *\n * _.isObjectLike([1, 2, 3]);\n * // => true\n *\n * _.isObjectLike(_.noop);\n * // => false\n *\n * _.isObjectLike(null);\n * // => false\n */\nfunction isObjectLike(value) {\n return !!value && typeof value == 'object';\n}\n\n/**\n * Checks if `value` is classified as a `Symbol` primitive or object.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a symbol, else `false`.\n * @example\n *\n * _.isSymbol(Symbol.iterator);\n * // => true\n *\n * _.isSymbol('abc');\n * // => false\n */\nfunction isSymbol(value) {\n return typeof value == 'symbol' ||\n (isObjectLike(value) && objectToString.call(value) == symbolTag);\n}\n\n/**\n * Converts `value` to a finite number.\n *\n * @static\n * @memberOf _\n * @since 4.12.0\n * @category Lang\n * @param {*} value The value to convert.\n * @returns {number} Returns the converted number.\n * @example\n *\n * _.toFinite(3.2);\n * // => 3.2\n *\n * _.toFinite(Number.MIN_VALUE);\n * // => 5e-324\n *\n * _.toFinite(Infinity);\n * // => 1.7976931348623157e+308\n *\n * _.toFinite('3.2');\n * // => 3.2\n */\nfunction toFinite(value) {\n if (!value) {\n return value === 0 ? value : 0;\n }\n value = toNumber(value);\n if (value === INFINITY || value === -INFINITY) {\n var sign = (value < 0 ? -1 : 1);\n return sign * MAX_INTEGER;\n }\n return value === value ? value : 0;\n}\n\n/**\n * Converts `value` to an integer.\n *\n * **Note:** This method is loosely based on\n * [`ToInteger`](http://www.ecma-international.org/ecma-262/7.0/#sec-tointeger).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to convert.\n * @returns {number} Returns the converted integer.\n * @example\n *\n * _.toInteger(3.2);\n * // => 3\n *\n * _.toInteger(Number.MIN_VALUE);\n * // => 0\n *\n * _.toInteger(Infinity);\n * // => 1.7976931348623157e+308\n *\n * _.toInteger('3.2');\n * // => 3\n */\nfunction toInteger(value) {\n var result = toFinite(value),\n remainder = result % 1;\n\n return result === result ? (remainder ? result - remainder : result) : 0;\n}\n\n/**\n * Converts `value` to a number.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to process.\n * @returns {number} Returns the number.\n * @example\n *\n * _.toNumber(3.2);\n * // => 3.2\n *\n * _.toNumber(Number.MIN_VALUE);\n * // => 5e-324\n *\n * _.toNumber(Infinity);\n * // => Infinity\n *\n * _.toNumber('3.2');\n * // => 3.2\n */\nfunction toNumber(value) {\n if (typeof value == 'number') {\n return value;\n }\n if (isSymbol(value)) {\n return NAN;\n }\n if (isObject(value)) {\n var other = typeof value.valueOf == 'function' ? value.valueOf() : value;\n value = isObject(other) ? (other + '') : other;\n }\n if (typeof value != 'string') {\n return value === 0 ? value : +value;\n }\n value = value.replace(reTrim, '');\n var isBinary = reIsBinary.test(value);\n return (isBinary || reIsOctal.test(value))\n ? freeParseInt(value.slice(2), isBinary ? 2 : 8)\n : (reIsBadHex.test(value) ? NAN : +value);\n}\n\nmodule.exports = isInteger;\n","/**\n * lodash 3.0.2 (Custom Build) \n * Build: `lodash modern modularize exports=\"npm\" -o ./`\n * Copyright 2012-2015 The Dojo Foundation \n * Based on Underscore.js 1.8.3 \n * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors\n * Available under MIT license \n */\n\n/**\n * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`.\n * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)\n *\n * @static\n * @memberOf _\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an object, else `false`.\n * @example\n *\n * _.isObject({});\n * // => true\n *\n * _.isObject([1, 2, 3]);\n * // => true\n *\n * _.isObject(1);\n * // => false\n */\nfunction isObject(value) {\n // Avoid a V8 JIT bug in Chrome 19-20.\n // See https://code.google.com/p/v8/issues/detail?id=2291 for more details.\n var type = typeof value;\n return !!value && (type == 'object' || type == 'function');\n}\n\nmodule.exports = isObject;\n","/**\n * lodash (Custom Build) \n * Build: `lodash modularize exports=\"npm\" -o ./`\n * Copyright jQuery Foundation and other contributors \n * Released under MIT license \n * Based on Underscore.js 1.8.3 \n * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors\n */\n\n/** Used as references for various `Number` constants. */\nvar INFINITY = 1 / 0,\n MAX_INTEGER = 1.7976931348623157e+308,\n NAN = 0 / 0;\n\n/** `Object#toString` result references. */\nvar symbolTag = '[object Symbol]';\n\n/** Used to match leading and trailing whitespace. */\nvar reTrim = /^\\s+|\\s+$/g;\n\n/** Used to detect bad signed hexadecimal string values. */\nvar reIsBadHex = /^[-+]0x[0-9a-f]+$/i;\n\n/** Used to detect binary string values. */\nvar reIsBinary = /^0b[01]+$/i;\n\n/** Used to detect octal string values. */\nvar reIsOctal = /^0o[0-7]+$/i;\n\n/** Built-in method references without a dependency on `root`. */\nvar freeParseInt = parseInt;\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar objectToString = objectProto.toString;\n\n/**\n * Checks if `value` is the\n * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)\n * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an object, else `false`.\n * @example\n *\n * _.isObject({});\n * // => true\n *\n * _.isObject([1, 2, 3]);\n * // => true\n *\n * _.isObject(_.noop);\n * // => true\n *\n * _.isObject(null);\n * // => false\n */\nfunction isObject(value) {\n var type = typeof value;\n return !!value && (type == 'object' || type == 'function');\n}\n\n/**\n * Checks if `value` is object-like. A value is object-like if it's not `null`\n * and has a `typeof` result of \"object\".\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is object-like, else `false`.\n * @example\n *\n * _.isObjectLike({});\n * // => true\n *\n * _.isObjectLike([1, 2, 3]);\n * // => true\n *\n * _.isObjectLike(_.noop);\n * // => false\n *\n * _.isObjectLike(null);\n * // => false\n */\nfunction isObjectLike(value) {\n return !!value && typeof value == 'object';\n}\n\n/**\n * Checks if `value` is classified as a `Symbol` primitive or object.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a symbol, else `false`.\n * @example\n *\n * _.isSymbol(Symbol.iterator);\n * // => true\n *\n * _.isSymbol('abc');\n * // => false\n */\nfunction isSymbol(value) {\n return typeof value == 'symbol' ||\n (isObjectLike(value) && objectToString.call(value) == symbolTag);\n}\n\n/**\n * Converts `value` to a finite number.\n *\n * @static\n * @memberOf _\n * @since 4.12.0\n * @category Lang\n * @param {*} value The value to convert.\n * @returns {number} Returns the converted number.\n * @example\n *\n * _.toFinite(3.2);\n * // => 3.2\n *\n * _.toFinite(Number.MIN_VALUE);\n * // => 5e-324\n *\n * _.toFinite(Infinity);\n * // => 1.7976931348623157e+308\n *\n * _.toFinite('3.2');\n * // => 3.2\n */\nfunction toFinite(value) {\n if (!value) {\n return value === 0 ? value : 0;\n }\n value = toNumber(value);\n if (value === INFINITY || value === -INFINITY) {\n var sign = (value < 0 ? -1 : 1);\n return sign * MAX_INTEGER;\n }\n return value === value ? value : 0;\n}\n\n/**\n * Converts `value` to an integer.\n *\n * **Note:** This method is loosely based on\n * [`ToInteger`](http://www.ecma-international.org/ecma-262/7.0/#sec-tointeger).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to convert.\n * @returns {number} Returns the converted integer.\n * @example\n *\n * _.toInteger(3.2);\n * // => 3\n *\n * _.toInteger(Number.MIN_VALUE);\n * // => 0\n *\n * _.toInteger(Infinity);\n * // => 1.7976931348623157e+308\n *\n * _.toInteger('3.2');\n * // => 3\n */\nfunction toInteger(value) {\n var result = toFinite(value),\n remainder = result % 1;\n\n return result === result ? (remainder ? result - remainder : result) : 0;\n}\n\n/**\n * Converts `value` to a number.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to process.\n * @returns {number} Returns the number.\n * @example\n *\n * _.toNumber(3.2);\n * // => 3.2\n *\n * _.toNumber(Number.MIN_VALUE);\n * // => 5e-324\n *\n * _.toNumber(Infinity);\n * // => Infinity\n *\n * _.toNumber('3.2');\n * // => 3.2\n */\nfunction toNumber(value) {\n if (typeof value == 'number') {\n return value;\n }\n if (isSymbol(value)) {\n return NAN;\n }\n if (isObject(value)) {\n var other = typeof value.valueOf == 'function' ? value.valueOf() : value;\n value = isObject(other) ? (other + '') : other;\n }\n if (typeof value != 'string') {\n return value === 0 ? value : +value;\n }\n value = value.replace(reTrim, '');\n var isBinary = reIsBinary.test(value);\n return (isBinary || reIsOctal.test(value))\n ? freeParseInt(value.slice(2), isBinary ? 2 : 8)\n : (reIsBadHex.test(value) ? NAN : +value);\n}\n\nmodule.exports = toInteger;\n","/**\n * lodash (Custom Build) \n * Build: `lodash modularize exports=\"npm\" -o ./`\n * Copyright jQuery Foundation and other contributors \n * Released under MIT license \n * Based on Underscore.js 1.8.3 \n * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors\n */\n\n/** Used as references for various `Number` constants. */\nvar NAN = 0 / 0;\n\n/** `Object#toString` result references. */\nvar symbolTag = '[object Symbol]';\n\n/** Used to match leading and trailing whitespace. */\nvar reTrim = /^\\s+|\\s+$/g;\n\n/** Used to detect bad signed hexadecimal string values. */\nvar reIsBadHex = /^[-+]0x[0-9a-f]+$/i;\n\n/** Used to detect binary string values. */\nvar reIsBinary = /^0b[01]+$/i;\n\n/** Used to detect octal string values. */\nvar reIsOctal = /^0o[0-7]+$/i;\n\n/** Built-in method references without a dependency on `root`. */\nvar freeParseInt = parseInt;\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar objectToString = objectProto.toString;\n\n/**\n * Checks if `value` is the\n * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)\n * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an object, else `false`.\n * @example\n *\n * _.isObject({});\n * // => true\n *\n * _.isObject([1, 2, 3]);\n * // => true\n *\n * _.isObject(_.noop);\n * // => true\n *\n * _.isObject(null);\n * // => false\n */\nfunction isObject(value) {\n var type = typeof value;\n return !!value && (type == 'object' || type == 'function');\n}\n\n/**\n * Checks if `value` is object-like. A value is object-like if it's not `null`\n * and has a `typeof` result of \"object\".\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is object-like, else `false`.\n * @example\n *\n * _.isObjectLike({});\n * // => true\n *\n * _.isObjectLike([1, 2, 3]);\n * // => true\n *\n * _.isObjectLike(_.noop);\n * // => false\n *\n * _.isObjectLike(null);\n * // => false\n */\nfunction isObjectLike(value) {\n return !!value && typeof value == 'object';\n}\n\n/**\n * Checks if `value` is classified as a `Symbol` primitive or object.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a symbol, else `false`.\n * @example\n *\n * _.isSymbol(Symbol.iterator);\n * // => true\n *\n * _.isSymbol('abc');\n * // => false\n */\nfunction isSymbol(value) {\n return typeof value == 'symbol' ||\n (isObjectLike(value) && objectToString.call(value) == symbolTag);\n}\n\n/**\n * Converts `value` to a number.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to process.\n * @returns {number} Returns the number.\n * @example\n *\n * _.toNumber(3.2);\n * // => 3.2\n *\n * _.toNumber(Number.MIN_VALUE);\n * // => 5e-324\n *\n * _.toNumber(Infinity);\n * // => Infinity\n *\n * _.toNumber('3.2');\n * // => 3.2\n */\nfunction toNumber(value) {\n if (typeof value == 'number') {\n return value;\n }\n if (isSymbol(value)) {\n return NAN;\n }\n if (isObject(value)) {\n var other = typeof value.valueOf == 'function' ? value.valueOf() : value;\n value = isObject(other) ? (other + '') : other;\n }\n if (typeof value != 'string') {\n return value === 0 ? value : +value;\n }\n value = value.replace(reTrim, '');\n var isBinary = reIsBinary.test(value);\n return (isBinary || reIsOctal.test(value))\n ? freeParseInt(value.slice(2), isBinary ? 2 : 8)\n : (reIsBadHex.test(value) ? NAN : +value);\n}\n\nmodule.exports = toNumber;\n","import * as tslib_1 from \"tslib\";\nimport * as React from 'react';\nimport * as common from 'schema-based-json-editor';\nexport * from 'schema-based-json-editor';\nimport { Editor } from './editor';\n/**\n * @public\n */\nvar JSONEditor = /** @class */ (function (_super) {\n tslib_1.__extends(JSONEditor, _super);\n function JSONEditor(props) {\n var _this = _super.call(this, props) || this;\n _this.updateValue = function (value, isValid) {\n _this.props.updateValue(value, isValid);\n };\n _this.md = common.initializeMarkdown(_this.props.markdownit, _this.props.hljs, _this.props.forceHttps);\n return _this;\n }\n JSONEditor.prototype.render = function () {\n var theme = common.getTheme(this.props.theme);\n var locale = common.getLocale(this.props.locale);\n var icon = common.getIcon(this.props.icon, locale);\n return React.createElement(Editor, { schema: this.props.schema, initialValue: this.props.initialValue, updateValue: this.updateValue, readonly: this.props.readonly, theme: theme, locale: locale, icon: icon, required: true, dragula: this.props.dragula, md: this.md, hljs: this.props.hljs, forceHttps: this.props.forceHttps, disableCollapse: this.props.disableCollapse, noSelect2: this.props.noSelect2, minItemCountIfNeedFilter: this.props.minItemCountIfNeedFilter });\n };\n return JSONEditor;\n}(React.Component));\nexport { JSONEditor };\n","'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n\tvalue: true\n});\n\nvar _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; };\n\nvar _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; }; }();\n\nvar _react = require('react');\n\nvar _react2 = _interopRequireDefault(_react);\n\nvar _propTypes = require('prop-types');\n\nvar _propTypes2 = _interopRequireDefault(_propTypes);\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction _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; }\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _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; }\n\nfunction _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; }\n\nvar sizerStyle = {\n\tposition: 'absolute',\n\ttop: 0,\n\tleft: 0,\n\tvisibility: 'hidden',\n\theight: 0,\n\toverflow: 'scroll',\n\twhiteSpace: 'pre'\n};\n\nvar INPUT_PROPS_BLACKLIST = ['extraWidth', 'injectStyles', 'inputClassName', 'inputRef', 'inputStyle', 'minWidth', 'onAutosize', 'placeholderIsMinWidth'];\n\nvar cleanInputProps = function cleanInputProps(inputProps) {\n\tINPUT_PROPS_BLACKLIST.forEach(function (field) {\n\t\treturn delete inputProps[field];\n\t});\n\treturn inputProps;\n};\n\nvar copyStyles = function copyStyles(styles, node) {\n\tnode.style.fontSize = styles.fontSize;\n\tnode.style.fontFamily = styles.fontFamily;\n\tnode.style.fontWeight = styles.fontWeight;\n\tnode.style.fontStyle = styles.fontStyle;\n\tnode.style.letterSpacing = styles.letterSpacing;\n\tnode.style.textTransform = styles.textTransform;\n};\n\nvar isIE = typeof window !== 'undefined' && window.navigator ? /MSIE |Trident\\/|Edge\\//.test(window.navigator.userAgent) : false;\n\nvar generateId = function generateId() {\n\t// we only need an auto-generated ID for stylesheet injection, which is only\n\t// used for IE. so if the browser is not IE, this should return undefined.\n\treturn isIE ? '_' + Math.random().toString(36).substr(2, 12) : undefined;\n};\n\nvar AutosizeInput = function (_Component) {\n\t_inherits(AutosizeInput, _Component);\n\n\tfunction AutosizeInput(props) {\n\t\t_classCallCheck(this, AutosizeInput);\n\n\t\tvar _this = _possibleConstructorReturn(this, (AutosizeInput.__proto__ || Object.getPrototypeOf(AutosizeInput)).call(this, props));\n\n\t\t_this.inputRef = function (el) {\n\t\t\t_this.input = el;\n\t\t\tif (typeof _this.props.inputRef === 'function') {\n\t\t\t\t_this.props.inputRef(el);\n\t\t\t}\n\t\t};\n\n\t\t_this.placeHolderSizerRef = function (el) {\n\t\t\t_this.placeHolderSizer = el;\n\t\t};\n\n\t\t_this.sizerRef = function (el) {\n\t\t\t_this.sizer = el;\n\t\t};\n\n\t\t_this.state = {\n\t\t\tinputWidth: props.minWidth,\n\t\t\tinputId: props.id || generateId()\n\t\t};\n\t\treturn _this;\n\t}\n\n\t_createClass(AutosizeInput, [{\n\t\tkey: 'componentDidMount',\n\t\tvalue: function componentDidMount() {\n\t\t\tthis.mounted = true;\n\t\t\tthis.copyInputStyles();\n\t\t\tthis.updateInputWidth();\n\t\t}\n\t}, {\n\t\tkey: 'componentWillReceiveProps',\n\t\tvalue: function componentWillReceiveProps(nextProps) {\n\t\t\tvar id = nextProps.id;\n\n\t\t\tif (id !== this.props.id) {\n\t\t\t\tthis.setState({ inputId: id || generateId() });\n\t\t\t}\n\t\t}\n\t}, {\n\t\tkey: 'componentDidUpdate',\n\t\tvalue: function componentDidUpdate(prevProps, prevState) {\n\t\t\tif (prevState.inputWidth !== this.state.inputWidth) {\n\t\t\t\tif (typeof this.props.onAutosize === 'function') {\n\t\t\t\t\tthis.props.onAutosize(this.state.inputWidth);\n\t\t\t\t}\n\t\t\t}\n\t\t\tthis.updateInputWidth();\n\t\t}\n\t}, {\n\t\tkey: 'componentWillUnmount',\n\t\tvalue: function componentWillUnmount() {\n\t\t\tthis.mounted = false;\n\t\t}\n\t}, {\n\t\tkey: 'copyInputStyles',\n\t\tvalue: function copyInputStyles() {\n\t\t\tif (!this.mounted || !window.getComputedStyle) {\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tvar inputStyles = this.input && window.getComputedStyle(this.input);\n\t\t\tif (!inputStyles) {\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tcopyStyles(inputStyles, this.sizer);\n\t\t\tif (this.placeHolderSizer) {\n\t\t\t\tcopyStyles(inputStyles, this.placeHolderSizer);\n\t\t\t}\n\t\t}\n\t}, {\n\t\tkey: 'updateInputWidth',\n\t\tvalue: function updateInputWidth() {\n\t\t\tif (!this.mounted || !this.sizer || typeof this.sizer.scrollWidth === 'undefined') {\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tvar newInputWidth = void 0;\n\t\t\tif (this.props.placeholder && (!this.props.value || this.props.value && this.props.placeholderIsMinWidth)) {\n\t\t\t\tnewInputWidth = Math.max(this.sizer.scrollWidth, this.placeHolderSizer.scrollWidth) + 2;\n\t\t\t} else {\n\t\t\t\tnewInputWidth = this.sizer.scrollWidth + 2;\n\t\t\t}\n\t\t\t// add extraWidth to the detected width. for number types, this defaults to 16 to allow for the stepper UI\n\t\t\tvar extraWidth = this.props.type === 'number' && this.props.extraWidth === undefined ? 16 : parseInt(this.props.extraWidth) || 0;\n\t\t\tnewInputWidth += extraWidth;\n\t\t\tif (newInputWidth < this.props.minWidth) {\n\t\t\t\tnewInputWidth = this.props.minWidth;\n\t\t\t}\n\t\t\tif (newInputWidth !== this.state.inputWidth) {\n\t\t\t\tthis.setState({\n\t\t\t\t\tinputWidth: newInputWidth\n\t\t\t\t});\n\t\t\t}\n\t\t}\n\t}, {\n\t\tkey: 'getInput',\n\t\tvalue: function getInput() {\n\t\t\treturn this.input;\n\t\t}\n\t}, {\n\t\tkey: 'focus',\n\t\tvalue: function focus() {\n\t\t\tthis.input.focus();\n\t\t}\n\t}, {\n\t\tkey: 'blur',\n\t\tvalue: function blur() {\n\t\t\tthis.input.blur();\n\t\t}\n\t}, {\n\t\tkey: 'select',\n\t\tvalue: function select() {\n\t\t\tthis.input.select();\n\t\t}\n\t}, {\n\t\tkey: 'renderStyles',\n\t\tvalue: function renderStyles() {\n\t\t\t// this method injects styles to hide IE's clear indicator, which messes\n\t\t\t// with input size detection. the stylesheet is only injected when the\n\t\t\t// browser is IE, and can also be disabled by the `injectStyles` prop.\n\t\t\tvar injectStyles = this.props.injectStyles;\n\n\t\t\treturn isIE && injectStyles ? _react2.default.createElement('style', { dangerouslySetInnerHTML: {\n\t\t\t\t\t__html: 'input#' + this.state.inputId + '::-ms-clear {display: none;}'\n\t\t\t\t} }) : null;\n\t\t}\n\t}, {\n\t\tkey: 'render',\n\t\tvalue: function render() {\n\t\t\tvar sizerValue = [this.props.defaultValue, this.props.value, ''].reduce(function (previousValue, currentValue) {\n\t\t\t\tif (previousValue !== null && previousValue !== undefined) {\n\t\t\t\t\treturn previousValue;\n\t\t\t\t}\n\t\t\t\treturn currentValue;\n\t\t\t});\n\n\t\t\tvar wrapperStyle = _extends({}, this.props.style);\n\t\t\tif (!wrapperStyle.display) wrapperStyle.display = 'inline-block';\n\n\t\t\tvar inputStyle = _extends({\n\t\t\t\tboxSizing: 'content-box',\n\t\t\t\twidth: this.state.inputWidth + 'px'\n\t\t\t}, this.props.inputStyle);\n\n\t\t\tvar inputProps = _objectWithoutProperties(this.props, []);\n\n\t\t\tcleanInputProps(inputProps);\n\t\t\tinputProps.className = this.props.inputClassName;\n\t\t\tinputProps.id = this.state.inputId;\n\t\t\tinputProps.style = inputStyle;\n\n\t\t\treturn _react2.default.createElement(\n\t\t\t\t'div',\n\t\t\t\t{ className: this.props.className, style: wrapperStyle },\n\t\t\t\tthis.renderStyles(),\n\t\t\t\t_react2.default.createElement('input', _extends({}, inputProps, { ref: this.inputRef })),\n\t\t\t\t_react2.default.createElement(\n\t\t\t\t\t'div',\n\t\t\t\t\t{ ref: this.sizerRef, style: sizerStyle },\n\t\t\t\t\tsizerValue\n\t\t\t\t),\n\t\t\t\tthis.props.placeholder ? _react2.default.createElement(\n\t\t\t\t\t'div',\n\t\t\t\t\t{ ref: this.placeHolderSizerRef, style: sizerStyle },\n\t\t\t\t\tthis.props.placeholder\n\t\t\t\t) : null\n\t\t\t);\n\t\t}\n\t}]);\n\n\treturn AutosizeInput;\n}(_react.Component);\n\nAutosizeInput.propTypes = {\n\tclassName: _propTypes2.default.string, // className for the outer element\n\tdefaultValue: _propTypes2.default.any, // default field value\n\textraWidth: _propTypes2.default.oneOfType([// additional width for input element\n\t_propTypes2.default.number, _propTypes2.default.string]),\n\tid: _propTypes2.default.string, // id to use for the input, can be set for consistent snapshots\n\tinjectStyles: _propTypes2.default.bool, // inject the custom stylesheet to hide clear UI, defaults to true\n\tinputClassName: _propTypes2.default.string, // className for the input element\n\tinputRef: _propTypes2.default.func, // ref callback for the input element\n\tinputStyle: _propTypes2.default.object, // css styles for the input element\n\tminWidth: _propTypes2.default.oneOfType([// minimum width for input element\n\t_propTypes2.default.number, _propTypes2.default.string]),\n\tonAutosize: _propTypes2.default.func, // onAutosize handler: function(newWidth) {}\n\tonChange: _propTypes2.default.func, // onChange handler: function(event) {}\n\tplaceholder: _propTypes2.default.string, // placeholder text\n\tplaceholderIsMinWidth: _propTypes2.default.bool, // don't collapse size to less than the placeholder\n\tstyle: _propTypes2.default.object, // css styles for the outer element\n\tvalue: _propTypes2.default.any // field value\n};\nAutosizeInput.defaultProps = {\n\tminWidth: 1,\n\tinjectStyles: true\n};\n\nexports.default = AutosizeInput;","import AutosizeInput from 'react-input-autosize';\nimport classNames from 'classnames';\nimport PropTypes from 'prop-types';\nimport React, { Component } from 'react';\nimport { findDOMNode } from 'react-dom';\n\nvar arrowRenderer = function arrowRenderer(_ref) {\n\tvar onMouseDown = _ref.onMouseDown;\n\n\treturn React.createElement('span', {\n\t\tclassName: 'Select-arrow',\n\t\tonMouseDown: onMouseDown\n\t});\n};\n\narrowRenderer.propTypes = {\n\tonMouseDown: PropTypes.func\n};\n\nvar clearRenderer = function clearRenderer() {\n\treturn React.createElement('span', {\n\t\tclassName: 'Select-clear',\n\t\tdangerouslySetInnerHTML: { __html: '×' }\n\t});\n};\n\nvar 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 }];\n\nvar stripDiacritics = function stripDiacritics(str) {\n\tfor (var i = 0; i < map.length; i++) {\n\t\tstr = str.replace(map[i].letters, map[i].base);\n\t}\n\treturn str;\n};\n\nvar trim = function trim(str) {\n return str.replace(/^\\s+|\\s+$/g, '');\n};\n\nvar isValid = function isValid(value) {\n\treturn typeof value !== 'undefined' && value !== null && value !== '';\n};\n\nvar filterOptions = function filterOptions(options, filterValue, excludeOptions, props) {\n\tif (props.ignoreAccents) {\n\t\tfilterValue = stripDiacritics(filterValue);\n\t}\n\n\tif (props.ignoreCase) {\n\t\tfilterValue = filterValue.toLowerCase();\n\t}\n\n\tif (props.trimFilter) {\n\t\tfilterValue = trim(filterValue);\n\t}\n\n\tif (excludeOptions) excludeOptions = excludeOptions.map(function (i) {\n\t\treturn i[props.valueKey];\n\t});\n\n\treturn options.filter(function (option) {\n\t\tif (excludeOptions && excludeOptions.indexOf(option[props.valueKey]) > -1) return false;\n\t\tif (props.filterOption) return props.filterOption.call(undefined, option, filterValue);\n\t\tif (!filterValue) return true;\n\n\t\tvar value = option[props.valueKey];\n\t\tvar label = option[props.labelKey];\n\t\tvar hasValue = isValid(value);\n\t\tvar hasLabel = isValid(label);\n\n\t\tif (!hasValue && !hasLabel) {\n\t\t\treturn false;\n\t\t}\n\n\t\tvar valueTest = hasValue ? String(value) : null;\n\t\tvar labelTest = hasLabel ? String(label) : null;\n\n\t\tif (props.ignoreAccents) {\n\t\t\tif (valueTest && props.matchProp !== 'label') valueTest = stripDiacritics(valueTest);\n\t\t\tif (labelTest && props.matchProp !== 'value') labelTest = stripDiacritics(labelTest);\n\t\t}\n\n\t\tif (props.ignoreCase) {\n\t\t\tif (valueTest && props.matchProp !== 'label') valueTest = valueTest.toLowerCase();\n\t\t\tif (labelTest && props.matchProp !== 'value') labelTest = labelTest.toLowerCase();\n\t\t}\n\n\t\treturn 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;\n\t});\n};\n\nvar menuRenderer = function menuRenderer(_ref) {\n\tvar focusedOption = _ref.focusedOption,\n\t focusOption = _ref.focusOption,\n\t inputValue = _ref.inputValue,\n\t instancePrefix = _ref.instancePrefix,\n\t onFocus = _ref.onFocus,\n\t onOptionRef = _ref.onOptionRef,\n\t onSelect = _ref.onSelect,\n\t optionClassName = _ref.optionClassName,\n\t optionComponent = _ref.optionComponent,\n\t optionRenderer = _ref.optionRenderer,\n\t options = _ref.options,\n\t removeValue = _ref.removeValue,\n\t selectValue = _ref.selectValue,\n\t valueArray = _ref.valueArray,\n\t valueKey = _ref.valueKey;\n\n\tvar Option = optionComponent;\n\n\treturn options.map(function (option, i) {\n\t\tvar isSelected = valueArray && valueArray.some(function (x) {\n\t\t\treturn x[valueKey] === option[valueKey];\n\t\t});\n\t\tvar isFocused = option === focusedOption;\n\t\tvar optionClass = classNames(optionClassName, {\n\t\t\t'Select-option': true,\n\t\t\t'is-selected': isSelected,\n\t\t\t'is-focused': isFocused,\n\t\t\t'is-disabled': option.disabled\n\t\t});\n\n\t\treturn React.createElement(\n\t\t\tOption,\n\t\t\t{\n\t\t\t\tclassName: optionClass,\n\t\t\t\tfocusOption: focusOption,\n\t\t\t\tinputValue: inputValue,\n\t\t\t\tinstancePrefix: instancePrefix,\n\t\t\t\tisDisabled: option.disabled,\n\t\t\t\tisFocused: isFocused,\n\t\t\t\tisSelected: isSelected,\n\t\t\t\tkey: 'option-' + i + '-' + option[valueKey],\n\t\t\t\tonFocus: onFocus,\n\t\t\t\tonSelect: onSelect,\n\t\t\t\toption: option,\n\t\t\t\toptionIndex: i,\n\t\t\t\tref: function ref(_ref2) {\n\t\t\t\t\tonOptionRef(_ref2, isFocused);\n\t\t\t\t},\n\t\t\t\tremoveValue: removeValue,\n\t\t\t\tselectValue: selectValue\n\t\t\t},\n\t\t\toptionRenderer(option, i, inputValue)\n\t\t);\n\t});\n};\n\nmenuRenderer.propTypes = {\n\tfocusOption: PropTypes.func,\n\tfocusedOption: PropTypes.object,\n\tinputValue: PropTypes.string,\n\tinstancePrefix: PropTypes.string,\n\tonFocus: PropTypes.func,\n\tonOptionRef: PropTypes.func,\n\tonSelect: PropTypes.func,\n\toptionClassName: PropTypes.string,\n\toptionComponent: PropTypes.func,\n\toptionRenderer: PropTypes.func,\n\toptions: PropTypes.array,\n\tremoveValue: PropTypes.func,\n\tselectValue: PropTypes.func,\n\tvalueArray: PropTypes.array,\n\tvalueKey: PropTypes.string\n};\n\nvar blockEvent = (function (event) {\n\tevent.preventDefault();\n\tevent.stopPropagation();\n\tif (event.target.tagName !== 'A' || !('href' in event.target)) {\n\t\treturn;\n\t}\n\tif (event.target.target) {\n\t\twindow.open(event.target.href, event.target.target);\n\t} else {\n\t\twindow.location.href = event.target.href;\n\t}\n});\n\nvar _typeof = typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\" ? function (obj) {\n return typeof obj;\n} : function (obj) {\n return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj;\n};\n\n\n\n\n\nvar asyncGenerator = function () {\n function AwaitValue(value) {\n this.value = value;\n }\n\n function AsyncGenerator(gen) {\n var front, back;\n\n function send(key, arg) {\n return new Promise(function (resolve, reject) {\n var request = {\n key: key,\n arg: arg,\n resolve: resolve,\n reject: reject,\n next: null\n };\n\n if (back) {\n back = back.next = request;\n } else {\n front = back = request;\n resume(key, arg);\n }\n });\n }\n\n function resume(key, arg) {\n try {\n var result = gen[key](arg);\n var value = result.value;\n\n if (value instanceof AwaitValue) {\n Promise.resolve(value.value).then(function (arg) {\n resume(\"next\", arg);\n }, function (arg) {\n resume(\"throw\", arg);\n });\n } else {\n settle(result.done ? \"return\" : \"normal\", result.value);\n }\n } catch (err) {\n settle(\"throw\", err);\n }\n }\n\n function settle(type, value) {\n switch (type) {\n case \"return\":\n front.resolve({\n value: value,\n done: true\n });\n break;\n\n case \"throw\":\n front.reject(value);\n break;\n\n default:\n front.resolve({\n value: value,\n done: false\n });\n break;\n }\n\n front = front.next;\n\n if (front) {\n resume(front.key, front.arg);\n } else {\n back = null;\n }\n }\n\n this._invoke = send;\n\n if (typeof gen.return !== \"function\") {\n this.return = undefined;\n }\n }\n\n if (typeof Symbol === \"function\" && Symbol.asyncIterator) {\n AsyncGenerator.prototype[Symbol.asyncIterator] = function () {\n return this;\n };\n }\n\n AsyncGenerator.prototype.next = function (arg) {\n return this._invoke(\"next\", arg);\n };\n\n AsyncGenerator.prototype.throw = function (arg) {\n return this._invoke(\"throw\", arg);\n };\n\n AsyncGenerator.prototype.return = function (arg) {\n return this._invoke(\"return\", arg);\n };\n\n return {\n wrap: function (fn) {\n return function () {\n return new AsyncGenerator(fn.apply(this, arguments));\n };\n },\n await: function (value) {\n return new AwaitValue(value);\n }\n };\n}();\n\n\n\n\n\nvar classCallCheck = function (instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n};\n\nvar createClass = function () {\n function defineProperties(target, props) {\n for (var i = 0; i < props.length; i++) {\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n Object.defineProperty(target, descriptor.key, descriptor);\n }\n }\n\n return function (Constructor, protoProps, staticProps) {\n if (protoProps) defineProperties(Constructor.prototype, protoProps);\n if (staticProps) defineProperties(Constructor, staticProps);\n return Constructor;\n };\n}();\n\n\n\n\n\nvar defineProperty = function (obj, key, value) {\n if (key in obj) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n } else {\n obj[key] = value;\n }\n\n return obj;\n};\n\nvar _extends = Object.assign || function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n\n return target;\n};\n\n\n\nvar inherits = function (subClass, superClass) {\n if (typeof superClass !== \"function\" && superClass !== null) {\n throw new TypeError(\"Super expression must either be null or a function, not \" + typeof superClass);\n }\n\n subClass.prototype = Object.create(superClass && superClass.prototype, {\n constructor: {\n value: subClass,\n enumerable: false,\n writable: true,\n configurable: true\n }\n });\n if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass;\n};\n\n\n\n\n\n\n\n\n\nvar objectWithoutProperties = function (obj, keys) {\n var target = {};\n\n for (var i in obj) {\n if (keys.indexOf(i) >= 0) continue;\n if (!Object.prototype.hasOwnProperty.call(obj, i)) continue;\n target[i] = obj[i];\n }\n\n return target;\n};\n\nvar possibleConstructorReturn = function (self, call) {\n if (!self) {\n throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\");\n }\n\n return call && (typeof call === \"object\" || typeof call === \"function\") ? call : self;\n};\n\nvar Option = function (_React$Component) {\n\tinherits(Option, _React$Component);\n\n\tfunction Option(props) {\n\t\tclassCallCheck(this, Option);\n\n\t\tvar _this = possibleConstructorReturn(this, (Option.__proto__ || Object.getPrototypeOf(Option)).call(this, props));\n\n\t\t_this.handleMouseDown = _this.handleMouseDown.bind(_this);\n\t\t_this.handleMouseEnter = _this.handleMouseEnter.bind(_this);\n\t\t_this.handleMouseMove = _this.handleMouseMove.bind(_this);\n\t\t_this.handleTouchStart = _this.handleTouchStart.bind(_this);\n\t\t_this.handleTouchEnd = _this.handleTouchEnd.bind(_this);\n\t\t_this.handleTouchMove = _this.handleTouchMove.bind(_this);\n\t\t_this.onFocus = _this.onFocus.bind(_this);\n\t\treturn _this;\n\t}\n\n\tcreateClass(Option, [{\n\t\tkey: 'handleMouseDown',\n\t\tvalue: function handleMouseDown(event) {\n\t\t\tevent.preventDefault();\n\t\t\tevent.stopPropagation();\n\t\t\tthis.props.onSelect(this.props.option, event);\n\t\t}\n\t}, {\n\t\tkey: 'handleMouseEnter',\n\t\tvalue: function handleMouseEnter(event) {\n\t\t\tthis.onFocus(event);\n\t\t}\n\t}, {\n\t\tkey: 'handleMouseMove',\n\t\tvalue: function handleMouseMove(event) {\n\t\t\tthis.onFocus(event);\n\t\t}\n\t}, {\n\t\tkey: 'handleTouchEnd',\n\t\tvalue: function handleTouchEnd(event) {\n\t\t\t// Check if the view is being dragged, In this case\n\t\t\t// we don't want to fire the click event (because the user only wants to scroll)\n\t\t\tif (this.dragging) return;\n\n\t\t\tthis.handleMouseDown(event);\n\t\t}\n\t}, {\n\t\tkey: 'handleTouchMove',\n\t\tvalue: function handleTouchMove() {\n\t\t\t// Set a flag that the view is being dragged\n\t\t\tthis.dragging = true;\n\t\t}\n\t}, {\n\t\tkey: 'handleTouchStart',\n\t\tvalue: function handleTouchStart() {\n\t\t\t// Set a flag that the view is not being dragged\n\t\t\tthis.dragging = false;\n\t\t}\n\t}, {\n\t\tkey: 'onFocus',\n\t\tvalue: function onFocus(event) {\n\t\t\tif (!this.props.isFocused) {\n\t\t\t\tthis.props.onFocus(this.props.option, event);\n\t\t\t}\n\t\t}\n\t}, {\n\t\tkey: 'render',\n\t\tvalue: function render() {\n\t\t\tvar _props = this.props,\n\t\t\t option = _props.option,\n\t\t\t instancePrefix = _props.instancePrefix,\n\t\t\t optionIndex = _props.optionIndex;\n\n\t\t\tvar className = classNames(this.props.className, option.className);\n\n\t\t\treturn option.disabled ? React.createElement(\n\t\t\t\t'div',\n\t\t\t\t{ className: className,\n\t\t\t\t\tonMouseDown: blockEvent,\n\t\t\t\t\tonClick: blockEvent },\n\t\t\t\tthis.props.children\n\t\t\t) : React.createElement(\n\t\t\t\t'div',\n\t\t\t\t{ className: className,\n\t\t\t\t\tstyle: option.style,\n\t\t\t\t\trole: 'option',\n\t\t\t\t\t'aria-label': option.label,\n\t\t\t\t\tonMouseDown: this.handleMouseDown,\n\t\t\t\t\tonMouseEnter: this.handleMouseEnter,\n\t\t\t\t\tonMouseMove: this.handleMouseMove,\n\t\t\t\t\tonTouchStart: this.handleTouchStart,\n\t\t\t\t\tonTouchMove: this.handleTouchMove,\n\t\t\t\t\tonTouchEnd: this.handleTouchEnd,\n\t\t\t\t\tid: instancePrefix + '-option-' + optionIndex,\n\t\t\t\t\ttitle: option.title },\n\t\t\t\tthis.props.children\n\t\t\t);\n\t\t}\n\t}]);\n\treturn Option;\n}(React.Component);\n\nOption.propTypes = {\n\tchildren: PropTypes.node,\n\tclassName: PropTypes.string, // className (based on mouse position)\n\tinstancePrefix: PropTypes.string.isRequired, // unique prefix for the ids (used for aria)\n\tisDisabled: PropTypes.bool, // the option is disabled\n\tisFocused: PropTypes.bool, // the option is focused\n\tisSelected: PropTypes.bool, // the option is selected\n\tonFocus: PropTypes.func, // method to handle mouseEnter on option element\n\tonSelect: PropTypes.func, // method to handle click on option element\n\tonUnfocus: PropTypes.func, // method to handle mouseLeave on option element\n\toption: PropTypes.object.isRequired, // object that is base for that option\n\toptionIndex: PropTypes.number // index of the option, used to generate unique ids for aria\n};\n\nvar Value = function (_React$Component) {\n\tinherits(Value, _React$Component);\n\n\tfunction Value(props) {\n\t\tclassCallCheck(this, Value);\n\n\t\tvar _this = possibleConstructorReturn(this, (Value.__proto__ || Object.getPrototypeOf(Value)).call(this, props));\n\n\t\t_this.handleMouseDown = _this.handleMouseDown.bind(_this);\n\t\t_this.onRemove = _this.onRemove.bind(_this);\n\t\t_this.handleTouchEndRemove = _this.handleTouchEndRemove.bind(_this);\n\t\t_this.handleTouchMove = _this.handleTouchMove.bind(_this);\n\t\t_this.handleTouchStart = _this.handleTouchStart.bind(_this);\n\t\treturn _this;\n\t}\n\n\tcreateClass(Value, [{\n\t\tkey: 'handleMouseDown',\n\t\tvalue: function handleMouseDown(event) {\n\t\t\tif (event.type === 'mousedown' && event.button !== 0) {\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tif (this.props.onClick) {\n\t\t\t\tevent.stopPropagation();\n\t\t\t\tthis.props.onClick(this.props.value, event);\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tif (this.props.value.href) {\n\t\t\t\tevent.stopPropagation();\n\t\t\t}\n\t\t}\n\t}, {\n\t\tkey: 'onRemove',\n\t\tvalue: function onRemove(event) {\n\t\t\tevent.preventDefault();\n\t\t\tevent.stopPropagation();\n\t\t\tthis.props.onRemove(this.props.value);\n\t\t}\n\t}, {\n\t\tkey: 'handleTouchEndRemove',\n\t\tvalue: function handleTouchEndRemove(event) {\n\t\t\t// Check if the view is being dragged, In this case\n\t\t\t// we don't want to fire the click event (because the user only wants to scroll)\n\t\t\tif (this.dragging) return;\n\n\t\t\t// Fire the mouse events\n\t\t\tthis.onRemove(event);\n\t\t}\n\t}, {\n\t\tkey: 'handleTouchMove',\n\t\tvalue: function handleTouchMove() {\n\t\t\t// Set a flag that the view is being dragged\n\t\t\tthis.dragging = true;\n\t\t}\n\t}, {\n\t\tkey: 'handleTouchStart',\n\t\tvalue: function handleTouchStart() {\n\t\t\t// Set a flag that the view is not being dragged\n\t\t\tthis.dragging = false;\n\t\t}\n\t}, {\n\t\tkey: 'renderRemoveIcon',\n\t\tvalue: function renderRemoveIcon() {\n\t\t\tif (this.props.disabled || !this.props.onRemove) return;\n\t\t\treturn React.createElement(\n\t\t\t\t'span',\n\t\t\t\t{ className: 'Select-value-icon',\n\t\t\t\t\t'aria-hidden': 'true',\n\t\t\t\t\tonMouseDown: this.onRemove,\n\t\t\t\t\tonTouchEnd: this.handleTouchEndRemove,\n\t\t\t\t\tonTouchStart: this.handleTouchStart,\n\t\t\t\t\tonTouchMove: this.handleTouchMove },\n\t\t\t\t'\\xD7'\n\t\t\t);\n\t\t}\n\t}, {\n\t\tkey: 'renderLabel',\n\t\tvalue: function renderLabel() {\n\t\t\tvar className = 'Select-value-label';\n\t\t\treturn this.props.onClick || this.props.value.href ? React.createElement(\n\t\t\t\t'a',\n\t\t\t\t{ className: className, href: this.props.value.href, target: this.props.value.target, onMouseDown: this.handleMouseDown, onTouchEnd: this.handleMouseDown },\n\t\t\t\tthis.props.children\n\t\t\t) : React.createElement(\n\t\t\t\t'span',\n\t\t\t\t{ className: className, role: 'option', 'aria-selected': 'true', id: this.props.id },\n\t\t\t\tthis.props.children\n\t\t\t);\n\t\t}\n\t}, {\n\t\tkey: 'render',\n\t\tvalue: function render() {\n\t\t\treturn React.createElement(\n\t\t\t\t'div',\n\t\t\t\t{ className: classNames('Select-value', this.props.value.className),\n\t\t\t\t\tstyle: this.props.value.style,\n\t\t\t\t\ttitle: this.props.value.title\n\t\t\t\t},\n\t\t\t\tthis.renderRemoveIcon(),\n\t\t\t\tthis.renderLabel()\n\t\t\t);\n\t\t}\n\t}]);\n\treturn Value;\n}(React.Component);\n\nValue.propTypes = {\n\tchildren: PropTypes.node,\n\tdisabled: PropTypes.bool, // disabled prop passed to ReactSelect\n\tid: PropTypes.string, // Unique id for the value - used for aria\n\tonClick: PropTypes.func, // method to handle click on value label\n\tonRemove: PropTypes.func, // method to handle removal of the value\n\tvalue: PropTypes.object.isRequired // the option object for this value\n};\n\n/*!\n Copyright (c) 2018 Jed Watson.\n Licensed under the MIT License (MIT), see\n http://jedwatson.github.io/react-select\n*/\nvar stringifyValue = function stringifyValue(value) {\n\treturn typeof value === 'string' ? value : value !== null && JSON.stringify(value) || '';\n};\n\nvar stringOrNode = PropTypes.oneOfType([PropTypes.string, PropTypes.node]);\nvar stringOrNumber = PropTypes.oneOfType([PropTypes.string, PropTypes.number]);\n\nvar instanceId = 1;\n\nvar shouldShowValue = function shouldShowValue(state, props) {\n\tvar inputValue = state.inputValue,\n\t isPseudoFocused = state.isPseudoFocused,\n\t isFocused = state.isFocused;\n\tvar onSelectResetsInput = props.onSelectResetsInput;\n\n\n\tif (!inputValue) return true;\n\n\tif (!onSelectResetsInput) {\n\t\treturn !(!isFocused && isPseudoFocused || isFocused && !isPseudoFocused);\n\t}\n\n\treturn false;\n};\n\nvar shouldShowPlaceholder = function shouldShowPlaceholder(state, props, isOpen) {\n\tvar inputValue = state.inputValue,\n\t isPseudoFocused = state.isPseudoFocused,\n\t isFocused = state.isFocused;\n\tvar onSelectResetsInput = props.onSelectResetsInput;\n\n\n\treturn !inputValue || !onSelectResetsInput && !isOpen && !isPseudoFocused && !isFocused;\n};\n\n/**\n * Retrieve a value from the given options and valueKey\n * @param {String|Number|Array} value\t- the selected value(s)\n * @param {Object}\t\t props\t- the Select component's props (or nextProps)\n */\nvar expandValue = function expandValue(value, props) {\n\tvar valueType = typeof value === 'undefined' ? 'undefined' : _typeof(value);\n\tif (valueType !== 'string' && valueType !== 'number' && valueType !== 'boolean') return value;\n\tvar options = props.options,\n\t valueKey = props.valueKey;\n\n\tif (!options) return;\n\tfor (var i = 0; i < options.length; i++) {\n\t\tif (String(options[i][valueKey]) === String(value)) return options[i];\n\t}\n};\n\nvar handleRequired = function handleRequired(value, multi) {\n\tif (!value) return true;\n\treturn multi ? value.length === 0 : Object.keys(value).length === 0;\n};\n\nvar Select$1 = function (_React$Component) {\n\tinherits(Select, _React$Component);\n\n\tfunction Select(props) {\n\t\tclassCallCheck(this, Select);\n\n\t\tvar _this = possibleConstructorReturn(this, (Select.__proto__ || Object.getPrototypeOf(Select)).call(this, props));\n\n\t\t['clearValue', 'focusOption', 'getOptionLabel', 'handleInputBlur', 'handleInputChange', 'handleInputFocus', 'handleInputValueChange', 'handleKeyDown', 'handleMenuScroll', 'handleMouseDown', 'handleMouseDownOnArrow', 'handleMouseDownOnMenu', 'handleTouchEnd', 'handleTouchEndClearValue', 'handleTouchMove', 'handleTouchOutside', 'handleTouchStart', 'handleValueClick', 'onOptionRef', 'removeValue', 'selectValue'].forEach(function (fn) {\n\t\t\treturn _this[fn] = _this[fn].bind(_this);\n\t\t});\n\n\t\t_this.state = {\n\t\t\tinputValue: '',\n\t\t\tisFocused: false,\n\t\t\tisOpen: false,\n\t\t\tisPseudoFocused: false,\n\t\t\trequired: false\n\t\t};\n\t\treturn _this;\n\t}\n\n\tcreateClass(Select, [{\n\t\tkey: 'componentWillMount',\n\t\tvalue: function componentWillMount() {\n\t\t\tthis._instancePrefix = 'react-select-' + (this.props.instanceId || ++instanceId) + '-';\n\t\t\tvar valueArray = this.getValueArray(this.props.value);\n\n\t\t\tif (this.props.required) {\n\t\t\t\tthis.setState({\n\t\t\t\t\trequired: handleRequired(valueArray[0], this.props.multi)\n\t\t\t\t});\n\t\t\t}\n\t\t}\n\t}, {\n\t\tkey: 'componentDidMount',\n\t\tvalue: function componentDidMount() {\n\t\t\tif (typeof this.props.autofocus !== 'undefined' && typeof console !== 'undefined') {\n\t\t\t\tconsole.warn('Warning: The autofocus prop has changed to autoFocus, support will be removed after react-select@1.0');\n\t\t\t}\n\t\t\tif (this.props.autoFocus || this.props.autofocus) {\n\t\t\t\tthis.focus();\n\t\t\t}\n\t\t}\n\t}, {\n\t\tkey: 'componentWillReceiveProps',\n\t\tvalue: function componentWillReceiveProps(nextProps) {\n\t\t\tvar valueArray = this.getValueArray(nextProps.value, nextProps);\n\n\t\t\tif (nextProps.required) {\n\t\t\t\tthis.setState({\n\t\t\t\t\trequired: handleRequired(valueArray[0], nextProps.multi)\n\t\t\t\t});\n\t\t\t} else if (this.props.required) {\n\t\t\t\t// Used to be required but it's not any more\n\t\t\t\tthis.setState({ required: false });\n\t\t\t}\n\n\t\t\tif (this.state.inputValue && this.props.value !== nextProps.value && nextProps.onSelectResetsInput) {\n\t\t\t\tthis.setState({ inputValue: this.handleInputValueChange('') });\n\t\t\t}\n\t\t}\n\t}, {\n\t\tkey: 'componentDidUpdate',\n\t\tvalue: function componentDidUpdate(prevProps, prevState) {\n\t\t\t// focus to the selected option\n\t\t\tif (this.menu && this.focused && this.state.isOpen && !this.hasScrolledToOption) {\n\t\t\t\tvar focusedOptionNode = findDOMNode(this.focused);\n\t\t\t\tvar menuNode = findDOMNode(this.menu);\n\n\t\t\t\tvar scrollTop = menuNode.scrollTop;\n\t\t\t\tvar scrollBottom = scrollTop + menuNode.offsetHeight;\n\t\t\t\tvar optionTop = focusedOptionNode.offsetTop;\n\t\t\t\tvar optionBottom = optionTop + focusedOptionNode.offsetHeight;\n\n\t\t\t\tif (scrollTop > optionTop || scrollBottom < optionBottom) {\n\t\t\t\t\tmenuNode.scrollTop = focusedOptionNode.offsetTop;\n\t\t\t\t}\n\n\t\t\t\t// We still set hasScrolledToOption to true even if we didn't\n\t\t\t\t// actually need to scroll, as we've still confirmed that the\n\t\t\t\t// option is in view.\n\t\t\t\tthis.hasScrolledToOption = true;\n\t\t\t} else if (!this.state.isOpen) {\n\t\t\t\tthis.hasScrolledToOption = false;\n\t\t\t}\n\n\t\t\tif (this._scrollToFocusedOptionOnUpdate && this.focused && this.menu) {\n\t\t\t\tthis._scrollToFocusedOptionOnUpdate = false;\n\t\t\t\tvar focusedDOM = findDOMNode(this.focused);\n\t\t\t\tvar menuDOM = findDOMNode(this.menu);\n\t\t\t\tvar focusedRect = focusedDOM.getBoundingClientRect();\n\t\t\t\tvar menuRect = menuDOM.getBoundingClientRect();\n\t\t\t\tif (focusedRect.bottom > menuRect.bottom) {\n\t\t\t\t\tmenuDOM.scrollTop = focusedDOM.offsetTop + focusedDOM.clientHeight - menuDOM.offsetHeight;\n\t\t\t\t} else if (focusedRect.top < menuRect.top) {\n\t\t\t\t\tmenuDOM.scrollTop = focusedDOM.offsetTop;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (this.props.scrollMenuIntoView && this.menuContainer) {\n\t\t\t\tvar menuContainerRect = this.menuContainer.getBoundingClientRect();\n\t\t\t\tif (window.innerHeight < menuContainerRect.bottom + this.props.menuBuffer) {\n\t\t\t\t\twindow.scrollBy(0, menuContainerRect.bottom + this.props.menuBuffer - window.innerHeight);\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (prevProps.disabled !== this.props.disabled) {\n\t\t\t\tthis.setState({ isFocused: false }); // eslint-disable-line react/no-did-update-set-state\n\t\t\t\tthis.closeMenu();\n\t\t\t}\n\t\t\tif (prevState.isOpen !== this.state.isOpen) {\n\t\t\t\tthis.toggleTouchOutsideEvent(this.state.isOpen);\n\t\t\t\tvar handler = this.state.isOpen ? this.props.onOpen : this.props.onClose;\n\t\t\t\thandler && handler();\n\t\t\t}\n\t\t}\n\t}, {\n\t\tkey: 'componentWillUnmount',\n\t\tvalue: function componentWillUnmount() {\n\t\t\tthis.toggleTouchOutsideEvent(false);\n\t\t}\n\t}, {\n\t\tkey: 'toggleTouchOutsideEvent',\n\t\tvalue: function toggleTouchOutsideEvent(enabled) {\n\t\t\tif (enabled) {\n\t\t\t\tif (!document.addEventListener && document.attachEvent) {\n\t\t\t\t\tdocument.attachEvent('ontouchstart', this.handleTouchOutside);\n\t\t\t\t} else {\n\t\t\t\t\tdocument.addEventListener('touchstart', this.handleTouchOutside);\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tif (!document.removeEventListener && document.detachEvent) {\n\t\t\t\t\tdocument.detachEvent('ontouchstart', this.handleTouchOutside);\n\t\t\t\t} else {\n\t\t\t\t\tdocument.removeEventListener('touchstart', this.handleTouchOutside);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}, {\n\t\tkey: 'handleTouchOutside',\n\t\tvalue: function handleTouchOutside(event) {\n\t\t\t// handle touch outside on ios to dismiss menu\n\t\t\tif (this.wrapper && !this.wrapper.contains(event.target)) {\n\t\t\t\tthis.closeMenu();\n\t\t\t}\n\t\t}\n\t}, {\n\t\tkey: 'focus',\n\t\tvalue: function focus() {\n\t\t\tif (!this.input) return;\n\t\t\tthis.input.focus();\n\t\t}\n\t}, {\n\t\tkey: 'blurInput',\n\t\tvalue: function blurInput() {\n\t\t\tif (!this.input) return;\n\t\t\tthis.input.blur();\n\t\t}\n\t}, {\n\t\tkey: 'handleTouchMove',\n\t\tvalue: function handleTouchMove() {\n\t\t\t// Set a flag that the view is being dragged\n\t\t\tthis.dragging = true;\n\t\t}\n\t}, {\n\t\tkey: 'handleTouchStart',\n\t\tvalue: function handleTouchStart() {\n\t\t\t// Set a flag that the view is not being dragged\n\t\t\tthis.dragging = false;\n\t\t}\n\t}, {\n\t\tkey: 'handleTouchEnd',\n\t\tvalue: function handleTouchEnd(event) {\n\t\t\t// Check if the view is being dragged, In this case\n\t\t\t// we don't want to fire the click event (because the user only wants to scroll)\n\t\t\tif (this.dragging) return;\n\n\t\t\t// Fire the mouse events\n\t\t\tthis.handleMouseDown(event);\n\t\t}\n\t}, {\n\t\tkey: 'handleTouchEndClearValue',\n\t\tvalue: function handleTouchEndClearValue(event) {\n\t\t\t// Check if the view is being dragged, In this case\n\t\t\t// we don't want to fire the click event (because the user only wants to scroll)\n\t\t\tif (this.dragging) return;\n\n\t\t\t// Clear the value\n\t\t\tthis.clearValue(event);\n\t\t}\n\t}, {\n\t\tkey: 'handleMouseDown',\n\t\tvalue: function handleMouseDown(event) {\n\t\t\t// if the event was triggered by a mousedown and not the primary\n\t\t\t// button, or if the component is disabled, ignore it.\n\t\t\tif (this.props.disabled || event.type === 'mousedown' && event.button !== 0) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tif (event.target.tagName === 'INPUT') {\n\t\t\t\tif (!this.state.isFocused) {\n\t\t\t\t\tthis._openAfterFocus = this.props.openOnClick;\n\t\t\t\t\tthis.focus();\n\t\t\t\t} else if (!this.state.isOpen) {\n\t\t\t\t\tthis.setState({\n\t\t\t\t\t\tisOpen: true,\n\t\t\t\t\t\tisPseudoFocused: false\n\t\t\t\t\t});\n\t\t\t\t}\n\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\t// prevent default event handlers\n\t\t\tevent.preventDefault();\n\n\t\t\t// for the non-searchable select, toggle the menu\n\t\t\tif (!this.props.searchable) {\n\t\t\t\t// This code means that if a select is searchable, onClick the options menu will not appear, only on subsequent click will it open.\n\t\t\t\tthis.focus();\n\t\t\t\treturn this.setState({\n\t\t\t\t\tisOpen: !this.state.isOpen\n\t\t\t\t});\n\t\t\t}\n\n\t\t\tif (this.state.isFocused) {\n\t\t\t\t// On iOS, we can get into a state where we think the input is focused but it isn't really,\n\t\t\t\t// since iOS ignores programmatic calls to input.focus() that weren't triggered by a click event.\n\t\t\t\t// Call focus() again here to be safe.\n\t\t\t\tthis.focus();\n\n\t\t\t\tvar input = this.input;\n\t\t\t\tvar toOpen = true;\n\n\t\t\t\tif (typeof input.getInput === 'function') {\n\t\t\t\t\t// Get the actual DOM input if the ref is an component\n\t\t\t\t\tinput = input.getInput();\n\t\t\t\t}\n\n\t\t\t\t// clears the value so that the cursor will be at the end of input when the component re-renders\n\t\t\t\tinput.value = '';\n\n\t\t\t\tif (this._focusAfterClear) {\n\t\t\t\t\ttoOpen = false;\n\t\t\t\t\tthis._focusAfterClear = false;\n\t\t\t\t}\n\n\t\t\t\t// if the input is focused, ensure the menu is open\n\t\t\t\tthis.setState({\n\t\t\t\t\tisOpen: toOpen,\n\t\t\t\t\tisPseudoFocused: false,\n\t\t\t\t\tfocusedOption: null\n\t\t\t\t});\n\t\t\t} else {\n\t\t\t\t// otherwise, focus the input and open the menu\n\t\t\t\tthis._openAfterFocus = this.props.openOnClick;\n\t\t\t\tthis.focus();\n\t\t\t\tthis.setState({ focusedOption: null });\n\t\t\t}\n\t\t}\n\t}, {\n\t\tkey: 'handleMouseDownOnArrow',\n\t\tvalue: function handleMouseDownOnArrow(event) {\n\t\t\t// if the event was triggered by a mousedown and not the primary\n\t\t\t// button, or if the component is disabled, ignore it.\n\t\t\tif (this.props.disabled || event.type === 'mousedown' && event.button !== 0) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tif (this.state.isOpen) {\n\t\t\t\t// prevent default event handlers\n\t\t\t\tevent.stopPropagation();\n\t\t\t\tevent.preventDefault();\n\t\t\t\t// close the menu\n\t\t\t\tthis.closeMenu();\n\t\t\t} else {\n\t\t\t\t// If the menu isn't open, let the event bubble to the main handleMouseDown\n\t\t\t\tthis.setState({\n\t\t\t\t\tisOpen: true\n\t\t\t\t});\n\t\t\t}\n\t\t}\n\t}, {\n\t\tkey: 'handleMouseDownOnMenu',\n\t\tvalue: function handleMouseDownOnMenu(event) {\n\t\t\t// if the event was triggered by a mousedown and not the primary\n\t\t\t// button, or if the component is disabled, ignore it.\n\t\t\tif (this.props.disabled || event.type === 'mousedown' && event.button !== 0) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tevent.stopPropagation();\n\t\t\tevent.preventDefault();\n\n\t\t\tthis._openAfterFocus = true;\n\t\t\tthis.focus();\n\t\t}\n\t}, {\n\t\tkey: 'closeMenu',\n\t\tvalue: function closeMenu() {\n\t\t\tif (this.props.onCloseResetsInput) {\n\t\t\t\tthis.setState({\n\t\t\t\t\tinputValue: this.handleInputValueChange(''),\n\t\t\t\t\tisOpen: false,\n\t\t\t\t\tisPseudoFocused: this.state.isFocused && !this.props.multi\n\t\t\t\t});\n\t\t\t} else {\n\t\t\t\tthis.setState({\n\t\t\t\t\tisOpen: false,\n\t\t\t\t\tisPseudoFocused: this.state.isFocused && !this.props.multi\n\t\t\t\t});\n\t\t\t}\n\t\t\tthis.hasScrolledToOption = false;\n\t\t}\n\t}, {\n\t\tkey: 'handleInputFocus',\n\t\tvalue: function handleInputFocus(event) {\n\t\t\tif (this.props.disabled) return;\n\n\t\t\tvar toOpen = this.state.isOpen || this._openAfterFocus || this.props.openOnFocus;\n\t\t\ttoOpen = this._focusAfterClear ? false : toOpen; //if focus happens after clear values, don't open dropdown yet.\n\n\t\t\tif (this.props.onFocus) {\n\t\t\t\tthis.props.onFocus(event);\n\t\t\t}\n\n\t\t\tthis.setState({\n\t\t\t\tisFocused: true,\n\t\t\t\tisOpen: !!toOpen\n\t\t\t});\n\n\t\t\tthis._focusAfterClear = false;\n\t\t\tthis._openAfterFocus = false;\n\t\t}\n\t}, {\n\t\tkey: 'handleInputBlur',\n\t\tvalue: function handleInputBlur(event) {\n\t\t\t// The check for menu.contains(activeElement) is necessary to prevent IE11's scrollbar from closing the menu in certain contexts.\n\t\t\tif (this.menu && (this.menu === document.activeElement || this.menu.contains(document.activeElement))) {\n\t\t\t\tthis.focus();\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tif (this.props.onBlur) {\n\t\t\t\tthis.props.onBlur(event);\n\t\t\t}\n\t\t\tvar onBlurredState = {\n\t\t\t\tisFocused: false,\n\t\t\t\tisOpen: false,\n\t\t\t\tisPseudoFocused: false\n\t\t\t};\n\t\t\tif (this.props.onBlurResetsInput) {\n\t\t\t\tonBlurredState.inputValue = this.handleInputValueChange('');\n\t\t\t}\n\t\t\tthis.setState(onBlurredState);\n\t\t}\n\t}, {\n\t\tkey: 'handleInputChange',\n\t\tvalue: function handleInputChange(event) {\n\t\t\tvar newInputValue = event.target.value;\n\n\t\t\tif (this.state.inputValue !== event.target.value) {\n\t\t\t\tnewInputValue = this.handleInputValueChange(newInputValue);\n\t\t\t}\n\n\t\t\tthis.setState({\n\t\t\t\tinputValue: newInputValue,\n\t\t\t\tisOpen: true,\n\t\t\t\tisPseudoFocused: false\n\t\t\t});\n\t\t}\n\t}, {\n\t\tkey: 'setInputValue',\n\t\tvalue: function setInputValue(newValue) {\n\t\t\tif (this.props.onInputChange) {\n\t\t\t\tvar nextState = this.props.onInputChange(newValue);\n\t\t\t\tif (nextState != null && (typeof nextState === 'undefined' ? 'undefined' : _typeof(nextState)) !== 'object') {\n\t\t\t\t\tnewValue = '' + nextState;\n\t\t\t\t}\n\t\t\t}\n\t\t\tthis.setState({\n\t\t\t\tinputValue: newValue\n\t\t\t});\n\t\t}\n\t}, {\n\t\tkey: 'handleInputValueChange',\n\t\tvalue: function handleInputValueChange(newValue) {\n\t\t\tif (this.props.onInputChange) {\n\t\t\t\tvar nextState = this.props.onInputChange(newValue);\n\t\t\t\t// Note: != used deliberately here to catch undefined and null\n\t\t\t\tif (nextState != null && (typeof nextState === 'undefined' ? 'undefined' : _typeof(nextState)) !== 'object') {\n\t\t\t\t\tnewValue = '' + nextState;\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn newValue;\n\t\t}\n\t}, {\n\t\tkey: 'handleKeyDown',\n\t\tvalue: function handleKeyDown(event) {\n\t\t\tif (this.props.disabled) return;\n\n\t\t\tif (typeof this.props.onInputKeyDown === 'function') {\n\t\t\t\tthis.props.onInputKeyDown(event);\n\t\t\t\tif (event.defaultPrevented) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tswitch (event.keyCode) {\n\t\t\t\tcase 8:\n\t\t\t\t\t// backspace\n\t\t\t\t\tif (!this.state.inputValue && this.props.backspaceRemoves) {\n\t\t\t\t\t\tevent.preventDefault();\n\t\t\t\t\t\tthis.popValue();\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase 9:\n\t\t\t\t\t// tab\n\t\t\t\t\tif (event.shiftKey || !this.state.isOpen || !this.props.tabSelectsValue) {\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\tevent.preventDefault();\n\t\t\t\t\tthis.selectFocusedOption();\n\t\t\t\t\tbreak;\n\t\t\t\tcase 13:\n\t\t\t\t\t// enter\n\t\t\t\t\tevent.preventDefault();\n\t\t\t\t\tevent.stopPropagation();\n\t\t\t\t\tif (this.state.isOpen) {\n\t\t\t\t\t\tthis.selectFocusedOption();\n\t\t\t\t\t} else {\n\t\t\t\t\t\tthis.focusNextOption();\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase 27:\n\t\t\t\t\t// escape\n\t\t\t\t\tevent.preventDefault();\n\t\t\t\t\tif (this.state.isOpen) {\n\t\t\t\t\t\tthis.closeMenu();\n\t\t\t\t\t\tevent.stopPropagation();\n\t\t\t\t\t} else if (this.props.clearable && this.props.escapeClearsValue) {\n\t\t\t\t\t\tthis.clearValue(event);\n\t\t\t\t\t\tevent.stopPropagation();\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase 32:\n\t\t\t\t\t// space\n\t\t\t\t\tif (this.props.searchable) {\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\tevent.preventDefault();\n\t\t\t\t\tif (!this.state.isOpen) {\n\t\t\t\t\t\tthis.focusNextOption();\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\tevent.stopPropagation();\n\t\t\t\t\tthis.selectFocusedOption();\n\t\t\t\t\tbreak;\n\t\t\t\tcase 38:\n\t\t\t\t\t// up\n\t\t\t\t\tevent.preventDefault();\n\t\t\t\t\tthis.focusPreviousOption();\n\t\t\t\t\tbreak;\n\t\t\t\tcase 40:\n\t\t\t\t\t// down\n\t\t\t\t\tevent.preventDefault();\n\t\t\t\t\tthis.focusNextOption();\n\t\t\t\t\tbreak;\n\t\t\t\tcase 33:\n\t\t\t\t\t// page up\n\t\t\t\t\tevent.preventDefault();\n\t\t\t\t\tthis.focusPageUpOption();\n\t\t\t\t\tbreak;\n\t\t\t\tcase 34:\n\t\t\t\t\t// page down\n\t\t\t\t\tevent.preventDefault();\n\t\t\t\t\tthis.focusPageDownOption();\n\t\t\t\t\tbreak;\n\t\t\t\tcase 35:\n\t\t\t\t\t// end key\n\t\t\t\t\tif (event.shiftKey) {\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\tevent.preventDefault();\n\t\t\t\t\tthis.focusEndOption();\n\t\t\t\t\tbreak;\n\t\t\t\tcase 36:\n\t\t\t\t\t// home key\n\t\t\t\t\tif (event.shiftKey) {\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\tevent.preventDefault();\n\t\t\t\t\tthis.focusStartOption();\n\t\t\t\t\tbreak;\n\t\t\t\tcase 46:\n\t\t\t\t\t// delete\n\t\t\t\t\tif (!this.state.inputValue && this.props.deleteRemoves) {\n\t\t\t\t\t\tevent.preventDefault();\n\t\t\t\t\t\tthis.popValue();\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t}, {\n\t\tkey: 'handleValueClick',\n\t\tvalue: function handleValueClick(option, event) {\n\t\t\tif (!this.props.onValueClick) return;\n\t\t\tthis.props.onValueClick(option, event);\n\t\t}\n\t}, {\n\t\tkey: 'handleMenuScroll',\n\t\tvalue: function handleMenuScroll(event) {\n\t\t\tif (!this.props.onMenuScrollToBottom) return;\n\t\t\tvar target = event.target;\n\n\t\t\tif (target.scrollHeight > target.offsetHeight && target.scrollHeight - target.offsetHeight - target.scrollTop <= 0) {\n\t\t\t\tthis.props.onMenuScrollToBottom();\n\t\t\t}\n\t\t}\n\t}, {\n\t\tkey: 'getOptionLabel',\n\t\tvalue: function getOptionLabel(op) {\n\t\t\treturn op[this.props.labelKey];\n\t\t}\n\n\t\t/**\n * Turns a value into an array from the given options\n * @param {String|Number|Array} value\t\t- the value of the select input\n * @param {Object}\t\tnextProps\t- optionally specify the nextProps so the returned array uses the latest configuration\n * @returns\t{Array}\tthe value of the select represented in an array\n */\n\n\t}, {\n\t\tkey: 'getValueArray',\n\t\tvalue: function getValueArray(value) {\n\t\t\tvar nextProps = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : undefined;\n\n\t\t\t/** support optionally passing in the `nextProps` so `componentWillReceiveProps` updates will function as expected */\n\t\t\tvar props = (typeof nextProps === 'undefined' ? 'undefined' : _typeof(nextProps)) === 'object' ? nextProps : this.props;\n\t\t\tif (props.multi) {\n\t\t\t\tif (typeof value === 'string') {\n\t\t\t\t\tvalue = value.split(props.delimiter);\n\t\t\t\t}\n\t\t\t\tif (!Array.isArray(value)) {\n\t\t\t\t\tif (value === null || value === undefined) return [];\n\t\t\t\t\tvalue = [value];\n\t\t\t\t}\n\t\t\t\treturn value.map(function (value) {\n\t\t\t\t\treturn expandValue(value, props);\n\t\t\t\t}).filter(function (i) {\n\t\t\t\t\treturn i;\n\t\t\t\t});\n\t\t\t}\n\t\t\tvar expandedValue = expandValue(value, props);\n\t\t\treturn expandedValue ? [expandedValue] : [];\n\t\t}\n\t}, {\n\t\tkey: 'setValue',\n\t\tvalue: function setValue(value) {\n\t\t\tvar _this2 = this;\n\n\t\t\tif (this.props.autoBlur) {\n\t\t\t\tthis.blurInput();\n\t\t\t}\n\t\t\tif (this.props.required) {\n\t\t\t\tvar required = handleRequired(value, this.props.multi);\n\t\t\t\tthis.setState({ required: required });\n\t\t\t}\n\t\t\tif (this.props.simpleValue && value) {\n\t\t\t\tvalue = this.props.multi ? value.map(function (i) {\n\t\t\t\t\treturn i[_this2.props.valueKey];\n\t\t\t\t}).join(this.props.delimiter) : value[this.props.valueKey];\n\t\t\t}\n\t\t\tif (this.props.onChange) {\n\t\t\t\tthis.props.onChange(value);\n\t\t\t}\n\t\t}\n\t}, {\n\t\tkey: 'selectValue',\n\t\tvalue: function selectValue(value) {\n\t\t\tvar _this3 = this;\n\n\t\t\t// NOTE: we actually add/set the value in a callback to make sure the\n\t\t\t// input value is empty to avoid styling issues in Chrome\n\t\t\tif (this.props.closeOnSelect) {\n\t\t\t\tthis.hasScrolledToOption = false;\n\t\t\t}\n\t\t\tvar updatedValue = this.props.onSelectResetsInput ? '' : this.state.inputValue;\n\t\t\tif (this.props.multi) {\n\t\t\t\tthis.setState({\n\t\t\t\t\tfocusedIndex: null,\n\t\t\t\t\tinputValue: this.handleInputValueChange(updatedValue),\n\t\t\t\t\tisOpen: !this.props.closeOnSelect\n\t\t\t\t}, function () {\n\t\t\t\t\tvar valueArray = _this3.getValueArray(_this3.props.value);\n\t\t\t\t\tif (valueArray.some(function (i) {\n\t\t\t\t\t\treturn i[_this3.props.valueKey] === value[_this3.props.valueKey];\n\t\t\t\t\t})) {\n\t\t\t\t\t\t_this3.removeValue(value);\n\t\t\t\t\t} else {\n\t\t\t\t\t\t_this3.addValue(value);\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t} else {\n\t\t\t\tthis.setState({\n\t\t\t\t\tinputValue: this.handleInputValueChange(updatedValue),\n\t\t\t\t\tisOpen: !this.props.closeOnSelect,\n\t\t\t\t\tisPseudoFocused: this.state.isFocused\n\t\t\t\t}, function () {\n\t\t\t\t\t_this3.setValue(value);\n\t\t\t\t});\n\t\t\t}\n\t\t}\n\t}, {\n\t\tkey: 'addValue',\n\t\tvalue: function addValue(value) {\n\t\t\tvar valueArray = this.getValueArray(this.props.value);\n\t\t\tvar visibleOptions = this._visibleOptions.filter(function (val) {\n\t\t\t\treturn !val.disabled;\n\t\t\t});\n\t\t\tvar lastValueIndex = visibleOptions.indexOf(value);\n\t\t\tthis.setValue(valueArray.concat(value));\n\t\t\tif (visibleOptions.length - 1 === lastValueIndex) {\n\t\t\t\t// the last option was selected; focus the second-last one\n\t\t\t\tthis.focusOption(visibleOptions[lastValueIndex - 1]);\n\t\t\t} else if (visibleOptions.length > lastValueIndex) {\n\t\t\t\t// focus the option below the selected one\n\t\t\t\tthis.focusOption(visibleOptions[lastValueIndex + 1]);\n\t\t\t}\n\t\t}\n\t}, {\n\t\tkey: 'popValue',\n\t\tvalue: function popValue() {\n\t\t\tvar valueArray = this.getValueArray(this.props.value);\n\t\t\tif (!valueArray.length) return;\n\t\t\tif (valueArray[valueArray.length - 1].clearableValue === false) return;\n\t\t\tthis.setValue(this.props.multi ? valueArray.slice(0, valueArray.length - 1) : null);\n\t\t}\n\t}, {\n\t\tkey: 'removeValue',\n\t\tvalue: function removeValue(value) {\n\t\t\tvar _this4 = this;\n\n\t\t\tvar valueArray = this.getValueArray(this.props.value);\n\t\t\tthis.setValue(valueArray.filter(function (i) {\n\t\t\t\treturn i[_this4.props.valueKey] !== value[_this4.props.valueKey];\n\t\t\t}));\n\t\t\tthis.focus();\n\t\t}\n\t}, {\n\t\tkey: 'clearValue',\n\t\tvalue: function clearValue(event) {\n\t\t\t// if the event was triggered by a mousedown and not the primary\n\t\t\t// button, ignore it.\n\t\t\tif (event && event.type === 'mousedown' && event.button !== 0) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tevent.preventDefault();\n\n\t\t\tthis.setValue(this.getResetValue());\n\t\t\tthis.setState({\n\t\t\t\tinputValue: this.handleInputValueChange(''),\n\t\t\t\tisOpen: false\n\t\t\t}, this.focus);\n\n\t\t\tthis._focusAfterClear = true;\n\t\t}\n\t}, {\n\t\tkey: 'getResetValue',\n\t\tvalue: function getResetValue() {\n\t\t\tif (this.props.resetValue !== undefined) {\n\t\t\t\treturn this.props.resetValue;\n\t\t\t} else if (this.props.multi) {\n\t\t\t\treturn [];\n\t\t\t} else {\n\t\t\t\treturn null;\n\t\t\t}\n\t\t}\n\t}, {\n\t\tkey: 'focusOption',\n\t\tvalue: function focusOption(option) {\n\t\t\tthis.setState({\n\t\t\t\tfocusedOption: option\n\t\t\t});\n\t\t}\n\t}, {\n\t\tkey: 'focusNextOption',\n\t\tvalue: function focusNextOption() {\n\t\t\tthis.focusAdjacentOption('next');\n\t\t}\n\t}, {\n\t\tkey: 'focusPreviousOption',\n\t\tvalue: function focusPreviousOption() {\n\t\t\tthis.focusAdjacentOption('previous');\n\t\t}\n\t}, {\n\t\tkey: 'focusPageUpOption',\n\t\tvalue: function focusPageUpOption() {\n\t\t\tthis.focusAdjacentOption('page_up');\n\t\t}\n\t}, {\n\t\tkey: 'focusPageDownOption',\n\t\tvalue: function focusPageDownOption() {\n\t\t\tthis.focusAdjacentOption('page_down');\n\t\t}\n\t}, {\n\t\tkey: 'focusStartOption',\n\t\tvalue: function focusStartOption() {\n\t\t\tthis.focusAdjacentOption('start');\n\t\t}\n\t}, {\n\t\tkey: 'focusEndOption',\n\t\tvalue: function focusEndOption() {\n\t\t\tthis.focusAdjacentOption('end');\n\t\t}\n\t}, {\n\t\tkey: 'focusAdjacentOption',\n\t\tvalue: function focusAdjacentOption(dir) {\n\t\t\tvar options = this._visibleOptions.map(function (option, index) {\n\t\t\t\treturn { option: option, index: index };\n\t\t\t}).filter(function (option) {\n\t\t\t\treturn !option.option.disabled;\n\t\t\t});\n\t\t\tthis._scrollToFocusedOptionOnUpdate = true;\n\t\t\tif (!this.state.isOpen) {\n\t\t\t\tvar newState = {\n\t\t\t\t\tfocusedOption: this._focusedOption || (options.length ? options[dir === 'next' ? 0 : options.length - 1].option : null),\n\t\t\t\t\tisOpen: true\n\t\t\t\t};\n\t\t\t\tif (this.props.onSelectResetsInput) {\n\t\t\t\t\tnewState.inputValue = '';\n\t\t\t\t}\n\t\t\t\tthis.setState(newState);\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tif (!options.length) return;\n\t\t\tvar focusedIndex = -1;\n\t\t\tfor (var i = 0; i < options.length; i++) {\n\t\t\t\tif (this._focusedOption === options[i].option) {\n\t\t\t\t\tfocusedIndex = i;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (dir === 'next' && focusedIndex !== -1) {\n\t\t\t\tfocusedIndex = (focusedIndex + 1) % options.length;\n\t\t\t} else if (dir === 'previous') {\n\t\t\t\tif (focusedIndex > 0) {\n\t\t\t\t\tfocusedIndex = focusedIndex - 1;\n\t\t\t\t} else {\n\t\t\t\t\tfocusedIndex = options.length - 1;\n\t\t\t\t}\n\t\t\t} else if (dir === 'start') {\n\t\t\t\tfocusedIndex = 0;\n\t\t\t} else if (dir === 'end') {\n\t\t\t\tfocusedIndex = options.length - 1;\n\t\t\t} else if (dir === 'page_up') {\n\t\t\t\tvar potentialIndex = focusedIndex - this.props.pageSize;\n\t\t\t\tif (potentialIndex < 0) {\n\t\t\t\t\tfocusedIndex = 0;\n\t\t\t\t} else {\n\t\t\t\t\tfocusedIndex = potentialIndex;\n\t\t\t\t}\n\t\t\t} else if (dir === 'page_down') {\n\t\t\t\tvar _potentialIndex = focusedIndex + this.props.pageSize;\n\t\t\t\tif (_potentialIndex > options.length - 1) {\n\t\t\t\t\tfocusedIndex = options.length - 1;\n\t\t\t\t} else {\n\t\t\t\t\tfocusedIndex = _potentialIndex;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif (focusedIndex === -1) {\n\t\t\t\tfocusedIndex = 0;\n\t\t\t}\n\n\t\t\tthis.setState({\n\t\t\t\tfocusedIndex: options[focusedIndex].index,\n\t\t\t\tfocusedOption: options[focusedIndex].option\n\t\t\t});\n\t\t}\n\t}, {\n\t\tkey: 'getFocusedOption',\n\t\tvalue: function getFocusedOption() {\n\t\t\treturn this._focusedOption;\n\t\t}\n\t}, {\n\t\tkey: 'selectFocusedOption',\n\t\tvalue: function selectFocusedOption() {\n\t\t\tif (this._focusedOption) {\n\t\t\t\treturn this.selectValue(this._focusedOption);\n\t\t\t}\n\t\t}\n\t}, {\n\t\tkey: 'renderLoading',\n\t\tvalue: function renderLoading() {\n\t\t\tif (!this.props.isLoading) return;\n\t\t\treturn React.createElement(\n\t\t\t\t'span',\n\t\t\t\t{ className: 'Select-loading-zone', 'aria-hidden': 'true' },\n\t\t\t\tReact.createElement('span', { className: 'Select-loading' })\n\t\t\t);\n\t\t}\n\t}, {\n\t\tkey: 'renderValue',\n\t\tvalue: function renderValue(valueArray, isOpen) {\n\t\t\tvar _this5 = this;\n\n\t\t\tvar renderLabel = this.props.valueRenderer || this.getOptionLabel;\n\t\t\tvar ValueComponent = this.props.valueComponent;\n\t\t\tif (!valueArray.length) {\n\t\t\t\tvar showPlaceholder = shouldShowPlaceholder(this.state, this.props, isOpen);\n\t\t\t\treturn showPlaceholder ? React.createElement(\n\t\t\t\t\t'div',\n\t\t\t\t\t{ className: 'Select-placeholder' },\n\t\t\t\t\tthis.props.placeholder\n\t\t\t\t) : null;\n\t\t\t}\n\t\t\tvar onClick = this.props.onValueClick ? this.handleValueClick : null;\n\t\t\tif (this.props.multi) {\n\t\t\t\treturn valueArray.map(function (value, i) {\n\t\t\t\t\treturn React.createElement(\n\t\t\t\t\t\tValueComponent,\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tdisabled: _this5.props.disabled || value.clearableValue === false,\n\t\t\t\t\t\t\tid: _this5._instancePrefix + '-value-' + i,\n\t\t\t\t\t\t\tinstancePrefix: _this5._instancePrefix,\n\t\t\t\t\t\t\tkey: 'value-' + i + '-' + value[_this5.props.valueKey],\n\t\t\t\t\t\t\tonClick: onClick,\n\t\t\t\t\t\t\tonRemove: _this5.removeValue,\n\t\t\t\t\t\t\tplaceholder: _this5.props.placeholder,\n\t\t\t\t\t\t\tvalue: value\n\t\t\t\t\t\t},\n\t\t\t\t\t\trenderLabel(value, i),\n\t\t\t\t\t\tReact.createElement(\n\t\t\t\t\t\t\t'span',\n\t\t\t\t\t\t\t{ className: 'Select-aria-only' },\n\t\t\t\t\t\t\t'\\xA0'\n\t\t\t\t\t\t)\n\t\t\t\t\t);\n\t\t\t\t});\n\t\t\t} else if (shouldShowValue(this.state, this.props)) {\n\t\t\t\tif (isOpen) onClick = null;\n\t\t\t\treturn React.createElement(\n\t\t\t\t\tValueComponent,\n\t\t\t\t\t{\n\t\t\t\t\t\tdisabled: this.props.disabled,\n\t\t\t\t\t\tid: this._instancePrefix + '-value-item',\n\t\t\t\t\t\tinstancePrefix: this._instancePrefix,\n\t\t\t\t\t\tonClick: onClick,\n\t\t\t\t\t\tplaceholder: this.props.placeholder,\n\t\t\t\t\t\tvalue: valueArray[0]\n\t\t\t\t\t},\n\t\t\t\t\trenderLabel(valueArray[0])\n\t\t\t\t);\n\t\t\t}\n\t\t}\n\t}, {\n\t\tkey: 'renderInput',\n\t\tvalue: function renderInput(valueArray, focusedOptionIndex) {\n\t\t\tvar _classNames,\n\t\t\t _this6 = this;\n\n\t\t\tvar className = classNames('Select-input', this.props.inputProps.className);\n\t\t\tvar isOpen = this.state.isOpen;\n\n\t\t\tvar ariaOwns = classNames((_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));\n\n\t\t\tvar value = this.state.inputValue;\n\t\t\tif (value && !this.props.onSelectResetsInput && !this.state.isFocused) {\n\t\t\t\t// it hides input value when it is not focused and was not reset on select\n\t\t\t\tvalue = '';\n\t\t\t}\n\n\t\t\tvar inputProps = _extends({}, this.props.inputProps, {\n\t\t\t\t'aria-activedescendant': isOpen ? this._instancePrefix + '-option-' + focusedOptionIndex : this._instancePrefix + '-value',\n\t\t\t\t'aria-describedby': this.props['aria-describedby'],\n\t\t\t\t'aria-expanded': '' + isOpen,\n\t\t\t\t'aria-haspopup': '' + isOpen,\n\t\t\t\t'aria-label': this.props['aria-label'],\n\t\t\t\t'aria-labelledby': this.props['aria-labelledby'],\n\t\t\t\t'aria-owns': ariaOwns,\n\t\t\t\tclassName: className,\n\t\t\t\tonBlur: this.handleInputBlur,\n\t\t\t\tonChange: this.handleInputChange,\n\t\t\t\tonFocus: this.handleInputFocus,\n\t\t\t\tref: function ref(_ref) {\n\t\t\t\t\treturn _this6.input = _ref;\n\t\t\t\t},\n\t\t\t\trole: 'combobox',\n\t\t\t\trequired: this.state.required,\n\t\t\t\ttabIndex: this.props.tabIndex,\n\t\t\t\tvalue: value\n\t\t\t});\n\n\t\t\tif (this.props.inputRenderer) {\n\t\t\t\treturn this.props.inputRenderer(inputProps);\n\t\t\t}\n\n\t\t\tif (this.props.disabled || !this.props.searchable) {\n\t\t\t\tvar divProps = objectWithoutProperties(this.props.inputProps, []);\n\n\n\t\t\t\tvar _ariaOwns = classNames(defineProperty({}, this._instancePrefix + '-list', isOpen));\n\t\t\t\treturn React.createElement('div', _extends({}, divProps, {\n\t\t\t\t\t'aria-expanded': isOpen,\n\t\t\t\t\t'aria-owns': _ariaOwns,\n\t\t\t\t\t'aria-activedescendant': isOpen ? this._instancePrefix + '-option-' + focusedOptionIndex : this._instancePrefix + '-value',\n\t\t\t\t\t'aria-disabled': '' + this.props.disabled,\n\t\t\t\t\t'aria-label': this.props['aria-label'],\n\t\t\t\t\t'aria-labelledby': this.props['aria-labelledby'],\n\t\t\t\t\tclassName: className,\n\t\t\t\t\tonBlur: this.handleInputBlur,\n\t\t\t\t\tonFocus: this.handleInputFocus,\n\t\t\t\t\tref: function ref(_ref2) {\n\t\t\t\t\t\treturn _this6.input = _ref2;\n\t\t\t\t\t},\n\t\t\t\t\trole: 'combobox',\n\t\t\t\t\tstyle: { border: 0, width: 1, display: 'inline-block' },\n\t\t\t\t\ttabIndex: this.props.tabIndex || 0\n\t\t\t\t}));\n\t\t\t}\n\n\t\t\tif (this.props.autosize) {\n\t\t\t\treturn React.createElement(AutosizeInput, _extends({ id: this.props.id }, inputProps, { minWidth: '5' }));\n\t\t\t}\n\t\t\treturn React.createElement(\n\t\t\t\t'div',\n\t\t\t\t{ className: className, key: 'input-wrap', style: { display: 'inline-block' } },\n\t\t\t\tReact.createElement('input', _extends({ id: this.props.id }, inputProps))\n\t\t\t);\n\t\t}\n\t}, {\n\t\tkey: 'renderClear',\n\t\tvalue: function renderClear() {\n\t\t\tvar valueArray = this.getValueArray(this.props.value);\n\t\t\tif (!this.props.clearable || !valueArray.length || this.props.disabled || this.props.isLoading) return;\n\t\t\tvar ariaLabel = this.props.multi ? this.props.clearAllText : this.props.clearValueText;\n\t\t\tvar clear = this.props.clearRenderer();\n\n\t\t\treturn React.createElement(\n\t\t\t\t'span',\n\t\t\t\t{\n\t\t\t\t\t'aria-label': ariaLabel,\n\t\t\t\t\tclassName: 'Select-clear-zone',\n\t\t\t\t\tonMouseDown: this.clearValue,\n\t\t\t\t\tonTouchEnd: this.handleTouchEndClearValue,\n\t\t\t\t\tonTouchMove: this.handleTouchMove,\n\t\t\t\t\tonTouchStart: this.handleTouchStart,\n\t\t\t\t\ttitle: ariaLabel\n\t\t\t\t},\n\t\t\t\tclear\n\t\t\t);\n\t\t}\n\t}, {\n\t\tkey: 'renderArrow',\n\t\tvalue: function renderArrow() {\n\t\t\tif (!this.props.arrowRenderer) return;\n\n\t\t\tvar onMouseDown = this.handleMouseDownOnArrow;\n\t\t\tvar isOpen = this.state.isOpen;\n\t\t\tvar arrow = this.props.arrowRenderer({ onMouseDown: onMouseDown, isOpen: isOpen });\n\n\t\t\tif (!arrow) {\n\t\t\t\treturn null;\n\t\t\t}\n\n\t\t\treturn React.createElement(\n\t\t\t\t'span',\n\t\t\t\t{\n\t\t\t\t\tclassName: 'Select-arrow-zone',\n\t\t\t\t\tonMouseDown: onMouseDown\n\t\t\t\t},\n\t\t\t\tarrow\n\t\t\t);\n\t\t}\n\t}, {\n\t\tkey: 'filterOptions',\n\t\tvalue: function filterOptions$$1(excludeOptions) {\n\t\t\tvar filterValue = this.state.inputValue;\n\t\t\tvar options = this.props.options || [];\n\t\t\tif (this.props.filterOptions) {\n\t\t\t\t// Maintain backwards compatibility with boolean attribute\n\t\t\t\tvar filterOptions$$1 = typeof this.props.filterOptions === 'function' ? this.props.filterOptions : filterOptions;\n\n\t\t\t\treturn filterOptions$$1(options, filterValue, excludeOptions, {\n\t\t\t\t\tfilterOption: this.props.filterOption,\n\t\t\t\t\tignoreAccents: this.props.ignoreAccents,\n\t\t\t\t\tignoreCase: this.props.ignoreCase,\n\t\t\t\t\tlabelKey: this.props.labelKey,\n\t\t\t\t\tmatchPos: this.props.matchPos,\n\t\t\t\t\tmatchProp: this.props.matchProp,\n\t\t\t\t\ttrimFilter: this.props.trimFilter,\n\t\t\t\t\tvalueKey: this.props.valueKey\n\t\t\t\t});\n\t\t\t} else {\n\t\t\t\treturn options;\n\t\t\t}\n\t\t}\n\t}, {\n\t\tkey: 'onOptionRef',\n\t\tvalue: function onOptionRef(ref, isFocused) {\n\t\t\tif (isFocused) {\n\t\t\t\tthis.focused = ref;\n\t\t\t}\n\t\t}\n\t}, {\n\t\tkey: 'renderMenu',\n\t\tvalue: function renderMenu(options, valueArray, focusedOption) {\n\t\t\tif (options && options.length) {\n\t\t\t\treturn this.props.menuRenderer({\n\t\t\t\t\tfocusedOption: focusedOption,\n\t\t\t\t\tfocusOption: this.focusOption,\n\t\t\t\t\tinputValue: this.state.inputValue,\n\t\t\t\t\tinstancePrefix: this._instancePrefix,\n\t\t\t\t\tlabelKey: this.props.labelKey,\n\t\t\t\t\tonFocus: this.focusOption,\n\t\t\t\t\tonOptionRef: this.onOptionRef,\n\t\t\t\t\tonSelect: this.selectValue,\n\t\t\t\t\toptionClassName: this.props.optionClassName,\n\t\t\t\t\toptionComponent: this.props.optionComponent,\n\t\t\t\t\toptionRenderer: this.props.optionRenderer || this.getOptionLabel,\n\t\t\t\t\toptions: options,\n\t\t\t\t\tremoveValue: this.removeValue,\n\t\t\t\t\tselectValue: this.selectValue,\n\t\t\t\t\tvalueArray: valueArray,\n\t\t\t\t\tvalueKey: this.props.valueKey\n\t\t\t\t});\n\t\t\t} else if (this.props.noResultsText) {\n\t\t\t\treturn React.createElement(\n\t\t\t\t\t'div',\n\t\t\t\t\t{ className: 'Select-noresults' },\n\t\t\t\t\tthis.props.noResultsText\n\t\t\t\t);\n\t\t\t} else {\n\t\t\t\treturn null;\n\t\t\t}\n\t\t}\n\t}, {\n\t\tkey: 'renderHiddenField',\n\t\tvalue: function renderHiddenField(valueArray) {\n\t\t\tvar _this7 = this;\n\n\t\t\tif (!this.props.name) return;\n\t\t\tif (this.props.joinValues) {\n\t\t\t\tvar value = valueArray.map(function (i) {\n\t\t\t\t\treturn stringifyValue(i[_this7.props.valueKey]);\n\t\t\t\t}).join(this.props.delimiter);\n\t\t\t\treturn React.createElement('input', {\n\t\t\t\t\tdisabled: this.props.disabled,\n\t\t\t\t\tname: this.props.name,\n\t\t\t\t\tref: function ref(_ref3) {\n\t\t\t\t\t\treturn _this7.value = _ref3;\n\t\t\t\t\t},\n\t\t\t\t\ttype: 'hidden',\n\t\t\t\t\tvalue: value\n\t\t\t\t});\n\t\t\t}\n\t\t\treturn valueArray.map(function (item, index) {\n\t\t\t\treturn React.createElement('input', {\n\t\t\t\t\tdisabled: _this7.props.disabled,\n\t\t\t\t\tkey: 'hidden.' + index,\n\t\t\t\t\tname: _this7.props.name,\n\t\t\t\t\tref: 'value' + index,\n\t\t\t\t\ttype: 'hidden',\n\t\t\t\t\tvalue: stringifyValue(item[_this7.props.valueKey])\n\t\t\t\t});\n\t\t\t});\n\t\t}\n\t}, {\n\t\tkey: 'getFocusableOptionIndex',\n\t\tvalue: function getFocusableOptionIndex(selectedOption) {\n\t\t\tvar options = this._visibleOptions;\n\t\t\tif (!options.length) return null;\n\n\t\t\tvar valueKey = this.props.valueKey;\n\t\t\tvar focusedOption = this.state.focusedOption || selectedOption;\n\t\t\tif (focusedOption && !focusedOption.disabled) {\n\t\t\t\tvar focusedOptionIndex = -1;\n\t\t\t\toptions.some(function (option, index) {\n\t\t\t\t\tvar isOptionEqual = option[valueKey] === focusedOption[valueKey];\n\t\t\t\t\tif (isOptionEqual) {\n\t\t\t\t\t\tfocusedOptionIndex = index;\n\t\t\t\t\t}\n\t\t\t\t\treturn isOptionEqual;\n\t\t\t\t});\n\t\t\t\tif (focusedOptionIndex !== -1) {\n\t\t\t\t\treturn focusedOptionIndex;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tfor (var i = 0; i < options.length; i++) {\n\t\t\t\tif (!options[i].disabled) return i;\n\t\t\t}\n\t\t\treturn null;\n\t\t}\n\t}, {\n\t\tkey: 'renderOuter',\n\t\tvalue: function renderOuter(options, valueArray, focusedOption) {\n\t\t\tvar _this8 = this;\n\n\t\t\tvar menu = this.renderMenu(options, valueArray, focusedOption);\n\t\t\tif (!menu) {\n\t\t\t\treturn null;\n\t\t\t}\n\n\t\t\treturn React.createElement(\n\t\t\t\t'div',\n\t\t\t\t{ ref: function ref(_ref5) {\n\t\t\t\t\t\treturn _this8.menuContainer = _ref5;\n\t\t\t\t\t}, className: 'Select-menu-outer', style: this.props.menuContainerStyle },\n\t\t\t\tReact.createElement(\n\t\t\t\t\t'div',\n\t\t\t\t\t{\n\t\t\t\t\t\tclassName: 'Select-menu',\n\t\t\t\t\t\tid: this._instancePrefix + '-list',\n\t\t\t\t\t\tonMouseDown: this.handleMouseDownOnMenu,\n\t\t\t\t\t\tonScroll: this.handleMenuScroll,\n\t\t\t\t\t\tref: function ref(_ref4) {\n\t\t\t\t\t\t\treturn _this8.menu = _ref4;\n\t\t\t\t\t\t},\n\t\t\t\t\t\trole: 'listbox',\n\t\t\t\t\t\tstyle: this.props.menuStyle,\n\t\t\t\t\t\ttabIndex: -1\n\t\t\t\t\t},\n\t\t\t\t\tmenu\n\t\t\t\t)\n\t\t\t);\n\t\t}\n\t}, {\n\t\tkey: 'render',\n\t\tvalue: function render() {\n\t\t\tvar _this9 = this;\n\n\t\t\tvar valueArray = this.getValueArray(this.props.value);\n\t\t\tvar options = this._visibleOptions = this.filterOptions(this.props.multi && this.props.removeSelected ? valueArray : null);\n\t\t\tvar isOpen = this.state.isOpen;\n\t\t\tif (this.props.multi && !options.length && valueArray.length && !this.state.inputValue) isOpen = false;\n\t\t\tvar focusedOptionIndex = this.getFocusableOptionIndex(valueArray[0]);\n\n\t\t\tvar focusedOption = null;\n\t\t\tif (focusedOptionIndex !== null) {\n\t\t\t\tfocusedOption = this._focusedOption = options[focusedOptionIndex];\n\t\t\t} else {\n\t\t\t\tfocusedOption = this._focusedOption = null;\n\t\t\t}\n\t\t\tvar className = classNames('Select', this.props.className, {\n\t\t\t\t'has-value': valueArray.length,\n\t\t\t\t'is-clearable': this.props.clearable,\n\t\t\t\t'is-disabled': this.props.disabled,\n\t\t\t\t'is-focused': this.state.isFocused,\n\t\t\t\t'is-loading': this.props.isLoading,\n\t\t\t\t'is-open': isOpen,\n\t\t\t\t'is-pseudo-focused': this.state.isPseudoFocused,\n\t\t\t\t'is-searchable': this.props.searchable,\n\t\t\t\t'Select--multi': this.props.multi,\n\t\t\t\t'Select--rtl': this.props.rtl,\n\t\t\t\t'Select--single': !this.props.multi\n\t\t\t});\n\n\t\t\tvar removeMessage = null;\n\t\t\tif (this.props.multi && !this.props.disabled && valueArray.length && !this.state.inputValue && this.state.isFocused && this.props.backspaceRemoves) {\n\t\t\t\tremoveMessage = React.createElement(\n\t\t\t\t\t'span',\n\t\t\t\t\t{ id: this._instancePrefix + '-backspace-remove-message', className: 'Select-aria-only', 'aria-live': 'assertive' },\n\t\t\t\t\tthis.props.backspaceToRemoveMessage.replace('{label}', valueArray[valueArray.length - 1][this.props.labelKey])\n\t\t\t\t);\n\t\t\t}\n\n\t\t\treturn React.createElement(\n\t\t\t\t'div',\n\t\t\t\t{ ref: function ref(_ref7) {\n\t\t\t\t\t\treturn _this9.wrapper = _ref7;\n\t\t\t\t\t},\n\t\t\t\t\tclassName: className,\n\t\t\t\t\tstyle: this.props.wrapperStyle },\n\t\t\t\tthis.renderHiddenField(valueArray),\n\t\t\t\tReact.createElement(\n\t\t\t\t\t'div',\n\t\t\t\t\t{ ref: function ref(_ref6) {\n\t\t\t\t\t\t\treturn _this9.control = _ref6;\n\t\t\t\t\t\t},\n\t\t\t\t\t\tclassName: 'Select-control',\n\t\t\t\t\t\tonKeyDown: this.handleKeyDown,\n\t\t\t\t\t\tonMouseDown: this.handleMouseDown,\n\t\t\t\t\t\tonTouchEnd: this.handleTouchEnd,\n\t\t\t\t\t\tonTouchMove: this.handleTouchMove,\n\t\t\t\t\t\tonTouchStart: this.handleTouchStart,\n\t\t\t\t\t\tstyle: this.props.style\n\t\t\t\t\t},\n\t\t\t\t\tReact.createElement(\n\t\t\t\t\t\t'span',\n\t\t\t\t\t\t{ className: 'Select-multi-value-wrapper', id: this._instancePrefix + '-value' },\n\t\t\t\t\t\tthis.renderValue(valueArray, isOpen),\n\t\t\t\t\t\tthis.renderInput(valueArray, focusedOptionIndex)\n\t\t\t\t\t),\n\t\t\t\t\tremoveMessage,\n\t\t\t\t\tthis.renderLoading(),\n\t\t\t\t\tthis.renderClear(),\n\t\t\t\t\tthis.renderArrow()\n\t\t\t\t),\n\t\t\t\tisOpen ? this.renderOuter(options, valueArray, focusedOption) : null\n\t\t\t);\n\t\t}\n\t}]);\n\treturn Select;\n}(React.Component);\n\nSelect$1.propTypes = {\n\t'aria-describedby': PropTypes.string, // html id(s) of element(s) that should be used to describe this input (for assistive tech)\n\t'aria-label': PropTypes.string, // aria label (for assistive tech)\n\t'aria-labelledby': PropTypes.string, // html id of an element that should be used as the label (for assistive tech)\n\tarrowRenderer: PropTypes.func, // create the drop-down caret element\n\tautoBlur: PropTypes.bool, // automatically blur the component when an option is selected\n\tautoFocus: PropTypes.bool, // autofocus the component on mount\n\tautofocus: PropTypes.bool, // deprecated; use autoFocus instead\n\tautosize: PropTypes.bool, // whether to enable autosizing or not\n\tbackspaceRemoves: PropTypes.bool, // whether backspace removes an item if there is no text input\n\tbackspaceToRemoveMessage: PropTypes.string, // message to use for screenreaders to press backspace to remove the current item - {label} is replaced with the item label\n\tclassName: PropTypes.string, // className for the outer element\n\tclearAllText: stringOrNode, // title for the \"clear\" control when multi: true\n\tclearRenderer: PropTypes.func, // create clearable x element\n\tclearValueText: stringOrNode, // title for the \"clear\" control\n\tclearable: PropTypes.bool, // should it be possible to reset value\n\tcloseOnSelect: PropTypes.bool, // whether to close the menu when a value is selected\n\tdeleteRemoves: PropTypes.bool, // whether delete removes an item if there is no text input\n\tdelimiter: PropTypes.string, // delimiter to use to join multiple values for the hidden field value\n\tdisabled: PropTypes.bool, // whether the Select is disabled or not\n\tescapeClearsValue: PropTypes.bool, // whether escape clears the value when the menu is closed\n\tfilterOption: PropTypes.func, // method to filter a single option (option, filterString)\n\tfilterOptions: PropTypes.any, // boolean to enable default filtering or function to filter the options array ([options], filterString, [values])\n\tid: PropTypes.string, // html id to set on the input element for accessibility or tests\n\tignoreAccents: PropTypes.bool, // whether to strip diacritics when filtering\n\tignoreCase: PropTypes.bool, // whether to perform case-insensitive filtering\n\tinputProps: PropTypes.object, // custom attributes for the Input\n\tinputRenderer: PropTypes.func, // returns a custom input component\n\tinstanceId: PropTypes.string, // set the components instanceId\n\tisLoading: PropTypes.bool, // whether the Select is loading externally or not (such as options being loaded)\n\tjoinValues: PropTypes.bool, // joins multiple values into a single form field with the delimiter (legacy mode)\n\tlabelKey: PropTypes.string, // path of the label value in option objects\n\tmatchPos: PropTypes.string, // (any|start) match the start or entire string when filtering\n\tmatchProp: PropTypes.string, // (any|label|value) which option property to filter on\n\tmenuBuffer: PropTypes.number, // optional buffer (in px) between the bottom of the viewport and the bottom of the menu\n\tmenuContainerStyle: PropTypes.object, // optional style to apply to the menu container\n\tmenuRenderer: PropTypes.func, // renders a custom menu with options\n\tmenuStyle: PropTypes.object, // optional style to apply to the menu\n\tmulti: PropTypes.bool, // multi-value input\n\tname: PropTypes.string, // generates a hidden tag with this field name for html forms\n\tnoResultsText: stringOrNode, // placeholder displayed when there are no matching search results\n\tonBlur: PropTypes.func, // onBlur handler: function (event) {}\n\tonBlurResetsInput: PropTypes.bool, // whether input is cleared on blur\n\tonChange: PropTypes.func, // onChange handler: function (newValue) {}\n\tonClose: PropTypes.func, // fires when the menu is closed\n\tonCloseResetsInput: PropTypes.bool, // whether input is cleared when menu is closed through the arrow\n\tonFocus: PropTypes.func, // onFocus handler: function (event) {}\n\tonInputChange: PropTypes.func, // onInputChange handler: function (inputValue) {}\n\tonInputKeyDown: PropTypes.func, // input keyDown handler: function (event) {}\n\tonMenuScrollToBottom: PropTypes.func, // fires when the menu is scrolled to the bottom; can be used to paginate options\n\tonOpen: PropTypes.func, // fires when the menu is opened\n\tonSelectResetsInput: PropTypes.bool, // whether input is cleared on select (works only for multiselect)\n\tonValueClick: PropTypes.func, // onClick handler for value labels: function (value, event) {}\n\topenOnClick: PropTypes.bool, // boolean to control opening the menu when the control is clicked\n\topenOnFocus: PropTypes.bool, // always open options menu on focus\n\toptionClassName: PropTypes.string, // additional class(es) to apply to the