Skip to content
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

[Extended Proposal] Provide a standard way to add description to <resourceItem> #25

Open
3 of 4 tasks
yumaoka opened this issue Jun 20, 2023 · 2 comments
Open
3 of 4 tasks

Comments

@yumaoka
Copy link
Contributor

yumaoka commented Jun 20, 2023

Authors

Yoshito Umaoka

Area of Changes

  • XLIFF specification document
  • XLIFF schema
  • XLIFF validator
  • Example files

Detailed Description

The Resource Data module provides a mechanism for referencing external resource data. To specify a reference item,<resourceItem> element is used. In the current specification, there is no way way to specify description of each resource item without attributes/elements from other namespaces. When a resource item is used as context reference, it is important to provide a description about the content, not just mimeType. XLIFF should provide a standard way to add description of each resource item.

There are two options to support this requirement.

  1. Add new attribute description to <resourceItem> element.
  2. Allow note element in <resourceItem> element.

1 is probably easier for XLIFF implementators. 2 is more consistent with other XLIFF elements.

Example of Option 1 above

<file id="f3">
  <res:resourceData>
    <res:resourceItem id="r1" mimeType="image/jpeg" context="yes" description="Config Screen 1">
      <res:source href="resources\en\registryconfig1.resources.jpg" />
      <res:target href="resources\lb\registryconfig1.resources.jpg" />
    </res:resourceItem>
  </res:resourceData>
  <unit id="1">
    <res:resourceData>
      <res:resourceItemRef ref="r1" />
    </res:resourceData>
    <segment id="1" state="translated">
      <source>Remove Registry Config</source>
      <target>Registrierungskonfiguration entfernen</target>
    </segment>
  </unit>
</file>

Example of Option 2 above

<file id="f3">
  <res:resourceData>
    <res:resourceItem id="r1" mimeType="image/jpeg" context="yes">
      <res:source href="resources\en\registryconfig1.resources.jpg" />
      <res:target href="resources\lb\registryconfig1.resources.jpg" />
      <notes>
        <note>Config Screen 1</note>
      </notes>
    </res:resourceItem>
  </res:resourceData>
  <unit id="1">
    <res:resourceData>
      <res:resourceItemRef ref="r1" />
    </res:resourceData>
    <segment id="1" state="translated">
      <source>Remove Registry Config</source>
      <target>Registrierungskonfiguration entfernen</target>
    </segment>
  </unit>
</file>

Example Use Case

No response

Compatibility Impacts

No response

@rmraya
Copy link
Contributor

rmraya commented Feb 20, 2024

It was unanimously agreed to use <notes> to provide a holder for descriptions.

yumaoka added a commit to yumaoka/xliff-xliff-22 that referenced this issue Feb 26, 2024
rmraya added a commit that referenced this issue Feb 28, 2024
@rmraya
Copy link
Contributor

rmraya commented Feb 28, 2024

Updated spec published, ready for review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants