1import{$t as e,C as t,Et as n,I as r,J as i,L as a,Pt as o,ct as s,et as c,f as l,h as u,ht as d,m as f,ot as p,p as m,rn as h,x as g}from"./CB5-eA5X.js";import{d as _}from"./DIs47Bu1.js";import{l as v}from"./DNnrF5Vr.js";import{t as y}from"./BxvlFwtD.js";import{t as b}from"./B01tAdpj.js";import{t as x}from"./DUIhvRT2.js";var S={key:0,class:`input-custom__label`},C=[`value`,`type`,`placeholder`,`disabled`,`readonly`,`maxlength`],w=[`disabled`],T={key:1,class:`input-custom__error`},E={key:2,class:`input-custom__hint`},D=Object.assign(t({__name:`UiInput`,props:r({label:{},hideLabel:{type:Boolean},type:{default:`text`},placeholder:{},disabled:{type:Boolean},readonly:{type:Boolean},clearable:{type:Boolean},required:{type:Boolean},rightIcon:{},rightIconColor:{},leftIcon:{},disabledLeftIcon:{type:Boolean},hint:{},maxlength:{},error:{type:[String,Boolean,null]},isErrorMessageHide:{type:Boolean},withoutPreloader:{type:Boolean},compact:{type:Boolean},mask:{}},{modelValue:{required:!0},modelModifiers:{}}),emits:r([`change`,`click:left`,`click:right`,`click:clear`,`focus`,`blur`],[`update:modelValue`]),setup(t,{expose:r,emit:D}){let O=p(t,`modelValue`),k=t,A=D;r({focusInput:I,blurInput:L,selectInput:R});let j=n(!1),M=s(`inputEl`),{isLoading:N}=v(b());function P(e){let t=e.target;!k.maxlength||+t.value.length<=+k.maxlength?O.value=t.value:M.value.value=t.value.slice(0,+k.maxlength)}function F(){O.value=k.type===`number`?`0`:``,A(`click:clear`),I()}function I(){k.disabled||k.readonly||(M.value.focus(),j.value=!0)}function L(){M.value.blur(),j.value=!1,A(`blur`)}function R(){M.value.focus(),M.value.select(),j.value=!0}return(n,r)=>{let s=y,p=x,v=c(`mask-input`);return t.withoutPreloader||!o(N)?(i(),u(`div`,a({key:0,class:[`input-custom`,{"error-item":t.error}]},n.$attrs),[l(`div`,{class:e([`input-custom__input-wrap`,{"input-custom__input-wrap--with-left-icon":t.leftIcon,"input-custom__input-wrap--with-right-icon":t.clearable||t.rightIcon,"input-custom__input-wrap--disabled":t.disabled}])},[t.label&&!t.hideLabel?(i(),u(`label`,S,h(t.label),1)):f(``,!0),l(`div`,{class:e([`input-custom__input-block`,{"input-custom__input-block--required":t.required}])},[d(l(`input`,{ref_key:`inputEl`,ref:M,value:O.value,class:e([`input-custom__input`,{"input-custom__input--compact":t.compact}]),type:t.type,placeholder:t.placeholder,disabled:t.disabled,readonly:t.readonly,autocomplete:`nope`,maxlength:t.maxlength,onFocus:r[0]||=e=>j.value=!0,onBlur:r[1]||=e=>(j.value=!1,n.$emit(`blur`)),onInput:_(P,[`stop`]),onChange:r[2]||=_(e=>A(`change`,e.target.value),[`stop`])},null,42,C),[[v,t.mask||null]]),(O.value||O.value==0)&&t.clearable&&!t.disabled&&!t.readonly&&!t.rightIcon?(i(),u(`button`,{key:0,type:`button`,class:`input-custom__clear`,onClick:_(F,[`stop`,`prevent`])},[g(s,{icon:`mdi-close`})])):f(``,!0),t.leftIcon?(i(),u(`button`,{key:1,type:`button`,class:`input-custom__left-icon`,disabled:t.disabledLeftIcon,onClick:r[3]||=_(e=>A(`click:left`),[`prevent`])},[g(s,{icon:t.leftIcon,color:`#868FAC`},null,8,[`icon`])],8,w)):f(``,!0),t.rightIcon?(i(),u(`button`,{key:2,type:`button`,class:`input-custom__right-icon`,onClick:r[4]||=_(e=>A(`click:right`),[`prevent`])},[g(s,{icon:t.rightIcon,color:t.rightIconColor?t.rightIconColor:`#868FAC`},null,8,[`icon`,`color`])])):f(``,!0)],2),t.error&&typeof t.error==`string`&&!t.isErrorMessageHide?(i(),u(`div`,T,h(t.error),1)):f(``,!0),t.hint&&!t.error?(i(),u(`div`,E,h(t.hint),1)):f(``,!0)],2)],16)):(i(),m(p,{key:1,width:`100%`,height:`48px`}))}}}),{__name:`UiInput`});export{D as t};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.