Profectus-Niffix/assets/vue-next-select.dc61a6b4.js

3 lines
24 KiB
JavaScript

import"./vue.a1abd053.js";import{aF as b,a1 as B,aL as x,a2 as y,bu as $,bv as I,O as P,aK as ye,ar as re,ab as De,aM as J,a0 as z,a9 as X,b7 as ge,$ as Ee,b9 as Le,bt as je,t as F,az as $e,aE as ze,am as he,G as K,J as Q,q as Ue,z as Z,b3 as S,_ as h,ag as Pe,b2 as j,as as _,aH as qe}from"./@vue.6f8187b0.js";function ie(e){return(ie=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(e)}function me(e){return function(t){if(Array.isArray(t))return ne(t)}(e)||function(t){if(typeof Symbol!="undefined"&&t[Symbol.iterator]!=null||t["@@iterator"]!=null)return Array.from(t)}(e)||be(e)||function(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function be(e,t){if(e){if(typeof e=="string")return ne(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set"?Array.from(e):n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?ne(e,t):void 0}}function ne(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,l=new Array(t);n<t;n++)l[n]=e[n];return l}function D(e,t){var n=typeof Symbol!="undefined"&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=be(e))||t&&e&&typeof e.length=="number"){n&&(e=n);var l=0,g=function(){};return{s:g,n:function(){return l>=e.length?{done:!0}:{done:!1,value:e[l++]}},e:function(s){throw s},f:g}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var m,u=!0,v=!1;return{s:function(){n=n.call(e)},n:function(){var s=n.next();return u=s.done,s},e:function(s){v=!0,m=s},f:function(){try{u||n.return==null||n.return()}finally{if(v)throw m}}}}var ae={inheritAttrs:!1,name:"vue-input",props:{autocomplete:{required:!1,type:String},modelValue:{required:!0,type:String},placeholder:{required:!0,type:String},disabled:{required:!0,type:Boolean},tabindex:{required:!0,type:Number},autofocus:{required:!0,type:Boolean},comboboxUid:{required:!0,type:Number}},emits:["update:modelValue","input","change","focus","blur","escape"],setup:function(e,t){var n=F(null);return $e(function(){e.autofocus&&n.value.focus()}),ze(function(){e.autofocus&&n.value.focus()}),{handleInput:function(l){t.emit("input",l),t.emit("update:modelValue",l.target.value)},handleChange:function(l){t.emit("change",l),t.emit("update:modelValue",l.target.value)},handleFocus:function(l){t.emit("focus",l)},handleBlur:function(l){t.emit("blur",l)},input:n,handleEscape:function(l){n.value.blur(),t.emit("escape",l)}}}},He={class:"vue-input"},_e=["autocomplete","modelValue","placeholder","disabled","tabindex","autofocus","aria-controls","aria-labelledby"];ae.render=function(e,t,n,l,g,m){return b(),B("div",He,[x(e.$slots,"prepend"),y("input",{ref:"input",autocomplete:n.autocomplete,modelValue:n.modelValue,placeholder:n.placeholder,disabled:n.disabled,onInput:t[0]||(t[0]=function(){return l.handleInput&&l.handleInput.apply(l,arguments)}),onChange:t[1]||(t[1]=function(){return l.handleChange&&l.handleChange.apply(l,arguments)}),onFocus:t[2]||(t[2]=function(){return l.handleFocus&&l.handleFocus.apply(l,arguments)}),onBlur:t[3]||(t[3]=function(){return l.handleBlur&&l.handleBlur.apply(l,arguments)}),onKeyup:t[4]||(t[4]=$(I(function(){return l.handleEscape&&l.handleEscape.apply(l,arguments)},["exact"]),["esc"])),tabindex:n.tabindex,autofocus:n.autofocus,"aria-autocomplete":"list","aria-controls":"vs".concat(n.comboboxUid,"-listbox"),"aria-labelledby":"vs".concat(n.comboboxUid,"-combobox")},null,40,_e),x(e.$slots,"append")])},ae.__file="src/components/input.vue";var le={inheritAttrs:!1,name:"vue-tags",props:{modelValue:{required:!0,type:Array,validator:function(e){return e.every(function(t){return ie(t.key)!==void 0&&t.label!==void 0&&typeof t.selected=="boolean"})}},collapseTags:{type:Boolean}},emits:["click"],setup:function(e,t){return{dataAttrs:he("dataAttrs"),handleClick:function(n){t.emit("click",n)}}}};le.render=function(e,t,n,l,g,m){return b(),B("ul",re({class:["vue-tags",{collapsed:n.collapseTags}],onMousedown:t[0]||(t[0]=I(function(){},["prevent"])),tabindex:"-1",onClick:t[1]||(t[1]=function(){return l.handleClick&&l.handleClick.apply(l,arguments)})},l.dataAttrs),[(b(!0),B(P,null,ye(n.modelValue,function(u){return b(),B(P,{key:u.key},[u.group?z("v-if",!0):(b(),B("li",{key:0,class:K(["vue-tag",{selected:u.selected}])},[x(e.$slots,"default",{option:u},function(){return[y("span",null,Q(u.label),1)]})],2))],64)}),128))],16)},le.__file="src/components/tags.vue";var oe={inheritAttrs:!1,name:"vue-dropdown",props:{modelValue:{required:!0,type:Array,validator:function(e){return e.every(function(t){return ie(t.key)!==void 0&&t.label!==void 0&&typeof t.selected=="boolean"})}},comboboxUid:{required:!0,type:Number},maxHeight:{required:!0},highlightedOriginalIndex:{required:!0}},emits:["click-item","mouseenter"],setup:function(e,t){return{dataAttrs:he("dataAttrs"),handleClickItem:function(n,l){l.disabled||t.emit("click-item",n,l)},handleMouseenter:function(n,l){t.emit("mouseenter",n,l)}}}},Re=["id","aria-multiselectable","aria-busy","aria-disabled"],We=["onClick","onMouseenter","id","aria-selected","aria-disabled"];oe.render=function(e,t,n,l,g,m){return b(),B("ul",re({class:"vue-dropdown",style:{maxHeight:n.maxHeight+"px"},onMousedown:t[0]||(t[0]=I(function(){},["prevent"]))},l.dataAttrs,{role:"listbox",id:"vs".concat(n.comboboxUid,"-listbox"),"aria-multiselectable":l.dataAttrs["data-multiple"],"aria-busy":l.dataAttrs["data-loading"],"aria-disabled":l.dataAttrs["data-disabled"]}),[(b(!0),B(P,null,ye(n.modelValue,function(u,v){return b(),B(P,{key:u.key},[u.visible&&u.hidden===!1?(b(),B("li",{key:0,onClick:function(s){return l.handleClickItem(s,u)},class:K(["vue-dropdown-item",{selected:u.selected,disabled:u.disabled,highlighted:u.originalIndex===n.highlightedOriginalIndex,group:u.group}]),onMouseenter:function(s){return l.handleMouseenter(s,u)},role:"option",id:"vs".concat(n.comboboxUid,"-option-").concat(v),"aria-selected":!!u.selected||!!u.disabled&&void 0,"aria-disabled":u.disabled},[x(e.$slots,"default",{option:u},function(){return[y("span",null,Q(u.label),1)]})],42,We)):z("v-if",!0)],64)}),128))],16,Re)},oe.__file="src/components/dropdown.vue";var Be=function(e,t,n){var l=n.valueBy;return l(e)===l(t)},U=function(e,t,n){var l=n.valueBy;return e.some(function(g){return Be(g,t,{valueBy:l})})},N=function(e,t,n){var l=n.valueBy;return e.find(function(g){return l(g)===t})},ee=function(e,t,n){var l=n.max,g=n.valueBy;return U(e,t,{valueBy:g})||e.length>=l?e:e.concat(t)},te=function(e,t,n){var l=n.min,g=n.valueBy;return U(e,t,{valueBy:g})===!1||e.length<=l?e:e.filter(function(m){return Be(m,t,{valueBy:g})===!1})},G=function(e){return h(function(){return typeof e.value=="function"?e.value:typeof e.value=="string"?function(t){return e.value.split(".").reduce(function(n,l){return n[l]},t)}:function(t){return t}})},Ze=function(e,t){var n=h(function(){return e.value.reduce(function(u,v){return Object.assign(u,(s={},c=v.originalIndex,f=v,c in s?Object.defineProperty(s,c,{value:f,enumerable:!0,configurable:!0,writable:!0}):s[c]=f,s));var s,c,f},{})}),l=function(u){var v=n.value[u];return v!==void 0&&g(v)!==!1&&(t.value=u,!0)},g=function(u){return!u.disabled&&!u.hidden&&u.visible},m=h(function(){return e.value.some(function(u){return g(u)})});return S(function(){if(m.value===!1&&(t.value=null),t.value!==null&&e.value.length<=t.value){var u,v=D(e.value.reverse());try{for(v.s();!(u=v.n()).done;){var s=u.value;if(l(s.originalIndex))break}}catch(V){v.e(V)}finally{v.f()}}if(t.value===null||g(e.value[t.value])===!1){var c,f=D(e.value);try{for(f.s();!(c=f.n()).done;){var E=c.value;if(l(E.originalIndex))break}}catch(V){f.e(V)}finally{f.f()}}}),{pointerForward:function(){if(m.value!==!1&&t.value!==null)for(var u=t.value+1,v=0;u!==t.value&&v++<e.value.length&&(e.value.length<=u&&(u=0),!l(u));)++u},pointerBackward:function(){if(m.value!==!1&&t.value!==null)for(var u=t.value-1,v=0;u!==t.value&&v++<e.value.length&&(u<0&&(u=e.value.length-1),!l(u));)--u},pointerSet:l}},ue=De({name:"vue-select",inheritAttrs:!1,props:{modelValue:{required:!0},emptyModelValue:{},options:{required:!0,type:Array},labelBy:{type:[String,Function]},valueBy:{type:[String,Function]},disabledBy:{default:"disabled",type:[String,Function]},groupBy:{default:"group",type:[String,Function]},visibleOptions:{type:Array,default:null},multiple:{default:!1,type:Boolean},min:{default:0,type:Number},max:{default:1/0,type:Number},searchable:{default:!1,type:Boolean},searchPlaceholder:{default:"Type to search",type:String},clearOnSelect:{default:!1,type:Boolean},clearOnClose:{default:!1,type:Boolean},taggable:{default:!1,type:Boolean},collapseTags:{default:!1,type:Boolean},autocomplete:{default:"off",type:String},disabled:{default:!1,type:Boolean},loading:{default:!1,type:Boolean},closeOnSelect:{default:!1,type:Boolean},hideSelected:{default:!1,type:Boolean},placeholder:{default:"Select option",type:String},tabindex:{default:0,type:Number},autofocus:{default:!1,type:Boolean},maxHeight:{default:300,type:Number},openDirection:{type:String,validator:function(e){return["top","bottom"].includes(e)}}},emits:["selected","removed","update:modelValue","focus","blur","toggle","opened","closed","search:input","search:change","search:focus","search:blur"],setup:function(e,t){var n=function(a){var o=Ue({}),i=G(Z(a,"labelBy"));S(function(){return o.labelBy=i.value});var r=G(Z(a,"valueBy"));S(function(){return o.valueBy=r.value});var M=G(Z(a,"disabledBy"));S(function(){return o.disabledBy=M.value});var p=G(Z(a,"groupBy"));S(function(){return o.groupBy=p.value});var k=h(function(){return a.multiple?a.min:Math.min(1,a.min)});S(function(){return o.min=k.value});var C=h(function(){return a.multiple?a.max:1});return S(function(){return o.max=C.value}),S(function(){return o.options=a.options}),o}(e),l=h(function(){var a;return(a=e.emptyModelValue)!==null&&a!==void 0?a:null}),g=Pe(),m=F(),u=F(),v=F(),s=h(function(){var a;return(a=v.value)===null||a===void 0?void 0:a._.refs.input}),c=F(!1);j(function(){return c.value},function(){var a,o;c.value?(t.emit("opened"),t.emit("focus"),e.searchable?(s.value!==document.activeElement&&s.value.focus(),t.emit("search:focus")):(a=m.value)===null||a===void 0||a.focus()):(e.searchable?(s.value===document.activeElement&&s.value.blur(),e.clearOnClose&&pe(),t.emit("search:blur")):(o=m.value)===null||o===void 0||o.blur(),t.emit("closed"),t.emit("blur")),t.emit("toggle")});var f=function(){e.disabled||(c.value=!0)},E=function(a){var o;!((o=m.value)===null||o===void 0)&&o.contains(a==null?void 0:a.relatedTarget)?setTimeout(function(){var i;(i=m.value)===null||i===void 0||i.focus()}):c.value=!1};j(function(){return e.disabled},function(){return E()});var V=F(""),Ie=h(function(){return new RegExp(V.value.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),"i")}),xe=h(function(){return V.value?n.options.filter(function(a){return Ie.value.test(n.labelBy(a))}):void 0}),d=F([]),A=h(function(){return new Set(d.value.map(function(a){return n.valueBy(a)}))}),ce=function(){if(e.multiple){if(Array.isArray(e.modelValue)===!1||d.value.length!==e.modelValue.length||Object.keys(d.value).some(function(a){return d.value[a]!==N(n.options,e.modelValue[a],{valueBy:n.valueBy})}))return!1}else if(d.value.length===0&&e.modelValue!==l.value||d.value.length===1&&e.modelValue===l.value||d.value[0]!==N(n.options,e.modelValue,{valueBy:n.valueBy}))return!1;return!0},de=function(){if(!ce()){d.value=[];var a,o=D(e.multiple?e.modelValue:e.modelValue===l.value?[]:[e.modelValue]);try{for(o.s();!(a=o.n()).done;){var i=a.value,r=N(n.options,i,{valueBy:n.valueBy});U(n.options,r,{valueBy:n.valueBy})!==!1&&(d.value=ee(d.value,r,{max:1/0,valueBy:n.valueBy}))}}catch(M){o.e(M)}finally{o.f()}}};de(),j(function(){return e.modelValue},function(){return de()},{deep:!0}),j(function(){return n.options},function(){d.value=n.options.filter(function(a){return A.value.has(n.valueBy(a))})},{deep:!0});var se,we=function(a,o){(o=o.originalOption).value.every(function(i){var r=N(n.options,i,{valueBy:n.valueBy});return U(d.value,r,{valueBy:n.valueBy})})?o.value.forEach(function(i){var r=N(n.options,i,{valueBy:n.valueBy});d.value=te(d.value,r,{min:n.min,valueBy:n.valueBy}),t.emit("removed",r)}):o.value.forEach(function(i){var r=N(n.options,i,{valueBy:n.valueBy});U(d.value,r,{valueBy:n.valueBy})||(d.value=ee(d.value,r,{max:n.max,valueBy:n.valueBy}),t.emit("selected",r))})},Me=function(a,o){if(o=o.originalOption,U(d.value,o,{valueBy:n.valueBy}))d.value=te(d.value,o,{min:n.min,valueBy:n.valueBy}),t.emit("removed",o);else{if(!e.multiple&&d.value.length===1){var i=d.value[0];d.value=te(d.value,d.value[0],{min:0,valueBy:n.valueBy}),t.emit("removed",i)}d.value=ee(d.value,o,{max:n.max,valueBy:n.valueBy}),t.emit("selected",o)}},ke=function(){if(!ce()){var a=d.value.map(function(o){return n.valueBy(o)});e.multiple?t.emit("update:modelValue",a):a.length?t.emit("update:modelValue",a[0]):t.emit("update:modelValue",l.value)}},pe=function(){s.value.value="",s.value.dispatchEvent(new Event("input")),s.value.dispatchEvent(new Event("change"))},Oe=h(function(){var a,o;return(o=(a=e.visibleOptions)!==null&&a!==void 0?a:xe.value)!==null&&o!==void 0?o:n.options}),R=F(0),w=h(function(){var a,o=new Set(Oe.value.map(function(p){return n.valueBy(p)})),i=n.options.map(function(p,k){var C,O={key:n.valueBy(p),label:n.labelBy(p),group:(C=n.groupBy(p))!==null&&C!==void 0&&C,originalIndex:k,originalOption:p};return O.selected=O.group?p.value.every(function(T){return A.value.has(T)}):A.value.has(n.valueBy(p)),O.disabled=O.group?n.disabledBy(p)||p.value.every(function(T){var Ne=N(n.options,T,{valueBy:n.valueBy});return n.disabledBy(Ne)}):n.disabledBy(p),O.visible=O.group?p.value.some(function(T){return o.has(T)}):o.has(n.valueBy(p)),O.hidden=!!e.hideSelected&&(O.group?p.value.every(function(T){return A.value.has(T)}):A.value.has(n.valueBy(p))),O}),r=D(i);try{for(r.s();!(a=r.n()).done;){var M=a.value;M.group!==!1&&M.disabled&&function(){var p=new Set(M.originalOption.value);i.filter(function(k){return p.has(n.valueBy(k.originalOption))}).forEach(function(k){return k.disabled=!0})}()}}catch(p){r.e(p)}finally{r.f()}return i}),Y=Ze(w,R),Fe=Y.pointerForward,Ve=Y.pointerBackward,q=Y.pointerSet,W="",Se=/^[\w]$/,Ae=h(function(){var a=me(n.options.keys());return a.slice(R.value).concat(a.slice(0,R.value))}),H=function(){var a,o=(a=m.value)===null||a===void 0?void 0:a.querySelector(".highlighted");if(o&&u.value){var i,r=getComputedStyle(o);for(i=0;o.offsetTop+parseFloat(r.height)+parseFloat(r.paddingTop)+parseFloat(r.paddingBottom)>u.value.$el.clientHeight+u.value.$el.scrollTop&&i++<w.value.length;)u.value.$el.scrollTop=u.value.$el.scrollTop+parseFloat(r.height)+parseFloat(r.paddingTop)+parseFloat(r.paddingBottom);for(i=0;o.offsetTop<u.value.$el.scrollTop&&i++<w.value.length;)u.value.$el.scrollTop=u.value.$el.scrollTop-parseFloat(r.height)-parseFloat(r.paddingTop)-parseFloat(r.paddingBottom)}};j(function(){return[c.value,n.options,A.value]},function(a,o){(o==null?void 0:o[0])!==!0&&c.value!==!1&&d.value.length!==0&&(q(n.options.findIndex(function(i){return A.value.has(n.valueBy(i))})),_(H))},{deep:!0,immediate:!0});var ve=h(function(){return{"data-is-focusing":c.value,"data-visible-length":w.value.filter(function(a){return a.visible&&a.hidden===!1}).length,"data-not-selected-length":n.options.length-w.value.filter(function(a){return a.selected}).length,"data-selected-length":w.value.filter(function(a){return a.selected}).length,"data-addable":w.value.filter(function(a){return a.selected}).length<n.max,"data-removable":w.value.filter(function(a){return a.selected}).length>n.min,"data-total-length":n.options.length,"data-multiple":e.multiple,"data-loading":e.loading,"data-disabled":e.disabled}});qe("dataAttrs",ve);var L=h(function(){return w.value.filter(function(a){return a.selected}).filter(function(a){return!a.group})}),Ce=h(function(){return e.multiple?L.value.length===0?e.placeholder:L.value.length===1?"1 option selected":L.value.length+" options selected":L.value.length===0?e.placeholder:L.value[0].label+""}),Te=h(function(){var a=L.value.map(function(o){return o.originalOption});return e.multiple?a:a[0]||l.value}),fe=F();return j(function(){return[e.openDirection,c.value]},function(){var a,o;fe.value=(o=(a=e.openDirection)!==null&&a!==void 0?a:function(){if(m.value!==void 0&&window!==void 0)return window.innerHeight-m.value.getBoundingClientRect().bottom>=e.maxHeight?"bottom":"top"}())!==null&&o!==void 0?o:"bottom"},{immediate:!0}),{instance:g,isFocusing:c,wrapper:m,dropdown:u,input:v,focus:f,blur:E,toggle:function(){c.value?E():f()},searchingInputValue:V,handleInputForInput:function(a){t.emit("search:input",a)},handleChangeForInput:function(a){t.emit("search:change",a)},handleFocusForInput:function(a){f()},handleBlurForInput:function(a){E()},optionsWithInfo:w,addOrRemoveOption:function(a,o){e.disabled||(o.group&&e.multiple?we(a,o):Me(a,o),ke(),e.closeOnSelect===!0&&(c.value=!1),e.clearOnSelect===!0&&V.value&&pe())},dataAttrs:ve,innerPlaceholder:Ce,selected:Te,highlightedOriginalIndex:R,pointerForward:function(){Fe(),_(H)},pointerBackward:function(){Ve(),_(H)},pointerFirst:function(){var a,o=D(n.options.keys());try{for(o.s();!(a=o.n()).done;){var i=a.value;if(q(i))break}}catch(r){o.e(r)}finally{o.f()}_(H)},pointerLast:function(){var a,o=D(me(n.options.keys()).reverse());try{for(o.s();!(a=o.n()).done;){var i=a.value;if(q(i))break}}catch(r){o.e(r)}finally{o.f()}_(H)},typeAhead:function(a){var o,i;if(!e.searchable){var r=!1;if(Se.test(a.key)?(W+=a.key.toLowerCase(),r=!0):a.code==="Space"&&(W+=" "),r){var M,p=D(Ae.value);try{for(p.s();!(M=p.n()).done;){var k=M.value;if(((i=(o=n.labelBy(n.options[k]))===null||o===void 0?void 0:o.toLowerCase())===null||i===void 0?void 0:i.startsWith(W))===!0&&q(k))break}}catch(C){p.e(C)}finally{p.f()}clearTimeout(se),se=setTimeout(function(){W=""},500)}}},pointerSet:q,direction:fe}},components:{VInput:ae,VTags:le,VDropdown:oe}});ue.__VERSION__="2.10.5";var Ge=["tabindex","id","role","aria-expanded","aria-owns","aria-activedescendant","aria-busy","aria-disabled"],Ke={class:"vue-select-header"},Qe={key:0,class:"vue-input"},Ye=["placeholder","autocomplete"],Je=["onClick"],Xe=y("span",{class:"icon loading"},[y("div"),y("div"),y("div")],-1),et={key:0,class:"vue-select-input-wrapper"},tt=y("span",{class:"icon loading"},[y("div"),y("div"),y("div")],-1);ue.render=function(e,t,n,l,g,m){var u=J("v-tags"),v=J("v-input"),s=J("v-dropdown");return b(),B("div",re({ref:"wrapper",class:["vue-select",["direction-".concat(e.direction)]],tabindex:e.isFocusing?-1:e.tabindex,onFocus:t[9]||(t[9]=function(){return e.focus&&e.focus.apply(e,arguments)}),onBlur:t[10]||(t[10]=function(c){return!e.searchable&&e.blur(c)})},Object.assign({},e.dataAttrs,e.$attrs),{onKeypress:t[11]||(t[11]=$(I(function(){return e.highlightedOriginalIndex!==null&&e.addOrRemoveOption(e.$event,e.optionsWithInfo[e.highlightedOriginalIndex])},["prevent","exact"]),["enter"])),onKeydown:[t[12]||(t[12]=$(I(function(){return e.pointerForward&&e.pointerForward.apply(e,arguments)},["prevent","exact"]),["down"])),t[13]||(t[13]=$(I(function(){return e.pointerBackward&&e.pointerBackward.apply(e,arguments)},["prevent","exact"]),["up"])),t[14]||(t[14]=$(I(function(){return e.pointerFirst&&e.pointerFirst.apply(e,arguments)},["prevent","exact"]),["home"])),t[15]||(t[15]=$(I(function(){return e.pointerLast&&e.pointerLast.apply(e,arguments)},["prevent","exact"]),["end"])),t[16]||(t[16]=function(){return e.typeAhead&&e.typeAhead.apply(e,arguments)})],id:"vs".concat(e.instance.uid,"-combobox"),role:e.searchable?"combobox":null,"aria-expanded":e.isFocusing,"aria-haspopup":"listbox","aria-owns":"vs".concat(e.instance.uid,"-listbox"),"aria-activedescendant":e.highlightedOriginalIndex===null?null:"vs".concat(e.instance.uid,"-option-").concat(e.highlightedOriginalIndex),"aria-busy":e.loading,"aria-disabled":e.disabled}),[y("div",Ke,[e.multiple&&e.taggable&&e.modelValue.length===0||e.searchable===!1&&e.taggable===!1?(b(),B("div",Qe,[x(e.$slots,"label",{selected:e.selected},function(){return[y("input",{placeholder:e.innerPlaceholder,autocomplete:e.autocomplete,readonly:"",onClick:t[0]||(t[0]=function(){return e.focus&&e.focus.apply(e,arguments)})},null,8,Ye)]})])):z("v-if",!0),e.multiple&&e.taggable?(b(),B(P,{key:1},[X(u,{modelValue:e.optionsWithInfo,"collapse-tags":e.collapseTags,tabindex:"-1",onClick:e.focus},{default:ge(function(c){var f=c.option;return[x(e.$slots,"tag",{option:f.originalOption,remove:function(){return e.addOrRemoveOption(e.$event,f)}},function(){return[y("span",null,Q(f.label),1),y("img",{src:"data:image/svg+xml;base64,PHN2ZyBpZD0iZGVsZXRlIiBkYXRhLW5hbWU9ImRlbGV0ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgNTEyIDUxMiI+PHRpdGxlPmRlbGV0ZTwvdGl0bGU+PHBhdGggZD0iTTI1NiwyNEMzODMuOSwyNCw0ODgsMTI4LjEsNDg4LDI1NlMzODMuOSw0ODgsMjU2LDQ4OCwyNC4wNiwzODMuOSwyNC4wNiwyNTYsMTI4LjEsMjQsMjU2LDI0Wk0wLDI1NkMwLDM5Ny4xNiwxMTQuODQsNTEyLDI1Niw1MTJTNTEyLDM5Ny4xNiw1MTIsMjU2LDM5Ny4xNiwwLDI1NiwwLDAsMTE0Ljg0LDAsMjU2WiIgZmlsbD0iIzViNWI1ZiIvPjxwb2x5Z29uIHBvaW50cz0iMzgyIDE3Mi43MiAzMzkuMjkgMTMwLjAxIDI1NiAyMTMuMjkgMTcyLjcyIDEzMC4wMSAxMzAuMDEgMTcyLjcyIDIxMy4yOSAyNTYgMTMwLjAxIDMzOS4yOCAxNzIuNzIgMzgyIDI1NiAyOTguNzEgMzM5LjI5IDM4MS45OSAzODIgMzM5LjI4IDI5OC43MSAyNTYgMzgyIDE3Mi43MiIgZmlsbD0iIzViNWI1ZiIvPjwvc3ZnPg==",alt:"delete tag",class:"icon delete",onClick:I(function(){return e.addOrRemoveOption(e.$event,f)},["prevent","stop"])},null,8,Je)]})]}),_:3},8,["modelValue","collapse-tags","onClick"]),x(e.$slots,"toggle",{isFocusing:e.isFocusing,toggle:e.toggle},function(){return[y("span",{class:K(["icon arrow-downward",{active:e.isFocusing}]),onClick:t[1]||(t[1]=function(){return e.toggle&&e.toggle.apply(e,arguments)}),onMousedown:t[2]||(t[2]=I(function(){},["prevent","stop"]))},null,34)]})],64)):(b(),B(P,{key:2},[e.searchable?(b(),Ee(v,{key:0,ref:"input",modelValue:e.searchingInputValue,"onUpdate:modelValue":t[3]||(t[3]=function(c){return e.searchingInputValue=c}),disabled:e.disabled,autocomplete:e.autocomplete,placeholder:e.isFocusing?e.searchPlaceholder:e.innerPlaceholder,onInput:e.handleInputForInput,onChange:e.handleChangeForInput,onFocus:e.handleFocusForInput,onBlur:e.handleBlurForInput,onEscape:e.blur,autofocus:e.autofocus||e.taggable&&e.searchable,tabindex:e.tabindex,comboboxUid:e.instance.uid},null,8,["modelValue","disabled","autocomplete","placeholder","onInput","onChange","onFocus","onBlur","onEscape","autofocus","tabindex","comboboxUid"])):z("v-if",!0),e.loading?x(e.$slots,"loading",{key:1},function(){return[Xe]}):x(e.$slots,"toggle",{key:2,isFocusing:e.isFocusing,toggle:e.toggle},function(){return[y("span",{class:K(["icon arrow-downward",{active:e.isFocusing}]),onClick:t[4]||(t[4]=function(){return e.toggle&&e.toggle.apply(e,arguments)}),onMousedown:t[5]||(t[5]=I(function(){},["prevent","stop"]))},null,34)]})],64))]),e.multiple&&e.taggable&&e.searchable?(b(),B("div",et,[Le(X(v,{ref:"input",modelValue:e.searchingInputValue,"onUpdate:modelValue":t[6]||(t[6]=function(c){return e.searchingInputValue=c}),disabled:e.disabled,autocomplete:e.autocomplete,placeholder:e.isFocusing?e.searchPlaceholder:e.innerPlaceholder,onInput:e.handleInputForInput,onChange:e.handleChangeForInput,onFocus:e.handleFocusForInput,onBlur:e.handleBlurForInput,onEscape:e.blur,autofocus:e.autofocus||e.taggable&&e.searchable,tabindex:e.tabindex,comboboxUid:e.instance.uid},null,8,["modelValue","disabled","autocomplete","placeholder","onInput","onChange","onFocus","onBlur","onEscape","autofocus","tabindex","comboboxUid"]),[[je,e.isFocusing]]),e.loading?x(e.$slots,"loading",{key:0},function(){return[tt]}):z("v-if",!0)])):z("v-if",!0),X(s,{ref:"dropdown",modelValue:e.optionsWithInfo,"onUpdate:modelValue":t[7]||(t[7]=function(c){return e.optionsWithInfo=c}),onClickItem:e.addOrRemoveOption,onMouseenter:t[8]||(t[8]=function(c,f){return e.pointerSet(f.originalIndex)}),comboboxUid:e.instance.uid,maxHeight:e.maxHeight,highlightedOriginalIndex:e.highlightedOriginalIndex},{default:ge(function(c){var f=c.option;return[x(e.$slots,"dropdown-item",{option:f.originalOption},function(){return[y("span",null,Q(f.label),1)]})]}),_:3},8,["modelValue","onClickItem","comboboxUid","maxHeight","highlightedOriginalIndex"])],16,Ge)},ue.__file="src/index.vue";export{ue as Y};