ngx-i18nsupport
Advanced tools
Comparing version 0.4.0 to 0.5.0
@@ -1,2 +0,9 @@ | ||
<a name="0.4-0"></a> | ||
<a name="0.5.0"></a> | ||
# [0.5.0](https://github.com/martinroob/ngx-i18nsupport/compare/v0.4.0...v0.5.0) (2017-05-05) | ||
### Features | ||
* **xliffmerge:** added XLIFF 2.0 support. ([#20](https://github.com/martinroob/ngx-i18nsupport/issues/20)) | ||
<a name="0.4.0"></a> | ||
# [0.4.0](https://github.com/martinroob/ngx-i18nsupport/compare/v0.3.1...v0.4.0) (2017-05-03) | ||
@@ -3,0 +10,0 @@ |
@@ -173,5 +173,5 @@ /** | ||
} | ||
// i18nFormat must be xlf or xmb | ||
if (!(this.i18nFormat() === 'xlf' || this.i18nFormat() === 'xmb')) { | ||
this.errorsFound.push(new xliff_merge_error_1.XliffMergeError('i18nFormat "' + this.i18nFormat() + '" invalid, must be "xlf" or "xmb"')); | ||
// i18nFormat must be xlf xlf2 or xmb | ||
if (!(this.i18nFormat() === 'xlf' || this.i18nFormat() === 'xlf2' || this.i18nFormat() === 'xmb')) { | ||
this.errorsFound.push(new xliff_merge_error_1.XliffMergeError('i18nFormat "' + this.i18nFormat() + '" invalid, must be "xlf" or "xlf2" or "xmb"')); | ||
} | ||
@@ -243,3 +243,3 @@ }; | ||
* Format of the master xlif file. | ||
* Default is "xlf", possible are "xlf" or "xmb". | ||
* Default is "xlf", possible are "xlf" or "xlf2" or "xmb". | ||
* @return {string} | ||
@@ -246,0 +246,0 @@ */ |
{ | ||
"name": "ngx-i18nsupport", | ||
"version": "0.4.0", | ||
"version": "0.5.0", | ||
"description": "Some tooling to be used with the Angular 2 i18n workflow", | ||
@@ -52,4 +52,4 @@ "main": "index.js", | ||
"commander": "^2.9.0", | ||
"ngx-i18nsupport-lib": "^0.0.8" | ||
"ngx-i18nsupport-lib": "^0.1.3" | ||
} | ||
} |
@@ -33,3 +33,3 @@ [![Build Status][travis-badge]][travis-badge-url] | ||
* markup your strings to translate in your templates with an attribute `i18n` | ||
* run the Amgular extraction tool (`ng-xi18n`) to extract the strings in an XML Format called [[XLIFF]]((http://docs.oasis-open.org/xliff/xliff-core/xliff-core.html)) | ||
* run the Amgular extraction tool (`ng-xi18n`) to extract the strings in an XML Format called [[XLIFF-1.2]](http://docs.oasis-open.org/xliff/v1.2/os/xliff-core.html) | ||
* copy and then translate the extracted file for every language you plan to support | ||
@@ -108,4 +108,4 @@ * run the ng compiler to generate a special version of your app for the different languages | ||
- `i18nFile` (string, default "messages.xlf"): master file (relativ to srcDir) | ||
- `i18nFormat` (string, default "xlf"): "xlf" for XLIFF or "xmb" for XML Message Bundles | ||
- `encoding` (string, default "UTF-8"): expected encoding of xlf or xmb files | ||
- `i18nFormat` (string, default "xlf"): `xlf` for XLIFF 1.2 or `xlf2` for XLIFF 2.0 or `xmb` for XML Message Bundles | ||
- `encoding` (string, default "UTF-8"): expected encoding of xlf, xlf2 or xmb files | ||
- `defaultLanguage` (string, default "en"): the native language used in your templates | ||
@@ -206,3 +206,4 @@ - `languages` (array of strings): list of languages (if not spefified at command line) | ||
* Roland Oldengarm: [Angular 2: Automated i18n workflow using gulp](http://rolandoldengarm.com/index.php/2016/10/17/angular-2-automated-i18n-workflow-using-gulp/) | ||
* XLIFF Specification: [XLIFF Spec](http://docs.oasis-open.org/xliff/xliff-core/xliff-core.html) | ||
* XLIFF 1.2 Specification: [XLIFF-1.2](http://docs.oasis-open.org/xliff/v1.2/os/xliff-core.html) | ||
* XLIFF 2.0 Specification: [XLIFF-2.0](http://docs.oasis-open.org/xliff/xliff-core/v2.0/os/xliff-core-v2.0-os.html) | ||
* My Tiny Translator Tool: [TinyTranslator](https://github.com/martinroob/tiny-translator) | ||
@@ -209,0 +210,0 @@ |
@@ -192,5 +192,5 @@ /** | ||
} | ||
// i18nFormat must be xlf or xmb | ||
if (!(this.i18nFormat() === 'xlf' || this.i18nFormat() === 'xmb')) { | ||
this.errorsFound.push(new XliffMergeError('i18nFormat "' + this.i18nFormat() + '" invalid, must be "xlf" or "xmb"')); | ||
// i18nFormat must be xlf xlf2 or xmb | ||
if (!(this.i18nFormat() === 'xlf' || this.i18nFormat() === 'xlf2' || this.i18nFormat() === 'xmb')) { | ||
this.errorsFound.push(new XliffMergeError('i18nFormat "' + this.i18nFormat() + '" invalid, must be "xlf" or "xlf2" or "xmb"')); | ||
} | ||
@@ -271,3 +271,3 @@ } | ||
* Format of the master xlif file. | ||
* Default is "xlf", possible are "xlf" or "xmb". | ||
* Default is "xlf", possible are "xlf" or "xlf2" or "xmb". | ||
* @return {string} | ||
@@ -274,0 +274,0 @@ */ |
@@ -76,3 +76,3 @@ import * as program from 'commander'; | ||
*/ | ||
private master: ITranslationMessagesFile; // XliffFile or XmbFile | ||
private master: ITranslationMessagesFile; // XliffFile or Xliff2File or XmbFile | ||
@@ -79,0 +79,0 @@ /** |
@@ -12,2 +12,3 @@ This directory contains some testdata. | ||
The xmb files are the same in principle, but for format xmb. | ||
The xmb files are the same in principle, but for format xmb. | ||
And the xlf2 files are for XLIFF 2.0 |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
430664
62
4815
218
+ Addedngx-i18nsupport-lib@0.1.3(transitive)
- Removedngx-i18nsupport-lib@0.0.8(transitive)
Updatedngx-i18nsupport-lib@^0.1.3