|
|
@ -10906,6 +10906,8 @@ AnnotationElementFactory.prototype = { |
|
|
|
return new WidgetAnnotationElement(parameters); |
|
|
|
return new WidgetAnnotationElement(parameters); |
|
|
|
case AnnotationType.POPUP: |
|
|
|
case AnnotationType.POPUP: |
|
|
|
return new PopupAnnotationElement(parameters); |
|
|
|
return new PopupAnnotationElement(parameters); |
|
|
|
|
|
|
|
case AnnotationType.LINE: |
|
|
|
|
|
|
|
return new LineAnnotationElement(parameters); |
|
|
|
case AnnotationType.HIGHLIGHT: |
|
|
|
case AnnotationType.HIGHLIGHT: |
|
|
|
return new HighlightAnnotationElement(parameters); |
|
|
|
return new HighlightAnnotationElement(parameters); |
|
|
|
case AnnotationType.UNDERLINE: |
|
|
|
case AnnotationType.UNDERLINE: |
|
|
@ -10922,7 +10924,7 @@ AnnotationElementFactory.prototype = { |
|
|
|
} |
|
|
|
} |
|
|
|
}; |
|
|
|
}; |
|
|
|
var AnnotationElement = function AnnotationElementClosure() { |
|
|
|
var AnnotationElement = function AnnotationElementClosure() { |
|
|
|
function AnnotationElement(parameters, isRenderable) { |
|
|
|
function AnnotationElement(parameters, isRenderable, ignoreBorder) { |
|
|
|
this.isRenderable = isRenderable || false; |
|
|
|
this.isRenderable = isRenderable || false; |
|
|
|
this.data = parameters.data; |
|
|
|
this.data = parameters.data; |
|
|
|
this.layer = parameters.layer; |
|
|
|
this.layer = parameters.layer; |
|
|
@ -10933,11 +10935,11 @@ var AnnotationElement = function AnnotationElementClosure() { |
|
|
|
this.imageResourcesPath = parameters.imageResourcesPath; |
|
|
|
this.imageResourcesPath = parameters.imageResourcesPath; |
|
|
|
this.renderInteractiveForms = parameters.renderInteractiveForms; |
|
|
|
this.renderInteractiveForms = parameters.renderInteractiveForms; |
|
|
|
if (isRenderable) { |
|
|
|
if (isRenderable) { |
|
|
|
this.container = this._createContainer(); |
|
|
|
this.container = this._createContainer(ignoreBorder); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
AnnotationElement.prototype = { |
|
|
|
AnnotationElement.prototype = { |
|
|
|
_createContainer: function AnnotationElement_createContainer() { |
|
|
|
_createContainer: function AnnotationElement_createContainer(ignoreBorder) { |
|
|
|
var data = this.data, |
|
|
|
var data = this.data, |
|
|
|
page = this.page, |
|
|
|
page = this.page, |
|
|
|
viewport = this.viewport; |
|
|
|
viewport = this.viewport; |
|
|
@ -10948,7 +10950,7 @@ var AnnotationElement = function AnnotationElementClosure() { |
|
|
|
var rect = Util.normalizeRect([data.rect[0], page.view[3] - data.rect[1] + page.view[1], data.rect[2], page.view[3] - data.rect[3] + page.view[1]]); |
|
|
|
var rect = Util.normalizeRect([data.rect[0], page.view[3] - data.rect[1] + page.view[1], data.rect[2], page.view[3] - data.rect[3] + page.view[1]]); |
|
|
|
CustomStyle.setProp('transform', container, 'matrix(' + viewport.transform.join(',') + ')'); |
|
|
|
CustomStyle.setProp('transform', container, 'matrix(' + viewport.transform.join(',') + ')'); |
|
|
|
CustomStyle.setProp('transformOrigin', container, -rect[0] + 'px ' + -rect[1] + 'px'); |
|
|
|
CustomStyle.setProp('transformOrigin', container, -rect[0] + 'px ' + -rect[1] + 'px'); |
|
|
|
if (data.borderStyle.width > 0) { |
|
|
|
if (!ignoreBorder && data.borderStyle.width > 0) { |
|
|
|
container.style.borderWidth = data.borderStyle.width + 'px'; |
|
|
|
container.style.borderWidth = data.borderStyle.width + 'px'; |
|
|
|
if (data.borderStyle.style !== AnnotationBorderStyleType.UNDERLINE) { |
|
|
|
if (data.borderStyle.style !== AnnotationBorderStyleType.UNDERLINE) { |
|
|
|
width = width - 2 * data.borderStyle.width; |
|
|
|
width = width - 2 * data.borderStyle.width; |
|
|
@ -11231,6 +11233,7 @@ var ChoiceWidgetAnnotationElement = function ChoiceWidgetAnnotationElementClosur |
|
|
|
return ChoiceWidgetAnnotationElement; |
|
|
|
return ChoiceWidgetAnnotationElement; |
|
|
|
}(); |
|
|
|
}(); |
|
|
|
var PopupAnnotationElement = function PopupAnnotationElementClosure() { |
|
|
|
var PopupAnnotationElement = function PopupAnnotationElementClosure() { |
|
|
|
|
|
|
|
var IGNORE_TYPES = ['Line']; |
|
|
|
function PopupAnnotationElement(parameters) { |
|
|
|
function PopupAnnotationElement(parameters) { |
|
|
|
var isRenderable = !!(parameters.data.title || parameters.data.contents); |
|
|
|
var isRenderable = !!(parameters.data.title || parameters.data.contents); |
|
|
|
AnnotationElement.call(this, parameters, isRenderable); |
|
|
|
AnnotationElement.call(this, parameters, isRenderable); |
|
|
@ -11238,6 +11241,9 @@ var PopupAnnotationElement = function PopupAnnotationElementClosure() { |
|
|
|
Util.inherit(PopupAnnotationElement, AnnotationElement, { |
|
|
|
Util.inherit(PopupAnnotationElement, AnnotationElement, { |
|
|
|
render: function PopupAnnotationElement_render() { |
|
|
|
render: function PopupAnnotationElement_render() { |
|
|
|
this.container.className = 'popupAnnotation'; |
|
|
|
this.container.className = 'popupAnnotation'; |
|
|
|
|
|
|
|
if (IGNORE_TYPES.indexOf(this.data.parentType) >= 0) { |
|
|
|
|
|
|
|
return this.container; |
|
|
|
|
|
|
|
} |
|
|
|
var selector = '[data-annotation-id="' + this.data.parentId + '"]'; |
|
|
|
var selector = '[data-annotation-id="' + this.data.parentId + '"]'; |
|
|
|
var parentElement = this.layer.querySelector(selector); |
|
|
|
var parentElement = this.layer.querySelector(selector); |
|
|
|
if (!parentElement) { |
|
|
|
if (!parentElement) { |
|
|
@ -11338,10 +11344,43 @@ var PopupElement = function PopupElementClosure() { |
|
|
|
}; |
|
|
|
}; |
|
|
|
return PopupElement; |
|
|
|
return PopupElement; |
|
|
|
}(); |
|
|
|
}(); |
|
|
|
|
|
|
|
var LineAnnotationElement = function LineAnnotationElementClosure() { |
|
|
|
|
|
|
|
var SVG_NS = 'http://www.w3.org/2000/svg'; |
|
|
|
|
|
|
|
function LineAnnotationElement(parameters) { |
|
|
|
|
|
|
|
var isRenderable = !!(parameters.data.hasPopup || parameters.data.title || parameters.data.contents); |
|
|
|
|
|
|
|
AnnotationElement.call(this, parameters, isRenderable, true); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
Util.inherit(LineAnnotationElement, AnnotationElement, { |
|
|
|
|
|
|
|
render: function LineAnnotationElement_render() { |
|
|
|
|
|
|
|
this.container.className = 'lineAnnotation'; |
|
|
|
|
|
|
|
var data = this.data; |
|
|
|
|
|
|
|
var width = data.rect[2] - data.rect[0]; |
|
|
|
|
|
|
|
var height = data.rect[3] - data.rect[1]; |
|
|
|
|
|
|
|
var svg = document.createElementNS(SVG_NS, 'svg:svg'); |
|
|
|
|
|
|
|
svg.setAttributeNS(null, 'version', '1.1'); |
|
|
|
|
|
|
|
svg.setAttributeNS(null, 'width', width + 'px'); |
|
|
|
|
|
|
|
svg.setAttributeNS(null, 'height', height + 'px'); |
|
|
|
|
|
|
|
svg.setAttributeNS(null, 'preserveAspectRatio', 'none'); |
|
|
|
|
|
|
|
svg.setAttributeNS(null, 'viewBox', '0 0 ' + width + ' ' + height); |
|
|
|
|
|
|
|
var line = document.createElementNS(SVG_NS, 'svg:line'); |
|
|
|
|
|
|
|
line.setAttributeNS(null, 'x1', data.rect[2] - data.lineCoordinates[0]); |
|
|
|
|
|
|
|
line.setAttributeNS(null, 'y1', data.rect[3] - data.lineCoordinates[1]); |
|
|
|
|
|
|
|
line.setAttributeNS(null, 'x2', data.rect[2] - data.lineCoordinates[2]); |
|
|
|
|
|
|
|
line.setAttributeNS(null, 'y2', data.rect[3] - data.lineCoordinates[3]); |
|
|
|
|
|
|
|
line.setAttributeNS(null, 'stroke-width', data.borderStyle.width); |
|
|
|
|
|
|
|
line.setAttributeNS(null, 'stroke', 'transparent'); |
|
|
|
|
|
|
|
svg.appendChild(line); |
|
|
|
|
|
|
|
this.container.append(svg); |
|
|
|
|
|
|
|
this._createPopup(this.container, line, this.data); |
|
|
|
|
|
|
|
return this.container; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}); |
|
|
|
|
|
|
|
return LineAnnotationElement; |
|
|
|
|
|
|
|
}(); |
|
|
|
var HighlightAnnotationElement = function HighlightAnnotationElementClosure() { |
|
|
|
var HighlightAnnotationElement = function HighlightAnnotationElementClosure() { |
|
|
|
function HighlightAnnotationElement(parameters) { |
|
|
|
function HighlightAnnotationElement(parameters) { |
|
|
|
var isRenderable = !!(parameters.data.hasPopup || parameters.data.title || parameters.data.contents); |
|
|
|
var isRenderable = !!(parameters.data.hasPopup || parameters.data.title || parameters.data.contents); |
|
|
|
AnnotationElement.call(this, parameters, isRenderable); |
|
|
|
AnnotationElement.call(this, parameters, isRenderable, true); |
|
|
|
} |
|
|
|
} |
|
|
|
Util.inherit(HighlightAnnotationElement, AnnotationElement, { |
|
|
|
Util.inherit(HighlightAnnotationElement, AnnotationElement, { |
|
|
|
render: function HighlightAnnotationElement_render() { |
|
|
|
render: function HighlightAnnotationElement_render() { |
|
|
@ -11357,7 +11396,7 @@ var HighlightAnnotationElement = function HighlightAnnotationElementClosure() { |
|
|
|
var UnderlineAnnotationElement = function UnderlineAnnotationElementClosure() { |
|
|
|
var UnderlineAnnotationElement = function UnderlineAnnotationElementClosure() { |
|
|
|
function UnderlineAnnotationElement(parameters) { |
|
|
|
function UnderlineAnnotationElement(parameters) { |
|
|
|
var isRenderable = !!(parameters.data.hasPopup || parameters.data.title || parameters.data.contents); |
|
|
|
var isRenderable = !!(parameters.data.hasPopup || parameters.data.title || parameters.data.contents); |
|
|
|
AnnotationElement.call(this, parameters, isRenderable); |
|
|
|
AnnotationElement.call(this, parameters, isRenderable, true); |
|
|
|
} |
|
|
|
} |
|
|
|
Util.inherit(UnderlineAnnotationElement, AnnotationElement, { |
|
|
|
Util.inherit(UnderlineAnnotationElement, AnnotationElement, { |
|
|
|
render: function UnderlineAnnotationElement_render() { |
|
|
|
render: function UnderlineAnnotationElement_render() { |
|
|
@ -11373,7 +11412,7 @@ var UnderlineAnnotationElement = function UnderlineAnnotationElementClosure() { |
|
|
|
var SquigglyAnnotationElement = function SquigglyAnnotationElementClosure() { |
|
|
|
var SquigglyAnnotationElement = function SquigglyAnnotationElementClosure() { |
|
|
|
function SquigglyAnnotationElement(parameters) { |
|
|
|
function SquigglyAnnotationElement(parameters) { |
|
|
|
var isRenderable = !!(parameters.data.hasPopup || parameters.data.title || parameters.data.contents); |
|
|
|
var isRenderable = !!(parameters.data.hasPopup || parameters.data.title || parameters.data.contents); |
|
|
|
AnnotationElement.call(this, parameters, isRenderable); |
|
|
|
AnnotationElement.call(this, parameters, isRenderable, true); |
|
|
|
} |
|
|
|
} |
|
|
|
Util.inherit(SquigglyAnnotationElement, AnnotationElement, { |
|
|
|
Util.inherit(SquigglyAnnotationElement, AnnotationElement, { |
|
|
|
render: function SquigglyAnnotationElement_render() { |
|
|
|
render: function SquigglyAnnotationElement_render() { |
|
|
@ -11389,7 +11428,7 @@ var SquigglyAnnotationElement = function SquigglyAnnotationElementClosure() { |
|
|
|
var StrikeOutAnnotationElement = function StrikeOutAnnotationElementClosure() { |
|
|
|
var StrikeOutAnnotationElement = function StrikeOutAnnotationElementClosure() { |
|
|
|
function StrikeOutAnnotationElement(parameters) { |
|
|
|
function StrikeOutAnnotationElement(parameters) { |
|
|
|
var isRenderable = !!(parameters.data.hasPopup || parameters.data.title || parameters.data.contents); |
|
|
|
var isRenderable = !!(parameters.data.hasPopup || parameters.data.title || parameters.data.contents); |
|
|
|
AnnotationElement.call(this, parameters, isRenderable); |
|
|
|
AnnotationElement.call(this, parameters, isRenderable, true); |
|
|
|
} |
|
|
|
} |
|
|
|
Util.inherit(StrikeOutAnnotationElement, AnnotationElement, { |
|
|
|
Util.inherit(StrikeOutAnnotationElement, AnnotationElement, { |
|
|
|
render: function StrikeOutAnnotationElement_render() { |
|
|
|
render: function StrikeOutAnnotationElement_render() { |
|
|
@ -12737,8 +12776,8 @@ var _UnsupportedManager = function UnsupportedManagerClosure() { |
|
|
|
} |
|
|
|
} |
|
|
|
}; |
|
|
|
}; |
|
|
|
}(); |
|
|
|
}(); |
|
|
|
exports.version = '1.8.183'; |
|
|
|
exports.version = '1.8.186'; |
|
|
|
exports.build = '22744655'; |
|
|
|
exports.build = '32e01cda'; |
|
|
|
exports.getDocument = getDocument; |
|
|
|
exports.getDocument = getDocument; |
|
|
|
exports.PDFDataRangeTransport = PDFDataRangeTransport; |
|
|
|
exports.PDFDataRangeTransport = PDFDataRangeTransport; |
|
|
|
exports.PDFWorker = PDFWorker; |
|
|
|
exports.PDFWorker = PDFWorker; |
|
|
@ -27971,8 +28010,8 @@ if (!globalScope.PDFJS) { |
|
|
|
globalScope.PDFJS = {}; |
|
|
|
globalScope.PDFJS = {}; |
|
|
|
} |
|
|
|
} |
|
|
|
var PDFJS = globalScope.PDFJS; |
|
|
|
var PDFJS = globalScope.PDFJS; |
|
|
|
PDFJS.version = '1.8.183'; |
|
|
|
PDFJS.version = '1.8.186'; |
|
|
|
PDFJS.build = '22744655'; |
|
|
|
PDFJS.build = '32e01cda'; |
|
|
|
PDFJS.pdfBug = false; |
|
|
|
PDFJS.pdfBug = false; |
|
|
|
if (PDFJS.verbosity !== undefined) { |
|
|
|
if (PDFJS.verbosity !== undefined) { |
|
|
|
sharedUtil.setVerbosityLevel(PDFJS.verbosity); |
|
|
|
sharedUtil.setVerbosityLevel(PDFJS.verbosity); |
|
|
@ -28152,6 +28191,8 @@ AnnotationFactory.prototype = { |
|
|
|
return new WidgetAnnotation(parameters); |
|
|
|
return new WidgetAnnotation(parameters); |
|
|
|
case 'Popup': |
|
|
|
case 'Popup': |
|
|
|
return new PopupAnnotation(parameters); |
|
|
|
return new PopupAnnotation(parameters); |
|
|
|
|
|
|
|
case 'Line': |
|
|
|
|
|
|
|
return new LineAnnotation(parameters); |
|
|
|
case 'Highlight': |
|
|
|
case 'Highlight': |
|
|
|
return new HighlightAnnotation(parameters); |
|
|
|
return new HighlightAnnotation(parameters); |
|
|
|
case 'Underline': |
|
|
|
case 'Underline': |
|
|
@ -28646,6 +28687,8 @@ var PopupAnnotation = function PopupAnnotationClosure() { |
|
|
|
warn('Popup annotation has a missing or invalid parent annotation.'); |
|
|
|
warn('Popup annotation has a missing or invalid parent annotation.'); |
|
|
|
return; |
|
|
|
return; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
var parentSubtype = parentItem.get('Subtype'); |
|
|
|
|
|
|
|
this.data.parentType = isName(parentSubtype) ? parentSubtype.name : null; |
|
|
|
this.data.parentId = dict.getRaw('Parent').toString(); |
|
|
|
this.data.parentId = dict.getRaw('Parent').toString(); |
|
|
|
this.data.title = stringToPDFString(parentItem.get('T') || ''); |
|
|
|
this.data.title = stringToPDFString(parentItem.get('T') || ''); |
|
|
|
this.data.contents = stringToPDFString(parentItem.get('Contents') || ''); |
|
|
|
this.data.contents = stringToPDFString(parentItem.get('Contents') || ''); |
|
|
@ -28665,12 +28708,22 @@ var PopupAnnotation = function PopupAnnotationClosure() { |
|
|
|
Util.inherit(PopupAnnotation, Annotation, {}); |
|
|
|
Util.inherit(PopupAnnotation, Annotation, {}); |
|
|
|
return PopupAnnotation; |
|
|
|
return PopupAnnotation; |
|
|
|
}(); |
|
|
|
}(); |
|
|
|
|
|
|
|
var LineAnnotation = function LineAnnotationClosure() { |
|
|
|
|
|
|
|
function LineAnnotation(parameters) { |
|
|
|
|
|
|
|
Annotation.call(this, parameters); |
|
|
|
|
|
|
|
this.data.annotationType = AnnotationType.LINE; |
|
|
|
|
|
|
|
var dict = parameters.dict; |
|
|
|
|
|
|
|
this.data.lineCoordinates = Util.normalizeRect(dict.getArray('L')); |
|
|
|
|
|
|
|
this._preparePopup(dict); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
Util.inherit(LineAnnotation, Annotation, {}); |
|
|
|
|
|
|
|
return LineAnnotation; |
|
|
|
|
|
|
|
}(); |
|
|
|
var HighlightAnnotation = function HighlightAnnotationClosure() { |
|
|
|
var HighlightAnnotation = function HighlightAnnotationClosure() { |
|
|
|
function HighlightAnnotation(parameters) { |
|
|
|
function HighlightAnnotation(parameters) { |
|
|
|
Annotation.call(this, parameters); |
|
|
|
Annotation.call(this, parameters); |
|
|
|
this.data.annotationType = AnnotationType.HIGHLIGHT; |
|
|
|
this.data.annotationType = AnnotationType.HIGHLIGHT; |
|
|
|
this._preparePopup(parameters.dict); |
|
|
|
this._preparePopup(parameters.dict); |
|
|
|
this.data.borderStyle.setWidth(0); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
Util.inherit(HighlightAnnotation, Annotation, {}); |
|
|
|
Util.inherit(HighlightAnnotation, Annotation, {}); |
|
|
|
return HighlightAnnotation; |
|
|
|
return HighlightAnnotation; |
|
|
@ -28680,7 +28733,6 @@ var UnderlineAnnotation = function UnderlineAnnotationClosure() { |
|
|
|
Annotation.call(this, parameters); |
|
|
|
Annotation.call(this, parameters); |
|
|
|
this.data.annotationType = AnnotationType.UNDERLINE; |
|
|
|
this.data.annotationType = AnnotationType.UNDERLINE; |
|
|
|
this._preparePopup(parameters.dict); |
|
|
|
this._preparePopup(parameters.dict); |
|
|
|
this.data.borderStyle.setWidth(0); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
Util.inherit(UnderlineAnnotation, Annotation, {}); |
|
|
|
Util.inherit(UnderlineAnnotation, Annotation, {}); |
|
|
|
return UnderlineAnnotation; |
|
|
|
return UnderlineAnnotation; |
|
|
@ -28690,7 +28742,6 @@ var SquigglyAnnotation = function SquigglyAnnotationClosure() { |
|
|
|
Annotation.call(this, parameters); |
|
|
|
Annotation.call(this, parameters); |
|
|
|
this.data.annotationType = AnnotationType.SQUIGGLY; |
|
|
|
this.data.annotationType = AnnotationType.SQUIGGLY; |
|
|
|
this._preparePopup(parameters.dict); |
|
|
|
this._preparePopup(parameters.dict); |
|
|
|
this.data.borderStyle.setWidth(0); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
Util.inherit(SquigglyAnnotation, Annotation, {}); |
|
|
|
Util.inherit(SquigglyAnnotation, Annotation, {}); |
|
|
|
return SquigglyAnnotation; |
|
|
|
return SquigglyAnnotation; |
|
|
@ -28700,7 +28751,6 @@ var StrikeOutAnnotation = function StrikeOutAnnotationClosure() { |
|
|
|
Annotation.call(this, parameters); |
|
|
|
Annotation.call(this, parameters); |
|
|
|
this.data.annotationType = AnnotationType.STRIKEOUT; |
|
|
|
this.data.annotationType = AnnotationType.STRIKEOUT; |
|
|
|
this._preparePopup(parameters.dict); |
|
|
|
this._preparePopup(parameters.dict); |
|
|
|
this.data.borderStyle.setWidth(0); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
Util.inherit(StrikeOutAnnotation, Annotation, {}); |
|
|
|
Util.inherit(StrikeOutAnnotation, Annotation, {}); |
|
|
|
return StrikeOutAnnotation; |
|
|
|
return StrikeOutAnnotation; |
|
|
@ -43498,8 +43548,8 @@ exports.TilingPattern = TilingPattern; |
|
|
|
"use strict"; |
|
|
|
"use strict"; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var pdfjsVersion = '1.8.183'; |
|
|
|
var pdfjsVersion = '1.8.186'; |
|
|
|
var pdfjsBuild = '22744655'; |
|
|
|
var pdfjsBuild = '32e01cda'; |
|
|
|
var pdfjsSharedUtil = __w_pdfjs_require__(0); |
|
|
|
var pdfjsSharedUtil = __w_pdfjs_require__(0); |
|
|
|
var pdfjsDisplayGlobal = __w_pdfjs_require__(26); |
|
|
|
var pdfjsDisplayGlobal = __w_pdfjs_require__(26); |
|
|
|
var pdfjsDisplayAPI = __w_pdfjs_require__(10); |
|
|
|
var pdfjsDisplayAPI = __w_pdfjs_require__(10); |
|
|
|