universalviewer icon indicating copy to clipboard operation
universalviewer copied to clipboard

Metadata values aren't being localised

Open mel-mason opened this issue 5 years ago • 2 comments

UV version:

 [email protected]

I'm submitting a:

  • [x] bug report
  • [ ] feature request => please use the user stories repo
  • [ ] support request => Please do not submit support requests here, use stackoverflow

Current behavior: With a bilingual english/german manifest and locale set to English the metadata labels are correctly localised to English, but any metadata values with multiple language choices stay in German. I.e. with a manifest containing the metadata block in 'related code' I get the following metadata in the universal.io demo

Date: 1462
Digitization Project: Handschriften aus dem deutschen Sprachraum

Expected behavior: Metadata values with multiple language choices should be localised to the correct language. I.e. with a manifest containing the metadata block in 'related code' and locale set to English I should get the following metadata

Date: 1462
Digitization Project: Manuscripts from German-Speaking Lands

Steps to reproduce: Use a manifest with the following top level metadata block in the UV demo (I can't currently give you the full manifest I was using, sorry)

Related code:

"metadata": [
  {
    "label": [
      {
        "@language": "en",
        "@value": "Date"
      },
      {
        "@language": "de",
        "@value": "Datierung"
      }
    ],
    "value": "1462"
  },
  {
    "label": [
      {
        "@language": "de",
        "@value": "Digitalisierungsprojekt"
      },
      {
        "@language": "en",
        "@value": "Digitization Project"
      }
    ],
    "value": [
      {
        "@language": "en",
        "@value": "Manuscripts from German-Speaking Lands"
      },
      {
        "@language": "de",
        "@value": "Handschriften aus dem deutschen Sprachraum"
      }
    ]
  }
]

Other information:

May be an issue with only some of the values having multiple language choices? Although this is permitted in the presentation spec. All of the labels have multiple language choices.

mel-mason avatar Mar 05 '19 14:03 mel-mason

can confirm this also seems to be the case in UV 3 (and presentation API 3) example: https://gist.githubusercontent.com/irv/40f8be0c4bc924b135d11943f6ba92c2/raw/a0b273389444146613e83d066f9504d7e290ad1e/richard.json

irv avatar Mar 07 '19 13:03 irv

Example manifest in presentation API 2: https://iiif.hab.de/object/mss_272-helmst/manifest.json

mel-mason avatar Mar 18 '19 10:03 mel-mason

All issues will be triaged for further investigation or closure by the 28 September 2023. If your issue is still relevant and would like for it be investigated further please comment by 14 September 2023.

LlGC-szw avatar Aug 25 '23 11:08 LlGC-szw

Cannot reproduce -- I believe this problem has been fixed.

demiankatz avatar Nov 02 '23 17:11 demiankatz