UNPKG

bdt105angulartranslatecomponent

Version:

Access to MySql database API

1 lines 1.69 kB
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports,require("@angular/core"),require("bdt105angulartranslateservice")):"function"==typeof define&&define.amd?define(["exports","@angular/core","bdt105angulartranslateservice"],e):e((t.ng=t.ng||{},t.ng.bdt105angulartranslatecomponent={}),t.ng.core,t.bdt105angulartranslateservice)}(this,function(t,e,n){"use strict";var r=function(){function t(){}return t.decorators=[{type:e.Injectable}],t.ctorParameters=function(){return[]},t}(),a=function(){function t(t,e){this.translateService=t,this.options=e,this.isTag=!1}return t.prototype.ngOnInit=function(){this.isTag?this.translateService.getTranslateTag()?this.translation=this.translateService.translate(this.text):this.translation=this.text:this.translation=this.translateService.translate(this.text),this.options&&this.options.baseUrl&&this.translateService.setDatabaseBaseUrl(this.options.baseUrl)},t.prototype.setDatabaseBaseUrl=function(t){this.translateService.setDatabaseBaseUrl(t)},t.decorators=[{type:e.Component,args:[{selector:"translate",template:"{{translation}}",providers:[n.TranslateService]}]},{type:e.Injectable}],t.ctorParameters=function(){return[{type:n.TranslateService},{type:r}]},t.propDecorators={text:[{type:e.Input}],isTag:[{type:e.Input}]},t}(),s=new e.InjectionToken("Translate component user options"),o=function(){function t(){}return t.forRoot=function(e){return{ngModule:t,providers:[{provide:s,useValue:e}]}},t.decorators=[{type:e.NgModule,args:[{declarations:[a],exports:[a]}]}],t.ctorParameters=function(){return[]},t}();t.TranslateModule=o,t.TranslateComponent=a,t.TranslateOptions=r,Object.defineProperty(t,"__esModule",{value:!0})});