collapseWhitespace and trim not applied to translationTargetFile resulting in target state reset
Closed this issue · 0 comments
mbey-mw commented
Describe the bug
Translation tool lokalize (v23.08.1) adds line break to source/target when ending with interpolation. This is the observable change when saving in lokalize:
- <trans-unit id="AudioChannelNumber" datatype="html">
- <source>Audio Channel <x equiv-text="{{c}}" id="INTERPOLATION"/></source>
+ <trans-unit datatype="html" id="AudioChannelNumber">
+ <source>Audio Channel <x equiv-text="{{c}}" id="INTERPOLATION"/>
+ </source>
<target state="signed-off">Canal Audio <x equiv-text="{{c}}" id="INTERPOLATION"/></target>
</trans-unit>
This results in a target state change from signed-off
to new
after a run of ng-extract-i18n-merge.
Expected behavior
When using "collapseWhitespace": true
and "trim": true
it should not change the target state because the source is the same (after normalization).
Version (please complete the following information):
- Angular: 17.1.2
- OS: Ubuntu 23.10
- nodejs: 20.11.0
- ng-extract-i18n-merge version: 2.10.0