import{g as l}from"./chunk-MDIMQ3H3.js";import{Xb as s,eb as n,kb as r}from"./chunk-GJDGQISV.js";var c=class o{constructor(e){this.control=e}onInput(e){let t=e.replace(/\s/g,"");this.control.control?.setValue(t,{emitEvent:!1})}onPaste(e){e.preventDefault();let t="";e.clipboardData?t=e.clipboardData.getData("text/plain"):window.clipboardData&&(t=window.clipboardData.getData("Text"));let i=t.replace(/\s/g,"");this.control.control?.setValue(i,{emitEvent:!1}),this.control.control?.updateValueAndValidity()}static \u0275fac=function(t){return new(t||o)(n(l))};static \u0275dir=r({type:o,selectors:[["","disallowSpaces",""]],hostBindings:function(t,i){t&1&&s("input",function(a){return i.onInput(a.target.value)})("paste",function(a){return i.onPaste(a)})}})};export{c as a};
