UNPKG

@namefully/ng

Version:
2 lines 2.49 kB
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("@angular/core"),require("namefully")):"function"==typeof define&&define.amd?define("@namefully/ng",["exports","@angular/core","namefully"],t):t(((e=e||self).namefully=e.namefully||{},e.namefully.ng={}),e.ng.core,e.namefully)}(this,(function(e,t,n){"use strict";function r(e,t,n){var r=t.apply(e,n);return Array.isArray(r)?r.join(" "):r}var o=function(){function e(){}return e.prototype.ngOnInit=function(){var e=new n.Namefully(this.raw,this.options);this.content=r(e,e[this.method||"birthName"],this.args)},e.decorators=[{type:t.Component,args:[{selector:"ngx-namefully",template:"{{content}}"}]}],e.propDecorators={raw:[{type:t.Input}],options:[{type:t.Input}],method:[{type:t.Input}],args:[{type:t.Input}]},e}();var u=function(){function e(){}return e.prototype.transform=function(e,t,o,u){var a=new n.Namefully(e,t);return r(a,a[null!=o?o:"birthName"],u)},e.decorators=[{type:t.Pipe,args:[{name:"namefully"}]}],e}(),a=function(){function e(e){this.elRef=e}return e.prototype.ngAfterViewInit=function(){var e,t=new n.Namefully(this.raw,this.options);this.elRef.nativeElement.innerHTML=r(t,t[null!==(e=this.method)&&void 0!==e?e:"birthName"],this.args)},e.decorators=[{type:t.Directive,args:[{selector:"[ngxNamefully]"}]}],e.ctorParameters=function(){return[{type:t.ElementRef}]},e.propDecorators={raw:[{type:t.Input,args:["ngxNamefully"]}],options:[{type:t.Input,args:["nfOptions"]}],method:[{type:t.Input,args:["nfMethod"]}],args:[{type:t.Input,args:["nfArgs"]}]},e}();var i=new t.InjectionToken("ConfigToken"),f=function(){function e(){}return e.forRoot=function(t){return{ngModule:e,providers:[{provide:i,useValue:{default:n.Config.create(),custom:t}}]}},e.decorators=[{type:t.NgModule,args:[{declarations:[o,u,a],exports:[o,u,a]}]}],e}(),l=function(){function e(e){this.config=e.custom?n.Config.merge(e.custom):e.default}return e.prototype.build=function(e,t){return new n.Namefully(e,t||this.config)},e.decorators=[{type:t.Injectable,args:[{providedIn:"root"}]}],e.ctorParameters=function(){return[{type:void 0,decorators:[{type:t.Inject,args:[i]}]}]},e.ɵprov=t.ɵɵdefineInjectable({factory:function(){return new e(t.ɵɵinject(i))},token:e,providedIn:"root"}),e}();e.CONFIG_TOKEN=i,e.NamefullyComponent=o,e.NamefullyDirective=a,e.NamefullyModule=f,e.NamefullyPipe=u,e.NamefullyService=l,Object.defineProperty(e,"__esModule",{value:!0})})); //# sourceMappingURL=namefully-ng.umd.min.js.map