@libresign/pdf-elements 0.1.1 → 0.2.0
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/README.md +14 -12
- package/dist/pdf-elements.common.js +35 -200
- package/dist/pdf-elements.common.js.map +1 -1
- package/dist/pdf-elements.css +1 -1
- package/dist/pdf-elements.umd.js +35 -200
- package/dist/pdf-elements.umd.js.map +1 -1
- package/dist/pdf-elements.umd.min.js +22 -1
- package/dist/pdf-elements.umd.min.js.map +1 -1
- package/package.json +1 -1
- package/src/components/PDFElements.vue +33 -0
- package/src/utils/asyncReader.js +2 -2
package/dist/pdf-elements.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
canvas[data-v-2c9e224a]{display:block}.draggable-wrapper[data-v-55db89ce]{position:relative}.actions-toolbar[data-v-55db89ce]{position:absolute;display:flex;gap:4px;background:#1f2937;border-radius:6px;padding:6px 8px;box-shadow:0 4px 12px -2px #00000026,0 2px 6px -2px #0000001a;z-index:100;white-space:nowrap}.action-btn[data-v-55db89ce]{border:none;background:#0000;color:#fff;padding:4px;border-radius:4px;cursor:pointer;display:flex;align-items:center;justify-content:center;transition:background .12s ease}.action-btn[data-v-55db89ce]:hover{background:#ffffff1a}.draggable-element[data-v-55db89ce]{position:absolute;cursor:move;user-select:none;border-radius:6px;overflow:visible}.draggable-element.selected[data-v-55db89ce]{box-shadow:inset 0 0 0 2px #2563eb}.resize-handle[data-v-55db89ce]{position:absolute;width:10px;height:10px;background:#2563eb;border:1px solid #fff;border-radius:2px;padding:0;margin:0;cursor:pointer;z-index:200}.handle-top-left[data-v-55db89ce]{top:-6px;left:-6px;cursor:nwse-resize}.handle-top-right[data-v-55db89ce]{top:-6px;right:-6px;cursor:nesw-resize}.handle-bottom-left[data-v-55db89ce]{bottom:-6px;left:-6px;cursor:nesw-resize}.handle-bottom-right[data-v-55db89ce]{bottom:-6px;right:-6px;cursor:nwse-resize}.pdf-elements-root[data-v-
|
|
1
|
+
canvas[data-v-2c9e224a]{display:block}.draggable-wrapper[data-v-55db89ce]{position:relative}.actions-toolbar[data-v-55db89ce]{position:absolute;display:flex;gap:4px;background:#1f2937;border-radius:6px;padding:6px 8px;box-shadow:0 4px 12px -2px #00000026,0 2px 6px -2px #0000001a;z-index:100;white-space:nowrap}.action-btn[data-v-55db89ce]{border:none;background:#0000;color:#fff;padding:4px;border-radius:4px;cursor:pointer;display:flex;align-items:center;justify-content:center;transition:background .12s ease}.action-btn[data-v-55db89ce]:hover{background:#ffffff1a}.draggable-element[data-v-55db89ce]{position:absolute;cursor:move;user-select:none;border-radius:6px;overflow:visible}.draggable-element.selected[data-v-55db89ce]{box-shadow:inset 0 0 0 2px #2563eb}.resize-handle[data-v-55db89ce]{position:absolute;width:10px;height:10px;background:#2563eb;border:1px solid #fff;border-radius:2px;padding:0;margin:0;cursor:pointer;z-index:200}.handle-top-left[data-v-55db89ce]{top:-6px;left:-6px;cursor:nwse-resize}.handle-top-right[data-v-55db89ce]{top:-6px;right:-6px;cursor:nesw-resize}.handle-bottom-left[data-v-55db89ce]{bottom:-6px;left:-6px;cursor:nesw-resize}.handle-bottom-right[data-v-55db89ce]{bottom:-6px;right:-6px;cursor:nwse-resize}.pdf-elements-root[data-v-7a179460]{width:100%;height:100%;overflow-y:auto;overflow-x:hidden;box-sizing:border-box}.pages-container[data-v-7a179460]{width:100%;padding:20px 0 0 0;text-align:center;background:#f7fafc;overflow:hidden}.page-slot[data-v-7a179460]{margin:0 auto}.page-wrapper[data-v-7a179460]{display:inline-block;margin-bottom:0}.page-canvas[data-v-7a179460]{position:relative;box-shadow:0 10px 15px -3px #0000001a,0 4px 6px -4px #0000001a}.shadow-outline[data-v-7a179460]{box-shadow:0 0 0 3px #4299e180}.preview-element[data-v-7a179460]{position:absolute;opacity:.7;pointer-events:none}.drag-ghost[data-v-7a179460]{position:fixed;opacity:.9;pointer-events:none;z-index:10000;transform-origin:top left;transition:none;box-shadow:0 8px 16px #0000004d}.overlay[data-v-7a179460]{position:absolute;top:0;left:0;transform-origin:top left;width:100%;height:100%}.page-footer[data-v-7a179460]{display:flex;justify-content:space-between;align-items:center;padding:12px 20px 20px 20px;color:#4b5563;font-size:14px}
|
package/dist/pdf-elements.umd.js
CHANGED
|
@@ -206,22 +206,6 @@ module.exports = !fails(function () {
|
|
|
206
206
|
});
|
|
207
207
|
|
|
208
208
|
|
|
209
|
-
/***/ },
|
|
210
|
-
|
|
211
|
-
/***/ 655
|
|
212
|
-
(module, __unused_webpack_exports, __webpack_require__) {
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
var classof = __webpack_require__(6955);
|
|
216
|
-
|
|
217
|
-
var $String = String;
|
|
218
|
-
|
|
219
|
-
module.exports = function (argument) {
|
|
220
|
-
if (classof(argument) === 'Symbol') throw new TypeError('Cannot convert a Symbol value to a string');
|
|
221
|
-
return $String(argument);
|
|
222
|
-
};
|
|
223
|
-
|
|
224
|
-
|
|
225
209
|
/***/ },
|
|
226
210
|
|
|
227
211
|
/***/ 679
|
|
@@ -296,13 +280,6 @@ module.exports = USE_SYMBOL_AS_UID ? function (it) {
|
|
|
296
280
|
};
|
|
297
281
|
|
|
298
282
|
|
|
299
|
-
/***/ },
|
|
300
|
-
|
|
301
|
-
/***/ 824
|
|
302
|
-
(module, __unused_webpack_exports, __webpack_require__) {
|
|
303
|
-
|
|
304
|
-
module.exports = __webpack_require__.p + "pdf.worker.min.mjs";
|
|
305
|
-
|
|
306
283
|
/***/ },
|
|
307
284
|
|
|
308
285
|
/***/ 851
|
|
@@ -961,20 +938,6 @@ var POLYFILL = isForced.POLYFILL = 'P';
|
|
|
961
938
|
module.exports = isForced;
|
|
962
939
|
|
|
963
940
|
|
|
964
|
-
/***/ },
|
|
965
|
-
|
|
966
|
-
/***/ 2812
|
|
967
|
-
(module) {
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
var $TypeError = TypeError;
|
|
971
|
-
|
|
972
|
-
module.exports = function (passed, required) {
|
|
973
|
-
if (passed < required) throw new $TypeError('Not enough arguments');
|
|
974
|
-
return passed;
|
|
975
|
-
};
|
|
976
|
-
|
|
977
|
-
|
|
978
941
|
/***/ },
|
|
979
942
|
|
|
980
943
|
/***/ 2839
|
|
@@ -1303,62 +1266,6 @@ module.exports =
|
|
|
1303
1266
|
(function () { return this; })() || Function('return this')();
|
|
1304
1267
|
|
|
1305
1268
|
|
|
1306
|
-
/***/ },
|
|
1307
|
-
|
|
1308
|
-
/***/ 4603
|
|
1309
|
-
(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
1310
|
-
|
|
1311
|
-
|
|
1312
|
-
var defineBuiltIn = __webpack_require__(6840);
|
|
1313
|
-
var uncurryThis = __webpack_require__(9504);
|
|
1314
|
-
var toString = __webpack_require__(655);
|
|
1315
|
-
var validateArgumentsLength = __webpack_require__(2812);
|
|
1316
|
-
|
|
1317
|
-
var $URLSearchParams = URLSearchParams;
|
|
1318
|
-
var URLSearchParamsPrototype = $URLSearchParams.prototype;
|
|
1319
|
-
var append = uncurryThis(URLSearchParamsPrototype.append);
|
|
1320
|
-
var $delete = uncurryThis(URLSearchParamsPrototype['delete']);
|
|
1321
|
-
var forEach = uncurryThis(URLSearchParamsPrototype.forEach);
|
|
1322
|
-
var push = uncurryThis([].push);
|
|
1323
|
-
var params = new $URLSearchParams('a=1&a=2&b=3');
|
|
1324
|
-
|
|
1325
|
-
params['delete']('a', 1);
|
|
1326
|
-
// `undefined` case is a Chromium 117 bug
|
|
1327
|
-
// https://bugs.chromium.org/p/v8/issues/detail?id=14222
|
|
1328
|
-
params['delete']('b', undefined);
|
|
1329
|
-
|
|
1330
|
-
if (params + '' !== 'a=2') {
|
|
1331
|
-
defineBuiltIn(URLSearchParamsPrototype, 'delete', function (name /* , value */) {
|
|
1332
|
-
var length = arguments.length;
|
|
1333
|
-
var $value = length < 2 ? undefined : arguments[1];
|
|
1334
|
-
if (length && $value === undefined) return $delete(this, name);
|
|
1335
|
-
var entries = [];
|
|
1336
|
-
forEach(this, function (v, k) { // also validates `this`
|
|
1337
|
-
push(entries, { key: k, value: v });
|
|
1338
|
-
});
|
|
1339
|
-
validateArgumentsLength(length, 1);
|
|
1340
|
-
var key = toString(name);
|
|
1341
|
-
var value = toString($value);
|
|
1342
|
-
var index = 0;
|
|
1343
|
-
var dindex = 0;
|
|
1344
|
-
var found = false;
|
|
1345
|
-
var entriesLength = entries.length;
|
|
1346
|
-
var entry;
|
|
1347
|
-
while (index < entriesLength) {
|
|
1348
|
-
entry = entries[index++];
|
|
1349
|
-
if (found || entry.key === key) {
|
|
1350
|
-
found = true;
|
|
1351
|
-
$delete(this, entry.key);
|
|
1352
|
-
} else dindex++;
|
|
1353
|
-
}
|
|
1354
|
-
while (dindex < entriesLength) {
|
|
1355
|
-
entry = entries[dindex++];
|
|
1356
|
-
if (!(entry.key === key && entry.value === value)) append(this, entry.key, entry.value);
|
|
1357
|
-
}
|
|
1358
|
-
}, { enumerable: true, unsafe: true });
|
|
1359
|
-
}
|
|
1360
|
-
|
|
1361
|
-
|
|
1362
1269
|
/***/ },
|
|
1363
1270
|
|
|
1364
1271
|
/***/ 4659
|
|
@@ -1983,41 +1890,6 @@ module.exports = function (fn) {
|
|
|
1983
1890
|
};
|
|
1984
1891
|
|
|
1985
1892
|
|
|
1986
|
-
/***/ },
|
|
1987
|
-
|
|
1988
|
-
/***/ 7566
|
|
1989
|
-
(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
1990
|
-
|
|
1991
|
-
|
|
1992
|
-
var defineBuiltIn = __webpack_require__(6840);
|
|
1993
|
-
var uncurryThis = __webpack_require__(9504);
|
|
1994
|
-
var toString = __webpack_require__(655);
|
|
1995
|
-
var validateArgumentsLength = __webpack_require__(2812);
|
|
1996
|
-
|
|
1997
|
-
var $URLSearchParams = URLSearchParams;
|
|
1998
|
-
var URLSearchParamsPrototype = $URLSearchParams.prototype;
|
|
1999
|
-
var getAll = uncurryThis(URLSearchParamsPrototype.getAll);
|
|
2000
|
-
var $has = uncurryThis(URLSearchParamsPrototype.has);
|
|
2001
|
-
var params = new $URLSearchParams('a=1');
|
|
2002
|
-
|
|
2003
|
-
// `undefined` case is a Chromium 117 bug
|
|
2004
|
-
// https://bugs.chromium.org/p/v8/issues/detail?id=14222
|
|
2005
|
-
if (params.has('a', 2) || !params.has('a', undefined)) {
|
|
2006
|
-
defineBuiltIn(URLSearchParamsPrototype, 'has', function has(name /* , value */) {
|
|
2007
|
-
var length = arguments.length;
|
|
2008
|
-
var $value = length < 2 ? undefined : arguments[1];
|
|
2009
|
-
if (length && $value === undefined) return $has(this, name);
|
|
2010
|
-
var values = getAll(this, name); // also validates `this`
|
|
2011
|
-
validateArgumentsLength(length, 1);
|
|
2012
|
-
var value = toString($value);
|
|
2013
|
-
var index = 0;
|
|
2014
|
-
while (index < values.length) {
|
|
2015
|
-
if (values[index++] === value) return true;
|
|
2016
|
-
} return false;
|
|
2017
|
-
}, { enumerable: true, unsafe: true });
|
|
2018
|
-
}
|
|
2019
|
-
|
|
2020
|
-
|
|
2021
1893
|
/***/ },
|
|
2022
1894
|
|
|
2023
1895
|
/***/ 7588
|
|
@@ -2382,34 +2254,6 @@ module.exports = DESCRIPTORS && fails(function () {
|
|
|
2382
2254
|
});
|
|
2383
2255
|
|
|
2384
2256
|
|
|
2385
|
-
/***/ },
|
|
2386
|
-
|
|
2387
|
-
/***/ 8721
|
|
2388
|
-
(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
2389
|
-
|
|
2390
|
-
|
|
2391
|
-
var DESCRIPTORS = __webpack_require__(3724);
|
|
2392
|
-
var uncurryThis = __webpack_require__(9504);
|
|
2393
|
-
var defineBuiltInAccessor = __webpack_require__(2106);
|
|
2394
|
-
|
|
2395
|
-
var URLSearchParamsPrototype = URLSearchParams.prototype;
|
|
2396
|
-
var forEach = uncurryThis(URLSearchParamsPrototype.forEach);
|
|
2397
|
-
|
|
2398
|
-
// `URLSearchParams.prototype.size` getter
|
|
2399
|
-
// https://github.com/whatwg/url/pull/734
|
|
2400
|
-
if (DESCRIPTORS && !('size' in URLSearchParamsPrototype)) {
|
|
2401
|
-
defineBuiltInAccessor(URLSearchParamsPrototype, 'size', {
|
|
2402
|
-
get: function size() {
|
|
2403
|
-
var count = 0;
|
|
2404
|
-
forEach(this, function () { count++; });
|
|
2405
|
-
return count;
|
|
2406
|
-
},
|
|
2407
|
-
configurable: true,
|
|
2408
|
-
enumerable: true
|
|
2409
|
-
});
|
|
2410
|
-
}
|
|
2411
|
-
|
|
2412
|
-
|
|
2413
2257
|
/***/ },
|
|
2414
2258
|
|
|
2415
2259
|
/***/ 8727
|
|
@@ -2801,9 +2645,6 @@ module.exports = {
|
|
|
2801
2645
|
/******/ return module.exports;
|
|
2802
2646
|
/******/ }
|
|
2803
2647
|
/******/
|
|
2804
|
-
/******/ // expose the modules object (__webpack_modules__)
|
|
2805
|
-
/******/ __webpack_require__.m = __webpack_modules__;
|
|
2806
|
-
/******/
|
|
2807
2648
|
/************************************************************************/
|
|
2808
2649
|
/******/ /* webpack/runtime/define property getters */
|
|
2809
2650
|
/******/ (() => {
|
|
@@ -2827,32 +2668,6 @@ module.exports = {
|
|
|
2827
2668
|
/******/ __webpack_require__.p = "";
|
|
2828
2669
|
/******/ })();
|
|
2829
2670
|
/******/
|
|
2830
|
-
/******/ /* webpack/runtime/jsonp chunk loading */
|
|
2831
|
-
/******/ (() => {
|
|
2832
|
-
/******/ __webpack_require__.b = (typeof document !== 'undefined' && document.baseURI) || self.location.href;
|
|
2833
|
-
/******/
|
|
2834
|
-
/******/ // object to store loaded and loading chunks
|
|
2835
|
-
/******/ // undefined = chunk not loaded, null = chunk preloaded/prefetched
|
|
2836
|
-
/******/ // [resolve, reject, Promise] = chunk loading, 0 = chunk loaded
|
|
2837
|
-
/******/ var installedChunks = {
|
|
2838
|
-
/******/ 899: 0
|
|
2839
|
-
/******/ };
|
|
2840
|
-
/******/
|
|
2841
|
-
/******/ // no chunk on demand loading
|
|
2842
|
-
/******/
|
|
2843
|
-
/******/ // no prefetching
|
|
2844
|
-
/******/
|
|
2845
|
-
/******/ // no preloaded
|
|
2846
|
-
/******/
|
|
2847
|
-
/******/ // no HMR
|
|
2848
|
-
/******/
|
|
2849
|
-
/******/ // no HMR manifest
|
|
2850
|
-
/******/
|
|
2851
|
-
/******/ // no on chunks loaded
|
|
2852
|
-
/******/
|
|
2853
|
-
/******/ // no jsonp function
|
|
2854
|
-
/******/ })();
|
|
2855
|
-
/******/
|
|
2856
2671
|
/************************************************************************/
|
|
2857
2672
|
var __webpack_exports__ = {};
|
|
2858
2673
|
|
|
@@ -2881,7 +2696,7 @@ if (typeof window !== 'undefined') {
|
|
|
2881
2696
|
// Indicate to webpack that this file can be concatenated
|
|
2882
2697
|
/* harmony default export */ const setPublicPath = (null);
|
|
2883
2698
|
|
|
2884
|
-
;// ./node_modules/babel-loader/lib/index.js??clonedRuleSet-83.use[1]!./node_modules/@vue/vue-loader-v15/lib/loaders/templateLoader.js??ruleSet[1].rules[3]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./src/components/PDFElements.vue?vue&type=template&id=
|
|
2699
|
+
;// ./node_modules/babel-loader/lib/index.js??clonedRuleSet-83.use[1]!./node_modules/@vue/vue-loader-v15/lib/loaders/templateLoader.js??ruleSet[1].rules[3]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./src/components/PDFElements.vue?vue&type=template&id=7a179460&scoped=true
|
|
2885
2700
|
var render = function render() {
|
|
2886
2701
|
var _vm = this,
|
|
2887
2702
|
_c = _vm._self._c;
|
|
@@ -3833,12 +3648,6 @@ var DraggableElement_component = normalizeComponent(
|
|
|
3833
3648
|
)
|
|
3834
3649
|
|
|
3835
3650
|
/* harmony default export */ const DraggableElement = (DraggableElement_component.exports);
|
|
3836
|
-
// EXTERNAL MODULE: ./node_modules/core-js/modules/web.url-search-params.delete.js
|
|
3837
|
-
var web_url_search_params_delete = __webpack_require__(4603);
|
|
3838
|
-
// EXTERNAL MODULE: ./node_modules/core-js/modules/web.url-search-params.has.js
|
|
3839
|
-
var web_url_search_params_has = __webpack_require__(7566);
|
|
3840
|
-
// EXTERNAL MODULE: ./node_modules/core-js/modules/web.url-search-params.size.js
|
|
3841
|
-
var web_url_search_params_size = __webpack_require__(8721);
|
|
3842
3651
|
;// ./node_modules/pdfjs-dist/build/pdf.mjs
|
|
3843
3652
|
/**
|
|
3844
3653
|
* @licstart The following is the entire license notice for the
|
|
@@ -30231,16 +30040,15 @@ globalThis.pdfjsLib = {
|
|
|
30231
30040
|
|
|
30232
30041
|
|
|
30233
30042
|
//# sourceMappingURL=pdf.mjs.map
|
|
30043
|
+
;// ./node_modules/pdfjs-dist/build/pdf.worker.min.mjs
|
|
30044
|
+
const pdf_worker_min_namespaceObject = __webpack_require__.p + "pdf.worker.min.mjs";
|
|
30234
30045
|
;// ./src/utils/asyncReader.js
|
|
30235
|
-
|
|
30236
|
-
|
|
30237
|
-
|
|
30238
30046
|
// SPDX-FileCopyrightText: 2026 LibreCode coop and contributors
|
|
30239
30047
|
// SPDX-License-Identifier: AGPL-3.0-or-later
|
|
30240
30048
|
|
|
30241
30049
|
|
|
30242
|
-
|
|
30243
|
-
GlobalWorkerOptions.workerSrc =
|
|
30050
|
+
|
|
30051
|
+
GlobalWorkerOptions.workerSrc = pdf_worker_min_namespaceObject;
|
|
30244
30052
|
function readAsArrayBuffer(file) {
|
|
30245
30053
|
return new Promise((resolve, reject) => {
|
|
30246
30054
|
const reader = new FileReader();
|
|
@@ -30309,6 +30117,10 @@ function readAsPDF(file) {
|
|
|
30309
30117
|
pageCountFormat: {
|
|
30310
30118
|
type: String,
|
|
30311
30119
|
default: '{currentPage} of {totalPages}'
|
|
30120
|
+
},
|
|
30121
|
+
autoFitZoom: {
|
|
30122
|
+
type: Boolean,
|
|
30123
|
+
default: false
|
|
30312
30124
|
}
|
|
30313
30125
|
},
|
|
30314
30126
|
data() {
|
|
@@ -30381,6 +30193,9 @@ function readAsPDF(file) {
|
|
|
30381
30193
|
this.$el?.addEventListener('wheel', this.boundHandleWheel, {
|
|
30382
30194
|
passive: false
|
|
30383
30195
|
});
|
|
30196
|
+
if (this.autoFitZoom) {
|
|
30197
|
+
window.addEventListener('resize', this.adjustZoomToFit);
|
|
30198
|
+
}
|
|
30384
30199
|
},
|
|
30385
30200
|
beforeUnmount() {
|
|
30386
30201
|
if (this.zoomRafId) {
|
|
@@ -30398,6 +30213,9 @@ function readAsPDF(file) {
|
|
|
30398
30213
|
window.removeEventListener('scroll', this.onViewportScroll);
|
|
30399
30214
|
window.removeEventListener('resize', this.onViewportScroll);
|
|
30400
30215
|
this.$el?.removeEventListener('scroll', this.onViewportScroll);
|
|
30216
|
+
if (this.autoFitZoom) {
|
|
30217
|
+
window.removeEventListener('resize', this.adjustZoomToFit);
|
|
30218
|
+
}
|
|
30401
30219
|
if (this.viewportRafId) {
|
|
30402
30220
|
window.cancelAnimationFrame(this.viewportRafId);
|
|
30403
30221
|
this.viewportRafId = 0;
|
|
@@ -30876,15 +30694,32 @@ function readAsPDF(file) {
|
|
|
30876
30694
|
const doc = this.pdfDocuments[docIndex];
|
|
30877
30695
|
const pagesScale = doc.pagesScale[pageIndex] || 1;
|
|
30878
30696
|
return pageRef.getCanvasMeasurement().canvasHeight / pagesScale;
|
|
30697
|
+
},
|
|
30698
|
+
calculateOptimalScale(maxPageWidth) {
|
|
30699
|
+
const containerWidth = this.$el?.clientWidth || 0;
|
|
30700
|
+
if (!containerWidth || !maxPageWidth) return 1;
|
|
30701
|
+
const availableWidth = containerWidth - 40;
|
|
30702
|
+
return Math.max(0.1, Math.min(2, availableWidth / maxPageWidth));
|
|
30703
|
+
},
|
|
30704
|
+
adjustZoomToFit() {
|
|
30705
|
+
if (!this.autoFitZoom || !this.pdfDocuments.length) return;
|
|
30706
|
+
const canvases = this.$el?.querySelectorAll('canvas');
|
|
30707
|
+
if (!canvases?.length) return;
|
|
30708
|
+
const maxCanvasWidth = Math.max(...Array.from(canvases).map(canvas => canvas.width / (this.scale || 1)));
|
|
30709
|
+
const optimalScale = this.calculateOptimalScale(maxCanvasWidth);
|
|
30710
|
+
if (Math.abs(optimalScale - this.scale) > 0.01) {
|
|
30711
|
+
this.scale = optimalScale;
|
|
30712
|
+
this.visualScale = optimalScale;
|
|
30713
|
+
}
|
|
30879
30714
|
}
|
|
30880
30715
|
}
|
|
30881
30716
|
});
|
|
30882
30717
|
;// ./src/components/PDFElements.vue?vue&type=script&lang=js
|
|
30883
30718
|
/* harmony default export */ const components_PDFElementsvue_type_script_lang_js = (PDFElementsvue_type_script_lang_js);
|
|
30884
|
-
;// ./node_modules/mini-css-extract-plugin/dist/loader.js??clonedRuleSet-55.use[0]!./node_modules/css-loader/dist/cjs.js??clonedRuleSet-55.use[1]!./node_modules/@vue/vue-loader-v15/lib/loaders/stylePostLoader.js!./node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-55.use[2]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./src/components/PDFElements.vue?vue&type=style&index=0&id=
|
|
30719
|
+
;// ./node_modules/mini-css-extract-plugin/dist/loader.js??clonedRuleSet-55.use[0]!./node_modules/css-loader/dist/cjs.js??clonedRuleSet-55.use[1]!./node_modules/@vue/vue-loader-v15/lib/loaders/stylePostLoader.js!./node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-55.use[2]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./src/components/PDFElements.vue?vue&type=style&index=0&id=7a179460&prod&scoped=true&lang=css
|
|
30885
30720
|
// extracted by mini-css-extract-plugin
|
|
30886
30721
|
|
|
30887
|
-
;// ./src/components/PDFElements.vue?vue&type=style&index=0&id=
|
|
30722
|
+
;// ./src/components/PDFElements.vue?vue&type=style&index=0&id=7a179460&prod&scoped=true&lang=css
|
|
30888
30723
|
|
|
30889
30724
|
;// ./src/components/PDFElements.vue
|
|
30890
30725
|
|
|
@@ -30901,7 +30736,7 @@ var PDFElements_component = normalizeComponent(
|
|
|
30901
30736
|
staticRenderFns,
|
|
30902
30737
|
false,
|
|
30903
30738
|
null,
|
|
30904
|
-
"
|
|
30739
|
+
"7a179460",
|
|
30905
30740
|
null
|
|
30906
30741
|
|
|
30907
30742
|
)
|