hoeditor-web 3.0.21 → 3.0.22
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/lib/hoeditor.umd.js +20 -15
- package/lib/hoeditor.umd.min.js +2 -2
- package/package.json +1 -1
package/lib/hoeditor.umd.js
CHANGED
|
@@ -35266,22 +35266,22 @@ var Print = /*#__PURE__*/function () {
|
|
|
35266
35266
|
(0,createClass/* default */.Z)(Print, null, [{
|
|
35267
35267
|
key: "openDataUriInWindow",
|
|
35268
35268
|
value: function openDataUriInWindow(PDF, fileName, width) {
|
|
35269
|
-
var _window$top, _window$top$chrome;
|
|
35270
35269
|
if (navigator && navigator.userAgent.toLowerCase().indexOf('electron') !== -1) {
|
|
35271
35270
|
var htmlForNewWindow = '<html>' + '<title>' + fileName + '</title>' + '<style>html, body { padding: 0; margin: 0; } iframe { width: 100%; height: 100%; border: 0;} </style>' + '<body>' + '<iframe src="' + PDF.output('bloburl') + '"></iframe>' + '</body></html>';
|
|
35272
35271
|
var nW = window.open('', 'modal', 'width=' + (width + 400) + ',height=800');
|
|
35273
35272
|
if (nW) {
|
|
35274
35273
|
nW.document.write(htmlForNewWindow);
|
|
35275
35274
|
}
|
|
35276
|
-
}
|
|
35277
|
-
|
|
35278
|
-
|
|
35279
|
-
|
|
35280
|
-
|
|
35281
|
-
|
|
35282
|
-
|
|
35283
|
-
|
|
35284
|
-
}
|
|
35275
|
+
}
|
|
35276
|
+
// else if (window.top?.chrome?.webview) {
|
|
35277
|
+
// window.top?.chrome?.webview.postMessage({
|
|
35278
|
+
// exec: 'printpdf',
|
|
35279
|
+
// data: {
|
|
35280
|
+
// base64: PDF.output('datauristring').replace(/^data:application\/pdf;filename=generated.pdf;base64,/, ''),
|
|
35281
|
+
// },
|
|
35282
|
+
// });
|
|
35283
|
+
// } =
|
|
35284
|
+
else {
|
|
35285
35285
|
if (document.querySelector('#Ho_Editor_Print_Iframe')) {
|
|
35286
35286
|
document.body.removeChild(document.querySelector('#Ho_Editor_Print_Iframe'));
|
|
35287
35287
|
}
|
|
@@ -260010,7 +260010,7 @@ var SignNode = __webpack_require__(24701);
|
|
|
260010
260010
|
// EXTERNAL MODULE: ./src/editor/dom/treeNode/ParagraphNode.ts
|
|
260011
260011
|
var ParagraphNode = __webpack_require__(67945);
|
|
260012
260012
|
;// CONCATENATED MODULE: ./src/components/version.ts
|
|
260013
|
-
/* harmony default export */ var version = ('3.0.
|
|
260013
|
+
/* harmony default export */ var version = ('3.0.22');
|
|
260014
260014
|
// EXTERNAL MODULE: ./src/components/controls/poperTipText/PoperTipText.vue + 5 modules
|
|
260015
260015
|
var PoperTipText = __webpack_require__(15845);
|
|
260016
260016
|
;// CONCATENATED MODULE: ./src/components/controls/poperTipText/index.ts
|
|
@@ -268667,9 +268667,9 @@ var VueController = /*#__PURE__*/function () {
|
|
|
268667
268667
|
*/
|
|
268668
268668
|
}, {
|
|
268669
268669
|
key: "printPromisePDF",
|
|
268670
|
-
value: function printPromisePDF(printMode, printAppoint) {
|
|
268670
|
+
value: function printPromisePDF(printMode, printAppoint, type, callback) {
|
|
268671
268671
|
var hoEditorFactory = HOEditorFactorys/* HOEditorFactorys.instance */.b.instance().getFactory(this._hoEditorFactoryID);
|
|
268672
|
-
hoEditorFactory.printController.printPromisePDF(printMode, printAppoint);
|
|
268672
|
+
hoEditorFactory.printController.printPromisePDF(printMode, printAppoint, type, callback);
|
|
268673
268673
|
}
|
|
268674
268674
|
/**
|
|
268675
268675
|
* 保存pdf
|
|
@@ -276455,8 +276455,13 @@ var PrintController = /*#__PURE__*/function () {
|
|
|
276455
276455
|
}
|
|
276456
276456
|
}).then(function (res) {
|
|
276457
276457
|
if (res === 'printend') {
|
|
276458
|
-
|
|
276459
|
-
|
|
276458
|
+
var lastPos = hoEditorFactory.printStatus.printRecord.last();
|
|
276459
|
+
if (callback && lastPos) {
|
|
276460
|
+
callback({
|
|
276461
|
+
startPageNum: 0,
|
|
276462
|
+
pageNum: lastPos[0],
|
|
276463
|
+
positionY: lastPos[1]
|
|
276464
|
+
});
|
|
276460
276465
|
}
|
|
276461
276466
|
hoEditorFactory.printStatus.printAppoint = '';
|
|
276462
276467
|
hoEditorFactory.printStatus.drawPrintRecord.Position = [0, 0];
|