@pdftron/webviewer
Version:
[WebViewer](https://www.apryse.com/webviewer) is a powerful JavaScript Document SDK and UI Component Library that is a part of the [Apryse PDF SDK](https://www.apryse.com). It provides a slick, out-of-the-box responsive UI that interacts with the core lib
1 lines • 90.9 kB
JavaScript
(window.webpackJsonp=window.webpackJsonp||[]).push([[30],{1568:function(e,t,n){"use strict";n.d(t,"a",(function(){return d})),n.d(t,"b",(function(){return g})),n.d(t,"c",(function(){return f})),n.d(t,"d",(function(){return u})),n.d(t,"e",(function(){return v})),n.d(t,"f",(function(){return b})),n.d(t,"g",(function(){return c})),n.d(t,"h",(function(){return p}));var r=n(0),o=n(1589),i=(n(154),n(1592),n(1616),n(1613)),a=n(1631),s=n(1614),u=!1,c="undefined"!=typeof document,l=r.createContext("undefined"!=typeof HTMLElement?Object(o.a)({key:"css"}):null),d=l.Provider,p=function(e){return Object(r.forwardRef)((function(t,n){var o=Object(r.useContext)(l);return e(t,o,n)}))};c||(p=function(e){return function(t){var n=Object(r.useContext)(l);return null===n?(n=Object(o.a)({key:"css"}),r.createElement(l.Provider,{value:n},e(t,n))):e(t,n)}});var f=r.createContext({});var b={}.hasOwnProperty,h="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",v=function(e,t){var n={};for(var r in t)b.call(t,r)&&(n[r]=t[r]);return n[h]=e,n},m=function(e){var t=e.cache,n=e.serialized,o=e.isStringTag;Object(i.c)(t,n,o);var a=Object(s.a)((function(){return Object(i.b)(t,n,o)}));if(!c&&void 0!==a){for(var u,l=n.name,d=n.next;void 0!==d;)l+=" "+d.name,d=d.next;return r.createElement("style",((u={})["data-emotion"]=t.key+" "+l,u.dangerouslySetInnerHTML={__html:a},u.nonce=t.sheet.nonce,u))}return null},g=p((function(e,t,n){var o=e.css;"string"==typeof o&&void 0!==t.registered[o]&&(o=t.registered[o]);var s=e[h],c=[o],l="";"string"==typeof e.className?l=Object(i.a)(t.registered,c,e.className):null!=e.className&&(l=e.className+" ");var d=Object(a.a)(c,void 0,r.useContext(f));l+=t.key+"-"+d.name;var p={};for(var v in e)b.call(e,v)&&"css"!==v&&v!==h&&!u&&(p[v]=e[v]);return p.className=l,n&&(p.ref=n),r.createElement(r.Fragment,null,r.createElement(m,{cache:t,serialized:d,isStringTag:"string"==typeof s}),r.createElement(s,p))}))},1577:function(e,t,n){"use strict";n.d(t,"a",(function(){return s})),n.d(t,"b",(function(){return a})),n.d(t,"c",(function(){return u}));var r=n(1568),o=n(0),i=(n(1613),n(1614),n(1631)),a=(n(1589),n(1569),n(1592),n(375),function(e,t){var n=arguments;if(null==t||!r.f.call(t,"css"))return o.createElement.apply(void 0,n);var i=n.length,a=new Array(i);a[0]=r.b,a[1]=Object(r.e)(e,t);for(var s=2;s<i;s++)a[s]=n[s];return o.createElement.apply(null,a)});function s(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return Object(i.a)(t)}var u=function(){var e=s.apply(void 0,arguments),t="animation-"+e.name;return{name:t,styles:"@keyframes "+t+"{"+e.styles+"}",anim:1,toString:function(){return"_EMO_"+this.name+"_"+this.styles+"_EMO_"}}}},1579:function(e,t,n){"use strict";n.d(t,"a",(function(){return he})),n.d(t,"b",(function(){return K})),n.d(t,"c",(function(){return J}));var r=n(154),o=n(374),i=n(167),a=n(168),s=n(287),u=n(286);function c(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(c=function(){return!!e})()}var l=n(249);var d=n(1630),p=n(0),f=n(1583),b=n(1577),h=n(1602),v=n(1581);for(var m={name:"7pg0cj-a11yText",styles:"label:a11yText;z-index:9999;border:0;clip:rect(1px, 1px, 1px, 1px);height:1px;width:1px;position:absolute;overflow:hidden;padding:0;white-space:nowrap"},g=function(e){return Object(b.b)("span",Object(r.a)({css:m},e))},O={guidance:function(e){var t=e.isSearchable,n=e.isMulti,r=e.tabSelectsValue,o=e.context,i=e.isInitialFocus;switch(o){case"menu":return"Use Up and Down to choose options, press Enter to select the currently focused option, press Escape to exit the menu".concat(r?", press Tab to select the option and exit the menu":"",".");case"input":return i?"".concat(e["aria-label"]||"Select"," is focused ").concat(t?",type to refine list":"",", press Down to open the menu, ").concat(n?" press left to focus selected values":""):"";case"value":return"Use left and right to toggle between focused values, press Backspace to remove the currently focused value";default:return""}},onChange:function(e){var t=e.action,n=e.label,r=void 0===n?"":n,o=e.labels,i=e.isDisabled;switch(t){case"deselect-option":case"pop-value":case"remove-value":return"option ".concat(r,", deselected.");case"clear":return"All selected options have been cleared.";case"initial-input-focus":return"option".concat(o.length>1?"s":""," ").concat(o.join(","),", selected.");case"select-option":return"option ".concat(r,i?" is disabled. Select another option.":", selected.");default:return""}},onFocus:function(e){var t=e.context,n=e.focused,r=e.options,o=e.label,i=void 0===o?"":o,a=e.selectValue,s=e.isDisabled,u=e.isSelected,c=e.isAppleDevice,l=function(e,t){return e&&e.length?"".concat(e.indexOf(t)+1," of ").concat(e.length):""};if("value"===t&&a)return"value ".concat(i," focused, ").concat(l(a,n),".");if("menu"===t&&c){var d=s?" disabled":"",p="".concat(u?" selected":"").concat(d);return"".concat(i).concat(p,", ").concat(l(r,n),".")}return""},onFilter:function(e){var t=e.inputValue,n=e.resultsMessage;return"".concat(n).concat(t?" for search term "+t:"",".")}},y=function(e){var t=e.ariaSelection,n=e.focusedOption,r=e.focusedValue,i=e.focusableOptions,a=e.isFocused,s=e.selectValue,u=e.selectProps,c=e.id,l=e.isAppleDevice,d=u.ariaLiveMessages,f=u.getOptionLabel,h=u.inputValue,v=u.isMulti,m=u.isOptionDisabled,y=u.isSearchable,j=u.menuIsOpen,w=u.options,C=u.screenReaderStatus,x=u.tabSelectsValue,I=u.isLoading,S=u["aria-label"],M=u["aria-live"],E=Object(p.useMemo)((function(){return Object(o.a)(Object(o.a)({},O),d||{})}),[d]),V=Object(p.useMemo)((function(){var e,n="";if(t&&E.onChange){var r=t.option,i=t.options,a=t.removedValue,u=t.removedValues,c=t.value,l=a||r||(e=c,Array.isArray(e)?null:e),d=l?f(l):"",p=i||u||void 0,b=p?p.map(f):[],h=Object(o.a)({isDisabled:l&&m(l,s),label:d,labels:b},t);n=E.onChange(h)}return n}),[t,E,m,s,f]),k=Object(p.useMemo)((function(){var e="",t=n||r,o=!!(n&&s&&s.includes(n));if(t&&E.onFocus){var a={focused:t,label:f(t),isDisabled:m(t,s),isSelected:o,options:i,context:t===n?"menu":"value",selectValue:s,isAppleDevice:l};e=E.onFocus(a)}return e}),[n,r,f,m,E,i,s,l]),P=Object(p.useMemo)((function(){var e="";if(j&&w.length&&!I&&E.onFilter){var t=C({count:i.length});e=E.onFilter({inputValue:h,resultsMessage:t})}return e}),[i,h,j,E,w,C,I]),L="initial-input-focus"===(null==t?void 0:t.action),R=Object(p.useMemo)((function(){var e="";if(E.guidance){var t=r?"value":j?"menu":"input";e=E.guidance({"aria-label":S,context:t,isDisabled:n&&m(n,s),isMulti:v,isSearchable:y,tabSelectsValue:x,isInitialFocus:L})}return e}),[S,n,r,v,m,y,j,E,s,x,L]),D=Object(b.b)(p.Fragment,null,Object(b.b)("span",{id:"aria-selection"},V),Object(b.b)("span",{id:"aria-focused"},k),Object(b.b)("span",{id:"aria-results"},P),Object(b.b)("span",{id:"aria-guidance"},R));return Object(b.b)(p.Fragment,null,Object(b.b)(g,{id:c},L&&D),Object(b.b)(g,{"aria-live":M,"aria-atomic":"false","aria-relevant":"additions text",role:"log"},a&&!L&&D))},j=[{base:"A",letters:"AⒶAÀÁÂẦẤẪẨÃĀĂẰẮẴẲȦǠÄǞẢÅǺǍȀȂẠẬẶḀĄȺⱯ"},{base:"AA",letters:"Ꜳ"},{base:"AE",letters:"ÆǼǢ"},{base:"AO",letters:"Ꜵ"},{base:"AU",letters:"Ꜷ"},{base:"AV",letters:"ꜸꜺ"},{base:"AY",letters:"Ꜽ"},{base:"B",letters:"BⒷBḂḄḆɃƂƁ"},{base:"C",letters:"CⒸCĆĈĊČÇḈƇȻꜾ"},{base:"D",letters:"DⒹDḊĎḌḐḒḎĐƋƊƉꝹ"},{base:"DZ",letters:"DZDŽ"},{base:"Dz",letters:"DzDž"},{base:"E",letters:"EⒺEÈÉÊỀẾỄỂẼĒḔḖĔĖËẺĚȄȆẸỆȨḜĘḘḚƐƎ"},{base:"F",letters:"FⒻFḞƑꝻ"},{base:"G",letters:"GⒼGǴĜḠĞĠǦĢǤƓꞠꝽꝾ"},{base:"H",letters:"HⒽHĤḢḦȞḤḨḪĦⱧⱵꞍ"},{base:"I",letters:"IⒾIÌÍÎĨĪĬİÏḮỈǏȈȊỊĮḬƗ"},{base:"J",letters:"JⒿJĴɈ"},{base:"K",letters:"KⓀKḰǨḲĶḴƘⱩꝀꝂꝄꞢ"},{base:"L",letters:"LⓁLĿĹĽḶḸĻḼḺŁȽⱢⱠꝈꝆꞀ"},{base:"LJ",letters:"LJ"},{base:"Lj",letters:"Lj"},{base:"M",letters:"MⓂMḾṀṂⱮƜ"},{base:"N",letters:"NⓃNǸŃÑṄŇṆŅṊṈȠƝꞐꞤ"},{base:"NJ",letters:"NJ"},{base:"Nj",letters:"Nj"},{base:"O",letters:"OⓄOÒÓÔỒỐỖỔÕṌȬṎŌṐṒŎȮȰÖȪỎŐǑȌȎƠỜỚỠỞỢỌỘǪǬØǾƆƟꝊꝌ"},{base:"OI",letters:"Ƣ"},{base:"OO",letters:"Ꝏ"},{base:"OU",letters:"Ȣ"},{base:"P",letters:"PⓅPṔṖƤⱣꝐꝒꝔ"},{base:"Q",letters:"QⓆQꝖꝘɊ"},{base:"R",letters:"RⓇRŔṘŘȐȒṚṜŖṞɌⱤꝚꞦꞂ"},{base:"S",letters:"SⓈSẞŚṤŜṠŠṦṢṨȘŞⱾꞨꞄ"},{base:"T",letters:"TⓉTṪŤṬȚŢṰṮŦƬƮȾꞆ"},{base:"TZ",letters:"Ꜩ"},{base:"U",letters:"UⓊUÙÚÛŨṸŪṺŬÜǛǗǕǙỦŮŰǓȔȖƯỪỨỮỬỰỤṲŲṶṴɄ"},{base:"V",letters:"VⓋVṼṾƲꝞɅ"},{base:"VY",letters:"Ꝡ"},{base:"W",letters:"WⓌWẀẂŴẆẄẈⱲ"},{base:"X",letters:"XⓍXẊẌ"},{base:"Y",letters:"YⓎYỲÝŶỸȲẎŸỶỴƳɎỾ"},{base:"Z",letters:"ZⓏZŹẐŻŽẒẔƵȤⱿⱫꝢ"},{base:"a",letters:"aⓐaẚàáâầấẫẩãāăằắẵẳȧǡäǟảåǻǎȁȃạậặḁąⱥɐ"},{base:"aa",letters:"ꜳ"},{base:"ae",letters:"æǽǣ"},{base:"ao",letters:"ꜵ"},{base:"au",letters:"ꜷ"},{base:"av",letters:"ꜹꜻ"},{base:"ay",letters:"ꜽ"},{base:"b",letters:"bⓑbḃḅḇƀƃɓ"},{base:"c",letters:"cⓒcćĉċčçḉƈȼꜿↄ"},{base:"d",letters:"dⓓdḋďḍḑḓḏđƌɖɗꝺ"},{base:"dz",letters:"dzdž"},{base:"e",letters:"eⓔeèéêềếễểẽēḕḗĕėëẻěȅȇẹệȩḝęḙḛɇɛǝ"},{base:"f",letters:"fⓕfḟƒꝼ"},{base:"g",letters:"gⓖgǵĝḡğġǧģǥɠꞡᵹꝿ"},{base:"h",letters:"hⓗhĥḣḧȟḥḩḫẖħⱨⱶɥ"},{base:"hv",letters:"ƕ"},{base:"i",letters:"iⓘiìíîĩīĭïḯỉǐȉȋịįḭɨı"},{base:"j",letters:"jⓙjĵǰɉ"},{base:"k",letters:"kⓚkḱǩḳķḵƙⱪꝁꝃꝅꞣ"},{base:"l",letters:"lⓛlŀĺľḷḹļḽḻſłƚɫⱡꝉꞁꝇ"},{base:"lj",letters:"lj"},{base:"m",letters:"mⓜmḿṁṃɱɯ"},{base:"n",letters:"nⓝnǹńñṅňṇņṋṉƞɲʼnꞑꞥ"},{base:"nj",letters:"nj"},{base:"o",letters:"oⓞoòóôồốỗổõṍȭṏōṑṓŏȯȱöȫỏőǒȍȏơờớỡởợọộǫǭøǿɔꝋꝍɵ"},{base:"oi",letters:"ƣ"},{base:"ou",letters:"ȣ"},{base:"oo",letters:"ꝏ"},{base:"p",letters:"pⓟpṕṗƥᵽꝑꝓꝕ"},{base:"q",letters:"qⓠqɋꝗꝙ"},{base:"r",letters:"rⓡrŕṙřȑȓṛṝŗṟɍɽꝛꞧꞃ"},{base:"s",letters:"sⓢsßśṥŝṡšṧṣṩșşȿꞩꞅẛ"},{base:"t",letters:"tⓣtṫẗťṭțţṱṯŧƭʈⱦꞇ"},{base:"tz",letters:"ꜩ"},{base:"u",letters:"uⓤuùúûũṹūṻŭüǜǘǖǚủůűǔȕȗưừứữửựụṳųṷṵʉ"},{base:"v",letters:"vⓥvṽṿʋꝟʌ"},{base:"vy",letters:"ꝡ"},{base:"w",letters:"wⓦwẁẃŵẇẅẘẉⱳ"},{base:"x",letters:"xⓧxẋẍ"},{base:"y",letters:"yⓨyỳýŷỹȳẏÿỷẙỵƴɏỿ"},{base:"z",letters:"zⓩzźẑżžẓẕƶȥɀⱬꝣ"}],w=new RegExp("["+j.map((function(e){return e.letters})).join("")+"]","g"),C={},x=0;x<j.length;x++)for(var I=j[x],S=0;S<I.letters.length;S++)C[I.letters[S]]=I.base;var M=function(e){return e.replace(w,(function(e){return C[e]}))},E=Object(h.a)(M),V=function(e){return e.replace(/^\s+|\s+$/g,"")},k=function(e){return"".concat(e.label," ").concat(e.value)},P=["innerRef"];function L(e){var t=e.innerRef,n=Object(v.a)(e,P),o=Object(f.D)(n,"onExited","in","enter","exit","appear");return Object(b.b)("input",Object(r.a)({ref:t},o,{css:Object(b.a)({label:"dummyInput",background:0,border:0,caretColor:"transparent",fontSize:"inherit",gridArea:"1 / 1 / 2 / 3",outline:0,padding:0,width:1,color:"transparent",left:-100,opacity:0,position:"relative",transform:"scale(.01)"},"","")}))}var R=["boxSizing","height","overflow","paddingRight","position"],D={boxSizing:"border-box",overflow:"hidden",position:"relative",height:"100%"};function F(e){e.preventDefault()}function A(e){e.stopPropagation()}function T(){var e=this.scrollTop,t=this.scrollHeight,n=e+this.offsetHeight;0===e?this.scrollTop=1:n===t&&(this.scrollTop=e-1)}function H(){return"ontouchstart"in window||navigator.maxTouchPoints}var N=!("undefined"==typeof window||!window.document||!window.document.createElement),z=0,U={capture:!1,passive:!1};var B=function(e){var t=e.target;return t.ownerDocument.activeElement&&t.ownerDocument.activeElement.blur()},_={name:"1kfdb0e",styles:"position:fixed;left:0;bottom:0;right:0;top:0"};function $(e){var t=e.children,n=e.lockEnabled,r=e.captureEnabled,o=function(e){var t=e.isEnabled,n=e.onBottomArrive,r=e.onBottomLeave,o=e.onTopArrive,i=e.onTopLeave,a=Object(p.useRef)(!1),s=Object(p.useRef)(!1),u=Object(p.useRef)(0),c=Object(p.useRef)(null),l=Object(p.useCallback)((function(e,t){if(null!==c.current){var u=c.current,l=u.scrollTop,d=u.scrollHeight,p=u.clientHeight,f=c.current,b=t>0,h=d-p-l,v=!1;h>t&&a.current&&(r&&r(e),a.current=!1),b&&s.current&&(i&&i(e),s.current=!1),b&&t>h?(n&&!a.current&&n(e),f.scrollTop=d,v=!0,a.current=!0):!b&&-t>l&&(o&&!s.current&&o(e),f.scrollTop=0,v=!0,s.current=!0),v&&function(e){e.cancelable&&e.preventDefault(),e.stopPropagation()}(e)}}),[n,r,o,i]),d=Object(p.useCallback)((function(e){l(e,e.deltaY)}),[l]),b=Object(p.useCallback)((function(e){u.current=e.changedTouches[0].clientY}),[]),h=Object(p.useCallback)((function(e){var t=u.current-e.changedTouches[0].clientY;l(e,t)}),[l]),v=Object(p.useCallback)((function(e){if(e){var t=!!f.E&&{passive:!1};e.addEventListener("wheel",d,t),e.addEventListener("touchstart",b,t),e.addEventListener("touchmove",h,t)}}),[h,b,d]),m=Object(p.useCallback)((function(e){e&&(e.removeEventListener("wheel",d,!1),e.removeEventListener("touchstart",b,!1),e.removeEventListener("touchmove",h,!1))}),[h,b,d]);return Object(p.useEffect)((function(){if(t){var e=c.current;return v(e),function(){m(e)}}}),[t,v,m]),function(e){c.current=e}}({isEnabled:void 0===r||r,onBottomArrive:e.onBottomArrive,onBottomLeave:e.onBottomLeave,onTopArrive:e.onTopArrive,onTopLeave:e.onTopLeave}),i=function(e){var t=e.isEnabled,n=e.accountForScrollbars,r=void 0===n||n,o=Object(p.useRef)({}),i=Object(p.useRef)(null),a=Object(p.useCallback)((function(e){if(N){var t=document.body,n=t&&t.style;if(r&&R.forEach((function(e){var t=n&&n[e];o.current[e]=t})),r&&z<1){var i=parseInt(o.current.paddingRight,10)||0,a=document.body?document.body.clientWidth:0,s=window.innerWidth-a+i||0;Object.keys(D).forEach((function(e){var t=D[e];n&&(n[e]=t)})),n&&(n.paddingRight="".concat(s,"px"))}t&&H()&&(t.addEventListener("touchmove",F,U),e&&(e.addEventListener("touchstart",T,U),e.addEventListener("touchmove",A,U))),z+=1}}),[r]),s=Object(p.useCallback)((function(e){if(N){var t=document.body,n=t&&t.style;z=Math.max(z-1,0),r&&z<1&&R.forEach((function(e){var t=o.current[e];n&&(n[e]=t)})),t&&H()&&(t.removeEventListener("touchmove",F,U),e&&(e.removeEventListener("touchstart",T,U),e.removeEventListener("touchmove",A,U)))}}),[r]);return Object(p.useEffect)((function(){if(t){var e=i.current;return a(e),function(){s(e)}}}),[t,a,s]),function(e){i.current=e}}({isEnabled:n});return Object(b.b)(p.Fragment,null,n&&Object(b.b)("div",{onClick:B,css:_}),t((function(e){o(e),i(e)})))}var W={name:"1a0ro4n-requiredInput",styles:"label:requiredInput;opacity:0;pointer-events:none;position:absolute;bottom:0;left:0;right:0;width:100%"},G=function(e){var t=e.name,n=e.onFocus;return Object(b.b)("input",{required:!0,name:t,tabIndex:-1,"aria-hidden":"true",onFocus:n,css:W,value:"",onChange:function(){}})};function Y(e){var t;return"undefined"!=typeof window&&null!=window.navigator&&e.test((null===(t=window.navigator.userAgentData)||void 0===t?void 0:t.platform)||window.navigator.platform)}function q(){return Y(/^Mac/i)}function X(){return Y(/^iPhone/i)||Y(/^iPad/i)||q()&&navigator.maxTouchPoints>1}var K=function(e){return e.label},J=function(e){return e.value},Z={clearIndicator:f.m,container:f.n,control:f.p,dropdownIndicator:f.q,group:f.s,groupHeading:f.r,indicatorsContainer:f.u,indicatorSeparator:f.t,input:f.v,loadingIndicator:f.x,loadingMessage:f.w,menu:f.y,menuList:f.z,menuPortal:f.A,multiValue:f.B,multiValueLabel:f.C,multiValueRemove:f.F,noOptionsMessage:f.G,option:f.H,placeholder:f.I,singleValue:f.J,valueContainer:f.K};var Q,ee={borderRadius:4,colors:{primary:"#2684FF",primary75:"#4C9AFF",primary50:"#B2D4FF",primary25:"#DEEBFF",danger:"#DE350B",dangerLight:"#FFBDAD",neutral0:"hsl(0, 0%, 100%)",neutral5:"hsl(0, 0%, 95%)",neutral10:"hsl(0, 0%, 90%)",neutral20:"hsl(0, 0%, 80%)",neutral30:"hsl(0, 0%, 70%)",neutral40:"hsl(0, 0%, 60%)",neutral50:"hsl(0, 0%, 50%)",neutral60:"hsl(0, 0%, 40%)",neutral70:"hsl(0, 0%, 30%)",neutral80:"hsl(0, 0%, 20%)",neutral90:"hsl(0, 0%, 10%)"},spacing:{baseUnit:4,controlHeight:38,menuGutter:8}},te={"aria-live":"polite",backspaceRemovesValue:!0,blurInputOnSelect:Object(f.L)(),captureMenuScroll:!Object(f.L)(),classNames:{},closeMenuOnSelect:!0,closeMenuOnScroll:!1,components:{},controlShouldRenderValue:!0,escapeClearsValue:!1,filterOption:function(e,t){if(e.data.__isNew__)return!0;var n=Object(o.a)({ignoreCase:!0,ignoreAccents:!0,stringify:k,trim:!0,matchFrom:"any"},Q),r=n.ignoreCase,i=n.ignoreAccents,a=n.stringify,s=n.trim,u=n.matchFrom,c=s?V(t):t,l=s?V(a(e)):a(e);return r&&(c=c.toLowerCase(),l=l.toLowerCase()),i&&(c=E(c),l=M(l)),"start"===u?l.substr(0,c.length)===c:l.indexOf(c)>-1},formatGroupLabel:function(e){return e.label},getOptionLabel:K,getOptionValue:J,isDisabled:!1,isLoading:!1,isMulti:!1,isRtl:!1,isSearchable:!0,isOptionDisabled:function(e){return!!e.isDisabled},loadingMessage:function(){return"Loading..."},maxMenuHeight:300,minMenuHeight:140,menuIsOpen:!1,menuPlacement:"bottom",menuPosition:"absolute",menuShouldBlockScroll:!1,menuShouldScrollIntoView:!Object(f.a)(),noOptionsMessage:function(){return"No options"},openMenuOnFocus:!1,openMenuOnClick:!0,options:[],pageSize:5,placeholder:"Select...",screenReaderStatus:function(e){var t=e.count;return"".concat(t," result").concat(1!==t?"s":""," available")},styles:{},tabIndex:0,tabSelectsValue:!0,unstyled:!1};function ne(e,t,n,r){return{type:"option",data:t,isDisabled:le(e,t,n),isSelected:de(e,t,n),label:ue(e,t),value:ce(e,t),index:r}}function re(e,t){return e.options.map((function(n,r){if("options"in n){var o=n.options.map((function(n,r){return ne(e,n,t,r)})).filter((function(t){return ae(e,t)}));return o.length>0?{type:"group",data:n,options:o,index:r}:void 0}var i=ne(e,n,t,r);return ae(e,i)?i:void 0})).filter(f.k)}function oe(e){return e.reduce((function(e,t){return"group"===t.type?e.push.apply(e,Object(d.a)(t.options.map((function(e){return e.data})))):e.push(t.data),e}),[])}function ie(e,t){return e.reduce((function(e,n){return"group"===n.type?e.push.apply(e,Object(d.a)(n.options.map((function(e){return{data:e.data,id:"".concat(t,"-").concat(n.index,"-").concat(e.index)}})))):e.push({data:n.data,id:"".concat(t,"-").concat(n.index)}),e}),[])}function ae(e,t){var n=e.inputValue,r=void 0===n?"":n,o=t.data,i=t.isSelected,a=t.label,s=t.value;return(!fe(e)||!i)&&pe(e,{label:a,value:s,data:o},r)}var se=function(e,t){var n;return(null===(n=e.find((function(e){return e.data===t})))||void 0===n?void 0:n.id)||null},ue=function(e,t){return e.getOptionLabel(t)},ce=function(e,t){return e.getOptionValue(t)};function le(e,t,n){return"function"==typeof e.isOptionDisabled&&e.isOptionDisabled(t,n)}function de(e,t,n){if(n.indexOf(t)>-1)return!0;if("function"==typeof e.isOptionSelected)return e.isOptionSelected(t,n);var r=ce(e,t);return n.some((function(t){return ce(e,t)===r}))}function pe(e,t,n){return!e.filterOption||e.filterOption(t,n)}var fe=function(e){var t=e.hideSelectedOptions,n=e.isMulti;return void 0===t?n:t},be=1,he=function(e){Object(s.a)(h,e);var t,n,b=(t=h,n=c(),function(){var e,r=Object(u.a)(t);if(n){var o=Object(u.a)(this).constructor;e=Reflect.construct(r,arguments,o)}else e=r.apply(this,arguments);return Object(l.a)(this,e)});function h(e){var t;if(Object(i.a)(this,h),(t=b.call(this,e)).state={ariaSelection:null,focusedOption:null,focusedOptionId:null,focusableOptionsWithIds:[],focusedValue:null,inputIsHidden:!1,isFocused:!1,selectValue:[],clearFocusValueOnUpdate:!1,prevWasFocused:!1,inputIsHiddenAfterUpdate:void 0,prevProps:void 0,instancePrefix:""},t.blockOptionHover=!1,t.isComposing=!1,t.commonProps=void 0,t.initialTouchX=0,t.initialTouchY=0,t.openAfterFocus=!1,t.scrollToFocusedOptionOnUpdate=!1,t.userIsDragging=void 0,t.isAppleDevice=q()||X(),t.controlRef=null,t.getControlRef=function(e){t.controlRef=e},t.focusedOptionRef=null,t.getFocusedOptionRef=function(e){t.focusedOptionRef=e},t.menuListRef=null,t.getMenuListRef=function(e){t.menuListRef=e},t.inputRef=null,t.getInputRef=function(e){t.inputRef=e},t.focus=t.focusInput,t.blur=t.blurInput,t.onChange=function(e,n){var r=t.props,o=r.onChange,i=r.name;n.name=i,t.ariaOnChange(e,n),o(e,n)},t.setValue=function(e,n,r){var o=t.props,i=o.closeMenuOnSelect,a=o.isMulti,s=o.inputValue;t.onInputChange("",{action:"set-value",prevInputValue:s}),i&&(t.setState({inputIsHiddenAfterUpdate:!a}),t.onMenuClose()),t.setState({clearFocusValueOnUpdate:!0}),t.onChange(e,{action:n,option:r})},t.selectOption=function(e){var n=t.props,r=n.blurInputOnSelect,o=n.isMulti,i=n.name,a=t.state.selectValue,s=o&&t.isOptionSelected(e,a),u=t.isOptionDisabled(e,a);if(s){var c=t.getOptionValue(e);t.setValue(Object(f.b)(a.filter((function(e){return t.getOptionValue(e)!==c}))),"deselect-option",e)}else{if(u)return void t.ariaOnChange(Object(f.c)(e),{action:"select-option",option:e,name:i});o?t.setValue(Object(f.b)([].concat(Object(d.a)(a),[e])),"select-option",e):t.setValue(Object(f.c)(e),"select-option")}r&&t.blurInput()},t.removeValue=function(e){var n=t.props.isMulti,r=t.state.selectValue,o=t.getOptionValue(e),i=r.filter((function(e){return t.getOptionValue(e)!==o})),a=Object(f.d)(n,i,i[0]||null);t.onChange(a,{action:"remove-value",removedValue:e}),t.focusInput()},t.clearValue=function(){var e=t.state.selectValue;t.onChange(Object(f.d)(t.props.isMulti,[],null),{action:"clear",removedValues:e})},t.popValue=function(){var e=t.props.isMulti,n=t.state.selectValue,r=n[n.length-1],o=n.slice(0,n.length-1),i=Object(f.d)(e,o,o[0]||null);r&&t.onChange(i,{action:"pop-value",removedValue:r})},t.getFocusedOptionId=function(e){return se(t.state.focusableOptionsWithIds,e)},t.getFocusableOptionsWithIds=function(){return ie(re(t.props,t.state.selectValue),t.getElementId("option"))},t.getValue=function(){return t.state.selectValue},t.cx=function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return f.e.apply(void 0,[t.props.classNamePrefix].concat(n))},t.getOptionLabel=function(e){return ue(t.props,e)},t.getOptionValue=function(e){return ce(t.props,e)},t.getStyles=function(e,n){var r=t.props.unstyled,o=Z[e](n,r);o.boxSizing="border-box";var i=t.props.styles[e];return i?i(o,n):o},t.getClassNames=function(e,n){var r,o;return null===(r=(o=t.props.classNames)[e])||void 0===r?void 0:r.call(o,n)},t.getElementId=function(e){return"".concat(t.state.instancePrefix,"-").concat(e)},t.getComponents=function(){return Object(f.f)(t.props)},t.buildCategorizedOptions=function(){return re(t.props,t.state.selectValue)},t.getCategorizedOptions=function(){return t.props.menuIsOpen?t.buildCategorizedOptions():[]},t.buildFocusableOptions=function(){return oe(t.buildCategorizedOptions())},t.getFocusableOptions=function(){return t.props.menuIsOpen?t.buildFocusableOptions():[]},t.ariaOnChange=function(e,n){t.setState({ariaSelection:Object(o.a)({value:e},n)})},t.onMenuMouseDown=function(e){0===e.button&&(e.stopPropagation(),e.preventDefault(),t.focusInput())},t.onMenuMouseMove=function(e){t.blockOptionHover=!1},t.onControlMouseDown=function(e){if(!e.defaultPrevented){var n=t.props.openMenuOnClick;t.state.isFocused?t.props.menuIsOpen?"INPUT"!==e.target.tagName&&"TEXTAREA"!==e.target.tagName&&t.onMenuClose():n&&t.openMenu("first"):(n&&(t.openAfterFocus=!0),t.focusInput()),"INPUT"!==e.target.tagName&&"TEXTAREA"!==e.target.tagName&&e.preventDefault()}},t.onDropdownIndicatorMouseDown=function(e){if(!(e&&"mousedown"===e.type&&0!==e.button||t.props.isDisabled)){var n=t.props,r=n.isMulti,o=n.menuIsOpen;t.focusInput(),o?(t.setState({inputIsHiddenAfterUpdate:!r}),t.onMenuClose()):t.openMenu("first"),e.preventDefault()}},t.onClearIndicatorMouseDown=function(e){e&&"mousedown"===e.type&&0!==e.button||(t.clearValue(),e.preventDefault(),t.openAfterFocus=!1,"touchend"===e.type?t.focusInput():setTimeout((function(){return t.focusInput()})))},t.onScroll=function(e){"boolean"==typeof t.props.closeMenuOnScroll?e.target instanceof HTMLElement&&Object(f.g)(e.target)&&t.props.onMenuClose():"function"==typeof t.props.closeMenuOnScroll&&t.props.closeMenuOnScroll(e)&&t.props.onMenuClose()},t.onCompositionStart=function(){t.isComposing=!0},t.onCompositionEnd=function(){t.isComposing=!1},t.onTouchStart=function(e){var n=e.touches,r=n&&n.item(0);r&&(t.initialTouchX=r.clientX,t.initialTouchY=r.clientY,t.userIsDragging=!1)},t.onTouchMove=function(e){var n=e.touches,r=n&&n.item(0);if(r){var o=Math.abs(r.clientX-t.initialTouchX),i=Math.abs(r.clientY-t.initialTouchY);t.userIsDragging=o>5||i>5}},t.onTouchEnd=function(e){t.userIsDragging||(t.controlRef&&!t.controlRef.contains(e.target)&&t.menuListRef&&!t.menuListRef.contains(e.target)&&t.blurInput(),t.initialTouchX=0,t.initialTouchY=0)},t.onControlTouchEnd=function(e){t.userIsDragging||t.onControlMouseDown(e)},t.onClearIndicatorTouchEnd=function(e){t.userIsDragging||t.onClearIndicatorMouseDown(e)},t.onDropdownIndicatorTouchEnd=function(e){t.userIsDragging||t.onDropdownIndicatorMouseDown(e)},t.handleInputChange=function(e){var n=t.props.inputValue,r=e.currentTarget.value;t.setState({inputIsHiddenAfterUpdate:!1}),t.onInputChange(r,{action:"input-change",prevInputValue:n}),t.props.menuIsOpen||t.onMenuOpen()},t.onInputFocus=function(e){t.props.onFocus&&t.props.onFocus(e),t.setState({inputIsHiddenAfterUpdate:!1,isFocused:!0}),(t.openAfterFocus||t.props.openMenuOnFocus)&&t.openMenu("first"),t.openAfterFocus=!1},t.onInputBlur=function(e){var n=t.props.inputValue;t.menuListRef&&t.menuListRef.contains(document.activeElement)?t.inputRef.focus():(t.props.onBlur&&t.props.onBlur(e),t.onInputChange("",{action:"input-blur",prevInputValue:n}),t.onMenuClose(),t.setState({focusedValue:null,isFocused:!1}))},t.onOptionHover=function(e){if(!t.blockOptionHover&&t.state.focusedOption!==e){var n=t.getFocusableOptions().indexOf(e);t.setState({focusedOption:e,focusedOptionId:n>-1?t.getFocusedOptionId(e):null})}},t.shouldHideSelectedOptions=function(){return fe(t.props)},t.onValueInputFocus=function(e){e.preventDefault(),e.stopPropagation(),t.focus()},t.onKeyDown=function(e){var n=t.props,r=n.isMulti,o=n.backspaceRemovesValue,i=n.escapeClearsValue,a=n.inputValue,s=n.isClearable,u=n.isDisabled,c=n.menuIsOpen,l=n.onKeyDown,d=n.tabSelectsValue,p=n.openMenuOnFocus,f=t.state,b=f.focusedOption,h=f.focusedValue,v=f.selectValue;if(!(u||"function"==typeof l&&(l(e),e.defaultPrevented))){switch(t.blockOptionHover=!0,e.key){case"ArrowLeft":if(!r||a)return;t.focusValue("previous");break;case"ArrowRight":if(!r||a)return;t.focusValue("next");break;case"Delete":case"Backspace":if(a)return;if(h)t.removeValue(h);else{if(!o)return;r?t.popValue():s&&t.clearValue()}break;case"Tab":if(t.isComposing)return;if(e.shiftKey||!c||!d||!b||p&&t.isOptionSelected(b,v))return;t.selectOption(b);break;case"Enter":if(229===e.keyCode)break;if(c){if(!b)return;if(t.isComposing)return;t.selectOption(b);break}return;case"Escape":c?(t.setState({inputIsHiddenAfterUpdate:!1}),t.onInputChange("",{action:"menu-close",prevInputValue:a}),t.onMenuClose()):s&&i&&t.clearValue();break;case" ":if(a)return;if(!c){t.openMenu("first");break}if(!b)return;t.selectOption(b);break;case"ArrowUp":c?t.focusOption("up"):t.openMenu("last");break;case"ArrowDown":c?t.focusOption("down"):t.openMenu("first");break;case"PageUp":if(!c)return;t.focusOption("pageup");break;case"PageDown":if(!c)return;t.focusOption("pagedown");break;case"Home":if(!c)return;t.focusOption("first");break;case"End":if(!c)return;t.focusOption("last");break;default:return}e.preventDefault()}},t.state.instancePrefix="react-select-"+(t.props.instanceId||++be),t.state.selectValue=Object(f.h)(e.value),e.menuIsOpen&&t.state.selectValue.length){var n=t.getFocusableOptionsWithIds(),r=t.buildFocusableOptions(),a=r.indexOf(t.state.selectValue[0]);t.state.focusableOptionsWithIds=n,t.state.focusedOption=r[a],t.state.focusedOptionId=se(n,r[a])}return t}return Object(a.a)(h,[{key:"componentDidMount",value:function(){this.startListeningComposition(),this.startListeningToTouch(),this.props.closeMenuOnScroll&&document&&document.addEventListener&&document.addEventListener("scroll",this.onScroll,!0),this.props.autoFocus&&this.focusInput(),this.props.menuIsOpen&&this.state.focusedOption&&this.menuListRef&&this.focusedOptionRef&&Object(f.i)(this.menuListRef,this.focusedOptionRef)}},{key:"componentDidUpdate",value:function(e){var t=this.props,n=t.isDisabled,r=t.menuIsOpen,o=this.state.isFocused;(o&&!n&&e.isDisabled||o&&r&&!e.menuIsOpen)&&this.focusInput(),o&&n&&!e.isDisabled?this.setState({isFocused:!1},this.onMenuClose):o||n||!e.isDisabled||this.inputRef!==document.activeElement||this.setState({isFocused:!0}),this.menuListRef&&this.focusedOptionRef&&this.scrollToFocusedOptionOnUpdate&&(Object(f.i)(this.menuListRef,this.focusedOptionRef),this.scrollToFocusedOptionOnUpdate=!1)}},{key:"componentWillUnmount",value:function(){this.stopListeningComposition(),this.stopListeningToTouch(),document.removeEventListener("scroll",this.onScroll,!0)}},{key:"onMenuOpen",value:function(){this.props.onMenuOpen()}},{key:"onMenuClose",value:function(){this.onInputChange("",{action:"menu-close",prevInputValue:this.props.inputValue}),this.props.onMenuClose()}},{key:"onInputChange",value:function(e,t){this.props.onInputChange(e,t)}},{key:"focusInput",value:function(){this.inputRef&&this.inputRef.focus()}},{key:"blurInput",value:function(){this.inputRef&&this.inputRef.blur()}},{key:"openMenu",value:function(e){var t=this,n=this.state,r=n.selectValue,o=n.isFocused,i=this.buildFocusableOptions(),a="first"===e?0:i.length-1;if(!this.props.isMulti){var s=i.indexOf(r[0]);s>-1&&(a=s)}this.scrollToFocusedOptionOnUpdate=!(o&&this.menuListRef),this.setState({inputIsHiddenAfterUpdate:!1,focusedValue:null,focusedOption:i[a],focusedOptionId:this.getFocusedOptionId(i[a])},(function(){return t.onMenuOpen()}))}},{key:"focusValue",value:function(e){var t=this.state,n=t.selectValue,r=t.focusedValue;if(this.props.isMulti){this.setState({focusedOption:null});var o=n.indexOf(r);r||(o=-1);var i=n.length-1,a=-1;if(n.length){switch(e){case"previous":a=0===o?0:-1===o?i:o-1;break;case"next":o>-1&&o<i&&(a=o+1)}this.setState({inputIsHidden:-1!==a,focusedValue:n[a]})}}}},{key:"focusOption",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"first",t=this.props.pageSize,n=this.state.focusedOption,r=this.getFocusableOptions();if(r.length){var o=0,i=r.indexOf(n);n||(i=-1),"up"===e?o=i>0?i-1:r.length-1:"down"===e?o=(i+1)%r.length:"pageup"===e?(o=i-t)<0&&(o=0):"pagedown"===e?(o=i+t)>r.length-1&&(o=r.length-1):"last"===e&&(o=r.length-1),this.scrollToFocusedOptionOnUpdate=!0,this.setState({focusedOption:r[o],focusedValue:null,focusedOptionId:this.getFocusedOptionId(r[o])})}}},{key:"getTheme",value:function(){return this.props.theme?"function"==typeof this.props.theme?this.props.theme(ee):Object(o.a)(Object(o.a)({},ee),this.props.theme):ee}},{key:"getCommonProps",value:function(){var e=this.clearValue,t=this.cx,n=this.getStyles,r=this.getClassNames,o=this.getValue,i=this.selectOption,a=this.setValue,s=this.props,u=s.isMulti,c=s.isRtl,l=s.options;return{clearValue:e,cx:t,getStyles:n,getClassNames:r,getValue:o,hasValue:this.hasValue(),isMulti:u,isRtl:c,options:l,selectOption:i,selectProps:s,setValue:a,theme:this.getTheme()}}},{key:"hasValue",value:function(){return this.state.selectValue.length>0}},{key:"hasOptions",value:function(){return!!this.getFocusableOptions().length}},{key:"isClearable",value:function(){var e=this.props,t=e.isClearable,n=e.isMulti;return void 0===t?n:t}},{key:"isOptionDisabled",value:function(e,t){return le(this.props,e,t)}},{key:"isOptionSelected",value:function(e,t){return de(this.props,e,t)}},{key:"filterOption",value:function(e,t){return pe(this.props,e,t)}},{key:"formatOptionLabel",value:function(e,t){if("function"==typeof this.props.formatOptionLabel){var n=this.props.inputValue,r=this.state.selectValue;return this.props.formatOptionLabel(e,{context:t,inputValue:n,selectValue:r})}return this.getOptionLabel(e)}},{key:"formatGroupLabel",value:function(e){return this.props.formatGroupLabel(e)}},{key:"startListeningComposition",value:function(){document&&document.addEventListener&&(document.addEventListener("compositionstart",this.onCompositionStart,!1),document.addEventListener("compositionend",this.onCompositionEnd,!1))}},{key:"stopListeningComposition",value:function(){document&&document.removeEventListener&&(document.removeEventListener("compositionstart",this.onCompositionStart),document.removeEventListener("compositionend",this.onCompositionEnd))}},{key:"startListeningToTouch",value:function(){document&&document.addEventListener&&(document.addEventListener("touchstart",this.onTouchStart,!1),document.addEventListener("touchmove",this.onTouchMove,!1),document.addEventListener("touchend",this.onTouchEnd,!1))}},{key:"stopListeningToTouch",value:function(){document&&document.removeEventListener&&(document.removeEventListener("touchstart",this.onTouchStart),document.removeEventListener("touchmove",this.onTouchMove),document.removeEventListener("touchend",this.onTouchEnd))}},{key:"renderInput",value:function(){var e=this.props,t=e.isDisabled,n=e.isSearchable,i=e.inputId,a=e.inputValue,s=e.tabIndex,u=e.form,c=e.menuIsOpen,l=e.required,d=this.getComponents().Input,b=this.state,h=b.inputIsHidden,v=b.ariaSelection,m=this.commonProps,g=i||this.getElementId("input"),O=Object(o.a)(Object(o.a)(Object(o.a)({"aria-autocomplete":"list","aria-expanded":c,"aria-haspopup":!0,"aria-errormessage":this.props["aria-errormessage"],"aria-invalid":this.props["aria-invalid"],"aria-label":this.props["aria-label"],"aria-labelledby":this.props["aria-labelledby"],"aria-required":l,role:"combobox","aria-activedescendant":this.isAppleDevice?void 0:this.state.focusedOptionId||""},c&&{"aria-controls":this.getElementId("listbox")}),!n&&{"aria-readonly":!0}),this.hasValue()?"initial-input-focus"===(null==v?void 0:v.action)&&{"aria-describedby":this.getElementId("live-region")}:{"aria-describedby":this.getElementId("placeholder")});return n?p.createElement(d,Object(r.a)({},m,{autoCapitalize:"none",autoComplete:"off",autoCorrect:"off",id:g,innerRef:this.getInputRef,isDisabled:t,isHidden:h,onBlur:this.onInputBlur,onChange:this.handleInputChange,onFocus:this.onInputFocus,spellCheck:"false",tabIndex:s,form:u,type:"text",value:a},O)):p.createElement(L,Object(r.a)({id:g,innerRef:this.getInputRef,onBlur:this.onInputBlur,onChange:f.j,onFocus:this.onInputFocus,disabled:t,tabIndex:s,inputMode:"none",form:u,value:""},O))}},{key:"renderPlaceholderOrValue",value:function(){var e=this,t=this.getComponents(),n=t.MultiValue,o=t.MultiValueContainer,i=t.MultiValueLabel,a=t.MultiValueRemove,s=t.SingleValue,u=t.Placeholder,c=this.commonProps,l=this.props,d=l.controlShouldRenderValue,f=l.isDisabled,b=l.isMulti,h=l.inputValue,v=l.placeholder,m=this.state,g=m.selectValue,O=m.focusedValue,y=m.isFocused;if(!this.hasValue()||!d)return h?null:p.createElement(u,Object(r.a)({},c,{key:"placeholder",isDisabled:f,isFocused:y,innerProps:{id:this.getElementId("placeholder")}}),v);if(b)return g.map((function(t,s){var u=t===O,l="".concat(e.getOptionLabel(t),"-").concat(e.getOptionValue(t));return p.createElement(n,Object(r.a)({},c,{components:{Container:o,Label:i,Remove:a},isFocused:u,isDisabled:f,key:l,index:s,removeProps:{onClick:function(){return e.removeValue(t)},onTouchEnd:function(){return e.removeValue(t)},onMouseDown:function(e){e.preventDefault()}},data:t}),e.formatOptionLabel(t,"value"))}));if(h)return null;var j=g[0];return p.createElement(s,Object(r.a)({},c,{data:j,isDisabled:f}),this.formatOptionLabel(j,"value"))}},{key:"renderClearIndicator",value:function(){var e=this.getComponents().ClearIndicator,t=this.commonProps,n=this.props,o=n.isDisabled,i=n.isLoading,a=this.state.isFocused;if(!this.isClearable()||!e||o||!this.hasValue()||i)return null;var s={onMouseDown:this.onClearIndicatorMouseDown,onTouchEnd:this.onClearIndicatorTouchEnd,"aria-hidden":"true"};return p.createElement(e,Object(r.a)({},t,{innerProps:s,isFocused:a}))}},{key:"renderLoadingIndicator",value:function(){var e=this.getComponents().LoadingIndicator,t=this.commonProps,n=this.props,o=n.isDisabled,i=n.isLoading,a=this.state.isFocused;if(!e||!i)return null;return p.createElement(e,Object(r.a)({},t,{innerProps:{"aria-hidden":"true"},isDisabled:o,isFocused:a}))}},{key:"renderIndicatorSeparator",value:function(){var e=this.getComponents(),t=e.DropdownIndicator,n=e.IndicatorSeparator;if(!t||!n)return null;var o=this.commonProps,i=this.props.isDisabled,a=this.state.isFocused;return p.createElement(n,Object(r.a)({},o,{isDisabled:i,isFocused:a}))}},{key:"renderDropdownIndicator",value:function(){var e=this.getComponents().DropdownIndicator;if(!e)return null;var t=this.commonProps,n=this.props.isDisabled,o=this.state.isFocused,i={onMouseDown:this.onDropdownIndicatorMouseDown,onTouchEnd:this.onDropdownIndicatorTouchEnd,"aria-hidden":"true"};return p.createElement(e,Object(r.a)({},t,{innerProps:i,isDisabled:n,isFocused:o}))}},{key:"renderMenu",value:function(){var e=this,t=this.getComponents(),n=t.Group,o=t.GroupHeading,i=t.Menu,a=t.MenuList,s=t.MenuPortal,u=t.LoadingMessage,c=t.NoOptionsMessage,l=t.Option,d=this.commonProps,b=this.state.focusedOption,h=this.props,v=h.captureMenuScroll,m=h.inputValue,g=h.isLoading,O=h.loadingMessage,y=h.minMenuHeight,j=h.maxMenuHeight,w=h.menuIsOpen,C=h.menuPlacement,x=h.menuPosition,I=h.menuPortalTarget,S=h.menuShouldBlockScroll,M=h.menuShouldScrollIntoView,E=h.noOptionsMessage,V=h.onMenuScrollToTop,k=h.onMenuScrollToBottom;if(!w)return null;var P,L=function(t,n){var o=t.type,i=t.data,a=t.isDisabled,s=t.isSelected,u=t.label,c=t.value,f=b===i,h=a?void 0:function(){return e.onOptionHover(i)},v=a?void 0:function(){return e.selectOption(i)},m="".concat(e.getElementId("option"),"-").concat(n),g={id:m,onClick:v,onMouseMove:h,onMouseOver:h,tabIndex:-1,role:"option","aria-selected":e.isAppleDevice?void 0:s};return p.createElement(l,Object(r.a)({},d,{innerProps:g,data:i,isDisabled:a,isSelected:s,key:m,label:u,type:o,value:c,isFocused:f,innerRef:f?e.getFocusedOptionRef:void 0}),e.formatOptionLabel(t.data,"menu"))};if(this.hasOptions())P=this.getCategorizedOptions().map((function(t){if("group"===t.type){var i=t.data,a=t.options,s=t.index,u="".concat(e.getElementId("group"),"-").concat(s),c="".concat(u,"-heading");return p.createElement(n,Object(r.a)({},d,{key:u,data:i,options:a,Heading:o,headingProps:{id:c,data:t.data},label:e.formatGroupLabel(t.data)}),t.options.map((function(e){return L(e,"".concat(s,"-").concat(e.index))})))}if("option"===t.type)return L(t,"".concat(t.index))}));else if(g){var R=O({inputValue:m});if(null===R)return null;P=p.createElement(u,d,R)}else{var D=E({inputValue:m});if(null===D)return null;P=p.createElement(c,d,D)}var F={minMenuHeight:y,maxMenuHeight:j,menuPlacement:C,menuPosition:x,menuShouldScrollIntoView:M},A=p.createElement(f.l,Object(r.a)({},d,F),(function(t){var n=t.ref,o=t.placerProps,s=o.placement,u=o.maxHeight;return p.createElement(i,Object(r.a)({},d,F,{innerRef:n,innerProps:{onMouseDown:e.onMenuMouseDown,onMouseMove:e.onMenuMouseMove},isLoading:g,placement:s}),p.createElement($,{captureEnabled:v,onTopArrive:V,onBottomArrive:k,lockEnabled:S},(function(t){return p.createElement(a,Object(r.a)({},d,{innerRef:function(n){e.getMenuListRef(n),t(n)},innerProps:{role:"listbox","aria-multiselectable":d.isMulti,id:e.getElementId("listbox")},isLoading:g,maxHeight:u,focusedOption:b}),P)})))}));return I||"fixed"===x?p.createElement(s,Object(r.a)({},d,{appendTo:I,controlElement:this.controlRef,menuPlacement:C,menuPosition:x}),A):A}},{key:"renderFormField",value:function(){var e=this,t=this.props,n=t.delimiter,r=t.isDisabled,o=t.isMulti,i=t.name,a=t.required,s=this.state.selectValue;if(a&&!this.hasValue()&&!r)return p.createElement(G,{name:i,onFocus:this.onValueInputFocus});if(i&&!r){if(o){if(n){var u=s.map((function(t){return e.getOptionValue(t)})).join(n);return p.createElement("input",{name:i,type:"hidden",value:u})}var c=s.length>0?s.map((function(t,n){return p.createElement("input",{key:"i-".concat(n),name:i,type:"hidden",value:e.getOptionValue(t)})})):p.createElement("input",{name:i,type:"hidden",value:""});return p.createElement("div",null,c)}var l=s[0]?this.getOptionValue(s[0]):"";return p.createElement("input",{name:i,type:"hidden",value:l})}}},{key:"renderLiveRegion",value:function(){var e=this.commonProps,t=this.state,n=t.ariaSelection,o=t.focusedOption,i=t.focusedValue,a=t.isFocused,s=t.selectValue,u=this.getFocusableOptions();return p.createElement(y,Object(r.a)({},e,{id:this.getElementId("live-region"),ariaSelection:n,focusedOption:o,focusedValue:i,isFocused:a,selectValue:s,focusableOptions:u,isAppleDevice:this.isAppleDevice}))}},{key:"render",value:function(){var e=this.getComponents(),t=e.Control,n=e.IndicatorsContainer,o=e.SelectContainer,i=e.ValueContainer,a=this.props,s=a.className,u=a.id,c=a.isDisabled,l=a.menuIsOpen,d=this.state.isFocused,f=this.commonProps=this.getCommonProps();return p.createElement(o,Object(r.a)({},f,{className:s,innerProps:{id:u,onKeyDown:this.onKeyDown},isDisabled:c,isFocused:d}),this.renderLiveRegion(),p.createElement(t,Object(r.a)({},f,{innerRef:this.getControlRef,innerProps:{onMouseDown:this.onControlMouseDown,onTouchEnd:this.onControlTouchEnd},isDisabled:c,isFocused:d,menuIsOpen:l}),p.createElement(i,Object(r.a)({},f,{isDisabled:c}),this.renderPlaceholderOrValue(),this.renderInput()),p.createElement(n,Object(r.a)({},f,{isDisabled:c}),this.renderClearIndicator(),this.renderLoadingIndicator(),this.renderIndicatorSeparator(),this.renderDropdownIndicator())),this.renderMenu(),this.renderFormField())}}],[{key:"getDerivedStateFromProps",value:function(e,t){var n=t.prevProps,r=t.clearFocusValueOnUpdate,i=t.inputIsHiddenAfterUpdate,a=t.ariaSelection,s=t.isFocused,u=t.prevWasFocused,c=t.instancePrefix,l=e.options,d=e.value,p=e.menuIsOpen,b=e.inputValue,h=e.isMulti,v=Object(f.h)(d),m={};if(n&&(d!==n.value||l!==n.options||p!==n.menuIsOpen||b!==n.inputValue)){var g=p?function(e,t){return oe(re(e,t))}(e,v):[],O=p?ie(re(e,v),"".concat(c,"-option")):[],y=r?function(e,t){var n=e.focusedValue,r=e.selectValue.indexOf(n);if(r>-1){if(t.indexOf(n)>-1)return n;if(r<t.length)return t[r]}return null}(t,v):null,j=function(e,t){var n=e.focusedOption;return n&&t.indexOf(n)>-1?n:t[0]}(t,g);m={selectValue:v,focusedOption:j,focusedOptionId:se(O,j),focusableOptionsWithIds:O,focusedValue:y,clearFocusValueOnUpdate:!1}}var w=null!=i&&e!==n?{inputIsHidden:i,inputIsHiddenAfterUpdate:void 0}:{},C=a,x=s&&u;return s&&!x&&(C={value:Object(f.d)(h,v,v[0]||null),options:v,action:"initial-input-focus"},x=!u),"initial-input-focus"===(null==a?void 0:a.action)&&(C=null),Object(o.a)(Object(o.a)(Object(o.a)({},m),w),{},{prevProps:e,ariaSelection:C,prevWasFocused:x})}}]),h}(p.Component);he.defaultProps=te},1581:function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(175);function o(e,t){if(null==e)return{};var n,o,i=Object(r.a)(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(o=0;o<a.length;o++)n=a[o],-1===t.indexOf(n)&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}},1583:function(e,t,n){"use strict";n.d(t,"a",(function(){return E})),n.d(t,"b",(function(){return A})),n.d(t,"c",(function(){return F})),n.d(t,"d",(function(){return D})),n.d(t,"e",(function(){return m})),n.d(t,"f",(function(){return Fe})),n.d(t,"g",(function(){return j})),n.d(t,"h",(function(){return g})),n.d(t,"i",(function(){return S})),n.d(t,"j",(function(){return h})),n.d(t,"k",(function(){return R})),n.d(t,"l",(function(){return W})),n.d(t,"m",(function(){return de})),n.d(t,"n",(function(){return Z})),n.d(t,"o",(function(){return De})),n.d(t,"p",(function(){return ve})),n.d(t,"q",(function(){return le})),n.d(t,"r",(function(){return ye})),n.d(t,"s",(function(){return Oe})),n.d(t,"t",(function(){return pe})),n.d(t,"u",(function(){return ee})),n.d(t,"v",(function(){return Ce})),n.d(t,"w",(function(){return K})),n.d(t,"x",(function(){return be})),n.d(t,"y",(function(){return _})),n.d(t,"z",(function(){return Y})),n.d(t,"A",(function(){return J})),n.d(t,"B",(function(){return Me})),n.d(t,"C",(function(){return Ee})),n.d(t,"D",(function(){return T})),n.d(t,"E",(function(){return L})),n.d(t,"F",(function(){return Ve})),n.d(t,"G",(function(){return X})),n.d(t,"H",(function(){return Pe})),n.d(t,"I",(function(){return Le})),n.d(t,"J",(function(){return Re})),n.d(t,"K",(function(){return Q})),n.d(t,"L",(function(){return M}));var r=n(374),o=n(154),i=n(1577),a=n(1629),s=n(1581),u=n(137);var c=n(314),l=n(0),d=n(119),p=n(1606),f=n(1600),b=["className","clearValue","cx","getStyles","getClassNames","getValue","hasValue","isMulti","isRtl","options","selectOption","selectProps","setValue","theme"],h=function(){};function v(e,t){return t?"-"===t[0]?e+t:e+"__"+t:e}function m(e,t){for(var n=arguments.length,r=new Array(n>2?n-2:0),o=2;o<n;o++)r[o-2]=arguments[o];var i=[].concat(r);if(t&&e)for(var a in t)t.hasOwnProperty(a)&&t[a]&&i.push("".concat(v(e,a)));return i.filter((function(e){return e})).map((function(e){return String(e).trim()})).join(" ")}var g=function(e){return t=e,Array.isArray(t)?e.filter(Boolean):"object"===Object(u.a)(e)&&null!==e?[e]:[];var t},O=function(e){e.className,e.clearValue,e.cx,e.getStyles,e.getClassNames,e.getValue,e.hasValue,e.isMulti,e.isRtl,e.options,e.selectOption,e.selectProps,e.setValue,e.theme;var t=Object(s.a)(e,b);return Object(r.a)({},t)},y=function(e,t,n){var r=e.cx,o=e.getStyles,i=e.getClassNames,a=e.className;return{css:o(t,e),className:r(null!=n?n:{},i(t,e),a)}};function j(e){return[document.documentElement,document.body,window].indexOf(e)>-1}function w(e){return j(e)?window.pageYOffset:e.scrollTop}function C(e,t){j(e)?window.scrollTo(0,t):e.scrollTop=t}function x(e,t,n,r){return n*((e=e/r-1)*e*e+1)+t}function I(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:200,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:h,o=w(e),i=t-o,a=10,s=0;function u(){var t=x(s+=a,o,i,n);C(e,t),s<n?window.requestAnimationFrame(u):r(e)}u()}function S(e,t){var n=e.getBoundingClientRect(),r=t.getBoundingClientRect(),o=t.offsetHeight/3;r.bottom+o>n.bottom?C(e,Math.min(t.offsetTop+t.clientHeight-e.offsetHeight+o,e.scrollHeight)):r.top-o<n.top&&C(e,Math.max(t.offsetTop-o,0))}function M(){try{return document.createEvent("TouchEvent"),!0}catch(e){return!1}}function E(){try{return/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)}catch(e){return!1}}var V=!1,k={get passive(){return V=!0}},P="undefined"!=typeof window?window:{};P.addEventListener&&P.removeEventListener&&(P.addEventListener("p",h,k),P.removeEventListener("p",h,!1));var L=V;function R(e){return null!=e}function D(e,t,n){return e?t:n}function F(e){return e}function A(e){return e}var T=function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];var o=Object.entries(e).filter((function(e){var t=Object(a.a)(e,1)[0];return!n.includes(t)}));return o.reduce((function(e,t){var n=Object(a.a)(t,2),r=n[0],o=n[1];return e[r]=o,e}),{})},H=["children","innerProps"],N=["children","innerProps"];function z(e){var t=e.maxHeight,n=e.menuEl,r=e.minHeight,o=e.placement,i=e.shouldScroll,a=e.isFixedPosition,s=e.controlHeight,u=function(e){var t=getComputedStyle(e),n="absolute"===t.position,r=/(auto|scroll)/;if("fixed"===t.position)return document.documentElement;for(var o=e;o=o.parentElement;)if(t=getComputedStyle(o),(!n||"static"!==t.position)&&r.test(t.overflow+t.overflowY+t.overflowX))return o;return document.documentElement}(n),c={placement:"bottom",maxHeight:t};if(!n||!n.offsetParent)return c;var l,d=u.getBoundingClientRect().height,p=n.getBoundingClientRect(),f=p.bottom,b=p.height,h=p.top,v=n.offsetParent.getBoundingClientRect().top,m=a?window.innerHeight:j(l=u)?window.innerHeight:l.clientHeight,g=w(u),O=parseInt(getComputedStyle(n).marginBottom,10),y=parseInt(getComputedStyle(n).marginTop,10),x=v-y,S=m-h,M=x+g,E=d-g-h,V=f-m+g+O,k=g+h-y;switch(o){case"auto":case"bottom":if(S>=b)return{placement:"bottom",maxHeight:t};if(E>=b&&!a)return i&&I(u,V,160),{placement:"bottom",maxHeight:t};if(!a&&E>=r||a&&S>=r)return i&&I(u,V,160),{placement:"bottom",maxHeight:a?S-O:E-O};if("auto"===o||a){var P=t,L=a?x:M;return L>=r&&(P=Math.min(L-O-s,t)),{placement:"top",maxHeight:P}}if("bottom"===o)return i&&C(u,V),{placement:"bottom",maxHeight:t};break;case"top":if(x>=b)return{placement:"top",maxHeight:t};if(M>=b&&!a)return i&&I(u,k,160),{placement:"top",maxHeight:t};if(!a&&M>=r||a&&x>=r){var R=t;return(!a&&M>=r||a&&x>=r)&&(R=a?x-y:M-y),i&&I(u,k,160),{placement:"top",maxHeight:R}}return{placement:"bottom",maxHeight:t};default:throw new Error('Invalid placement provided "'.concat(o,'".'))}return c}var U,B=function(e){return"auto"===e?"bottom":e},_=function(e,t){var n,o=e.placement,i=e.theme,a=i.borderRadius,s=i.spacing,u=i.colors;return Object(r.a)((n={label:"menu"},Object(c.a)(n,function(e){return e?{bottom:"top",top:"bottom"}[e]:"bottom"}(o),"100%"),Object(c.a)(n,"position","absolute"),Object(c.a)(n,"width","100%"),Object(c.a)(n,"zIndex",1),n),t?{}:{backgroundColor:u.neutral0,borderRadius:a,boxShadow:"0 0 0 1px hsla(0, 0%, 0%, 0.1), 0 4px 11px hsla(0, 0%, 0%, 0.1)",marginBottom:s.menuGutter,marginTop:s.menuGutter})},$=Object(l.createContext)(null),W=function(e){var t=e.children,n=e.minMenuHeight,o=e.maxMenuHeight,i=e.menuPlacement,s=e.menuPosition,u=e.menuShouldScrollIntoView,c=e.theme,d=(Object(l.useContext)($)||{}).setPortalPlacement,p=Object(l.useRef)(null),b=Object(l.useState)(o),h=Object(a.a)(b,2),v=h[0],m=h[1],g=Object(l.useState)(null),O=Object(a.a)(g,2),y=O[0],j=O[1],w=c.spacing.controlHeight;return Object(f.a)((function(){var e=p.current;if(e){var t="fixed"===s,r=z({maxHeight:o,menuEl:e,minHeight:n,placement:i,shouldScroll:u&&!t,isFixedPosition:t,controlHeight:w});m(r.maxHeight),j(r.placement),null==d||d(r.placement)}}),[o,i,s,u,n,d,w]),t({ref:p,placerProps:Object(r.a)(Object(r.a)({},e),{},{placement:y||B(i),maxHeight:v})})},G=function(e){var t=e.children,n=e.innerRef,r=e.innerProps;return Object(i.b)("div",Object(o.a)({},y(e,"menu",{menu:!0}),{ref:n},r),t)},Y=function(e,t){var n=e.maxHeight,o=e.theme.spacing.baseUnit;return Object(r.a)({maxHeight:n,overflowY:"auto",position:"relative",WebkitOverflowScrolling:"touch"},t?{}:{paddingBottom:o,paddingTop:o})},q=function(e,t){var n=e.theme,o=n.spacing.baseUnit,i=n.colors;return Object(r.a)({textAlign:"center"},t?{}:{color:i.neutral40,padding:"".concat(2*o,"px ").concat(3*o,"px")})},X=q,K=q,J=function(e){var t=e.rect,n=e.offset,r=e.position;return{left:t.left,position:r,top:n,width:t.wid