hoeditor-web 3.3.3 → 3.3.4-beta.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/lib/hoeditor.mjs CHANGED
@@ -1,5 +1,5 @@
1
1
  import "vue";
2
- import { H as i, d as r, b as e, a as l, e as t, T as H, f as d, i as f } from "./index-D_r4vqGA.mjs";
2
+ import { H as i, d as r, b as e, a as l, e as t, T as H, f as d, i as f } from "./index-ql43YyPO.mjs";
3
3
  export {
4
4
  i as HoDocs,
5
5
  r as HoEditorProvide,
@@ -15203,7 +15203,7 @@ class DrawSignNode extends DrawCombineNode {
15203
15203
  }
15204
15204
  }
15205
15205
  }
15206
- const version = "3.3.3";
15206
+ const version = "3.3.4-beta.0";
15207
15207
  var FingerPosition = /* @__PURE__ */ ((a) => (a[a.left = 0] = "left", a[a.center = 1] = "center", a[a.right = 2] = "right", a))(FingerPosition || {});
15208
15208
  class SignNode extends BaseNode {
15209
15209
  constructor(hoEditorFactoryID, rootNodes, pNode, nodeType, number, type, name, signType, signFormat, signor, signTime, signTimeFormat, imgSrc, imgWidth, imgHeight, customProperty, isTemplate, styleIndex, connectMode, isFront, allowEditSignTime, fingerPrintSrc, fingerPosition, attribute, connectChar, otherProperties, dataId, associatedElement, isTemp, innerIdentifier) {
@@ -44906,33 +44906,23 @@ class PageNumNode extends ControlNode {
44906
44906
  class DrawPageMarkNode extends DrawCombineNode {
44907
44907
  constructor(t, r, o, n, s, l) {
44908
44908
  super(t, r, o, n);
44909
- const c = DrawPageMarkNode.getPageMarkText(
44910
- t,
44911
- o.formatType,
44912
- s,
44913
- l
44914
- );
44909
+ const c = DrawPageMarkNode.getPageMarkText(t, o.formatType, s, l);
44915
44910
  this.updatePageNum(c);
44916
44911
  }
44917
44912
  updatePageNum(t) {
44918
44913
  this.removeAllChildren();
44919
- const r = this._node.styleIndex, o = new DrawStyleText(
44920
- this._hoEditorFactoryID,
44921
- this,
44922
- t,
44923
- r
44924
- );
44914
+ const r = this._node.styleIndex, o = new DrawStyleText(this._hoEditorFactoryID, this, t, r);
44925
44915
  this._dHeight = o.dHeight, this._dWidth = o.dWidth, this.y = o.baseY;
44926
44916
  }
44927
44917
  static getPageMarkText(t, r, o, n) {
44928
44918
  const s = HOEditorFactorys.instance().getFactory(t);
44929
44919
  o += s.pageProperty.startPageNumber || 0;
44930
- const l = Math.max(s.drawTree.drawPages.length.toString().length, 2);
44920
+ const l = Math.max(o.toString().length, 2);
44931
44921
  if (r === 0)
44932
44922
  return n ? " ".repeat(l) : o.toString();
44933
44923
  {
44934
44924
  const c = s.unitConvert.getChineseNumber(o);
44935
- return n ? " ".repeat(l * 2) : c.toString();
44925
+ return n ? " ".repeat(l) : c.toString();
44936
44926
  }
44937
44927
  }
44938
44928
  static paintMarkNode(t, r, o, n) {
@@ -44952,14 +44942,7 @@ class DrawPageMarkNode extends DrawCombineNode {
44952
44942
  const f = l.drawTree.drawPages[l.drawTree.drawPages.length - 1];
44953
44943
  f.drawMainDoc.children.length === 2 && !(f.drawMainDoc.children[0] instanceof DrawPageTable) && f.drawMainDoc.children[1] && f.drawMainDoc.children[1].drawItems.length === 0 && (d = l.drawTree.drawPages.length - 1);
44954
44944
  }
44955
- const u = new DrawPageMarkNode(
44956
- t,
44957
- r.rootPath,
44958
- r,
44959
- 0,
44960
- d,
44961
- !1
44962
- );
44945
+ const u = new DrawPageMarkNode(t, r.rootPath, r, 0, d, !1);
44963
44946
  return d < 9 && (c.x += Math.floor((r.drawNodes[0]._dWidth - u._dWidth) / 2)), u.x = c.x, u.y = c.y, u;
44964
44947
  }
44965
44948
  updatePaint() {
@@ -44969,34 +44952,17 @@ class DrawPageMarkNode extends DrawCombineNode {
44969
44952
  s.parent && s.parent.removeChild(s);
44970
44953
  }
44971
44954
  if (o.length = 0, t) {
44972
- const n = r.drawPageTree.getDrawPageByDNode(
44973
- this
44974
- );
44955
+ const n = r.drawPageTree.getDrawPageByDNode(this);
44975
44956
  if (n && n.drawMainDoc) {
44976
- const s = DrawPageMarkNode.paintMarkNode(
44977
- this._hoEditorFactoryID,
44978
- this._node,
44979
- n.drawMainDoc,
44980
- HeaderFooterType.hftUnkown
44981
- );
44957
+ const s = DrawPageMarkNode.paintMarkNode(this._hoEditorFactoryID, this._node, n.drawMainDoc, HeaderFooterType.hftUnkown);
44982
44958
  n.drawMainDoc.addChild(s), o.push(s), r.drawPageTree.updateDrawPage(n.pageIndex);
44983
44959
  }
44984
44960
  } else {
44985
44961
  const n = r.drawPageTree.getMainRootArea(this);
44986
44962
  if (!n) return;
44987
- const [
44988
- s,
44989
- l
44990
- ] = r.subDocManger.getAllSameSubDocPageRange(
44991
- n.index,
44992
- n.hftType,
44993
- !1
44994
- );
44963
+ const [s, l] = r.subDocManger.getAllSameSubDocPageRange(n.index, n.hftType, !1);
44995
44964
  for (let d = s; d <= l; d++) {
44996
- const u = r.subDocManger.getSubDocCopyDrawArea(
44997
- d,
44998
- n.hftType
44999
- );
44965
+ const u = r.subDocManger.getSubDocCopyDrawArea(d, n.hftType);
45000
44966
  this.paintPageMarkToArea(u);
45001
44967
  }
45002
44968
  const c = r.subDocManger.getSubDocDrawArea(s, n.hftType);
@@ -45005,23 +44971,13 @@ class DrawPageMarkNode extends DrawCombineNode {
45005
44971
  }
45006
44972
  paintPageMarkToArea(t) {
45007
44973
  this.removePageMarkDrawNode(this._node, t), t instanceof DrawHeader ? HeaderFooterType.hftHead : t instanceof DrawFooter ? HeaderFooterType.hftFoot : HeaderFooterType.hftUnkown;
45008
- const r = this.node.drawPageMarkNodes, o = DrawPageMarkNode.paintMarkNode(
45009
- this._hoEditorFactoryID,
45010
- this._node,
45011
- t,
45012
- HeaderFooterType.hftUnkown
45013
- );
44974
+ const r = this.node.drawPageMarkNodes, o = DrawPageMarkNode.paintMarkNode(this._hoEditorFactoryID, this._node, t, HeaderFooterType.hftUnkown);
45014
44975
  t.addChild(o), HOEditorFactorys.instance().getFactory(this._hoEditorFactoryID).drawPageTree.updateDrawPage(t.index), r.push(o);
45015
44976
  }
45016
44977
  repaintPageMarkNodes(t, r) {
45017
44978
  const o = this.node;
45018
44979
  this.removePageMarkDrawNode(o, t);
45019
- const n = DrawPageMarkNode.paintMarkNode(
45020
- this._hoEditorFactoryID,
45021
- o,
45022
- t,
45023
- r
45024
- );
44980
+ const n = DrawPageMarkNode.paintMarkNode(this._hoEditorFactoryID, o, t, r);
45025
44981
  this.node.drawPageMarkNodes.push(n), t.addChild(n);
45026
44982
  }
45027
44983
  removePageMarkDrawNode(t, r) {
@@ -65172,7 +65128,7 @@ WebPDecoder.prototype.getData = function() {
65172
65128
  (function(a) {
65173
65129
  function t() {
65174
65130
  return function() {
65175
- return globalObject.canvg ? Promise.resolve(globalObject.canvg) : import("./index.es-BQGzH3YG.mjs");
65131
+ return globalObject.canvg ? Promise.resolve(globalObject.canvg) : import("./index.es-CGQjzc_f.mjs");
65176
65132
  }().catch(function(r) {
65177
65133
  return Promise.reject(new Error("Could not load canvg: " + r));
65178
65134
  }).then(function(r) {
@@ -1,4 +1,4 @@
1
- import { c as Da, _ as Va, g as il } from "./index-D_r4vqGA.mjs";
1
+ import { c as Da, _ as Va, g as il } from "./index-ql43YyPO.mjs";
2
2
  var fn = {}, cn = {}, cr, vn;
3
3
  function Q() {
4
4
  if (vn) return cr;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "hoeditor-web",
3
- "version": "3.3.3",
3
+ "version": "3.3.4-beta.0",
4
4
  "private": false,
5
5
  "main": "lib/hoeditor.mjs",
6
6
  "typings": "types/index.d.ts",