Browse Source

Merge pull request #8469 from Snuffleupagus/ESLint-object-styles-web

Fix inconsistent spacing and trailing commas in objects in `web/` files, so we can enable the `comma-dangle` and `object-curly-spacing` ESLint rules later on
Tim van der Meij 8 years ago committed by GitHub
parent
commit
593dec1bb7
  1. 2
      web/annotation_layer_builder.js
  2. 34
      web/app.js
  3. 6
      web/chromecom.js
  4. 12
      web/debugger.js
  5. 14
      web/dom_events.js
  6. 4
      web/download_manager.js
  7. 6
      web/firefox_print_service.js
  8. 12
      web/firefoxcom.js
  9. 2
      web/grab_to_pan.js
  10. 6
      web/pdf_document_properties.js
  11. 12
      web/pdf_find_controller.js
  12. 14
      web/pdf_history.js
  13. 14
      web/pdf_link_service.js
  14. 4
      web/pdf_outline_viewer.js
  15. 4
      web/pdf_print_service.js
  16. 2
      web/pdf_sidebar.js
  17. 18
      web/pdf_thumbnail_view.js
  18. 4
      web/pdf_thumbnail_viewer.js
  19. 12
      web/pdf_viewer.js
  20. 2
      web/preferences.js
  21. 25
      web/secondary_toolbar.js
  22. 10
      web/text_layer_builder.js
  23. 6
      web/toolbar.js
  24. 12
      web/ui_utils.js
  25. 2
      web/view_history.js
  26. 10
      web/viewer.js

2
web/annotation_layer_builder.js

@ -49,7 +49,7 @@ class AnnotationLayerBuilder {
render(viewport, intent = 'display') { render(viewport, intent = 'display') {
this.pdfPage.getAnnotations({ intent, }).then((annotations) => { this.pdfPage.getAnnotations({ intent, }).then((annotations) => {
var parameters = { var parameters = {
viewport: viewport.clone({ dontFlip: true }), viewport: viewport.clone({ dontFlip: true, }),
div: this.div, div: this.div,
annotations, annotations,
page: this.pdfPage, page: this.pdfPage,

34
web/app.js

@ -22,7 +22,7 @@ import {
import { import {
build, createBlob, getDocument, getFilenameFromUrl, InvalidPDFException, build, createBlob, getDocument, getFilenameFromUrl, InvalidPDFException,
MissingPDFException, OPS, PDFJS, shadow, UnexpectedResponseException, MissingPDFException, OPS, PDFJS, shadow, UnexpectedResponseException,
UNSUPPORTED_FEATURES, version, UNSUPPORTED_FEATURES, version
} from 'pdfjs-lib'; } from 'pdfjs-lib';
import { CursorTool, PDFCursorTools } from './pdf_cursor_tools'; import { CursorTool, PDFCursorTools } from './pdf_cursor_tools';
import { PDFRenderingQueue, RenderingStates } from './pdf_rendering_queue'; import { PDFRenderingQueue, RenderingStates } from './pdf_rendering_queue';
@ -329,7 +329,7 @@ var PDFViewerApplication = {
container: thumbnailContainer, container: thumbnailContainer,
renderingQueue: pdfRenderingQueue, renderingQueue: pdfRenderingQueue,
linkService: pdfLinkService, linkService: pdfLinkService,
l10n: this.l10n l10n: this.l10n,
}); });
pdfRenderingQueue.setThumbnailViewer(this.pdfThumbnailViewer); pdfRenderingQueue.setThumbnailViewer(this.pdfThumbnailViewer);
@ -389,7 +389,7 @@ var PDFViewerApplication = {
viewer, viewer,
pdfViewer: this.pdfViewer, pdfViewer: this.pdfViewer,
eventBus, eventBus,
contextMenuItems: appConfig.fullscreen contextMenuItems: appConfig.fullscreen,
}); });
} }
@ -543,7 +543,7 @@ var PDFViewerApplication = {
}, },
onProgress(loaded, total) { onProgress(loaded, total) {
PDFViewerApplication.progress(loaded / total); PDFViewerApplication.progress(loaded / total);
} },
}); });
} else { } else {
throw new Error('Not implemented: initPassiveLoading'); throw new Error('Not implemented: initPassiveLoading');
@ -779,25 +779,25 @@ var PDFViewerApplication = {
*/ */
error: function pdfViewError(message, moreInfo) { error: function pdfViewError(message, moreInfo) {
let moreInfoText = [this.l10n.get('error_version_info', let moreInfoText = [this.l10n.get('error_version_info',
{version: version || '?', build: build || '?'}, { version: version || '?', build: build || '?', },
'PDF.js v{{version}} (build: {{build}})')]; 'PDF.js v{{version}} (build: {{build}})')];
if (moreInfo) { if (moreInfo) {
moreInfoText.push( moreInfoText.push(
this.l10n.get('error_message', {message: moreInfo.message}, this.l10n.get('error_message', { message: moreInfo.message, },
'Message: {{message}}')); 'Message: {{message}}'));
if (moreInfo.stack) { if (moreInfo.stack) {
moreInfoText.push( moreInfoText.push(
this.l10n.get('error_stack', {stack: moreInfo.stack}, this.l10n.get('error_stack', { stack: moreInfo.stack, },
'Stack: {{stack}}')); 'Stack: {{stack}}'));
} else { } else {
if (moreInfo.filename) { if (moreInfo.filename) {
moreInfoText.push( moreInfoText.push(
this.l10n.get('error_file', {file: moreInfo.filename}, this.l10n.get('error_file', { file: moreInfo.filename, },
'File: {{file}}')); 'File: {{file}}'));
} }
if (moreInfo.lineNumber) { if (moreInfo.lineNumber) {
moreInfoText.push( moreInfoText.push(
this.l10n.get('error_line', {line: moreInfo.lineNumber}, this.l10n.get('error_line', { line: moreInfo.lineNumber, },
'Line: {{line}}')); 'Line: {{line}}'));
} }
} }
@ -1133,7 +1133,7 @@ var PDFViewerApplication = {
this.initialDestination = null; this.initialDestination = null;
} else if (this.initialBookmark) { } else if (this.initialBookmark) {
this.pdfLinkService.setHash(this.initialBookmark); this.pdfLinkService.setHash(this.initialBookmark);
this.pdfHistory.push({ hash: this.initialBookmark }, true); this.pdfHistory.push({ hash: this.initialBookmark, }, true);
this.initialBookmark = null; this.initialBookmark = null;
} else if (storedHash) { } else if (storedHash) {
this.pdfLinkService.setHash(storedHash); this.pdfLinkService.setHash(storedHash);
@ -1215,7 +1215,7 @@ var PDFViewerApplication = {
if (typeof PDFJSDev !== 'undefined' && if (typeof PDFJSDev !== 'undefined' &&
PDFJSDev.test('FIREFOX || MOZCENTRAL')) { PDFJSDev.test('FIREFOX || MOZCENTRAL')) {
this.externalServices.reportTelemetry({ this.externalServices.reportTelemetry({
type: 'print' type: 'print',
}); });
} }
}, },
@ -1608,7 +1608,7 @@ function webViewerPageRendered(e) {
if (typeof PDFJSDev !== 'undefined' && if (typeof PDFJSDev !== 'undefined' &&
PDFJSDev.test('FIREFOX || MOZCENTRAL')) { PDFJSDev.test('FIREFOX || MOZCENTRAL')) {
PDFViewerApplication.externalServices.reportTelemetry({ PDFViewerApplication.externalServices.reportTelemetry({
type: 'pageInfo' type: 'pageInfo',
}); });
// It is a good time to report stream and font types. // It is a good time to report stream and font types.
PDFViewerApplication.pdfDocument.getStats().then(function (stats) { PDFViewerApplication.pdfDocument.getStats().then(function (stats) {
@ -1851,7 +1851,7 @@ function webViewerFind(e) {
phraseSearch: e.phraseSearch, phraseSearch: e.phraseSearch,
caseSensitive: e.caseSensitive, caseSensitive: e.caseSensitive,
highlightAll: e.highlightAll, highlightAll: e.highlightAll,
findPrevious: e.findPrevious findPrevious: e.findPrevious,
}); });
} }
@ -1861,7 +1861,7 @@ function webViewerFindFromUrlHash(e) {
phraseSearch: e.phraseSearch, phraseSearch: e.phraseSearch,
caseSensitive: false, caseSensitive: false,
highlightAll: true, highlightAll: true,
findPrevious: false findPrevious: false,
}); });
} }
@ -1989,7 +1989,7 @@ function webViewerKeyDown(evt) {
phraseSearch: findState.phraseSearch, phraseSearch: findState.phraseSearch,
caseSensitive: findState.caseSensitive, caseSensitive: findState.caseSensitive,
highlightAll: findState.highlightAll, highlightAll: findState.highlightAll,
findPrevious: cmd === 5 || cmd === 12 findPrevious: cmd === 5 || cmd === 12,
}); });
} }
handled = true; handled = true;
@ -2241,8 +2241,8 @@ var PDFPrintServiceFactory = {
supportsPrinting: false, supportsPrinting: false,
createPrintService() { createPrintService() {
throw new Error('Not implemented: createPrintService'); throw new Error('Not implemented: createPrintService');
} },
} },
}; };
export { export {

6
web/chromecom.js

@ -208,7 +208,7 @@ function requestAccessToLocalFile(fileUrl, overlayManager) {
// checkbox causes the extension to reload, and Chrome will close all // checkbox causes the extension to reload, and Chrome will close all
// tabs upon reload. // tabs upon reload.
ChromeCom.request('openExtensionsPageForFileAccess', { ChromeCom.request('openExtensionsPageForFileAccess', {
newTab: e.ctrlKey || e.metaKey || e.button === 1 || window !== top newTab: e.ctrlKey || e.metaKey || e.button === 1 || window !== top,
}); });
}; };
@ -254,14 +254,14 @@ function setReferer(url, callback) {
if (!port) { if (!port) {
// The background page will accept the port, and keep adding the Referer // The background page will accept the port, and keep adding the Referer
// request header to requests to |url| until the port is disconnected. // request header to requests to |url| until the port is disconnected.
port = chrome.runtime.connect({name: 'chromecom-referrer'}); port = chrome.runtime.connect({ name: 'chromecom-referrer', });
} }
port.onDisconnect.addListener(onDisconnect); port.onDisconnect.addListener(onDisconnect);
port.onMessage.addListener(onMessage); port.onMessage.addListener(onMessage);
// Initiate the information exchange. // Initiate the information exchange.
port.postMessage({ port.postMessage({
referer: window.history.state && window.history.state.chromecomState, referer: window.history.state && window.history.state.chromecomState,
requestUrl: url requestUrl: url,
}); });
function onMessage(referer) { function onMessage(referer) {

12
web/debugger.js

@ -119,7 +119,7 @@ var FontInspector = (function FontInspectorClosure() {
download.href = url[1]; download.href = url[1];
} else if (fontObj.data) { } else if (fontObj.data) {
url = URL.createObjectURL(new Blob([fontObj.data], { url = URL.createObjectURL(new Blob([fontObj.data], {
type: fontObj.mimeType type: fontObj.mimeType,
})); }));
download.href = url; download.href = url;
} }
@ -154,7 +154,7 @@ var FontInspector = (function FontInspectorClosure() {
resetSelection(); resetSelection();
} }
}, 2000); }, 2000);
} },
}; };
})(); })();
@ -243,7 +243,7 @@ var StepperManager = (function StepperManagerClosure() {
saveBreakPoints: function saveBreakPoints(pageIndex, bps) { saveBreakPoints: function saveBreakPoints(pageIndex, bps) {
breakPoints[pageIndex] = bps; breakPoints[pageIndex] = bps;
sessionStorage.setItem('pdfjsBreakPoints', JSON.stringify(breakPoints)); sessionStorage.setItem('pdfjsBreakPoints', JSON.stringify(breakPoints));
} },
}; };
})(); })();
@ -433,7 +433,7 @@ var Stepper = (function StepperClosure() {
row.style.backgroundColor = null; row.style.backgroundColor = null;
} }
} }
} },
}; };
return Stepper; return Stepper;
})(); })();
@ -497,7 +497,7 @@ var Stats = (function Stats() {
cleanup() { cleanup() {
stats = []; stats = [];
clear(this.panel); clear(this.panel);
} },
}; };
})(); })();
@ -615,6 +615,6 @@ window.PDFBug = (function PDFBugClosure() {
tools[j].panel.setAttribute('hidden', 'true'); tools[j].panel.setAttribute('hidden', 'true');
} }
} }
} },
}; };
})(); })();

14
web/dom_events.js

@ -34,7 +34,7 @@ function attachDOMEventsToEventBus(eventBus) {
eventBus.on('textlayerrendered', function (e) { eventBus.on('textlayerrendered', function (e) {
var event = document.createEvent('CustomEvent'); var event = document.createEvent('CustomEvent');
event.initCustomEvent('textlayerrendered', true, true, { event.initCustomEvent('textlayerrendered', true, true, {
pageNumber: e.pageNumber pageNumber: e.pageNumber,
}); });
e.source.textLayerDiv.dispatchEvent(event); e.source.textLayerDiv.dispatchEvent(event);
}); });
@ -52,7 +52,7 @@ function attachDOMEventsToEventBus(eventBus) {
eventBus.on('pagesloaded', function (e) { eventBus.on('pagesloaded', function (e) {
var event = document.createEvent('CustomEvent'); var event = document.createEvent('CustomEvent');
event.initCustomEvent('pagesloaded', true, true, { event.initCustomEvent('pagesloaded', true, true, {
pagesCount: e.pagesCount pagesCount: e.pagesCount,
}); });
e.source.container.dispatchEvent(event); e.source.container.dispatchEvent(event);
}); });
@ -79,14 +79,14 @@ function attachDOMEventsToEventBus(eventBus) {
phraseSearch: e.phraseSearch, phraseSearch: e.phraseSearch,
caseSensitive: e.caseSensitive, caseSensitive: e.caseSensitive,
highlightAll: e.highlightAll, highlightAll: e.highlightAll,
findPrevious: e.findPrevious findPrevious: e.findPrevious,
}); });
window.dispatchEvent(event); window.dispatchEvent(event);
}); });
eventBus.on('attachmentsloaded', function (e) { eventBus.on('attachmentsloaded', function (e) {
var event = document.createEvent('CustomEvent'); var event = document.createEvent('CustomEvent');
event.initCustomEvent('attachmentsloaded', true, true, { event.initCustomEvent('attachmentsloaded', true, true, {
attachmentsCount: e.attachmentsCount attachmentsCount: e.attachmentsCount,
}); });
e.source.container.dispatchEvent(event); e.source.container.dispatchEvent(event);
}); });
@ -107,7 +107,7 @@ function attachDOMEventsToEventBus(eventBus) {
eventBus.on('namedaction', function (e) { eventBus.on('namedaction', function (e) {
var event = document.createEvent('CustomEvent'); var event = document.createEvent('CustomEvent');
event.initCustomEvent('namedaction', true, true, { event.initCustomEvent('namedaction', true, true, {
action: e.action action: e.action,
}); });
e.source.pdfViewer.container.dispatchEvent(event); e.source.pdfViewer.container.dispatchEvent(event);
}); });
@ -115,14 +115,14 @@ function attachDOMEventsToEventBus(eventBus) {
var event = document.createEvent('CustomEvent'); var event = document.createEvent('CustomEvent');
event.initCustomEvent('presentationmodechanged', true, true, { event.initCustomEvent('presentationmodechanged', true, true, {
active: e.active, active: e.active,
switchInProgress: e.switchInProgress switchInProgress: e.switchInProgress,
}); });
window.dispatchEvent(event); window.dispatchEvent(event);
}); });
eventBus.on('outlineloaded', function (e) { eventBus.on('outlineloaded', function (e) {
var event = document.createEvent('CustomEvent'); var event = document.createEvent('CustomEvent');
event.initCustomEvent('outlineloaded', true, true, { event.initCustomEvent('outlineloaded', true, true, {
outlineCount: e.outlineCount outlineCount: e.outlineCount,
}); });
e.source.container.dispatchEvent(event); e.source.container.dispatchEvent(event);
}); });

4
web/download_manager.js

@ -69,7 +69,7 @@ DownloadManager.prototype = {
downloadData: function DownloadManager_downloadData(data, filename, downloadData: function DownloadManager_downloadData(data, filename,
contentType) { contentType) {
if (navigator.msSaveBlob) { // IE10 and above if (navigator.msSaveBlob) { // IE10 and above
return navigator.msSaveBlob(new Blob([data], { type: contentType }), return navigator.msSaveBlob(new Blob([data], { type: contentType, }),
filename); filename);
} }
@ -95,7 +95,7 @@ DownloadManager.prototype = {
var blobUrl = URL.createObjectURL(blob); var blobUrl = URL.createObjectURL(blob);
download(blobUrl, filename); download(blobUrl, filename);
} },
}; };
export { export {

6
web/firefox_print_service.js

@ -49,7 +49,7 @@ function composePage(pdfDocument, pageNumber, size, printContainer) {
canvasContext: ctx, canvasContext: ctx,
transform: [PRINT_UNITS, 0, 0, PRINT_UNITS, 0, 0], transform: [PRINT_UNITS, 0, 0, PRINT_UNITS, 0, 0],
viewport: pdfPage.getViewport(1, size.rotation), viewport: pdfPage.getViewport(1, size.rotation),
intent: 'print' intent: 'print',
}; };
return pdfPage.render(renderContext).promise; return pdfPage.render(renderContext).promise;
}).then(function() { }).then(function() {
@ -88,7 +88,7 @@ FirefoxPrintService.prototype = {
destroy() { destroy() {
this.printContainer.textContent = ''; this.printContainer.textContent = '';
} },
}; };
PDFPrintServiceFactory.instance = { PDFPrintServiceFactory.instance = {
@ -101,7 +101,7 @@ PDFPrintServiceFactory.instance = {
createPrintService(pdfDocument, pagesOverview, printContainer) { createPrintService(pdfDocument, pagesOverview, printContainer) {
return new FirefoxPrintService(pdfDocument, pagesOverview, printContainer); return new FirefoxPrintService(pdfDocument, pagesOverview, printContainer);
} },
}; };
export { export {

12
web/firefoxcom.js

@ -75,10 +75,10 @@ var FirefoxCom = (function FirefoxComClosure() {
action, action,
data, data,
sync: false, sync: false,
responseExpected: !!callback responseExpected: !!callback,
}); });
return request.dispatchEvent(sender); return request.dispatchEvent(sender);
} },
}; };
})(); })();
@ -101,7 +101,7 @@ var DownloadManager = (function DownloadManagerClosure() {
blobUrl, blobUrl,
originalUrl: blobUrl, originalUrl: blobUrl,
filename, filename,
isAttachment: true isAttachment: true,
}); });
}, },
@ -119,7 +119,7 @@ var DownloadManager = (function DownloadManagerClosure() {
originalUrl: url, originalUrl: url,
filename, filename,
}, onResponse); }, onResponse);
} },
}; };
return DownloadManager; return DownloadManager;
@ -179,7 +179,7 @@ class MozL10n {
phraseSearch: true, phraseSearch: true,
caseSensitive: !!evt.detail.caseSensitive, caseSensitive: !!evt.detail.caseSensitive,
highlightAll: !!evt.detail.highlightAll, highlightAll: !!evt.detail.highlightAll,
findPrevious: !!evt.detail.findPrevious findPrevious: !!evt.detail.findPrevious,
}); });
}; };
@ -305,7 +305,7 @@ document.mozL10n.setExternalLocalizerServices({
getStrings(key) { getStrings(key) {
return FirefoxCom.requestSync('getStrings', key); return FirefoxCom.requestSync('getStrings', key);
} },
}); });
export { export {

2
web/grab_to_pan.js

@ -175,7 +175,7 @@ GrabToPan.prototype = {
this.document.removeEventListener('mouseup', this._endPan, true); this.document.removeEventListener('mouseup', this._endPan, true);
// Note: ChildNode.remove doesn't throw if the parentNode is undefined. // Note: ChildNode.remove doesn't throw if the parentNode is undefined.
this.overlay.remove(); this.overlay.remove();
} },
}; };
// Get the correct (vendor-prefixed) name of the matches method. // Get the correct (vendor-prefixed) name of the matches method.

6
web/pdf_document_properties.js

@ -201,12 +201,12 @@ class PDFDocumentProperties {
} else if (kb < 1024) { } else if (kb < 1024) {
return this.l10n.get('document_properties_kb', { return this.l10n.get('document_properties_kb', {
size_kb: (+kb.toPrecision(3)).toLocaleString(), size_kb: (+kb.toPrecision(3)).toLocaleString(),
size_b: fileSize.toLocaleString() size_b: fileSize.toLocaleString(),
}, '{{size_kb}} KB ({{size_b}} bytes)'); }, '{{size_kb}} KB ({{size_b}} bytes)');
} }
return this.l10n.get('document_properties_mb', { return this.l10n.get('document_properties_mb', {
size_mb: (+(kb / 1024).toPrecision(3)).toLocaleString(), size_mb: (+(kb / 1024).toPrecision(3)).toLocaleString(),
size_b: fileSize.toLocaleString() size_b: fileSize.toLocaleString(),
}, '{{size_mb}} MB ({{size_b}} bytes)'); }, '{{size_mb}} MB ({{size_b}} bytes)');
} }
@ -256,7 +256,7 @@ class PDFDocumentProperties {
var dateString = date.toLocaleDateString(); var dateString = date.toLocaleDateString();
var timeString = date.toLocaleTimeString(); var timeString = date.toLocaleTimeString();
return this.l10n.get('document_properties_date_string', return this.l10n.get('document_properties_date_string',
{ date: dateString, time: timeString }, { date: dateString, time: timeString, },
'{{date}}, {{time}}'); '{{date}}, {{time}}');
} }
} }

12
web/pdf_find_controller.js

@ -20,7 +20,7 @@ var FindStates = {
FIND_FOUND: 0, FIND_FOUND: 0,
FIND_NOTFOUND: 1, FIND_NOTFOUND: 1,
FIND_WRAPPED: 2, FIND_WRAPPED: 2,
FIND_PENDING: 3 FIND_PENDING: 3,
}; };
var FIND_SCROLL_OFFSET_TOP = -50; var FIND_SCROLL_OFFSET_TOP = -50;
@ -70,11 +70,11 @@ var PDFFindController = (function PDFFindControllerClosure() {
this.matchCount = 0; this.matchCount = 0;
this.selected = { // Currently selected match. this.selected = { // Currently selected match.
pageIdx: -1, pageIdx: -1,
matchIdx: -1 matchIdx: -1,
}; };
this.offset = { // Where the find algorithm currently is in the document. this.offset = { // Where the find algorithm currently is in the document.
pageIdx: null, pageIdx: null,
matchIdx: null matchIdx: null,
}; };
this.pagesToSearch = null; this.pagesToSearch = null;
this.resumePageIdx = null; this.resumePageIdx = null;
@ -180,7 +180,7 @@ var PDFFindController = (function PDFFindControllerClosure() {
matchesWithLength.push({ matchesWithLength.push({
match: matchIdx, match: matchIdx,
matchLength: subqueryLen, matchLength: subqueryLen,
skipped: false skipped: false,
}); });
} }
} }
@ -406,7 +406,7 @@ var PDFFindController = (function PDFFindControllerClosure() {
this.selected.pageIdx === pageIndex) { this.selected.pageIdx === pageIndex) {
var spot = { var spot = {
top: FIND_SCROLL_OFFSET_TOP, top: FIND_SCROLL_OFFSET_TOP,
left: FIND_SCROLL_OFFSET_LEFT left: FIND_SCROLL_OFFSET_LEFT,
}; };
scrollIntoView(elements[beginIdx], spot, scrollIntoView(elements[beginIdx], spot,
/* skipOverflowHiddenElements = */ true); /* skipOverflowHiddenElements = */ true);
@ -476,7 +476,7 @@ var PDFFindController = (function PDFFindControllerClosure() {
if (this.onUpdateState) { if (this.onUpdateState) {
this.onUpdateState(state, previous, this.matchCount); this.onUpdateState(state, previous, this.matchCount);
} }
} },
}; };
return PDFFindController; return PDFFindController;
})(); })();

14
web/pdf_history.js

@ -68,7 +68,7 @@ PDFHistory.prototype = {
// is opened in the web viewer. // is opened in the web viewer.
this.reInitialized = true; this.reInitialized = true;
} }
this._pushOrReplaceState({fingerprint: this.fingerprint}, true); this._pushOrReplaceState({ fingerprint: this.fingerprint, }, true);
} }
var self = this; var self = this;
@ -95,8 +95,8 @@ PDFHistory.prototype = {
// Replace the previous state if it was not explicitly set. // Replace the previous state if it was not explicitly set.
var previousParams = (self.previousHash && self.currentBookmark && var previousParams = (self.previousHash && self.currentBookmark &&
self.previousHash !== self.currentBookmark) ? self.previousHash !== self.currentBookmark) ?
{hash: self.currentBookmark, page: self.currentPage} : { hash: self.currentBookmark, page: self.currentPage, } :
{page: 1}; { page: 1, };
replacePreviousHistoryState(previousParams, function() { replacePreviousHistoryState(previousParams, function() {
updateHistoryWithCurrentHash(); updateHistoryWithCurrentHash();
}); });
@ -108,7 +108,7 @@ PDFHistory.prototype = {
function updateHistoryWithCurrentHash() { function updateHistoryWithCurrentHash() {
self.previousHash = window.location.hash.slice(1); self.previousHash = window.location.hash.slice(1);
self._pushToHistory({hash: self.previousHash}, false, true); self._pushToHistory({ hash: self.previousHash, }, false, true);
self._updatePreviousBookmark(); self._updatePreviousBookmark();
} }
@ -329,7 +329,7 @@ PDFHistory.prototype = {
} else { } else {
return null; return null;
} }
var params = {hash: this.currentBookmark, page: this.currentPage}; var params = { hash: this.currentBookmark, page: this.currentPage, };
if (this.isViewerInPresentationMode) { if (this.isViewerInPresentationMode) {
params.hash = null; params.hash = null;
} }
@ -337,7 +337,7 @@ PDFHistory.prototype = {
}, },
_stateObj: function pdfHistory_stateObj(params) { _stateObj: function pdfHistory_stateObj(params) {
return {fingerprint: this.fingerprint, uid: this.uid, target: params}; return { fingerprint: this.fingerprint, uid: this.uid, target: params, };
}, },
_pushToHistory: function pdfHistory_pushToHistory(params, _pushToHistory: function pdfHistory_pushToHistory(params,
@ -418,7 +418,7 @@ PDFHistory.prototype = {
window.history.forward(); window.history.forward();
} }
} }
} },
}; };
export { export {

14
web/pdf_link_service.js

@ -189,7 +189,7 @@ var PDFLinkService = (function PDFLinkServiceClosure() {
this.eventBus.dispatch('findfromurlhash', { this.eventBus.dispatch('findfromurlhash', {
source: this, source: this,
query: params['search'].replace(/"/g, ''), query: params['search'].replace(/"/g, ''),
phraseSearch: (params['phrase'] === 'true') phraseSearch: (params['phrase'] === 'true'),
}); });
} }
// borrowing syntax from "Parameters for Opening PDF Files" // borrowing syntax from "Parameters for Opening PDF Files"
@ -212,23 +212,23 @@ var PDFLinkService = (function PDFLinkServiceClosure() {
if (zoomArg.indexOf('Fit') === -1) { if (zoomArg.indexOf('Fit') === -1) {
// If the zoomArg is a number, it has to get divided by 100. If it's // If the zoomArg is a number, it has to get divided by 100. If it's
// a string, it should stay as it is. // a string, it should stay as it is.
dest = [null, { name: 'XYZ' }, dest = [null, { name: 'XYZ', },
zoomArgs.length > 1 ? (zoomArgs[1] | 0) : null, zoomArgs.length > 1 ? (zoomArgs[1] | 0) : null,
zoomArgs.length > 2 ? (zoomArgs[2] | 0) : null, zoomArgs.length > 2 ? (zoomArgs[2] | 0) : null,
(zoomArgNumber ? zoomArgNumber / 100 : zoomArg)]; (zoomArgNumber ? zoomArgNumber / 100 : zoomArg)];
} else { } else {
if (zoomArg === 'Fit' || zoomArg === 'FitB') { if (zoomArg === 'Fit' || zoomArg === 'FitB') {
dest = [null, { name: zoomArg }]; dest = [null, { name: zoomArg, }];
} else if ((zoomArg === 'FitH' || zoomArg === 'FitBH') || } else if ((zoomArg === 'FitH' || zoomArg === 'FitBH') ||
(zoomArg === 'FitV' || zoomArg === 'FitBV')) { (zoomArg === 'FitV' || zoomArg === 'FitBV')) {
dest = [null, { name: zoomArg }, dest = [null, { name: zoomArg, },
zoomArgs.length > 1 ? (zoomArgs[1] | 0) : null]; zoomArgs.length > 1 ? (zoomArgs[1] | 0) : null];
} else if (zoomArg === 'FitR') { } else if (zoomArg === 'FitR') {
if (zoomArgs.length !== 5) { if (zoomArgs.length !== 5) {
console.error('PDFLinkService_setHash: ' + console.error('PDFLinkService_setHash: ' +
'Not enough parameters for \'FitR\'.'); 'Not enough parameters for \'FitR\'.');
} else { } else {
dest = [null, { name: zoomArg }, dest = [null, { name: zoomArg, },
(zoomArgs[1] | 0), (zoomArgs[2] | 0), (zoomArgs[1] | 0), (zoomArgs[2] | 0),
(zoomArgs[3] | 0), (zoomArgs[4] | 0)]; (zoomArgs[3] | 0), (zoomArgs[4] | 0)];
} }
@ -250,7 +250,7 @@ var PDFLinkService = (function PDFLinkServiceClosure() {
if ('pagemode' in params) { if ('pagemode' in params) {
this.eventBus.dispatch('pagemode', { this.eventBus.dispatch('pagemode', {
source: this, source: this,
mode: params.pagemode mode: params.pagemode,
}); });
} }
} else { // Named (or explicit) destination. } else { // Named (or explicit) destination.
@ -465,7 +465,7 @@ var SimpleLinkService = (function SimpleLinkServiceClosure() {
* @param {number} pageNum - page number. * @param {number} pageNum - page number.
* @param {Object} pageRef - reference to the page. * @param {Object} pageRef - reference to the page.
*/ */
cachePageRef(pageNum, pageRef) {} cachePageRef(pageNum, pageRef) {},
}; };
return SimpleLinkService; return SimpleLinkService;
})(); })();

4
web/pdf_outline_viewer.js

@ -171,7 +171,7 @@ class PDFOutlineViewer {
} }
var fragment = document.createDocumentFragment(); var fragment = document.createDocumentFragment();
var queue = [{ parent: fragment, items: this.outline }]; var queue = [{ parent: fragment, items: this.outline, }];
var hasAnyNesting = false; var hasAnyNesting = false;
while (queue.length > 0) { while (queue.length > 0) {
var levelData = queue.shift(); var levelData = queue.shift();
@ -196,7 +196,7 @@ class PDFOutlineViewer {
var itemsDiv = document.createElement('div'); var itemsDiv = document.createElement('div');
itemsDiv.className = 'outlineItems'; itemsDiv.className = 'outlineItems';
div.appendChild(itemsDiv); div.appendChild(itemsDiv);
queue.push({ parent: itemsDiv, items: item.items }); queue.push({ parent: itemsDiv, items: item.items, });
} }
levelData.parent.appendChild(div); levelData.parent.appendChild(div);

4
web/pdf_print_service.js

@ -46,7 +46,7 @@ function renderPage(activeServiceOnEntry, pdfDocument, pageNumber, size) {
canvasContext: ctx, canvasContext: ctx,
transform: [PRINT_UNITS, 0, 0, PRINT_UNITS, 0, 0], transform: [PRINT_UNITS, 0, 0, PRINT_UNITS, 0, 0],
viewport: pdfPage.getViewport(1, size.rotation), viewport: pdfPage.getViewport(1, size.rotation),
intent: 'print' intent: 'print',
}; };
return pdfPage.render(renderContext).promise; return pdfPage.render(renderContext).promise;
}).then(function () { }).then(function () {
@ -337,7 +337,7 @@ PDFPrintServiceFactory.instance = {
activeService = new PDFPrintService(pdfDocument, pagesOverview, activeService = new PDFPrintService(pdfDocument, pagesOverview,
printContainer, l10n); printContainer, l10n);
return activeService; return activeService;
} },
}; };
export { export {

2
web/pdf_sidebar.js

@ -22,7 +22,7 @@ const SidebarView = {
NONE: 0, NONE: 0,
THUMBS: 1, THUMBS: 1,
OUTLINE: 2, OUTLINE: 2,
ATTACHMENTS: 3 ATTACHMENTS: 3,
}; };
/** /**

18
web/pdf_thumbnail_view.js

@ -123,7 +123,7 @@ var PDFThumbnailView = (function PDFThumbnailViewClosure() {
var anchor = document.createElement('a'); var anchor = document.createElement('a');
anchor.href = linkService.getAnchorUrl('#page=' + id); anchor.href = linkService.getAnchorUrl('#page=' + id);
this.l10n.get('thumb_page_title', {page: id}, 'Page {{page}}'). this.l10n.get('thumb_page_title', { page: id, }, 'Page {{page}}').
then((msg) => { then((msg) => {
anchor.title = msg; anchor.title = msg;
}); });
@ -205,7 +205,7 @@ var PDFThumbnailView = (function PDFThumbnailViewClosure() {
var totalRotation = (this.rotation + this.pdfPageRotate) % 360; var totalRotation = (this.rotation + this.pdfPageRotate) % 360;
this.viewport = this.viewport.clone({ this.viewport = this.viewport.clone({
scale: 1, scale: 1,
rotation: totalRotation rotation: totalRotation,
}); });
this.reset(); this.reset();
}, },
@ -233,7 +233,7 @@ var PDFThumbnailView = (function PDFThumbnailViewClosure() {
PDFJSDev.test('MOZCENTRAL || FIREFOX || GENERIC')) { PDFJSDev.test('MOZCENTRAL || FIREFOX || GENERIC')) {
canvas.mozOpaque = true; canvas.mozOpaque = true;
} }
var ctx = canvas.getContext('2d', {alpha: false}); var ctx = canvas.getContext('2d', { alpha: false, });
var outputScale = getOutputScale(ctx); var outputScale = getOutputScale(ctx);
canvas.width = (this.canvasWidth * outputScale.sx) | 0; canvas.width = (this.canvasWidth * outputScale.sx) | 0;
@ -263,7 +263,7 @@ var PDFThumbnailView = (function PDFThumbnailViewClosure() {
if (this.disableCanvasToImageConversion) { if (this.disableCanvasToImageConversion) {
this.canvas.id = id; this.canvas.id = id;
this.canvas.className = className; this.canvas.className = className;
this.l10n.get('thumb_page_canvas', { page: this.pageId }, this.l10n.get('thumb_page_canvas', { page: this.pageId, },
'Thumbnail of Page {{page}}').then((msg) => { 'Thumbnail of Page {{page}}').then((msg) => {
this.canvas.setAttribute('aria-label', msg); this.canvas.setAttribute('aria-label', msg);
}); });
@ -275,7 +275,7 @@ var PDFThumbnailView = (function PDFThumbnailViewClosure() {
var image = document.createElement('img'); var image = document.createElement('img');
image.id = id; image.id = id;
image.className = className; image.className = className;
this.l10n.get('thumb_page_canvas', { page: this.pageId }, this.l10n.get('thumb_page_canvas', { page: this.pageId, },
'Thumbnail of Page {{page}}'). 'Thumbnail of Page {{page}}').
then((msg) => { then((msg) => {
image.setAttribute('aria-label', msg); image.setAttribute('aria-label', msg);
@ -348,7 +348,7 @@ var PDFThumbnailView = (function PDFThumbnailViewClosure() {
let renderContext = { let renderContext = {
canvasContext: ctx, canvasContext: ctx,
viewport: drawViewport viewport: drawViewport,
}; };
let renderTask = this.renderTask = this.pdfPage.render(renderContext); let renderTask = this.renderTask = this.pdfPage.render(renderContext);
renderTask.onContinue = renderContinueCallback; renderTask.onContinue = renderContinueCallback;
@ -420,8 +420,8 @@ var PDFThumbnailView = (function PDFThumbnailViewClosure() {
setPageLabel: function PDFThumbnailView_setPageLabel(label) { setPageLabel: function PDFThumbnailView_setPageLabel(label) {
this.pageLabel = (typeof label === 'string' ? label : null); this.pageLabel = (typeof label === 'string' ? label : null);
this.l10n.get('thumb_page_title', { page: this.pageId }, 'Page {{page}}'). this.l10n.get('thumb_page_title', { page: this.pageId, },
then((msg) => { 'Page {{page}}').then((msg) => {
this.anchor.title = msg; this.anchor.title = msg;
}); });
@ -429,7 +429,7 @@ var PDFThumbnailView = (function PDFThumbnailViewClosure() {
return; return;
} }
this.l10n.get('thumb_page_canvas', { page: this.pageId }, this.l10n.get('thumb_page_canvas', { page: this.pageId, },
'Thumbnail of Page {{page}}').then((ariaLabel) => { 'Thumbnail of Page {{page}}').then((ariaLabel) => {
if (this.image) { if (this.image) {
this.image.setAttribute('aria-label', ariaLabel); this.image.setAttribute('aria-label', ariaLabel);

4
web/pdf_thumbnail_viewer.js

@ -88,7 +88,7 @@ var PDFThumbnailViewer = (function PDFThumbnailViewerClosure() {
// Account for only one thumbnail being visible. // Account for only one thumbnail being visible.
var last = (numVisibleThumbs > 1 ? visibleThumbs.last.id : first); var last = (numVisibleThumbs > 1 ? visibleThumbs.last.id : first);
if (page <= first || page >= last) { if (page <= first || page >= last) {
scrollIntoView(thumbnail, { top: THUMBNAIL_SCROLL_MARGIN }); scrollIntoView(thumbnail, { top: THUMBNAIL_SCROLL_MARGIN, });
} }
} }
}, },
@ -220,7 +220,7 @@ var PDFThumbnailViewer = (function PDFThumbnailViewerClosure() {
return true; return true;
} }
return false; return false;
} },
}; };
return PDFThumbnailViewer; return PDFThumbnailViewer;

12
web/pdf_viewer.js

@ -400,7 +400,7 @@ var PDFViewer = (function pdfViewer() {
} }
}); });
this.eventBus.dispatch('pagesinit', { source: this }); this.eventBus.dispatch('pagesinit', { source: this, });
if (this.defaultRenderingQueue) { if (this.defaultRenderingQueue) {
this.update(); this.update();
@ -467,7 +467,7 @@ var PDFViewer = (function pdfViewer() {
var arg = { var arg = {
source: this, source: this,
scale: newScale, scale: newScale,
presetValue: preset ? newValue : undefined presetValue: preset ? newValue : undefined,
}; };
this.eventBus.dispatch('scalechanging', arg); this.eventBus.dispatch('scalechanging', arg);
this.eventBus.dispatch('scalechange', arg); this.eventBus.dispatch('scalechange', arg);
@ -494,7 +494,7 @@ var PDFViewer = (function pdfViewer() {
if (this._location && !PDFJS.ignoreCurrentPositionOnZoom && if (this._location && !PDFJS.ignoreCurrentPositionOnZoom &&
!(this.isInPresentationMode || this.isChangingPresentationMode)) { !(this.isInPresentationMode || this.isChangingPresentationMode)) {
page = this._location.pageNumber; page = this._location.pageNumber;
dest = [null, { name: 'XYZ' }, this._location.left, dest = [null, { name: 'XYZ', }, this._location.left,
this._location.top, null]; this._location.top, null];
} }
this.scrollPageIntoView({ this.scrollPageIntoView({
@ -776,7 +776,7 @@ var PDFViewer = (function pdfViewer() {
this.eventBus.dispatch('updateviewarea', { this.eventBus.dispatch('updateviewarea', {
source: this, source: this,
location: this._location location: this._location,
}); });
}, },
@ -809,8 +809,8 @@ var PDFViewer = (function pdfViewer() {
// configurations when presentation mode is active. // configurations when presentation mode is active.
var visible = []; var visible = [];
var currentPage = this._pages[this._currentPageNumber - 1]; var currentPage = this._pages[this._currentPageNumber - 1];
visible.push({ id: currentPage.id, view: currentPage }); visible.push({ id: currentPage.id, view: currentPage, });
return { first: currentPage, last: currentPage, views: visible }; return { first: currentPage, last: currentPage, views: visible, };
}, },
cleanup() { cleanup() {

2
web/preferences.js

@ -57,7 +57,7 @@ class BasePreferences {
value: Object.freeze(defaults), value: Object.freeze(defaults),
writable: false, writable: false,
enumerable: true, enumerable: true,
configurable: false configurable: false,
}); });
this.prefs = cloneObj(defaults); this.prefs = cloneObj(defaults);

25
web/secondary_toolbar.js

@ -60,23 +60,24 @@ class SecondaryToolbar {
this.toolbarButtonContainer = options.toolbarButtonContainer; this.toolbarButtonContainer = options.toolbarButtonContainer;
this.buttons = [ this.buttons = [
{ element: options.presentationModeButton, eventName: 'presentationmode', { element: options.presentationModeButton, eventName: 'presentationmode',
close: true }, close: true, },
{ element: options.openFileButton, eventName: 'openfile', close: true }, { element: options.openFileButton, eventName: 'openfile', close: true, },
{ element: options.printButton, eventName: 'print', close: true }, { element: options.printButton, eventName: 'print', close: true, },
{ element: options.downloadButton, eventName: 'download', close: true }, { element: options.downloadButton, eventName: 'download', close: true, },
{ element: options.viewBookmarkButton, eventName: null, close: true }, { element: options.viewBookmarkButton, eventName: null, close: true, },
{ element: options.firstPageButton, eventName: 'firstpage', close: true }, { element: options.firstPageButton, eventName: 'firstpage',
{ element: options.lastPageButton, eventName: 'lastpage', close: true }, close: true, },
{ element: options.lastPageButton, eventName: 'lastpage', close: true, },
{ element: options.pageRotateCwButton, eventName: 'rotatecw', { element: options.pageRotateCwButton, eventName: 'rotatecw',
close: false }, close: false, },
{ element: options.pageRotateCcwButton, eventName: 'rotateccw', { element: options.pageRotateCcwButton, eventName: 'rotateccw',
close: false }, close: false, },
{ element: options.cursorSelectToolButton, eventName: 'switchcursortool', { element: options.cursorSelectToolButton, eventName: 'switchcursortool',
eventDetails: { tool: CursorTool.SELECT, }, close: true }, eventDetails: { tool: CursorTool.SELECT, }, close: true, },
{ element: options.cursorHandToolButton, eventName: 'switchcursortool', { element: options.cursorHandToolButton, eventName: 'switchcursortool',
eventDetails: { tool: CursorTool.HAND, }, close: true }, eventDetails: { tool: CursorTool.HAND, }, close: true, },
{ element: options.documentPropertiesButton, { element: options.documentPropertiesButton,
eventName: 'documentproperties', close: true } eventName: 'documentproperties', close: true, },
]; ];
this.items = { this.items = {
firstPage: options.firstPageButton, firstPage: options.firstPageButton,

10
web/text_layer_builder.js

@ -147,8 +147,8 @@ var TextLayerBuilder = (function TextLayerBuilderClosure() {
var match = { var match = {
begin: { begin: {
divIdx: i, divIdx: i,
offset: matchIdx - iIndex offset: matchIdx - iIndex,
} },
}; };
// Calculate the end position. // Calculate the end position.
@ -167,7 +167,7 @@ var TextLayerBuilder = (function TextLayerBuilderClosure() {
match.end = { match.end = {
divIdx: i, divIdx: i,
offset: matchIdx - iIndex offset: matchIdx - iIndex,
}; };
ret.push(match); ret.push(match);
} }
@ -193,7 +193,7 @@ var TextLayerBuilder = (function TextLayerBuilderClosure() {
false : this.findController.state.highlightAll); false : this.findController.state.highlightAll);
var infinity = { var infinity = {
divIdx: -1, divIdx: -1,
offset: undefined offset: undefined,
}; };
function beginText(begin, className) { function beginText(begin, className) {
@ -405,7 +405,7 @@ DefaultTextLayerFactory.prototype = {
viewport, viewport,
enhanceTextSelection, enhanceTextSelection,
}); });
} },
}; };
export { export {

6
web/toolbar.js

@ -128,7 +128,7 @@ var Toolbar = (function ToolbarClosure() {
items.pageNumber.addEventListener('change', function() { items.pageNumber.addEventListener('change', function() {
eventBus.dispatch('pagenumberchanged', { eventBus.dispatch('pagenumberchanged', {
source: self, source: self,
value: this.value value: this.value,
}); });
}); });
@ -138,7 +138,7 @@ var Toolbar = (function ToolbarClosure() {
} }
eventBus.dispatch('scalechanged', { eventBus.dispatch('scalechanged', {
source: self, source: self,
value: this.value value: this.value,
}); });
}); });
@ -193,7 +193,7 @@ var Toolbar = (function ToolbarClosure() {
} }
if (!predefinedValueFound) { if (!predefinedValueFound) {
var customScale = Math.round(scale * 10000) / 100; var customScale = Math.round(scale * 10000) / 100;
this.l10n.get('page_scale_percent', {scale: customScale}, this.l10n.get('page_scale_percent', { scale: customScale, },
'{{scale}}%'). '{{scale}}%').
then((msg) => { then((msg) => {
items.customScaleOption.textContent = msg; items.customScaleOption.textContent = msg;

12
web/ui_utils.js

@ -51,7 +51,7 @@ var NullL10n = {
translate(element) { translate(element) {
return Promise.resolve(); return Promise.resolve();
} },
}; };
/** /**
@ -125,7 +125,7 @@ function getOutputScale(ctx) {
return { return {
sx: pixelRatio, sx: pixelRatio,
sy: pixelRatio, sy: pixelRatio,
scaled: pixelRatio !== 1 scaled: pixelRatio !== 1,
}; };
} }
@ -200,7 +200,7 @@ function watchScroll(viewAreaElement, callback) {
var state = { var state = {
down: true, down: true,
lastY: viewAreaElement.scrollTop, lastY: viewAreaElement.scrollTop,
_eventHandler: debounceScroll _eventHandler: debounceScroll,
}; };
var rAF = null; var rAF = null;
@ -350,7 +350,7 @@ function getVisibleElements(scrollEl, views, sortByVisibility) {
x: currentWidth, x: currentWidth,
y: currentHeight, y: currentHeight,
view, view,
percent: percentHeight percent: percentHeight,
}); });
} }
@ -508,7 +508,7 @@ var EventBus = (function EventBusClosure() {
eventListeners.slice(0).forEach(function (listener) { eventListeners.slice(0).forEach(function (listener) {
listener.apply(null, args); listener.apply(null, args);
}); });
} },
}; };
return EventBus; return EventBus;
})(); })();
@ -589,7 +589,7 @@ var ProgressBar = (function ProgressBarClosure() {
this.visible = true; this.visible = true;
document.body.classList.add('loadingInProgress'); document.body.classList.add('loadingInProgress');
this.bar.classList.remove('hidden'); this.bar.classList.remove('hidden');
} },
}; };
return ProgressBar; return ProgressBar;

2
web/view_history.js

@ -46,7 +46,7 @@ class ViewHistory {
} }
} }
if (typeof index !== 'number') { if (typeof index !== 'number') {
index = database.files.push({fingerprint: this.fingerprint}) - 1; index = database.files.push({ fingerprint: this.fingerprint, }) - 1;
} }
this.file = database.files[index]; this.file = database.files[index];
this.database = database; this.database = database;

10
web/viewer.js

@ -127,7 +127,7 @@ function getViewerConfiguration() {
findResultsCount: document.getElementById('findResultsCount'), findResultsCount: document.getElementById('findResultsCount'),
findStatusIcon: document.getElementById('findStatusIcon'), findStatusIcon: document.getElementById('findStatusIcon'),
findPreviousButton: document.getElementById('findPrevious'), findPreviousButton: document.getElementById('findPrevious'),
findNextButton: document.getElementById('findNext') findNextButton: document.getElementById('findNext'),
}, },
passwordOverlay: { passwordOverlay: {
overlayName: 'passwordOverlay', overlayName: 'passwordOverlay',
@ -135,7 +135,7 @@ function getViewerConfiguration() {
label: document.getElementById('passwordText'), label: document.getElementById('passwordText'),
input: document.getElementById('password'), input: document.getElementById('password'),
submitButton: document.getElementById('passwordSubmit'), submitButton: document.getElementById('passwordSubmit'),
cancelButton: document.getElementById('passwordCancel') cancelButton: document.getElementById('passwordCancel'),
}, },
documentProperties: { documentProperties: {
overlayName: 'documentPropertiesOverlay', overlayName: 'documentPropertiesOverlay',
@ -153,8 +153,8 @@ function getViewerConfiguration() {
'creator': document.getElementById('creatorField'), 'creator': document.getElementById('creatorField'),
'producer': document.getElementById('producerField'), 'producer': document.getElementById('producerField'),
'version': document.getElementById('versionField'), 'version': document.getElementById('versionField'),
'pageCount': document.getElementById('pageCountField') 'pageCount': document.getElementById('pageCountField'),
} },
}, },
errorWrapper: { errorWrapper: {
container: document.getElementById('errorWrapper'), container: document.getElementById('errorWrapper'),
@ -167,7 +167,7 @@ function getViewerConfiguration() {
printContainer: document.getElementById('printContainer'), printContainer: document.getElementById('printContainer'),
openFileInputName: 'fileInput', openFileInputName: 'fileInput',
debuggerScriptPath: './debugger.js', debuggerScriptPath: './debugger.js',
defaultUrl: DEFAULT_URL defaultUrl: DEFAULT_URL,
}; };
} }

Loading…
Cancel
Save