We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hi!
I'm introducing i18n in my ng-table with ngx-translate library.
When I change language by this:
this.translate.use(lang)
all texts are translated but filter inputs placeholders.
By the moment, the only way that allows me implement this feature is handling the language change and setting manually the texts:
// Previous code let column1 = { name: 'first_name', sort: false, filtering: { filterString: '', placeholder: '' } }; let column2 = { name: 'last_name', sort: false, filtering: { filterString: '', placeholder: '' } }; let column3 = { name: 'email', sort: false, filtering: { filterString: '', placeholder: '' } }; ... // More code // Important code this.translate.onLangChange.subscribe((event: LangChangeEvent) => { Observable.forkJoin( this.translate.get('List.Filter.First Name'), this.translate.get('List.Filter.Last Name'), this.translate.get('List.Filter.Email'), ).subscribe(result => { column1['filtering']['placeholder'] = result[0]; column2['filtering']['placeholder'] = result[1]; column3['filtering']['placeholder'] = result[2]; this.columns = [column1, column2, column3]; this.config = { paging: true, sorting: { columns: this.columns }, filtering: { filterString: '' }, className: ['table-striped', 'table-bordered'] }; }); });
Is there any way for translate filter inputs placeholders without handling language change event?
Thank you so much.
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Hi!
I'm introducing i18n in my ng-table with ngx-translate library.
When I change language by this:
this.translate.use(lang)
all texts are translated but filter inputs placeholders.
By the moment, the only way that allows me implement this feature is handling the language change and setting manually the texts:
Is there any way for translate filter inputs placeholders without handling language change event?
Thank you so much.
The text was updated successfully, but these errors were encountered: