mirror of
https://github.com/zen-browser/pdf.js.git
synced 2025-07-08 01:10:08 +02:00
Convert a number of import * as pdfjsLib from 'pdfjs-web/pdfjs';
cases to only specify the necessary imports
Rather than always importing everything from the `web/pdfjs.js`, similar to all other imports we can just choose what we actually need.
This commit is contained in:
parent
3b35c15d42
commit
b2c3f8f081
14 changed files with 89 additions and 86 deletions
|
@ -13,9 +13,9 @@
|
|||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import * as pdfjsLib from 'pdfjs-web/pdfjs';
|
||||
import { mozL10n } from 'pdfjs-web/ui_utils';
|
||||
import { OverlayManager } from 'pdfjs-web/overlay_manager';
|
||||
import { PasswordResponses } from 'pdfjs-web/pdfjs';
|
||||
|
||||
/**
|
||||
* @typedef {Object} PasswordPromptOptions
|
||||
|
@ -71,7 +71,7 @@ var PasswordPrompt = (function PasswordPromptClosure() {
|
|||
var promptString = mozL10n.get('password_label', null,
|
||||
'Enter the password to open this PDF file.');
|
||||
|
||||
if (this.reason === pdfjsLib.PasswordResponses.INCORRECT_PASSWORD) {
|
||||
if (this.reason === PasswordResponses.INCORRECT_PASSWORD) {
|
||||
promptString = mozL10n.get('password_invalid', null,
|
||||
'Invalid password. Please try again.');
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue