@toolspack/ttd-pdfjs 0.0.8 → 0.0.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.eslintignore +2 -2
- package/README.md +14 -2
- package/lib/ttd-pdfjs.common.js +199 -267
- package/lib/ttd-pdfjs.umd.js +199 -267
- package/lib/ttd-pdfjs.umd.min.js +5 -27
- package/package.json +3 -3
- package/src/packages/pdfjs/PdfView216.vue +80 -65
package/lib/ttd-pdfjs.umd.js
CHANGED
|
@@ -118,6 +118,17 @@ test[TO_STRING_TAG] = 'z';
|
|
|
118
118
|
module.exports = String(test) === '[object z]';
|
|
119
119
|
|
|
120
120
|
|
|
121
|
+
/***/ }),
|
|
122
|
+
|
|
123
|
+
/***/ "01ac":
|
|
124
|
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
125
|
+
|
|
126
|
+
"use strict";
|
|
127
|
+
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_7_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_7_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_7_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_7_oneOf_1_3_node_modules_cache_loader_dist_cjs_js_ref_1_0_node_modules_vue_loader_lib_index_js_vue_loader_options_SwitchPage_vue_vue_type_style_index_0_id_0190e316_prod_lang_css_scoped_true__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("3a86");
|
|
128
|
+
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_7_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_7_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_7_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_7_oneOf_1_3_node_modules_cache_loader_dist_cjs_js_ref_1_0_node_modules_vue_loader_lib_index_js_vue_loader_options_SwitchPage_vue_vue_type_style_index_0_id_0190e316_prod_lang_css_scoped_true__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_vue_style_loader_index_js_ref_7_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_7_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_7_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_7_oneOf_1_3_node_modules_cache_loader_dist_cjs_js_ref_1_0_node_modules_vue_loader_lib_index_js_vue_loader_options_SwitchPage_vue_vue_type_style_index_0_id_0190e316_prod_lang_css_scoped_true__WEBPACK_IMPORTED_MODULE_0__);
|
|
129
|
+
/* unused harmony reexport * */
|
|
130
|
+
|
|
131
|
+
|
|
121
132
|
/***/ }),
|
|
122
133
|
|
|
123
134
|
/***/ "0366":
|
|
@@ -248,17 +259,6 @@ module.exports = {
|
|
|
248
259
|
};
|
|
249
260
|
|
|
250
261
|
|
|
251
|
-
/***/ }),
|
|
252
|
-
|
|
253
|
-
/***/ "0a5a":
|
|
254
|
-
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
255
|
-
|
|
256
|
-
"use strict";
|
|
257
|
-
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_10_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_10_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_10_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_10_oneOf_1_3_node_modules_less_loader_dist_cjs_js_ref_10_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_PdfView216_vue_vue_type_style_index_0_id_3ce34874_lang_less_scoped_true___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("ceb2");
|
|
258
|
-
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_10_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_10_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_10_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_10_oneOf_1_3_node_modules_less_loader_dist_cjs_js_ref_10_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_PdfView216_vue_vue_type_style_index_0_id_3ce34874_lang_less_scoped_true___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_vue_style_loader_index_js_ref_10_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_10_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_10_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_10_oneOf_1_3_node_modules_less_loader_dist_cjs_js_ref_10_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_PdfView216_vue_vue_type_style_index_0_id_3ce34874_lang_less_scoped_true___WEBPACK_IMPORTED_MODULE_0__);
|
|
259
|
-
/* unused harmony reexport * */
|
|
260
|
-
|
|
261
|
-
|
|
262
262
|
/***/ }),
|
|
263
263
|
|
|
264
264
|
/***/ "0cb2":
|
|
@@ -384,11 +384,12 @@ module.exports = function (argument) {
|
|
|
384
384
|
|
|
385
385
|
// load the styles
|
|
386
386
|
var content = __webpack_require__("51d3");
|
|
387
|
+
if(content.__esModule) content = content.default;
|
|
387
388
|
if(typeof content === 'string') content = [[module.i, content, '']];
|
|
388
389
|
if(content.locals) module.exports = content.locals;
|
|
389
390
|
// add the styles to the DOM
|
|
390
391
|
var add = __webpack_require__("499e").default
|
|
391
|
-
var update = add("
|
|
392
|
+
var update = add("5222ba7b", content, true, {"sourceMap":false,"shadowMode":false});
|
|
392
393
|
|
|
393
394
|
/***/ }),
|
|
394
395
|
|
|
@@ -1220,6 +1221,20 @@ function toComment(sourceMap) {
|
|
|
1220
1221
|
return "/*# ".concat(data, " */");
|
|
1221
1222
|
}
|
|
1222
1223
|
|
|
1224
|
+
/***/ }),
|
|
1225
|
+
|
|
1226
|
+
/***/ "263a":
|
|
1227
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
1228
|
+
|
|
1229
|
+
// Imports
|
|
1230
|
+
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__("24fb");
|
|
1231
|
+
exports = ___CSS_LOADER_API_IMPORT___(false);
|
|
1232
|
+
// Module
|
|
1233
|
+
exports.push([module.i, ".pdf-view[data-v-071495fa]{height:100%;width:100%;display:flex;flex-direction:column}.pdf-view-control[data-v-071495fa]{text-align:center;margin:10px 0}.pdf-view-area-wapper[data-v-071495fa]{flex:1 1 0%;overflow:auto;width:100%;flex-shrink:0%}.pdf-view-area[data-v-071495fa]{position:relative;min-height:700px}.pdf-view-area .canvasstyle[data-v-071495fa]{display:block;margin:0 auto}.pdf-view-area .label-area[data-v-071495fa]{position:absolute;right:0;bottom:0;top:0;left:0}.pdf-view-empty[data-v-071495fa]{text-align:center;line-height:150px;font-size:14px;color:#999}.pdf-view-loading[data-v-071495fa],.pdf-view-rendering[data-v-071495fa]{margin-top:40px;text-align:center;font-size:14px;color:#999}", ""]);
|
|
1234
|
+
// Exports
|
|
1235
|
+
module.exports = exports;
|
|
1236
|
+
|
|
1237
|
+
|
|
1223
1238
|
/***/ }),
|
|
1224
1239
|
|
|
1225
1240
|
/***/ "271a":
|
|
@@ -1695,6 +1710,22 @@ module.exports = SILENT_ON_NON_WRITABLE_LENGTH_SET ? function (O, length) {
|
|
|
1695
1710
|
};
|
|
1696
1711
|
|
|
1697
1712
|
|
|
1713
|
+
/***/ }),
|
|
1714
|
+
|
|
1715
|
+
/***/ "3a86":
|
|
1716
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
1717
|
+
|
|
1718
|
+
// style-loader: Adds some css to the DOM by adding a <style> tag
|
|
1719
|
+
|
|
1720
|
+
// load the styles
|
|
1721
|
+
var content = __webpack_require__("bb79");
|
|
1722
|
+
if(content.__esModule) content = content.default;
|
|
1723
|
+
if(typeof content === 'string') content = [[module.i, content, '']];
|
|
1724
|
+
if(content.locals) module.exports = content.locals;
|
|
1725
|
+
// add the styles to the DOM
|
|
1726
|
+
var add = __webpack_require__("499e").default
|
|
1727
|
+
var update = add("159154f8", content, true, {"sourceMap":false,"shadowMode":false});
|
|
1728
|
+
|
|
1698
1729
|
/***/ }),
|
|
1699
1730
|
|
|
1700
1731
|
/***/ "3a9b":
|
|
@@ -1886,17 +1917,6 @@ exports.uvCounters = function() {};
|
|
|
1886
1917
|
exports.features = {};
|
|
1887
1918
|
|
|
1888
1919
|
|
|
1889
|
-
/***/ }),
|
|
1890
|
-
|
|
1891
|
-
/***/ "43c2":
|
|
1892
|
-
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
1893
|
-
|
|
1894
|
-
"use strict";
|
|
1895
|
-
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_6_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_6_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_6_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_6_oneOf_1_3_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_SwitchPage_vue_vue_type_style_index_0_id_0190e316_lang_css_scoped_true___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("c299");
|
|
1896
|
-
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_6_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_6_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_6_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_6_oneOf_1_3_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_SwitchPage_vue_vue_type_style_index_0_id_0190e316_lang_css_scoped_true___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_vue_style_loader_index_js_ref_6_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_6_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_6_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_6_oneOf_1_3_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_SwitchPage_vue_vue_type_style_index_0_id_0190e316_lang_css_scoped_true___WEBPACK_IMPORTED_MODULE_0__);
|
|
1897
|
-
/* unused harmony reexport * */
|
|
1898
|
-
|
|
1899
|
-
|
|
1900
1920
|
/***/ }),
|
|
1901
1921
|
|
|
1902
1922
|
/***/ "448a":
|
|
@@ -1994,11 +2014,12 @@ module.exports = function (it) {
|
|
|
1994
2014
|
|
|
1995
2015
|
// load the styles
|
|
1996
2016
|
var content = __webpack_require__("7f6e");
|
|
2017
|
+
if(content.__esModule) content = content.default;
|
|
1997
2018
|
if(typeof content === 'string') content = [[module.i, content, '']];
|
|
1998
2019
|
if(content.locals) module.exports = content.locals;
|
|
1999
2020
|
// add the styles to the DOM
|
|
2000
2021
|
var add = __webpack_require__("499e").default
|
|
2001
|
-
var update = add("
|
|
2022
|
+
var update = add("ede70dbe", content, true, {"sourceMap":false,"shadowMode":false});
|
|
2002
2023
|
|
|
2003
2024
|
/***/ }),
|
|
2004
2025
|
|
|
@@ -4885,91 +4906,6 @@ function _classExtractFieldDescriptor(receiver, privateMap, action) {
|
|
|
4885
4906
|
}
|
|
4886
4907
|
module.exports = _classExtractFieldDescriptor, module.exports.__esModule = true, module.exports["default"] = module.exports;
|
|
4887
4908
|
|
|
4888
|
-
/***/ }),
|
|
4889
|
-
|
|
4890
|
-
/***/ "8875":
|
|
4891
|
-
/***/ (function(module, exports, __webpack_require__) {
|
|
4892
|
-
|
|
4893
|
-
var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;// addapted from the document.currentScript polyfill by Adam Miller
|
|
4894
|
-
// MIT license
|
|
4895
|
-
// source: https://github.com/amiller-gh/currentScript-polyfill
|
|
4896
|
-
|
|
4897
|
-
// added support for Firefox https://bugzilla.mozilla.org/show_bug.cgi?id=1620505
|
|
4898
|
-
|
|
4899
|
-
(function (root, factory) {
|
|
4900
|
-
if (true) {
|
|
4901
|
-
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory),
|
|
4902
|
-
__WEBPACK_AMD_DEFINE_RESULT__ = (typeof __WEBPACK_AMD_DEFINE_FACTORY__ === 'function' ?
|
|
4903
|
-
(__WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__)) : __WEBPACK_AMD_DEFINE_FACTORY__),
|
|
4904
|
-
__WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
|
4905
|
-
} else {}
|
|
4906
|
-
}(typeof self !== 'undefined' ? self : this, function () {
|
|
4907
|
-
function getCurrentScript () {
|
|
4908
|
-
var descriptor = Object.getOwnPropertyDescriptor(document, 'currentScript')
|
|
4909
|
-
// for chrome
|
|
4910
|
-
if (!descriptor && 'currentScript' in document && document.currentScript) {
|
|
4911
|
-
return document.currentScript
|
|
4912
|
-
}
|
|
4913
|
-
|
|
4914
|
-
// for other browsers with native support for currentScript
|
|
4915
|
-
if (descriptor && descriptor.get !== getCurrentScript && document.currentScript) {
|
|
4916
|
-
return document.currentScript
|
|
4917
|
-
}
|
|
4918
|
-
|
|
4919
|
-
// IE 8-10 support script readyState
|
|
4920
|
-
// IE 11+ & Firefox support stack trace
|
|
4921
|
-
try {
|
|
4922
|
-
throw new Error();
|
|
4923
|
-
}
|
|
4924
|
-
catch (err) {
|
|
4925
|
-
// Find the second match for the "at" string to get file src url from stack.
|
|
4926
|
-
var ieStackRegExp = /.*at [^(]*\((.*):(.+):(.+)\)$/ig,
|
|
4927
|
-
ffStackRegExp = /@([^@]*):(\d+):(\d+)\s*$/ig,
|
|
4928
|
-
stackDetails = ieStackRegExp.exec(err.stack) || ffStackRegExp.exec(err.stack),
|
|
4929
|
-
scriptLocation = (stackDetails && stackDetails[1]) || false,
|
|
4930
|
-
line = (stackDetails && stackDetails[2]) || false,
|
|
4931
|
-
currentLocation = document.location.href.replace(document.location.hash, ''),
|
|
4932
|
-
pageSource,
|
|
4933
|
-
inlineScriptSourceRegExp,
|
|
4934
|
-
inlineScriptSource,
|
|
4935
|
-
scripts = document.getElementsByTagName('script'); // Live NodeList collection
|
|
4936
|
-
|
|
4937
|
-
if (scriptLocation === currentLocation) {
|
|
4938
|
-
pageSource = document.documentElement.outerHTML;
|
|
4939
|
-
inlineScriptSourceRegExp = new RegExp('(?:[^\\n]+?\\n){0,' + (line - 2) + '}[^<]*<script>([\\d\\D]*?)<\\/script>[\\d\\D]*', 'i');
|
|
4940
|
-
inlineScriptSource = pageSource.replace(inlineScriptSourceRegExp, '$1').trim();
|
|
4941
|
-
}
|
|
4942
|
-
|
|
4943
|
-
for (var i = 0; i < scripts.length; i++) {
|
|
4944
|
-
// If ready state is interactive, return the script tag
|
|
4945
|
-
if (scripts[i].readyState === 'interactive') {
|
|
4946
|
-
return scripts[i];
|
|
4947
|
-
}
|
|
4948
|
-
|
|
4949
|
-
// If src matches, return the script tag
|
|
4950
|
-
if (scripts[i].src === scriptLocation) {
|
|
4951
|
-
return scripts[i];
|
|
4952
|
-
}
|
|
4953
|
-
|
|
4954
|
-
// If inline source matches, return the script tag
|
|
4955
|
-
if (
|
|
4956
|
-
scriptLocation === currentLocation &&
|
|
4957
|
-
scripts[i].innerHTML &&
|
|
4958
|
-
scripts[i].innerHTML.trim() === inlineScriptSource
|
|
4959
|
-
) {
|
|
4960
|
-
return scripts[i];
|
|
4961
|
-
}
|
|
4962
|
-
}
|
|
4963
|
-
|
|
4964
|
-
// If no match, return null
|
|
4965
|
-
return null;
|
|
4966
|
-
}
|
|
4967
|
-
};
|
|
4968
|
-
|
|
4969
|
-
return getCurrentScript
|
|
4970
|
-
}));
|
|
4971
|
-
|
|
4972
|
-
|
|
4973
4909
|
/***/ }),
|
|
4974
4910
|
|
|
4975
4911
|
/***/ "88a7":
|
|
@@ -5506,6 +5442,33 @@ exports.f = DESCRIPTORS ? V8_PROTOTYPE_DEFINE_BUG ? function defineProperty(O, P
|
|
|
5506
5442
|
};
|
|
5507
5443
|
|
|
5508
5444
|
|
|
5445
|
+
/***/ }),
|
|
5446
|
+
|
|
5447
|
+
/***/ "9c3f":
|
|
5448
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
5449
|
+
|
|
5450
|
+
// style-loader: Adds some css to the DOM by adding a <style> tag
|
|
5451
|
+
|
|
5452
|
+
// load the styles
|
|
5453
|
+
var content = __webpack_require__("263a");
|
|
5454
|
+
if(content.__esModule) content = content.default;
|
|
5455
|
+
if(typeof content === 'string') content = [[module.i, content, '']];
|
|
5456
|
+
if(content.locals) module.exports = content.locals;
|
|
5457
|
+
// add the styles to the DOM
|
|
5458
|
+
var add = __webpack_require__("499e").default
|
|
5459
|
+
var update = add("77e7d9da", content, true, {"sourceMap":false,"shadowMode":false});
|
|
5460
|
+
|
|
5461
|
+
/***/ }),
|
|
5462
|
+
|
|
5463
|
+
/***/ "9f3b":
|
|
5464
|
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
5465
|
+
|
|
5466
|
+
"use strict";
|
|
5467
|
+
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_11_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_11_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_11_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_11_oneOf_1_3_node_modules_less_loader_dist_cjs_js_ref_11_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_1_0_node_modules_vue_loader_lib_index_js_vue_loader_options_PdfView216_vue_vue_type_style_index_0_id_071495fa_prod_lang_less_scoped_true__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("9c3f");
|
|
5468
|
+
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_11_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_11_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_11_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_11_oneOf_1_3_node_modules_less_loader_dist_cjs_js_ref_11_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_1_0_node_modules_vue_loader_lib_index_js_vue_loader_options_PdfView216_vue_vue_type_style_index_0_id_071495fa_prod_lang_less_scoped_true__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_vue_style_loader_index_js_ref_11_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_11_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_11_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_11_oneOf_1_3_node_modules_less_loader_dist_cjs_js_ref_11_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_1_0_node_modules_vue_loader_lib_index_js_vue_loader_options_PdfView216_vue_vue_type_style_index_0_id_071495fa_prod_lang_less_scoped_true__WEBPACK_IMPORTED_MODULE_0__);
|
|
5469
|
+
/* unused harmony reexport * */
|
|
5470
|
+
|
|
5471
|
+
|
|
5509
5472
|
/***/ }),
|
|
5510
5473
|
|
|
5511
5474
|
/***/ "9f70":
|
|
@@ -8260,6 +8223,20 @@ module.exports = !fails(function () {
|
|
|
8260
8223
|
});
|
|
8261
8224
|
|
|
8262
8225
|
|
|
8226
|
+
/***/ }),
|
|
8227
|
+
|
|
8228
|
+
/***/ "bb79":
|
|
8229
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
8230
|
+
|
|
8231
|
+
// Imports
|
|
8232
|
+
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__("24fb");
|
|
8233
|
+
exports = ___CSS_LOADER_API_IMPORT___(false);
|
|
8234
|
+
// Module
|
|
8235
|
+
exports.push([module.i, ".switch-page[data-v-0190e316]{margin:0;padding:0;overflow:auto}.switch-page button[data-v-0190e316]{font-size:16px;padding:6px!important}", ""]);
|
|
8236
|
+
// Exports
|
|
8237
|
+
module.exports = exports;
|
|
8238
|
+
|
|
8239
|
+
|
|
8263
8240
|
/***/ }),
|
|
8264
8241
|
|
|
8265
8242
|
/***/ "bcbf":
|
|
@@ -8345,21 +8322,6 @@ module.exports = _nonIterableRest, module.exports.__esModule = true, module.expo
|
|
|
8345
8322
|
|
|
8346
8323
|
/***/ }),
|
|
8347
8324
|
|
|
8348
|
-
/***/ "c299":
|
|
8349
|
-
/***/ (function(module, exports, __webpack_require__) {
|
|
8350
|
-
|
|
8351
|
-
// style-loader: Adds some css to the DOM by adding a <style> tag
|
|
8352
|
-
|
|
8353
|
-
// load the styles
|
|
8354
|
-
var content = __webpack_require__("dd05");
|
|
8355
|
-
if(typeof content === 'string') content = [[module.i, content, '']];
|
|
8356
|
-
if(content.locals) module.exports = content.locals;
|
|
8357
|
-
// add the styles to the DOM
|
|
8358
|
-
var add = __webpack_require__("499e").default
|
|
8359
|
-
var update = add("614e6f6b", content, true, {"sourceMap":false,"shadowMode":false});
|
|
8360
|
-
|
|
8361
|
-
/***/ }),
|
|
8362
|
-
|
|
8363
8325
|
/***/ "c430":
|
|
8364
8326
|
/***/ (function(module, exports, __webpack_require__) {
|
|
8365
8327
|
|
|
@@ -8384,20 +8346,6 @@ module.exports = NATIVE_BIND ? call.bind(call) : function () {
|
|
|
8384
8346
|
};
|
|
8385
8347
|
|
|
8386
8348
|
|
|
8387
|
-
/***/ }),
|
|
8388
|
-
|
|
8389
|
-
/***/ "c69f":
|
|
8390
|
-
/***/ (function(module, exports, __webpack_require__) {
|
|
8391
|
-
|
|
8392
|
-
// Imports
|
|
8393
|
-
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__("24fb");
|
|
8394
|
-
exports = ___CSS_LOADER_API_IMPORT___(false);
|
|
8395
|
-
// Module
|
|
8396
|
-
exports.push([module.i, ".pdf-view[data-v-3ce34874]{height:100%;width:100%;display:flex;flex-direction:column}.pdf-view-control[data-v-3ce34874]{text-align:center;margin:10px 0}.pdf-view-area-wapper[data-v-3ce34874]{flex:1 1 0%;overflow:auto;width:100%;flex-shrink:0%}.pdf-view-area[data-v-3ce34874]{position:relative;min-height:700px}.pdf-view-area .canvasstyle[data-v-3ce34874]{display:block;margin:0 auto}.pdf-view-area .label-area[data-v-3ce34874]{position:absolute;right:0;bottom:0;top:0;left:0}.pdf-view-empty[data-v-3ce34874]{text-align:center;line-height:150px;font-size:14px;color:#999}.pdf-view-loading[data-v-3ce34874],.pdf-view-rendering[data-v-3ce34874]{margin-top:40px;text-align:center;font-size:14px;color:#999}", ""]);
|
|
8397
|
-
// Exports
|
|
8398
|
-
module.exports = exports;
|
|
8399
|
-
|
|
8400
|
-
|
|
8401
8349
|
/***/ }),
|
|
8402
8350
|
|
|
8403
8351
|
/***/ "c6b6":
|
|
@@ -8665,21 +8613,6 @@ var WeakMap = global.WeakMap;
|
|
|
8665
8613
|
module.exports = isCallable(WeakMap) && /native code/.test(String(WeakMap));
|
|
8666
8614
|
|
|
8667
8615
|
|
|
8668
|
-
/***/ }),
|
|
8669
|
-
|
|
8670
|
-
/***/ "ceb2":
|
|
8671
|
-
/***/ (function(module, exports, __webpack_require__) {
|
|
8672
|
-
|
|
8673
|
-
// style-loader: Adds some css to the DOM by adding a <style> tag
|
|
8674
|
-
|
|
8675
|
-
// load the styles
|
|
8676
|
-
var content = __webpack_require__("c69f");
|
|
8677
|
-
if(typeof content === 'string') content = [[module.i, content, '']];
|
|
8678
|
-
if(content.locals) module.exports = content.locals;
|
|
8679
|
-
// add the styles to the DOM
|
|
8680
|
-
var add = __webpack_require__("499e").default
|
|
8681
|
-
var update = add("e4356e10", content, true, {"sourceMap":false,"shadowMode":false});
|
|
8682
|
-
|
|
8683
8616
|
/***/ }),
|
|
8684
8617
|
|
|
8685
8618
|
/***/ "cf98":
|
|
@@ -9100,20 +9033,6 @@ module.exports = function (V, P) {
|
|
|
9100
9033
|
};
|
|
9101
9034
|
|
|
9102
9035
|
|
|
9103
|
-
/***/ }),
|
|
9104
|
-
|
|
9105
|
-
/***/ "dd05":
|
|
9106
|
-
/***/ (function(module, exports, __webpack_require__) {
|
|
9107
|
-
|
|
9108
|
-
// Imports
|
|
9109
|
-
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__("24fb");
|
|
9110
|
-
exports = ___CSS_LOADER_API_IMPORT___(false);
|
|
9111
|
-
// Module
|
|
9112
|
-
exports.push([module.i, ".switch-page[data-v-0190e316]{margin:0;padding:0;overflow:auto}.switch-page button[data-v-0190e316]{font-size:16px;padding:6px!important}", ""]);
|
|
9113
|
-
// Exports
|
|
9114
|
-
module.exports = exports;
|
|
9115
|
-
|
|
9116
|
-
|
|
9117
9036
|
/***/ }),
|
|
9118
9037
|
|
|
9119
9038
|
/***/ "de5e":
|
|
@@ -10788,15 +10707,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
10788
10707
|
|
|
10789
10708
|
if (typeof window !== 'undefined') {
|
|
10790
10709
|
var currentScript = window.document.currentScript
|
|
10791
|
-
if (
|
|
10792
|
-
var getCurrentScript = __webpack_require__("8875")
|
|
10793
|
-
currentScript = getCurrentScript()
|
|
10794
|
-
|
|
10795
|
-
// for backward compatibility, because previously we directly included the polyfill
|
|
10796
|
-
if (!('currentScript' in document)) {
|
|
10797
|
-
Object.defineProperty(document, 'currentScript', { get: getCurrentScript })
|
|
10798
|
-
}
|
|
10799
|
-
}
|
|
10710
|
+
if (false) { var getCurrentScript; }
|
|
10800
10711
|
|
|
10801
10712
|
var src = currentScript && currentScript.src.match(/(.+\/)[^/]+\.js(\?.*)?$/)
|
|
10802
10713
|
if (src) {
|
|
@@ -10807,12 +10718,12 @@ if (typeof window !== 'undefined') {
|
|
|
10807
10718
|
// Indicate to webpack that this file can be concatenated
|
|
10808
10719
|
/* harmony default export */ var setPublicPath = (null);
|
|
10809
10720
|
|
|
10810
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"
|
|
10811
|
-
var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"pdf-view"},[(_vm.showPages)?_c('div',{staticClass:"pdf-view-control"},[_c('switch-page',{ref:"switchPage",attrs:{"numPages":_vm.page_count},on:{"page":_vm.onChangePage}})],1):_vm._e(),_c('div',{staticClass:"pdf-view-area-wapper"},[_c('div',{style:(_vm.style)},[(_vm.pdfurl)?_c('div',{staticClass:"center pdf-view-area",style:({'border': _vm.border?'1px solid #666': ''}),on:{"drop":_vm.onDrop,"dragover":_vm.onDragOver}},[(_vm.fileLoading)?_c('div',{staticClass:"pdf-view-loading"},[_vm._v("文件加载中...")]):_vm._e(),_c('canvas',{ref:"canvas",staticClass:"canvasstyle"}),_c('div',{staticClass:"label-area"},[_vm._t("default")],2)]):_c('div',{staticClass:"pdf-view-empty"},[_vm._v("未找到资源,请联系管理员!")])])])])}
|
|
10721
|
+
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"803a9372-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--1-0!./node_modules/vue-loader/lib??vue-loader-options!./src/packages/pdfjs/PdfView216.vue?vue&type=template&id=071495fa&scoped=true
|
|
10722
|
+
var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"pdf-view"},[(_vm.showPages)?_c('div',{staticClass:"pdf-view-control"},[_c('switch-page',{ref:"switchPage",attrs:{"numPages":_vm.page_count},on:{"page":_vm.onChangePage}})],1):_vm._e(),_c('div',{staticClass:"pdf-view-area-wapper"},[_c('div',{style:(_vm.style)},[(_vm.pdfurl)?_c('div',{key:_vm.pdfurl,staticClass:"center pdf-view-area",style:({'border': _vm.border?'1px solid #666': ''}),on:{"drop":_vm.onDrop,"dragover":_vm.onDragOver}},[(_vm.fileLoading)?_c('div',{staticClass:"pdf-view-loading"},[_vm._v("文件加载中...")]):(_vm.pageRendering)?_c('div',{staticClass:"pdf-view-rendering"},[_vm._v("内容渲染中...")]):_vm._e(),_c('canvas',{key:_vm.pdfurl +'canvas',ref:"canvas",staticClass:"canvasstyle"}),_c('div',{staticClass:"label-area"},[_vm._t("default")],2)]):_c('div',{staticClass:"pdf-view-empty"},[_vm._v("未找到资源,请联系管理员!")])])])])}
|
|
10812
10723
|
var staticRenderFns = []
|
|
10813
10724
|
|
|
10814
10725
|
|
|
10815
|
-
// CONCATENATED MODULE: ./src/packages/pdfjs/PdfView216.vue?vue&type=template&id=
|
|
10726
|
+
// CONCATENATED MODULE: ./src/packages/pdfjs/PdfView216.vue?vue&type=template&id=071495fa&scoped=true
|
|
10816
10727
|
|
|
10817
10728
|
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.error.cause.js
|
|
10818
10729
|
var es_error_cause = __webpack_require__("d9e2");
|
|
@@ -11188,14 +11099,14 @@ var web_url_search_params_has = __webpack_require__("271a");
|
|
|
11188
11099
|
// EXTERNAL MODULE: ./node_modules/core-js/modules/web.url-search-params.size.js
|
|
11189
11100
|
var web_url_search_params_size = __webpack_require__("5494");
|
|
11190
11101
|
|
|
11191
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"
|
|
11102
|
+
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"803a9372-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--1-0!./node_modules/vue-loader/lib??vue-loader-options!./src/packages/pdfjs/SwitchPage.vue?vue&type=template&id=0190e316&scoped=true&lang=html
|
|
11192
11103
|
var SwitchPagevue_type_template_id_0190e316_scoped_true_lang_html_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"switch-page"},[_c('el-button',{attrs:{"size":"mini"},on:{"click":function($event){return _vm.switchPage('prev')}}},[_c('i',{staticClass:"el-icon-caret-left"})]),_c('el-button',{attrs:{"size":"mini"},on:{"click":function($event){return _vm.switchPage('next')}}},[_c('i',{staticClass:"el-icon-caret-right"})]),_c('span',{staticStyle:{"margin-left":"10px"}},[_vm._v(_vm._s(_vm.page)+"/"+_vm._s(_vm.numPages))]),_c('span',{staticStyle:{"margin-left":"6px"}},[_vm._v(" 跳转至 "),_c('el-input',{staticStyle:{"width":"50px","margin":"0 4px"},attrs:{"size":"mini"},nativeOn:{"keyup":function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"enter",13,$event.key,"Enter")){ return null; }return _vm.goPage($event)}},model:{value:(_vm.itemPage),callback:function ($$v) {_vm.itemPage=_vm._n($$v)},expression:"itemPage"}}),_vm._v(" 页 ")],1)],1)}
|
|
11193
11104
|
var SwitchPagevue_type_template_id_0190e316_scoped_true_lang_html_staticRenderFns = []
|
|
11194
11105
|
|
|
11195
11106
|
|
|
11196
|
-
// CONCATENATED MODULE: ./src/packages/pdfjs/SwitchPage.vue?vue&type=template&id=0190e316&scoped=true&lang=html
|
|
11107
|
+
// CONCATENATED MODULE: ./src/packages/pdfjs/SwitchPage.vue?vue&type=template&id=0190e316&scoped=true&lang=html
|
|
11197
11108
|
|
|
11198
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--
|
|
11109
|
+
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--13-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--1-0!./node_modules/vue-loader/lib??vue-loader-options!./src/packages/pdfjs/SwitchPage.vue?vue&type=script&lang=js
|
|
11199
11110
|
//
|
|
11200
11111
|
//
|
|
11201
11112
|
//
|
|
@@ -11210,7 +11121,7 @@ var SwitchPagevue_type_template_id_0190e316_scoped_true_lang_html_staticRenderFn
|
|
|
11210
11121
|
//
|
|
11211
11122
|
//
|
|
11212
11123
|
|
|
11213
|
-
/* harmony default export */ var
|
|
11124
|
+
/* harmony default export */ var SwitchPagevue_type_script_lang_js = ({
|
|
11214
11125
|
name: 'switch-page',
|
|
11215
11126
|
props: {
|
|
11216
11127
|
numPages: {
|
|
@@ -11266,10 +11177,10 @@ var SwitchPagevue_type_template_id_0190e316_scoped_true_lang_html_staticRenderFn
|
|
|
11266
11177
|
}
|
|
11267
11178
|
}
|
|
11268
11179
|
});
|
|
11269
|
-
// CONCATENATED MODULE: ./src/packages/pdfjs/SwitchPage.vue?vue&type=script&lang=js
|
|
11270
|
-
/* harmony default export */ var
|
|
11271
|
-
// EXTERNAL MODULE: ./src/packages/pdfjs/SwitchPage.vue?vue&type=style&index=0&id=0190e316&lang=css&scoped=true
|
|
11272
|
-
var
|
|
11180
|
+
// CONCATENATED MODULE: ./src/packages/pdfjs/SwitchPage.vue?vue&type=script&lang=js
|
|
11181
|
+
/* harmony default export */ var pdfjs_SwitchPagevue_type_script_lang_js = (SwitchPagevue_type_script_lang_js);
|
|
11182
|
+
// EXTERNAL MODULE: ./src/packages/pdfjs/SwitchPage.vue?vue&type=style&index=0&id=0190e316&prod&lang=css&scoped=true
|
|
11183
|
+
var SwitchPagevue_type_style_index_0_id_0190e316_prod_lang_css_scoped_true = __webpack_require__("01ac");
|
|
11273
11184
|
|
|
11274
11185
|
// CONCATENATED MODULE: ./node_modules/vue-loader/lib/runtime/componentNormalizer.js
|
|
11275
11186
|
/* globals __VUE_SSR_CONTEXT__ */
|
|
@@ -11278,20 +11189,19 @@ var SwitchPagevue_type_style_index_0_id_0190e316_lang_css_scoped_true_ = __webpa
|
|
|
11278
11189
|
// This module is a runtime utility for cleaner component module output and will
|
|
11279
11190
|
// be included in the final webpack user bundle.
|
|
11280
11191
|
|
|
11281
|
-
function normalizeComponent
|
|
11192
|
+
function normalizeComponent(
|
|
11282
11193
|
scriptExports,
|
|
11283
11194
|
render,
|
|
11284
11195
|
staticRenderFns,
|
|
11285
11196
|
functionalTemplate,
|
|
11286
11197
|
injectStyles,
|
|
11287
11198
|
scopeId,
|
|
11288
|
-
moduleIdentifier
|
|
11199
|
+
moduleIdentifier /* server only */,
|
|
11289
11200
|
shadowMode /* vue-cli only */
|
|
11290
11201
|
) {
|
|
11291
11202
|
// Vue.extend constructor export interop
|
|
11292
|
-
var options =
|
|
11293
|
-
? scriptExports.options
|
|
11294
|
-
: scriptExports
|
|
11203
|
+
var options =
|
|
11204
|
+
typeof scriptExports === 'function' ? scriptExports.options : scriptExports
|
|
11295
11205
|
|
|
11296
11206
|
// render functions
|
|
11297
11207
|
if (render) {
|
|
@@ -11311,7 +11221,8 @@ function normalizeComponent (
|
|
|
11311
11221
|
}
|
|
11312
11222
|
|
|
11313
11223
|
var hook
|
|
11314
|
-
if (moduleIdentifier) {
|
|
11224
|
+
if (moduleIdentifier) {
|
|
11225
|
+
// server build
|
|
11315
11226
|
hook = function (context) {
|
|
11316
11227
|
// 2.3 injection
|
|
11317
11228
|
context =
|
|
@@ -11337,11 +11248,11 @@ function normalizeComponent (
|
|
|
11337
11248
|
} else if (injectStyles) {
|
|
11338
11249
|
hook = shadowMode
|
|
11339
11250
|
? function () {
|
|
11340
|
-
|
|
11341
|
-
|
|
11342
|
-
|
|
11343
|
-
|
|
11344
|
-
|
|
11251
|
+
injectStyles.call(
|
|
11252
|
+
this,
|
|
11253
|
+
(options.functional ? this.parent : this).$root.$options.shadowRoot
|
|
11254
|
+
)
|
|
11255
|
+
}
|
|
11345
11256
|
: injectStyles
|
|
11346
11257
|
}
|
|
11347
11258
|
|
|
@@ -11352,16 +11263,14 @@ function normalizeComponent (
|
|
|
11352
11263
|
options._injectStyles = hook
|
|
11353
11264
|
// register for functional component in vue file
|
|
11354
11265
|
var originalRender = options.render
|
|
11355
|
-
options.render = function renderWithStyleInjection
|
|
11266
|
+
options.render = function renderWithStyleInjection(h, context) {
|
|
11356
11267
|
hook.call(context)
|
|
11357
11268
|
return originalRender(h, context)
|
|
11358
11269
|
}
|
|
11359
11270
|
} else {
|
|
11360
11271
|
// inject component registration as beforeCreate hook
|
|
11361
11272
|
var existing = options.beforeCreate
|
|
11362
|
-
options.beforeCreate = existing
|
|
11363
|
-
? [].concat(existing, hook)
|
|
11364
|
-
: [hook]
|
|
11273
|
+
options.beforeCreate = existing ? [].concat(existing, hook) : [hook]
|
|
11365
11274
|
}
|
|
11366
11275
|
}
|
|
11367
11276
|
|
|
@@ -11381,7 +11290,7 @@ function normalizeComponent (
|
|
|
11381
11290
|
/* normalize component */
|
|
11382
11291
|
|
|
11383
11292
|
var component = normalizeComponent(
|
|
11384
|
-
|
|
11293
|
+
pdfjs_SwitchPagevue_type_script_lang_js,
|
|
11385
11294
|
SwitchPagevue_type_template_id_0190e316_scoped_true_lang_html_render,
|
|
11386
11295
|
SwitchPagevue_type_template_id_0190e316_scoped_true_lang_html_staticRenderFns,
|
|
11387
11296
|
false,
|
|
@@ -11392,7 +11301,7 @@ var component = normalizeComponent(
|
|
|
11392
11301
|
)
|
|
11393
11302
|
|
|
11394
11303
|
/* harmony default export */ var SwitchPage = (component.exports);
|
|
11395
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--
|
|
11304
|
+
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--13-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--1-0!./node_modules/vue-loader/lib??vue-loader-options!./src/packages/pdfjs/PdfView216.vue?vue&type=script&lang=js
|
|
11396
11305
|
|
|
11397
11306
|
|
|
11398
11307
|
|
|
@@ -11427,6 +11336,7 @@ var component = normalizeComponent(
|
|
|
11427
11336
|
//
|
|
11428
11337
|
//
|
|
11429
11338
|
//
|
|
11339
|
+
//
|
|
11430
11340
|
|
|
11431
11341
|
|
|
11432
11342
|
function getChromeVersion() {
|
|
@@ -11455,7 +11365,6 @@ if (getChromeVersion()) {
|
|
|
11455
11365
|
// const PDFJS = require('pdfjs-dist/legacy/build/pdf.js')
|
|
11456
11366
|
var PDFJS = __webpack_require__("9511");
|
|
11457
11367
|
var defautScale = 1.0;
|
|
11458
|
-
|
|
11459
11368
|
// PDFJS.GlobalWorkerOptions.workerSrc = require('pdfjs-dist/legacy/build/pdf.worker.min.js')
|
|
11460
11369
|
PDFJS.GlobalWorkerOptions.workerSrc = __webpack_require__("2aad");
|
|
11461
11370
|
// https://unpkg.com/pdfjs-dist@2.16.105/cmaps/
|
|
@@ -11463,7 +11372,7 @@ PDFJS.GlobalWorkerOptions.workerSrc = __webpack_require__("2aad");
|
|
|
11463
11372
|
// 使用代理的cmaps,会导致加载很慢,改用本地
|
|
11464
11373
|
|
|
11465
11374
|
var cMapUrl = 'https://wsp.totodi.com/staticfiles_web/web/pdfjs/cmaps/';
|
|
11466
|
-
/* harmony default export */ var
|
|
11375
|
+
/* harmony default export */ var PdfView216vue_type_script_lang_js = ({
|
|
11467
11376
|
components: {
|
|
11468
11377
|
SwitchPage: SwitchPage
|
|
11469
11378
|
},
|
|
@@ -11528,18 +11437,33 @@ var cMapUrl = 'https://wsp.totodi.com/staticfiles_web/web/pdfjs/cmaps/';
|
|
|
11528
11437
|
renderPage: function renderPage(num) {
|
|
11529
11438
|
var _this = this;
|
|
11530
11439
|
return _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
|
|
11531
|
-
var vm, page, scaleNum, viewport, viewboxWidth, desiredWidth, canvas, renderContext
|
|
11440
|
+
var vm, page, scaleNum, viewport, viewboxWidth, desiredWidth, canvas, renderContext;
|
|
11532
11441
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
11533
11442
|
while (1) switch (_context.prev = _context.next) {
|
|
11534
11443
|
case 0:
|
|
11444
|
+
console.log('renderPage ', _this.pageRendering);
|
|
11445
|
+
if (!_this.pageRendering) {
|
|
11446
|
+
_context.next = 5;
|
|
11447
|
+
break;
|
|
11448
|
+
}
|
|
11449
|
+
_this.pageNumPending = num;
|
|
11450
|
+
_context.next = 39;
|
|
11451
|
+
break;
|
|
11452
|
+
case 5:
|
|
11535
11453
|
// 渲染pdf
|
|
11536
11454
|
vm = _this;
|
|
11537
11455
|
_this.pageRendering = true;
|
|
11538
11456
|
// Using promise to fetch the page
|
|
11539
|
-
|
|
11540
|
-
|
|
11457
|
+
if (_this.pdfDoc) {
|
|
11458
|
+
_context.next = 9;
|
|
11459
|
+
break;
|
|
11460
|
+
}
|
|
11461
|
+
return _context.abrupt("return", false);
|
|
11462
|
+
case 9:
|
|
11463
|
+
_context.prev = 9;
|
|
11464
|
+
_context.next = 12;
|
|
11541
11465
|
return _this.pdfDoc.getPage(num);
|
|
11542
|
-
case
|
|
11466
|
+
case 12:
|
|
11543
11467
|
page = _context.sent;
|
|
11544
11468
|
scaleNum = vm.compuscale;
|
|
11545
11469
|
viewport = '';
|
|
@@ -11572,13 +11496,11 @@ var cMapUrl = 'https://wsp.totodi.com/staticfiles_web/web/pdfjs/cmaps/';
|
|
|
11572
11496
|
renderContext = {
|
|
11573
11497
|
canvasContext: canvas.getContext('2d'),
|
|
11574
11498
|
viewport: viewport
|
|
11575
|
-
};
|
|
11576
|
-
_context.next =
|
|
11577
|
-
return page.render(renderContext);
|
|
11578
|
-
case
|
|
11579
|
-
|
|
11580
|
-
// Wait for rendering to finish
|
|
11581
|
-
renderTask.promise;
|
|
11499
|
+
}; // Wait for rendering to finish
|
|
11500
|
+
_context.next = 28;
|
|
11501
|
+
return page.render(renderContext).promise;
|
|
11502
|
+
case 28:
|
|
11503
|
+
// console.log(' await page.render 168')
|
|
11582
11504
|
vm.pageRendering = false;
|
|
11583
11505
|
if (vm.pageNumPending !== null) {
|
|
11584
11506
|
// New page rendering is pending
|
|
@@ -11586,21 +11508,22 @@ var cMapUrl = 'https://wsp.totodi.com/staticfiles_web/web/pdfjs/cmaps/';
|
|
|
11586
11508
|
vm.pageNumPending = null;
|
|
11587
11509
|
}
|
|
11588
11510
|
_this.$emit('renderSuccess');
|
|
11589
|
-
_context.next =
|
|
11511
|
+
_context.next = 36;
|
|
11590
11512
|
break;
|
|
11591
|
-
case
|
|
11592
|
-
_context.prev =
|
|
11593
|
-
_context.t0 = _context["catch"](
|
|
11513
|
+
case 33:
|
|
11514
|
+
_context.prev = 33;
|
|
11515
|
+
_context.t0 = _context["catch"](9);
|
|
11594
11516
|
console.error(_context.t0);
|
|
11595
|
-
case
|
|
11596
|
-
_context.prev =
|
|
11517
|
+
case 36:
|
|
11518
|
+
_context.prev = 36;
|
|
11519
|
+
// console.log('finally 178')
|
|
11597
11520
|
_this.pageRendering = false;
|
|
11598
|
-
return _context.finish(
|
|
11599
|
-
case
|
|
11521
|
+
return _context.finish(36);
|
|
11522
|
+
case 39:
|
|
11600
11523
|
case "end":
|
|
11601
11524
|
return _context.stop();
|
|
11602
11525
|
}
|
|
11603
|
-
}, _callee, null, [[
|
|
11526
|
+
}, _callee, null, [[9, 33, 36, 39]]);
|
|
11604
11527
|
}))();
|
|
11605
11528
|
},
|
|
11606
11529
|
prev: function prev() {
|
|
@@ -11639,13 +11562,15 @@ var cMapUrl = 'https://wsp.totodi.com/staticfiles_web/web/pdfjs/cmaps/';
|
|
|
11639
11562
|
}
|
|
11640
11563
|
this.viewport = null;
|
|
11641
11564
|
this.pdfDoc.destroy();
|
|
11565
|
+
// console.log('closepdf end')
|
|
11642
11566
|
}
|
|
11643
|
-
this.pdfDoc = null
|
|
11567
|
+
// this.pdfDoc = null
|
|
11644
11568
|
this.isready = false;
|
|
11645
11569
|
this.compuscale = this.scale;
|
|
11646
11570
|
this.$emit('closepdf');
|
|
11647
11571
|
},
|
|
11648
11572
|
queueRenderPage: function queueRenderPage(num) {
|
|
11573
|
+
// console.log('queueRenderPage 226', this.pageRendering)
|
|
11649
11574
|
if (this.pageRendering) {
|
|
11650
11575
|
this.pageNumPending = num;
|
|
11651
11576
|
} else {
|
|
@@ -11673,60 +11598,58 @@ var cMapUrl = 'https://wsp.totodi.com/staticfiles_web/web/pdfjs/cmaps/';
|
|
|
11673
11598
|
// console.log('-----encodeURI------', url)
|
|
11674
11599
|
// }
|
|
11675
11600
|
console.log('----PdfView---', url);
|
|
11676
|
-
|
|
11677
|
-
|
|
11601
|
+
if (_this2.pdfDoc) {
|
|
11602
|
+
// console.log('pdfDocument is ready destroy,,')
|
|
11603
|
+
_this2.pdfDoc.destroy();
|
|
11604
|
+
}
|
|
11605
|
+
_context2.prev = 5;
|
|
11606
|
+
_context2.next = 8;
|
|
11678
11607
|
return PDFJS.getDocument({
|
|
11679
11608
|
url: encodeURI(url),
|
|
11680
11609
|
cMapUrl: cMapUrl,
|
|
11681
11610
|
cMapPacked: true
|
|
11682
11611
|
}).promise;
|
|
11683
|
-
case
|
|
11612
|
+
case 8:
|
|
11684
11613
|
pdfDoc_ = _context2.sent;
|
|
11685
|
-
_context2.next =
|
|
11614
|
+
_context2.next = 23;
|
|
11686
11615
|
break;
|
|
11687
|
-
case
|
|
11688
|
-
_context2.prev =
|
|
11689
|
-
_context2.t0 = _context2["catch"](
|
|
11616
|
+
case 11:
|
|
11617
|
+
_context2.prev = 11;
|
|
11618
|
+
_context2.t0 = _context2["catch"](5);
|
|
11690
11619
|
console.error(_context2.t0);
|
|
11691
|
-
_context2.next =
|
|
11620
|
+
_context2.next = 16;
|
|
11692
11621
|
return fetch(new URL(url, window.location).href);
|
|
11693
|
-
case
|
|
11622
|
+
case 16:
|
|
11694
11623
|
pdfData = _context2.sent;
|
|
11695
|
-
_context2.next =
|
|
11624
|
+
_context2.next = 19;
|
|
11696
11625
|
return pdfData.arrayBuffer();
|
|
11697
|
-
case
|
|
11626
|
+
case 19:
|
|
11698
11627
|
arrayBufferPdf = _context2.sent;
|
|
11699
|
-
_context2.next =
|
|
11628
|
+
_context2.next = 22;
|
|
11700
11629
|
return PDFJS.getDocument({
|
|
11701
11630
|
data: arrayBufferPdf
|
|
11702
11631
|
}).promise;
|
|
11703
|
-
case 21:
|
|
11704
|
-
pdfDoc_ = _context2.sent;
|
|
11705
11632
|
case 22:
|
|
11706
|
-
|
|
11633
|
+
pdfDoc_ = _context2.sent;
|
|
11634
|
+
case 23:
|
|
11635
|
+
_context2.prev = 23;
|
|
11707
11636
|
_this2.fileLoading = false;
|
|
11708
|
-
return _context2.finish(
|
|
11709
|
-
case
|
|
11710
|
-
|
|
11711
|
-
|
|
11712
|
-
break;
|
|
11713
|
-
}
|
|
11714
|
-
console.log('pdfDocument is ready destroy,,');
|
|
11715
|
-
_context2.next = 29;
|
|
11716
|
-
return _this2.closepdf();
|
|
11717
|
-
case 29:
|
|
11718
|
-
_this2.pdfDoc = null;
|
|
11719
|
-
case 30:
|
|
11637
|
+
return _context2.finish(23);
|
|
11638
|
+
case 26:
|
|
11639
|
+
// console.log('pdfDoc_', pdfDoc_)
|
|
11640
|
+
// debugger
|
|
11720
11641
|
_this2.pdfDoc = pdfDoc_;
|
|
11642
|
+
// 初始化pdf
|
|
11721
11643
|
_this2.page_count = pdfDoc_.numPages;
|
|
11722
11644
|
_this2.$emit('numPages', pdfDoc_.numPages);
|
|
11645
|
+
// console.log('265', this.pageRendering)
|
|
11723
11646
|
_this2.renderPage(_this2.pageNum);
|
|
11724
11647
|
_this2.emitPage(_this2.pageNum);
|
|
11725
|
-
case
|
|
11648
|
+
case 31:
|
|
11726
11649
|
case "end":
|
|
11727
11650
|
return _context2.stop();
|
|
11728
11651
|
}
|
|
11729
|
-
}, _callee2, null, [[
|
|
11652
|
+
}, _callee2, null, [[5, 11, 23, 26]]);
|
|
11730
11653
|
}))();
|
|
11731
11654
|
},
|
|
11732
11655
|
onDrop: function onDrop(event) {
|
|
@@ -11739,6 +11662,7 @@ var cMapUrl = 'https://wsp.totodi.com/staticfiles_web/web/pdfjs/cmaps/';
|
|
|
11739
11662
|
},
|
|
11740
11663
|
updateScale: function updateScale() {
|
|
11741
11664
|
this.compuscale = this.scale;
|
|
11665
|
+
// console.log('updateScale 278')
|
|
11742
11666
|
this.renderPage(this.pageNum);
|
|
11743
11667
|
}
|
|
11744
11668
|
},
|
|
@@ -11750,7 +11674,7 @@ var cMapUrl = 'https://wsp.totodi.com/staticfiles_web/web/pdfjs/cmaps/';
|
|
|
11750
11674
|
// }
|
|
11751
11675
|
},
|
|
11752
11676
|
beforeDestroy: function beforeDestroy() {
|
|
11753
|
-
console.log('---', this.pdfDoc)
|
|
11677
|
+
// console.log('---', this.pdfDoc)
|
|
11754
11678
|
if (this.pdfDoc) {
|
|
11755
11679
|
this.closepdf();
|
|
11756
11680
|
}
|
|
@@ -11764,14 +11688,16 @@ var cMapUrl = 'https://wsp.totodi.com/staticfiles_web/web/pdfjs/cmaps/';
|
|
|
11764
11688
|
pdfurl: {
|
|
11765
11689
|
handler: function handler(val) {
|
|
11766
11690
|
var _this3 = this;
|
|
11691
|
+
// console.log('watch url change: ', val)
|
|
11692
|
+
if (this.pdfDoc) {
|
|
11693
|
+
// console.log('closepdf')
|
|
11694
|
+
this.closepdf();
|
|
11695
|
+
}
|
|
11767
11696
|
this.$nextTick(function () {
|
|
11768
11697
|
if (val) {
|
|
11769
11698
|
_this3.pageNum = 1;
|
|
11770
11699
|
_this3.initPage = true;
|
|
11771
11700
|
_this3.loadUrl(val);
|
|
11772
|
-
if (_this3.pdfDoc) {
|
|
11773
|
-
_this3.closepdf();
|
|
11774
|
-
}
|
|
11775
11701
|
}
|
|
11776
11702
|
if (_this3.showPages) {
|
|
11777
11703
|
_this3.$refs.switchPage.setPage(1);
|
|
@@ -11782,14 +11708,20 @@ var cMapUrl = 'https://wsp.totodi.com/staticfiles_web/web/pdfjs/cmaps/';
|
|
|
11782
11708
|
},
|
|
11783
11709
|
// 监听页码变化,渲染对应合同页
|
|
11784
11710
|
page: function page(newPage, oldPage) {
|
|
11785
|
-
|
|
11711
|
+
// console.log('watch page change: ', newPage)
|
|
11712
|
+
if (this.pdfDoc) {
|
|
11713
|
+
this.queueRenderPage(newPage);
|
|
11714
|
+
} else {
|
|
11715
|
+
this.pageNum = newPage;
|
|
11716
|
+
// console.log('no pdfDoc')
|
|
11717
|
+
}
|
|
11786
11718
|
}
|
|
11787
11719
|
}
|
|
11788
11720
|
});
|
|
11789
|
-
// CONCATENATED MODULE: ./src/packages/pdfjs/PdfView216.vue?vue&type=script&lang=js
|
|
11790
|
-
/* harmony default export */ var
|
|
11791
|
-
// EXTERNAL MODULE: ./src/packages/pdfjs/PdfView216.vue?vue&type=style&index=0&id=
|
|
11792
|
-
var
|
|
11721
|
+
// CONCATENATED MODULE: ./src/packages/pdfjs/PdfView216.vue?vue&type=script&lang=js
|
|
11722
|
+
/* harmony default export */ var pdfjs_PdfView216vue_type_script_lang_js = (PdfView216vue_type_script_lang_js);
|
|
11723
|
+
// EXTERNAL MODULE: ./src/packages/pdfjs/PdfView216.vue?vue&type=style&index=0&id=071495fa&prod&lang=less&scoped=true
|
|
11724
|
+
var PdfView216vue_type_style_index_0_id_071495fa_prod_lang_less_scoped_true = __webpack_require__("9f3b");
|
|
11793
11725
|
|
|
11794
11726
|
// CONCATENATED MODULE: ./src/packages/pdfjs/PdfView216.vue
|
|
11795
11727
|
|
|
@@ -11801,12 +11733,12 @@ var PdfView216vue_type_style_index_0_id_3ce34874_lang_less_scoped_true_ = __webp
|
|
|
11801
11733
|
/* normalize component */
|
|
11802
11734
|
|
|
11803
11735
|
var PdfView216_component = normalizeComponent(
|
|
11804
|
-
|
|
11736
|
+
pdfjs_PdfView216vue_type_script_lang_js,
|
|
11805
11737
|
render,
|
|
11806
11738
|
staticRenderFns,
|
|
11807
11739
|
false,
|
|
11808
11740
|
null,
|
|
11809
|
-
"
|
|
11741
|
+
"071495fa",
|
|
11810
11742
|
null
|
|
11811
11743
|
|
|
11812
11744
|
)
|