mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-19 22:58:07 +02:00
Change how we handle l10n-args for dates in the DocumentProperties dialog (bug 1922618)
Strangely enough the code works just fine as-is in the GENERIC viewer, so there must be some difference between the Firefox built-in Fluent implementation and the Fluent.js one. It seems that we can work-around the problem by handling this l10n-arg the same way that we handle dates in the AnnotationLayer, and testing this with the Firefox Devtools it seems that it should work.
This commit is contained in:
parent
e5b6144bfa
commit
c681ff25d8
1 changed files with 3 additions and 1 deletions
|
@ -329,7 +329,9 @@ class PDFDocumentProperties {
|
|||
async #parseDate(inputDate) {
|
||||
const dateObj = PDFDateString.toDateObject(inputDate);
|
||||
return dateObj
|
||||
? this.l10n.get("pdfjs-document-properties-date-time-string", { dateObj })
|
||||
? this.l10n.get("pdfjs-document-properties-date-time-string", {
|
||||
dateObj: dateObj.valueOf(),
|
||||
})
|
||||
: undefined;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue