13 Commits

Author SHA1 Message Date
Victor Berchet
e74d8aaf92
fix(i18n): parse ICU messages while normalizing templates
Fixes:
- Inject the i18n specific HtmlParser into the directive normalizer,
- Parse ICU messages while normalizing templates,
- Normalize (visit) the content of ICU messages.

🎄🎁🎅
2016-12-27 15:32:43 -08:00
Victor Berchet
c8baf51f4f style: clang-format the code 2016-12-09 11:19:55 -08:00
maxime-allex
6dd5201765 feat(compiler): add id property to i18nMessage 2016-12-09 10:43:47 -08:00
Victor Berchet
76e4911e8b fix(core): fix placeholders handling in i18n.
Prior to this commit, translations were built in the serializers. This
could not work as a single translation can be used for different source
messages having different placeholder content.

Serializers do not try to replace the placeholders any more.
Placeholders are replaced by the translation bundle and the source
message is given as parameter so that the content of the placeholders is
taken into account.

Also XMB ids are now independent of the expression which is replaced by
a placeholder in the extracted file.
fixes #12512
2016-11-14 12:55:48 -08:00
Victor Berchet
08c038ebd9 fix(core): xmb serializer uses decimal messaged IDs
fixes #12511
2016-11-14 12:55:48 -08:00
Victor Berchet
39c0f9ebb3 fix(ExtractorMerger): returns errors together with nodes (as a ParseTreeResult) 2016-08-11 23:24:22 -07:00
Victor Berchet
50345b8c36 feat(i18n): add an HtmlParser decorator (#10645)
* fix(i18n): merge retains attributes w/o value

* feat(i18n): allow attributes on ng-container (i.e. i18n)

* feat(i18n): add an HtmlParser decorator

* style: clang format
2016-08-11 21:00:35 -07:00
Victor Berchet
dd68ae3ef1 feat(ExtractorMerger): ignore implicit tags in translatable sections 2016-08-09 09:52:11 -07:00
Victor Berchet
1b04d70626 feat(ExtractorMerger): allow nested implicit tags 2016-08-09 09:52:11 -07:00
Victor Berchet
74b57dfa7d refactor(i18n): remove circular dep 2016-08-05 13:39:54 -07:00
Victor Berchet
8c9c0986e9 refatcor(digestMessage): takes a i18n.Message 2016-08-05 13:39:54 -07:00
Victor Berchet
4028fcaa51 refactor(i18n): Drop html.Message and create i18n.Message right away 2016-08-05 13:39:54 -07:00
Victor Berchet
7a8ef1eae5 feat(i18n): merge translations 2016-08-05 13:39:54 -07:00