import{Hd as l,Kd as u,Td as d}from"./chunk-PCDQIHDN.js";function a(n,r,o){let t=o||{};return Object.keys(n.controls).forEach(s=>{let e=n.controls[s];if(!r||e.dirty)if(e instanceof l||e instanceof d)t[s]=a(e,r);else{let i=e;i.requiresToModelConversion?t[s]=i.modelValue:t[s]=e.value}}),t}var v=class extends u{constructor(r,o,t,s,e){super(r,o,t),this.modelToViewConverter=s,this.viewToModelConverter=e}get requiresToModelConversion(){return!!this.viewToModelConverter}get requiresToViewConversion(){return!!this.modelToViewConverter}setValue(r,o){this.requiresToViewConversion?super.setValue(this.modelToViewConverter(r),o):super.setValue(r,o)}get modelValue(){return this.requiresToModelConversion?this.viewToModelConverter(this.value):this.value}};export{a,v as b};
