"use strict";(globalThis.itsecWebpackJsonP=globalThis.itsecWebpackJsonP||[]).push([[2766],{12766:(t,e,n)=>{n.r(e),n.d(e,{default:()=>C,defaultProps:()=>y,makeCreatableSelect:()=>w});var r=n(87462),o=n(42982),i=n(4942),a=n(15671),c=n(43144),s=n(60136),u=n(82963),l=n(61120),f=n(99196),p=n.n(f),v=(n(1103),n(91850),n(48533)),h=n(6224),O=(n(25657),n(66680),n(61085));function g(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}var b=function(){var t=arguments.length>1?arguments[1]:void 0,e=String(arguments.length>0&&void 0!==arguments[0]?arguments[0]:"").toLowerCase(),n=String(t.value).toLowerCase(),r=String(t.label).toLowerCase();return n===e||r===e},y=function(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?g(Object(n),!0).forEach((function(e){(0,i.Z)(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):g(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}({allowCreateWhileLoading:!1,createOptionPosition:"last"},{formatCreateLabel:function(t){return'Create "'.concat(t,'"')},isValidNewOption:function(t,e,n){return!(!t||e.some((function(e){return b(t,e)}))||n.some((function(e){return b(t,e)})))},getNewOptionData:function(t,e){return{label:e,value:t,__isNew__:!0}}}),w=function(t){var e,n;return n=e=function(e){(0,s.Z)(h,e);var n,i,f=(n=h,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}(),function(){var t,e=(0,l.Z)(n);if(i){var r=(0,l.Z)(this).constructor;t=Reflect.construct(e,arguments,r)}else t=e.apply(this,arguments);return(0,u.Z)(this,t)});function h(t){var e;(0,a.Z)(this,h),(e=f.call(this,t)).select=void 0,e.onChange=function(t,n){var r=e.props,i=r.getNewOptionData,a=r.inputValue,c=r.isMulti,s=r.onChange,u=r.onCreateOption,l=r.value,f=r.name;if("select-option"!==n.action)return s(t,n);var p=e.state.newOption,h=Array.isArray(t)?t:[t];if(h[h.length-1]!==p)s(t,n);else if(u)u(a);else{var O=i(a,a),g={action:"create-option",name:f};s(c?[].concat((0,o.Z)((0,v.C)(l)),[O]):O,g)}};var n=t.options||[];return e.state={newOption:void 0,options:n},e}return(0,c.Z)(h,[{key:"UNSAFE_componentWillReceiveProps",value:function(t){var e=t.allowCreateWhileLoading,n=t.createOptionPosition,r=t.formatCreateLabel,i=t.getNewOptionData,a=t.inputValue,c=t.isLoading,s=t.isValidNewOption,u=t.value,l=t.options||[],f=this.state.newOption;f=s(a,(0,v.C)(u),l)?i(a,r(a)):void 0,this.setState({newOption:f,options:!e&&c||!f?l:"first"===n?[f].concat((0,o.Z)(l)):[].concat((0,o.Z)(l),[f])})}},{key:"focus",value:function(){this.select.focus()}},{key:"blur",value:function(){this.select.blur()}},{key:"render",value:function(){var e=this,n=this.state.options;return p().createElement(t,(0,r.Z)({},this.props,{ref:function(t){e.select=t},options:n,onChange:this.onChange}))}}]),h}(f.Component),e.defaultProps=y,n},d=w(h.S);const C=(0,O.m)(d)}}]);