-
Notifications
You must be signed in to change notification settings - Fork 10.6k
Open
Labels
Description
Attach (recommended) or Link to PDF file
Web browser and its version
Firefox 149.0b4 (Developer Edition)
Operating system and its version
Arch Linux 6.18.13-zen1-1-zen
PDF.js version
5.5.207
Is the bug present in the latest PDF.js version?
Yes
Is a browser extension
Yes
Steps to reproduce the problem
- Create a PDF with a title with multiple languages in the XMP metadata.
For example, the following LaTeX code in TeX Live 2026 produces the PDF attached above:
\DocumentMetadata{lang=en,debug={xmp-export}}
\documentclass{article}
\usepackage{hyperref}
\hypersetup{pdftitle={Hello World}}
\begin{document}
Hello World!
\end{document}The produced PDF has the following XMP title metadata, with both x-default and en languages specified:
<dc:title>
<rdf:Alt>
<rdf:li xml:lang="x-default">Hello World</rdf:li>
<rdf:li xml:lang="en">Hello World</rdf:li>
</rdf:Alt>
</dc:title>- Open the PDF using pdf.js.
- Open the Document Properties window in pdf.js.
What is the expected behavior?
The pdf.js Document Properties window displays the title for one language
What went wrong?
The properties window (and page title) concatenates the titles for all languages together:
(The title here should just be "Hello World" rather than "Hello WorldHello World".)
Link to a viewer
No response
Additional context
Full XMP metadata from the attached PDF file (generated by LaTeX using \DocumentMetadata{debug={xmp-export}}):
Reactions are currently unavailable