import{i as h}from"./chunk-YJYOGSOO.js";import{U as a,ha as o,i as n}from"./chunk-FWZCAEAJ.js";import{a as r}from"./chunk-CWTPBX7D.js";var b=(()=>{let e=class e{constructor(){this.delay=5e3,this.toasts=new n([]),this.translate=h()}info(t){this.show(t,{delay:this.delay,classname:"bg-info text-dark"})}tinfo(t){this.translate(t).pipe(a()).subscribe(s=>this.info(s))}success(t){this.show(t,{classname:"bg-success text-light",delay:this.delay})}tsuccess(t){this.translate(t).pipe(a()).subscribe(s=>this.success(s))}warning(t,s){this.show(t,{classname:"bg-warning text-dark",delay:s??this.delay})}twarning(t){this.translate(t).pipe(a()).subscribe(s=>this.warning(s))}error(t,s){this.show(t,{classname:"bg-danger text-light",delay:s??this.delay})}terror(t){this.translate(t).pipe(a()).subscribe(s=>this.error(s))}show(t,s){this.toasts.next([...this.toasts.getValue(),r({textOrTpl:t},s)])}remove(t){this.toasts.next(this.toasts.getValue().filter(s=>s!==t))}};e.\u0275fac=function(s){return new(s||e)},e.\u0275prov=o({token:e,factory:e.\u0275fac,providedIn:"root"});let i=e;return i})();export{b as a};
