import{d as I,e as O}from"./chunk-IEJVBN5K.js";import{E as z,a as w,h as E,o as V}from"./chunk-MDIMQ3H3.js";import{a as g}from"./chunk-3DEA4WWC.js";import{Ad as D,Bb as v,Bc as S,Db as f,Ha as c,Ib as l,Jb as d,Kb as s,Uc as N,Yc as i,Za as o,Zb as y,ad as L,ib as m,ma as b,mc as u,nc as p,nd as _,rc as C,sc as h,tc as M}from"./chunk-GJDGQISV.js";function P(a,e){if(a&1&&(d(0,"p"),u(1),s()),a&2){let t=y();o(),p(t.description())}}var H=class a{label=i("");options=i([]);bindLabel=i("");bindValue=i("");disabled=i(!1);value=L(null);isHorizontalLayout=i(!1);description=i("");clearable=i(!1);disabledSignal=N(()=>this.disabled());constructor(){c(()=>{let e=this.value(),t=[g?.GuidEmpty].filter(Boolean);typeof e=="string"&&t.includes(e)&&(this.value.set(null),e=null),this.onChange(e)})}onChange=e=>{};onTouched=()=>{};writeValue(e){let t=[g?.GuidEmpty].filter(Boolean);typeof e=="string"&&t.includes(e)?this.value.set(null):this.value.set(e)}registerOnChange(e){this.onChange=e}registerOnTouched(e){this.onTouched=e}setDisabledState(e){this.disabledSignal.set(e)}static \u0275fac=function(t){return new(t||a)};static \u0275cmp=m({type:a,selectors:[["POS-input-select"]],inputs:{label:[1,"label"],options:[1,"options"],bindLabel:[1,"bindLabel"],bindValue:[1,"bindValue"],disabled:[1,"disabled"],value:[1,"value"],isHorizontalLayout:[1,"isHorizontalLayout"],description:[1,"description"],clearable:[1,"clearable"]},outputs:{value:"valueChange"},features:[S([{provide:w,useExisting:b(()=>a),multi:!0}])],decls:7,vars:10,consts:[[1,"mb-6","row","wrapper"],[3,"ngClass"],[1,"mb-2","h5"],["placeholder","Emoney Type","placeholder","Choose an Options",1,"custom-select",3,"ngModelChange","clearable","items","bindLabel","bindValue","ngModel","disabled"]],template:function(t,n){t&1&&(d(0,"div",0)(1,"div",1)(2,"label",2),u(3),s(),v(4,P,2,1,"p"),s(),d(5,"div",1)(6,"ng-select",3),M("ngModelChange",function(r){return h(n.value,r)||(n.value=r),r}),s()()()),t&2&&(o(),l("ngClass",n.isHorizontalLayout()?"col-6":"col-12"),o(2),p(n.label()),o(),f(n.isHorizontalLayout()?4:-1),o(),l("ngClass",n.isHorizontalLayout()?"col-6":"col-12"),o(),l("clearable",n.clearable())("items",n.options())("bindLabel",n.bindLabel())("bindValue",n.bindValue()),C("ngModel",n.value),l("disabled",n.disabledSignal()))},dependencies:[O,I,z,E,V,D,_],styles:[".wrapper[_ngcontent-%COMP%]{padding:4px;border-radius:8px}","label[_ngcontent-%COMP%]{font-weight:600}.form-control[_ngcontent-%COMP%]{padding:12px;border-radius:8px;color:#000}"]})};export{H as a};
