added translation for new feature
This commit is contained in:
@@ -10,5 +10,6 @@ export interface listTranslations {
|
||||
translate: string;
|
||||
locationName: string;
|
||||
distance: string;
|
||||
positionNotFoundErrorMessage: string;
|
||||
}
|
||||
|
||||
|
||||
@@ -32,7 +32,7 @@
|
||||
</h3>
|
||||
<div class="distance">
|
||||
<h4 *ngIf="distance[i]">{{translations.distance}}{{distance[i]}} km</h4>
|
||||
<h4 *ngIf="positionNotFound">could not retrieve distance</h4>
|
||||
<h4 *ngIf="positionNotFound">{{translations.positionNotFoundErrorMessage}}</h4>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
@@ -121,6 +121,6 @@ export class ListComponent implements OnInit, OnChanges {
|
||||
this.translations.translate = await this.translateService.getData(this.translations.translate, lang);
|
||||
this.translations.distance = await this.translateService.getData(this.translations.distance, lang);
|
||||
this.translations.locationName = await this.translateService.getData(this.translations.locationName, lang);
|
||||
|
||||
this.translations.positionNotFoundErrorMessage = await this.translateService.getData(this.translations.positionNotFoundErrorMessage, lang);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -24,6 +24,7 @@ export class ReadTranslateJsonService {
|
||||
this.listTranslation.translate = data.translate;
|
||||
this.listTranslation.distance = data.distance;
|
||||
this.listTranslation.locationName = data.locationName;
|
||||
this.listTranslation.positionNotFoundErrorMessage = data.positionNotFoundErrorMessage;
|
||||
console.log("data loaded", this.homeTranslations)
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user