Skip to content

Commit

Permalink
Added translations
Browse files Browse the repository at this point in the history
  • Loading branch information
rmathis committed Mar 7, 2018
1 parent 84b7aaf commit 8dff230
Show file tree
Hide file tree
Showing 5 changed files with 60 additions and 10 deletions.
2 changes: 1 addition & 1 deletion ui/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"license": "MIT",
"scripts": {
"ng": "ng",
"start": "ng serve --proxy-config proxy.conf.json",
"start": "ng serve --proxy-config proxy.conf.json --i18nFile=./src/locale/en.xlf --i18nFormat=xlf --locale=es --aot",
"build": "ng build",
"test": "ng test --code-coverage",
"lint": "ng lint",
Expand Down
4 changes: 2 additions & 2 deletions ui/src/app/app.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
aria-expanded="false"
ngbDropdownToggle>
<i class="fa fa-plus-circle" aria-hidden="true"></i>
Add New
<ng-container i18n="@@action--add-new">Add New</ng-container>
</button>
<div ngbDropdownMenu aria-labelledby="addNewDropdown">
<a class="nav-link"
Expand All @@ -29,7 +29,7 @@
aria-label="Add a new metadata filter"
role="button">
<i class="fa fa-cubes" aria-hidden="true"></i>
<ng-container i18n="@@action--add-provider">Filter</ng-container>
<ng-container i18n="@@action--add-filter">Filter</ng-container>
</a>
<a class="nav-link"
routerLink="/new"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@
<div class="row justify-content-between">
<div class="col-md-12">
<span class="display-6">
<i class="fa fa-gears"></i> New Filter Page</span>
<i class="fa fa-gears"></i>
<ng-container i18n="@@label--new-filter">New Filter</ng-container>
</span>
</div>
</div>
</div>
Expand Down
30 changes: 27 additions & 3 deletions ui/src/locale/en.xlf
Original file line number Diff line number Diff line change
Expand Up @@ -18,14 +18,38 @@
<context context-type="linenumber">17</context>
</context-group>
</trans-unit>
<trans-unit id="action--add-provider" datatype="html">
<source>Add new provider</source>
<target>Add new provider</target>
<trans-unit id="action--add-new" datatype="html">
<source>Add New</source>
<target>Add New</target>
<context-group purpose="location">
<context context-type="sourcefile">app/app.component.ts</context>
<context context-type="linenumber">23</context>
</context-group>
</trans-unit>
<trans-unit id="action--add-provider" datatype="html">
<source>Metadata Provider</source>
<target>Metadata Provider</target>
<context-group purpose="location">
<context context-type="sourcefile">app/app.component.ts</context>
<context context-type="linenumber">40</context>
</context-group>
</trans-unit>
<trans-unit id="action--add-filter" datatype="html">
<source>Filter</source>
<target>Filter</target>
<context-group purpose="location">
<context context-type="sourcefile">app/app.component.ts</context>
<context context-type="linenumber">32</context>
</context-group>
</trans-unit>
<trans-unit id="label--new-filter" datatype="html">
<source>New Filter</source>
<target>New Filter</target>
<context-group purpose="location">
<context context-type="sourcefile">app/metadata-filter/container/new-filter.component.ts</context>
<context context-type="linenumber">8</context>
</context-group>
</trans-unit>
<trans-unit id="action--logout" datatype="html">
<source>Logout</source>
<target>Logout</target>
Expand Down
30 changes: 27 additions & 3 deletions ui/src/locale/es.xlf
Original file line number Diff line number Diff line change
Expand Up @@ -18,14 +18,38 @@
<context context-type="linenumber">17</context>
</context-group>
</trans-unit>
<trans-unit id="action--add-provider" datatype="html">
<source>Add new provider</source>
<target>Add new provider (es)</target>
<trans-unit id="action--add-new" datatype="html">
<source>Add New</source>
<target>Add New (es)</target>
<context-group purpose="location">
<context context-type="sourcefile">app/app.component.ts</context>
<context context-type="linenumber">23</context>
</context-group>
</trans-unit>
<trans-unit id="action--add-provider" datatype="html">
<source>Metadata Provider</source>
<target>Metadata Provider (es)</target>
<context-group purpose="location">
<context context-type="sourcefile">app/app.component.ts</context>
<context context-type="linenumber">40</context>
</context-group>
</trans-unit>
<trans-unit id="action--add-filter" datatype="html">
<source>Filter</source>
<target>Filter (es)</target>
<context-group purpose="location">
<context context-type="sourcefile">app/app.component.ts</context>
<context context-type="linenumber">32</context>
</context-group>
</trans-unit>
<trans-unit id="label--new-filter" datatype="html">
<source>New Filter</source>
<target>New Filter (es)</target>
<context-group purpose="location">
<context context-type="sourcefile">app/metadata-filter/container/new-filter.component.ts</context>
<context context-type="linenumber">8</context>
</context-group>
</trans-unit>
<trans-unit id="action--logout" datatype="html">
<source>Logout</source>
<target>Logout (es)</target>
Expand Down

0 comments on commit 8dff230

Please sign in to comment.