Open sdellis opened 2 years ago
potentially relevant UV ticket https://github.com/UniversalViewer/universalviewer/issues/299
Follow up with users about whether the title in UV is RTL, but should also be justified right. UV has no dir
attribute on the element. Is there a way to tell the viewer that this is RTL. Setting dir='rtl'
in the TOC seems to do the right thing. However, there's often mixed languages in the TOC, so we need to apply it directly to the section labels.
Things to explore, in order:
lang
value in Structure Manager. We define the language in the metadata values, and you can see that it works in the metadata panel of the UV. Note: Rails Gem currently auto-assumes RTL or LTR (not language) based on the unicode character range.
Other implementation possibilities:
mentioned by @eliotjordan https://github.com/jtoy/cld
PO Priority: This is one of two top figgy priorities for the Large 3 year project for Middle East Manuscripts. After discussion with project team, it would be great to see this through to completion by the end of the 3 year project (2024)
Implementation proposal:
In the Manifest Builder, check to see if a section label is RTL (#dir
), if it is, then make it a RDF Literal with the language tag that's in the imported metadata's #language
property.
https://github.com/pulibrary/figgy/pull/5750 updates manifests as per the implementation proposal in the previous comment. However, UV only implemented the rtl direction feature for the metadata info pane, not for the leftPanel "Contents" iiif-tree-component.
Code references:
Note that @tpendragon also tried just putting html as the manifest value, but that resulted in an error.
The proposed path forward is (not necessarily in this order):
However, this path forward is a bigger project than we had hoped and the work will need to undergo prioritization again.
Summary
Arabic section titles are not appearing as Right To Left in Universal Viewer. Adding brackets to wrapped text also creates problems because they do not start and end at the beginning of the text.
Impact
This affects end users as the text is not displayed properly, but does not typically prevent them from accomplishing their task.
Priority recommendation
Sudden Priority Justification
Required if "asap" or "within the next 3 weeks" is checked. Add "Sudden Priority" and "Maintenance/Research" labels
Expected behaviour
Section titles should be displayed Right To Left
Actual behaviour
Section titles are displayed Left To Right, which is incorrect
Steps to reproduce behaviour
See highlight reel. at 12:50.
ScreenshoTS
See highlight reel. at 12:50.
Example
Example used in this screencast: https://catalog.princeton.edu/catalog/9963585953506421 https://figgy.princeton.edu/catalog/cfec680e-1169-475d-b0f3-90b5f64e8115
Context
This issue is the result of a UX research session. The bug was reported during a focus group / observation with Graduate Students working on an Islamic Manuscripts project, held on Aug 16th, 2022.