HTML Filter: Don't group when the text is surrounded by a single html tag

Issue #1082 wontfix
Handika Dwi created an issue

I notice Okapi groups (<g>) a text which surrounded by a single HTML tag on the extracted xliff.

for example
<a href="">Can the surrounding g tags removed?</a>

will result:

<g id="1">Can the surrounding g tags removed?</g>

on the extracted xliff.

Is there option/config to not to group it when there’s only single tag?

The filter is fine when:

<a href="">Another One</a><a href="">Another Two</a>

Comments (2)

  1. Chase Tingley

    Per the XLIFF 1.2 spec:

    The <g> element is used to replace any inline code of the original document that has a beginning and an end, does not overlap other paired inline codes, and can be moved within its parent structural element.

    Hyperlinks have a beginning (<a href="">) and an end (</g>), and in this case it does not overlap with other paired inline codes. The codes can be moved within its parent structural element (ie, the hyperlink could be rearranged inside the paragraph or whatever). In other words, this is what <g> is designed for.

  2. Log in to comment