mirror of
https://github.com/zen-browser/pdf.js.git
synced 2025-07-08 09:20:06 +02:00
Fix the linting errors, from the Prettier auto-formatting, that ESLint --fix
couldn't handle
This patch makes the follow changes: - Remove no longer necessary inline `// eslint-disable-...` comments. - Fix `// eslint-disable-...` comments that Prettier moved down, thus causing new linting errors. - Concatenate strings which now fit on just one line. - Fix comments that are now too long. - Finally, and most importantly, adjust comments that Prettier moved down, since the new positions often is confusing or outright wrong.
This commit is contained in:
parent
de36b2aaba
commit
a63f7ad486
46 changed files with 179 additions and 219 deletions
|
@ -22,7 +22,7 @@ import { GenericL10n } from "./genericl10n";
|
|||
|
||||
if (typeof PDFJSDev === "undefined" || !PDFJSDev.test("CHROME")) {
|
||||
throw new Error(
|
||||
'Module "pdfjs-web/chromecom" shall not be used outside ' + "CHROME build."
|
||||
'Module "pdfjs-web/chromecom" shall not be used outside CHROME build.'
|
||||
);
|
||||
}
|
||||
|
||||
|
@ -178,11 +178,9 @@ function requestAccessToLocalFile(fileUrl, overlayManager, callback) {
|
|||
// Use Chrome's definition of UI language instead of PDF.js's #lang=...,
|
||||
// because the shown string should match the UI at chrome://extensions.
|
||||
// These strings are from chrome/app/resources/generated_resources_*.xtb.
|
||||
/* eslint-disable no-unexpected-multiline */
|
||||
let i18nFileAccessLabel = PDFJSDev.json(
|
||||
"$ROOT/web/chrome-i18n-allow-access-to-file-urls.json"
|
||||
)[chrome.i18n.getUILanguage && chrome.i18n.getUILanguage()];
|
||||
/* eslint-enable no-unexpected-multiline */
|
||||
|
||||
if (i18nFileAccessLabel) {
|
||||
document.getElementById(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue