From c4ac3aacb4caac3490957e91081556bc0e6d48fe Mon Sep 17 00:00:00 2001 From: Tim van der Meij Date: Thu, 7 Mar 2019 23:49:44 +0100 Subject: [PATCH] Add missing pagemode values (thanks @Lekensteyn!) --- Viewer-options.md | 14 ++++++++++++++ Viewer-options.mediawiki | 14 -------------- 2 files changed, 14 insertions(+), 14 deletions(-) create mode 100644 Viewer-options.md delete mode 100644 Viewer-options.mediawiki diff --git a/Viewer-options.md b/Viewer-options.md new file mode 100644 index 0000000..d502c75 --- /dev/null +++ b/Viewer-options.md @@ -0,0 +1,14 @@ +Below are the options for the PDF.js viewer that can be given at URL level. Multiple values of either type can be combined by separating with an ampersand (`&`) after the hash (for example: `#page=2&zoom=200`). + +## Options after the \# +Example: https://mozilla.github.io/pdf.js/web/viewer.html#page=2 + +* page: page number. Example: page=2 +* zoom: zoom level. Example: zoom=200 (accepted formats: `[zoom],[left offset],[top offset]`, `page-width`, `page-height`, `page-fit`, `auto`) +* nameddest: go to a named destination +* pagemode: sidebar state. Example: `pagemode=none` (accepted values: `none`, `thumbs`, `bookmarks`, `attachments`) + +## Options after the ? +Example: https://mozilla.github.io/pdf.js/web/viewer.html?file=compressed.tracemonkey-pldi-09.pdf + +* file: the path of the PDF file to use (must be on the same server due to JavaScript limitations). Please notice that the path/URL must be encoded using `encodeURIComponent`, e.g. `/viewer.html?file=%2Fpdf.js%2Fweb%2Fcompressed.tracemonkey-pldi-09.pdf` \ No newline at end of file diff --git a/Viewer-options.mediawiki b/Viewer-options.mediawiki deleted file mode 100644 index 76cfb67..0000000 --- a/Viewer-options.mediawiki +++ /dev/null @@ -1,14 +0,0 @@ -Below are the options for the PDF.js viewer that can be given at URL level. Multiple values of either type can be combined by separating with an ampersand (&) after the hash (for example: #page=2&zoom=200). - -===Options after the #=== -Example: http://mozilla.github.io/pdf.js/web/viewer.html#page=2 - -* page: page number. Example: page=2 -* zoom: zoom level. Example: zoom=200 (accepted formats: `[zoom],[left offset],[top offset]`, `page-width`, `page-height`, `page-fit`, `auto`) -* nameddest: go to a named destination -* pagemode: either "thumbs" or "bookmarks". Example: pagemode=thumbs - -===Options after the ?=== -Example: http://mozilla.github.io/pdf.js/web/viewer.html?file=compressed.tracemonkey-pldi-09.pdf - -* file: the path of the PDF file to use (must be on the same server due to JavaScript limitations). Please notice that the path/URL must be encoded using encodeURIComponent(), e.g. "/viewer.html?file=%2Fpdf.js%2Fweb%2Fcompressed.tracemonkey-pldi-09.pdf" \ No newline at end of file