import { Pipe, PipeTransform, inject } from '@angular/core'; import { TranslationService } from './translation.service'; @Pipe({ name: 'translate', pure: false, standalone: true }) export class TranslatePipe implements PipeTransform { private svc = inject(TranslationService); transform(key: string): string { return this.svc.translate(key); } }