1
0
mirror of https://github.com/bitwarden/desktop.git synced 2024-10-05 05:08:14 +02:00
bitwarden-desktop/src/app/pipes/i18n.pipe.ts

18 lines
394 B
TypeScript
Raw Normal View History

2018-01-24 20:59:03 +01:00
import {
Pipe,
PipeTransform,
} from '@angular/core';
2018-01-25 20:25:44 +01:00
import { I18nService } from 'jslib/abstractions/i18n.service';
2018-01-24 20:59:03 +01:00
@Pipe({
name: 'i18n',
})
export class I18nPipe implements PipeTransform {
constructor(private i18nService: I18nService) { }
2018-01-24 20:59:03 +01:00
transform(id: string, p1?: string, p2?: string, p3?: string): string {
return this.i18nService.t(id, p1, p2, p3);
2018-01-24 20:59:03 +01:00
}
}