Thanks to visit codestin.com
Credit goes to github.com

Skip to content

[Translation] XLIFF2: Make sure to trim source if it is too long for "name" #26661

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 30, 2018

Conversation

Nyholm
Copy link
Member

@Nyholm Nyholm commented Mar 23, 2018

Q A
Branch? master
Bug fix? yes
New feature? no
BC breaks? no
Deprecations? no
Tests pass? yes
Fixed tickets
License MIT
Doc PR

This PR is a follow-up on @javiereguiluz's comment here: symfony/symfony-docs#9302

This feature was introduced in #26149

@Nyholm Nyholm force-pushed the translation-xliff-name branch from e485a5b to ca41fec Compare March 27, 2018 07:49
@Nyholm
Copy link
Member Author

Nyholm commented Mar 27, 2018

I've rebased my PR on master to make Travis happy.

@javiereguiluz
Copy link
Member

I'm not sure about this because translations will have different kinds of id depending on its contents:

<trans-unit id="http_error_403.suggestion"> ... </trans-unit>
<trans-unit id="ca41fec"> ... </trans-unit>

Why can't we just apply this md5 ID to all translation nodes? Why it's important to duplicate the translation contents in the id too? XLIFF is already verbose and this is not helping 😓

@Nyholm
Copy link
Member Author

Nyholm commented Mar 27, 2018

As mentioned in #25758

For backward compatibility I don't expect to see a change to the way the element is used, but for the 1.2 and 2.0 formats to be treated as equivalent it seems the same logic should be applied.

So we use source as name to be similar to 1.2.

@fabpot
Copy link
Member

fabpot commented Mar 30, 2018

Thank you @Nyholm.

@fabpot fabpot merged commit ca41fec into symfony:master Mar 30, 2018
fabpot added a commit that referenced this pull request Mar 30, 2018
…o long for "name" (Nyholm)

This PR was merged into the 4.1-dev branch.

Discussion
----------

[Translation] XLIFF2: Make sure to trim source if it is too long for "name"

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        |

This PR is a follow-up on @javiereguiluz's comment here: symfony/symfony-docs#9302

This feature was introduced in #26149

Commits
-------

ca41fec Make sure to trim source if it is too long
@Nyholm Nyholm deleted the translation-xliff-name branch February 24, 2021 09:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants