hoeditor-web 3.3.4-beta.2 → 3.3.4

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-BwYkZrdT.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-StM8bNN8.mjs";
3
3
  export {
4
4
  i as HoDocs,
5
5
  r as HoEditorProvide,
@@ -7643,7 +7643,10 @@ const isDate = (a) => a == null ? !1 : typeof a == "string" ? !isNaN(new Date(a)
7643
7643
  "yyyy-MM-dd",
7644
7644
  "yyyy-MM-dd HH:mm",
7645
7645
  "MM-dd HH:mm",
7646
- "yyyy-MM-dd HH:mm:ss"
7646
+ "yyyy-MM-dd HH:mm:ss",
7647
+ "YYYY/MM",
7648
+ "YYYY-MM",
7649
+ "YYYY年-MM月"
7647
7650
  ], dateFormatValueList = [
7648
7651
  { value: "HH:mm" },
7649
7652
  { value: "HH:mm:ss" },
@@ -7658,21 +7661,25 @@ const isDate = (a) => a == null ? !1 : typeof a == "string" ? !isNaN(new Date(a)
7658
7661
  { value: "MM-dd" },
7659
7662
  { value: "yyyy-MM-dd" },
7660
7663
  { value: "yyyy-MM-dd HH:mm" },
7661
- { value: "yyyy-MM-dd HH:mm:ss" }
7664
+ { value: "yyyy-MM-dd HH:mm:ss" },
7665
+ { value: "YYYY/MM" },
7666
+ { value: "YYYY-MM" },
7667
+ { value: "YYYY年-MM月" }
7662
7668
  ], dateFormat = (a, t) => {
7669
+ var u;
7663
7670
  let r;
7664
7671
  if (a && typeof a == "string")
7665
7672
  if (!isNaN(Number(a)))
7666
7673
  r = toDate(Number(a));
7667
7674
  else {
7668
- let u = a.replace(/[年|月|-]/g, "/");
7669
- if (u = u.replace(/[点|时|分]/g, ":"), u = u.replace(/[日|秒]/g, ""), isNaN(new Date(u).getTime())) {
7670
- if (t && t.includes("MM") && !t.includes("yyyy") && (u = (/* @__PURE__ */ new Date()).getFullYear() + "/" + u), t && t.includes("HH") && !t.includes("ss") && (u = u + ":00", u = u.replace("::", ":")), !u.includes("/")) {
7671
- let f = /* @__PURE__ */ new Date();
7672
- u = `${f.getFullYear()}/${f.getMonth() + 1}/${f.getDate()} ` + u;
7675
+ let f = a.replace(/[年|月|-]/g, "/").replace(/\/{2,}/g, "/");
7676
+ if (f = f.replace(/[点|时|分]/g, ":"), f = f.replace(/[日|秒]/g, ""), isNaN(new Date(f).getTime())) {
7677
+ if (t && t.includes("MM") && !t.includes("yyyy") && !t.includes("YYYY") && (f = (/* @__PURE__ */ new Date()).getFullYear() + "/" + f), t && t.includes("HH") && !t.includes("ss") && (f = f + ":00", f = f.replace("::", ":")), !f.includes("/")) {
7678
+ let p = /* @__PURE__ */ new Date();
7679
+ f = `${p.getFullYear()}/${p.getMonth() + 1}/${p.getDate()} ` + f;
7673
7680
  }
7674
- } else t && t.includes("MM") && !t.toLocaleLowerCase().includes("yyyy") && u.split("/")[1] == "29" && (u = "2024/" + u);
7675
- r = toDate(u);
7681
+ } else t && t.includes("MM") && !t.toLocaleLowerCase().includes("yyyy") && ((u = f.split("/")[1]) == null ? void 0 : u.split(" ")[0]) === "29" && (f = "2024/" + f);
7682
+ r = toDate(f);
7676
7683
  }
7677
7684
  else
7678
7685
  r = toDate(a);
@@ -15203,7 +15210,7 @@ class DrawSignNode extends DrawCombineNode {
15203
15210
  }
15204
15211
  }
15205
15212
  }
15206
- const version = "3.3.4-beta.2";
15213
+ const version = "3.3.4";
15207
15214
  var FingerPosition = /* @__PURE__ */ ((a) => (a[a.left = 0] = "left", a[a.center = 1] = "center", a[a.right = 2] = "right", a))(FingerPosition || {});
15208
15215
  class SignNode extends BaseNode {
15209
15216
  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) {
@@ -15422,10 +15429,10 @@ class SignNode extends BaseNode {
15422
15429
  this._associatedElement !== t && (this._associatedElement = t);
15423
15430
  }
15424
15431
  /**
15425
- *
15426
- * @param drawTree 绘制树
15427
- * @param dline 绘制行
15428
- */
15432
+ *
15433
+ * @param drawTree 绘制树
15434
+ * @param dline 绘制行
15435
+ */
15429
15436
  //根据可放置的宽度,将普通组件转换成绘制组件
15430
15437
  node2DrawNodeRange(t, r) {
15431
15438
  this._drawNodes.length = 0;
@@ -15453,12 +15460,12 @@ class SignNode extends BaseNode {
15453
15460
  this._drawNodes.push(l);
15454
15461
  }
15455
15462
  /**
15456
- * @author xyl
15457
- * @param dRoots 绘制根数组
15458
- * @param paragraphNode 对应的段落
15459
- * @param start 当前起始位置,绘制时不应含入
15460
- * @param endIndex 结束位置 ,包含入
15461
- */
15463
+ * @author xyl
15464
+ * @param dRoots 绘制根数组
15465
+ * @param paragraphNode 对应的段落
15466
+ * @param start 当前起始位置,绘制时不应含入
15467
+ * @param endIndex 结束位置 ,包含入
15468
+ */
15462
15469
  //根据可放置的宽度,将普通组件转换成绘制组件
15463
15470
  placeDNode2DrawLine(t, r, o, n, s) {
15464
15471
  if (n >= 1)
@@ -36698,7 +36705,7 @@ const columns$1 = [
36698
36705
  // }
36699
36706
  // },
36700
36707
  datePoperStyle() {
36701
- return this.dateTimeStyle.includes("yyyy") || this.dateTimeStyle.includes("MM") || this.dateTimeStyle.includes("dd") ? {
36708
+ return this.dateTimeStyle.includes("yyyy") || this.dateTimeStyle.includes("YYYY") || this.dateTimeStyle.includes("MM") || this.dateTimeStyle.includes("dd") ? {
36702
36709
  width: "100px",
36703
36710
  height: "0",
36704
36711
  border: "0"
@@ -36725,7 +36732,7 @@ const columns$1 = [
36725
36732
  if (t instanceof DateTimeNode) {
36726
36733
  this.notSelectTime = t.notSelectTime ? t.notSelectTime : !1, this.dateTimeStyle = t.controlStyle;
36727
36734
  let n = t.text;
36728
- (!n || n === t.name) && (n = moment$2().format(this.dateTimeStyle.replace(/dd/g, "DD"))), n = n.split(" "), this.date = n[0] ? n[0] : "", this.time = n[1] ? n[1] : "", !this.dateTimeStyle.includes("yyyy") && !this.dateTimeStyle.includes("MM") && !this.dateTimeStyle.includes("dd") && (this.time = n[0]);
36735
+ (!n || n === t.name) && (n = moment$2().format(this.dateTimeStyle.replace(/dd/g, "DD"))), n = n.split(" "), this.date = n[0] ? n[0] : "", this.time = n[1] ? n[1] : "", !this.dateTimeStyle.includes("yyyy") && !this.dateTimeStyle.includes("YYYY") && !this.dateTimeStyle.includes("MM") && !this.dateTimeStyle.includes("dd") && (this.time = n[0]);
36729
36736
  }
36730
36737
  } else {
36731
36738
  let n = [];
@@ -37078,7 +37085,7 @@ var _sfc_render$1g = function a() {
37078
37085
  return r("a-radio", { key: o.id + Math.random(), style: { display: "block", whiteSpace: "break-spaces", marginRight: "0px" }, attrs: { value: o.id }, nativeOn: { "~click": function(n) {
37079
37086
  return t.selectItemsChange(o);
37080
37087
  } } }, [t._v(" " + t._s(o.showText) + " ")]);
37081
- }), 1)]] : t._e()] : t._e(), t.selectedList.length > 0 && t.isAllowMultiSelect && !t.insCheckSyncUpdateList && !t.mutexSelect && t.isCanSearch ? r("transition-group", { staticClass: "list", attrs: { name: "drag", tag: "ul" } }, [r("li", { key: i18nHelper("04-001-009-EMR.3.3.515", null, "已选择"), staticStyle: { width: "270px", position: "absolute", top: "0px", "z-index": "111", background: "#fff" } }, [t._v(` ${i18nHelper("04-001-009-EMR.3.3.515", null, "已选择")}` + t._s(t.currentListNameText))]), t._l(t.selectedList, function(o, n) {
37088
+ }), 1)]] : t._e()] : t._e(), t.selectedList.length > 0 && t.isAllowMultiSelect && !t.insCheckSyncUpdateList && !t.mutexSelect && t.isCanSearch ? r("transition-group", { staticClass: "list", attrs: { name: "drag", tag: "ul" } }, [r("li", { key: i18nHelper("04-001-009-EMR.3.3.515", null, "已选择"), staticStyle: { width: "270px", position: "absolute", top: "0px", "z-index": "111", background: "#fff" } }, [t._v(i18nHelper("04-001-009-EMR.3.3.515", null, "已选择") + t._s(t.currentListNameText))]), t._l(t.selectedList, function(o, n) {
37082
37089
  return [r("li", { key: o.id + Math.random(), staticClass: "drag-item selected", attrs: { draggable: "" }, on: { dragenter: function(s) {
37083
37090
  return t.dragenter(s, n);
37084
37091
  }, dragover: function(s) {
@@ -37094,7 +37101,7 @@ var _sfc_render$1g = function a() {
37094
37101
  } } })], 1)];
37095
37102
  })], 2) : t._e()], 2)]) : t._e(), t.poperType === "selectPoper" && !t.isAllowMultiSelect ? r("footer", { staticClass: "select-poper-footer" }, [r("a-button", { on: { click: t.cancelSelectClose } }, [t._v(i18nHelper("04-001-009-EMR.3.3.533", null, "清空"))]), r("a-button", { on: { click: t.handleClose } }, [t._v(i18nHelper("04-001-009-EMR.3.3.348", null, "关闭"))])], 1) : t._e(), t.poperType === "selectPoper" && t.isAllowMultiSelect ? r("footer", { staticClass: "select-poper-footer" }, [t.mutexSelect ? t._e() : r("a-button", { on: { click: t.allSelect } }, [t._v(i18nHelper("04-001-009-EMR.3.3.201", null, "全选"))]), r("a-button", { on: { click: t.cancelSelect } }, [t._v(i18nHelper("04-001-009-EMR.3.3.533", null, "清空"))]), r("a-button", { on: { click: t.handleClose } }, [t._v(i18nHelper("04-001-009-EMR.3.3.346", null, "取消"))]), r("a-button", { attrs: { type: "primary" }, on: { click: function(o) {
37096
37103
  return t.sureSelect();
37097
- } } }, [t._v(i18nHelper("04-001-009-EMR.3.3.347", null, "确定"))])], 1) : t._e(), t.poperType === "datePoper" ? r("div", { staticClass: "date-poper", style: t.datePoperStyle }, [t.dateTimeStyle.includes("yyyy") || t.dateTimeStyle.includes("MM") || t.dateTimeStyle.includes("dd") ? r("a-date-picker", { ref: "datePicker", attrs: { size: "small", type: "datetime", placeholder: i18nHelper("04-001-009-EMR.3.3.69", null, "日期"), open: !0, locale: t.locale, showToday: !1, "disabled-date": t.disabledEndDate, format: t.dateTimeStyle.replace(/dd/g, "DD").split(" ")[0], valueFormat: t.dateTimeStyle.replace(/dd/g, "DD").split(" ")[0] }, scopedSlots: t._u([{ key: "dateRender", fn: function(o) {
37104
+ } } }, [t._v(i18nHelper("04-001-009-EMR.3.3.347", null, "确定"))])], 1) : t._e(), t.poperType === "datePoper" ? r("div", { staticClass: "date-poper", style: t.datePoperStyle }, [t.dateTimeStyle.includes("yyyy") || t.dateTimeStyle.includes("YYYY") || t.dateTimeStyle.includes("MM") || t.dateTimeStyle.includes("dd") ? r("a-date-picker", { ref: "datePicker", attrs: { size: "small", type: "datetime", placeholder: i18nHelper("04-001-009-EMR.3.3.69", null, "日期"), open: !0, locale: t.locale, showToday: !1, "disabled-date": t.disabledEndDate, format: t.dateTimeStyle.replace(/dd/g, "DD").split(" ")[0], valueFormat: t.dateTimeStyle.replace(/dd/g, "DD").split(" ")[0] }, scopedSlots: t._u([{ key: "dateRender", fn: function(o) {
37098
37105
  return [r("div", { staticClass: "ant-calendar-date", on: { dblclick: t.getTime } }, [t._v(" " + t._s(o.date()) + " ")])];
37099
37106
  } }], null, !1, 213485314), model: { value: t.date, callback: function(o) {
37100
37107
  t.date = o;
@@ -65128,7 +65135,7 @@ WebPDecoder.prototype.getData = function() {
65128
65135
  (function(a) {
65129
65136
  function t() {
65130
65137
  return function() {
65131
- return globalObject.canvg ? Promise.resolve(globalObject.canvg) : import("./index.es-BSKdXCkE.mjs");
65138
+ return globalObject.canvg ? Promise.resolve(globalObject.canvg) : import("./index.es-CZOQDDFF.mjs");
65132
65139
  }().catch(function(r) {
65133
65140
  return Promise.reject(new Error("Could not load canvg: " + r));
65134
65141
  }).then(function(r) {
@@ -66687,6 +66694,14 @@ class PrintController {
66687
66694
  value: 0
66688
66695
  };
66689
66696
  const y = async () => {
66697
+ var v;
66698
+ if (o != null && o.duplex && g.value > 0 && g.value % 2 !== 0) {
66699
+ if (s.isUseImagePrint) {
66700
+ const C = s.unitConvert.mmConversionPx(s.pageProperty.widthMm, !0), _ = s.unitConvert.mmConversionPx(s.pageProperty.heightMm, !0), D = C > _ ? "l" : "p";
66701
+ (v = this.PDF) == null || v.addPage([C, _], D);
66702
+ }
66703
+ g.value++;
66704
+ }
66690
66705
  o && p && Array.isArray(o.notPrintDocId) && o.notPrintDocId.length > 0 && o.notPrintDocId.includes(p) ? await Print.printAllNew(this._hoEditorFactoryID, w, this.PDF, f, !0, g) : await Print.printAllNew(this._hoEditorFactoryID, w, this.PDF, f, !1, g);
66691
66706
  }, w = async () => {
66692
66707
  var v, C;
@@ -75148,7 +75163,8 @@ const VerifyTip$1 = __component__$13.exports, _sfc_main$12 = {
75148
75163
  "value",
75149
75164
  "hideDuringPrint",
75150
75165
  "notReplaceElement",
75151
- "insCheckSyncUpdateList"
75166
+ "insCheckSyncUpdateList",
75167
+ "isTipText"
75152
75168
  ]
75153
75169
  };
75154
75170
  },
@@ -75213,9 +75229,11 @@ const VerifyTip$1 = __component__$13.exports, _sfc_main$12 = {
75213
75229
  methods: {
75214
75230
  setWatchProps() {
75215
75231
  this.watchProps.forEach((a) => {
75216
- this.unwatchProps.push(this.$watch(`textParam.${a}`, function(t, r) {
75217
- a === "readTypeBool" ? this.modifyProps.readType = t ? "1" : "0" : this.modifyProps[a] = t;
75218
- }));
75232
+ this.unwatchProps.push(
75233
+ this.$watch(`textParam.${a}`, function(t, r) {
75234
+ a === "readTypeBool" ? this.modifyProps.readType = t ? "1" : "0" : this.modifyProps[a] = t;
75235
+ })
75236
+ );
75219
75237
  });
75220
75238
  },
75221
75239
  clearWatchProps() {
@@ -75678,7 +75696,7 @@ var _sfc_render$$ = function a() {
75678
75696
  t.controlStyle = o;
75679
75697
  }, expression: "controlStyle" } }, t._l(t.dateFormatList, function(o) {
75680
75698
  return r("a-select-option", { key: o, attrs: { value: o } }, [t._v(t._s(o))]);
75681
- }), 1)], 1)]), r("li", { staticClass: "control-item" }, [r("span", { staticClass: "label" }, [t._v(i18nHelper("04-001-009-EMR.3.3.117", null, "日期时间"))]), t.controlStyle.includes("yyyy") || t.controlStyle.includes("MM") || t.controlStyle.includes("dd") ? r("a-date-picker", { attrs: { size: "small", type: "date", placeholder: i18nHelper("04-001-009-EMR.3.3.69", null, "日期"), locale: t.locale, showTime: t.controlStyle.includes("mm"), format: t.controlStyle.replace(/dd/g, "DD"), valueFormat: t.controlStyle.replace(/dd/g, "DD") }, model: { value: t.text, callback: function(o) {
75699
+ }), 1)], 1)]), r("li", { staticClass: "control-item" }, [r("span", { staticClass: "label" }, [t._v(i18nHelper("04-001-009-EMR.3.3.117", null, "日期时间"))]), t.controlStyle.includes("yyyy") || t.controlStyle.includes("YYYY") || t.controlStyle.includes("MM") || t.controlStyle.includes("dd") ? r("a-date-picker", { attrs: { size: "small", type: "date", placeholder: i18nHelper("04-001-009-EMR.3.3.69", null, "日期"), locale: t.locale, showTime: t.controlStyle.includes("mm"), format: t.controlStyle.replace(/dd/g, "DD"), valueFormat: t.controlStyle.replace(/dd/g, "DD") }, model: { value: t.text, callback: function(o) {
75682
75700
  t.text = o;
75683
75701
  }, expression: "text" } }) : r("a-time-picker", { attrs: { size: "small", type: "time", placeholder: i18nHelper("04-001-009-EMR.3.3.69", null, "日期"), locale: t.locale, format: t.controlStyle, valueFormat: t.controlStyle }, model: { value: t.text, callback: function(o) {
75684
75702
  t.text = o;
@@ -85262,7 +85280,7 @@ const HoMedicalExpression = __component__$j.exports, _sfc_main$i = defineCompone
85262
85280
  }
85263
85281
  },
85264
85282
  setup(a, { emit: t }) {
85265
- const r = ["yyyy/MM/dd", "yyyy/MM/dd HH:mm", "yyyy年MM月dd日", "yyyy年MM月dd日 HH时mm分", "yyyy-MM-dd", "yyyy-MM-dd HH:mm"], o = ref([]);
85283
+ const r = ["yyyy/MM/dd", "yyyy/MM/dd HH:mm", "yyyy年MM月dd日", "yyyy年MM月dd日 HH时mm分", "yyyy-MM-dd", "yyyy-MM-dd HH:mm", "YYYY/MM", "YYYY-MM", "YYYY年-MM月"], o = ref([]);
85266
85284
  inject("hoEditorProvider", {});
85267
85285
  const n = inject("setHoModal");
85268
85286
  return (() => {
@@ -1,4 +1,4 @@
1
- import { c as Da, _ as Va, g as il } from "./index-BwYkZrdT.mjs";
1
+ import { c as Da, _ as Va, g as il } from "./index-StM8bNN8.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.4-beta.2",
3
+ "version": "3.3.4",
4
4
  "private": false,
5
5
  "main": "lib/hoeditor.mjs",
6
6
  "typings": "types/index.d.ts",