react-select = function (props, context, updater) { // This constructor is overridden by mocks. The argument is used // by mocks to assert on what gets mounted. if (process.env.NODE_ENV !== 'production') { process.env.NODE_ENV !== 'production' ? warning(this instanceof Constructor, 'Something is calling a React component directly . Use a factory or ' + 'JSX instead. See: https://fb.me/react-legacyfactory') : undefined; } // Wire up auto-binding if (this.__reactAutoBindMap) { bindAutoBindMethods(this); } this.props = props; this.context = context; this.refs = emptyObject; this.updater = updater || ReactNoopUpdateQueue; this.state = null; // ReactClasses doesn't have constructors. Instead, they use the // getInitialState and componentWillMount methods for initialization. var initialState = this.getInitialState ? this.getInitialState() : null; if (process.env.NODE_ENV !== 'production') { // We allow auto-mocks to proceed as if they're returning null. if (typeof initialState === 'undefined' && this.getInitialState._isMockFunction) { // This is probably bad practice. Consider warning here and // deprecating this convenience. initialState = null; } } !(typeof initialState === 'object' && !Array.isArray(initialState)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '% s.getInitialState(): must return an object or null', Constructor.displayName || 'ReactCompositeComponent') : invariant(false) : undefined; this.state = initialState; }
n/a
defaultProps.optionComponent = function (props, context, updater) { // This constructor is overridden by mocks. The argument is used // by mocks to assert on what gets mounted. if (process.env.NODE_ENV !== 'production') { process.env.NODE_ENV !== 'production' ? warning(this instanceof Constructor, 'Something is calling a React component directly . Use a factory or ' + 'JSX instead. See: https://fb.me/react-legacyfactory') : undefined; } // Wire up auto-binding if (this.__reactAutoBindMap) { bindAutoBindMethods(this); } this.props = props; this.context = context; this.refs = emptyObject; this.updater = updater || ReactNoopUpdateQueue; this.state = null; // ReactClasses doesn't have constructors. Instead, they use the // getInitialState and componentWillMount methods for initialization. var initialState = this.getInitialState ? this.getInitialState() : null; if (process.env.NODE_ENV !== 'production') { // We allow auto-mocks to proceed as if they're returning null. if (typeof initialState === 'undefined' && this.getInitialState._isMockFunction) { // This is probably bad practice. Consider warning here and // deprecating this convenience. initialState = null; } } !(typeof initialState === 'object' && !Array.isArray(initialState)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '% s.getInitialState(): must return an object or null', Constructor.displayName || 'ReactCompositeComponent') : invariant(false) : undefined; this.state = initialState; }
n/a
defaultProps.singleValueComponent = function (props, context, updater) { // This constructor is overridden by mocks. The argument is used // by mocks to assert on what gets mounted. if (process.env.NODE_ENV !== 'production') { process.env.NODE_ENV !== 'production' ? warning(this instanceof Constructor, 'Something is calling a React component directly . Use a factory or ' + 'JSX instead. See: https://fb.me/react-legacyfactory') : undefined; } // Wire up auto-binding if (this.__reactAutoBindMap) { bindAutoBindMethods(this); } this.props = props; this.context = context; this.refs = emptyObject; this.updater = updater || ReactNoopUpdateQueue; this.state = null; // ReactClasses doesn't have constructors. Instead, they use the // getInitialState and componentWillMount methods for initialization. var initialState = this.getInitialState ? this.getInitialState() : null; if (process.env.NODE_ENV !== 'production') { // We allow auto-mocks to proceed as if they're returning null. if (typeof initialState === 'undefined' && this.getInitialState._isMockFunction) { // This is probably bad practice. Consider warning here and // deprecating this convenience. initialState = null; } } !(typeof initialState === 'object' && !Array.isArray(initialState)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '% s.getInitialState(): must return an object or null', Constructor.displayName || 'ReactCompositeComponent') : invariant(false) : undefined; this.state = initialState; }
n/a
defaultProps.valueComponent = function (props, context, updater) { // This constructor is overridden by mocks. The argument is used // by mocks to assert on what gets mounted. if (process.env.NODE_ENV !== 'production') { process.env.NODE_ENV !== 'production' ? warning(this instanceof Constructor, 'Something is calling a React component directly . Use a factory or ' + 'JSX instead. See: https://fb.me/react-legacyfactory') : undefined; } // Wire up auto-binding if (this.__reactAutoBindMap) { bindAutoBindMethods(this); } this.props = props; this.context = context; this.refs = emptyObject; this.updater = updater || ReactNoopUpdateQueue; this.state = null; // ReactClasses doesn't have constructors. Instead, they use the // getInitialState and componentWillMount methods for initialization. var initialState = this.getInitialState ? this.getInitialState() : null; if (process.env.NODE_ENV !== 'production') { // We allow auto-mocks to proceed as if they're returning null. if (typeof initialState === 'undefined' && this.getInitialState._isMockFunction) { // This is probably bad practice. Consider warning here and // deprecating this convenience. initialState = null; } } !(typeof initialState === 'object' && !Array.isArray(initialState)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '% s.getInitialState(): must return an object or null', Constructor.displayName || 'ReactCompositeComponent') : invariant(false) : undefined; this.state = initialState; }
n/a
function getDefaultProps() { return { addLabelText: 'Add "{label}"?', allowCreate: false, asyncOptions: undefined, autoload: true, backspaceRemoves: true, cacheAsyncResults: true, className: undefined, clearAllText: 'Clear all', clearValueText: 'Clear value', clearable: true, delimiter: ',', disabled: false, ignoreCase: true, inputProps: {}, isLoading: false, labelKey: 'label', matchPos: 'any', matchProp: 'any', name: undefined, newOptionCreator: undefined, noResultsText: 'No results found', onChange: undefined, onInputChange: undefined, onOptionLabelClick: undefined, optionComponent: Option, options: undefined, placeholder: 'Select...', searchable: true, searchingText: 'Searching...', searchPromptText: 'Type to search', singleValueComponent: SingleValue, value: undefined, valueComponent: Value, valueKey: 'value' }; }
...
mixSpecIntoComponent.bind(null, Constructor)
);
mixSpecIntoComponent(Constructor, spec);
// Initialize the defaultProps property after all mixins have been merged
if (Constructor.getDefaultProps) {
Constructor.defaultProps = Constructor.getDefaultProps();
}
if ("production" !== process.env.NODE_ENV) {
// This is a tag to indicate that the use of these method names is ok,
// since it's used with createClass. If it's not, then it's likely a
// mistake so we'll warn you to use the static property, property
// initializer or constructor respectively.
...
propTypes.addLabelText = function () { [native code] }
n/a
propTypes.allowCreate = function () { [native code] }
n/a
propTypes.asyncOptions = function () { [native code] }
n/a
propTypes.inputProps = function () { [native code] }
n/a
propTypes.options = function () { [native code] }
n/a
propTypes.value = function () { [native code] }
n/a
optionComponent = function (props, context, updater) { // This constructor is overridden by mocks. The argument is used // by mocks to assert on what gets mounted. if (process.env.NODE_ENV !== 'production') { process.env.NODE_ENV !== 'production' ? warning(this instanceof Constructor, 'Something is calling a React component directly . Use a factory or ' + 'JSX instead. See: https://fb.me/react-legacyfactory') : undefined; } // Wire up auto-binding if (this.__reactAutoBindMap) { bindAutoBindMethods(this); } this.props = props; this.context = context; this.refs = emptyObject; this.updater = updater || ReactNoopUpdateQueue; this.state = null; // ReactClasses doesn't have constructors. Instead, they use the // getInitialState and componentWillMount methods for initialization. var initialState = this.getInitialState ? this.getInitialState() : null; if (process.env.NODE_ENV !== 'production') { // We allow auto-mocks to proceed as if they're returning null. if (typeof initialState === 'undefined' && this.getInitialState._isMockFunction) { // This is probably bad practice. Consider warning here and // deprecating this convenience. initialState = null; } } !(typeof initialState === 'object' && !Array.isArray(initialState)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '% s.getInitialState(): must return an object or null', Constructor.displayName || 'ReactCompositeComponent') : invariant(false) : undefined; this.state = initialState; }
n/a
singleValueComponent = function (props, context, updater) { // This constructor is overridden by mocks. The argument is used // by mocks to assert on what gets mounted. if (process.env.NODE_ENV !== 'production') { process.env.NODE_ENV !== 'production' ? warning(this instanceof Constructor, 'Something is calling a React component directly . Use a factory or ' + 'JSX instead. See: https://fb.me/react-legacyfactory') : undefined; } // Wire up auto-binding if (this.__reactAutoBindMap) { bindAutoBindMethods(this); } this.props = props; this.context = context; this.refs = emptyObject; this.updater = updater || ReactNoopUpdateQueue; this.state = null; // ReactClasses doesn't have constructors. Instead, they use the // getInitialState and componentWillMount methods for initialization. var initialState = this.getInitialState ? this.getInitialState() : null; if (process.env.NODE_ENV !== 'production') { // We allow auto-mocks to proceed as if they're returning null. if (typeof initialState === 'undefined' && this.getInitialState._isMockFunction) { // This is probably bad practice. Consider warning here and // deprecating this convenience. initialState = null; } } !(typeof initialState === 'object' && !Array.isArray(initialState)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '% s.getInitialState(): must return an object or null', Constructor.displayName || 'ReactCompositeComponent') : invariant(false) : undefined; this.state = initialState; }
n/a
valueComponent = function (props, context, updater) { // This constructor is overridden by mocks. The argument is used // by mocks to assert on what gets mounted. if (process.env.NODE_ENV !== 'production') { process.env.NODE_ENV !== 'production' ? warning(this instanceof Constructor, 'Something is calling a React component directly . Use a factory or ' + 'JSX instead. See: https://fb.me/react-legacyfactory') : undefined; } // Wire up auto-binding if (this.__reactAutoBindMap) { bindAutoBindMethods(this); } this.props = props; this.context = context; this.refs = emptyObject; this.updater = updater || ReactNoopUpdateQueue; this.state = null; // ReactClasses doesn't have constructors. Instead, they use the // getInitialState and componentWillMount methods for initialization. var initialState = this.getInitialState ? this.getInitialState() : null; if (process.env.NODE_ENV !== 'production') { // We allow auto-mocks to proceed as if they're returning null. if (typeof initialState === 'undefined' && this.getInitialState._isMockFunction) { // This is probably bad practice. Consider warning here and // deprecating this convenience. initialState = null; } } !(typeof initialState === 'object' && !Array.isArray(initialState)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '% s.getInitialState(): must return an object or null', Constructor.displayName || 'ReactCompositeComponent') : invariant(false) : undefined; this.state = initialState; }
n/a
optionComponent = function (props, context, updater) { // This constructor is overridden by mocks. The argument is used // by mocks to assert on what gets mounted. if (process.env.NODE_ENV !== 'production') { process.env.NODE_ENV !== 'production' ? warning(this instanceof Constructor, 'Something is calling a React component directly . Use a factory or ' + 'JSX instead. See: https://fb.me/react-legacyfactory') : undefined; } // Wire up auto-binding if (this.__reactAutoBindMap) { bindAutoBindMethods(this); } this.props = props; this.context = context; this.refs = emptyObject; this.updater = updater || ReactNoopUpdateQueue; this.state = null; // ReactClasses doesn't have constructors. Instead, they use the // getInitialState and componentWillMount methods for initialization. var initialState = this.getInitialState ? this.getInitialState() : null; if (process.env.NODE_ENV !== 'production') { // We allow auto-mocks to proceed as if they're returning null. if (typeof initialState === 'undefined' && this.getInitialState._isMockFunction) { // This is probably bad practice. Consider warning here and // deprecating this convenience. initialState = null; } } !(typeof initialState === 'object' && !Array.isArray(initialState)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '% s.getInitialState(): must return an object or null', Constructor.displayName || 'ReactCompositeComponent') : invariant(false) : undefined; this.state = initialState; }
n/a
function blockEvent(event) { event.preventDefault(); if (event.target.tagName !== 'A' || !('href' in event.target)) { return; } if (event.target.target) { window.open(event.target.href); } else { window.location.href = event.target.href; } }
n/a
constructor = function (props, context, updater) { // This constructor is overridden by mocks. The argument is used // by mocks to assert on what gets mounted. if (process.env.NODE_ENV !== 'production') { process.env.NODE_ENV !== 'production' ? warning(this instanceof Constructor, 'Something is calling a React component directly . Use a factory or ' + 'JSX instead. See: https://fb.me/react-legacyfactory') : undefined; } // Wire up auto-binding if (this.__reactAutoBindMap) { bindAutoBindMethods(this); } this.props = props; this.context = context; this.refs = emptyObject; this.updater = updater || ReactNoopUpdateQueue; this.state = null; // ReactClasses doesn't have constructors. Instead, they use the // getInitialState and componentWillMount methods for initialization. var initialState = this.getInitialState ? this.getInitialState() : null; if (process.env.NODE_ENV !== 'production') { // We allow auto-mocks to proceed as if they're returning null. if (typeof initialState === 'undefined' && this.getInitialState._isMockFunction) { // This is probably bad practice. Consider warning here and // deprecating this convenience. initialState = null; } } !(typeof initialState === 'object' && !Array.isArray(initialState)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '% s.getInitialState(): must return an object or null', Constructor.displayName || 'ReactCompositeComponent') : invariant(false) : undefined; this.state = initialState; }
n/a
getDOMNode = function () { process.env.NODE_ENV !== 'production' ? warning(this.constructor[didWarnKey], '%s.getDOMNode(...) is deprecated. Please use ' + ' ReactDOM.findDOMNode(instance) instead.', ReactInstanceMap.get(this).getName() || this.tagName || 'Unknown') : undefined; this.constructor[didWarnKey] = true; return findDOMNode(this); }
...
'use strict';
var focusNode = require("./focusNode");
var AutoFocusMixin = {
componentDidMount: function() {
if (this.props.autoFocus) {
focusNode(this.getDOMNode());
}
}
};
module.exports = AutoFocusMixin;
},{"./focusNode":120}],3:[function(require,module,exports){
...
function handleMouseDown(e) { this.props.mouseDown(this.props.option, e); }
n/a
function handleMouseEnter(e) { this.props.mouseEnter(this.props.option, e); }
n/a
function handleMouseLeave(e) { this.props.mouseLeave(this.props.option, e); }
n/a
function render() { var option = this.props.option; var label = option.create ? this.props.addLabelText.replace('{label}', option.label) : this.props.renderFunc(option); var optionClasses = classes(this.props.className, option.className); return option.disabled ? React.createElement( 'div', { className: optionClasses, onMouseDown: this.blockEvent, onClick: this.blockEvent }, label ) : React.createElement( 'div', { className: optionClasses, style: option.style, onMouseDown: this.handleMouseDown, onMouseEnter: this.handleMouseEnter, onMouseLeave: this.handleMouseLeave, onClick: this.handleMouseDown, title: option.title }, label ); }
...
},
/**
* @protected
*/
_renderValidatedComponentWithoutOwnerOrContext: function() {
var inst = this._instance;
var renderedComponent = inst.render();
if ("production" !== process.env.NODE_ENV) {
// We allow auto-mocks to proceed as if they're returning null.
if (typeof renderedComponent === 'undefined' &&
inst.render._isMockFunction) {
// This is probably bad practice. Consider warning here and
// deprecating this convenience.
renderedComponent = null;
...
function blockEvent(event) { event.preventDefault(); if (event.target.tagName !== 'A' || !('href' in event.target)) { return; } if (event.target.target) { window.open(event.target.href); } else { window.location.href = event.target.href; } }
n/a
getDOMNode = function () { process.env.NODE_ENV !== 'production' ? warning(this.constructor[didWarnKey], '%s.getDOMNode(...) is deprecated. Please use ' + ' ReactDOM.findDOMNode(instance) instead.', ReactInstanceMap.get(this).getName() || this.tagName || 'Unknown') : undefined; this.constructor[didWarnKey] = true; return findDOMNode(this); }
...
'use strict';
var focusNode = require("./focusNode");
var AutoFocusMixin = {
componentDidMount: function() {
if (this.props.autoFocus) {
focusNode(this.getDOMNode());
}
}
};
module.exports = AutoFocusMixin;
},{"./focusNode":120}],3:[function(require,module,exports){
...
function handleMouseDown(e) { this.props.mouseDown(this.props.option, e); }
n/a
function handleMouseEnter(e) { this.props.mouseEnter(this.props.option, e); }
n/a
function handleMouseLeave(e) { this.props.mouseLeave(this.props.option, e); }
n/a
singleValueComponent = function (props, context, updater) { // This constructor is overridden by mocks. The argument is used // by mocks to assert on what gets mounted. if (process.env.NODE_ENV !== 'production') { process.env.NODE_ENV !== 'production' ? warning(this instanceof Constructor, 'Something is calling a React component directly . Use a factory or ' + 'JSX instead. See: https://fb.me/react-legacyfactory') : undefined; } // Wire up auto-binding if (this.__reactAutoBindMap) { bindAutoBindMethods(this); } this.props = props; this.context = context; this.refs = emptyObject; this.updater = updater || ReactNoopUpdateQueue; this.state = null; // ReactClasses doesn't have constructors. Instead, they use the // getInitialState and componentWillMount methods for initialization. var initialState = this.getInitialState ? this.getInitialState() : null; if (process.env.NODE_ENV !== 'production') { // We allow auto-mocks to proceed as if they're returning null. if (typeof initialState === 'undefined' && this.getInitialState._isMockFunction) { // This is probably bad practice. Consider warning here and // deprecating this convenience. initialState = null; } } !(typeof initialState === 'object' && !Array.isArray(initialState)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '% s.getInitialState(): must return an object or null', Constructor.displayName || 'ReactCompositeComponent') : invariant(false) : undefined; this.state = initialState; }
n/a
constructor = function (props, context, updater) { // This constructor is overridden by mocks. The argument is used // by mocks to assert on what gets mounted. if (process.env.NODE_ENV !== 'production') { process.env.NODE_ENV !== 'production' ? warning(this instanceof Constructor, 'Something is calling a React component directly . Use a factory or ' + 'JSX instead. See: https://fb.me/react-legacyfactory') : undefined; } // Wire up auto-binding if (this.__reactAutoBindMap) { bindAutoBindMethods(this); } this.props = props; this.context = context; this.refs = emptyObject; this.updater = updater || ReactNoopUpdateQueue; this.state = null; // ReactClasses doesn't have constructors. Instead, they use the // getInitialState and componentWillMount methods for initialization. var initialState = this.getInitialState ? this.getInitialState() : null; if (process.env.NODE_ENV !== 'production') { // We allow auto-mocks to proceed as if they're returning null. if (typeof initialState === 'undefined' && this.getInitialState._isMockFunction) { // This is probably bad practice. Consider warning here and // deprecating this convenience. initialState = null; } } !(typeof initialState === 'object' && !Array.isArray(initialState)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '% s.getInitialState(): must return an object or null', Constructor.displayName || 'ReactCompositeComponent') : invariant(false) : undefined; this.state = initialState; }
n/a
getDOMNode = function () { process.env.NODE_ENV !== 'production' ? warning(this.constructor[didWarnKey], '%s.getDOMNode(...) is deprecated. Please use ' + ' ReactDOM.findDOMNode(instance) instead.', ReactInstanceMap.get(this).getName() || this.tagName || 'Unknown') : undefined; this.constructor[didWarnKey] = true; return findDOMNode(this); }
...
'use strict';
var focusNode = require("./focusNode");
var AutoFocusMixin = {
componentDidMount: function() {
if (this.props.autoFocus) {
focusNode(this.getDOMNode());
}
}
};
module.exports = AutoFocusMixin;
},{"./focusNode":120}],3:[function(require,module,exports){
...
function render() { var classNames = classes('Select-placeholder', this.props.value && this.props.value.className); return React.createElement( 'div', { className: classNames, style: this.props.value && this.props.value.style, title: this.props.value && this.props.value.title }, this.props.placeholder ); }
...
},
/**
* @protected
*/
_renderValidatedComponentWithoutOwnerOrContext: function() {
var inst = this._instance;
var renderedComponent = inst.render();
if ("production" !== process.env.NODE_ENV) {
// We allow auto-mocks to proceed as if they're returning null.
if (typeof renderedComponent === 'undefined' &&
inst.render._isMockFunction) {
// This is probably bad practice. Consider warning here and
// deprecating this convenience.
renderedComponent = null;
...
getDOMNode = function () { process.env.NODE_ENV !== 'production' ? warning(this.constructor[didWarnKey], '%s.getDOMNode(...) is deprecated. Please use ' + ' ReactDOM.findDOMNode(instance) instead.', ReactInstanceMap.get(this).getName() || this.tagName || 'Unknown') : undefined; this.constructor[didWarnKey] = true; return findDOMNode(this); }
...
'use strict';
var focusNode = require("./focusNode");
var AutoFocusMixin = {
componentDidMount: function() {
if (this.props.autoFocus) {
focusNode(this.getDOMNode());
}
}
};
module.exports = AutoFocusMixin;
},{"./focusNode":120}],3:[function(require,module,exports){
...
valueComponent = function (props, context, updater) { // This constructor is overridden by mocks. The argument is used // by mocks to assert on what gets mounted. if (process.env.NODE_ENV !== 'production') { process.env.NODE_ENV !== 'production' ? warning(this instanceof Constructor, 'Something is calling a React component directly . Use a factory or ' + 'JSX instead. See: https://fb.me/react-legacyfactory') : undefined; } // Wire up auto-binding if (this.__reactAutoBindMap) { bindAutoBindMethods(this); } this.props = props; this.context = context; this.refs = emptyObject; this.updater = updater || ReactNoopUpdateQueue; this.state = null; // ReactClasses doesn't have constructors. Instead, they use the // getInitialState and componentWillMount methods for initialization. var initialState = this.getInitialState ? this.getInitialState() : null; if (process.env.NODE_ENV !== 'production') { // We allow auto-mocks to proceed as if they're returning null. if (typeof initialState === 'undefined' && this.getInitialState._isMockFunction) { // This is probably bad practice. Consider warning here and // deprecating this convenience. initialState = null; } } !(typeof initialState === 'object' && !Array.isArray(initialState)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '% s.getInitialState(): must return an object or null', Constructor.displayName || 'ReactCompositeComponent') : invariant(false) : undefined; this.state = initialState; }
n/a
function blockEvent(event) { event.stopPropagation(); }
n/a
constructor = function (props, context, updater) { // This constructor is overridden by mocks. The argument is used // by mocks to assert on what gets mounted. if (process.env.NODE_ENV !== 'production') { process.env.NODE_ENV !== 'production' ? warning(this instanceof Constructor, 'Something is calling a React component directly . Use a factory or ' + 'JSX instead. See: https://fb.me/react-legacyfactory') : undefined; } // Wire up auto-binding if (this.__reactAutoBindMap) { bindAutoBindMethods(this); } this.props = props; this.context = context; this.refs = emptyObject; this.updater = updater || ReactNoopUpdateQueue; this.state = null; // ReactClasses doesn't have constructors. Instead, they use the // getInitialState and componentWillMount methods for initialization. var initialState = this.getInitialState ? this.getInitialState() : null; if (process.env.NODE_ENV !== 'production') { // We allow auto-mocks to proceed as if they're returning null. if (typeof initialState === 'undefined' && this.getInitialState._isMockFunction) { // This is probably bad practice. Consider warning here and // deprecating this convenience. initialState = null; } } !(typeof initialState === 'object' && !Array.isArray(initialState)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '% s.getInitialState(): must return an object or null', Constructor.displayName || 'ReactCompositeComponent') : invariant(false) : undefined; this.state = initialState; }
n/a
getDOMNode = function () { process.env.NODE_ENV !== 'production' ? warning(this.constructor[didWarnKey], '%s.getDOMNode(...) is deprecated. Please use ' + ' ReactDOM.findDOMNode(instance) instead.', ReactInstanceMap.get(this).getName() || this.tagName || 'Unknown') : undefined; this.constructor[didWarnKey] = true; return findDOMNode(this); }
...
'use strict';
var focusNode = require("./focusNode");
var AutoFocusMixin = {
componentDidMount: function() {
if (this.props.autoFocus) {
focusNode(this.getDOMNode());
}
}
};
module.exports = AutoFocusMixin;
},{"./focusNode":120}],3:[function(require,module,exports){
...
function handleOnRemove(event) { if (!this.props.disabled) { this.props.onRemove(event); } }
n/a
function render() { var label = this.props.option.label; if (this.props.renderer) { label = this.props.renderer(this.props.option); } if (!this.props.onRemove && !this.props.optionLabelClick) { return React.createElement( 'div', { className: classes('Select-value', this.props.option.className), style: this.props.option.style, title: this.props.option.title }, label ); } if (this.props.optionLabelClick) { label = React.createElement( 'a', { className: classes('Select-item-label__a', this.props.option.className), onMouseDown: this.blockEvent, onTouchEnd: this.props.onOptionLabelClick, onClick: this.props.onOptionLabelClick, style: this.props.option.style, title: this.props.option.title }, label ); } return React.createElement( 'div', { className: classes('Select-item', this.props.option.className), style: this.props.option.style, title: this.props.option.title }, React.createElement( 'span', { className: 'Select-item-icon', onMouseDown: this.blockEvent, onClick: this.handleOnRemove, onTouchEnd: this.handleOnRemove }, '×' ), React.createElement( 'span', { className: 'Select-item-label' }, label ) ); }
...
},
/**
* @protected
*/
_renderValidatedComponentWithoutOwnerOrContext: function() {
var inst = this._instance;
var renderedComponent = inst.render();
if ("production" !== process.env.NODE_ENV) {
// We allow auto-mocks to proceed as if they're returning null.
if (typeof renderedComponent === 'undefined' &&
inst.render._isMockFunction) {
// This is probably bad practice. Consider warning here and
// deprecating this convenience.
renderedComponent = null;
...
function blockEvent(event) { event.stopPropagation(); }
n/a
getDOMNode = function () { process.env.NODE_ENV !== 'production' ? warning(this.constructor[didWarnKey], '%s.getDOMNode(...) is deprecated. Please use ' + ' ReactDOM.findDOMNode(instance) instead.', ReactInstanceMap.get(this).getName() || this.tagName || 'Unknown') : undefined; this.constructor[didWarnKey] = true; return findDOMNode(this); }
...
'use strict';
var focusNode = require("./focusNode");
var AutoFocusMixin = {
componentDidMount: function() {
if (this.props.autoFocus) {
focusNode(this.getDOMNode());
}
}
};
module.exports = AutoFocusMixin;
},{"./focusNode":120}],3:[function(require,module,exports){
...
function handleOnRemove(event) { if (!this.props.disabled) { this.props.onRemove(event); } }
n/a
installInto = function (expect) { expect.addType({ name: 'NodeList', base: 'array-like', identify: value => { return typeof window !== 'undefined' && typeof window.NodeList === 'function' && value instanceof window.NodeList; } }); }
n/a
addLabelText = function () { [native code] }
n/a
allowCreate = function () { [native code] }
n/a
asyncOptions = function () { [native code] }
...
this.setState(newState);
if (callback) callback.call(this, newState);
return;
}
}
}
this.props.asyncOptions(input, function (err, data) {
if (err) throw err;
if (_this6.props.cacheAsyncResults) {
_this6._optionsCache[input] = data;
}
if (thisRequestId !== _this6._currentRequestId) {
return;
}
...
autoload = function () { [native code] }
n/a
backspaceRemoves = function () { [native code] }
n/a
cacheAsyncResults = function () { [native code] }
n/a
className = function () { [native code] }
n/a
clearAllText = function () { [native code] }
n/a
clearValueText = function () { [native code] }
n/a
clearable = function () { [native code] }
n/a
delimiter = function () { [native code] }
n/a
disabled = function () { [native code] }
n/a
filterOption = function () { [native code] }
n/a
filterOptions = function () { [native code] }
...
var _this2 = this;
var optionsChanged = false;
if (JSON.stringify(newProps.options) !== JSON.stringify(this.props.options)) {
optionsChanged = true;
this.setState({
options: newProps.options,
filteredOptions: this.filterOptions(newProps.options)
});
}
if (newProps.value !== this.state.value || newProps.placeholder !== this.props.placeholder || optionsChanged) {
var setState = function setState(newState) {
_this2.setState(_this2.getStateFromValue(newProps.value, newState && newState.options || newProps.options, newProps
.placeholder));
};
if (this.props.asyncOptions) {
...
ignoreCase = function () { [native code] }
n/a
inputProps = function () { [native code] }
n/a
isLoading = function () { [native code] }
n/a
labelKey = function () { [native code] }
n/a
matchPos = function () { [native code] }
n/a
matchProp = function () { [native code] }
n/a
multi = function () { [native code] }
n/a
name = function () { [native code] }
n/a
newOptionCreator = function () { [native code] }
...
focusedValue = focusedValue == null ? this.state.filteredOptions[0] : focusedValue;
}
// Add the current value to the filtered options in last resort
var options = this.state.filteredOptions;
if (this.props.allowCreate && this.state.inputValue.trim()) {
var inputValue = this.state.inputValue;
options = options.slice();
var newOption = this.props.newOptionCreator ? this.props.newOptionCreator(inputValue
) : {
value: inputValue,
label: inputValue,
create: true
};
options.unshift(newOption);
}
var ops = Object.keys(options).map(function (key) {
...
noResultsText = function () { [native code] }
n/a
onBlur = function () { [native code] }
...
if (_this4._focusAfterUpdate) return;
_this4.setState({
isFocused: false,
isOpen: false
});
}, 50);
if (this.props.onBlur) {
this.props.onBlur(event);
}
},
handleKeyDown: function handleKeyDown(event) {
event.preventDefault();
if (this.props.disabled) return;
switch (event.keyCode) {
...
onChange = function () { [native code] }
...
getInputNode: function getInputNode() {
var input = this.refs.input;
return this.props.searchable ? input : React.findDOMNode(input);
},
fireChangeEvent: function fireChangeEvent(newState) {
if (newState.value !== this.state.value && this.props.onChange) {
this.props.onChange(newState.value, newState.values);
}
},
handleMouseDown: function handleMouseDown(event) {
// if the event was triggered by a mousedown and not the primary
// button, or if the component is disabled, ignore it.
if (this.props.disabled || event.type === 'mousedown' && event.button !== 0) {
...
onFocus = function () { [native code] }
...
this._bindCloseMenuIfClickedOutside();
} else {
this._unbindCloseMenuIfClickedOutside();
}
});
this._openAfterFocus = false;
if (this.props.onFocus) {
this.props.onFocus(event);
}
},
handleInputBlur: function handleInputBlur(event) {
var _this4 = this;
this._blurTimeout = setTimeout(function () {
...
onInputChange = function () { [native code] }
n/a
onOptionLabelClick = function () { [native code] }
...
noResultsText
);
}
},
handleOptionLabelClick: function handleOptionLabelClick(value, event) {
if (this.props.onOptionLabelClick) {
this.props.onOptionLabelClick(value, event);
}
},
render: function render() {
var selectClass = classes('Select', this.props.className, {
'is-multi': this.props.multi,
'is-searchable': this.props.searchable,
...
optionComponent = function () { [native code] }
n/a
optionRenderer = function () { [native code] }
n/a
options = function () { [native code] }
n/a
placeholder = function () { [native code] }
n/a
searchPromptText = function () { [native code] }
n/a
searchable = function () { [native code] }
n/a
searchingText = function () { [native code] }
n/a
singleValueComponent = function () { [native code] }
n/a
value = function () { [native code] }
n/a
valueComponent = function () { [native code] }
n/a
valueKey = function () { [native code] }
n/a
valueRenderer = function () { [native code] }
n/a
addLabelText = function () { [native code] }
n/a
isRequired = function () { [native code] }
n/a
allowCreate = function () { [native code] }
n/a
isRequired = function () { [native code] }
n/a
asyncOptions = function () { [native code] }
...
this.setState(newState);
if (callback) callback.call(this, newState);
return;
}
}
}
this.props.asyncOptions(input, function (err, data) {
if (err) throw err;
if (_this6.props.cacheAsyncResults) {
_this6._optionsCache[input] = data;
}
if (thisRequestId !== _this6._currentRequestId) {
return;
}
...
isRequired = function () { [native code] }
n/a
inputProps = function () { [native code] }
n/a
isRequired = function () { [native code] }
n/a
options = function () { [native code] }
n/a
isRequired = function () { [native code] }
n/a
value = function () { [native code] }
n/a
isRequired = function () { [native code] }
n/a