@webitel/ui-sdk 25.8.19 → 25.8.20

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -3141,7 +3141,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
3141
3141
  width: `).concat(this.breakpoints[r],` !important;
3142
3142
  }
3143
3143
  }
3144
- `);this.styleElement.innerHTML=a}},destroyStyle:function(){this.styleElement&&(document.head.removeChild(this.styleElement),this.styleElement=null)},onOverlayClick:function(i){qa.emit("overlay-click",{originalEvent:i,target:this.target})}},directives:{focustrap:yM,ripple:V0},components:{Portal:$0}},FM=["aria-modal"];function VM(o,i,a,r,s,c){var p=l.resolveComponent("Portal"),f=l.resolveDirective("focustrap");return l.openBlock(),l.createBlock(p,{appendTo:o.appendTo},{default:l.withCtx(function(){return[l.createVNode(l.Transition,l.mergeProps({name:"p-popover",onEnter:c.onEnter,onLeave:c.onLeave,onAfterLeave:c.onAfterLeave},o.ptm("transition")),{default:l.withCtx(function(){return[s.visible?l.withDirectives((l.openBlock(),l.createElementBlock("div",l.mergeProps({key:0,ref:c.containerRef,role:"dialog","aria-modal":s.visible,onClick:i[3]||(i[3]=function(){return c.onOverlayClick&&c.onOverlayClick.apply(c,arguments)}),class:o.cx("root")},o.ptmi("root")),[o.$slots.container?l.renderSlot(o.$slots,"container",{key:0,closeCallback:c.hide,keydownCallback:function(b){return c.onButtonKeydown(b)}}):(l.openBlock(),l.createElementBlock("div",l.mergeProps({key:1,class:o.cx("content"),onClick:i[0]||(i[0]=function(){return c.onContentClick&&c.onContentClick.apply(c,arguments)}),onMousedown:i[1]||(i[1]=function(){return c.onContentClick&&c.onContentClick.apply(c,arguments)}),onKeydown:i[2]||(i[2]=function(){return c.onContentKeydown&&c.onContentKeydown.apply(c,arguments)})},o.ptm("content")),[l.renderSlot(o.$slots,"default")],16))],16,FM)),[[f]]):l.createCommentVNode("",!0)]}),_:3},16,["onEnter","onLeave","onAfterLeave"])]}),_:3},8,["appendTo"])}U0.render=VM;const UM=l.defineComponent({__name:"wt-popover",props:{dismissable:{type:Boolean},appendTo:{default:"body"},baseZIndex:{default:0},autoZIndex:{type:Boolean,default:!0},breakpoints:{default:null},dt:{default:null},pt:{default:null},ptOptions:{default:null},unstyled:{type:Boolean},closeOnEscape:{type:Boolean,default:!0}},emits:["show","hide"],setup(o,{expose:i}){const a=l.useAttrs(),r=l.useTemplateRef("innerPopover");return i({toggle:(...s)=>{var c,p;return(p=(c=r.value)==null?void 0:c.toggle)==null?void 0:p.call(c,...s)},show:(...s)=>{var c,p;return(p=(c=r.value)==null?void 0:c.show)==null?void 0:p.call(c,...s)},hide:(...s)=>{var c,p;return(p=(c=r.value)==null?void 0:c.hide)==null?void 0:p.call(c,...s)}}),(s,c)=>(l.openBlock(),l.createBlock(l.unref(U0),l.mergeProps(l.unref(a),{ref_key:"innerPopover",ref:r},{"append-to":s.appendTo,"base-z-index":s.baseZIndex,"auto-z-index":s.autoZIndex,breakpoints:s.breakpoints,dt:s.dt,pt:s.pt,"pt-options":s.ptOptions,"close-on-escape":s.closeOnEscape},l.toHandlers(l.unref(a))),{default:l.withCtx(()=>[l.renderSlot(s.$slots,"default")],void 0,!0),_:3},16,["append-to","base-z-index","auto-z-index","breakpoints","dt","pt","pt-options","close-on-escape"]))}});var zM=o=>Object.prototype.toString.call(o).includes("Object"),T4=o=>typeof o=="number"&&!isNaN(o),HM=o=>Array.isArray(o),E4=o=>Object.prototype.toString.call(o)==="[object String]",z0=o=>Number.isInteger(o);const Il=(o,i)=>i(o)?!0:!zM(o)||Object.keys(o).length!==2?!1:!Object.entries(o).some(([a,r])=>{const s=!["enter","leave"].includes(a),c=!i(r);return s||c}),WM=o=>Il(o,i=>z0(i)&&i>=0),ZM=o=>Il(o,i=>E4(i)&&i.trim()!==""),YM=o=>Il(o,i=>z0(i)&&i>=0),D4=300,KM="cubic-bezier(.25, .8, .5, 1)",GM=0,XM=[0,-16],QM={inheritAttrs:!1,props:{duration:{validator:WM,default:D4},easing:{validator:ZM,default:()=>KM},delay:{validator:YM,default:GM},noOpacity:{type:Boolean,default:!1},appear:{type:Boolean,default:!1},mode:{type:String,default:void 0},group:{type:Boolean,default:!1},tag:{type:String,default:"span"},noMove:{type:Boolean,default:!1},moveDuration:{type:Number,default:D4}},computed:{cComponent(){return this.group?l.TransitionGroup:l.Transition},cAttrs(){const{appear:o,mode:i,tag:a,duration:r}=this;return this.group?{appear:o,tag:a,duration:r,...this.$attrs}:{appear:o,mode:i,duration:r}},cHooks(){return{beforeEnter:(...o)=>{this.reduceTransition(...o),this.$emit("before-enter",...o)},beforeLeave:(...o)=>{var i;this.reduceTransition(...o),(i=this.initLeaving)==null||i.call(this,...o),this.$emit("before-leave",...o)},enter:(...o)=>{var i;(i=this.onEnter)==null||i.call(this,...o),this.$emit("enter",...o)},leave:(...o)=>{var i;(i=this.onLeave)==null||i.call(this,...o),this.$emit("leave",...o)},afterEnter:(...o)=>{var i;this.resetTransition(...o),(i=this.resetElement)==null||i.call(this,...o),this.$emit("after-enter",...o)},afterLeave:(...o)=>{var i;this.resetTransition(...o),(i=this.resetElement)==null||i.call(this,...o),this.$emit("after-leave",...o)}}}},methods:{setupTransition(o,i="enter"){var a,r,s;const c=((a=this.duration)==null?void 0:a[i])??this.duration,p=((r=this.easing)==null?void 0:r[i])??this.easing,f=((s=this.delay)==null?void 0:s[i])??this.delay;o.style.setProperty("transition-duration",`${c}ms`,"important"),o.style.setProperty("transition-timing-function",`${p}`,"important"),o.style.setProperty("transition-delay",`${f}ms`,"important")},reduceTransition(o){o.style.setProperty("transition-duration","0ms","important"),o.style.setProperty("transition-delay","0ms","important")},resetTransition(o){o.style.removeProperty("transition-duration"),o.style.removeProperty("transition-timing-function"),o.style.removeProperty("transition-delay")},initLeaving(o){if(!this.group||this.noMove)return o;const i=getComputedStyle(o),{width:a,height:r}=i,{marginLeft:s,marginTop:c}=i;return o.style.setProperty("left",`${o.offsetLeft-parseFloat(s)}px`,"important"),o.style.setProperty("top",`${o.offsetTop-parseFloat(c)}px`,"important"),o.style.setProperty("width",`${parseFloat(a)}px`,"important"),o.style.setProperty("height",`${parseFloat(r)}px`,"important"),o.style.setProperty("position","absolute","important"),o},setMoveDuration(){var o;this.group&&this.$el&&((o=this.$el.style)==null||o.setProperty("--move-duration",`${this.moveDuration}ms`))}},watch:{moveDuration(){this.setMoveDuration()},group(){this.setMoveDuration()}},mounted(){this.setMoveDuration()}},JM=(o,i)=>{const a=o.__vccOpts||o;for(const[r,s]of i)a[r]=s;return a},e$=o=>{const i=o.startsWith("matrix3d")?"matrix3d":"matrix",a=i==="matrix3d"?o.slice(9,-1).split(",").map(Number):o.startsWith("matrix")?o.slice(7,-1).split(",").map(Number):[1,0,0,1,0,0];return[i,a]},t$={name:"transition-slide",mixins:[QM],props:{offset:{validator:o=>Il(o,i=>!HM(i)||i.length!==2?!1:!i.some(a=>z0(a)?!1:E4(a)?isNaN(Number(a.endsWith("%")?a.slice(0,-1):a)):!0)),default:()=>XM}},data:()=>({}),computed:{},methods:{onEnter(o){this.slideElement(o,"enter"),o.offsetTop,this.setupTransition(o,"enter"),o.style.removeProperty("opacity"),o.style.removeProperty("transform")},onLeave(o){this.setupTransition(o,"leave"),this.slideElement(o,"leave")},slideElement(o,i="enter"){var a;const{width:r,height:s,transform:c}=getComputedStyle(o),p=((a=this.offset)==null?void 0:a[i])??this.offset;let[f,h]=p;T4(f)||(f=f.endsWith("%")?parseFloat(r)*(parseFloat(f.slice(0,-1))||0)/100:parseFloat(f)),T4(h)||(h=h.endsWith("%")?parseFloat(s)*(parseFloat(h.slice(0,-1))||0)/100:parseFloat(h));const[b,g]=e$(c);c.startsWith("matrix3d")?(g[12]+=f,g[13]+=h):c.startsWith("matrix")?(g[4]+=f,g[5]+=h):(g[4]=f,g[5]=h),this.noOpacity||o.style.setProperty("opacity",0),o.style.setProperty("transform",`${b}(${g})`)},resetElement(o){o.style.removeProperty("opacity"),o.style.removeProperty("transform")}}};function o$(o,i,a,r,s,c){return l.openBlock(),l.createBlock(l.resolveDynamicComponent(o.cComponent),l.mergeProps({name:"slide"},o.cAttrs,l.toHandlers(o.cHooks)),{default:l.withCtx(()=>[l.renderSlot(o.$slots,"default")]),_:3},16)}const i$=JM(t$,[["render",o$]]),n$={key:0,class:"wt-popup__popup"},a$={class:"wt-popup__header"},r$={class:"wt-popup__title"},l$={key:0,class:"wt-popup__main"},s$={key:1,class:"wt-popup__actions"},c$=l.defineComponent({__name:"wt-popup",props:{shown:{type:Boolean,default:!0},size:{default:$t.MD},overflow:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1}},emits:["close","popup:opened","popup:closed"],setup(o,{emit:i}){const a=o,r=i,c=!!l.useSlots().activator,p=l.ref(a.shown),f=l.ref(!1),h=()=>{p.value=!0},b=()=>{f.value=!0,p.value=!1,setTimeout(()=>{f.value=!1},200)},g=l.computed(()=>p.value||f.value);return l.watch(()=>a.shown,w=>{c||(w?h():b())}),l.watch(p,w=>{r(w?"popup:opened":"popup:closed")}),(w,y)=>{const C=l.resolveComponent("wt-icon-btn");return l.withDirectives((l.openBlock(),l.createElementBlock("div",{class:l.normalizeClass([[`wt-popup--size-${w.size}`,{"wt-popup--overflow":w.overflow}],"wt-popup"])},[l.createVNode(l.unref(i$),{offset:[0,-1440/2]},{default:l.withCtx(()=>[p.value?(l.openBlock(),l.createElementBlock("aside",n$,[l.createElementVNode("header",a$,[l.renderSlot(w.$slots,"header",{},()=>[l.createElementVNode("h3",r$,[l.renderSlot(w.$slots,"title",{},void 0,!0)])],!0),l.createVNode(C,{class:"wt-popup__close-btn",icon:"close",onClick:y[0]||(y[0]=A=>r("close"))})]),w.$slots.main?(l.openBlock(),l.createElementBlock("section",l$,[l.renderSlot(w.$slots,"main",{},void 0,!0)])):l.createCommentVNode("",!0),w.$slots.actions?(l.openBlock(),l.createElementBlock("footer",s$,[l.renderSlot(w.$slots,"actions",{},void 0,!0)])):l.createCommentVNode("",!0)])):l.createCommentVNode("",!0)],void 0,!0),_:3})],2)),[[l.vShow,g.value]])}}}),d$=Te(c$,[["__scopeId","data-v-c1cd80e6"]]),p$={name:"WtProgressBar",props:{max:{type:[Number,String],default:100},value:{type:[Number,String],default:0},color:{type:String,default:"primary",options:["primary","secondary","success","error"]}},computed:{progress(){return this.value*100/this.max},isOverflow(){return this.progress>=100},progressWidth(){return this.isOverflow?100:this.progress}}};function u$(o,i,a,r,s,c){return l.openBlock(),l.createElementBlock("div",{class:l.normalizeClass([[{"wt-progress-bar--overflow":c.isOverflow},`wt-progress-bar--${a.color}`],"wt-progress-bar"])},[l.createElementVNode("span",{style:l.normalizeStyle(`width: ${c.progressWidth}%;`),class:"wt-progress-bar__progress"},null,4)],2)}const f$=Te(p$,[["render",u$],["__scopeId","data-v-8e95a59e"]]),m$={name:"WtRadio",model:{prop:"selected",event:"input"},props:{value:{type:[String,Number,Boolean,Object],default:""},selected:{type:[String,Number,Boolean,Object],default:""},label:{type:String,default:""},required:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},outline:{type:Boolean,default:!1}},emits:["input"],computed:{isChecked(){return this.value===this.selected},radioIcon(){return this.isChecked?"radio--checked":"radio"}},methods:{inputHandler(){this.$emit("input",this.value)}}},h$=["checked","disabled","value"],b$={key:0,class:"wt-radio__label"};function g$(o,i,a,r,s,c){const p=l.resolveComponent("wt-icon"),f=l.resolveComponent("wt-label");return l.openBlock(),l.createElementBlock("div",{class:l.normalizeClass([{"wt-radio--active":c.isChecked,"wt-radio--outline":a.outline,"wt-radio--disabled":a.disabled},"wt-radio"])},[l.createVNode(f,{class:"wt-radio__wrapper"},{default:l.withCtx(()=>[l.createElementVNode("input",{checked:c.isChecked,disabled:a.disabled,value:a.value,class:"wt-radio__input",type:"radio",onInput:i[0]||(i[0]=(...h)=>c.inputHandler&&c.inputHandler(...h))},null,40,h$),l.createVNode(p,{icon:c.radioIcon,class:"wt-radio__icon"},null,8,["icon"]),l.renderSlot(o.$slots,"label",l.normalizeProps(l.guardReactiveProps({label:a.label,isChecked:c.isChecked,disabled:a.disabled})),()=>[a.label?(l.openBlock(),l.createElementBlock("div",b$,l.toDisplayString(a.label),1)):l.createCommentVNode("",!0)],!0)],void 0,!0),_:3})],2)}const y$=Te(m$,[["render",g$],["__scopeId","data-v-e4e0f836"]]),w$=Te({__name:"wt-rounded-action",props:{icon:{type:String,required:!0},iconPrefix:{type:String,default:""},color:{type:String,options:["primary","secondary","success","error","transfer"],default:"secondary"},size:{type:String,default:"md"},active:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},rounded:{type:Boolean,default:!1},wide:{type:Boolean,default:!1},loading:{type:Boolean,default:!1}},emits:["click"],setup(o,{emit:i}){const a=o,r=i,s=ref(!1),c=l.computed(()=>a.size==="sm"?"xs":"sm"),p=l.computed(()=>{if(a.disabled)return"disabled";switch(a.color){case"secondary":return"default";default:return a.color}});return watch(()=>a.loading,f=>{f?s.value=!0:setTimeout(()=>{s.value=f},1e3)},{immediate:!0}),(f,h)=>{const b=l.resolveComponent("wt-loader"),g=l.resolveComponent("wt-icon");return l.openBlock(),l.createElementBlock("button",{class:l.normalizeClass([[`wt-rounded-action--size-${o.size}`,{"wt-rounded-action--active":o.active},{"wt-rounded-action--disabled":o.disabled},{"wt-rounded-action--rounded":o.rounded},{"wt-rounded-action--wide":o.wide},{"wt-button--loading":l.unref(s)}],"wt-rounded-action"]),type:"button",onClick:h[0]||(h[0]=w=>r("click",w))},[l.unref(s)?(l.openBlock(),l.createBlock(b,{key:0,color:"main",size:c.value},null,8,["size"])):(l.openBlock(),l.createBlock(g,{key:1,color:p.value,icon:o.icon,"icon-prefix":o.iconPrefix,size:o.size},null,8,["color","icon","icon-prefix","size"]))],2)}}},[["__scopeId","data-v-116e5deb"]]),v$={class:"wt-search-bar__wrapper"},C$={class:"wt-search-bar__search-icon"},k$=["placeholder","value"],x$={class:"wt-search-bar__icon-controls"},_$=Te(l.defineComponent({__name:"wt-search-bar",props:{v:{type:Object},customValidators:{type:Array,default:()=>[]},value:{type:String,default:""},placeholder:{type:String},hint:{type:String,description:'Adds hint icon + tooltip with text, passed as "hint" prop'},searchMode:{type:[String,Object]},searchModeOptions:{type:Array,default:()=>[]}},emits:["input","search","enter","update:search-mode","change:search-mode"],setup(o,{emit:i}){const a=o,r=i,{v:s,customValidators:c}=l.toRefs(a),{invalid:p}=hl({v:s,customValidators:c}),f=l.computed(()=>p.value?"error":"default"),h=_0(y=>{r("search",y)},1e3);function b(y){r("input",y),h(y)}function g(y){y.key==="Enter"?(h(a.value),y.preventDefault()):y.key==="Esc"&&(b(""),y.preventDefault())}function w({option:y}){r("update:search-mode",y),r("change:search-mode",y)}return(y,C)=>{const A=l.resolveComponent("wt-icon"),S=l.resolveComponent("wt-icon-btn"),I=l.resolveComponent("wt-hint"),_=l.resolveComponent("wt-tooltip"),k=l.resolveComponent("wt-radio"),E=l.resolveComponent("wt-context-menu");return l.openBlock(),l.createElementBlock("div",{class:l.normalizeClass([{"wt-search-bar--invalid":l.unref(p)},"wt-search-bar"])},[l.createElementVNode("div",v$,[l.createElementVNode("div",C$,[l.renderSlot(y.$slots,"search-icon",l.normalizeProps(l.guardReactiveProps({invalid:l.unref(p),searchMode:o.searchMode})),()=>{var T;return[l.createVNode(A,{color:f.value,icon:((T=o.searchMode)==null?void 0:T.icon)||"search"},null,8,["color","icon"])]},!0)]),l.createElementVNode("input",{placeholder:o.placeholder||y.$t("webitelUI.searchBar.placeholder"),value:o.value,class:"wt-search-bar__input",type:"search",onInput:C[0]||(C[0]=T=>b(T.target.value)),onKeyup:g},null,40,k$),l.createElementVNode("div",x$,[l.createVNode(S,{class:l.normalizeClass([{hidden:!o.value},"wt-search-bar__reset-icon-btn"]),color:f.value,icon:"close",onClick:C[1]||(C[1]=T=>b(""))},null,8,["class","color"]),o.hint?(l.openBlock(),l.createBlock(I,{key:0,"icon-color":f.value},{default:l.withCtx(()=>[l.createTextVNode(l.toDisplayString(o.hint),1)],void 0,!0),_:1},8,["icon-color"])):l.createCommentVNode("",!0),o.searchMode?(l.openBlock(),l.createBlock(E,{key:1,options:o.searchModeOptions,onClick:w},{activator:l.withCtx(()=>[l.createVNode(_,null,{activator:l.withCtx(()=>[l.createVNode(S,{color:l.unref(p)?"error":"default",icon:"filter"},null,8,["color"])]),default:l.withCtx(()=>[l.createTextVNode(" "+l.toDisplayString(y.$t("webitelUI.searchBar.settingsHint")),1)],void 0,!0),_:1})]),option:l.withCtx(({value:T,text:D})=>[l.createVNode(k,{label:D,selected:(typeof o.searchMode=="string"?o.searchMode:o.searchMode.value)===T,value:!0},null,8,["label","selected"])]),_:1},8,["options"])):l.createCommentVNode("",!0),l.renderSlot(y.$slots,"additional-actions",{invalid:l.unref(p)},void 0,!0)])])],2)}}}),[["__scopeId","data-v-46cce2ad"]]),O4=o=>Array.isArray(o)?!o.length:typeof o=="object"?!o||!Object.keys(o).length:!o,R4={methods:{tag(o,i){this.emitTagEvent(o,i);const a=this.trackBy?{[this.optionLabel||"name"]:o,[this.trackBy]:i||o}:o;if(!(s=>typeof s=="string"?this.options.some(c=>c===s):this.options.some(c=>c[this.trackBy]===s[this.trackBy]))(a)&&(this.options.unshift(a),!this.manualTagging)){const s=this.multiple?[...this.value,a]:a;this.input(s)}},emitTagEvent(o,i){this.$emit("tag",o,i)}}};function H0(o){return o===0?!1:Array.isArray(o)&&o.length===0?!0:!o}function I$(o){return(...i)=>!o(...i)}function S$(o,i){return o===void 0&&(o="undefined"),o===null&&(o="null"),o===!1&&(o="false"),o.toString().toLowerCase().indexOf(i.trim())!==-1}function A$(o){return o.filter(i=>!i.$isLabel)}function W0(o,i){return a=>a.reduce((r,s)=>s[o]&&s[o].length?(r.push({$groupLabel:s[i],$isLabel:!0}),r.concat(s[o])):r,[])}const B4=(...o)=>i=>o.reduce((a,r)=>r(a),i);var T$={data(){return{search:"",isOpen:!1,preferredOpenDirection:"below",optimizedHeight:this.maxHeight}},props:{internalSearch:{type:Boolean,default:!0},options:{type:Array,required:!0},multiple:{type:Boolean,default:!1},trackBy:{type:String},label:{type:String},searchable:{type:Boolean,default:!0},clearOnSelect:{type:Boolean,default:!0},hideSelected:{type:Boolean,default:!1},placeholder:{type:String,default:"Select option"},allowEmpty:{type:Boolean,default:!0},resetAfter:{type:Boolean,default:!1},closeOnSelect:{type:Boolean,default:!0},customLabel:{type:Function,default(o,i){return H0(o)?"":i?o[i]:o}},taggable:{type:Boolean,default:!1},tagPlaceholder:{type:String,default:"Press enter to create a tag"},tagPosition:{type:String,default:"top"},max:{type:[Number,Boolean],default:!1},id:{default:null},optionsLimit:{type:Number,default:1e3},groupValues:{type:String},groupLabel:{type:String},groupSelect:{type:Boolean,default:!1},blockKeys:{type:Array,default(){return[]}},preserveSearch:{type:Boolean,default:!1},preselectFirst:{type:Boolean,default:!1},preventAutofocus:{type:Boolean,default:!1},filteringSortFunc:{type:Function,default:null}},mounted(){!this.multiple&&this.max&&console.warn("[Vue-Multiselect warn]: Max prop should not be used when prop Multiple equals false."),this.preselectFirst&&!this.internalValue.length&&this.options.length&&this.select(this.filteredOptions[0])},computed:{internalValue(){return this.modelValue||this.modelValue===0?Array.isArray(this.modelValue)?this.modelValue:[this.modelValue]:[]},filteredOptions(){const o=this.search||"",i=o.toLowerCase().trim();let a=this.options.concat();return this.internalSearch?a=this.groupValues?this.filterAndFlat(a,i,this.label):this.filterOptions(a,i,this.label,this.customLabel):a=this.groupValues?W0(this.groupValues,this.groupLabel)(a):a,a=this.hideSelected?a.filter(I$(this.isSelected)):a,this.taggable&&i.length&&!this.isExistingOption(i)&&(this.tagPosition==="bottom"?a.push({isTag:!0,label:o}):a.unshift({isTag:!0,label:o})),a.slice(0,this.optionsLimit)},valueKeys(){return this.trackBy?this.internalValue.map(o=>o[this.trackBy]):this.internalValue},optionKeys(){return(this.groupValues?this.flatAndStrip(this.options):this.options).map(i=>this.customLabel(i,this.label).toString().toLowerCase())},currentOptionLabel(){return this.multiple?this.searchable?"":this.placeholder:this.internalValue.length?this.getOptionLabel(this.internalValue[0]):this.searchable?"":this.placeholder}},watch:{internalValue:{handler(){this.resetAfter&&this.internalValue.length&&(this.search="",this.$emit("update:modelValue",this.multiple?[]:null))},deep:!0},search(){this.$emit("search-change",this.search)}},emits:["open","search-change","close","select","update:modelValue","remove","tag"],methods:{getValue(){return this.multiple?this.internalValue:this.internalValue.length===0?null:this.internalValue[0]},filterAndFlat(o,i,a){return B4(this.filterGroups(i,a,this.groupValues,this.groupLabel,this.customLabel),W0(this.groupValues,this.groupLabel))(o)},flatAndStrip(o){return B4(W0(this.groupValues,this.groupLabel),A$)(o)},updateSearch(o){this.search=o},isExistingOption(o){return this.options?this.optionKeys.indexOf(o)>-1:!1},isSelected(o){const i=this.trackBy?o[this.trackBy]:o;return this.valueKeys.indexOf(i)>-1},isOptionDisabled(o){return!!o.$isDisabled},getOptionLabel(o){if(H0(o))return"";if(o.isTag)return o.label;if(o.$isLabel)return o.$groupLabel;const i=this.customLabel(o,this.label);return H0(i)?"":i},select(o,i){if(o.$isLabel&&this.groupSelect){this.selectGroup(o);return}if(!(this.blockKeys.indexOf(i)!==-1||this.disabled||o.$isDisabled||o.$isLabel)&&!(this.max&&this.multiple&&this.internalValue.length===this.max)&&!(i==="Tab"&&!this.pointerDirty)){if(o.isTag)this.$emit("tag",o.label,this.id),this.search="",this.closeOnSelect&&!this.multiple&&this.deactivate();else{if(this.isSelected(o)){i!=="Tab"&&this.removeElement(o);return}this.multiple?this.$emit("update:modelValue",this.internalValue.concat([o])):this.$emit("update:modelValue",o),this.$emit("select",o,this.id),this.clearOnSelect&&(this.search="")}this.closeOnSelect&&this.deactivate()}},selectGroup(o){const i=this.options.find(a=>a[this.groupLabel]===o.$groupLabel);if(i){if(this.wholeGroupSelected(i)){this.$emit("remove",i[this.groupValues],this.id);const a=this.trackBy?i[this.groupValues].map(s=>s[this.trackBy]):i[this.groupValues],r=this.internalValue.filter(s=>a.indexOf(this.trackBy?s[this.trackBy]:s)===-1);this.$emit("update:modelValue",r)}else{const a=i[this.groupValues].filter(r=>!(this.isOptionDisabled(r)||this.isSelected(r)));this.max&&a.splice(this.max-this.internalValue.length),this.$emit("select",a,this.id),this.$emit("update:modelValue",this.internalValue.concat(a))}this.closeOnSelect&&this.deactivate()}},wholeGroupSelected(o){return o[this.groupValues].every(i=>this.isSelected(i)||this.isOptionDisabled(i))},wholeGroupDisabled(o){return o[this.groupValues].every(this.isOptionDisabled)},removeElement(o,i=!0){if(this.disabled||o.$isDisabled)return;if(!this.allowEmpty&&this.internalValue.length<=1){this.deactivate();return}const a=typeof o=="object"?this.valueKeys.indexOf(o[this.trackBy]):this.valueKeys.indexOf(o);if(this.multiple){const r=this.internalValue.slice(0,a).concat(this.internalValue.slice(a+1));this.$emit("update:modelValue",r)}else this.$emit("update:modelValue",null);this.$emit("remove",o,this.id),this.closeOnSelect&&i&&this.deactivate()},removeLastElement(){this.blockKeys.indexOf("Delete")===-1&&this.search.length===0&&Array.isArray(this.internalValue)&&this.internalValue.length&&this.removeElement(this.internalValue[this.internalValue.length-1],!1)},activate(){this.isOpen||this.disabled||(this.adjustPosition(),this.groupValues&&this.pointer===0&&this.filteredOptions.length&&(this.pointer=1),this.isOpen=!0,this.searchable?(this.preserveSearch||(this.search=""),this.preventAutofocus||this.$nextTick(()=>this.$refs.search&&this.$refs.search.focus())):this.preventAutofocus||typeof this.$el<"u"&&this.$el.focus(),this.$emit("open",this.id))},deactivate(){this.isOpen&&(this.isOpen=!1,this.searchable?this.$refs.search!==null&&typeof this.$refs.search<"u"&&this.$refs.search.blur():typeof this.$el<"u"&&this.$el.blur(),this.preserveSearch||(this.search=""),this.$emit("close",this.getValue(),this.id))},toggle(){this.isOpen?this.deactivate():this.activate()},adjustPosition(){if(typeof window>"u")return;const o=this.$el.getBoundingClientRect().top,i=window.innerHeight-this.$el.getBoundingClientRect().bottom;i>this.maxHeight||i>o||this.openDirection==="below"||this.openDirection==="bottom"?(this.preferredOpenDirection="below",this.optimizedHeight=Math.min(i-40,this.maxHeight)):(this.preferredOpenDirection="above",this.optimizedHeight=Math.min(o-40,this.maxHeight))},filterOptions(o,i,a,r){return i?o.filter(s=>S$(r(s,a),i)).sort((s,c)=>typeof this.filteringSortFunc=="function"?this.filteringSortFunc(s,c):r(s,a).length-r(c,a).length):o},filterGroups(o,i,a,r,s){return c=>c.map(p=>{if(!p[a])return console.warn("Options passed to vue-multiselect do not contain groups, despite the config."),[];const f=this.filterOptions(p[a],o,i,s);return f.length?{[r]:p[r],[a]:f}:[]})}}},E$={data(){return{pointer:0,pointerDirty:!1}},props:{showPointer:{type:Boolean,default:!0},optionHeight:{type:Number,default:40}},computed:{pointerPosition(){return this.pointer*this.optionHeight},visibleElements(){return this.optimizedHeight/this.optionHeight}},watch:{filteredOptions(){this.pointerAdjust()},isOpen(){this.pointerDirty=!1},pointer(){this.$refs.search&&this.$refs.search.setAttribute("aria-activedescendant",this.id+"-"+this.pointer.toString())}},methods:{optionHighlight(o,i){return{"multiselect__option--highlight":o===this.pointer&&this.showPointer,"multiselect__option--selected":this.isSelected(i)}},groupHighlight(o,i){if(!this.groupSelect)return["multiselect__option--disabled",{"multiselect__option--group":i.$isLabel}];const a=this.options.find(r=>r[this.groupLabel]===i.$groupLabel);return a&&!this.wholeGroupDisabled(a)?["multiselect__option--group",{"multiselect__option--highlight":o===this.pointer&&this.showPointer},{"multiselect__option--group-selected":this.wholeGroupSelected(a)}]:"multiselect__option--disabled"},addPointerElement({key:o}="Enter"){this.filteredOptions.length>0&&this.select(this.filteredOptions[this.pointer],o),this.pointerReset()},pointerForward(){this.pointer<this.filteredOptions.length-1&&(this.pointer++,this.$refs.list.scrollTop<=this.pointerPosition-(this.visibleElements-1)*this.optionHeight&&(this.$refs.list.scrollTop=this.pointerPosition-(this.visibleElements-1)*this.optionHeight),this.filteredOptions[this.pointer]&&this.filteredOptions[this.pointer].$isLabel&&!this.groupSelect&&this.pointerForward()),this.pointerDirty=!0},pointerBackward(){this.pointer>0?(this.pointer--,this.$refs.list.scrollTop>=this.pointerPosition&&(this.$refs.list.scrollTop=this.pointerPosition),this.filteredOptions[this.pointer]&&this.filteredOptions[this.pointer].$isLabel&&!this.groupSelect&&this.pointerBackward()):this.filteredOptions[this.pointer]&&this.filteredOptions[0].$isLabel&&!this.groupSelect&&this.pointerForward(),this.pointerDirty=!0},pointerReset(){this.closeOnSelect&&(this.pointer=0,this.$refs.list&&(this.$refs.list.scrollTop=0))},pointerAdjust(){this.pointer>=this.filteredOptions.length-1&&(this.pointer=this.filteredOptions.length?this.filteredOptions.length-1:0),this.filteredOptions.length>0&&this.filteredOptions[this.pointer].$isLabel&&!this.groupSelect&&this.pointerForward()},pointerSet(o){this.pointer=o,this.pointerDirty=!0}}},L4={name:"vue-multiselect",mixins:[T$,E$],compatConfig:{MODE:3,ATTR_ENUMERATED_COERCION:!1},props:{name:{type:String,default:""},modelValue:{type:null,default(){return[]}},selectLabel:{type:String,default:"Press enter to select"},selectGroupLabel:{type:String,default:"Press enter to select group"},selectedLabel:{type:String,default:"Selected"},deselectLabel:{type:String,default:"Press enter to remove"},deselectGroupLabel:{type:String,default:"Press enter to deselect group"},showLabels:{type:Boolean,default:!0},limit:{type:Number,default:99999},maxHeight:{type:Number,default:300},limitText:{type:Function,default:o=>`and ${o} more`},loading:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},spellcheck:{type:Boolean,default:!1},openDirection:{type:String,default:""},showNoOptions:{type:Boolean,default:!0},showNoResults:{type:Boolean,default:!0},tabindex:{type:Number,default:0},required:{type:Boolean,default:!1}},computed:{hasOptionGroup(){return this.groupValues&&this.groupLabel&&this.groupSelect},isSingleLabelVisible(){return(this.singleValue||this.singleValue===0)&&(!this.isOpen||!this.searchable)&&!this.visibleValues.length},isPlaceholderVisible(){return!this.internalValue.length&&(!this.searchable||!this.isOpen)},visibleValues(){return this.multiple?this.internalValue.slice(0,this.limit):[]},singleValue(){return this.internalValue[0]},deselectLabelText(){return this.showLabels?this.deselectLabel:""},deselectGroupLabelText(){return this.showLabels?this.deselectGroupLabel:""},selectLabelText(){return this.showLabels?this.selectLabel:""},selectGroupLabelText(){return this.showLabels?this.selectGroupLabel:""},selectedLabelText(){return this.showLabels?this.selectedLabel:""},inputStyle(){return this.searchable||this.multiple&&this.modelValue&&this.modelValue.length?this.isOpen?{width:"100%"}:{width:"0",position:"absolute",padding:"0"}:""},contentStyle(){return this.options.length?{display:"inline-block"}:{display:"block"}},isAbove(){return this.openDirection==="above"||this.openDirection==="top"?!0:this.openDirection==="below"||this.openDirection==="bottom"?!1:this.preferredOpenDirection==="above"},showSearchInput(){return this.searchable&&(this.hasSingleSelectedSlot&&(this.visibleSingleValue||this.visibleSingleValue===0)?this.isOpen:!0)},isRequired(){return this.required===!1?!1:this.internalValue.length<=0}}};const D$=["tabindex","aria-expanded","aria-owns","aria-activedescendant"],O$={ref:"tags",class:"multiselect__tags"},R$={class:"multiselect__tags-wrap"},B$=["textContent"],L$=["onKeypress","onMousedown"],N$=["textContent"],P$={class:"multiselect__spinner"},q$=["name","id","spellcheck","placeholder","required","value","disabled","tabindex","aria-label","aria-controls"],j$=["id","aria-multiselectable"],M$={key:0},$$={class:"multiselect__option"},F$=["aria-selected","id","role"],V$=["onClick","onMouseenter","data-select","data-selected","data-deselect"],U$=["data-select","data-deselect","onMouseenter","onMousedown"],z$={class:"multiselect__option"},H$={class:"multiselect__option"};function W$(o,i,a,r,s,c){return l.openBlock(),l.createElementBlock("div",{tabindex:o.searchable?-1:a.tabindex,class:l.normalizeClass([{"multiselect--active":o.isOpen,"multiselect--disabled":a.disabled,"multiselect--above":c.isAbove,"multiselect--has-options-group":c.hasOptionGroup},"multiselect"]),onFocus:i[14]||(i[14]=p=>o.activate()),onBlur:i[15]||(i[15]=p=>o.searchable?!1:o.deactivate()),onKeydown:[i[16]||(i[16]=l.withKeys(l.withModifiers(p=>o.pointerForward(),["self","prevent"]),["down"])),i[17]||(i[17]=l.withKeys(l.withModifiers(p=>o.pointerBackward(),["self","prevent"]),["up"]))],onKeypress:i[18]||(i[18]=l.withKeys(l.withModifiers(p=>o.addPointerElement(p),["stop","self"]),["enter","tab"])),onKeyup:i[19]||(i[19]=l.withKeys(p=>o.deactivate(),["esc"])),role:"combobox","aria-expanded":o.isOpen,"aria-owns":"listbox-"+o.id,"aria-activedescendant":o.isOpen&&o.pointer!==null?o.id+"-"+o.pointer:null},[l.renderSlot(o.$slots,"caret",{toggle:o.toggle},()=>[l.createElementVNode("div",{onMousedown:i[0]||(i[0]=l.withModifiers(p=>o.toggle(),["prevent","stop"])),class:"multiselect__select"},null,32)]),l.renderSlot(o.$slots,"clear",{search:o.search}),l.createElementVNode("div",O$,[l.renderSlot(o.$slots,"selection",{search:o.search,remove:o.removeElement,values:c.visibleValues,isOpen:o.isOpen},()=>[l.withDirectives(l.createElementVNode("div",R$,[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(c.visibleValues,(p,f)=>l.renderSlot(o.$slots,"tag",{option:p,search:o.search,remove:o.removeElement},()=>[(l.openBlock(),l.createElementBlock("span",{class:"multiselect__tag",key:f,onMousedown:i[1]||(i[1]=l.withModifiers(()=>{},["prevent"]))},[l.createElementVNode("span",{textContent:l.toDisplayString(o.getOptionLabel(p))},null,8,B$),l.createElementVNode("i",{tabindex:"1",onKeypress:l.withKeys(l.withModifiers(h=>o.removeElement(p),["prevent"]),["enter"]),onMousedown:l.withModifiers(h=>o.removeElement(p),["prevent"]),class:"multiselect__tag-icon"},null,40,L$)],32))])),256))],512),[[l.vShow,c.visibleValues.length>0]]),o.internalValue&&o.internalValue.length>a.limit?l.renderSlot(o.$slots,"limit",{key:0},()=>[l.createElementVNode("strong",{class:"multiselect__strong",textContent:l.toDisplayString(a.limitText(o.internalValue.length-a.limit))},null,8,N$)]):l.createCommentVNode("v-if",!0)]),l.createVNode(l.Transition,{name:"multiselect__loading"},{default:l.withCtx(()=>[l.renderSlot(o.$slots,"loading",{},()=>[l.withDirectives(l.createElementVNode("div",P$,null,512),[[l.vShow,a.loading]])])]),_:3}),o.searchable?(l.openBlock(),l.createElementBlock("input",{key:0,ref:"search",name:a.name,id:o.id,type:"text",autocomplete:"off",spellcheck:a.spellcheck,placeholder:o.placeholder,required:c.isRequired,style:l.normalizeStyle(c.inputStyle),value:o.search,disabled:a.disabled,tabindex:a.tabindex,"aria-label":a.name+"-searchbox",onInput:i[2]||(i[2]=p=>o.updateSearch(p.target.value)),onFocus:i[3]||(i[3]=l.withModifiers(p=>o.activate(),["prevent"])),onBlur:i[4]||(i[4]=l.withModifiers(p=>o.deactivate(),["prevent"])),onKeyup:i[5]||(i[5]=l.withKeys(p=>o.deactivate(),["esc"])),onKeydown:[i[6]||(i[6]=l.withKeys(l.withModifiers(p=>o.pointerForward(),["prevent"]),["down"])),i[7]||(i[7]=l.withKeys(l.withModifiers(p=>o.pointerBackward(),["prevent"]),["up"])),i[9]||(i[9]=l.withKeys(l.withModifiers(p=>o.removeLastElement(),["stop"]),["delete"]))],onKeypress:i[8]||(i[8]=l.withKeys(l.withModifiers(p=>o.addPointerElement(p),["prevent","stop","self"]),["enter"])),class:"multiselect__input","aria-controls":"listbox-"+o.id},null,44,q$)):l.createCommentVNode("v-if",!0),c.isSingleLabelVisible?(l.openBlock(),l.createElementBlock("span",{key:1,class:"multiselect__single",onMousedown:i[10]||(i[10]=l.withModifiers((...p)=>o.toggle&&o.toggle(...p),["prevent"]))},[l.renderSlot(o.$slots,"singleLabel",{option:c.singleValue},()=>[l.createTextVNode(l.toDisplayString(o.currentOptionLabel),1)])],32)):l.createCommentVNode("v-if",!0),c.isPlaceholderVisible?(l.openBlock(),l.createElementBlock("span",{key:2,class:"multiselect__placeholder",onMousedown:i[11]||(i[11]=l.withModifiers((...p)=>o.toggle&&o.toggle(...p),["prevent"]))},[l.renderSlot(o.$slots,"placeholder",{},()=>[l.createTextVNode(l.toDisplayString(o.placeholder),1)])],32)):l.createCommentVNode("v-if",!0)],512),l.createVNode(l.Transition,{name:"multiselect",persisted:""},{default:l.withCtx(()=>[l.withDirectives(l.createElementVNode("div",{class:"multiselect__content-wrapper",onFocus:i[12]||(i[12]=(...p)=>o.activate&&o.activate(...p)),tabindex:"-1",onMousedown:i[13]||(i[13]=l.withModifiers(()=>{},["prevent"])),style:l.normalizeStyle({maxHeight:o.optimizedHeight+"px"}),ref:"list"},[l.createElementVNode("ul",{class:"multiselect__content",style:l.normalizeStyle(c.contentStyle),role:"listbox",id:"listbox-"+o.id,"aria-multiselectable":o.multiple},[l.renderSlot(o.$slots,"beforeList"),o.multiple&&o.max===o.internalValue.length?(l.openBlock(),l.createElementBlock("li",M$,[l.createElementVNode("span",$$,[l.renderSlot(o.$slots,"maxElements",{},()=>[l.createTextVNode("Maximum of "+l.toDisplayString(o.max)+" options selected. First remove a selected option to select another.",1)])])])):l.createCommentVNode("v-if",!0),!o.max||o.internalValue.length<o.max?(l.openBlock(!0),l.createElementBlock(l.Fragment,{key:1},l.renderList(o.filteredOptions,(p,f)=>(l.openBlock(),l.createElementBlock("li",{class:"multiselect__element",key:f,"aria-selected":o.isSelected(p),id:o.id+"-"+f,role:p&&(p.$isLabel||p.$isDisabled)?null:"option"},[p&&(p.$isLabel||p.$isDisabled)?l.createCommentVNode("v-if",!0):(l.openBlock(),l.createElementBlock("span",{key:0,class:l.normalizeClass([o.optionHighlight(f,p),"multiselect__option"]),onClick:l.withModifiers(h=>o.select(p),["stop"]),onMouseenter:l.withModifiers(h=>o.pointerSet(f),["self"]),"data-select":p&&p.isTag?o.tagPlaceholder:c.selectLabelText,"data-selected":c.selectedLabelText,"data-deselect":c.deselectLabelText},[l.renderSlot(o.$slots,"option",{option:p,search:o.search,index:f},()=>[l.createElementVNode("span",null,l.toDisplayString(o.getOptionLabel(p)),1)])],42,V$)),p&&(p.$isLabel||p.$isDisabled)?(l.openBlock(),l.createElementBlock("span",{key:1,"data-select":o.groupSelect&&c.selectGroupLabelText,"data-deselect":o.groupSelect&&c.deselectGroupLabelText,class:l.normalizeClass([o.groupHighlight(f,p),"multiselect__option"]),onMouseenter:l.withModifiers(h=>o.groupSelect&&o.pointerSet(f),["self"]),onMousedown:l.withModifiers(h=>o.selectGroup(p),["prevent"])},[l.renderSlot(o.$slots,"option",{option:p,search:o.search,index:f},()=>[l.createElementVNode("span",null,l.toDisplayString(o.getOptionLabel(p)),1)])],42,U$)):l.createCommentVNode("v-if",!0)],8,F$))),128)):l.createCommentVNode("v-if",!0),l.withDirectives(l.createElementVNode("li",null,[l.createElementVNode("span",z$,[l.renderSlot(o.$slots,"noResult",{search:o.search},()=>[i[20]||(i[20]=l.createTextVNode("No elements found. Consider changing the search query."))])])],512),[[l.vShow,a.showNoResults&&o.filteredOptions.length===0&&o.search&&!a.loading]]),l.withDirectives(l.createElementVNode("li",null,[l.createElementVNode("span",H$,[l.renderSlot(o.$slots,"noOptions",{},()=>[i[21]||(i[21]=l.createTextVNode("List is empty."))])])],512),[[l.vShow,a.showNoOptions&&(o.options.length===0||c.hasOptionGroup===!0&&o.filteredOptions.length===0)&&!o.search&&!a.loading]]),l.renderSlot(o.$slots,"afterList")],12,j$)],36),[[l.vShow,o.isOpen]])]),_:3})],42,D$)}L4.render=W$;function Sl(o){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Sl=function(i){return typeof i}:Sl=function(i){return i&&typeof Symbol=="function"&&i.constructor===Symbol&&i!==Symbol.prototype?"symbol":typeof i},Sl(o)}function Z$(o,i){if(!(o instanceof i))throw new TypeError("Cannot call a class as a function")}function Y$(o,i){for(var a=0;a<i.length;a++){var r=i[a];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(o,r.key,r)}}function K$(o,i,a){return i&&Y$(o.prototype,i),o}function N4(o){return G$(o)||X$(o)||Q$(o)||J$()}function G$(o){if(Array.isArray(o))return Z0(o)}function X$(o){if(typeof Symbol<"u"&&Symbol.iterator in Object(o))return Array.from(o)}function Q$(o,i){if(o){if(typeof o=="string")return Z0(o,i);var a=Object.prototype.toString.call(o).slice(8,-1);if(a==="Object"&&o.constructor&&(a=o.constructor.name),a==="Map"||a==="Set")return Array.from(o);if(a==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(a))return Z0(o,i)}}function Z0(o,i){(i==null||i>o.length)&&(i=o.length);for(var a=0,r=new Array(i);a<i;a++)r[a]=o[a];return r}function J$(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
3144
+ `);this.styleElement.innerHTML=a}},destroyStyle:function(){this.styleElement&&(document.head.removeChild(this.styleElement),this.styleElement=null)},onOverlayClick:function(i){qa.emit("overlay-click",{originalEvent:i,target:this.target})}},directives:{focustrap:yM,ripple:V0},components:{Portal:$0}},FM=["aria-modal"];function VM(o,i,a,r,s,c){var p=l.resolveComponent("Portal"),f=l.resolveDirective("focustrap");return l.openBlock(),l.createBlock(p,{appendTo:o.appendTo},{default:l.withCtx(function(){return[l.createVNode(l.Transition,l.mergeProps({name:"p-popover",onEnter:c.onEnter,onLeave:c.onLeave,onAfterLeave:c.onAfterLeave},o.ptm("transition")),{default:l.withCtx(function(){return[s.visible?l.withDirectives((l.openBlock(),l.createElementBlock("div",l.mergeProps({key:0,ref:c.containerRef,role:"dialog","aria-modal":s.visible,onClick:i[3]||(i[3]=function(){return c.onOverlayClick&&c.onOverlayClick.apply(c,arguments)}),class:o.cx("root")},o.ptmi("root")),[o.$slots.container?l.renderSlot(o.$slots,"container",{key:0,closeCallback:c.hide,keydownCallback:function(b){return c.onButtonKeydown(b)}}):(l.openBlock(),l.createElementBlock("div",l.mergeProps({key:1,class:o.cx("content"),onClick:i[0]||(i[0]=function(){return c.onContentClick&&c.onContentClick.apply(c,arguments)}),onMousedown:i[1]||(i[1]=function(){return c.onContentClick&&c.onContentClick.apply(c,arguments)}),onKeydown:i[2]||(i[2]=function(){return c.onContentKeydown&&c.onContentKeydown.apply(c,arguments)})},o.ptm("content")),[l.renderSlot(o.$slots,"default")],16))],16,FM)),[[f]]):l.createCommentVNode("",!0)]}),_:3},16,["onEnter","onLeave","onAfterLeave"])]}),_:3},8,["appendTo"])}U0.render=VM;const UM=l.defineComponent({__name:"wt-popover",props:{dismissable:{type:Boolean},appendTo:{default:"body"},baseZIndex:{default:0},autoZIndex:{type:Boolean,default:!0},breakpoints:{default:null},dt:{default:null},pt:{default:null},ptOptions:{default:null},unstyled:{type:Boolean},closeOnEscape:{type:Boolean,default:!0}},emits:["show","hide"],setup(o,{expose:i}){const a=l.useAttrs(),r=l.useTemplateRef("innerPopover");return i({toggle:(...s)=>{var c,p;return(p=(c=r.value)==null?void 0:c.toggle)==null?void 0:p.call(c,...s)},show:(...s)=>{var c,p;return(p=(c=r.value)==null?void 0:c.show)==null?void 0:p.call(c,...s)},hide:(...s)=>{var c,p;return(p=(c=r.value)==null?void 0:c.hide)==null?void 0:p.call(c,...s)}}),(s,c)=>(l.openBlock(),l.createBlock(l.unref(U0),l.mergeProps(l.unref(a),{ref_key:"innerPopover",ref:r},{"append-to":s.appendTo,"base-z-index":s.baseZIndex,"auto-z-index":s.autoZIndex,breakpoints:s.breakpoints,dt:s.dt,pt:s.pt,"pt-options":s.ptOptions,"close-on-escape":s.closeOnEscape},l.toHandlers(l.unref(a))),{default:l.withCtx(()=>[l.renderSlot(s.$slots,"default")],void 0,!0),_:3},16,["append-to","base-z-index","auto-z-index","breakpoints","dt","pt","pt-options","close-on-escape"]))}});var zM=o=>Object.prototype.toString.call(o).includes("Object"),T4=o=>typeof o=="number"&&!isNaN(o),HM=o=>Array.isArray(o),E4=o=>Object.prototype.toString.call(o)==="[object String]",z0=o=>Number.isInteger(o);const Il=(o,i)=>i(o)?!0:!zM(o)||Object.keys(o).length!==2?!1:!Object.entries(o).some(([a,r])=>{const s=!["enter","leave"].includes(a),c=!i(r);return s||c}),WM=o=>Il(o,i=>z0(i)&&i>=0),ZM=o=>Il(o,i=>E4(i)&&i.trim()!==""),YM=o=>Il(o,i=>z0(i)&&i>=0),D4=300,KM="cubic-bezier(.25, .8, .5, 1)",GM=0,XM=[0,-16],QM={inheritAttrs:!1,props:{duration:{validator:WM,default:D4},easing:{validator:ZM,default:()=>KM},delay:{validator:YM,default:GM},noOpacity:{type:Boolean,default:!1},appear:{type:Boolean,default:!1},mode:{type:String,default:void 0},group:{type:Boolean,default:!1},tag:{type:String,default:"span"},noMove:{type:Boolean,default:!1},moveDuration:{type:Number,default:D4}},computed:{cComponent(){return this.group?l.TransitionGroup:l.Transition},cAttrs(){const{appear:o,mode:i,tag:a,duration:r}=this;return this.group?{appear:o,tag:a,duration:r,...this.$attrs}:{appear:o,mode:i,duration:r}},cHooks(){return{beforeEnter:(...o)=>{this.reduceTransition(...o),this.$emit("before-enter",...o)},beforeLeave:(...o)=>{var i;this.reduceTransition(...o),(i=this.initLeaving)==null||i.call(this,...o),this.$emit("before-leave",...o)},enter:(...o)=>{var i;(i=this.onEnter)==null||i.call(this,...o),this.$emit("enter",...o)},leave:(...o)=>{var i;(i=this.onLeave)==null||i.call(this,...o),this.$emit("leave",...o)},afterEnter:(...o)=>{var i;this.resetTransition(...o),(i=this.resetElement)==null||i.call(this,...o),this.$emit("after-enter",...o)},afterLeave:(...o)=>{var i;this.resetTransition(...o),(i=this.resetElement)==null||i.call(this,...o),this.$emit("after-leave",...o)}}}},methods:{setupTransition(o,i="enter"){var a,r,s;const c=((a=this.duration)==null?void 0:a[i])??this.duration,p=((r=this.easing)==null?void 0:r[i])??this.easing,f=((s=this.delay)==null?void 0:s[i])??this.delay;o.style.setProperty("transition-duration",`${c}ms`,"important"),o.style.setProperty("transition-timing-function",`${p}`,"important"),o.style.setProperty("transition-delay",`${f}ms`,"important")},reduceTransition(o){o.style.setProperty("transition-duration","0ms","important"),o.style.setProperty("transition-delay","0ms","important")},resetTransition(o){o.style.removeProperty("transition-duration"),o.style.removeProperty("transition-timing-function"),o.style.removeProperty("transition-delay")},initLeaving(o){if(!this.group||this.noMove)return o;const i=getComputedStyle(o),{width:a,height:r}=i,{marginLeft:s,marginTop:c}=i;return o.style.setProperty("left",`${o.offsetLeft-parseFloat(s)}px`,"important"),o.style.setProperty("top",`${o.offsetTop-parseFloat(c)}px`,"important"),o.style.setProperty("width",`${parseFloat(a)}px`,"important"),o.style.setProperty("height",`${parseFloat(r)}px`,"important"),o.style.setProperty("position","absolute","important"),o},setMoveDuration(){var o;this.group&&this.$el&&((o=this.$el.style)==null||o.setProperty("--move-duration",`${this.moveDuration}ms`))}},watch:{moveDuration(){this.setMoveDuration()},group(){this.setMoveDuration()}},mounted(){this.setMoveDuration()}},JM=(o,i)=>{const a=o.__vccOpts||o;for(const[r,s]of i)a[r]=s;return a},e$=o=>{const i=o.startsWith("matrix3d")?"matrix3d":"matrix",a=i==="matrix3d"?o.slice(9,-1).split(",").map(Number):o.startsWith("matrix")?o.slice(7,-1).split(",").map(Number):[1,0,0,1,0,0];return[i,a]},t$={name:"transition-slide",mixins:[QM],props:{offset:{validator:o=>Il(o,i=>!HM(i)||i.length!==2?!1:!i.some(a=>z0(a)?!1:E4(a)?isNaN(Number(a.endsWith("%")?a.slice(0,-1):a)):!0)),default:()=>XM}},data:()=>({}),computed:{},methods:{onEnter(o){this.slideElement(o,"enter"),o.offsetTop,this.setupTransition(o,"enter"),o.style.removeProperty("opacity"),o.style.removeProperty("transform")},onLeave(o){this.setupTransition(o,"leave"),this.slideElement(o,"leave")},slideElement(o,i="enter"){var a;const{width:r,height:s,transform:c}=getComputedStyle(o),p=((a=this.offset)==null?void 0:a[i])??this.offset;let[f,h]=p;T4(f)||(f=f.endsWith("%")?parseFloat(r)*(parseFloat(f.slice(0,-1))||0)/100:parseFloat(f)),T4(h)||(h=h.endsWith("%")?parseFloat(s)*(parseFloat(h.slice(0,-1))||0)/100:parseFloat(h));const[b,g]=e$(c);c.startsWith("matrix3d")?(g[12]+=f,g[13]+=h):c.startsWith("matrix")?(g[4]+=f,g[5]+=h):(g[4]=f,g[5]=h),this.noOpacity||o.style.setProperty("opacity",0),o.style.setProperty("transform",`${b}(${g})`)},resetElement(o){o.style.removeProperty("opacity"),o.style.removeProperty("transform")}}};function o$(o,i,a,r,s,c){return l.openBlock(),l.createBlock(l.resolveDynamicComponent(o.cComponent),l.mergeProps({name:"slide"},o.cAttrs,l.toHandlers(o.cHooks)),{default:l.withCtx(()=>[l.renderSlot(o.$slots,"default")]),_:3},16)}const i$=JM(t$,[["render",o$]]),n$={key:0,class:"wt-popup__popup"},a$={class:"wt-popup__header"},r$={class:"wt-popup__title"},l$={key:0,class:"wt-popup__main"},s$={key:1,class:"wt-popup__actions"},c$=l.defineComponent({__name:"wt-popup",props:{shown:{type:Boolean,default:!0},size:{default:$t.MD},overflow:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1}},emits:["close","popup:opened","popup:closed"],setup(o,{emit:i}){const a=o,r=i,c=!!l.useSlots().activator,p=l.ref(a.shown),f=l.ref(!1),h=()=>{p.value=!0},b=()=>{f.value=!0,p.value=!1,setTimeout(()=>{f.value=!1},200)},g=l.computed(()=>p.value||f.value);return l.watch(()=>a.shown,w=>{c||(w?h():b())}),l.watch(p,w=>{r(w?"popup:opened":"popup:closed")}),(w,y)=>{const C=l.resolveComponent("wt-icon-btn");return l.withDirectives((l.openBlock(),l.createElementBlock("div",{class:l.normalizeClass([[`wt-popup--size-${w.size}`,{"wt-popup--overflow":w.overflow}],"wt-popup"])},[l.createVNode(l.unref(i$),{offset:[0,-1440/2]},{default:l.withCtx(()=>[p.value?(l.openBlock(),l.createElementBlock("aside",n$,[l.createElementVNode("header",a$,[l.renderSlot(w.$slots,"header",{},()=>[l.createElementVNode("h3",r$,[l.renderSlot(w.$slots,"title",{},void 0,!0)])],!0),l.createVNode(C,{class:"wt-popup__close-btn",icon:"close",onClick:y[0]||(y[0]=A=>r("close"))})]),w.$slots.main?(l.openBlock(),l.createElementBlock("section",l$,[l.renderSlot(w.$slots,"main",{},void 0,!0)])):l.createCommentVNode("",!0),w.$slots.actions?(l.openBlock(),l.createElementBlock("footer",s$,[l.renderSlot(w.$slots,"actions",{},void 0,!0)])):l.createCommentVNode("",!0)])):l.createCommentVNode("",!0)],void 0,!0),_:3})],2)),[[l.vShow,g.value]])}}}),d$=Te(c$,[["__scopeId","data-v-c1cd80e6"]]),p$={name:"WtProgressBar",props:{max:{type:[Number,String],default:100},value:{type:[Number,String],default:0},color:{type:String,default:"primary",options:["primary","secondary","success","error"]}},computed:{progress(){return this.value*100/this.max},isOverflow(){return this.progress>=100},progressWidth(){return this.isOverflow?100:this.progress}}};function u$(o,i,a,r,s,c){return l.openBlock(),l.createElementBlock("div",{class:l.normalizeClass([[{"wt-progress-bar--overflow":c.isOverflow},`wt-progress-bar--${a.color}`],"wt-progress-bar"])},[l.createElementVNode("span",{style:l.normalizeStyle(`width: ${c.progressWidth}%;`),class:"wt-progress-bar__progress"},null,4)],2)}const f$=Te(p$,[["render",u$],["__scopeId","data-v-8e95a59e"]]),m$={name:"WtRadio",model:{prop:"selected",event:"input"},props:{value:{type:[String,Number,Boolean,Object],default:""},selected:{type:[String,Number,Boolean,Object],default:""},label:{type:String,default:""},required:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},outline:{type:Boolean,default:!1}},emits:["input"],computed:{isChecked(){return this.value===this.selected},radioIcon(){return this.isChecked?"radio--checked":"radio"}},methods:{inputHandler(){this.$emit("input",this.value)}}},h$=["checked","disabled","value"],b$={key:0,class:"wt-radio__label"};function g$(o,i,a,r,s,c){const p=l.resolveComponent("wt-icon"),f=l.resolveComponent("wt-label");return l.openBlock(),l.createElementBlock("div",{class:l.normalizeClass([{"wt-radio--active":c.isChecked,"wt-radio--outline":a.outline,"wt-radio--disabled":a.disabled},"wt-radio"])},[l.createVNode(f,{class:"wt-radio__wrapper"},{default:l.withCtx(()=>[l.createElementVNode("input",{checked:c.isChecked,disabled:a.disabled,value:a.value,class:"wt-radio__input",type:"radio",onInput:i[0]||(i[0]=(...h)=>c.inputHandler&&c.inputHandler(...h))},null,40,h$),l.createVNode(p,{icon:c.radioIcon,class:"wt-radio__icon"},null,8,["icon"]),l.renderSlot(o.$slots,"label",l.normalizeProps(l.guardReactiveProps({label:a.label,isChecked:c.isChecked,disabled:a.disabled})),()=>[a.label?(l.openBlock(),l.createElementBlock("div",b$,l.toDisplayString(a.label),1)):l.createCommentVNode("",!0)],!0)],void 0,!0),_:3})],2)}const y$=Te(m$,[["render",g$],["__scopeId","data-v-e4e0f836"]]),w$=Te({__name:"wt-rounded-action",props:{icon:{type:String,required:!0},iconPrefix:{type:String,default:""},color:{type:String,options:["primary","secondary","success","error","transfer"],default:"secondary"},size:{type:String,default:"md"},active:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},rounded:{type:Boolean,default:!1},wide:{type:Boolean,default:!1},loading:{type:Boolean,default:!1}},emits:["click"],setup(o,{emit:i}){const a=o,r=i,s=l.ref(!1),c=l.computed(()=>a.size==="sm"?"xs":"sm"),p=l.computed(()=>{if(a.disabled)return"disabled";switch(a.color){case"secondary":return"default";default:return a.color}});return l.watch(()=>a.loading,f=>{f?s.value=!0:setTimeout(()=>{s.value=f},1e3)},{immediate:!0}),(f,h)=>{const b=l.resolveComponent("wt-loader"),g=l.resolveComponent("wt-icon");return l.openBlock(),l.createElementBlock("button",{class:l.normalizeClass([[`wt-rounded-action--size-${o.size}`,{"wt-rounded-action--active":o.active},{"wt-rounded-action--disabled":o.disabled},{"wt-rounded-action--rounded":o.rounded},{"wt-rounded-action--wide":o.wide},{"wt-button--loading":s.value}],"wt-rounded-action"]),type:"button",onClick:h[0]||(h[0]=w=>r("click",w))},[s.value?(l.openBlock(),l.createBlock(b,{key:0,color:"main",size:c.value},null,8,["size"])):(l.openBlock(),l.createBlock(g,{key:1,color:p.value,icon:o.icon,"icon-prefix":o.iconPrefix,size:o.size},null,8,["color","icon","icon-prefix","size"]))],2)}}},[["__scopeId","data-v-5a6955de"]]),v$={class:"wt-search-bar__wrapper"},C$={class:"wt-search-bar__search-icon"},k$=["placeholder","value"],x$={class:"wt-search-bar__icon-controls"},_$=Te(l.defineComponent({__name:"wt-search-bar",props:{v:{type:Object},customValidators:{type:Array,default:()=>[]},value:{type:String,default:""},placeholder:{type:String},hint:{type:String,description:'Adds hint icon + tooltip with text, passed as "hint" prop'},searchMode:{type:[String,Object]},searchModeOptions:{type:Array,default:()=>[]}},emits:["input","search","enter","update:search-mode","change:search-mode"],setup(o,{emit:i}){const a=o,r=i,{v:s,customValidators:c}=l.toRefs(a),{invalid:p}=hl({v:s,customValidators:c}),f=l.computed(()=>p.value?"error":"default"),h=_0(y=>{r("search",y)},1e3);function b(y){r("input",y),h(y)}function g(y){y.key==="Enter"?(h(a.value),y.preventDefault()):y.key==="Esc"&&(b(""),y.preventDefault())}function w({option:y}){r("update:search-mode",y),r("change:search-mode",y)}return(y,C)=>{const A=l.resolveComponent("wt-icon"),S=l.resolveComponent("wt-icon-btn"),I=l.resolveComponent("wt-hint"),_=l.resolveComponent("wt-tooltip"),k=l.resolveComponent("wt-radio"),E=l.resolveComponent("wt-context-menu");return l.openBlock(),l.createElementBlock("div",{class:l.normalizeClass([{"wt-search-bar--invalid":l.unref(p)},"wt-search-bar"])},[l.createElementVNode("div",v$,[l.createElementVNode("div",C$,[l.renderSlot(y.$slots,"search-icon",l.normalizeProps(l.guardReactiveProps({invalid:l.unref(p),searchMode:o.searchMode})),()=>{var T;return[l.createVNode(A,{color:f.value,icon:((T=o.searchMode)==null?void 0:T.icon)||"search"},null,8,["color","icon"])]},!0)]),l.createElementVNode("input",{placeholder:o.placeholder||y.$t("webitelUI.searchBar.placeholder"),value:o.value,class:"wt-search-bar__input",type:"search",onInput:C[0]||(C[0]=T=>b(T.target.value)),onKeyup:g},null,40,k$),l.createElementVNode("div",x$,[l.createVNode(S,{class:l.normalizeClass([{hidden:!o.value},"wt-search-bar__reset-icon-btn"]),color:f.value,icon:"close",onClick:C[1]||(C[1]=T=>b(""))},null,8,["class","color"]),o.hint?(l.openBlock(),l.createBlock(I,{key:0,"icon-color":f.value},{default:l.withCtx(()=>[l.createTextVNode(l.toDisplayString(o.hint),1)],void 0,!0),_:1},8,["icon-color"])):l.createCommentVNode("",!0),o.searchMode?(l.openBlock(),l.createBlock(E,{key:1,options:o.searchModeOptions,onClick:w},{activator:l.withCtx(()=>[l.createVNode(_,null,{activator:l.withCtx(()=>[l.createVNode(S,{color:l.unref(p)?"error":"default",icon:"filter"},null,8,["color"])]),default:l.withCtx(()=>[l.createTextVNode(" "+l.toDisplayString(y.$t("webitelUI.searchBar.settingsHint")),1)],void 0,!0),_:1})]),option:l.withCtx(({value:T,text:D})=>[l.createVNode(k,{label:D,selected:(typeof o.searchMode=="string"?o.searchMode:o.searchMode.value)===T,value:!0},null,8,["label","selected"])]),_:1},8,["options"])):l.createCommentVNode("",!0),l.renderSlot(y.$slots,"additional-actions",{invalid:l.unref(p)},void 0,!0)])])],2)}}}),[["__scopeId","data-v-46cce2ad"]]),O4=o=>Array.isArray(o)?!o.length:typeof o=="object"?!o||!Object.keys(o).length:!o,R4={methods:{tag(o,i){this.emitTagEvent(o,i);const a=this.trackBy?{[this.optionLabel||"name"]:o,[this.trackBy]:i||o}:o;if(!(s=>typeof s=="string"?this.options.some(c=>c===s):this.options.some(c=>c[this.trackBy]===s[this.trackBy]))(a)&&(this.options.unshift(a),!this.manualTagging)){const s=this.multiple?[...this.value,a]:a;this.input(s)}},emitTagEvent(o,i){this.$emit("tag",o,i)}}};function H0(o){return o===0?!1:Array.isArray(o)&&o.length===0?!0:!o}function I$(o){return(...i)=>!o(...i)}function S$(o,i){return o===void 0&&(o="undefined"),o===null&&(o="null"),o===!1&&(o="false"),o.toString().toLowerCase().indexOf(i.trim())!==-1}function A$(o){return o.filter(i=>!i.$isLabel)}function W0(o,i){return a=>a.reduce((r,s)=>s[o]&&s[o].length?(r.push({$groupLabel:s[i],$isLabel:!0}),r.concat(s[o])):r,[])}const B4=(...o)=>i=>o.reduce((a,r)=>r(a),i);var T$={data(){return{search:"",isOpen:!1,preferredOpenDirection:"below",optimizedHeight:this.maxHeight}},props:{internalSearch:{type:Boolean,default:!0},options:{type:Array,required:!0},multiple:{type:Boolean,default:!1},trackBy:{type:String},label:{type:String},searchable:{type:Boolean,default:!0},clearOnSelect:{type:Boolean,default:!0},hideSelected:{type:Boolean,default:!1},placeholder:{type:String,default:"Select option"},allowEmpty:{type:Boolean,default:!0},resetAfter:{type:Boolean,default:!1},closeOnSelect:{type:Boolean,default:!0},customLabel:{type:Function,default(o,i){return H0(o)?"":i?o[i]:o}},taggable:{type:Boolean,default:!1},tagPlaceholder:{type:String,default:"Press enter to create a tag"},tagPosition:{type:String,default:"top"},max:{type:[Number,Boolean],default:!1},id:{default:null},optionsLimit:{type:Number,default:1e3},groupValues:{type:String},groupLabel:{type:String},groupSelect:{type:Boolean,default:!1},blockKeys:{type:Array,default(){return[]}},preserveSearch:{type:Boolean,default:!1},preselectFirst:{type:Boolean,default:!1},preventAutofocus:{type:Boolean,default:!1},filteringSortFunc:{type:Function,default:null}},mounted(){!this.multiple&&this.max&&console.warn("[Vue-Multiselect warn]: Max prop should not be used when prop Multiple equals false."),this.preselectFirst&&!this.internalValue.length&&this.options.length&&this.select(this.filteredOptions[0])},computed:{internalValue(){return this.modelValue||this.modelValue===0?Array.isArray(this.modelValue)?this.modelValue:[this.modelValue]:[]},filteredOptions(){const o=this.search||"",i=o.toLowerCase().trim();let a=this.options.concat();return this.internalSearch?a=this.groupValues?this.filterAndFlat(a,i,this.label):this.filterOptions(a,i,this.label,this.customLabel):a=this.groupValues?W0(this.groupValues,this.groupLabel)(a):a,a=this.hideSelected?a.filter(I$(this.isSelected)):a,this.taggable&&i.length&&!this.isExistingOption(i)&&(this.tagPosition==="bottom"?a.push({isTag:!0,label:o}):a.unshift({isTag:!0,label:o})),a.slice(0,this.optionsLimit)},valueKeys(){return this.trackBy?this.internalValue.map(o=>o[this.trackBy]):this.internalValue},optionKeys(){return(this.groupValues?this.flatAndStrip(this.options):this.options).map(i=>this.customLabel(i,this.label).toString().toLowerCase())},currentOptionLabel(){return this.multiple?this.searchable?"":this.placeholder:this.internalValue.length?this.getOptionLabel(this.internalValue[0]):this.searchable?"":this.placeholder}},watch:{internalValue:{handler(){this.resetAfter&&this.internalValue.length&&(this.search="",this.$emit("update:modelValue",this.multiple?[]:null))},deep:!0},search(){this.$emit("search-change",this.search)}},emits:["open","search-change","close","select","update:modelValue","remove","tag"],methods:{getValue(){return this.multiple?this.internalValue:this.internalValue.length===0?null:this.internalValue[0]},filterAndFlat(o,i,a){return B4(this.filterGroups(i,a,this.groupValues,this.groupLabel,this.customLabel),W0(this.groupValues,this.groupLabel))(o)},flatAndStrip(o){return B4(W0(this.groupValues,this.groupLabel),A$)(o)},updateSearch(o){this.search=o},isExistingOption(o){return this.options?this.optionKeys.indexOf(o)>-1:!1},isSelected(o){const i=this.trackBy?o[this.trackBy]:o;return this.valueKeys.indexOf(i)>-1},isOptionDisabled(o){return!!o.$isDisabled},getOptionLabel(o){if(H0(o))return"";if(o.isTag)return o.label;if(o.$isLabel)return o.$groupLabel;const i=this.customLabel(o,this.label);return H0(i)?"":i},select(o,i){if(o.$isLabel&&this.groupSelect){this.selectGroup(o);return}if(!(this.blockKeys.indexOf(i)!==-1||this.disabled||o.$isDisabled||o.$isLabel)&&!(this.max&&this.multiple&&this.internalValue.length===this.max)&&!(i==="Tab"&&!this.pointerDirty)){if(o.isTag)this.$emit("tag",o.label,this.id),this.search="",this.closeOnSelect&&!this.multiple&&this.deactivate();else{if(this.isSelected(o)){i!=="Tab"&&this.removeElement(o);return}this.multiple?this.$emit("update:modelValue",this.internalValue.concat([o])):this.$emit("update:modelValue",o),this.$emit("select",o,this.id),this.clearOnSelect&&(this.search="")}this.closeOnSelect&&this.deactivate()}},selectGroup(o){const i=this.options.find(a=>a[this.groupLabel]===o.$groupLabel);if(i){if(this.wholeGroupSelected(i)){this.$emit("remove",i[this.groupValues],this.id);const a=this.trackBy?i[this.groupValues].map(s=>s[this.trackBy]):i[this.groupValues],r=this.internalValue.filter(s=>a.indexOf(this.trackBy?s[this.trackBy]:s)===-1);this.$emit("update:modelValue",r)}else{const a=i[this.groupValues].filter(r=>!(this.isOptionDisabled(r)||this.isSelected(r)));this.max&&a.splice(this.max-this.internalValue.length),this.$emit("select",a,this.id),this.$emit("update:modelValue",this.internalValue.concat(a))}this.closeOnSelect&&this.deactivate()}},wholeGroupSelected(o){return o[this.groupValues].every(i=>this.isSelected(i)||this.isOptionDisabled(i))},wholeGroupDisabled(o){return o[this.groupValues].every(this.isOptionDisabled)},removeElement(o,i=!0){if(this.disabled||o.$isDisabled)return;if(!this.allowEmpty&&this.internalValue.length<=1){this.deactivate();return}const a=typeof o=="object"?this.valueKeys.indexOf(o[this.trackBy]):this.valueKeys.indexOf(o);if(this.multiple){const r=this.internalValue.slice(0,a).concat(this.internalValue.slice(a+1));this.$emit("update:modelValue",r)}else this.$emit("update:modelValue",null);this.$emit("remove",o,this.id),this.closeOnSelect&&i&&this.deactivate()},removeLastElement(){this.blockKeys.indexOf("Delete")===-1&&this.search.length===0&&Array.isArray(this.internalValue)&&this.internalValue.length&&this.removeElement(this.internalValue[this.internalValue.length-1],!1)},activate(){this.isOpen||this.disabled||(this.adjustPosition(),this.groupValues&&this.pointer===0&&this.filteredOptions.length&&(this.pointer=1),this.isOpen=!0,this.searchable?(this.preserveSearch||(this.search=""),this.preventAutofocus||this.$nextTick(()=>this.$refs.search&&this.$refs.search.focus())):this.preventAutofocus||typeof this.$el<"u"&&this.$el.focus(),this.$emit("open",this.id))},deactivate(){this.isOpen&&(this.isOpen=!1,this.searchable?this.$refs.search!==null&&typeof this.$refs.search<"u"&&this.$refs.search.blur():typeof this.$el<"u"&&this.$el.blur(),this.preserveSearch||(this.search=""),this.$emit("close",this.getValue(),this.id))},toggle(){this.isOpen?this.deactivate():this.activate()},adjustPosition(){if(typeof window>"u")return;const o=this.$el.getBoundingClientRect().top,i=window.innerHeight-this.$el.getBoundingClientRect().bottom;i>this.maxHeight||i>o||this.openDirection==="below"||this.openDirection==="bottom"?(this.preferredOpenDirection="below",this.optimizedHeight=Math.min(i-40,this.maxHeight)):(this.preferredOpenDirection="above",this.optimizedHeight=Math.min(o-40,this.maxHeight))},filterOptions(o,i,a,r){return i?o.filter(s=>S$(r(s,a),i)).sort((s,c)=>typeof this.filteringSortFunc=="function"?this.filteringSortFunc(s,c):r(s,a).length-r(c,a).length):o},filterGroups(o,i,a,r,s){return c=>c.map(p=>{if(!p[a])return console.warn("Options passed to vue-multiselect do not contain groups, despite the config."),[];const f=this.filterOptions(p[a],o,i,s);return f.length?{[r]:p[r],[a]:f}:[]})}}},E$={data(){return{pointer:0,pointerDirty:!1}},props:{showPointer:{type:Boolean,default:!0},optionHeight:{type:Number,default:40}},computed:{pointerPosition(){return this.pointer*this.optionHeight},visibleElements(){return this.optimizedHeight/this.optionHeight}},watch:{filteredOptions(){this.pointerAdjust()},isOpen(){this.pointerDirty=!1},pointer(){this.$refs.search&&this.$refs.search.setAttribute("aria-activedescendant",this.id+"-"+this.pointer.toString())}},methods:{optionHighlight(o,i){return{"multiselect__option--highlight":o===this.pointer&&this.showPointer,"multiselect__option--selected":this.isSelected(i)}},groupHighlight(o,i){if(!this.groupSelect)return["multiselect__option--disabled",{"multiselect__option--group":i.$isLabel}];const a=this.options.find(r=>r[this.groupLabel]===i.$groupLabel);return a&&!this.wholeGroupDisabled(a)?["multiselect__option--group",{"multiselect__option--highlight":o===this.pointer&&this.showPointer},{"multiselect__option--group-selected":this.wholeGroupSelected(a)}]:"multiselect__option--disabled"},addPointerElement({key:o}="Enter"){this.filteredOptions.length>0&&this.select(this.filteredOptions[this.pointer],o),this.pointerReset()},pointerForward(){this.pointer<this.filteredOptions.length-1&&(this.pointer++,this.$refs.list.scrollTop<=this.pointerPosition-(this.visibleElements-1)*this.optionHeight&&(this.$refs.list.scrollTop=this.pointerPosition-(this.visibleElements-1)*this.optionHeight),this.filteredOptions[this.pointer]&&this.filteredOptions[this.pointer].$isLabel&&!this.groupSelect&&this.pointerForward()),this.pointerDirty=!0},pointerBackward(){this.pointer>0?(this.pointer--,this.$refs.list.scrollTop>=this.pointerPosition&&(this.$refs.list.scrollTop=this.pointerPosition),this.filteredOptions[this.pointer]&&this.filteredOptions[this.pointer].$isLabel&&!this.groupSelect&&this.pointerBackward()):this.filteredOptions[this.pointer]&&this.filteredOptions[0].$isLabel&&!this.groupSelect&&this.pointerForward(),this.pointerDirty=!0},pointerReset(){this.closeOnSelect&&(this.pointer=0,this.$refs.list&&(this.$refs.list.scrollTop=0))},pointerAdjust(){this.pointer>=this.filteredOptions.length-1&&(this.pointer=this.filteredOptions.length?this.filteredOptions.length-1:0),this.filteredOptions.length>0&&this.filteredOptions[this.pointer].$isLabel&&!this.groupSelect&&this.pointerForward()},pointerSet(o){this.pointer=o,this.pointerDirty=!0}}},L4={name:"vue-multiselect",mixins:[T$,E$],compatConfig:{MODE:3,ATTR_ENUMERATED_COERCION:!1},props:{name:{type:String,default:""},modelValue:{type:null,default(){return[]}},selectLabel:{type:String,default:"Press enter to select"},selectGroupLabel:{type:String,default:"Press enter to select group"},selectedLabel:{type:String,default:"Selected"},deselectLabel:{type:String,default:"Press enter to remove"},deselectGroupLabel:{type:String,default:"Press enter to deselect group"},showLabels:{type:Boolean,default:!0},limit:{type:Number,default:99999},maxHeight:{type:Number,default:300},limitText:{type:Function,default:o=>`and ${o} more`},loading:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},spellcheck:{type:Boolean,default:!1},openDirection:{type:String,default:""},showNoOptions:{type:Boolean,default:!0},showNoResults:{type:Boolean,default:!0},tabindex:{type:Number,default:0},required:{type:Boolean,default:!1}},computed:{hasOptionGroup(){return this.groupValues&&this.groupLabel&&this.groupSelect},isSingleLabelVisible(){return(this.singleValue||this.singleValue===0)&&(!this.isOpen||!this.searchable)&&!this.visibleValues.length},isPlaceholderVisible(){return!this.internalValue.length&&(!this.searchable||!this.isOpen)},visibleValues(){return this.multiple?this.internalValue.slice(0,this.limit):[]},singleValue(){return this.internalValue[0]},deselectLabelText(){return this.showLabels?this.deselectLabel:""},deselectGroupLabelText(){return this.showLabels?this.deselectGroupLabel:""},selectLabelText(){return this.showLabels?this.selectLabel:""},selectGroupLabelText(){return this.showLabels?this.selectGroupLabel:""},selectedLabelText(){return this.showLabels?this.selectedLabel:""},inputStyle(){return this.searchable||this.multiple&&this.modelValue&&this.modelValue.length?this.isOpen?{width:"100%"}:{width:"0",position:"absolute",padding:"0"}:""},contentStyle(){return this.options.length?{display:"inline-block"}:{display:"block"}},isAbove(){return this.openDirection==="above"||this.openDirection==="top"?!0:this.openDirection==="below"||this.openDirection==="bottom"?!1:this.preferredOpenDirection==="above"},showSearchInput(){return this.searchable&&(this.hasSingleSelectedSlot&&(this.visibleSingleValue||this.visibleSingleValue===0)?this.isOpen:!0)},isRequired(){return this.required===!1?!1:this.internalValue.length<=0}}};const D$=["tabindex","aria-expanded","aria-owns","aria-activedescendant"],O$={ref:"tags",class:"multiselect__tags"},R$={class:"multiselect__tags-wrap"},B$=["textContent"],L$=["onKeypress","onMousedown"],N$=["textContent"],P$={class:"multiselect__spinner"},q$=["name","id","spellcheck","placeholder","required","value","disabled","tabindex","aria-label","aria-controls"],j$=["id","aria-multiselectable"],M$={key:0},$$={class:"multiselect__option"},F$=["aria-selected","id","role"],V$=["onClick","onMouseenter","data-select","data-selected","data-deselect"],U$=["data-select","data-deselect","onMouseenter","onMousedown"],z$={class:"multiselect__option"},H$={class:"multiselect__option"};function W$(o,i,a,r,s,c){return l.openBlock(),l.createElementBlock("div",{tabindex:o.searchable?-1:a.tabindex,class:l.normalizeClass([{"multiselect--active":o.isOpen,"multiselect--disabled":a.disabled,"multiselect--above":c.isAbove,"multiselect--has-options-group":c.hasOptionGroup},"multiselect"]),onFocus:i[14]||(i[14]=p=>o.activate()),onBlur:i[15]||(i[15]=p=>o.searchable?!1:o.deactivate()),onKeydown:[i[16]||(i[16]=l.withKeys(l.withModifiers(p=>o.pointerForward(),["self","prevent"]),["down"])),i[17]||(i[17]=l.withKeys(l.withModifiers(p=>o.pointerBackward(),["self","prevent"]),["up"]))],onKeypress:i[18]||(i[18]=l.withKeys(l.withModifiers(p=>o.addPointerElement(p),["stop","self"]),["enter","tab"])),onKeyup:i[19]||(i[19]=l.withKeys(p=>o.deactivate(),["esc"])),role:"combobox","aria-expanded":o.isOpen,"aria-owns":"listbox-"+o.id,"aria-activedescendant":o.isOpen&&o.pointer!==null?o.id+"-"+o.pointer:null},[l.renderSlot(o.$slots,"caret",{toggle:o.toggle},()=>[l.createElementVNode("div",{onMousedown:i[0]||(i[0]=l.withModifiers(p=>o.toggle(),["prevent","stop"])),class:"multiselect__select"},null,32)]),l.renderSlot(o.$slots,"clear",{search:o.search}),l.createElementVNode("div",O$,[l.renderSlot(o.$slots,"selection",{search:o.search,remove:o.removeElement,values:c.visibleValues,isOpen:o.isOpen},()=>[l.withDirectives(l.createElementVNode("div",R$,[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(c.visibleValues,(p,f)=>l.renderSlot(o.$slots,"tag",{option:p,search:o.search,remove:o.removeElement},()=>[(l.openBlock(),l.createElementBlock("span",{class:"multiselect__tag",key:f,onMousedown:i[1]||(i[1]=l.withModifiers(()=>{},["prevent"]))},[l.createElementVNode("span",{textContent:l.toDisplayString(o.getOptionLabel(p))},null,8,B$),l.createElementVNode("i",{tabindex:"1",onKeypress:l.withKeys(l.withModifiers(h=>o.removeElement(p),["prevent"]),["enter"]),onMousedown:l.withModifiers(h=>o.removeElement(p),["prevent"]),class:"multiselect__tag-icon"},null,40,L$)],32))])),256))],512),[[l.vShow,c.visibleValues.length>0]]),o.internalValue&&o.internalValue.length>a.limit?l.renderSlot(o.$slots,"limit",{key:0},()=>[l.createElementVNode("strong",{class:"multiselect__strong",textContent:l.toDisplayString(a.limitText(o.internalValue.length-a.limit))},null,8,N$)]):l.createCommentVNode("v-if",!0)]),l.createVNode(l.Transition,{name:"multiselect__loading"},{default:l.withCtx(()=>[l.renderSlot(o.$slots,"loading",{},()=>[l.withDirectives(l.createElementVNode("div",P$,null,512),[[l.vShow,a.loading]])])]),_:3}),o.searchable?(l.openBlock(),l.createElementBlock("input",{key:0,ref:"search",name:a.name,id:o.id,type:"text",autocomplete:"off",spellcheck:a.spellcheck,placeholder:o.placeholder,required:c.isRequired,style:l.normalizeStyle(c.inputStyle),value:o.search,disabled:a.disabled,tabindex:a.tabindex,"aria-label":a.name+"-searchbox",onInput:i[2]||(i[2]=p=>o.updateSearch(p.target.value)),onFocus:i[3]||(i[3]=l.withModifiers(p=>o.activate(),["prevent"])),onBlur:i[4]||(i[4]=l.withModifiers(p=>o.deactivate(),["prevent"])),onKeyup:i[5]||(i[5]=l.withKeys(p=>o.deactivate(),["esc"])),onKeydown:[i[6]||(i[6]=l.withKeys(l.withModifiers(p=>o.pointerForward(),["prevent"]),["down"])),i[7]||(i[7]=l.withKeys(l.withModifiers(p=>o.pointerBackward(),["prevent"]),["up"])),i[9]||(i[9]=l.withKeys(l.withModifiers(p=>o.removeLastElement(),["stop"]),["delete"]))],onKeypress:i[8]||(i[8]=l.withKeys(l.withModifiers(p=>o.addPointerElement(p),["prevent","stop","self"]),["enter"])),class:"multiselect__input","aria-controls":"listbox-"+o.id},null,44,q$)):l.createCommentVNode("v-if",!0),c.isSingleLabelVisible?(l.openBlock(),l.createElementBlock("span",{key:1,class:"multiselect__single",onMousedown:i[10]||(i[10]=l.withModifiers((...p)=>o.toggle&&o.toggle(...p),["prevent"]))},[l.renderSlot(o.$slots,"singleLabel",{option:c.singleValue},()=>[l.createTextVNode(l.toDisplayString(o.currentOptionLabel),1)])],32)):l.createCommentVNode("v-if",!0),c.isPlaceholderVisible?(l.openBlock(),l.createElementBlock("span",{key:2,class:"multiselect__placeholder",onMousedown:i[11]||(i[11]=l.withModifiers((...p)=>o.toggle&&o.toggle(...p),["prevent"]))},[l.renderSlot(o.$slots,"placeholder",{},()=>[l.createTextVNode(l.toDisplayString(o.placeholder),1)])],32)):l.createCommentVNode("v-if",!0)],512),l.createVNode(l.Transition,{name:"multiselect",persisted:""},{default:l.withCtx(()=>[l.withDirectives(l.createElementVNode("div",{class:"multiselect__content-wrapper",onFocus:i[12]||(i[12]=(...p)=>o.activate&&o.activate(...p)),tabindex:"-1",onMousedown:i[13]||(i[13]=l.withModifiers(()=>{},["prevent"])),style:l.normalizeStyle({maxHeight:o.optimizedHeight+"px"}),ref:"list"},[l.createElementVNode("ul",{class:"multiselect__content",style:l.normalizeStyle(c.contentStyle),role:"listbox",id:"listbox-"+o.id,"aria-multiselectable":o.multiple},[l.renderSlot(o.$slots,"beforeList"),o.multiple&&o.max===o.internalValue.length?(l.openBlock(),l.createElementBlock("li",M$,[l.createElementVNode("span",$$,[l.renderSlot(o.$slots,"maxElements",{},()=>[l.createTextVNode("Maximum of "+l.toDisplayString(o.max)+" options selected. First remove a selected option to select another.",1)])])])):l.createCommentVNode("v-if",!0),!o.max||o.internalValue.length<o.max?(l.openBlock(!0),l.createElementBlock(l.Fragment,{key:1},l.renderList(o.filteredOptions,(p,f)=>(l.openBlock(),l.createElementBlock("li",{class:"multiselect__element",key:f,"aria-selected":o.isSelected(p),id:o.id+"-"+f,role:p&&(p.$isLabel||p.$isDisabled)?null:"option"},[p&&(p.$isLabel||p.$isDisabled)?l.createCommentVNode("v-if",!0):(l.openBlock(),l.createElementBlock("span",{key:0,class:l.normalizeClass([o.optionHighlight(f,p),"multiselect__option"]),onClick:l.withModifiers(h=>o.select(p),["stop"]),onMouseenter:l.withModifiers(h=>o.pointerSet(f),["self"]),"data-select":p&&p.isTag?o.tagPlaceholder:c.selectLabelText,"data-selected":c.selectedLabelText,"data-deselect":c.deselectLabelText},[l.renderSlot(o.$slots,"option",{option:p,search:o.search,index:f},()=>[l.createElementVNode("span",null,l.toDisplayString(o.getOptionLabel(p)),1)])],42,V$)),p&&(p.$isLabel||p.$isDisabled)?(l.openBlock(),l.createElementBlock("span",{key:1,"data-select":o.groupSelect&&c.selectGroupLabelText,"data-deselect":o.groupSelect&&c.deselectGroupLabelText,class:l.normalizeClass([o.groupHighlight(f,p),"multiselect__option"]),onMouseenter:l.withModifiers(h=>o.groupSelect&&o.pointerSet(f),["self"]),onMousedown:l.withModifiers(h=>o.selectGroup(p),["prevent"])},[l.renderSlot(o.$slots,"option",{option:p,search:o.search,index:f},()=>[l.createElementVNode("span",null,l.toDisplayString(o.getOptionLabel(p)),1)])],42,U$)):l.createCommentVNode("v-if",!0)],8,F$))),128)):l.createCommentVNode("v-if",!0),l.withDirectives(l.createElementVNode("li",null,[l.createElementVNode("span",z$,[l.renderSlot(o.$slots,"noResult",{search:o.search},()=>[i[20]||(i[20]=l.createTextVNode("No elements found. Consider changing the search query."))])])],512),[[l.vShow,a.showNoResults&&o.filteredOptions.length===0&&o.search&&!a.loading]]),l.withDirectives(l.createElementVNode("li",null,[l.createElementVNode("span",H$,[l.renderSlot(o.$slots,"noOptions",{},()=>[i[21]||(i[21]=l.createTextVNode("List is empty."))])])],512),[[l.vShow,a.showNoOptions&&(o.options.length===0||c.hasOptionGroup===!0&&o.filteredOptions.length===0)&&!o.search&&!a.loading]]),l.renderSlot(o.$slots,"afterList")],12,j$)],36),[[l.vShow,o.isOpen]])]),_:3})],42,D$)}L4.render=W$;function Sl(o){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Sl=function(i){return typeof i}:Sl=function(i){return i&&typeof Symbol=="function"&&i.constructor===Symbol&&i!==Symbol.prototype?"symbol":typeof i},Sl(o)}function Z$(o,i){if(!(o instanceof i))throw new TypeError("Cannot call a class as a function")}function Y$(o,i){for(var a=0;a<i.length;a++){var r=i[a];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(o,r.key,r)}}function K$(o,i,a){return i&&Y$(o.prototype,i),o}function N4(o){return G$(o)||X$(o)||Q$(o)||J$()}function G$(o){if(Array.isArray(o))return Z0(o)}function X$(o){if(typeof Symbol<"u"&&Symbol.iterator in Object(o))return Array.from(o)}function Q$(o,i){if(o){if(typeof o=="string")return Z0(o,i);var a=Object.prototype.toString.call(o).slice(8,-1);if(a==="Object"&&o.constructor&&(a=o.constructor.name),a==="Map"||a==="Set")return Array.from(o);if(a==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(a))return Z0(o,i)}}function Z0(o,i){(i==null||i>o.length)&&(i=o.length);for(var a=0,r=new Array(i);a<i;a++)r[a]=o[a];return r}function J$(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
3145
3145
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function eF(o){var i;return typeof o=="function"?i={callback:o}:i=o,i}function tF(o,i){var a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r,s,c,p=function(h){for(var b=arguments.length,g=new Array(b>1?b-1:0),w=1;w<b;w++)g[w-1]=arguments[w];if(c=g,!(r&&h===s)){var y=a.leading;typeof y=="function"&&(y=y(h,s)),(!r||h!==s)&&y&&o.apply(void 0,[h].concat(N4(c))),s=h,clearTimeout(r),r=setTimeout(function(){o.apply(void 0,[h].concat(N4(c))),r=0},i)}};return p._clear=function(){clearTimeout(r),r=null},p}function P4(o,i){if(o===i)return!0;if(Sl(o)==="object"){for(var a in o)if(!P4(o[a],i[a]))return!1;return!0}return!1}var oF=function(){function o(i,a,r){Z$(this,o),this.el=i,this.observer=null,this.frozen=!1,this.createObserver(a,r)}return K$(o,[{key:"createObserver",value:function(a,r){var s=this;if(this.observer&&this.destroyObserver(),!this.frozen){if(this.options=eF(a),this.callback=function(f,h){s.options.callback(f,h),f&&s.options.once&&(s.frozen=!0,s.destroyObserver())},this.callback&&this.options.throttle){var c=this.options.throttleOptions||{},p=c.leading;this.callback=tF(this.callback,this.options.throttle,{leading:function(h){return p==="both"||p==="visible"&&h||p==="hidden"&&!h}})}this.oldResult=void 0,this.observer=new IntersectionObserver(function(f){var h=f[0];if(f.length>1){var b=f.find(function(w){return w.isIntersecting});b&&(h=b)}if(s.callback){var g=h.isIntersecting&&h.intersectionRatio>=s.threshold;if(g===s.oldResult)return;s.oldResult=g,s.callback(g,h)}},this.options.intersection),l.nextTick(function(){s.observer&&s.observer.observe(s.el)})}}},{key:"destroyObserver",value:function(){this.observer&&(this.observer.disconnect(),this.observer=null),this.callback&&this.callback._clear&&(this.callback._clear(),this.callback=null)}},{key:"threshold",get:function(){return this.options.intersection&&typeof this.options.intersection.threshold=="number"?this.options.intersection.threshold:0}}]),o}();function q4(o,i,a){var r=i.value;if(r)if(typeof IntersectionObserver>"u")console.warn("[vue-observe-visibility] IntersectionObserver API is not available in your browser. Please install this polyfill: https://github.com/w3c/IntersectionObserver/tree/master/polyfill");else{var s=new oF(o,r,a);o._vue_visibilityState=s}}function iF(o,i,a){var r=i.value,s=i.oldValue;if(!P4(r,s)){var c=o._vue_visibilityState;if(!r){j4(o);return}c?c.createObserver(r,a):q4(o,{value:r},a)}}function j4(o){var i=o._vue_visibilityState;i&&(i.destroyObserver(),delete o._vue_visibilityState)}var nF={beforeMount:q4,updated:iF,unmounted:j4};const Al={props:{v:{type:Object},customValidators:{type:Array,default:()=>[]}},computed:{isValidation(){return!!this.v&&!!Object.keys(this.v).length},invalid(){return this.isValidation&&this.v.$error},validationText(){var i,a,r,s,c,p,f,h,b,g,w,y,C,A,S,I,_,k,E,T,D,q,R;let o="";this.isValidation&&this.invalid&&((i=this.v.required)!=null&&i.$invalid?o=this.$t("validation.required"):(a=this.v.numeric)!=null&&a.$invalid?o=this.$t("validation.numeric"):(r=this.v.email)!=null&&r.$invalid?o=this.$t("validation.email"):(s=this.v.gatewayHostValidator)!=null&&s.$invalid?o=this.$t("validation.gatewayHostValidator"):(c=this.v.ipValidator)!=null&&c.$invalid?o=this.$t("validation.ipValidator"):(p=this.v.macValidator)!=null&&p.$invalid?o=this.$t("validation.macValidator"):(f=this.v.minValue)!=null&&f.$invalid?o=`${this.$t("validation.minValue")} ${this.v.minValue.$params.min}`:(h=this.v.maxValue)!=null&&h.$invalid?o=`${this.$t("validation.maxValue")} ${this.v.maxValue.$params.max}`:(b=this.v.sipAccountValidator)!=null&&b.$invalid?o=this.$t("validation.sipAccountValidator"):(g=this.v.minLength)!=null&&g.$invalid?o=`${this.$t("validation.minLength")} ${this.v.minLength.$params.min}`:(w=this.v.url)!=null&&w.$invalid?o=`${this.$t("validation.url")}`:(y=this.v.regExpValidator)!=null&&y.$invalid?o=`${this.$t("validation.regExpValidator")}`:(C=this.v.sameAs)!=null&&C.$invalid?o=`${this.$t("validation.sameAs")}`:(A=this.v.domainValidator)!=null&&A.$invalid?o=`${this.$t("validation.domainValidator")}`:(S=this.v.decimalValidator)!=null&&S.$invalid?o=`${this.$t("validation.decimalValidator")} ${this.v.decimalValidator.$params.count}`:(I=this.v.websocketValidator)!=null&&I.$invalid?o=`${this.$t("validation.websocketValidator")}`:(_=this.v.integer)!=null&&_.$invalid?o=`${this.$t("validation.integer")}`:(k=this.v.isRegExpMatched)!=null&&k.$invalid&&(o=((T=(E=this.v.isRegExpMatched)==null?void 0:E.$params)==null?void 0:T.errorMessage)||`${t("validation.isRegExpMatched")} ${(q=(D=this.v.isRegExpMatched)==null?void 0:D.$params)==null?void 0:q.regExp}`));for(const{name:M,text:$}of this.customValidators)(R=this.v[M])!=null&&R.$invalid&&(o=$);return o}}},M4={mixins:[{props:{label:{type:String,default:""},labelProps:{type:Object,description:"Object with props, passed down to wt-label as props"}},computed:{hasLabel(){return!!(this.label||this.$slots.label)},requiredLabel(){return this.required?`${this.label}*`:this.label}}}],directives:{ObserveVisibility:nF},components:{VueMultiselect:L4},props:{options:{type:Array,default:()=>[]},placeholder:{type:String,default:""},trackBy:{type:String,default:"id"},optionLabel:{type:String},searchMethod:{type:Function},disabled:{type:Boolean,default:!1},required:{type:Boolean,default:!1},allowEmpty:{type:Boolean,default:!1},useValueFromOptionsByProp:{type:String,default:""}},data:()=>({apiOptions:[],cachedOptionsMap:{},isLoading:!1,defaultOptionLabel:"name",searchParams:{search:"",page:1},searchHasNext:!0}),computed:{selectOptionLabel(){return this.trackBy===null?null:this.optionLabel||this.defaultOptionLabel},isApiMode(){return!!this.searchMethod},showIntersectionObserver(){return this.isApiMode&&!this.isLoading&&this.apiOptions.length},selectValue(){if(!this.isValue)return"";let o=this.value;return this.multiple&&!Array.isArray(o)&&(console.warn("wt-select: value prop should be an array when using multiple mode"),o=[o]),this.useValueFromOptionsByProp&&(this.multiple?o=o.map(i=>this.cachedOptionsMap[i]||i):o=this.cachedOptionsMap[o]||o),o},selectOptions(){return this.isApiMode?this.apiOptions:this.options},isValue(){return!O4(this.value)},listeners(){return{"update:model-value":this.input,close:this.close,tag:this.tag,"search-change":o=>{this.$emit("search-change",o),this.handleSearchChange(o)}}}},methods:{getOptionLabel({option:o,optionLabel:i}){return this.allowCustomValues&&o.isTag?o.label:i&&o[i]?o[i]:o.locale?Array.isArray(o.locale)?this.$t(...o.locale):this.$t(o.locale):o[this.defaultOptionLabel]||o},handleSearchChange(o){this.searchParams.search=o,this.isApiMode&&(this.isLoading=!0,this.searchParams.page=1,this.fetchOptions())},handleAfterListIntersect(o){o&&this.searchHasNext&&(this.isLoading=!0,this.searchParams.page+=1,this.fetchOptions())},async fetchOptions({search:o,page:i}=this.searchParams){if(!this.isApiMode)return;const{items:a,next:r}=await this.searchMethod({search:o,page:i});this.apiOptions=this.searchParams.page===1?a:this.apiOptions.concat(a),this.searchHasNext=r,this.isLoading=!1},input(o){let i=o;this.useValueFromOptionsByProp&&(this.multiple?i=o.map(a=>a[this.useValueFromOptionsByProp]):i=o[this.useValueFromOptionsByProp]),this.$emit("input",i),this.$emit("update:model-value",i)},close(o){this.$emit("closed",o)},tag(){}},watch:{disabled(){this.disabled||this.fetchOptions()},selectOptions:{handler(){if(this.trackBy!==null)for(const o of this.selectOptions)this.cachedOptionsMap[o[this.useValueFromOptionsByProp||this.trackBy]]=o},immediate:!0},value:{async handler(){if(this.useValueFromOptionsByProp&&this.isApiMode){const i=(Array.isArray(this.value)?this.value:[this.value]).filter(()=>!this.cachedOptionsMap[this.value]);if(i.length){const{items:a}=await this.searchMethod({id:i,size:i.length});a.forEach(r=>{this.cachedOptionsMap[r[this.useValueFromOptionsByProp]]=r})}}},immediate:!0}},created(){this.disabled||this.fetchOptions(),this.fetchOptions=_0(this.fetchOptions,500)}},aF={name:"WtSelect",mixins:[M4,R4],props:{value:{},multiple:{type:Boolean,default:!1},clearable:{type:Boolean,default:!0},allowCustomValues:{type:Boolean,default:!1,description:'See wt-tags-input "taggable" prop.'},handleCustomValuesAdditionManually:{type:Boolean,default:!1,description:'See wt-tags-input "manualTagging" prop.'},v:{type:Object,default:null},regleValidation:{type:Object,default:null}},emits:["reset","search-change","input","update:modelValue","closed","custom-value"],setup:o=>{const{v:i,customValidators:a,regleValidation:r}=l.toRefs(o),{isValidation:s,invalid:c,validationText:p}=hl({v:i,customValidators:a,regleValidation:r});return{isValidation:s,invalid:c,validationText:p}},data:()=>({isOpened:!1,items:[]}),computed:{taggable(){return this.allowCustomValues},manualTagging(){return this.handleCustomValuesAdditionManually},optionsWithCustomValues(){if(!this.allowCustomValues)return this.selectOptions;const o=Array.isArray(this.value)?this.value:O4(this.value)?[]:[this.value],i=this.selectOptions.filter(a=>{const r=this.trackBy?a[this.trackBy]:a;return!o.some(s=>(this.trackBy?s[this.trackBy]:s)===r)});return[...o,...i]}},methods:{async handleCustomValue(o){this.tag(o)},async search(o){console.log("event.query",o.query),this.items=[...this.optionsWithCustomValues]},async handleCustomValueArrowInput(o){this.tag(this.searchParams.search),o()},emitTagEvent(o,i){this.$emit("custom-value",o,i)},clearValue(){let o="";Array.isArray(this.value)?o=[]:typeof this.value=="object"&&this.value!==null&&(o={}),this.input(o),this.$emit("reset",o)}}},rF={class:"multiselect__custom-tag"},lF={class:"multiselect__single-label"},sF={class:"multiselect__loading-wrapper"},cF={style:{height:"1px"}};function dF(o,i,a,r,s,c){const p=l.resolveComponent("wt-label"),f=l.resolveComponent("wt-chip"),h=l.resolveComponent("wt-tooltip"),b=l.resolveComponent("wt-icon-btn"),g=l.resolveComponent("wt-loader"),w=l.resolveComponent("vue-multiselect"),y=l.resolveComponent("wt-input-info"),C=l.resolveDirective("observe-visibility");return l.openBlock(),l.createElementBlock("div",{class:l.normalizeClass([{"wt-select--disabled":o.disabled,"wt-select--invalid":o.invalid,"wt-select--multiple":a.multiple,"wt-select--clearable":a.clearable,"wt-select--loading":o.isLoading},"wt-select"])},[o.hasLabel?(l.openBlock(),l.createBlock(p,l.mergeProps({key:0},o.labelProps,{disabled:o.disabled,invalid:o.invalid,class:"wt-select__label"}),{default:l.withCtx(()=>[l.renderSlot(o.$slots,"label",l.normalizeProps(l.guardReactiveProps({label:o.label})),()=>[l.createTextVNode(l.toDisplayString(o.requiredLabel),1)],!0)],void 0,!0),_:3},16,["disabled","invalid"])):l.createCommentVNode("",!0),l.createVNode(w,l.mergeProps(o.$attrs,{ref:"vue-multiselect","allow-empty":o.allowEmpty,"close-on-select":o.$attrs.closeOnSelect||!a.multiple,disabled:o.disabled,"internal-search":!o.searchMethod,label:o.selectOptionLabel,limit:1,loading:!1,"model-value":o.selectValue,multiple:a.multiple,options:c.optionsWithCustomValues,placeholder:o.placeholder||o.label,taggable:c.taggable,"track-by":o.trackBy,class:"wt-select__select"},{onClose:i[2]||(i[2]=A=>o.isOpened=!1),onOpen:i[3]||(i[3]=A=>o.isOpened=!0)},l.toHandlers(o.listeners)),l.createSlots({tag:l.withCtx(({option:A})=>[l.createElementVNode("span",rF,l.toDisplayString(o.getOptionLabel({option:A,optionLabel:o.optionLabel})),1)]),singleLabel:l.withCtx(({option:A})=>[l.renderSlot(o.$slots,"singleLabel",l.normalizeProps(l.guardReactiveProps({option:A,optionLabel:o.optionLabel})),()=>[l.createElementVNode("span",lF,l.toDisplayString(o.getOptionLabel({option:A,optionLabel:o.optionLabel})),1)],!0)]),option:l.withCtx(({option:A})=>[l.renderSlot(o.$slots,"option",l.normalizeProps(l.guardReactiveProps({option:A,optionLabel:o.optionLabel})),()=>[l.createTextVNode(l.toDisplayString(o.getOptionLabel({option:A,optionLabel:o.optionLabel})),1)],!0)]),caret:l.withCtx(({toggle:A})=>[a.allowCustomValues&&o.searchParams.search?(l.openBlock(),l.createBlock(b,{key:0,disabled:o.disabled,class:"multiselect__select multiselect__custom-value",icon:"select-custom-value-enter",onClick:S=>c.handleCustomValueArrowInput(A),onMousedown:i[0]||(i[0]=l.withModifiers(()=>{},["prevent"]))},null,8,["disabled","onClick"])):(l.openBlock(),l.createBlock(b,{key:1,disabled:o.disabled,class:"multiselect__select multiselect__arrow",icon:"arrow-down",onClick:A,onMousedown:i[1]||(i[1]=l.withModifiers(()=>{},["prevent"]))},null,8,["disabled","onClick"]))]),clear:l.withCtx(({})=>[a.clearable?(l.openBlock(),l.createBlock(b,{key:0,class:l.normalizeClass([{hidden:!o.isValue},"multiselect__clear"]),disabled:o.disabled,icon:"close",onClick:c.clearValue},null,8,["class","disabled","onClick"])):l.createCommentVNode("",!0)]),beforeList:l.withCtx(()=>[l.withDirectives(l.createElementVNode("div",sF,[l.createVNode(g,{size:"sm"})],512),[[l.vShow,o.isLoading]])]),_:2},[o.isOpened?void 0:{name:"limit",fn:l.withCtx(()=>[l.createVNode(h,{triggers:["click"],class:"multiselect__limit"},{activator:l.withCtx(()=>[l.createVNode(f,null,{default:l.withCtx(()=>[l.createTextVNode(" +"+l.toDisplayString(a.value.length-1),1)],void 0,!0),_:1})]),default:l.withCtx(()=>[l.createElementVNode("div",null,[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(a.value.slice(1),(A,S)=>(l.openBlock(),l.createElementBlock("p",{key:S},l.toDisplayString(o.getOptionLabel({option:A,optionLabel:o.optionLabel})),1))),128))])],void 0,!0),_:1})]),key:"0"},o.showIntersectionObserver?{name:"afterList",fn:l.withCtx(()=>[l.withDirectives(l.createElementVNode("div",cF,null,512),[[C,o.handleAfterListIntersect]])]),key:"1"}:void 0]),1040,["allow-empty","close-on-select","disabled","internal-search","label","model-value","multiple","options","placeholder","taggable","track-by"]),o.isValidation?(l.openBlock(),l.createBlock(y,{key:1,invalid:o.invalid},{default:l.withCtx(()=>[l.createTextVNode(l.toDisplayString(o.validationText),1)],void 0,!0),_:1},8,["invalid"])):l.createCommentVNode("",!0)],2)}const pF=Te(aF,[["render",dF],["__scopeId","data-v-4dc33e91"]]),uF={name:"WtSlider",props:{value:{type:Number,default:0},disabled:{type:Boolean,default:!1},vertical:{type:Boolean,default:!1},min:{type:Number,default:0},max:{type:Number,default:100},step:{type:Number,default:1},height:{type:Number,default:100}},emits:["input"],computed:{progressStyle(){return`linear-gradient(to right, var(--wt-slider-background-completed-color) ${(this.value-this.min)/(this.max-this.min)*100}%, var(--wt-slider-background-color) 0%)`},verticalHeight(){return this.vertical?`${this.height}px`:"100%"}},methods:{inputHandler(o){this.$emit("input",+o.target.value)}}},fF=["disabled","max","min","step","value"];function mF(o,i,a,r,s,c){return l.openBlock(),l.createElementBlock("div",{class:l.normalizeClass([{"wt-slider--disabled":a.disabled,"wt-slider--vertical":a.vertical},"wt-slider"]),style:l.normalizeStyle({height:a.vertical&&c.verticalHeight})},[l.createElementVNode("div",{style:l.normalizeStyle({width:a.vertical&&c.verticalHeight}),class:"wt-slider__wrapper"},[l.createElementVNode("input",{disabled:a.disabled,max:a.max,min:a.min,step:a.step,style:l.normalizeStyle({background:c.progressStyle}),value:a.value,class:"wt-slider__slider",type:"range",onInput:i[0]||(i[0]=(...p)=>c.inputHandler&&c.inputHandler(...p))},null,44,fF)],4)],6)}const hF=Te(uF,[["render",mF],["__scopeId","data-v-d0ff567a"]]),bF=o=>{if(!o)return"00:00:00";let i=`${Math.floor(o/3600)}`,a=`${Math.floor(o%3600/60)}`,r=`${Math.floor(o%3600%60)}`;return i.length===1&&(i=`0${i}`),a.length===1&&(a=`0${a}`),r.length===1&&(r=`0${r}`),`${i}:${a}:${r}`},gF=[{locale:"webitelUI.statusSelect.online",color:"success",value:rn.ONLINE},{locale:"webitelUI.statusSelect.pause",color:"primary",value:rn.PAUSE},{locale:"webitelUI.statusSelect.offline",color:"disabled",value:rn.OFFLINE},{locale:"webitelUI.statusSelect.breakOut",color:"break-out",value:rn.BREAK_OUT}],yF={name:"WtStatusSelect",model:{prop:"status",event:"change"},props:{status:{type:String,default:rn.OFFLINE},statusDuration:{type:[String,Number],default:0},options:{type:Array}},emits:["change","closed"],computed:{selectedOption(){return this.statusOptions.find(o=>o.value===this.status)},statusOptions(){return this.options?this.options:gF.map(o=>({...o,text:this.$t(o.locale)}))},availableOptions(){return this.statusOptions.reduce((o,i)=>this.status===i.value&&i.value!==rn.PAUSE||i.value===rn.BREAK_OUT?o:[...o,i],[])},duration(){return typeof this.statusDuration=="string"?this.statusDuration:this.statusDuration!==void 0?bF(this.statusDuration):this.selectedOption.text}},methods:{inputHandler(o){this.$emit("change",o.value)},closedHandler(o){this.$emit("closed",o)}}};function wF(o,i,a,r,s,c){const p=l.resolveComponent("wt-indicator"),f=l.resolveComponent("wt-select");return l.openBlock(),l.createBlock(f,{clearable:!1,options:c.availableOptions,searchable:!1,value:c.selectedOption,class:"wt-status-select","track-by":"value",onClosed:c.closedHandler,onInput:c.inputHandler},{singleLabel:l.withCtx(({option:h})=>[l.createVNode(p,{color:h.color,text:c.duration},null,8,["color","text"])]),option:l.withCtx(({option:h})=>[l.createVNode(p,{color:h.color,text:h.text},null,8,["color","text"])]),_:1},8,["options","value","onClosed","onInput"])}const vF=Te(yF,[["render",wF],["__scopeId","data-v-03d21c6d"]]),CF={class:"wt-stepper"},kF={class:"wt-stepper-header"},xF={class:"wt-stepper-steps"},_F={class:"wt-stepper-steps__wrapper"},IF={class:"wt-stepper-description"},SF=Te({__name:"wt-stepper",props:{steps:{type:Object},activeStep:{type:Number,default:1}},setup(o){const i=o,a=l.computed(()=>i.steps[i.activeStep-1].description),r=l.computed(()=>i.steps.map((s,c)=>({...s,completed:i.activeStep>c})));return(s,c)=>{const p=l.resolveComponent("wt-chip");return l.openBlock(),l.createElementBlock("div",CF,[l.createElementVNode("div",kF,[l.createElementVNode("div",xF,[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(r.value,({name:f,completed:h},b)=>(l.openBlock(),l.createElementBlock("div",_F,[b!==0?(l.openBlock(),l.createElementBlock("div",{key:0,class:l.normalizeClass([{"wt-stepper-steps__divider--completed":h},"wt-stepper-steps__divider"])},null,2)):l.createCommentVNode("",!0),l.createVNode(p,{color:h?"primary":"secondary",class:"wt-stepper-steps__item"},{default:l.withCtx(()=>[l.createTextVNode(l.toDisplayString(f),1)],void 0,!0),_:2},1032,["color"])]))),256))])]),l.renderSlot(s.$slots,"description",{},()=>[l.createElementVNode("p",IF,l.toDisplayString(a.value),1)],!0),l.renderSlot(s.$slots,"main",{},void 0,!0)])}}},[["__scopeId","data-v-cc8fedd5"]]),AF={name:"WtSwitcher",model:{prop:"value",event:"change"},props:{value:{type:Boolean,default:!1},label:{type:String,default:""},labelLeft:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},labelProps:{type:Object,description:"Object with props, passed down to wt-label as props"}},emits:["change"],methods:{inputHandler(){this.$emit("change",!this.value)}}},TF=["checked","disabled"],EF={key:0,class:"wt-switcher__label"};function DF(o,i,a,r,s,c){const p=l.resolveComponent("wt-label");return l.openBlock(),l.createElementBlock("div",{class:l.normalizeClass([{"wt-switcher--off":!a.value,"wt-switcher--on":a.value,"wt-switcher--disabled":a.disabled},"wt-switcher"])},[l.createVNode(p,l.mergeProps(a.labelProps,{class:[{"wt-switcher__wrapper--label-left":a.labelLeft},"wt-switcher__wrapper"],disabled:a.disabled}),{default:l.withCtx(()=>[l.createElementVNode("input",{checked:a.value,disabled:a.disabled,class:"wt-switcher__input",type:"checkbox",onChange:i[0]||(i[0]=(...f)=>c.inputHandler&&c.inputHandler(...f))},null,40,TF),i[1]||(i[1]=l.createElementVNode("span",{class:"wt-switcher__checkmark"},null,-1)),l.renderSlot(o.$slots,"label",l.normalizeProps(l.guardReactiveProps({label:a.label,value:a.value,disabled:a.disabled})),()=>[a.label?(l.openBlock(),l.createElementBlock("div",EF,l.toDisplayString(a.label),1)):l.createCommentVNode("",!0)],!0)],void 0,!0),_:3},16,["class","disabled"])],2)}const OF=Te(AF,[["render",DF],["__scopeId","data-v-5a56d99f"]]),Va=Object.freeze({ASC:"asc",DESC:"desc",NONE:null}),$4=o=>{switch(o){case Va.ASC:return Va.DESC;case Va.DESC:return Va.NONE;default:return Va.ASC}},RF={name:"WtTable",props:{headers:{type:Array,default:()=>[]},data:{type:Array,default:()=>[]},sortable:{type:Boolean,default:!1},selectable:{type:Boolean,default:!0},selected:{type:Array},gridActions:{type:Boolean,default:!0},fixedActions:{type:Boolean,default:!1},headless:{type:Boolean,default:!1}},emits:["sort","update:selected"],data:()=>({}),computed:{_selected(){return this.selected||this.data.filter(o=>o._isSelected)},isAllSelected(){return this._selected.length===this.data.length&&this.data.length>0},dataHeaders(){return this.headers.filter(o=>o.show===void 0||o.show).map(o=>!o.text&&o.locale?{...o,text:typeof o.locale=="string"?this.$t(o.locale):this.$t(...o.locale)}:o)},columnsStyle(){let o="";this.selectable&&(o+="24px ");const i="minmax(140px, 1fr)";return this.dataHeaders.forEach(a=>{o+=` ${(a.width||i).trim()}`}),this.gridActions&&(o+=" 112px"),`grid-template-columns: ${o}`},isTableFooter(){return Object.keys(this.$slots).some(o=>o.includes("-footer"))}},methods:{sort(o){if(!this.isColSortable(o))return;const i=$4(o.sort);this.$emit("sort",o,i)},isColSortable({sort:o}){return this.sortable&&o!==void 0},selectAll(){this.selected?this.isAllSelected?this.$emit("update:selected",[]):this.$emit("update:selected",[...this.data]):this.isAllSelected?this.data.forEach(o=>{o._isSelected=!1}):this.data.forEach(o=>{o._isSelected=!0})},handleSelection(o,i){this.selected?i?this.$emit("update:selected",[...this._selected,o]):this.$emit("update:selected",this._selected.filter(a=>a!==o)):o._isSelected=!o._isSelected}}},BF={class:"wt-table"},LF={key:0,class:"wt-table__head"},NF={key:0,class:"wt-table__th wt-table__th--checkbox"},PF=["onClick"],qF={class:"wt-table__th__text"},jF={key:1,class:"wt-table__th__actions"},MF={class:"wt-table__body"},$F={key:0,class:"wt-table__td wt-table__td--checkbox"},FF={key:1,class:"wt-table__td__actions"},VF={key:1,class:"wt-table__foot"},UF={key:0,class:"wt-table__th__checkbox"};function zF(o,i,a,r,s,c){const p=l.resolveComponent("wt-checkbox"),f=l.resolveComponent("wt-icon");return l.openBlock(),l.createElementBlock("div",BF,[l.createElementVNode("table",{class:l.normalizeClass(["wt-table__table",{"wt-table__table--fixed-actions":a.fixedActions}])},[a.headless?l.createCommentVNode("",!0):(l.openBlock(),l.createElementBlock("thead",LF,[l.createElementVNode("tr",{style:l.normalizeStyle(c.columnsStyle),class:"wt-table__tr wt-table__tr__head"},[a.selectable?(l.openBlock(),l.createElementBlock("th",NF,[l.createVNode(p,{selected:c.isAllSelected,onChange:c.selectAll},null,8,["selected","onChange"])])):l.createCommentVNode("",!0),(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(c.dataHeaders,(h,b)=>(l.openBlock(),l.createElementBlock("th",{key:b,class:l.normalizeClass([[{"wt-table__th--sortable":c.isColSortable(h)},`wt-table__th--sort-${h.sort}`],"wt-table__th"]),onClick:g=>c.sort(h)},[l.createElementVNode("div",qF,l.toDisplayString(h.text),1),a.sortable?(l.openBlock(),l.createBlock(f,{key:0,class:"wt-table__th__sort-arrow wt-table__th__sort-arrow--asc",icon:"sort-arrow-up",size:"sm"})):l.createCommentVNode("",!0),a.sortable?(l.openBlock(),l.createBlock(f,{key:1,class:"wt-table__th__sort-arrow wt-table__th__sort-arrow--desc",icon:"sort-arrow-down",size:"sm"})):l.createCommentVNode("",!0)],10,PF))),128)),a.gridActions?(l.openBlock(),l.createElementBlock("th",jF,[l.renderSlot(o.$slots,"actions-header",{},void 0,!0)])):l.createCommentVNode("",!0)],4)])),l.createElementVNode("tbody",MF,[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(a.data,(h,b)=>(l.openBlock(),l.createElementBlock("tr",{key:b,class:l.normalizeClass([`wt-table__tr__${h.id||b}`,"wt-table__tr wt-table__tr__body"]),style:l.normalizeStyle(c.columnsStyle)},[a.selectable?(l.openBlock(),l.createElementBlock("td",$F,[l.createVNode(p,{selected:c._selected.includes(h),onChange:g=>c.handleSelection(h,g)},null,8,["selected","onChange"])])):l.createCommentVNode("",!0),(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(c.dataHeaders,(g,w)=>(l.openBlock(),l.createElementBlock("td",{key:w,class:"wt-table__td"},[l.renderSlot(o.$slots,g.value,{index:b,item:h},()=>[l.createElementVNode("div",null,l.toDisplayString(h[g.value]),1)],!0)]))),128)),a.gridActions?(l.openBlock(),l.createElementBlock("td",FF,[l.renderSlot(o.$slots,"actions",{index:b,item:h},void 0,!0)])):l.createCommentVNode("",!0)],6))),128))]),c.isTableFooter?(l.openBlock(),l.createElementBlock("tfoot",VF,[l.createElementVNode("tr",{style:l.normalizeStyle(c.columnsStyle),class:"wt-table__tr wt-table__tr__foot"},[a.selectable?(l.openBlock(),l.createElementBlock("th",UF)):l.createCommentVNode("",!0),(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(c.dataHeaders,(h,b)=>(l.openBlock(),l.createElementBlock("td",{key:b,class:"wt-table__td"},[l.renderSlot(o.$slots,`${h.value}-footer`,{header:h,index:b},void 0,!0)]))),128))],4)])):l.createCommentVNode("",!0)],2)])}const HF=Te(RF,[["render",zF],["__scopeId","data-v-57186150"]]),WF={name:"WtTableActions",props:{icons:{type:Array,default:()=>["refresh"]},isSettingsActive:{type:Boolean,default:!1}},computed:{isImport(){return this.icons.indexOf("import")!==-1},isExport(){return this.icons.indexOf("export")!==-1},isFilterReset(){return this.icons.indexOf("filter-reset")!==-1},isColumnSelect(){return this.icons.indexOf("column-select")!==-1},isRefresh(){return this.icons.indexOf("refresh")!==-1},isSettings(){return this.icons.indexOf("settings")!==-1}}},ZF={class:"wt-table-actions"};function YF(o,i,a,r,s,c){const p=l.resolveComponent("wt-icon-btn"),f=l.resolveComponent("wt-tooltip");return l.openBlock(),l.createElementBlock("aside",ZF,[l.renderSlot(o.$slots,"default",{},void 0,!0),c.isImport?(l.openBlock(),l.createBlock(f,{key:0},{activator:l.withCtx(()=>[l.createVNode(p,{icon:"download",onClick:i[0]||(i[0]=h=>o.$emit("input","import"))})]),default:l.withCtx(()=>[l.createTextVNode(" "+l.toDisplayString(o.$t("reusable.import")),1)],void 0,!0),_:1})):l.createCommentVNode("",!0),c.isExport?(l.openBlock(),l.createBlock(f,{key:1},{activator:l.withCtx(()=>[l.createVNode(p,{icon:"upload",onClick:i[1]||(i[1]=h=>o.$emit("input","export"))})]),default:l.withCtx(()=>[l.createTextVNode(" "+l.toDisplayString(o.$t("reusable.export")),1)],void 0,!0),_:1})):l.createCommentVNode("",!0),c.isFilterReset?(l.openBlock(),l.createBlock(f,{key:2},{activator:l.withCtx(()=>[l.createVNode(p,{icon:"clear",onClick:i[2]||(i[2]=h=>o.$emit("input","filterReset"))})]),default:l.withCtx(()=>[l.createTextVNode(" "+l.toDisplayString(o.$t("webitelUI.tableActions.filterReset")),1)],void 0,!0),_:1})):l.createCommentVNode("",!0),c.isColumnSelect?(l.openBlock(),l.createBlock(f,{key:3},{activator:l.withCtx(()=>[l.createVNode(p,{icon:"column-select",onClick:i[3]||(i[3]=h=>o.$emit("input","columnSelect"))})]),default:l.withCtx(()=>[l.createTextVNode(" "+l.toDisplayString(o.$t("webitelUI.tableActions.columnSelect")),1)],void 0,!0),_:1})):l.createCommentVNode("",!0),c.isRefresh?(l.openBlock(),l.createBlock(f,{key:4},{activator:l.withCtx(()=>[l.createVNode(p,{icon:"refresh",onClick:i[4]||(i[4]=h=>o.$emit("input","refresh"))})]),default:l.withCtx(()=>[l.createTextVNode(" "+l.toDisplayString(o.$t("webitelUI.tableActions.refreshTable")),1)],void 0,!0),_:1})):l.createCommentVNode("",!0),c.isSettings?(l.openBlock(),l.createBlock(f,{key:5},{activator:l.withCtx(()=>[l.createVNode(p,{class:l.normalizeClass({active:a.isSettingsActive}),icon:"filter",onClick:i[5]||(i[5]=h=>o.$emit("input","settings"))},null,8,["class"])]),default:l.withCtx(()=>[l.createTextVNode(" "+l.toDisplayString(o.$t("webitelUI.tableActions.expandFilters")),1)],void 0,!0),_:1})):l.createCommentVNode("",!0)])}const KF=Te(WF,[["render",YF],["__scopeId","data-v-1669a7c8"]]),GF={name:"WtTableColumnSelect",model:{prop:"headers",event:"change"},props:{headers:{type:Array,required:!0,description:"Each header should have following schema: { value: String, show: Boolean, text: String }"},staticHeaders:{type:Array,default:()=>[],description:"Header values to exclude from selection"}},emits:["change"],data:()=>({draft:[],isColumnSelectPopup:!1}),computed:{changeableDraft(){return this.draft.filter(o=>!this.staticHeaders.includes(o.value)).sort((o,i)=>this.shownColLabel(o).localeCompare(this.shownColLabel(i)))}},watch:{isColumnSelectPopup:{handler(){this.fillHeadersDraft()}}},methods:{shownColLabel({text:o,locale:i}){return!o&&i?typeof i=="string"?this.$t(i):this.$t(...i):o},openPopup(){this.isColumnSelectPopup=!0},close(){this.isColumnSelectPopup=!1},fillHeadersDraft(){this.draft=$3(this.headers)},setShownColumns(){this.$emit("change",this.draft),this.close()}}},XF={class:"wt-table-column-select"},QF={class:"wt-table-column-select__popup-list-wrap"},JF=["onClickCapture"];function eV(o,i,a,r,s,c){const p=l.resolveComponent("wt-icon-btn"),f=l.resolveComponent("wt-tooltip"),h=l.resolveComponent("wt-checkbox"),b=l.resolveComponent("wt-button"),g=l.resolveComponent("wt-popup");return l.openBlock(),l.createElementBlock("div",XF,[l.createVNode(f,null,{activator:l.withCtx(()=>[l.createVNode(p,{icon:"column-select",onClick:c.openPopup},null,8,["onClick"])]),default:l.withCtx(()=>[l.createTextVNode(" "+l.toDisplayString(o.$t("webitelUI.tableColumnSelect.title")),1)],void 0,!0),_:1}),l.createVNode(g,{shown:o.isColumnSelectPopup,class:"wt-table-column-select__popup",onClose:c.close},{title:l.withCtx(()=>[l.createTextVNode(l.toDisplayString(o.$t("webitelUI.tableColumnSelect.title")),1)]),main:l.withCtx(()=>[l.createElementVNode("div",QF,[l.createElementVNode("ul",{class:l.normalizeClass([{"wt-table-column-select__popup-list--md":c.changeableDraft.length>10&&c.changeableDraft.length<=20,"wt-table-column-select__popup-list--lg":c.changeableDraft.length>20},"wt-table-column-select__popup-list"])},[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(c.changeableDraft,(w,y)=>(l.openBlock(),l.createElementBlock("li",{key:y,class:"wt-table-column-select__popup-item",onClickCapture:l.withModifiers(C=>w.show=!w.show,["prevent"])},[l.createVNode(h,{label:c.shownColLabel(w),selected:w.show,onChange:C=>w.show=C},null,8,["label","selected","onChange"])],40,JF))),128))],2)])]),actions:l.withCtx(()=>[l.createVNode(b,{onClick:c.setShownColumns},{default:l.withCtx(()=>[l.createTextVNode(l.toDisplayString(o.$t("reusable.add")),1)],void 0,!0),_:1},8,["onClick"]),l.createVNode(b,{color:"secondary",onClick:c.close},{default:l.withCtx(()=>[l.createTextVNode(l.toDisplayString(o.$t("reusable.cancel")),1)],void 0,!0),_:1},8,["onClick"])]),_:1},8,["shown","onClose"])])}const tV=Te(GF,[["render",eV],["__scopeId","data-v-a49bd420"]]),oV={name:"WtTabs",model:{prop:"current",event:"change"},props:{current:{type:Object,default:()=>({})},tabs:{type:Array,default:()=>[]},wide:{type:Boolean,default:!1}},emits:["change"],data:()=>({activeLineWidth:0,activeLineOffset:0}),methods:{open(o){this.$emit("change",o),this.moveActiveLine(o)},moveActiveLine(o){if(!this.current||!this.$refs||!this.$refs[o]||!this.$refs[o][0])return;const i=this.$refs[o][0];this.activeLineWidth=i.clientWidth,this.activeLineOffset=i.offsetLeft}}},iV=["value","onClick"],nV={style:{display:"block"}},aV={class:"wt-tabs__underline"};function rV(o,i,a,r,s,c){return l.openBlock(),l.createElementBlock("nav",{class:l.normalizeClass([{"wt-tabs--wide":a.wide},"wt-tabs"])},[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(a.tabs,p=>(l.openBlock(),l.createElementBlock("button",{key:p.value,class:l.normalizeClass([{"wt-tab--highlight":p.value===a.current.value},"wt-tab"]),value:p.text,type:"button",onClick:f=>c.open(p)},[l.renderSlot(o.$slots,p.value,l.mergeProps({tab:p,current:a.current},{ref_for:!0}),()=>[l.createElementVNode("span",nV,l.toDisplayString(p.text),1)],!0)],10,iV))),128)),l.createElementVNode("div",aV,[l.createElementVNode("div",{style:l.normalizeStyle({width:`${o.activeLineWidth}px`,transform:`translateX(${o.activeLineOffset}px)`}),class:"wt-tab__underline--highlight"},null,4)])],2)}const lV=Te(oV,[["render",rV],["__scopeId","data-v-4303aef8"]]);var Y0,F4;function V4(){if(F4)return Y0;F4=1;var o=Object.prototype.toString;return Y0=function(a){var r=o.call(a),s=r==="[object Arguments]";return s||(s=r!=="[object Array]"&&a!==null&&typeof a=="object"&&typeof a.length=="number"&&a.length>=0&&o.call(a.callee)==="[object Function]"),s},Y0}var K0,U4;function sV(){if(U4)return K0;U4=1;var o;if(!Object.keys){var i=Object.prototype.hasOwnProperty,a=Object.prototype.toString,r=V4(),s=Object.prototype.propertyIsEnumerable,c=!s.call({toString:null},"toString"),p=s.call(function(){},"prototype"),f=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],h=function(y){var C=y.constructor;return C&&C.prototype===y},b={$applicationCache:!0,$console:!0,$external:!0,$frame:!0,$frameElement:!0,$frames:!0,$innerHeight:!0,$innerWidth:!0,$onmozfullscreenchange:!0,$onmozfullscreenerror:!0,$outerHeight:!0,$outerWidth:!0,$pageXOffset:!0,$pageYOffset:!0,$parent:!0,$scrollLeft:!0,$scrollTop:!0,$scrollX:!0,$scrollY:!0,$self:!0,$webkitIndexedDB:!0,$webkitStorageInfo:!0,$window:!0},g=function(){if(typeof window>"u")return!1;for(var y in window)try{if(!b["$"+y]&&i.call(window,y)&&window[y]!==null&&typeof window[y]=="object")try{h(window[y])}catch{return!0}}catch{return!0}return!1}(),w=function(y){if(typeof window>"u"||!g)return h(y);try{return h(y)}catch{return!1}};o=function(C){var A=C!==null&&typeof C=="object",S=a.call(C)==="[object Function]",I=r(C),_=A&&a.call(C)==="[object String]",k=[];if(!A&&!S&&!I)throw new TypeError("Object.keys called on a non-object");var E=p&&S;if(_&&C.length>0&&!i.call(C,0))for(var T=0;T<C.length;++T)k.push(String(T));if(I&&C.length>0)for(var D=0;D<C.length;++D)k.push(String(D));else for(var q in C)!(E&&q==="prototype")&&i.call(C,q)&&k.push(String(q));if(c)for(var R=w(C),M=0;M<f.length;++M)!(R&&f[M]==="constructor")&&i.call(C,f[M])&&k.push(f[M]);return k}}return K0=o,K0}var G0,z4;function X0(){if(z4)return G0;z4=1;var o=Array.prototype.slice,i=V4(),a=Object.keys,r=a?function(p){return a(p)}:sV(),s=Object.keys;return r.shim=function(){if(Object.keys){var p=function(){var f=Object.keys(arguments);return f&&f.length===arguments.length}(1,2);p||(Object.keys=function(h){return i(h)?s(o.call(h)):s(h)})}else Object.keys=r;return Object.keys||r},G0=r,G0}var Q0,H4;function J0(){if(H4)return Q0;H4=1;var o=Xr(),i=rc(),a=xo(),r=en();return Q0=function(c,p,f){if(!c||typeof c!="object"&&typeof c!="function")throw new a("`obj` must be an object or a function`");if(typeof p!="string"&&typeof p!="symbol")throw new a("`property` must be a string or a symbol`");if(arguments.length>3&&typeof arguments[3]!="boolean"&&arguments[3]!==null)throw new a("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&typeof arguments[4]!="boolean"&&arguments[4]!==null)throw new a("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&typeof arguments[5]!="boolean"&&arguments[5]!==null)throw new a("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&typeof arguments[6]!="boolean")throw new a("`loose`, if provided, must be a boolean");var h=arguments.length>3?arguments[3]:null,b=arguments.length>4?arguments[4]:null,g=arguments.length>5?arguments[5]:null,w=arguments.length>6?arguments[6]:!1,y=!!r&&r(c,p);if(o)o(c,p,{configurable:g===null&&y?y.configurable:!g,enumerable:h===null&&y?y.enumerable:!h,value:f,writable:b===null&&y?y.writable:!b});else if(w||!h&&!b&&!g)c[p]=f;else throw new i("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.")},Q0}var ep,W4;function tp(){if(W4)return ep;W4=1;var o=Xr(),i=function(){return!!o};return i.hasArrayLengthDefineBug=function(){if(!o)return null;try{return o([],"length",{value:1}).length!==1}catch{return!0}},ep=i,ep}var op,Z4;function yn(){if(Z4)return op;Z4=1;var o=X0(),i=typeof Symbol=="function"&&typeof Symbol("foo")=="symbol",a=Object.prototype.toString,r=Array.prototype.concat,s=J0(),c=function(b){return typeof b=="function"&&a.call(b)==="[object Function]"},p=tp()(),f=function(b,g,w,y){if(g in b){if(y===!0){if(b[g]===w)return}else if(!c(y)||!y())return}p?s(b,g,w,!0):s(b,g,w)},h=function(b,g){var w=arguments.length>2?arguments[2]:{},y=o(g);i&&(y=r.call(y,Object.getOwnPropertySymbols(g)));for(var C=0;C<y.length;C+=1)f(b,y[C],g[y[C]],w[y[C]])};return h.supportsDescriptors=!!p,op=h,op}var ip={exports:{}},np,Y4;function cV(){if(Y4)return np;Y4=1;var o=fi(),i=J0(),a=tp()(),r=en(),s=xo(),c=o("%Math.floor%");return np=function(f,h){if(typeof f!="function")throw new s("`fn` is not a function");if(typeof h!="number"||h<0||h>4294967295||c(h)!==h)throw new s("`length` must be a positive 32-bit integer");var b=arguments.length>2&&!!arguments[2],g=!0,w=!0;if("length"in f&&r){var y=r(f,"length");y&&!y.configurable&&(g=!1),y&&!y.writable&&(w=!1)}return(g||w||!b)&&(a?i(f,"length",h,!0,!0):i(f,"length",h)),f},np}var ap,K4;function dV(){if(K4)return ap;K4=1;var o=ma(),i=Ec(),a=t3();return ap=function(){return a(o,i,arguments)},ap}var G4;function zn(){return G4||(G4=1,function(o){var i=cV(),a=Xr(),r=Bc(),s=dV();o.exports=function(p){var f=r(arguments),h=p.length-(arguments.length-1);return i(f,1+(h>0?h:0),!0)},a?a(o.exports,"apply",{value:s}):o.exports.apply=s}(ip)),ip.exports}var rp,X4;function Q4(){if(X4)return rp;X4=1;var o=X0(),i=Qr()(),a=Jt(),r=ec(),s=a("Array.prototype.push"),c=a("Object.prototype.propertyIsEnumerable"),p=i?r.getOwnPropertySymbols:null;return rp=function(h,b){if(h==null)throw new TypeError("target must be an object");var g=r(h);if(arguments.length===1)return g;for(var w=1;w<arguments.length;++w){var y=r(arguments[w]),C=o(y),A=i&&(r.getOwnPropertySymbols||p);if(A)for(var S=A(y),I=0;I<S.length;++I){var _=S[I];c(y,_)&&s(C,_)}for(var k=0;k<C.length;++k){var E=C[k];if(c(y,E)){var T=y[E];g[E]=T}}}return g},rp}var lp,J4;function e5(){if(J4)return lp;J4=1;var o=Q4(),i=function(){if(!Object.assign)return!1;for(var r="abcdefghijklmnopqrst",s=r.split(""),c={},p=0;p<s.length;++p)c[s[p]]=s[p];var f=Object.assign({},c),h="";for(var b in f)h+=b;return r!==h},a=function(){if(!Object.assign||!Object.preventExtensions)return!1;var r=Object.preventExtensions({1:2});try{Object.assign(r,"xy")}catch{return r[1]==="y"}return!1};return lp=function(){return!Object.assign||i()||a()?o:Object.assign},lp}var sp,t5;function pV(){if(t5)return sp;t5=1;var o=yn(),i=e5();return sp=function(){var r=i();return o(Object,{assign:r},{assign:function(){return Object.assign!==r}}),r},sp}var cp,o5;function uV(){if(o5)return cp;o5=1;var o=yn(),i=zn(),a=Q4(),r=e5(),s=pV(),c=i.apply(r()),p=function(h,b){return c(Object,arguments)};return o(p,{getPolyfill:r,implementation:a,shim:s}),cp=p,cp}var dp,i5;function n5(){if(i5)return dp;i5=1;var o=fi(),i=zn(),a=i(o("String.prototype.indexOf"));return dp=function(s,c){var p=o(s,!!c);return typeof p=="function"&&a(s,".prototype.")>-1?i(p):p},dp}var pp,a5;function fV(){if(a5)return pp;a5=1;var o=function(){return typeof(function(){}).name=="string"},i=Object.getOwnPropertyDescriptor;if(i)try{i([],"length")}catch{i=null}o.functionsHaveConfigurableNames=function(){if(!o()||!i)return!1;var s=i(function(){},"name");return!!s&&!!s.configurable};var a=Function.prototype.bind;return o.boundFunctionsHaveNames=function(){return o()&&typeof a=="function"&&(function(){}).bind().name!==""},pp=o,pp}var up,r5;function mV(){if(r5)return up;r5=1;var o=J0(),i=tp()(),a=fV().functionsHaveConfigurableNames(),r=xo();return up=function(c,p){if(typeof c!="function")throw new r("`fn` is not a function");var f=arguments.length>2&&!!arguments[2];return(!f||a)&&(i?o(c,"name",p,!0,!0):o(c,"name",p)),c},up}var fp,l5;function s5(){if(l5)return fp;l5=1;var o=mV(),i=xo(),a=Object;return fp=o(function(){if(this==null||this!==a(this))throw new i("RegExp.prototype.flags getter called on non-object");var s="";return this.hasIndices&&(s+="d"),this.global&&(s+="g"),this.ignoreCase&&(s+="i"),this.multiline&&(s+="m"),this.dotAll&&(s+="s"),this.unicode&&(s+="u"),this.unicodeSets&&(s+="v"),this.sticky&&(s+="y"),s},"get flags",!0),fp}var mp,c5;function d5(){if(c5)return mp;c5=1;var o=s5(),i=yn().supportsDescriptors,a=Object.getOwnPropertyDescriptor;return mp=function(){if(i&&/a/mig.flags==="gim"){var s=a(RegExp.prototype,"flags");if(s&&typeof s.get=="function"&&"dotAll"in RegExp.prototype&&"hasIndices"in RegExp.prototype){var c="",p={};if(Object.defineProperty(p,"hasIndices",{get:function(){c+="d"}}),Object.defineProperty(p,"sticky",{get:function(){c+="y"}}),s.get.call(p),c==="dy")return s.get}}return o},mp}var hp,p5;function hV(){if(p5)return hp;p5=1;var o=yn().supportsDescriptors,i=d5(),a=en(),r=Object.defineProperty,s=Sf(),c=Pc(),p=/a/;return hp=function(){if(!o||!c)throw new s("RegExp.prototype.flags requires a true ES5 environment that supports property descriptors");var h=i(),b=c(p),g=a(b,"flags");return(!g||g.get!==h)&&r(b,"flags",{configurable:!0,enumerable:!1,get:h}),h},hp}var bp,u5;function bV(){if(u5)return bp;u5=1;var o=yn(),i=zn(),a=s5(),r=d5(),s=hV(),c=i(r());return o(c,{getPolyfill:r,implementation:a,shim:s}),bp=c,bp}var Ua={exports:{}},gp,f5;function wn(){if(f5)return gp;f5=1;var o=Qr();return gp=function(){return o()&&!!Symbol.toStringTag},gp}var yp,m5;function h5(){if(m5)return yp;m5=1;var o=wn()(),i=Jt(),a=i("Object.prototype.toString"),r=function(f){return o&&f&&typeof f=="object"&&Symbol.toStringTag in f?!1:a(f)==="[object Arguments]"},s=function(f){return r(f)?!0:f!==null&&typeof f=="object"&&"length"in f&&typeof f.length=="number"&&f.length>=0&&a(f)!=="[object Array]"&&"callee"in f&&a(f.callee)==="[object Function]"},c=function(){return r(arguments)}();return r.isLegacyArguments=s,yp=c?r:s,yp}var wp,b5;function gV(){if(b5)return wp;b5=1;var o=jc(),i=zc()(),a=xo(),r={assert:function(s,c){if(!s||typeof s!="object"&&typeof s!="function")throw new a("`O` is not an object");if(typeof c!="string")throw new a("`slot` must be a string");if(i.assert(s),!r.has(s,c))throw new a("`"+c+"` is not present on `O`")},get:function(s,c){if(!s||typeof s!="object"&&typeof s!="function")throw new a("`O` is not an object");if(typeof c!="string")throw new a("`slot` must be a string");var p=i.get(s);return p&&p["$"+c]},has:function(s,c){if(!s||typeof s!="object"&&typeof s!="function")throw new a("`O` is not an object");if(typeof c!="string")throw new a("`slot` must be a string");var p=i.get(s);return!!p&&o(p,"$"+c)},set:function(s,c,p){if(!s||typeof s!="object"&&typeof s!="function")throw new a("`O` is not an object");if(typeof c!="string")throw new a("`slot` must be a string");var f=i.get(s);f||(f={},i.set(s,f)),f["$"+c]=p}};return Object.freeze&&Object.freeze(r),wp=r,wp}var vp,g5;function yV(){if(g5)return vp;g5=1;var o=gV(),i=rc(),a=typeof StopIteration=="object"?StopIteration:null;return vp=function(s){if(!a)throw new i("this environment lacks StopIteration");o.set(s,"[[Done]]",!1);var c={next:function(){var f=o.get(this,"[[Iterator]]"),h=!!o.get(f,"[[Done]]");try{return{done:h,value:h?void 0:f.next()}}catch(b){if(o.set(f,"[[Done]]",!0),b!==a)throw b;return{done:!0,value:void 0}}}};return o.set(c,"[[Iterator]]",s),c},vp}var Cp,y5;function w5(){if(y5)return Cp;y5=1;var o={}.toString;return Cp=Array.isArray||function(i){return o.call(i)=="[object Array]"},Cp}var kp,v5;function C5(){if(v5)return kp;v5=1;var o=Jt(),i=o("String.prototype.valueOf"),a=function(f){try{return i(f),!0}catch{return!1}},r=o("Object.prototype.toString"),s="[object String]",c=wn()();return kp=function(f){return typeof f=="string"?!0:!f||typeof f!="object"?!1:c?a(f):r(f)===s},kp}var xp,k5;function x5(){if(k5)return xp;k5=1;var o=typeof Map=="function"&&Map.prototype?Map:null,i=typeof Set=="function"&&Set.prototype?Set:null,a;o||(a=function(p){return!1});var r=o?Map.prototype.has:null,s=i?Set.prototype.has:null;return!a&&!r&&(a=function(p){return!1}),xp=a||function(p){if(!p||typeof p!="object")return!1;try{if(r.call(p),s)try{s.call(p)}catch{return!0}return p instanceof o}catch{}return!1},xp}var _p,_5;function I5(){if(_5)return _p;_5=1;var o=typeof Map=="function"&&Map.prototype?Map:null,i=typeof Set=="function"&&Set.prototype?Set:null,a;i||(a=function(p){return!1});var r=o?Map.prototype.has:null,s=i?Set.prototype.has:null;return!a&&!s&&(a=function(p){return!1}),_p=a||function(p){if(!p||typeof p!="object")return!1;try{if(s.call(p),r)try{r.call(p)}catch{return!0}return p instanceof i}catch{}return!1},_p}var S5;function wV(){if(S5)return Ua.exports;S5=1;var o=h5(),i=yV();if(Cc()()||Qr()()){var a=Symbol.iterator;Ua.exports=function($){if($!=null&&typeof $[a]<"u")return $[a]();if(o($))return Array.prototype[a].call($)}}else{var r=w5(),s=C5(),c=fi(),p=c("%Map%",!0),f=c("%Set%",!0),h=n5(),b=h("Array.prototype.push"),g=h("String.prototype.charCodeAt"),w=h("String.prototype.slice"),y=function($,Q){var z=$.length;if(Q+1>=z)return Q+1;var W=g($,Q);if(W<55296||W>56319)return Q+1;var ie=g($,Q+1);return ie<56320||ie>57343?Q+1:Q+2},C=function($){var Q=0;return{next:function(){var W=Q>=$.length,ie;return W||(ie=$[Q],Q+=1),{done:W,value:ie}}}},A=function($,Q){if(r($)||o($))return C($);if(s($)){var z=0;return{next:function(){var ie=y($,z),de=w($,z,ie);return z=ie,{done:ie>$.length,value:de}}}}if(Q&&typeof $["_es6-shim iterator_"]<"u")return $["_es6-shim iterator_"]()};if(!p&&!f)Ua.exports=function($){if($!=null)return A($,!0)};else{var S=x5(),I=I5(),_=h("Map.prototype.forEach",!0),k=h("Set.prototype.forEach",!0);if(typeof $e>"u"||!$e.versions||!$e.versions.node)var E=h("Map.prototype.iterator",!0),T=h("Set.prototype.iterator",!0);var D=h("Map.prototype.@@iterator",!0)||h("Map.prototype._es6-shim iterator_",!0),q=h("Set.prototype.@@iterator",!0)||h("Set.prototype._es6-shim iterator_",!0),R=function($){if(S($)){if(E)return i(E($));if(D)return D($);if(_){var Q=[];return _($,function(W,ie){b(Q,[ie,W])}),C(Q)}}if(I($)){if(T)return i(T($));if(q)return q($);if(k){var z=[];return k($,function(W){b(z,W)}),C(z)}}};Ua.exports=function($){return R($)||A($)}}}return Ua.exports}var Ip,A5;function T5(){if(A5)return Ip;A5=1;var o=function(i){return i!==i};return Ip=function(a,r){return a===0&&r===0?1/a===1/r:!!(a===r||o(a)&&o(r))},Ip}var Sp,E5;function D5(){if(E5)return Sp;E5=1;var o=T5();return Sp=function(){return typeof Object.is=="function"?Object.is:o},Sp}var Ap,O5;function vV(){if(O5)return Ap;O5=1;var o=D5(),i=yn();return Ap=function(){var r=o();return i(Object,{is:r},{is:function(){return Object.is!==r}}),r},Ap}var Tp,R5;function CV(){if(R5)return Tp;R5=1;var o=yn(),i=zn(),a=T5(),r=D5(),s=vV(),c=i(r(),Object);return o(c,{getPolyfill:r,implementation:a,shim:s}),Tp=c,Tp}var Ep,B5;function L5(){if(B5)return Ep;B5=1;var o=zn(),i=Jt(),a=fi(),r=a("%ArrayBuffer%",!0),s=i("ArrayBuffer.prototype.byteLength",!0),c=i("Object.prototype.toString"),p=!!r&&!s&&new r(0).slice,f=!!p&&o(p);return Ep=s||f?function(b){if(!b||typeof b!="object")return!1;try{return s?s(b):f(b,0),!0}catch{return!1}}:r?function(b){return c(b)==="[object ArrayBuffer]"}:function(b){return!1},Ep}var Dp,N5;function kV(){if(N5)return Dp;N5=1;var o=Jt(),i=o("Date.prototype.getDay"),a=function(f){try{return i(f),!0}catch{return!1}},r=o("Object.prototype.toString"),s="[object Date]",c=wn()();return Dp=function(f){return typeof f!="object"||f===null?!1:c?a(f):r(f)===s},Dp}var Op,P5;function q5(){if(P5)return Op;P5=1;var o=Jt(),i=wn()(),a=jc(),r=en(),s;if(i){var c=o("RegExp.prototype.exec"),p={},f=function(){throw p},h={toString:f,valueOf:f};typeof Symbol.toPrimitive=="symbol"&&(h[Symbol.toPrimitive]=f),s=function(y){if(!y||typeof y!="object")return!1;var C=r(y,"lastIndex"),A=C&&a(C,"value");if(!A)return!1;try{c(y,h)}catch(S){return S===p}}}else{var b=o("Object.prototype.toString"),g="[object RegExp]";s=function(y){return!y||typeof y!="object"&&typeof y!="function"?!1:b(y)===g}}return Op=s,Op}var Rp,j5;function xV(){if(j5)return Rp;j5=1;var o=Jt(),i=o("SharedArrayBuffer.prototype.byteLength",!0);return Rp=i?function(r){if(!r||typeof r!="object")return!1;try{return i(r),!0}catch{return!1}}:function(r){return!1},Rp}var Bp,M5;function _V(){if(M5)return Bp;M5=1;var o=Jt(),i=o("Number.prototype.toString"),a=function(f){try{return i(f),!0}catch{return!1}},r=o("Object.prototype.toString"),s="[object Number]",c=wn()();return Bp=function(f){return typeof f=="number"?!0:!f||typeof f!="object"?!1:c?a(f):r(f)===s},Bp}var Lp,$5;function IV(){if($5)return Lp;$5=1;var o=Jt(),i=o("Boolean.prototype.toString"),a=o("Object.prototype.toString"),r=function(f){try{return i(f),!0}catch{return!1}},s="[object Boolean]",c=wn()();return Lp=function(f){return typeof f=="boolean"?!0:f===null||typeof f!="object"?!1:c?r(f):a(f)===s},Lp}var Tl={exports:{}},Np,F5;function SV(){if(F5)return Np;F5=1;var o=Jt(),i=q5(),a=o("RegExp.prototype.exec"),r=xo();return Np=function(c){if(!i(c))throw new r("`regex` must be a RegExp");return function(f){return a(c,f)!==null}},Np}var V5;function AV(){if(V5)return Tl.exports;V5=1;var o=Jt(),i=o("Object.prototype.toString"),a=Cc()(),r=SV();if(a){var s=o("Symbol.prototype.toString"),c=r(/^Symbol\(.*\)$/),p=function(h){return typeof h.valueOf()!="symbol"?!1:c(s(h))};Tl.exports=function(h){if(typeof h=="symbol")return!0;if(!h||typeof h!="object"||i(h)!=="[object Symbol]")return!1;try{return p(h)}catch{return!1}}}else Tl.exports=function(h){return!1};return Tl.exports}var El={exports:{}},Pp,U5;function TV(){if(U5)return Pp;U5=1;var o=typeof BigInt<"u"&&BigInt;return Pp=function(){return typeof o=="function"&&typeof BigInt=="function"&&typeof o(42)=="bigint"&&typeof BigInt(42)=="bigint"},Pp}var z5;function EV(){if(z5)return El.exports;z5=1;var o=TV()();if(o){var i=BigInt.prototype.valueOf,a=function(s){try{return i.call(s),!0}catch{}return!1};El.exports=function(s){return s===null||typeof s>"u"||typeof s=="boolean"||typeof s=="string"||typeof s=="number"||typeof s=="symbol"||typeof s=="function"?!1:typeof s=="bigint"?!0:a(s)}}else El.exports=function(s){return!1};return El.exports}var qp,H5;function DV(){if(H5)return qp;H5=1;var o=C5(),i=_V(),a=IV(),r=AV(),s=EV();return qp=function(p){if(p==null||typeof p!="object"&&typeof p!="function")return null;if(o(p))return"String";if(i(p))return"Number";if(a(p))return"Boolean";if(r(p))return"Symbol";if(s(p))return"BigInt"},qp}var jp,W5;function OV(){if(W5)return jp;W5=1;var o=typeof WeakMap=="function"&&WeakMap.prototype?WeakMap:null,i=typeof WeakSet=="function"&&WeakSet.prototype?WeakSet:null,a;o||(a=function(p){return!1});var r=o?o.prototype.has:null,s=i?i.prototype.has:null;return!a&&!r&&(a=function(p){return!1}),jp=a||function(p){if(!p||typeof p!="object")return!1;try{if(r.call(p,r),s)try{s.call(p,s)}catch{return!0}return p instanceof o}catch{}return!1},jp}var Dl={exports:{}},Z5;function RV(){if(Z5)return Dl.exports;Z5=1;var o=fi(),i=Jt(),a=o("%WeakSet%",!0),r=i("WeakSet.prototype.has",!0);if(r){var s=i("WeakMap.prototype.has",!0);Dl.exports=function(p){if(!p||typeof p!="object")return!1;try{if(r(p,r),s)try{s(p,s)}catch{return!0}return p instanceof a}catch{}return!1}}else Dl.exports=function(p){return!1};return Dl.exports}var Mp,Y5;function BV(){if(Y5)return Mp;Y5=1;var o=x5(),i=I5(),a=OV(),r=RV();return Mp=function(c){if(c&&typeof c=="object"){if(o(c))return"Map";if(i(c))return"Set";if(a(c))return"WeakMap";if(r(c))return"WeakSet"}return!1},Mp}var $p,K5;function LV(){if(K5)return $p;K5=1;var o=Function.prototype.toString,i=typeof Reflect=="object"&&Reflect!==null&&Reflect.apply,a,r;if(typeof i=="function"&&typeof Object.defineProperty=="function")try{a=Object.defineProperty({},"length",{get:function(){throw r}}),r={},i(function(){throw 42},null,a)}catch(k){k!==r&&(i=null)}else i=null;var s=/^\s*class\b/,c=function(E){try{var T=o.call(E);return s.test(T)}catch{return!1}},p=function(E){try{return c(E)?!1:(o.call(E),!0)}catch{return!1}},f=Object.prototype.toString,h="[object Object]",b="[object Function]",g="[object GeneratorFunction]",w="[object HTMLAllCollection]",y="[object HTML document.all class]",C="[object HTMLCollection]",A=typeof Symbol=="function"&&!!Symbol.toStringTag,S=!(0 in[,]),I=function(){return!1};if(typeof document=="object"){var _=document.all;f.call(_)===f.call(document.all)&&(I=function(E){if((S||!E)&&(typeof E>"u"||typeof E=="object"))try{var T=f.call(E);return(T===w||T===y||T===C||T===h)&&E("")==null}catch{}return!1})}return $p=i?function(E){if(I(E))return!0;if(!E||typeof E!="function"&&typeof E!="object")return!1;try{i(E,null,a)}catch(T){if(T!==r)return!1}return!c(E)&&p(E)}:function(E){if(I(E))return!0;if(!E||typeof E!="function"&&typeof E!="object")return!1;if(A)return p(E);if(c(E))return!1;var T=f.call(E);return T!==b&&T!==g&&!/^\[object HTML/.test(T)?!1:p(E)},$p}var Fp,G5;function NV(){if(G5)return Fp;G5=1;var o=LV(),i=Object.prototype.toString,a=Object.prototype.hasOwnProperty,r=function(h,b,g){for(var w=0,y=h.length;w<y;w++)a.call(h,w)&&(g==null?b(h[w],w,h):b.call(g,h[w],w,h))},s=function(h,b,g){for(var w=0,y=h.length;w<y;w++)g==null?b(h.charAt(w),w,h):b.call(g,h.charAt(w),w,h)},c=function(h,b,g){for(var w in h)a.call(h,w)&&(g==null?b(h[w],w,h):b.call(g,h[w],w,h))};function p(f){return i.call(f)==="[object Array]"}return Fp=function(h,b,g){if(!o(b))throw new TypeError("iterator must be a function");var w;arguments.length>=3&&(w=g),p(h)?r(h,b,w):typeof h=="string"?s(h,b,w):c(h,b,w)},Fp}var Vp,X5;function PV(){return X5||(X5=1,Vp=["Float16Array","Float32Array","Float64Array","Int8Array","Int16Array","Int32Array","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","BigInt64Array","BigUint64Array"]),Vp}var Up,Q5;function qV(){if(Q5)return Up;Q5=1;var o=PV(),i=typeof globalThis>"u"?zo:globalThis;return Up=function(){for(var r=[],s=0;s<o.length;s++)typeof i[o[s]]=="function"&&(r[r.length]=o[s]);return r},Up}var zp,J5;function jV(){if(J5)return zp;J5=1;var o=NV(),i=qV(),a=zn(),r=Jt(),s=en(),c=Pc(),p=r("Object.prototype.toString"),f=wn()(),h=typeof globalThis>"u"?zo:globalThis,b=i(),g=r("String.prototype.slice"),w=r("Array.prototype.indexOf",!0)||function(I,_){for(var k=0;k<I.length;k+=1)if(I[k]===_)return k;return-1},y={__proto__:null};f&&s&&c?o(b,function(S){var I=new h[S];if(Symbol.toStringTag in I&&c){var _=c(I),k=s(_,Symbol.toStringTag);if(!k&&_){var E=c(_);k=s(E,Symbol.toStringTag)}y["$"+S]=a(k.get)}}):o(b,function(S){var I=new h[S],_=I.slice||I.set;_&&(y["$"+S]=a(_))});var C=function(I){var _=!1;return o(y,function(k,E){if(!_)try{"$"+k(I)===E&&(_=g(E,1))}catch{}}),_},A=function(I){var _=!1;return o(y,function(k,E){if(!_)try{k(I),_=g(E,1)}catch{}}),_};return zp=function(I){if(!I||typeof I!="object")return!1;if(!f){var _=g(p(I),8,-1);return w(b,_)>-1?_:_!=="Object"?!1:A(I)}return s?C(I):null},zp}var Hp,eb;function MV(){if(eb)return Hp;eb=1;var o=Jt(),i=o("ArrayBuffer.prototype.byteLength",!0),a=L5();return Hp=function(s){return a(s)?i?i(s):s.byteLength:NaN},Hp}var Wp,tb;function $V(){if(tb)return Wp;tb=1;var o=uV(),i=n5(),a=bV(),r=fi(),s=wV(),c=zc(),p=CV(),f=h5(),h=w5(),b=L5(),g=kV(),w=q5(),y=xV(),C=X0(),A=DV(),S=BV(),I=jV(),_=MV(),k=i("SharedArrayBuffer.prototype.byteLength",!0),E=i("Date.prototype.getTime"),T=Object.getPrototypeOf,D=i("Object.prototype.toString"),q=r("%Set%",!0),R=i("Map.prototype.has",!0),M=i("Map.prototype.get",!0),$=i("Map.prototype.size",!0),Q=i("Set.prototype.add",!0),z=i("Set.prototype.delete",!0),W=i("Set.prototype.has",!0),ie=i("Set.prototype.size",!0);function de(B,H,ue,me){for(var we=s(B),_e;(_e=we.next())&&!_e.done;)if(F(H,_e.value,ue,me))return z(B,_e.value),!0;return!1}function be(B){if(typeof B>"u")return null;if(typeof B!="object")return typeof B=="symbol"?!1:typeof B=="string"||typeof B=="number"?+B==+B:!0}function re(B,H,ue,me,we,_e){var Ce=be(ue);if(Ce!=null)return Ce;var pe=M(H,Ce),ve=o({},we,{strict:!1});return typeof pe>"u"&&!R(H,Ce)||!F(me,pe,ve,_e)?!1:!R(B,Ce)&&F(me,pe,ve,_e)}function L(B,H,ue){var me=be(ue);return me??(W(H,me)&&!W(B,me))}function X(B,H,ue,me,we,_e){for(var Ce=s(B),pe,ve;(pe=Ce.next())&&!pe.done;)if(ve=pe.value,F(ue,ve,we,_e)&&F(me,M(H,ve),we,_e))return z(B,ve),!0;return!1}function F(B,H,ue,me){var we=ue||{};if(we.strict?p(B,H):B===H)return!0;var _e=A(B),Ce=A(H);if(_e!==Ce)return!1;if(!B||!H||typeof B!="object"&&typeof H!="object")return we.strict?p(B,H):B==H;var pe=me.has(B),ve=me.has(H),Ae;if(pe&&ve){if(me.get(B)===me.get(H))return!0}else Ae={};return pe||me.set(B,Ae),ve||me.set(H,Ae),ne(B,H,we,me)}function Y(B){return!B||typeof B!="object"||typeof B.length!="number"||typeof B.copy!="function"||typeof B.slice!="function"||B.length>0&&typeof B[0]!="number"?!1:!!(B.constructor&&B.constructor.isBuffer&&B.constructor.isBuffer(B))}function te(B,H,ue,me){if(ie(B)!==ie(H))return!1;for(var we=s(B),_e=s(H),Ce,pe,ve;(Ce=we.next())&&!Ce.done;)if(Ce.value&&typeof Ce.value=="object")ve||(ve=new q),Q(ve,Ce.value);else if(!W(H,Ce.value)){if(ue.strict||!L(B,H,Ce.value))return!1;ve||(ve=new q),Q(ve,Ce.value)}if(ve){for(;(pe=_e.next())&&!pe.done;)if(pe.value&&typeof pe.value=="object"){if(!de(ve,pe.value,ue.strict,me))return!1}else if(!ue.strict&&!W(B,pe.value)&&!de(ve,pe.value,ue.strict,me))return!1;return ie(ve)===0}return!0}function ce(B,H,ue,me){if($(B)!==$(H))return!1;for(var we=s(B),_e=s(H),Ce,pe,ve,Ae,Le,je;(Ce=we.next())&&!Ce.done;)if(Ae=Ce.value[0],Le=Ce.value[1],Ae&&typeof Ae=="object")ve||(ve=new q),Q(ve,Ae);else if(je=M(H,Ae),typeof je>"u"&&!R(H,Ae)||!F(Le,je,ue,me)){if(ue.strict||!re(B,H,Ae,Le,ue,me))return!1;ve||(ve=new q),Q(ve,Ae)}if(ve){for(;(pe=_e.next())&&!pe.done;)if(Ae=pe.value[0],je=pe.value[1],Ae&&typeof Ae=="object"){if(!X(ve,B,Ae,je,ue,me))return!1}else if(!ue.strict&&(!B.has(Ae)||!F(M(B,Ae),je,ue,me))&&!X(ve,B,Ae,je,o({},ue,{strict:!1}),me))return!1;return ie(ve)===0}return!0}function ne(B,H,ue,me){var we,_e;if(typeof B!=typeof H||B==null||H==null||D(B)!==D(H)||f(B)!==f(H))return!1;var Ce=h(B),pe=h(H);if(Ce!==pe)return!1;var ve=B instanceof Error,Ae=H instanceof Error;if(ve!==Ae||(ve||Ae)&&(B.name!==H.name||B.message!==H.message))return!1;var Le=w(B),je=w(H);if(Le!==je||(Le||je)&&(B.source!==H.source||a(B)!==a(H)))return!1;var ke=g(B),Pe=g(H);if(ke!==Pe||(ke||Pe)&&E(B)!==E(H)||ue.strict&&T&&T(B)!==T(H))return!1;var Z=I(B),J=I(H);if(Z!==J)return!1;if(Z||J){if(B.length!==H.length)return!1;for(we=0;we<B.length;we++)if(B[we]!==H[we])return!1;return!0}var se=Y(B),Ie=Y(H);if(se!==Ie)return!1;if(se||Ie){if(B.length!==H.length)return!1;for(we=0;we<B.length;we++)if(B[we]!==H[we])return!1;return!0}var Je=b(B),Xe=b(H);if(Je!==Xe)return!1;if(Je||Xe)return _(B)!==_(H)?!1:typeof Uint8Array=="function"&&F(new Uint8Array(B),new Uint8Array(H),ue,me);var Fe=y(B),ae=y(H);if(Fe!==ae)return!1;if(Fe||ae)return k(B)!==k(H)?!1:typeof Uint8Array=="function"&&F(new Uint8Array(B),new Uint8Array(H),ue,me);if(typeof B!=typeof H)return!1;var ge=C(B),Ye=C(H);if(ge.length!==Ye.length)return!1;for(ge.sort(),Ye.sort(),we=ge.length-1;we>=0;we--)if(ge[we]!=Ye[we])return!1;for(we=ge.length-1;we>=0;we--)if(_e=ge[we],!F(B[_e],H[_e],ue,me))return!1;var Qe=S(B),Dt=S(H);return Qe!==Dt?!1:Qe==="Set"||Dt==="Set"?te(B,H,ue,me):Qe==="Map"?ce(B,H,ue,me):!0}return Wp=function(H,ue,me){return F(H,ue,me,c())},Wp}var FV=$V();const za=Oi(FV),VV={name:"WtTagsInput",mixins:[Al,M4,R4],props:{value:{type:Array},trackBy:{type:String,default:null},taggable:{type:Boolean,default:!1},manualTagging:{type:Boolean,default:!1,description:`
3146
3146
  False: "tag" method automatically pushes { optionLabel | "name", trackBy } object to value
3147
3147
  array and $emits "input" event.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@webitel/ui-sdk",
3
- "version": "25.8.19",
3
+ "version": "25.8.20",
4
4
  "private": false,
5
5
  "scripts": {
6
6
  "make-all": "npm version patch --git-tag-version false && npm run build && (npm run build:types || true) && (npm run lint:fix || true) && npm run publish-lib",
@@ -28,7 +28,7 @@
28
28
  </template>
29
29
 
30
30
  <script setup>
31
- import { computed } from 'vue';
31
+ import { computed, ref, watch } from 'vue';
32
32
 
33
33
  const props = defineProps({
34
34
  icon: {
package/src/css/main.scss CHANGED
@@ -61,6 +61,18 @@ iframe {
61
61
  border: none;
62
62
  }
63
63
 
64
+ //@author @Oleksandr Palonnyi
65
+ //[WTEL-6985]-(https://webitel.atlassian.net/browse/WTEL-6985)
66
+ //:not(.wt-button) is added because of wt-button uses primevue component
67
+ //that confilcts with the default button styles
68
+
69
+ button:not(.wt-button) {
70
+ cursor: pointer;
71
+ outline-color: #000;
72
+ background: transparent;
73
+ padding: 0;
74
+ }
75
+
64
76
  a {
65
77
  color: #000;
66
78
  text-decoration: none;