File tree Expand file tree Collapse file tree 1 file changed +18
-0
lines changed
Phonebook.Frontend/src/app/shared/config Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Original file line number Diff line number Diff line change @@ -8,6 +8,24 @@ import { ColumnId } from 'src/app/shared/models/enumerables/ColumnId';
88export class ColumnTranslate {
99 constructor ( private i18n : I18n ) { }
1010 public getTranslation ( columnId : ColumnId ) : string {
11+ /*
12+ * workaround for ngx translate
13+ * necassary because the generated translations are wrong
14+ * They insert a new line after some strings and thus a space in the translated version of the string
15+ * E.G. What it should look like:
16+ * <source>Address</source><target state="final">Address</target>
17+ * looks like:
18+ * <source>
19+ * Buildings
20+ * </source><target state="final">
21+ * Buildings
22+ * </target>
23+ *
24+ * IssueLink: https://github.com/ngx-translate/i18n-polyfill/issues/63
25+ */
26+ return this . getInternalTranslation ( columnId ) . trim ( ) ;
27+ }
28+ private getInternalTranslation ( columnId : ColumnId ) : string {
1129 switch ( columnId ) {
1230 case ColumnId . picture :
1331 return this . i18n ( {
You can’t perform that action at this time.
0 commit comments