mirror of
https://github.com/zen-browser/pdf.js.git
synced 2025-07-10 02:05:37 +02:00
Stop bundling the openFile-buttons in the MOZCENTRAL build
Note how both of the openFile-buttons are always hidden during viewer initialization in the MOZCENTRAL build, i.e. the *built-in* Firefox PDF Viewer. Despite that we still include HTML, CSS, and JavaScript code for these buttons in the build. This patch *reduces* the size of the `gulp mozcentral` output by `1679` bytes, which isn't a lot but still cannot hurt.
This commit is contained in:
parent
2be19e828f
commit
b04c373362
7 changed files with 32 additions and 9 deletions
|
@ -88,7 +88,10 @@ function getViewerConfiguration() {
|
|||
zoomIn: document.getElementById("zoomIn"),
|
||||
zoomOut: document.getElementById("zoomOut"),
|
||||
viewFind: document.getElementById("viewFind"),
|
||||
openFile: document.getElementById("openFile"),
|
||||
openFile:
|
||||
typeof PDFJSDev === "undefined" || !PDFJSDev.test("MOZCENTRAL")
|
||||
? document.getElementById("openFile")
|
||||
: null,
|
||||
print: document.getElementById("print"),
|
||||
presentationModeButton: document.getElementById("presentationMode"),
|
||||
download: document.getElementById("download"),
|
||||
|
@ -103,7 +106,10 @@ function getViewerConfiguration() {
|
|||
presentationModeButton: document.getElementById(
|
||||
"secondaryPresentationMode"
|
||||
),
|
||||
openFileButton: document.getElementById("secondaryOpenFile"),
|
||||
openFileButton:
|
||||
typeof PDFJSDev === "undefined" || !PDFJSDev.test("MOZCENTRAL")
|
||||
? document.getElementById("secondaryOpenFile")
|
||||
: null,
|
||||
printButton: document.getElementById("secondaryPrint"),
|
||||
downloadButton: document.getElementById("secondaryDownload"),
|
||||
viewBookmarkButton: document.getElementById("secondaryViewBookmark"),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue