@progress/kendo-react-dropdowns
Advanced tools
Comparing version 0.4.0-dev.201802161152 to 0.4.0-dev.201802210843
@@ -12,2 +12,3 @@ /// <reference types="react" /> | ||
last?: string; | ||
filterInputFocused?: boolean; | ||
} | ||
@@ -17,2 +18,8 @@ /** | ||
*/ | ||
export interface DropDownListInternalState extends InternalState { | ||
data: DropDownListState; | ||
} | ||
/** | ||
* @hidden | ||
*/ | ||
export default class DropDownList extends React.Component<DropDownListProps, DropDownListState> { | ||
@@ -81,3 +88,3 @@ static propTypes: { | ||
setValueSelection: (value: any, text: any, selected: any, state: InternalState) => void; | ||
togglePopup: (state: InternalState) => void; | ||
togglePopup: (state: DropDownListInternalState) => void; | ||
render(): JSX.Element; | ||
@@ -96,3 +103,4 @@ private renderDropDownWrapper; | ||
private filteringInputDidFocus; | ||
private onPopupOpened; | ||
private onPopupClosed; | ||
} |
@@ -60,2 +60,3 @@ var __extends = (this && this.__extends) || (function () { | ||
state.data.isFocused = false; | ||
state.data.filterInputFocused = false; | ||
state.data.opened = false; | ||
@@ -131,2 +132,5 @@ state.events.push({ type: 'onBlur' }); | ||
} | ||
if (_this.props.filterable && _this.state.filterInputFocused) { | ||
state.data.filterInputFocused = false; | ||
} | ||
}; | ||
@@ -154,3 +158,2 @@ _this.renderDropDownWrapper = function () { | ||
var virtual = _this.props.virtual !== undefined; | ||
var vs = _this.base.vs; | ||
var listContainerProps = { | ||
@@ -165,2 +168,3 @@ onMouseDown: function (e) { | ||
popupSettings: { | ||
className: 'k-list-container k-reset', | ||
animate: (popupSettings || {}).animate, | ||
@@ -170,10 +174,4 @@ anchor: _this.element, | ||
show: opened, | ||
open: function () { | ||
vs.hidden = false; | ||
}, | ||
className: 'k-list-container k-reset', | ||
close: function () { | ||
vs.hidden = true; | ||
_this.onPopupClosed(); | ||
} | ||
open: _this.onPopupOpened, | ||
close: _this.onPopupClosed | ||
} | ||
@@ -227,4 +225,4 @@ }; | ||
var filterable = _this.props.filterable; | ||
var _a = _this.state, opened = _a.opened, filterText = _a.filterText; | ||
return filterable && (React.createElement(ListFilter, { value: filterText, focused: opened, willFocus: _this.filteringInputWillFocus, didFocus: _this.filteringInputDidFocus, onChange: _this.handleListFilterChange, onKeyDown: _this.handleKeyDown })); | ||
var _a = _this.state, opened = _a.opened, filterText = _a.filterText, filterInputFocused = _a.filterInputFocused; | ||
return filterable && (React.createElement(ListFilter, { value: filterText, focused: opened && filterInputFocused, willFocus: _this.filteringInputWillFocus, didFocus: _this.filteringInputDidFocus, onChange: _this.handleListFilterChange, onKeyDown: _this.handleKeyDown })); | ||
}; | ||
@@ -286,6 +284,23 @@ _this.renderDefaultItem = function () { | ||
}; | ||
_this.onPopupOpened = function () { | ||
_this.base.vs.hidden = false; | ||
if (_this.props.filterable) { | ||
_this.setState({ | ||
filterInputFocused: true | ||
}); | ||
} | ||
else { | ||
var wrapper = ReactDOM.findDOMNode(_this.base.wrapper); | ||
if (_this.state.isFocused && document.activeElement !== wrapper) { | ||
wrapper.focus(); | ||
} | ||
} | ||
}; | ||
_this.onPopupClosed = function () { | ||
_this.base.vs.hidden = true; | ||
if (_this.state.isFocused) { | ||
var wrapper_1 = ReactDOM.findDOMNode(_this.base.wrapper); | ||
setTimeout(function () { wrapper_1.focus(); }, 0); | ||
setTimeout(function () { if (_this.state.isFocused) { | ||
wrapper_1.focus(); | ||
} }, 0); | ||
} | ||
@@ -308,2 +323,3 @@ }; | ||
isFocused: false, | ||
filterInputFocused: false, | ||
opened: _this.props.opened, | ||
@@ -310,0 +326,0 @@ }; |
@@ -12,2 +12,3 @@ /// <reference types="react" /> | ||
last?: string; | ||
filterInputFocused?: boolean; | ||
} | ||
@@ -17,2 +18,8 @@ /** | ||
*/ | ||
export interface DropDownListInternalState extends InternalState { | ||
data: DropDownListState; | ||
} | ||
/** | ||
* @hidden | ||
*/ | ||
export default class DropDownList extends React.Component<DropDownListProps, DropDownListState> { | ||
@@ -81,3 +88,3 @@ static propTypes: { | ||
setValueSelection: (value: any, text: any, selected: any, state: InternalState) => void; | ||
togglePopup: (state: InternalState) => void; | ||
togglePopup: (state: DropDownListInternalState) => void; | ||
render(): JSX.Element; | ||
@@ -96,3 +103,4 @@ private renderDropDownWrapper; | ||
private filteringInputDidFocus; | ||
private onPopupOpened; | ||
private onPopupClosed; | ||
} |
@@ -62,2 +62,3 @@ "use strict"; | ||
state.data.isFocused = false; | ||
state.data.filterInputFocused = false; | ||
state.data.opened = false; | ||
@@ -133,2 +134,5 @@ state.events.push({ type: 'onBlur' }); | ||
} | ||
if (_this.props.filterable && _this.state.filterInputFocused) { | ||
state.data.filterInputFocused = false; | ||
} | ||
}; | ||
@@ -156,3 +160,2 @@ _this.renderDropDownWrapper = function () { | ||
var virtual = _this.props.virtual !== undefined; | ||
var vs = _this.base.vs; | ||
var listContainerProps = { | ||
@@ -167,2 +170,3 @@ onMouseDown: function (e) { | ||
popupSettings: { | ||
className: 'k-list-container k-reset', | ||
animate: (popupSettings || {}).animate, | ||
@@ -172,10 +176,4 @@ anchor: _this.element, | ||
show: opened, | ||
open: function () { | ||
vs.hidden = false; | ||
}, | ||
className: 'k-list-container k-reset', | ||
close: function () { | ||
vs.hidden = true; | ||
_this.onPopupClosed(); | ||
} | ||
open: _this.onPopupOpened, | ||
close: _this.onPopupClosed | ||
} | ||
@@ -229,4 +227,4 @@ }; | ||
var filterable = _this.props.filterable; | ||
var _a = _this.state, opened = _a.opened, filterText = _a.filterText; | ||
return filterable && (React.createElement(ListFilter_1.default, { value: filterText, focused: opened, willFocus: _this.filteringInputWillFocus, didFocus: _this.filteringInputDidFocus, onChange: _this.handleListFilterChange, onKeyDown: _this.handleKeyDown })); | ||
var _a = _this.state, opened = _a.opened, filterText = _a.filterText, filterInputFocused = _a.filterInputFocused; | ||
return filterable && (React.createElement(ListFilter_1.default, { value: filterText, focused: opened && filterInputFocused, willFocus: _this.filteringInputWillFocus, didFocus: _this.filteringInputDidFocus, onChange: _this.handleListFilterChange, onKeyDown: _this.handleKeyDown })); | ||
}; | ||
@@ -288,6 +286,23 @@ _this.renderDefaultItem = function () { | ||
}; | ||
_this.onPopupOpened = function () { | ||
_this.base.vs.hidden = false; | ||
if (_this.props.filterable) { | ||
_this.setState({ | ||
filterInputFocused: true | ||
}); | ||
} | ||
else { | ||
var wrapper = ReactDOM.findDOMNode(_this.base.wrapper); | ||
if (_this.state.isFocused && document.activeElement !== wrapper) { | ||
wrapper.focus(); | ||
} | ||
} | ||
}; | ||
_this.onPopupClosed = function () { | ||
_this.base.vs.hidden = true; | ||
if (_this.state.isFocused) { | ||
var wrapper_1 = ReactDOM.findDOMNode(_this.base.wrapper); | ||
setTimeout(function () { wrapper_1.focus(); }, 0); | ||
setTimeout(function () { if (_this.state.isFocused) { | ||
wrapper_1.focus(); | ||
} }, 0); | ||
} | ||
@@ -310,2 +325,3 @@ }; | ||
isFocused: false, | ||
filterInputFocused: false, | ||
opened: _this.props.opened, | ||
@@ -312,0 +328,0 @@ }; |
@@ -1,1 +0,1 @@ | ||
System.register("@progress/kendo-react-dropdowns",["react","prop-types","react-dom","@progress/kendo-react-common","@progress/kendo-react-popup"],function(e){var t,n,o,i,a;function s(e){return e.__useDefault?e.default:e}return{setters:[function(e){t=s(e)},function(e){n=s(e)},function(e){o=s(e)},function(e){i=s(e)},function(e){a=s(e)}],execute:function(){!function(e){var t={};function n(o){if(t[o])return t[o].exports;var i=t[o]={exports:{},id:o,loaded:!1};return e[o].call(i.exports,i,i.exports,n),i.loaded=!0,i.exports}n.m=e,n.c=t,n.p="",n(0)}([function(t,n,o){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var i=o(1);n.DropDownList=i.DropDownList;var a=o(18);n.ComboBox=a.ComboBox,function(t){for(var n in t)e(n,t[n])}(n)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(2);t.DropDownList=o.default},function(e,t,n){"use strict";var o,i=this&&this.__extends||(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}o(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),a=this&&this.__assign||Object.assign||function(e){for(var t,n=1,o=arguments.length;n<o;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e};Object.defineProperty(t,"__esModule",{value:!0});var s=n(3),r=n(4),l=n(5),p=n(6),c=n(7),u=n(8),d=n(10),h=n(11),f=n(13),v=n(15),m=n(16),g=n(12),y=0,b=1,x=2,I=function(e){"INPUT"!==e.target.nodeName&&e.preventDefault()},C=function(e){function t(t){var n=e.call(this,t)||this;n.vs=new m.default,n._lastMousedown=0,n.handleFocus=function(e){n.base.handleFocus(e)},n.handleBlur=function(e){if(n.state.isFocused&&!n._filteringWillFocus){if((new Date).getTime()-n._lastMousedown<500)return n._lastMousedown=0,e.target.focus();var t=n.base.initState();t.data.isFocused=!1,t.data.opened=!1,t.events.push({type:"onBlur"}),t.syntheticEvent=e,n.state.opened&&t.events.push({type:"onClose"}),n.base.applyState(t)}},n.handleWrapperClick=function(e){n.base.handleWrapperClick(e)},n.handleItemClick=function(e,t){n.base.handleItemClick(e,t)},n.handleDefaultItemClick=function(e,t){var o=n.base.initState(),i=n.props,a=i.defaultItem,s=i.valueField,r=i.textField;n.togglePopup(o);var l=g.getItemValue(a,s),p=g.getItemText(a,r);n.setValueSelection(l,p,e,o),o.events.push({type:"onChange"}),o.syntheticEvent=t,n.base.applyState(o)},n.handleKeyDown=function(e){n.base.handleKeyDown(e)},n.handleKeyPress=function(e){if(!n.props.filterable&&0!==e.which&&13!==e.keyCode){var t=String.fromCharCode(e.charCode||e.keyCode);n.props.ignoreCase&&(t=t.toLowerCase())," "===t&&e.preventDefault(),n.setState({word:n.state.word+t,last:n.state.last+t},n.search)}},n.handleItemSelect=function(e,t){n.base.handleItemSelect(e,t)},n.handleListFilterChange=function(e){var t=n.base.initState();n.base.filterChanged(e.target.value,t),t.syntheticEvent=e,n.base.applyState(t)},n.setValueSelection=function(e,t,o,i){void 0===e&&(e=void 0),void 0===t&&(t=void 0),void 0===o&&(o=void 0),n.state.selectedIndex!==o&&(i.data.selectedIndex=o),n.base.value=e,n.base.text=t,n.base.index=o},n.togglePopup=function(e){n.base.togglePopup(e),n.state.opened||n.base.calculatePopupWidth()},n.renderDropDownWrapper=function(){var e=n.props,t=e.defaultItem,o=e.valueField,i=e.disabled,a=e.tabIndex,r=e.loading,l=e.iconClassName,u=n.state,d=u.opened,h=u.isFocused,f=g.getItemIndex(n.props,n.value),v=g.getText(n.props,f);return!v&&g.isPresent(n.value)&&-1===f&&g.getItemValue(t,o)!==n.value&&(v=n.base.text),s.createElement(c.default,{disabled:i,focused:h,tabIndex:a,ariaExpanded:d||!1,ariaOwns:n.base.listBoxId,ariaActiveDescendant:n.base.optionPrefix+"-"+(n.value||""),onFocus:n.handleFocus,onBlur:n.handleBlur,onClick:n.handleWrapperClick,onKeyDown:n.handleKeyDown,onKeyPress:n.handleKeyPress,ref:function(e){n.base.wrapper=e}},s.createElement("span",{className:"k-input"},v),s.createElement("span",{className:"k-select"},s.createElement("span",{className:p.classNames("k-icon",l,{"k-i-arrow-s":!r&&!l,"k-i-loading":r&&!l})})))},n.renderListContainer=function(){var e=n.props.popupSettings,t=n.state.opened,o=void 0!==n.props.virtual,i=n.base.vs,r={onMouseDown:function(e){n._lastMousedown=(new Date).getTime(),I(e)},dir:void 0!==n.props.dir?n.props.dir:n.base.dirCalculated,onBlur:n.handleBlur,width:n.base.popupWidth,popupSettings:{animate:(e||{}).animate,anchor:n.element,appendTo:document.body,show:t,open:function(){i.hidden=!1},className:"k-list-container k-reset",close:function(){i.hidden=!0,n.onPopupClosed()}}};return s.createElement(u.default,a({},r),n.renderListFilter(),o?n.renderDefaultItem():void 0,n.renderScrollWrapper(o?[n.renderList(),n.renderScrollElement()]:[n.renderDefaultItem(),n.renderList(),n.renderScrollElement()]))},n.renderScrollWrapper=function(e){var t=n.props.popupSettings,o=n.base.vs;return o.enabled?s.createElement("div",{onScroll:o.scrollHandler,ref:n.scrollerRef,style:{height:(t||{}).height,overflowY:"scroll"}},e):e},n.renderScrollElement=function(){var e=n.base.vs;return e.enabled&&s.createElement("div",{ref:function(t){e.scrollElement=t},key:x})},n.renderList=function(){var e=n.props,t=e.data,o=e.textField,i=e.valueField,a=e.defaultItem,r=e.popupSettings,l=n.base.vs,p=n.state,c=p.opened,u=p.skip,d="translateY("+n.vs.translate+"px)",h=n.value,v=!(g.getItemIndex(n.props,h)<0&&!a);return s.createElement(f.default,{id:n.base.listBoxId,show:c,data:(t||[]).slice(),focusedIndex:v||0!==u?void 0:0,value:h,textField:o,valueField:i,optionPrefix:n.base.optionPrefix,listRef:function(e){l.enabled&&(l.list=e),n.base.list=e},wrapperStyle:l.enabled?{float:"left",width:"100%"}:{maxHeight:(r||{}).height},wrapperCssClass:l.enabled?void 0:"k-list-scroller",listStyle:l.enabled?{transform:d}:void 0,key:b,skip:u,onClick:n.handleItemClick})},n.renderListFilter=function(){var e=n.props.filterable,t=n.state,o=t.opened,i=t.filterText;return e&&s.createElement(d.default,{value:i,focused:o,willFocus:n.filteringInputWillFocus,didFocus:n.filteringInputDidFocus,onChange:n.handleListFilterChange,onKeyDown:n.handleKeyDown})},n.renderDefaultItem=function(){var e=n.props,t=e.textField,o=e.defaultItem;return o&&s.createElement(h.default,{defaultItem:o,textField:t,selected:-1===n.index,key:y,onClick:n.handleDefaultItemClick})},n.scrollerRef=function(e){if(e){var t=n.base.vs;t.container=e,setTimeout(t.calculateScrollSizes.bind(t),0)}},n.search=function(){clearTimeout(n._typingTimeout),n.props.filterable||(n._typingTimeout=setTimeout(function(){n.setState({word:""})},n.props.delay),n.selectNext())},n.selectNext=function(){var e,t,o,i=(n.props.data||[]).map(function(e,t){return{item:e,itemIndex:t}}),a=g.sameCharsOnly(n.state.word,n.state.last),s=i.length,r=n.state.selectedIndex||0;for(n.props.defaultItem&&(o={item:n.props.defaultItem,itemIndex:-1},s+=1,r+=1),r+=a?1:0,i=g.shuffleData(i,r,o),t=0;t<s;t++){e=g.getter(i[t].item,n.props.textField);var l=Boolean(a&&g.matchText(e,n.state.last,n.props.ignoreCase)),p=Boolean(g.matchText(e,n.state.word,n.props.ignoreCase));if(l||p){t=i[t].itemIndex;break}}if(t!==s){var c=n.base.initState();n.handleItemSelect(t,c),n.base.applyState(c)}},n.filteringInputWillFocus=function(){n._filteringWillFocus=!0},n.filteringInputDidFocus=function(){n._filteringWillFocus=!1},n.onPopupClosed=function(){if(n.state.isFocused){var e=r.findDOMNode(n.base.wrapper);setTimeout(function(){e.focus()},0)}};var o=void 0!==t.value?t.value:t.defaultValue,i=-1;return!g.isPresent(o)&&g.isPresent(t.defaultItem)?o=g.getItemValue(t.defaultItem,t.valueField):i=g.getItemIndex(t,o),n.state={filterText:"",word:"",last:"",selectedIndex:i,skip:0,isFocused:!1,opened:n.props.opened},n.base=new v.default(n),n.base.index=i,n.base.value=o,n}return i(t,e),Object.defineProperty(t.prototype,"element",{get:function(){return this._element},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"value",{get:function(){return this.base.value},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"index",{get:function(){return this.base.index},enumerable:!0,configurable:!0}),t.prototype.componentWillReceiveProps=function(e){this.base.componentWillReceiveProps(e)},t.prototype.componentWillUpdate=function(e,t){this.base.componentWillUpdate(e,t)},t.prototype.componentDidUpdate=function(e,t){this.base.componentDidUpdate(t)},t.prototype.componentDidMount=function(){this.base.componentDidMount()},t.prototype.componentWillUnmount=function(){this.base.componentWillUnmount()},t.prototype.onNavigate=function(e){var t=this.props,n=t.data,o=t.filterable,i=t.defaultItem,a=this.base.initState();a.syntheticEvent=e;var s=this.base.vs,r=g.getItemIndex(this.props,this.value);this.base.navigation.navigate({opened:this.state.opened,event:e,state:a,currentIndex:s.skip+r,max:(s.enabled?s.total:(n||[]).length)-1,min:i?-1:0,leftRightKeysNavigation:o,togglePopup:this.togglePopup,handleItemSelect:this.handleItemSelect}),this.base.applyState(a)},t.prototype.render=function(){var e=this,t=this.props,n=t.style,o=t.className,i=t.label,a=t.dir,r=this.state.opened,l=g.getText(this.props,g.getItemIndex(this.props,this.value)),c=s.createElement("span",{ref:function(t){e._element=t},className:p.classNames("k-widget k-dropdown k-header",o),style:n,dir:a,onMouseDown:r?I:void 0},this.renderDropDownWrapper(),this.renderListContainer());return i?s.createElement(p.FloatingLabel,{label:i,value:l,children:c}):c},t}(s.Component);C.propTypes=a({delay:l.number,ignoreCase:l.bool,loading:l.bool,value:l.oneOfType([l.string,l.number,l.object]),defaultValue:l.oneOfType([l.string,l.number,l.object]),iconClassName:l.string},v.default.propTypes),C.defaultProps=a({delay:500,ignoreCase:!0},v.default.defaultProps),t.default=C},function(e,n){e.exports=t},function(e,t){e.exports=o},function(e,t){e.exports=n},function(e,t){e.exports=i},function(e,t,n){"use strict";var o,i=this&&this.__extends||(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}o(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var a=n(3),s=n(6),r=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return i(t,e),t.prototype.render=function(){var e=this.props,t=e.disabled,n=e.focused,o=e.style,i=e.ariaExpanded,r=e.ariaOwns,l=e.ariaActiveDescendant,p=e.tabIndex;return a.createElement("span",{role:"listbox",tabIndex:t?void 0:p,className:s.classNames("k-dropdown-wrap",this.props.className,{"k-state-default":!t,"k-state-focused":n,"k-state-disabled":t}),style:o,onFocus:this.props.onFocus,onBlur:this.props.onBlur,onKeyDown:this.props.onKeyDown,onKeyPress:this.props.onKeyPress,onClick:this.props.onClick,"aria-disabled":t||void 0,"aria-haspopup":!0,"aria-expanded":i,"aria-owns":r,"aria-activedescendant":l},this.props.children)},t}(a.Component);t.default=r},function(e,t,n){"use strict";var o,i=this&&this.__extends||(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}o(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),a=this&&this.__assign||Object.assign||function(e){for(var t,n=1,o=arguments.length;n<o;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e};Object.defineProperty(t,"__esModule",{value:!0});var s=n(3),r=n(9),l=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return i(t,e),t.prototype.render=function(){var e=this.props,t=e.children,n=e.onMouseDown,o=e.onBlur,i=e.width,l=e.dir,p=e.popupSettings;return s.createElement(r.Popup,a({style:{width:i,direction:l}},p),s.createElement("div",{onMouseDown:n,onBlur:o},t))},t}(s.Component);t.default=l},function(e,t){e.exports=a},function(e,t,n){"use strict";var o,i=this&&this.__extends||(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}o(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var a=n(3),s=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return i(t,e),t.prototype.componentDidUpdate=function(){this._input&&this.props.focused&&(this.props.willFocus&&this.props.willFocus(),this._input.focus(),this.props.didFocus&&setTimeout(this.props.didFocus,0))},t.prototype.render=function(){var e=this;return a.createElement("span",{className:"k-list-filter"},a.createElement("input",{ref:function(t){e._input=t},value:this.props.value,className:"k-textbox",onChange:this.props.onChange,onKeyDown:this.props.onKeyDown}),a.createElement("span",{className:"k-icon k-i-search"}))},t}(a.Component);t.default=s},function(e,t,n){"use strict";var o,i=this&&this.__extends||(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}o(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var a=n(3),s=n(6),r=n(12),l=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.onMouseDown=function(e){e.preventDefault()},t.onClick=function(e){e.preventDefault(),t.props.onClick&&t.props.onClick(-1,e)},t}return i(t,e),t.prototype.render=function(){var e=this.props,t=e.selected,n=e.defaultItem,o=e.textField;return a.createElement("div",{onClick:this.onClick,onMouseDown:this.onMouseDown,className:s.classNames("k-list-optionlabel",{"k-state-selected":t})},r.getter(n,o)||"")},t}(a.Component);t.default=l},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(e){return null!=e};t.isPresent=n;var o=function(e,t,o){if(void 0===o&&(o=!1),n(e))return o?t&&n(e[t])?e[t]:e:t?e[t]:e};t.getter=o;t.sameCharsOnly=function(e,t){for(var n=0;n<e.length;n++)if(e.charAt(n)!==t)return!1;return!0};t.shuffleData=function(e,t,n){var o=e;return n&&(o=[n].concat(o)),o.slice(t).concat(o.slice(0,t))};t.matchText=function(e,t,o){if(!n(e))return!1;var i=String(e);return o&&(i=i.toLowerCase()),0===i.indexOf(t)};var i=["string","number","undefined"],a=function(e){var t=typeof e;return-1!==i.indexOf(t)};t.isPrimitive=a;t.scrollToItem=function(e,t,n,o,i){var a=e.offsetHeight,s=t*n-(i?e.scrollTop-o:0);if(i){var r=0;s+t>a?r=s+t-a:s<0&&(r=s),0!==r?e.scrollTop+=r:0===e.scrollTop&&0!==o&&(e.scrollTop=o)}else s+t>a+e.scrollTop?e.scrollTop=s+t-a:s<e.scrollTop&&(e.scrollTop-=e.scrollTop-s)};t.itemIndexStartsWith=function(e,t,n){var i=-1;if(e){e=e.toLowerCase();for(var s=0;s<t.length;s++){var r=(o(t[s],n,a(t[s]))||"")+"";if(r&&r.toLowerCase().startsWith(e)){i=s;break}}}return i};t.getItemIndex=function(e,t){var n=e.valueField;return(e.data||[]).findIndex(function(e){return e===t||o(e,n)===t})};t.getItemIndexByText=function(e,t,n){return e.findIndex(function(e){return a(e)?t.toLowerCase()===e.toString().toLowerCase():s(e,n).toLowerCase()===t.toLowerCase()})};var s=function(e,t){return a(e)?e:o(e,t)};t.getItemText=s;var r=function(e,t){return t?o(e,t):e};t.getItemValue=r;t.getText=function(e,t){if(!e.data)return null;if(-1===t)return s(e.defaultItem,e.textField);var n=e.data[t];return s(n,e.textField)};t.getValue=function(e,t){if(-1===t)return r(e.defaultItem,e.valueField);if(e.data){var n=e.data[t];return r(n,e.valueField)}}},function(e,t,n){"use strict";var o,i=this&&this.__extends||(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}o(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var a=n(3),s=n(14),r=n(12),l=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return i(t,e),t.prototype.renderItems=function(){var e=this,t=this.props,n=t.textField,o=t.valueField,i=t.value,l=t.optionPrefix,p=t.skip,c=t.focusedIndex;return this.props.data.map(function(t,u){var d=r.getter(t,o),h=(p||0)+u;return a.createElement(s.default,{id:l+"-"+(d||h.toString()),dataItem:t,selected:d===i,focused:c===u,index:h,key:h,onClick:e.props.onClick,textField:n})})},t.prototype.render=function(){var e=this.props,t=e.id,n=e.show,o=e.wrapperCssClass,i=e.wrapperStyle,s=e.listStyle,r=e.listRef,l=this.renderItems();return l.length?a.createElement("div",{className:o,style:i},a.createElement("ul",{id:t,role:"listbox","aria-hidden":!n||void 0,className:"k-list k-reset",ref:r,style:s},l)):a.createElement("div",{className:"k-nodata"},a.createElement("div",null,"NO DATA FOUND."))},t}(a.Component);t.default=l},function(e,t,n){"use strict";var o,i=this&&this.__extends||(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}o(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var a=n(3),s=n(6),r=n(12),l=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.handleClick=function(e){e.preventDefault(),t.props.onClick&&t.props.onClick(t.props.index||0,e)},t}return i(t,e),t.prototype.render=function(){var e=this.props,t=e.id,n=e.selected,o=e.focused,i=e.dataItem,l=e.textField;return a.createElement("li",{id:t,role:"option","aria-selected":n||!1,className:s.classNames("k-item",{"k-state-selected":n,"k-state-focused":o}),onClick:this.handleClick},r.getter(i,l))},t}(a.Component);t.default=l},function(e,t,n){"use strict";var o=this&&this.__assign||Object.assign||function(e){for(var t,n=1,o=arguments.length;n<o;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e};Object.defineProperty(t,"__esModule",{value:!0});var i=n(4),a=n(5),s=n(16),r=n(17),l=n(12),p=n(6),c=function(){function e(e){var t=this;this.valueDuringOnChange=void 0,this.indexDuringOnChange=void 0,this.valueNotInData=!1,this.text="",this.lastTextSelected="",this.selectedItemChanged=!1,this.vs=new s.default,this.navigation=new r.Navigation,this.handleKeyDown=function(e){var n=t.component.props,o=n.filterable,i=n.disabled,a=e.keyCode;i||!(o&&(37===a||39===a||32===a||16===a||36===a||35===a))&&t.component.onNavigate(e)},this.handleWrapperClick=function(e){var n=t.initState();t.component.togglePopup(n),n.syntheticEvent=e,t.applyState(n)},this.handleItemClick=function(e,n){var o=t.initState();t.component.handleItemSelect(e,o),t.component.togglePopup(o),o.syntheticEvent=n,t.applyState(o)},this.handleFocus=function(e){if(!t.component.state.isFocused){var n=t.initState();n.data.isFocused=!0,n.events.push({type:"onFocus"}),n.syntheticEvent=e,t.applyState(n)}},this.filterChanged=function(e,n){var o=t.component.props.textField;n.data.filterText=e,n.events.push({type:"onFilterChange",filter:{field:o,operator:"contains",ignoreCase:!0,value:e}})},this.togglePopup=function(e){e.data.isFocused=!0,e.data.opened=!t.component.state.opened,t.component.state.opened?e.events.push({type:"onClose"}):e.events.push({type:"onOpen"})},this.pageChange=function(e,n){if(t.component.props.virtual){var o=t.initState();o.events.push({type:"onPageChange",page:{skip:e.skip,take:e.take}}),o.syntheticEvent=n,t.applyState(o)}},this.handleItemSelect=function(e,n){var o=e-(t.component.state.skip||0),i=t.component.props,a=i.data||[],s=void 0!==i.value;if(l.isPresent(e))if(o>=0&&o<a.length||-1===o&&i.defaultItem){var r=l.getValue(i,o),p=l.getText(i,o),c=t.value;s?(t.valueDuringOnChange=r,t.indexDuringOnChange=e):(t.value=r,t.index=e,t.text=p,n.data.selectedIndex=e),r!==c&&(n.events.push({type:"onChange"}),t.selectedItemChanged=!0)}else void 0!==i.virtual&&(t.vs.handleVirtualItemSelect(n,t.component.state,t.vs.container,e),t.valueNotInData=!0,s?t.indexDuringOnChange=e:(t.index=e,n.data.selectedIndex=e),t.selectedItemChanged=!0)},this.listBoxId=p.guid(),this.optionPrefix=p.guid(),this.component=e,this.vs.initVirtualization(e.props.virtual,void 0),this.vs.PageChange=this.pageChange}return Object.defineProperty(e.prototype,"value",{get:function(){return void 0!==this.valueDuringOnChange?this.valueDuringOnChange:this._value},set:function(e){this._value=e},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"index",{get:function(){return void 0!==this.indexDuringOnChange?this.indexDuringOnChange:this._index},set:function(e){this._index=e},enumerable:!0,configurable:!0}),e.prototype.componentWillReceiveProps=function(e){var t=this.initState(),n=e.filterable&&void 0!==e.filter&&e.filter!==this.component.props.filter;void 0!==e.opened&&(t.data.opened=e.opened),!e.filterable&&this.component.state.filterText?t.data.filterText="":n&&(t.data.filterText=e.filter),this.vs.updateVirtualization(e.virtual,this.component.props.virtual,t);var o=void 0!==e.value,i=o&&e.value!==this.component.props.value;if(this.selectedItemChanged||i){if(this.valueNotInData&&!o){var a=this.index-(t.data.skip||0);this.value=l.getValue(e,a),this.text=l.getText(e,a)}else this.updateSelectedItem(e,t);this.lastValueSelected=this.value,this.lastTextSelected=this.text}this.selectedItemChanged=!1,this.valueNotInData=!1,this.applyState(t)},e.prototype.componentWillUpdate=function(e,t){t.opened&&this.component.state.opened&&-1!==t.selectedIndex&&this.component.state.selectedIndex!==t.selectedIndex&&this.scrollToSelectedItem(t),void 0!==e.value&&void 0===this.value&&(this.value=e.value)},e.prototype.componentDidUpdate=function(e){var t=this;if(this.component.state.opened&&!e.opened){var n=this.vs.container;if(n){this.vs.updateListScroll(this.component.state,n,function(){l.getItemIndex(t.component.props,t.value)>=0&&t.scrollToSelectedItem(t.component.state)})}else this.scrollToSelectedItem(this.component.state)}},e.prototype.componentDidMount=function(){this.component.element&&(this.dirCalculated=window.getComputedStyle(this.component.element).direction||void 0)},e.prototype.componentWillUnmount=function(){var e=this.vs;delete e.container,delete e.list},e.prototype.scrollToSelectedItem=function(e){var t=this.list||this.vs.list,n=(e.selectedIndex||0)-(e.skip||0),o=t?t.children[0]:void 0;if(o){var i=this.vs,a=i.container||t.parentNode;l.scrollToItem(a,o.offsetHeight,n,i.translate,i.enabled)}},e.prototype.initState=function(){return{data:{},events:[],syntheticEvent:void 0}},e.prototype.applyState=function(e){var t=this,n={syntheticEvent:e.syntheticEvent,nativeEvent:e.syntheticEvent?e.syntheticEvent.nativeEvent:void 0,target:this.component};Object.keys(e.data).length>0&&this.component.setState(e.data),e.events.forEach(function(e){var i=e.type;delete e.type;var a=t.component.props[i];a&&a.call(void 0,o({},n,e))}),this.indexDuringOnChange=void 0,this.valueDuringOnChange=void 0},e.prototype.calculatePopupWidth=function(){var e=(this.component.props.popupSettings||{}).width;this.popupWidth=void 0!==e?e:i.findDOMNode(this.wrapper).offsetWidth+"px"},e.prototype.updateSelectedItem=function(e,t){var n=void 0!==e.value?e.value:this.value,o=l.getItemIndex(e,n),i=l.getText(e,o),a=e.defaultItem?l.getItemValue(e.defaultItem,e.valueField):void 0;l.isPresent(n)&&-1===o&&void 0===a||(-1===o&&void 0!==a&&(n=a,i=l.getItemText(e.defaultItem,this.component.props.textField)),o=-1!==o?o+(t.data.skip||0):o,this.text=i,this.component.setValueSelection(n,i,o,t))},e}();c.propTypes={opened:a.bool,disabled:a.bool,dir:a.string,filterable:a.bool,tabIndex:a.number,data:a.array,textField:a.string,valueField:a.string,className:a.string,label:a.string,popupSettings:a.shape({animate:a.bool,width:a.string,height:a.string}),virtual:a.shape({pageSize:a.number.isRequired,skip:a.number.isRequired,total:a.number.isRequired}),onOpen:a.func,onClose:a.func,onFocus:a.func,onBlur:a.func,onChange:a.func,onFilterChange:a.func,onPageChange:a.func},c.defaultProps={tabIndex:0,popupSettings:{animate:!0,height:"200px"}},t.default=c},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(12),i=1533915,a=function(e,t,n){e.events.push({type:"onPageChange",page:{skip:t,take:n}})},s=function(){function e(){var e=this;this.containerHeight=0,this.skip=0,this.total=0,this.enabled=!1,this.pageSize=0,this.itemHeight=0,this.hidden=!1,this.prevScrollPos=0,this.listTranslate=0,this.scrollSyncing=!1,this.calculateScrollSizes=function(){e.scrollSyncing=!0;var t=!1;if(o.isPresent(e.list)){e.itemHeight=e.list?e.list.children[0].offsetHeight:e.itemHeight,e.containerHeight=Math.min(i,e.itemHeight*e.total);var n=e.containerHeight;(t=e.scrollElement.style.height!==n+"px")&&(e.scrollElement.style.height=n+"px")}return e.scrollSyncing=!1,t},this.scrollHandler=this.scrollHandler.bind(this)}return e.prototype.initVirtualization=function(e,t){this.enabled=void 0!==e,void 0!==e&&(this.skip=e.skip,this.pageSize=e.pageSize,this.total=e.total,void 0!==t&&(t.data.skip=e.skip))},e.prototype.updateVirtualization=function(e,t,n){if(void 0===e||void 0===t||t.total===e.total&&0!==e.skip)this.initVirtualization(e,n);else{var o=Object.assign({},e,{skip:0});this.initVirtualization(o,n),this.calculateScrollSizes()&&this.reset()}},e.prototype.handleVirtualItemSelect=function(e,t,n,o){var i=t.skip||0,s=t.selectedIndex||0,r=t.opened&&n,l=this,p=l.pageSize,c=o-i;if(r&&0===o)a(e,0,p),l.reset();else if(r&&o===l.total-1)a(e,l.total-l.pageSize,p),l.scrollToEnd();else if(r){var u=l.PageChange;l.PageChange=function(t){a(e,t.skip,t.take)},(o>s?l.localScrollDown:l.localScrollUp).call(l,t.syntheticEvent),l.PageChange=u}else if(r||0!==o)if(r||o!==l.total-1){if(!r){var d=Math.max(0,i+(c<0?-1:1));a(e,d,p)}}else a(e,l.total-l.pageSize,p);else a(e,0,p);t.opened||l.reset()},e.prototype.updateListScroll=function(e,t,n){var o=t.scrollTop,i=this,a=i.translate,s=i.hidden,r=e.skip||0;if(o!==a||0===a&&0===o&&r>0){var l=function(){i.enabled=!1;var e=a>0?a:i.itemHeight*r;t.scrollTop=e,i.translateTo(a||e),i.enabled=!0,n()};0===i.itemHeight||s?setTimeout(l,0):l()}},Object.defineProperty(e.prototype,"translate",{get:function(){return this.listTranslate},enumerable:!0,configurable:!0}),e.prototype.changePage=function(e,t){var n=Math.min(Math.max(0,e),this.total-this.pageSize);n!==this.skip&&this.PageChange({skip:n,take:this.pageSize},t)},e.prototype.translateTo=function(e){this.listTranslate=e,this.list&&(this.list.style.transform="translateY("+e+"px)")},e.prototype.reset=function(){this.scrollSyncing=!0,this.container&&(this.container.scrollTop=0),this.translateTo(0),this.scrollSyncing=!1},e.prototype.maxScroll=function(){return this.container.scrollHeight-this.container.offsetHeight},e.prototype.scrollToEnd=function(){if(this.container){var e=this.maxScroll();this.translateTo(e),this.container.scrollTop=e}},e.prototype.localScrollUp=function(e){var t,n=this.itemHeight,o=this.container.scrollTop,i=this.listTranslate,a=o-i;if(!(a>0)){for(t=0;t<this.skip&&!(i+n+a<=o);t++)i-=n;if(i=this.validateTranslate(i),this.skip-t<=0&&i>o)return this.translateTo(0),this.changePage(0,e),void(this.container.scrollTop=0);i!==this.listTranslate&&(this.translateTo(i),this.changePage(this.skip-t,e))}},e.prototype.localScrollDown=function(e){var t,n=this.itemHeight,o=this.container.scrollTop,i=this.listTranslate,a=this.list.children.length;for(t=0;t<a&&!(i+n>o);t++)i+=n;i=this.validateTranslate(i),t>=a&&this.skip+t>=this.total?(this.translateTo(i),this.changePage(this.total-1,e)):i!==this.listTranslate&&(this.translateTo(i),this.changePage(this.skip+t,e))},e.prototype.scrollNonStrict=function(e){var t=this.total*this.prevScrollPos/this.containerHeight,n=Math.min(Math.floor(t),this.total-1),o=this.containerHeight*t/this.total;o=this.validateTranslate(o),this.translateTo(o),this.changePage(n,e)},e.prototype.scrollHandler=function(e){if(this.enabled&&this.list&&!this.hidden&&!this.scrollSyncing){var t=this.container.scrollTop,n=this.prevScrollPos;this.prevScrollPos=t,t-n<0&&t>this.listTranslate-this.list.scrollHeight/10?this.localScrollUp(e):t-n>0&&t<this.listTranslate+2*this.list.scrollHeight/3?this.localScrollDown(e):this.scrollNonStrict(e)}},e.prototype.validateTranslate=function(e){return e=Math.max(0,e),e=Math.min(this.containerHeight-this.list.offsetHeight,e)},e}();t.default=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o,i,a=n(12),s=function(){return function(e,t,n){this.index=e,this.event=t,this.action=n}}();t.NavigationData=s,(i=o=t.NavigationAction||(t.NavigationAction={}))[i.Undefined=0]="Undefined",i[i.Open=1]="Open",i[i.Close=2]="Close",i[i.Enter=3]="Enter",i[i.Space=4]="Space",i[i.Tab=5]="Tab",i[i.Esc=6]="Esc",i[i.Delete=7]="Delete",i[i.Backspace=8]="Backspace",i[i.Home=9]="Home",i[i.End=10]="End",i[i.Up=11]="Up",i[i.Down=12]="Down",i[i.Left=13]="Left",i[i.Right=14]="Right";var r=function(){function e(){}return e.prototype.navigate=function(e){var t=this.process({current:e.currentIndex,max:e.max,min:e.min,event:e.event}),n=t.action;n!==o.Undefined&&(n===o.Open&&!e.opened||n===o.Close&&e.opened||13===e.event.keyCode||32===e.event.keyCode?e.togglePopup(e.state):void 0!==t.index&&e.handleItemSelect(t.index,e.state));var i=n===o.Left||n===o.Right;n===o.Undefined||n===o.Tab||n===o.Backspace||n===o.Delete||i&&e.leftRightKeysNavigation||!(n!==o.Enter||n===o.Enter&&e.opened)||e.event.preventDefault()},e.prototype.process=function(e){var t=e.event,n=t.keyCode,i=t.altKey,a=void 0,r=o.Undefined;return i&&40===n?r=o.Open:i&&38===n?r=o.Close:13===n?r=o.Enter:32===n?r=o.Space:27===n?r=o.Close:9===n?r=o.Tab:38===n?(a=this.next({current:e.current,min:e.min,max:e.max,step:-1}),r=o.Up):37===n?(a=this.next({current:e.current,min:e.min,max:e.max,step:-1}),r=o.Left):40===n?(a=this.next({current:e.current,min:e.min,max:e.max,step:1}),r=o.Down):39===n?(a=this.next({current:e.current,min:e.min,max:e.max,step:1}),r=o.Right):36===n?(a=0,r=o.Home):35===n?(a=e.max,r=o.End):46===n?r=o.Delete:8===n&&(r=o.Backspace),new s(a,t,r)},e.prototype.next=function(e){return a.isPresent(e.current)?Math.min(e.max,Math.max(e.current+e.step,e.min)):e.min},e}();t.Navigation=r},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(19);t.ComboBox=o.default},function(e,t,n){"use strict";var o,i=this&&this.__extends||(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}o(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),a=this&&this.__assign||Object.assign||function(e){for(var t,n=1,o=arguments.length;n<o;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e};Object.defineProperty(t,"__esModule",{value:!0});var s=n(3),r=n(5),l=n(15),p=n(8),c=n(13),u=n(20),d=n(12),h=n(6),f=1,v=2,m=function(e){function t(t){var n=e.call(this,t)||this;n._lastMousedown=0,n.handleItemSelect=function(e,t){n.base.handleItemSelect(e,t),n.base.selectedItemChanged&&(n.state.typedText&&(t.data.typedText=""),n.state.filterText&&(t.data.filterText=""))},n.togglePopup=function(e){n.base.togglePopup(e)},n.renderScrollWrapper=function(e){var t=n.props.popupSettings,o=n.base.vs;return o.enabled?s.createElement("div",{onScroll:o.scrollHandler,ref:n.scrollerRef,style:{height:(t||{}).height,overflowY:"scroll"}},e):e},n.renderScrollElement=function(){var e=n.base.vs;return e.enabled&&s.createElement("div",{ref:function(t){e.scrollElement=t},key:v})},n.renderList=function(){var e,t=n.props,o=t.textField,i=t.valueField,a=t.popupSettings,r=n.base,l=r.vs,p=n.state,u=p.opened,h=p.skip,v="translateY("+l.translate+"px)",m=n.valueToRender(),g=m.value,y=m.text,b=(n.props.data||[]).slice();return u&&(e=y?d.itemIndexStartsWith(y,b,o):0===h?0:void 0),s.createElement(c.default,{id:r.listBoxId,show:u,data:b,focusedIndex:e,value:g,textField:o,valueField:i,optionPrefix:r.optionPrefix,listRef:function(e){l.enabled&&(l.list=e),n.base.list=e},wrapperStyle:l.enabled?{float:"left",width:"100%"}:{maxHeight:(a||{}).height},wrapperCssClass:l.enabled?void 0:"k-list-scroller",listStyle:l.enabled?{transform:v}:void 0,key:f,skip:h,onClick:n.handleItemClick})},n.onInputKeyDown=function(e){var t=e.keyCode;if(13===t||27===t){e.preventDefault();var o=e.currentTarget.value,i=n.base.initState();i.syntheticEvent=e,n.applyInputValue(o,i,e.keyCode)}else 38!==t&&40!==t||(e.preventDefault(),n.handleKeyDown(e))},n.applyInputValue=function(e,t,o){void 0===o&&(o=void 0);var i=n.state.suggestedText||"",a=n.props,s=a.data,r=void 0===s?[]:s,l=a.textField,p=a.valueField,c=a.suggest,u=a.allowCustom,h=a.filterable,f=void 0===o||27===o,v=n.state.opened,m=d.getItemIndexByText(r,e,l);if(v&&(t.data.opened=!1),u&&-1===m&&n.value===e)return v&&t.events.push({type:"onClose"}),n.base.applyState(t);var g=void 0,y="";if(-1!==m?(g=d.getItemValue(r[m],p),y=d.getItemText(r[m],l)):u&&(g=e,y=e),c&&!f&&i.toLowerCase()===e.toLowerCase())y=g=i,t.data.typedText=i;else if(f)if(t.data.suggestedText=void 0,u||-1!==m||e!==n.base.lastTextSelected){if(!u&&-1===m&&e===n.state.typedText)return n.clearValue(t),n.base.applyState(t)}else g=n.base.lastValueSelected,y=n.base.lastTextSelected;else if(13===o&&!u){var b=d.itemIndexStartsWith(e,r,l);return n.handleItemSelect(b,t),v&&t.events.push({type:"onClose"}),n.state.typedText&&(t.data.typedText=""),h&&(t.data.filterText=n.base.text),n.base.applyState(t)}(n.value||"")!==g&&t.events.push({type:"onChange"}),v&&t.events.push({type:"onClose"}),n.base.value=g,n.base.text=y,n.base.applyState(t)},n.onInput=function(e){var t=n.base.initState(),o=e.currentTarget.value,i=void 0!==n.props.value;if(t.syntheticEvent=e,!o)return n.clearValue(t),delete t.data.opened,n.base.applyState(t);n.state.opened||(t.data.opened=!0),t.data.typedText=o,i||(t.data.selectedIndex=-1,n.base.index=-1),n.props.filterable&&n.filterChanged(o,t),n.state.opened===t.data.opened&&t.events.push({type:t.data.opened?"onOpen":"onClose"}),n.suggestValue(o,t),n.base.applyState(t)},n.clearButtonClick=function(e){var t=n.base.initState();t.syntheticEvent=e,n.clearValue(t),n.base.applyState(t)},n.handleFocus=function(e){n.base.handleFocus(e)},n.handleBlur=function(e){if(n.state.isFocused){if((new Date).getTime()-n._lastMousedown<500)return n._lastMousedown=0,e.currentTarget.focus();var t=n.base.initState();t.data.isFocused=!1,t.events.push({type:"onBlur"}),t.syntheticEvent=e,n.applyInputValue(e.currentTarget.value,t)}},n.handleWrapperClick=function(e){n.base.handleWrapperClick(e)},n.handleItemClick=function(e,t){n.base.handleItemClick(e,t)},n.handleKeyDown=function(e){n.base.handleKeyDown(e)},n.filterChanged=function(e,t){n.base.filterChanged(e,t)},n.setValueSelection=function(e,t,o,i){void 0===e&&(e=void 0),void 0===t&&(t=void 0),void 0===o&&(o=void 0),n.props.filterable||t===n.state.text||(i.data.text=t),i.data.selectedIndex!==n.state.selectedIndex&&(i.data.selectedIndex=o),n.base.value=e},n.scrollerRef=function(e){if(e){var t=n.base.vs;t.container=e,setTimeout(t.calculateScrollSizes.bind(t),0)}};var o=t.allowCustom,i=t.opened,a=t.textField,r=t.valueField,p=void 0!==t.value?t.value:t.defaultValue,u=-1,m="";o&&void 0!==p?(m=d.getItemText(p,a),u=d.getItemIndex(t,p)):o||(u=d.getItemIndex(t,p),m=d.getText(t,u)),n.state={filterText:"",typedText:"",text:m,selectedIndex:u,skip:0,isFocused:!1,opened:i};var g=n.base=new l.default(n);return g.value=d.getItemValue(p,r),g.index=u,g.text=m,n._inputId=h.guid(),n}return i(t,e),Object.defineProperty(t.prototype,"element",{get:function(){return this._element},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"value",{get:function(){return this.base.value},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"index",{get:function(){return this.base.index},enumerable:!0,configurable:!0}),t.prototype.componentWillReceiveProps=function(e){this.base.componentWillReceiveProps(e)},t.prototype.componentWillUpdate=function(e,t){this.base.componentWillUpdate(e,t),!this.state.opened&&t.opened&&this.base.calculatePopupWidth();var n=void 0!==t.selectedIndex&&this.state.selectedIndex!==t.selectedIndex,o=t.typedText||!t.typedText&&this.state.typedText&&void 0===this.base.lastValueSelected;if(n){var i=(e.data||[])[(t.selectedIndex||0)-(t.skip||0)];this.base.value=d.getItemValue(i,e.valueField),this.base.text=d.getItemText(i,e.textField),this.base.index=t.selectedIndex||0}else o&&(this.base.lastTextSelected="",this.base.lastValueSelected=void 0,this.base.value=void 0,this.base.index=-1,this.base.text="")},t.prototype.componentDidUpdate=function(e,t){this.base.componentDidUpdate(t)},t.prototype.componentDidMount=function(){this.base.componentDidMount()},t.prototype.componentWillUnmount=function(){this.base.componentWillUnmount()},t.prototype.onNavigate=function(e){var t=this.props,n=t.data,o=void 0===n?[]:n,i=t.filterable,a=t.textField,s=this.base.initState(),r=this.base.vs,l=d.getItemIndex(this.props,this.value),p=this.state.typedText,c=r.skip+l;if(c<0&&p&&(38===e.keyCode||40===e.keyCode)){var u=d.itemIndexStartsWith(p,o,a);u>=0&&(c=38===e.keyCode?u+1:u-1)}this.base.navigation.navigate({opened:this.state.opened,event:e,state:s,currentIndex:c,max:(r.enabled?r.total:o.length)-1,min:0,leftRightKeysNavigation:i,togglePopup:this.togglePopup,handleItemSelect:this.handleItemSelect}),s.syntheticEvent=e,this.base.applyState(s)},t.prototype.render=function(){var e=this,t=this.props,n=t.placeholder,o=t.tabIndex,i=t.dir,a=t.disabled,r=t.clearButton,l=t.label,c=t.popupSettings,d=t.className,f=t.style,v=t.loading,m=t.iconClassName,g=this.state,y=g.isFocused,b=g.opened,x=g.suggestedText,I=this.valueToRender().text,C=this.base.vs,S=s.createElement("span",{className:h.classNames("k-widget k-combobox k-header",{"k-combobox-clearable":r},d),ref:function(t){e._element=t},style:f,dir:i},s.createElement("span",{ref:function(t){e.base.wrapper=t},className:h.classNames("k-dropdown-wrap",{"k-state-default":!a,"k-state-disabled":a,"k-state-focused":y&&!a})},s.createElement(u.default,{id:this._inputId,placeholder:n,tabIndex:o||void 0,value:I,suggestedText:x,focused:y,onKeyDown:this.onInputKeyDown,onInput:this.onInput,onFocus:this.handleFocus,onBlur:this.handleBlur,disabled:a,expanded:b,owns:this.base.listBoxId,activedescendant:this.base.optionPrefix+"-"+(this.value||""),clearButton:!(!r||!I),clearButtonClick:this.clearButtonClick}),s.createElement("span",{className:"k-select",onClick:this.handleWrapperClick,onMouseDown:function(t){t.preventDefault(),e.setState({isFocused:!0})}},s.createElement("span",{className:h.classNames("k-icon",m,{"k-i-arrow-s":!v&&!m,"k-i-loading":v&&!m})}))),s.createElement(p.default,{onMouseDown:function(){e._lastMousedown=(new Date).getTime()},width:this.base.popupWidth,popupSettings:{animate:(c||{}).animate,anchor:this.element,appendTo:document.body,show:b,open:function(){C.hidden=!1},className:"k-list-container k-reset",close:function(){C.hidden=!0}},dir:void 0!==this.props.dir?this.props.dir:this.base.dirCalculated},this.renderScrollWrapper([this.renderList(),this.renderScrollElement()])));return l?s.createElement(h.FloatingLabel,{label:l,value:I,id:this._inputId,children:S}):S},t.prototype.valueToRender=function(e,t){var n=e||this.state,o=n.typedText,i=n.filterText,a=void 0===i?"":i,s=n.opened,r=t||this.props,l=r.value,p=r.filterable,c=void 0!==l,u=this.base.text||"",d=c?l:this.base.value,h=p&&!!a;return s||!u||this.base.lastTextSelected!==u||h&&!this.base.lastTextSelected.toLowerCase().startsWith(a.toLowerCase())?h?{value:d,text:a}:o?{value:null,text:o}:{value:d,text:u}:{value:d,text:u}},t.prototype.suggestValue=function(e,t){if(void 0!==this.state.suggestedText&&(t.data.suggestedText=void 0),this.props.suggest&&e){var n=this.props.data||[],o=this.props.textField,i=n[d.itemIndexStartsWith(e,n,o)];i&&(t.data.suggestedText=d.getItemText(i,o))}},t.prototype.clearValue=function(e){var t=void 0!==this.props.value,n=this.value;t?(this.base.valueDuringOnChange=null,this.base.indexDuringOnChange=-1):(this.base.value=null,this.base.index=-1,this.base.text="",e.data.selectedIndex=-1),e.data.typedText="",void 0!==this.state.suggestedText&&(e.data.suggestedText=void 0),null!==n&&(e.events.push({type:"onChange"}),this.base.selectedItemChanged=!0,this.props.filterable&&this.filterChanged("",e)),this.state.opened&&(e.data.opened=!1,e.events.push({type:"onClose"}))},t}(s.Component);m.propTypes=a({clearButton:r.bool,allowCustom:r.bool,suggest:r.bool,placeholder:r.string,loading:r.bool,value:r.oneOfType([r.string,r.number,r.object]),defaultValue:r.oneOfType([r.string,r.number,r.object]),iconClassName:r.string},l.default.propTypes),m.defaultProps=a({},l.default.defaultProps,{clearButton:!0}),t.default=m},function(e,t,n){"use strict";var o,i=this&&this.__extends||(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}o(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var a=n(3),s=function(e){function t(t){var n=e.call(this,t)||this;return n.valueChanged=!1,n.deleting=!1,n.text="",n.text=t.value,n}return i(t,e),t.prototype.componentWillReceiveProps=function(e){e.focused&&this.input.focus()},t.prototype.componentWillUpdate=function(e,t){var n=this.props.value,o=e.value,i=e.suggestedText,a=this.input,s=a&&a.selectionEnd===a.value.length;this.valueChanged=n!==o,this.deleting=this.valueChanged&&n.startsWith(o),this.text=s&&i&&this.valueChanged&&!this.deleting?o+i.substring(o.length):o},t.prototype.componentDidUpdate=function(){var e=this.props,t=e.value,n=e.suggestedText,o=this.input;if(n&&this.valueChanged&&!this.deleting&&o){var i=o.selectionStart,a=o.selectionEnd,s=o.value.length;i===a&&i===s&&o.setSelectionRange(t.length,n.length)}},t.prototype.render=function(){var e=this,t=this.props,n=t.id,o=t.placeholder,i=t.tabIndex,s=t.onKeyDown,r=t.onInput,l=t.onFocus,p=t.onBlur,c=t.disabled,u=t.expanded,d=t.owns,h=t.activedescendant,f=t.clearButton,v=t.clearButtonClick;return[a.createElement("span",{className:"k-searchbar",key:"searchbar"},a.createElement("input",{autoComplete:"off",id:n,placeholder:o,className:"k-input",tabIndex:i,role:"listbox",value:this.text,onChange:function(){},ref:function(t){e.input=t},onKeyDown:s,onInput:r,onFocus:l,onBlur:p,"aria-disabled":c||void 0,disabled:c||void 0,"aria-haspopup":!0,"aria-expanded":u||!1,"aria-owns":d,"aria-activedescendant":h})),f&&a.createElement("span",{className:"k-icon k-clear-value k-i-close",role:"button",onClick:v,onMouseDown:function(e){e.preventDefault()},tabIndex:-1,title:"clear",key:"clearbutton"})]},t}(a.Component);t.default=s}])}}}); | ||
System.register("@progress/kendo-react-dropdowns",["react","react-dom","prop-types","@progress/kendo-react-common","@progress/kendo-react-popup"],function(e){var t,n,o,i,a;function s(e){return e.__useDefault?e.default:e}return{setters:[function(e){t=s(e)},function(e){n=s(e)},function(e){o=s(e)},function(e){i=s(e)},function(e){a=s(e)}],execute:function(){!function(e){var t={};function n(o){if(t[o])return t[o].exports;var i=t[o]={exports:{},id:o,loaded:!1};return e[o].call(i.exports,i,i.exports,n),i.loaded=!0,i.exports}n.m=e,n.c=t,n.p="",n(0)}([function(t,n,o){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var i=o(1);n.DropDownList=i.DropDownList;var a=o(18);n.ComboBox=a.ComboBox,function(t){for(var n in t)e(n,t[n])}(n)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(2);t.DropDownList=o.default},function(e,t,n){"use strict";var o,i=this&&this.__extends||(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}o(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),a=this&&this.__assign||Object.assign||function(e){for(var t,n=1,o=arguments.length;n<o;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e};Object.defineProperty(t,"__esModule",{value:!0});var s=n(3),r=n(4),l=n(5),p=n(6),c=n(7),u=n(8),d=n(10),h=n(11),f=n(13),v=n(15),m=n(16),g=n(12),y=0,b=1,x=2,I=function(e){"INPUT"!==e.target.nodeName&&e.preventDefault()},C=function(e){function t(t){var n=e.call(this,t)||this;n.vs=new m.default,n._lastMousedown=0,n.handleFocus=function(e){n.base.handleFocus(e)},n.handleBlur=function(e){if(n.state.isFocused&&!n._filteringWillFocus){if((new Date).getTime()-n._lastMousedown<500)return n._lastMousedown=0,e.target.focus();var t=n.base.initState();t.data.isFocused=!1,t.data.filterInputFocused=!1,t.data.opened=!1,t.events.push({type:"onBlur"}),t.syntheticEvent=e,n.state.opened&&t.events.push({type:"onClose"}),n.base.applyState(t)}},n.handleWrapperClick=function(e){n.base.handleWrapperClick(e)},n.handleItemClick=function(e,t){n.base.handleItemClick(e,t)},n.handleDefaultItemClick=function(e,t){var o=n.base.initState(),i=n.props,a=i.defaultItem,s=i.valueField,r=i.textField;n.togglePopup(o);var l=g.getItemValue(a,s),p=g.getItemText(a,r);n.setValueSelection(l,p,e,o),o.events.push({type:"onChange"}),o.syntheticEvent=t,n.base.applyState(o)},n.handleKeyDown=function(e){n.base.handleKeyDown(e)},n.handleKeyPress=function(e){if(!n.props.filterable&&0!==e.which&&13!==e.keyCode){var t=String.fromCharCode(e.charCode||e.keyCode);n.props.ignoreCase&&(t=t.toLowerCase())," "===t&&e.preventDefault(),n.setState({word:n.state.word+t,last:n.state.last+t},n.search)}},n.handleItemSelect=function(e,t){n.base.handleItemSelect(e,t)},n.handleListFilterChange=function(e){var t=n.base.initState();n.base.filterChanged(e.target.value,t),t.syntheticEvent=e,n.base.applyState(t)},n.setValueSelection=function(e,t,o,i){void 0===e&&(e=void 0),void 0===t&&(t=void 0),void 0===o&&(o=void 0),n.state.selectedIndex!==o&&(i.data.selectedIndex=o),n.base.value=e,n.base.text=t,n.base.index=o},n.togglePopup=function(e){n.base.togglePopup(e),n.state.opened||n.base.calculatePopupWidth(),n.props.filterable&&n.state.filterInputFocused&&(e.data.filterInputFocused=!1)},n.renderDropDownWrapper=function(){var e=n.props,t=e.defaultItem,o=e.valueField,i=e.disabled,a=e.tabIndex,r=e.loading,l=e.iconClassName,u=n.state,d=u.opened,h=u.isFocused,f=g.getItemIndex(n.props,n.value),v=g.getText(n.props,f);return!v&&g.isPresent(n.value)&&-1===f&&g.getItemValue(t,o)!==n.value&&(v=n.base.text),s.createElement(c.default,{disabled:i,focused:h,tabIndex:a,ariaExpanded:d||!1,ariaOwns:n.base.listBoxId,ariaActiveDescendant:n.base.optionPrefix+"-"+(n.value||""),onFocus:n.handleFocus,onBlur:n.handleBlur,onClick:n.handleWrapperClick,onKeyDown:n.handleKeyDown,onKeyPress:n.handleKeyPress,ref:function(e){n.base.wrapper=e}},s.createElement("span",{className:"k-input"},v),s.createElement("span",{className:"k-select"},s.createElement("span",{className:p.classNames("k-icon",l,{"k-i-arrow-s":!r&&!l,"k-i-loading":r&&!l})})))},n.renderListContainer=function(){var e=n.props.popupSettings,t=n.state.opened,o=void 0!==n.props.virtual,i={onMouseDown:function(e){n._lastMousedown=(new Date).getTime(),I(e)},dir:void 0!==n.props.dir?n.props.dir:n.base.dirCalculated,onBlur:n.handleBlur,width:n.base.popupWidth,popupSettings:{className:"k-list-container k-reset",animate:(e||{}).animate,anchor:n.element,appendTo:document.body,show:t,open:n.onPopupOpened,close:n.onPopupClosed}};return s.createElement(u.default,a({},i),n.renderListFilter(),o?n.renderDefaultItem():void 0,n.renderScrollWrapper(o?[n.renderList(),n.renderScrollElement()]:[n.renderDefaultItem(),n.renderList(),n.renderScrollElement()]))},n.renderScrollWrapper=function(e){var t=n.props.popupSettings,o=n.base.vs;return o.enabled?s.createElement("div",{onScroll:o.scrollHandler,ref:n.scrollerRef,style:{height:(t||{}).height,overflowY:"scroll"}},e):e},n.renderScrollElement=function(){var e=n.base.vs;return e.enabled&&s.createElement("div",{ref:function(t){e.scrollElement=t},key:x})},n.renderList=function(){var e=n.props,t=e.data,o=e.textField,i=e.valueField,a=e.defaultItem,r=e.popupSettings,l=n.base.vs,p=n.state,c=p.opened,u=p.skip,d="translateY("+n.vs.translate+"px)",h=n.value,v=!(g.getItemIndex(n.props,h)<0&&!a);return s.createElement(f.default,{id:n.base.listBoxId,show:c,data:(t||[]).slice(),focusedIndex:v||0!==u?void 0:0,value:h,textField:o,valueField:i,optionPrefix:n.base.optionPrefix,listRef:function(e){l.enabled&&(l.list=e),n.base.list=e},wrapperStyle:l.enabled?{float:"left",width:"100%"}:{maxHeight:(r||{}).height},wrapperCssClass:l.enabled?void 0:"k-list-scroller",listStyle:l.enabled?{transform:d}:void 0,key:b,skip:u,onClick:n.handleItemClick})},n.renderListFilter=function(){var e=n.props.filterable,t=n.state,o=t.opened,i=t.filterText,a=t.filterInputFocused;return e&&s.createElement(d.default,{value:i,focused:o&&a,willFocus:n.filteringInputWillFocus,didFocus:n.filteringInputDidFocus,onChange:n.handleListFilterChange,onKeyDown:n.handleKeyDown})},n.renderDefaultItem=function(){var e=n.props,t=e.textField,o=e.defaultItem;return o&&s.createElement(h.default,{defaultItem:o,textField:t,selected:-1===n.index,key:y,onClick:n.handleDefaultItemClick})},n.scrollerRef=function(e){if(e){var t=n.base.vs;t.container=e,setTimeout(t.calculateScrollSizes.bind(t),0)}},n.search=function(){clearTimeout(n._typingTimeout),n.props.filterable||(n._typingTimeout=setTimeout(function(){n.setState({word:""})},n.props.delay),n.selectNext())},n.selectNext=function(){var e,t,o,i=(n.props.data||[]).map(function(e,t){return{item:e,itemIndex:t}}),a=g.sameCharsOnly(n.state.word,n.state.last),s=i.length,r=n.state.selectedIndex||0;for(n.props.defaultItem&&(o={item:n.props.defaultItem,itemIndex:-1},s+=1,r+=1),r+=a?1:0,i=g.shuffleData(i,r,o),t=0;t<s;t++){e=g.getter(i[t].item,n.props.textField);var l=Boolean(a&&g.matchText(e,n.state.last,n.props.ignoreCase)),p=Boolean(g.matchText(e,n.state.word,n.props.ignoreCase));if(l||p){t=i[t].itemIndex;break}}if(t!==s){var c=n.base.initState();n.handleItemSelect(t,c),n.base.applyState(c)}},n.filteringInputWillFocus=function(){n._filteringWillFocus=!0},n.filteringInputDidFocus=function(){n._filteringWillFocus=!1},n.onPopupOpened=function(){if(n.base.vs.hidden=!1,n.props.filterable)n.setState({filterInputFocused:!0});else{var e=r.findDOMNode(n.base.wrapper);n.state.isFocused&&document.activeElement!==e&&e.focus()}},n.onPopupClosed=function(){if(n.base.vs.hidden=!0,n.state.isFocused){var e=r.findDOMNode(n.base.wrapper);setTimeout(function(){n.state.isFocused&&e.focus()},0)}};var o=void 0!==t.value?t.value:t.defaultValue,i=-1;return!g.isPresent(o)&&g.isPresent(t.defaultItem)?o=g.getItemValue(t.defaultItem,t.valueField):i=g.getItemIndex(t,o),n.state={filterText:"",word:"",last:"",selectedIndex:i,skip:0,isFocused:!1,filterInputFocused:!1,opened:n.props.opened},n.base=new v.default(n),n.base.index=i,n.base.value=o,n}return i(t,e),Object.defineProperty(t.prototype,"element",{get:function(){return this._element},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"value",{get:function(){return this.base.value},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"index",{get:function(){return this.base.index},enumerable:!0,configurable:!0}),t.prototype.componentWillReceiveProps=function(e){this.base.componentWillReceiveProps(e)},t.prototype.componentWillUpdate=function(e,t){this.base.componentWillUpdate(e,t)},t.prototype.componentDidUpdate=function(e,t){this.base.componentDidUpdate(t)},t.prototype.componentDidMount=function(){this.base.componentDidMount()},t.prototype.componentWillUnmount=function(){this.base.componentWillUnmount()},t.prototype.onNavigate=function(e){var t=this.props,n=t.data,o=t.filterable,i=t.defaultItem,a=this.base.initState();a.syntheticEvent=e;var s=this.base.vs,r=g.getItemIndex(this.props,this.value);this.base.navigation.navigate({opened:this.state.opened,event:e,state:a,currentIndex:s.skip+r,max:(s.enabled?s.total:(n||[]).length)-1,min:i?-1:0,leftRightKeysNavigation:o,togglePopup:this.togglePopup,handleItemSelect:this.handleItemSelect}),this.base.applyState(a)},t.prototype.render=function(){var e=this,t=this.props,n=t.style,o=t.className,i=t.label,a=t.dir,r=this.state.opened,l=g.getText(this.props,g.getItemIndex(this.props,this.value)),c=s.createElement("span",{ref:function(t){e._element=t},className:p.classNames("k-widget k-dropdown k-header",o),style:n,dir:a,onMouseDown:r?I:void 0},this.renderDropDownWrapper(),this.renderListContainer());return i?s.createElement(p.FloatingLabel,{label:i,value:l,children:c}):c},t}(s.Component);C.propTypes=a({delay:l.number,ignoreCase:l.bool,loading:l.bool,value:l.oneOfType([l.string,l.number,l.object]),defaultValue:l.oneOfType([l.string,l.number,l.object]),iconClassName:l.string},v.default.propTypes),C.defaultProps=a({delay:500,ignoreCase:!0},v.default.defaultProps),t.default=C},function(e,n){e.exports=t},function(e,t){e.exports=n},function(e,t){e.exports=o},function(e,t){e.exports=i},function(e,t,n){"use strict";var o,i=this&&this.__extends||(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}o(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var a=n(3),s=n(6),r=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return i(t,e),t.prototype.render=function(){var e=this.props,t=e.disabled,n=e.focused,o=e.style,i=e.ariaExpanded,r=e.ariaOwns,l=e.ariaActiveDescendant,p=e.tabIndex;return a.createElement("span",{role:"listbox",tabIndex:t?void 0:p,className:s.classNames("k-dropdown-wrap",this.props.className,{"k-state-default":!t,"k-state-focused":n,"k-state-disabled":t}),style:o,onFocus:this.props.onFocus,onBlur:this.props.onBlur,onKeyDown:this.props.onKeyDown,onKeyPress:this.props.onKeyPress,onClick:this.props.onClick,"aria-disabled":t||void 0,"aria-haspopup":!0,"aria-expanded":i,"aria-owns":r,"aria-activedescendant":l},this.props.children)},t}(a.Component);t.default=r},function(e,t,n){"use strict";var o,i=this&&this.__extends||(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}o(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),a=this&&this.__assign||Object.assign||function(e){for(var t,n=1,o=arguments.length;n<o;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e};Object.defineProperty(t,"__esModule",{value:!0});var s=n(3),r=n(9),l=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return i(t,e),t.prototype.render=function(){var e=this.props,t=e.children,n=e.onMouseDown,o=e.onBlur,i=e.width,l=e.dir,p=e.popupSettings;return s.createElement(r.Popup,a({style:{width:i,direction:l}},p),s.createElement("div",{onMouseDown:n,onBlur:o},t))},t}(s.Component);t.default=l},function(e,t){e.exports=a},function(e,t,n){"use strict";var o,i=this&&this.__extends||(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}o(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var a=n(3),s=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return i(t,e),t.prototype.componentDidUpdate=function(){this._input&&this.props.focused&&(this.props.willFocus&&this.props.willFocus(),this._input.focus(),this.props.didFocus&&setTimeout(this.props.didFocus,0))},t.prototype.render=function(){var e=this;return a.createElement("span",{className:"k-list-filter"},a.createElement("input",{ref:function(t){e._input=t},value:this.props.value,className:"k-textbox",onChange:this.props.onChange,onKeyDown:this.props.onKeyDown}),a.createElement("span",{className:"k-icon k-i-search"}))},t}(a.Component);t.default=s},function(e,t,n){"use strict";var o,i=this&&this.__extends||(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}o(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var a=n(3),s=n(6),r=n(12),l=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.onMouseDown=function(e){e.preventDefault()},t.onClick=function(e){e.preventDefault(),t.props.onClick&&t.props.onClick(-1,e)},t}return i(t,e),t.prototype.render=function(){var e=this.props,t=e.selected,n=e.defaultItem,o=e.textField;return a.createElement("div",{onClick:this.onClick,onMouseDown:this.onMouseDown,className:s.classNames("k-list-optionlabel",{"k-state-selected":t})},r.getter(n,o)||"")},t}(a.Component);t.default=l},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(e){return null!=e};t.isPresent=n;var o=function(e,t,o){if(void 0===o&&(o=!1),n(e))return o?t&&n(e[t])?e[t]:e:t?e[t]:e};t.getter=o;t.sameCharsOnly=function(e,t){for(var n=0;n<e.length;n++)if(e.charAt(n)!==t)return!1;return!0};t.shuffleData=function(e,t,n){var o=e;return n&&(o=[n].concat(o)),o.slice(t).concat(o.slice(0,t))};t.matchText=function(e,t,o){if(!n(e))return!1;var i=String(e);return o&&(i=i.toLowerCase()),0===i.indexOf(t)};var i=["string","number","undefined"],a=function(e){var t=typeof e;return-1!==i.indexOf(t)};t.isPrimitive=a;t.scrollToItem=function(e,t,n,o,i){var a=e.offsetHeight,s=t*n-(i?e.scrollTop-o:0);if(i){var r=0;s+t>a?r=s+t-a:s<0&&(r=s),0!==r?e.scrollTop+=r:0===e.scrollTop&&0!==o&&(e.scrollTop=o)}else s+t>a+e.scrollTop?e.scrollTop=s+t-a:s<e.scrollTop&&(e.scrollTop-=e.scrollTop-s)};t.itemIndexStartsWith=function(e,t,n){var i=-1;if(e){e=e.toLowerCase();for(var s=0;s<t.length;s++){var r=(o(t[s],n,a(t[s]))||"")+"";if(r&&r.toLowerCase().startsWith(e)){i=s;break}}}return i};t.getItemIndex=function(e,t){var n=e.valueField;return(e.data||[]).findIndex(function(e){return e===t||o(e,n)===t})};t.getItemIndexByText=function(e,t,n){return e.findIndex(function(e){return a(e)?t.toLowerCase()===e.toString().toLowerCase():s(e,n).toLowerCase()===t.toLowerCase()})};var s=function(e,t){return a(e)?e:o(e,t)};t.getItemText=s;var r=function(e,t){return t?o(e,t):e};t.getItemValue=r;t.getText=function(e,t){if(!e.data)return null;if(-1===t)return s(e.defaultItem,e.textField);var n=e.data[t];return s(n,e.textField)};t.getValue=function(e,t){if(-1===t)return r(e.defaultItem,e.valueField);if(e.data){var n=e.data[t];return r(n,e.valueField)}}},function(e,t,n){"use strict";var o,i=this&&this.__extends||(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}o(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var a=n(3),s=n(14),r=n(12),l=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return i(t,e),t.prototype.renderItems=function(){var e=this,t=this.props,n=t.textField,o=t.valueField,i=t.value,l=t.optionPrefix,p=t.skip,c=t.focusedIndex;return this.props.data.map(function(t,u){var d=r.getter(t,o),h=(p||0)+u;return a.createElement(s.default,{id:l+"-"+(d||h.toString()),dataItem:t,selected:d===i,focused:c===u,index:h,key:h,onClick:e.props.onClick,textField:n})})},t.prototype.render=function(){var e=this.props,t=e.id,n=e.show,o=e.wrapperCssClass,i=e.wrapperStyle,s=e.listStyle,r=e.listRef,l=this.renderItems();return l.length?a.createElement("div",{className:o,style:i},a.createElement("ul",{id:t,role:"listbox","aria-hidden":!n||void 0,className:"k-list k-reset",ref:r,style:s},l)):a.createElement("div",{className:"k-nodata"},a.createElement("div",null,"NO DATA FOUND."))},t}(a.Component);t.default=l},function(e,t,n){"use strict";var o,i=this&&this.__extends||(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}o(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var a=n(3),s=n(6),r=n(12),l=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.handleClick=function(e){e.preventDefault(),t.props.onClick&&t.props.onClick(t.props.index||0,e)},t}return i(t,e),t.prototype.render=function(){var e=this.props,t=e.id,n=e.selected,o=e.focused,i=e.dataItem,l=e.textField;return a.createElement("li",{id:t,role:"option","aria-selected":n||!1,className:s.classNames("k-item",{"k-state-selected":n,"k-state-focused":o}),onClick:this.handleClick},r.getter(i,l))},t}(a.Component);t.default=l},function(e,t,n){"use strict";var o=this&&this.__assign||Object.assign||function(e){for(var t,n=1,o=arguments.length;n<o;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e};Object.defineProperty(t,"__esModule",{value:!0});var i=n(4),a=n(5),s=n(16),r=n(17),l=n(12),p=n(6),c=function(){function e(e){var t=this;this.valueDuringOnChange=void 0,this.indexDuringOnChange=void 0,this.valueNotInData=!1,this.text="",this.lastTextSelected="",this.selectedItemChanged=!1,this.vs=new s.default,this.navigation=new r.Navigation,this.handleKeyDown=function(e){var n=t.component.props,o=n.filterable,i=n.disabled,a=e.keyCode;i||!(o&&(37===a||39===a||32===a||16===a||36===a||35===a))&&t.component.onNavigate(e)},this.handleWrapperClick=function(e){var n=t.initState();t.component.togglePopup(n),n.syntheticEvent=e,t.applyState(n)},this.handleItemClick=function(e,n){var o=t.initState();t.component.handleItemSelect(e,o),t.component.togglePopup(o),o.syntheticEvent=n,t.applyState(o)},this.handleFocus=function(e){if(!t.component.state.isFocused){var n=t.initState();n.data.isFocused=!0,n.events.push({type:"onFocus"}),n.syntheticEvent=e,t.applyState(n)}},this.filterChanged=function(e,n){var o=t.component.props.textField;n.data.filterText=e,n.events.push({type:"onFilterChange",filter:{field:o,operator:"contains",ignoreCase:!0,value:e}})},this.togglePopup=function(e){e.data.isFocused=!0,e.data.opened=!t.component.state.opened,t.component.state.opened?e.events.push({type:"onClose"}):e.events.push({type:"onOpen"})},this.pageChange=function(e,n){if(t.component.props.virtual){var o=t.initState();o.events.push({type:"onPageChange",page:{skip:e.skip,take:e.take}}),o.syntheticEvent=n,t.applyState(o)}},this.handleItemSelect=function(e,n){var o=e-(t.component.state.skip||0),i=t.component.props,a=i.data||[],s=void 0!==i.value;if(l.isPresent(e))if(o>=0&&o<a.length||-1===o&&i.defaultItem){var r=l.getValue(i,o),p=l.getText(i,o),c=t.value;s?(t.valueDuringOnChange=r,t.indexDuringOnChange=e):(t.value=r,t.index=e,t.text=p,n.data.selectedIndex=e),r!==c&&(n.events.push({type:"onChange"}),t.selectedItemChanged=!0)}else void 0!==i.virtual&&(t.vs.handleVirtualItemSelect(n,t.component.state,t.vs.container,e),t.valueNotInData=!0,s?t.indexDuringOnChange=e:(t.index=e,n.data.selectedIndex=e),t.selectedItemChanged=!0)},this.listBoxId=p.guid(),this.optionPrefix=p.guid(),this.component=e,this.vs.initVirtualization(e.props.virtual,void 0),this.vs.PageChange=this.pageChange}return Object.defineProperty(e.prototype,"value",{get:function(){return void 0!==this.valueDuringOnChange?this.valueDuringOnChange:this._value},set:function(e){this._value=e},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"index",{get:function(){return void 0!==this.indexDuringOnChange?this.indexDuringOnChange:this._index},set:function(e){this._index=e},enumerable:!0,configurable:!0}),e.prototype.componentWillReceiveProps=function(e){var t=this.initState(),n=e.filterable&&void 0!==e.filter&&e.filter!==this.component.props.filter;void 0!==e.opened&&(t.data.opened=e.opened),!e.filterable&&this.component.state.filterText?t.data.filterText="":n&&(t.data.filterText=e.filter),this.vs.updateVirtualization(e.virtual,this.component.props.virtual,t);var o=void 0!==e.value,i=o&&e.value!==this.component.props.value;if(this.selectedItemChanged||i){if(this.valueNotInData&&!o){var a=this.index-(t.data.skip||0);this.value=l.getValue(e,a),this.text=l.getText(e,a)}else this.updateSelectedItem(e,t);this.lastValueSelected=this.value,this.lastTextSelected=this.text}this.selectedItemChanged=!1,this.valueNotInData=!1,this.applyState(t)},e.prototype.componentWillUpdate=function(e,t){t.opened&&this.component.state.opened&&-1!==t.selectedIndex&&this.component.state.selectedIndex!==t.selectedIndex&&this.scrollToSelectedItem(t),void 0!==e.value&&void 0===this.value&&(this.value=e.value)},e.prototype.componentDidUpdate=function(e){var t=this;if(this.component.state.opened&&!e.opened){var n=this.vs.container;if(n){this.vs.updateListScroll(this.component.state,n,function(){l.getItemIndex(t.component.props,t.value)>=0&&t.scrollToSelectedItem(t.component.state)})}else this.scrollToSelectedItem(this.component.state)}},e.prototype.componentDidMount=function(){this.component.element&&(this.dirCalculated=window.getComputedStyle(this.component.element).direction||void 0)},e.prototype.componentWillUnmount=function(){var e=this.vs;delete e.container,delete e.list},e.prototype.scrollToSelectedItem=function(e){var t=this.list||this.vs.list,n=(e.selectedIndex||0)-(e.skip||0),o=t?t.children[0]:void 0;if(o){var i=this.vs,a=i.container||t.parentNode;l.scrollToItem(a,o.offsetHeight,n,i.translate,i.enabled)}},e.prototype.initState=function(){return{data:{},events:[],syntheticEvent:void 0}},e.prototype.applyState=function(e){var t=this,n={syntheticEvent:e.syntheticEvent,nativeEvent:e.syntheticEvent?e.syntheticEvent.nativeEvent:void 0,target:this.component};Object.keys(e.data).length>0&&this.component.setState(e.data),e.events.forEach(function(e){var i=e.type;delete e.type;var a=t.component.props[i];a&&a.call(void 0,o({},n,e))}),this.indexDuringOnChange=void 0,this.valueDuringOnChange=void 0},e.prototype.calculatePopupWidth=function(){var e=(this.component.props.popupSettings||{}).width;this.popupWidth=void 0!==e?e:i.findDOMNode(this.wrapper).offsetWidth+"px"},e.prototype.updateSelectedItem=function(e,t){var n=void 0!==e.value?e.value:this.value,o=l.getItemIndex(e,n),i=l.getText(e,o),a=e.defaultItem?l.getItemValue(e.defaultItem,e.valueField):void 0;l.isPresent(n)&&-1===o&&void 0===a||(-1===o&&void 0!==a&&(n=a,i=l.getItemText(e.defaultItem,this.component.props.textField)),o=-1!==o?o+(t.data.skip||0):o,this.text=i,this.component.setValueSelection(n,i,o,t))},e}();c.propTypes={opened:a.bool,disabled:a.bool,dir:a.string,filterable:a.bool,tabIndex:a.number,data:a.array,textField:a.string,valueField:a.string,className:a.string,label:a.string,popupSettings:a.shape({animate:a.bool,width:a.string,height:a.string}),virtual:a.shape({pageSize:a.number.isRequired,skip:a.number.isRequired,total:a.number.isRequired}),onOpen:a.func,onClose:a.func,onFocus:a.func,onBlur:a.func,onChange:a.func,onFilterChange:a.func,onPageChange:a.func},c.defaultProps={tabIndex:0,popupSettings:{animate:!0,height:"200px"}},t.default=c},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(12),i=1533915,a=function(e,t,n){e.events.push({type:"onPageChange",page:{skip:t,take:n}})},s=function(){function e(){var e=this;this.containerHeight=0,this.skip=0,this.total=0,this.enabled=!1,this.pageSize=0,this.itemHeight=0,this.hidden=!1,this.prevScrollPos=0,this.listTranslate=0,this.scrollSyncing=!1,this.calculateScrollSizes=function(){e.scrollSyncing=!0;var t=!1;if(o.isPresent(e.list)){e.itemHeight=e.list?e.list.children[0].offsetHeight:e.itemHeight,e.containerHeight=Math.min(i,e.itemHeight*e.total);var n=e.containerHeight;(t=e.scrollElement.style.height!==n+"px")&&(e.scrollElement.style.height=n+"px")}return e.scrollSyncing=!1,t},this.scrollHandler=this.scrollHandler.bind(this)}return e.prototype.initVirtualization=function(e,t){this.enabled=void 0!==e,void 0!==e&&(this.skip=e.skip,this.pageSize=e.pageSize,this.total=e.total,void 0!==t&&(t.data.skip=e.skip))},e.prototype.updateVirtualization=function(e,t,n){if(void 0===e||void 0===t||t.total===e.total&&0!==e.skip)this.initVirtualization(e,n);else{var o=Object.assign({},e,{skip:0});this.initVirtualization(o,n),this.calculateScrollSizes()&&this.reset()}},e.prototype.handleVirtualItemSelect=function(e,t,n,o){var i=t.skip||0,s=t.selectedIndex||0,r=t.opened&&n,l=this,p=l.pageSize,c=o-i;if(r&&0===o)a(e,0,p),l.reset();else if(r&&o===l.total-1)a(e,l.total-l.pageSize,p),l.scrollToEnd();else if(r){var u=l.PageChange;l.PageChange=function(t){a(e,t.skip,t.take)},(o>s?l.localScrollDown:l.localScrollUp).call(l,t.syntheticEvent),l.PageChange=u}else if(r||0!==o)if(r||o!==l.total-1){if(!r){var d=Math.max(0,i+(c<0?-1:1));a(e,d,p)}}else a(e,l.total-l.pageSize,p);else a(e,0,p);t.opened||l.reset()},e.prototype.updateListScroll=function(e,t,n){var o=t.scrollTop,i=this,a=i.translate,s=i.hidden,r=e.skip||0;if(o!==a||0===a&&0===o&&r>0){var l=function(){i.enabled=!1;var e=a>0?a:i.itemHeight*r;t.scrollTop=e,i.translateTo(a||e),i.enabled=!0,n()};0===i.itemHeight||s?setTimeout(l,0):l()}},Object.defineProperty(e.prototype,"translate",{get:function(){return this.listTranslate},enumerable:!0,configurable:!0}),e.prototype.changePage=function(e,t){var n=Math.min(Math.max(0,e),this.total-this.pageSize);n!==this.skip&&this.PageChange({skip:n,take:this.pageSize},t)},e.prototype.translateTo=function(e){this.listTranslate=e,this.list&&(this.list.style.transform="translateY("+e+"px)")},e.prototype.reset=function(){this.scrollSyncing=!0,this.container&&(this.container.scrollTop=0),this.translateTo(0),this.scrollSyncing=!1},e.prototype.maxScroll=function(){return this.container.scrollHeight-this.container.offsetHeight},e.prototype.scrollToEnd=function(){if(this.container){var e=this.maxScroll();this.translateTo(e),this.container.scrollTop=e}},e.prototype.localScrollUp=function(e){var t,n=this.itemHeight,o=this.container.scrollTop,i=this.listTranslate,a=o-i;if(!(a>0)){for(t=0;t<this.skip&&!(i+n+a<=o);t++)i-=n;if(i=this.validateTranslate(i),this.skip-t<=0&&i>o)return this.translateTo(0),this.changePage(0,e),void(this.container.scrollTop=0);i!==this.listTranslate&&(this.translateTo(i),this.changePage(this.skip-t,e))}},e.prototype.localScrollDown=function(e){var t,n=this.itemHeight,o=this.container.scrollTop,i=this.listTranslate,a=this.list.children.length;for(t=0;t<a&&!(i+n>o);t++)i+=n;i=this.validateTranslate(i),t>=a&&this.skip+t>=this.total?(this.translateTo(i),this.changePage(this.total-1,e)):i!==this.listTranslate&&(this.translateTo(i),this.changePage(this.skip+t,e))},e.prototype.scrollNonStrict=function(e){var t=this.total*this.prevScrollPos/this.containerHeight,n=Math.min(Math.floor(t),this.total-1),o=this.containerHeight*t/this.total;o=this.validateTranslate(o),this.translateTo(o),this.changePage(n,e)},e.prototype.scrollHandler=function(e){if(this.enabled&&this.list&&!this.hidden&&!this.scrollSyncing){var t=this.container.scrollTop,n=this.prevScrollPos;this.prevScrollPos=t,t-n<0&&t>this.listTranslate-this.list.scrollHeight/10?this.localScrollUp(e):t-n>0&&t<this.listTranslate+2*this.list.scrollHeight/3?this.localScrollDown(e):this.scrollNonStrict(e)}},e.prototype.validateTranslate=function(e){return e=Math.max(0,e),e=Math.min(this.containerHeight-this.list.offsetHeight,e)},e}();t.default=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o,i,a=n(12),s=function(){return function(e,t,n){this.index=e,this.event=t,this.action=n}}();t.NavigationData=s,(i=o=t.NavigationAction||(t.NavigationAction={}))[i.Undefined=0]="Undefined",i[i.Open=1]="Open",i[i.Close=2]="Close",i[i.Enter=3]="Enter",i[i.Space=4]="Space",i[i.Tab=5]="Tab",i[i.Esc=6]="Esc",i[i.Delete=7]="Delete",i[i.Backspace=8]="Backspace",i[i.Home=9]="Home",i[i.End=10]="End",i[i.Up=11]="Up",i[i.Down=12]="Down",i[i.Left=13]="Left",i[i.Right=14]="Right";var r=function(){function e(){}return e.prototype.navigate=function(e){var t=this.process({current:e.currentIndex,max:e.max,min:e.min,event:e.event}),n=t.action;n!==o.Undefined&&(n===o.Open&&!e.opened||n===o.Close&&e.opened||13===e.event.keyCode||32===e.event.keyCode?e.togglePopup(e.state):void 0!==t.index&&e.handleItemSelect(t.index,e.state));var i=n===o.Left||n===o.Right;n===o.Undefined||n===o.Tab||n===o.Backspace||n===o.Delete||i&&e.leftRightKeysNavigation||!(n!==o.Enter||n===o.Enter&&e.opened)||e.event.preventDefault()},e.prototype.process=function(e){var t=e.event,n=t.keyCode,i=t.altKey,a=void 0,r=o.Undefined;return i&&40===n?r=o.Open:i&&38===n?r=o.Close:13===n?r=o.Enter:32===n?r=o.Space:27===n?r=o.Close:9===n?r=o.Tab:38===n?(a=this.next({current:e.current,min:e.min,max:e.max,step:-1}),r=o.Up):37===n?(a=this.next({current:e.current,min:e.min,max:e.max,step:-1}),r=o.Left):40===n?(a=this.next({current:e.current,min:e.min,max:e.max,step:1}),r=o.Down):39===n?(a=this.next({current:e.current,min:e.min,max:e.max,step:1}),r=o.Right):36===n?(a=0,r=o.Home):35===n?(a=e.max,r=o.End):46===n?r=o.Delete:8===n&&(r=o.Backspace),new s(a,t,r)},e.prototype.next=function(e){return a.isPresent(e.current)?Math.min(e.max,Math.max(e.current+e.step,e.min)):e.min},e}();t.Navigation=r},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(19);t.ComboBox=o.default},function(e,t,n){"use strict";var o,i=this&&this.__extends||(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}o(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),a=this&&this.__assign||Object.assign||function(e){for(var t,n=1,o=arguments.length;n<o;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e};Object.defineProperty(t,"__esModule",{value:!0});var s=n(3),r=n(5),l=n(15),p=n(8),c=n(13),u=n(20),d=n(12),h=n(6),f=1,v=2,m=function(e){function t(t){var n=e.call(this,t)||this;n._lastMousedown=0,n.handleItemSelect=function(e,t){n.base.handleItemSelect(e,t),n.base.selectedItemChanged&&(n.state.typedText&&(t.data.typedText=""),n.state.filterText&&(t.data.filterText=""))},n.togglePopup=function(e){n.base.togglePopup(e)},n.renderScrollWrapper=function(e){var t=n.props.popupSettings,o=n.base.vs;return o.enabled?s.createElement("div",{onScroll:o.scrollHandler,ref:n.scrollerRef,style:{height:(t||{}).height,overflowY:"scroll"}},e):e},n.renderScrollElement=function(){var e=n.base.vs;return e.enabled&&s.createElement("div",{ref:function(t){e.scrollElement=t},key:v})},n.renderList=function(){var e,t=n.props,o=t.textField,i=t.valueField,a=t.popupSettings,r=n.base,l=r.vs,p=n.state,u=p.opened,h=p.skip,v="translateY("+l.translate+"px)",m=n.valueToRender(),g=m.value,y=m.text,b=(n.props.data||[]).slice();return u&&(e=y?d.itemIndexStartsWith(y,b,o):0===h?0:void 0),s.createElement(c.default,{id:r.listBoxId,show:u,data:b,focusedIndex:e,value:g,textField:o,valueField:i,optionPrefix:r.optionPrefix,listRef:function(e){l.enabled&&(l.list=e),n.base.list=e},wrapperStyle:l.enabled?{float:"left",width:"100%"}:{maxHeight:(a||{}).height},wrapperCssClass:l.enabled?void 0:"k-list-scroller",listStyle:l.enabled?{transform:v}:void 0,key:f,skip:h,onClick:n.handleItemClick})},n.onInputKeyDown=function(e){var t=e.keyCode;if(13===t||27===t){e.preventDefault();var o=e.currentTarget.value,i=n.base.initState();i.syntheticEvent=e,n.applyInputValue(o,i,e.keyCode)}else 38!==t&&40!==t||(e.preventDefault(),n.handleKeyDown(e))},n.applyInputValue=function(e,t,o){void 0===o&&(o=void 0);var i=n.state.suggestedText||"",a=n.props,s=a.data,r=void 0===s?[]:s,l=a.textField,p=a.valueField,c=a.suggest,u=a.allowCustom,h=a.filterable,f=void 0===o||27===o,v=n.state.opened,m=d.getItemIndexByText(r,e,l);if(v&&(t.data.opened=!1),u&&-1===m&&n.value===e)return v&&t.events.push({type:"onClose"}),n.base.applyState(t);var g=void 0,y="";if(-1!==m?(g=d.getItemValue(r[m],p),y=d.getItemText(r[m],l)):u&&(g=e,y=e),c&&!f&&i.toLowerCase()===e.toLowerCase())y=g=i,t.data.typedText=i;else if(f)if(t.data.suggestedText=void 0,u||-1!==m||e!==n.base.lastTextSelected){if(!u&&-1===m&&e===n.state.typedText)return n.clearValue(t),n.base.applyState(t)}else g=n.base.lastValueSelected,y=n.base.lastTextSelected;else if(13===o&&!u){var b=d.itemIndexStartsWith(e,r,l);return n.handleItemSelect(b,t),v&&t.events.push({type:"onClose"}),n.state.typedText&&(t.data.typedText=""),h&&(t.data.filterText=n.base.text),n.base.applyState(t)}(n.value||"")!==g&&t.events.push({type:"onChange"}),v&&t.events.push({type:"onClose"}),n.base.value=g,n.base.text=y,n.base.applyState(t)},n.onInput=function(e){var t=n.base.initState(),o=e.currentTarget.value,i=void 0!==n.props.value;if(t.syntheticEvent=e,!o)return n.clearValue(t),delete t.data.opened,n.base.applyState(t);n.state.opened||(t.data.opened=!0),t.data.typedText=o,i||(t.data.selectedIndex=-1,n.base.index=-1),n.props.filterable&&n.filterChanged(o,t),n.state.opened===t.data.opened&&t.events.push({type:t.data.opened?"onOpen":"onClose"}),n.suggestValue(o,t),n.base.applyState(t)},n.clearButtonClick=function(e){var t=n.base.initState();t.syntheticEvent=e,n.clearValue(t),n.base.applyState(t)},n.handleFocus=function(e){n.base.handleFocus(e)},n.handleBlur=function(e){if(n.state.isFocused){if((new Date).getTime()-n._lastMousedown<500)return n._lastMousedown=0,e.currentTarget.focus();var t=n.base.initState();t.data.isFocused=!1,t.events.push({type:"onBlur"}),t.syntheticEvent=e,n.applyInputValue(e.currentTarget.value,t)}},n.handleWrapperClick=function(e){n.base.handleWrapperClick(e)},n.handleItemClick=function(e,t){n.base.handleItemClick(e,t)},n.handleKeyDown=function(e){n.base.handleKeyDown(e)},n.filterChanged=function(e,t){n.base.filterChanged(e,t)},n.setValueSelection=function(e,t,o,i){void 0===e&&(e=void 0),void 0===t&&(t=void 0),void 0===o&&(o=void 0),n.props.filterable||t===n.state.text||(i.data.text=t),i.data.selectedIndex!==n.state.selectedIndex&&(i.data.selectedIndex=o),n.base.value=e},n.scrollerRef=function(e){if(e){var t=n.base.vs;t.container=e,setTimeout(t.calculateScrollSizes.bind(t),0)}};var o=t.allowCustom,i=t.opened,a=t.textField,r=t.valueField,p=void 0!==t.value?t.value:t.defaultValue,u=-1,m="";o&&void 0!==p?(m=d.getItemText(p,a),u=d.getItemIndex(t,p)):o||(u=d.getItemIndex(t,p),m=d.getText(t,u)),n.state={filterText:"",typedText:"",text:m,selectedIndex:u,skip:0,isFocused:!1,opened:i};var g=n.base=new l.default(n);return g.value=d.getItemValue(p,r),g.index=u,g.text=m,n._inputId=h.guid(),n}return i(t,e),Object.defineProperty(t.prototype,"element",{get:function(){return this._element},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"value",{get:function(){return this.base.value},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"index",{get:function(){return this.base.index},enumerable:!0,configurable:!0}),t.prototype.componentWillReceiveProps=function(e){this.base.componentWillReceiveProps(e)},t.prototype.componentWillUpdate=function(e,t){this.base.componentWillUpdate(e,t),!this.state.opened&&t.opened&&this.base.calculatePopupWidth();var n=void 0!==t.selectedIndex&&this.state.selectedIndex!==t.selectedIndex,o=t.typedText||!t.typedText&&this.state.typedText&&void 0===this.base.lastValueSelected;if(n){var i=(e.data||[])[(t.selectedIndex||0)-(t.skip||0)];this.base.value=d.getItemValue(i,e.valueField),this.base.text=d.getItemText(i,e.textField),this.base.index=t.selectedIndex||0}else o&&(this.base.lastTextSelected="",this.base.lastValueSelected=void 0,this.base.value=void 0,this.base.index=-1,this.base.text="")},t.prototype.componentDidUpdate=function(e,t){this.base.componentDidUpdate(t)},t.prototype.componentDidMount=function(){this.base.componentDidMount()},t.prototype.componentWillUnmount=function(){this.base.componentWillUnmount()},t.prototype.onNavigate=function(e){var t=this.props,n=t.data,o=void 0===n?[]:n,i=t.filterable,a=t.textField,s=this.base.initState(),r=this.base.vs,l=d.getItemIndex(this.props,this.value),p=this.state.typedText,c=r.skip+l;if(c<0&&p&&(38===e.keyCode||40===e.keyCode)){var u=d.itemIndexStartsWith(p,o,a);u>=0&&(c=38===e.keyCode?u+1:u-1)}this.base.navigation.navigate({opened:this.state.opened,event:e,state:s,currentIndex:c,max:(r.enabled?r.total:o.length)-1,min:0,leftRightKeysNavigation:i,togglePopup:this.togglePopup,handleItemSelect:this.handleItemSelect}),s.syntheticEvent=e,this.base.applyState(s)},t.prototype.render=function(){var e=this,t=this.props,n=t.placeholder,o=t.tabIndex,i=t.dir,a=t.disabled,r=t.clearButton,l=t.label,c=t.popupSettings,d=t.className,f=t.style,v=t.loading,m=t.iconClassName,g=this.state,y=g.isFocused,b=g.opened,x=g.suggestedText,I=this.valueToRender().text,C=this.base.vs,S=s.createElement("span",{className:h.classNames("k-widget k-combobox k-header",{"k-combobox-clearable":r},d),ref:function(t){e._element=t},style:f,dir:i},s.createElement("span",{ref:function(t){e.base.wrapper=t},className:h.classNames("k-dropdown-wrap",{"k-state-default":!a,"k-state-disabled":a,"k-state-focused":y&&!a})},s.createElement(u.default,{id:this._inputId,placeholder:n,tabIndex:o||void 0,value:I,suggestedText:x,focused:y,onKeyDown:this.onInputKeyDown,onInput:this.onInput,onFocus:this.handleFocus,onBlur:this.handleBlur,disabled:a,expanded:b,owns:this.base.listBoxId,activedescendant:this.base.optionPrefix+"-"+(this.value||""),clearButton:!(!r||!I),clearButtonClick:this.clearButtonClick}),s.createElement("span",{className:"k-select",onClick:this.handleWrapperClick,onMouseDown:function(t){t.preventDefault(),e.setState({isFocused:!0})}},s.createElement("span",{className:h.classNames("k-icon",m,{"k-i-arrow-s":!v&&!m,"k-i-loading":v&&!m})}))),s.createElement(p.default,{onMouseDown:function(){e._lastMousedown=(new Date).getTime()},width:this.base.popupWidth,popupSettings:{animate:(c||{}).animate,anchor:this.element,appendTo:document.body,show:b,open:function(){C.hidden=!1},className:"k-list-container k-reset",close:function(){C.hidden=!0}},dir:void 0!==this.props.dir?this.props.dir:this.base.dirCalculated},this.renderScrollWrapper([this.renderList(),this.renderScrollElement()])));return l?s.createElement(h.FloatingLabel,{label:l,value:I,id:this._inputId,children:S}):S},t.prototype.valueToRender=function(e,t){var n=e||this.state,o=n.typedText,i=n.filterText,a=void 0===i?"":i,s=n.opened,r=t||this.props,l=r.value,p=r.filterable,c=void 0!==l,u=this.base.text||"",d=c?l:this.base.value,h=p&&!!a;return s||!u||this.base.lastTextSelected!==u||h&&!this.base.lastTextSelected.toLowerCase().startsWith(a.toLowerCase())?h?{value:d,text:a}:o?{value:null,text:o}:{value:d,text:u}:{value:d,text:u}},t.prototype.suggestValue=function(e,t){if(void 0!==this.state.suggestedText&&(t.data.suggestedText=void 0),this.props.suggest&&e){var n=this.props.data||[],o=this.props.textField,i=n[d.itemIndexStartsWith(e,n,o)];i&&(t.data.suggestedText=d.getItemText(i,o))}},t.prototype.clearValue=function(e){var t=void 0!==this.props.value,n=this.value;t?(this.base.valueDuringOnChange=null,this.base.indexDuringOnChange=-1):(this.base.value=null,this.base.index=-1,this.base.text="",e.data.selectedIndex=-1),e.data.typedText="",void 0!==this.state.suggestedText&&(e.data.suggestedText=void 0),null!==n&&(e.events.push({type:"onChange"}),this.base.selectedItemChanged=!0,this.props.filterable&&this.filterChanged("",e)),this.state.opened&&(e.data.opened=!1,e.events.push({type:"onClose"}))},t}(s.Component);m.propTypes=a({clearButton:r.bool,allowCustom:r.bool,suggest:r.bool,placeholder:r.string,loading:r.bool,value:r.oneOfType([r.string,r.number,r.object]),defaultValue:r.oneOfType([r.string,r.number,r.object]),iconClassName:r.string},l.default.propTypes),m.defaultProps=a({},l.default.defaultProps,{clearButton:!0}),t.default=m},function(e,t,n){"use strict";var o,i=this&&this.__extends||(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}o(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var a=n(3),s=function(e){function t(t){var n=e.call(this,t)||this;return n.valueChanged=!1,n.deleting=!1,n.text="",n.text=t.value,n}return i(t,e),t.prototype.componentWillReceiveProps=function(e){e.focused&&this.input.focus()},t.prototype.componentWillUpdate=function(e,t){var n=this.props.value,o=e.value,i=e.suggestedText,a=this.input,s=a&&a.selectionEnd===a.value.length;this.valueChanged=n!==o,this.deleting=this.valueChanged&&n.startsWith(o),this.text=s&&i&&this.valueChanged&&!this.deleting?o+i.substring(o.length):o},t.prototype.componentDidUpdate=function(){var e=this.props,t=e.value,n=e.suggestedText,o=this.input;if(n&&this.valueChanged&&!this.deleting&&o){var i=o.selectionStart,a=o.selectionEnd,s=o.value.length;i===a&&i===s&&o.setSelectionRange(t.length,n.length)}},t.prototype.render=function(){var e=this,t=this.props,n=t.id,o=t.placeholder,i=t.tabIndex,s=t.onKeyDown,r=t.onInput,l=t.onFocus,p=t.onBlur,c=t.disabled,u=t.expanded,d=t.owns,h=t.activedescendant,f=t.clearButton,v=t.clearButtonClick;return[a.createElement("span",{className:"k-searchbar",key:"searchbar"},a.createElement("input",{autoComplete:"off",id:n,placeholder:o,className:"k-input",tabIndex:i,role:"listbox",value:this.text,onChange:function(){},ref:function(t){e.input=t},onKeyDown:s,onInput:r,onFocus:l,onBlur:p,"aria-disabled":c||void 0,disabled:c||void 0,"aria-haspopup":!0,"aria-expanded":u||!1,"aria-owns":d,"aria-activedescendant":h})),f&&a.createElement("span",{className:"k-icon k-clear-value k-i-close",role:"button",onClick:v,onMouseDown:function(e){e.preventDefault()},tabIndex:-1,title:"clear",key:"clearbutton"})]},t}(a.Component);t.default=s}])}}}); |
{ | ||
"name": "@progress/kendo-react-dropdowns", | ||
"version": "0.4.0-dev.201802161152", | ||
"version": "0.4.0-dev.201802210843", | ||
"description": "Kendo UI for React DropDowns package", | ||
@@ -29,4 +29,4 @@ "repository": { | ||
"dependencies": { | ||
"@progress/kendo-react-common": "0.4.0-dev.201802161152", | ||
"@progress/kendo-react-popup": "0.4.0-dev.201802161152", | ||
"@progress/kendo-react-common": "0.4.0-dev.201802210843", | ||
"@progress/kendo-react-popup": "0.4.0-dev.201802210843", | ||
"prop-types": "^15.6.0" | ||
@@ -33,0 +33,0 @@ }, |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
584495
7038
+ Added@progress/kendo-react-animation@0.4.0-dev.201802210843(transitive)
+ Added@progress/kendo-react-common@0.4.0-dev.201802210843(transitive)
+ Added@progress/kendo-react-popup@0.4.0-dev.201802210843(transitive)
- Removed@progress/kendo-react-animation@0.4.0-dev.201802161152(transitive)
- Removed@progress/kendo-react-common@0.4.0-dev.201802161152(transitive)
- Removed@progress/kendo-react-popup@0.4.0-dev.201802161152(transitive)