@worm-print-platform/canvas 1.5.0 → 1.5.2

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.
Files changed (55) hide show
  1. package/README.md +112 -359
  2. package/dist/browser-bundle.d.ts +1 -1
  3. package/dist/canvas.css +1 -1
  4. package/dist/canvas.js +84 -81
  5. package/dist/core/default-template.d.ts +1 -1
  6. package/dist/core/element-definitions.d.ts +1 -1
  7. package/dist/core/format.d.ts +1 -1
  8. package/dist/core/h.d.ts +1 -1
  9. package/dist/core/icons.d.ts +1 -1
  10. package/dist/core/plugin.d.ts +1 -1
  11. package/dist/core/store.d.ts +1 -1
  12. package/dist/host-contract.d.ts +7 -3
  13. package/dist/index.cjs +14 -11
  14. package/dist/index.d.ts +1 -1
  15. package/dist/index.js +1289 -1242
  16. package/dist/print-designer.d.ts +7 -3
  17. package/dist/shell/binding.d.ts +1 -1
  18. package/dist/shell/canvas.d.ts +1 -1
  19. package/dist/shell/code.d.ts +1 -1
  20. package/dist/shell/color-picker.d.ts +1 -1
  21. package/dist/shell/controls.d.ts +4 -1
  22. package/dist/shell/crop-anchor.d.ts +1 -1
  23. package/dist/shell/elements.d.ts +1 -1
  24. package/dist/shell/expression-editor.d.ts +1 -1
  25. package/dist/shell/flow-list.d.ts +1 -1
  26. package/dist/shell/font-select.d.ts +1 -1
  27. package/dist/shell/format-bar.d.ts +1 -1
  28. package/dist/shell/help-content/advanced-settings.d.ts +1 -1
  29. package/dist/shell/help-content/changelog.d.ts +1 -1
  30. package/dist/shell/help-content/faq.d.ts +1 -1
  31. package/dist/shell/help-content/features.d.ts +1 -1
  32. package/dist/shell/help-content/getting-started.d.ts +1 -1
  33. package/dist/shell/help-content/index.d.ts +1 -1
  34. package/dist/shell/help-content/shortcuts.d.ts +1 -1
  35. package/dist/shell/help-modal.d.ts +1 -1
  36. package/dist/shell/page-extras.d.ts +1 -1
  37. package/dist/shell/panels.d.ts +1 -1
  38. package/dist/shell/plugin-ui.d.ts +1 -1
  39. package/dist/shell/prop-group.d.ts +1 -1
  40. package/dist/shell/property-panel.d.ts +1 -1
  41. package/dist/shell/property-search.d.ts +1 -1
  42. package/dist/shell/ruler.d.ts +1 -1
  43. package/dist/shell/table-props.d.ts +1 -1
  44. package/dist/shell/table.d.ts +2 -2
  45. package/dist/shell/toolbar-overflow.d.ts +1 -1
  46. package/dist/shell/toolbar.d.ts +1 -1
  47. package/dist/shell/watermark.d.ts +1 -1
  48. package/dist/vue3/PrintDesigner.d.ts +23 -1
  49. package/dist/vue3/PrintHtmlPreview.d.ts +1 -1
  50. package/dist/vue3/index.cjs +2 -2
  51. package/dist/vue3/index.d.ts +1 -1
  52. package/dist/vue3/index.js +121 -111
  53. package/dist/vue3/previewStyle.d.ts +1 -1
  54. package/dist/vue3/toolbarOverflow.d.ts +1 -1
  55. package/package.json +4 -4
@@ -1,11 +1,11 @@
1
- import { defineComponent as L, ref as h, onMounted as B, onBeforeUnmount as H, watch as y, h as g, computed as D, shallowRef as C, reactive as F, onUnmounted as _, provide as j, inject as V, nextTick as W } from "vue";
1
+ import { defineComponent as B, ref as y, onMounted as L, onBeforeUnmount as H, watch as w, h as g, computed as D, shallowRef as C, reactive as F, onUnmounted as _, provide as j, inject as V, nextTick as U } from "vue";
2
2
  import { definePrintDesigner as Z } from "@worm-print-platform/canvas";
3
- import { createDefaultTemplate as Re, toRuntimePool as ke } from "@worm-print-platform/canvas";
3
+ import { createDefaultTemplate as Pe, toRuntimePool as Re } from "@worm-print-platform/canvas";
4
4
  import { collectLayoutWarnings as G } from "@worm-print-platform/core";
5
5
  import { renderHtmlPages as K, browserCodeRenderer as N } from "@worm-print-platform/core/browser";
6
- import { browserCodeRenderer as Ie, renderHtmlPages as Ue } from "@worm-print-platform/core/browser";
6
+ import { browserCodeRenderer as Se, renderHtmlPages as Ie } from "@worm-print-platform/core/browser";
7
7
  import { resolvePrinterDpi as $, zoomPresets as q, paperWidthPx as Y, defaultZoomKey as Q, zoomValueOf as X, viewZoomHint as ee, applyPreviewViewZoom as te, resolveZoomKey as ne, resolveToolbarOverflow as oe } from "@worm-print-platform/core/designer";
8
- import { DEFAULT_DEMO_DATA as Ae, getDemoData as Se } from "@worm-print-platform/core/designer";
8
+ import { DEFAULT_DEMO_DATA as We, getDemoData as Ae } from "@worm-print-platform/core/designer";
9
9
  import { TOOLBAR_OVERFLOW_KEY as ie } from "@worm-print-platform/plugin-kit";
10
10
  function re(e, a) {
11
11
  const v = a.map((s) => ({
@@ -18,7 +18,7 @@ function re(e, a) {
18
18
  pages: i.map((s, r) => r === 0 ? { ...s, elements: v } : s)
19
19
  } : { ...e, elements: v };
20
20
  }
21
- const ae = L({
21
+ const ae = B({
22
22
  name: "PrintDesigner",
23
23
  props: {
24
24
  initialTemplate: {
@@ -46,6 +46,10 @@ const ae = L({
46
46
  },
47
47
  /** 是否展示帮助入口;不传时保持元素默认(展示) */
48
48
  showHelp: { type: Boolean, default: void 0 },
49
+ /** 是否展示工具栏「预览」按钮;不传时保持元素默认(展示) */
50
+ showPreview: { type: Boolean, default: void 0 },
51
+ /** 是否展示工具栏「保存」按钮;不传时保持元素默认(展示) */
52
+ showSave: { type: Boolean, default: void 0 },
49
53
  /** 模板级字体声明,保存 / 导出时写入模板 JSON */
50
54
  fonts: {
51
55
  type: Array,
@@ -62,7 +66,7 @@ const ae = L({
62
66
  save: (e) => typeof e == "string"
63
67
  },
64
68
  setup(e, { emit: a, expose: v }) {
65
- const i = h(null);
69
+ const i = y(null);
66
70
  let s = null, r = null;
67
71
  typeof customElements < "u" && Z();
68
72
  function c(t) {
@@ -71,46 +75,52 @@ const ae = L({
71
75
  return;
72
76
  }
73
77
  if (e.initialElements === void 0) return;
74
- const o = t.getTemplateJson(), p = JSON.parse(o);
75
- t.template = re(p, e.initialElements);
78
+ const n = t.getTemplateJson(), f = JSON.parse(n);
79
+ t.template = re(f, e.initialElements);
76
80
  }
77
81
  function x() {
78
82
  const t = i.value;
79
- t && (c(t), e.fields !== void 0 && (t.fields = e.fields), e.fonts !== void 0 && (t.fonts = e.fonts), e.designData !== void 0 && (t.designData = e.designData), t.uploadImage = e.uploadImage, t.uploadDesignBackground = e.uploadDesignBackground, e.isEdit !== void 0 && (t.isEdit = e.isEdit), e.showHelp !== void 0 && (t.showHelp = e.showHelp));
83
+ t && (c(t), e.fields !== void 0 && (t.fields = e.fields), e.fonts !== void 0 && (t.fonts = e.fonts), e.designData !== void 0 && (t.designData = e.designData), t.uploadImage = e.uploadImage, t.uploadDesignBackground = e.uploadDesignBackground, e.isEdit !== void 0 && (t.isEdit = e.isEdit), e.showHelp !== void 0 && (t.showHelp = e.showHelp), e.showPreview !== void 0 && (t.showPreview = e.showPreview), e.showSave !== void 0 && (t.showSave = e.showSave));
80
84
  }
81
- return B(() => {
85
+ return L(() => {
82
86
  const t = i.value;
83
- t && (s = (o) => a("save", o.detail), r = () => a("preview"), t.addEventListener("save", s), t.addEventListener("preview", r), x());
87
+ t && (s = (n) => a("save", n.detail), r = () => a("preview"), t.addEventListener("save", s), t.addEventListener("preview", r), x());
84
88
  }), H(() => {
85
89
  const t = i.value;
86
90
  s && t?.removeEventListener("save", s), r && t?.removeEventListener("preview", r), s = null, r = null;
87
- }), y(() => e.initialTemplate, () => {
91
+ }), w(() => e.initialTemplate, () => {
88
92
  const t = i.value;
89
93
  t && c(t);
90
- }), y(() => e.initialElements, () => {
94
+ }), w(() => e.initialElements, () => {
91
95
  const t = i.value;
92
96
  t && c(t);
93
- }), y(() => e.fields, (t) => {
94
- const o = i.value;
95
- o && (o.fields = t ?? []);
96
- }), y(() => e.fonts, (t) => {
97
- const o = i.value;
98
- o && (o.fonts = t);
99
- }), y(() => e.designData, (t) => {
100
- const o = i.value;
101
- o && (o.designData = t);
102
- }), y(() => e.uploadImage, (t) => {
103
- const o = i.value;
104
- o && (o.uploadImage = t);
105
- }), y(() => e.uploadDesignBackground, (t) => {
106
- const o = i.value;
107
- o && (o.uploadDesignBackground = t);
108
- }), y(() => e.isEdit, (t) => {
109
- const o = i.value;
110
- o && t !== void 0 && (o.isEdit = t);
111
- }), y(() => e.showHelp, (t) => {
112
- const o = i.value;
113
- o && t !== void 0 && (o.showHelp = t);
97
+ }), w(() => e.fields, (t) => {
98
+ const n = i.value;
99
+ n && (n.fields = t ?? []);
100
+ }), w(() => e.fonts, (t) => {
101
+ const n = i.value;
102
+ n && (n.fonts = t);
103
+ }), w(() => e.designData, (t) => {
104
+ const n = i.value;
105
+ n && (n.designData = t);
106
+ }), w(() => e.uploadImage, (t) => {
107
+ const n = i.value;
108
+ n && (n.uploadImage = t);
109
+ }), w(() => e.uploadDesignBackground, (t) => {
110
+ const n = i.value;
111
+ n && (n.uploadDesignBackground = t);
112
+ }), w(() => e.isEdit, (t) => {
113
+ const n = i.value;
114
+ n && t !== void 0 && (n.isEdit = t);
115
+ }), w(() => e.showHelp, (t) => {
116
+ const n = i.value;
117
+ n && t !== void 0 && (n.showHelp = t);
118
+ }), w(() => e.showPreview, (t) => {
119
+ const n = i.value;
120
+ n && t !== void 0 && (n.showPreview = t);
121
+ }), w(() => e.showSave, (t) => {
122
+ const n = i.value;
123
+ n && t !== void 0 && (n.showSave = t);
114
124
  }), v({
115
125
  getTemplateJson() {
116
126
  const t = i.value?.getTemplateJson();
@@ -124,7 +134,7 @@ const ae = L({
124
134
  }
125
135
  }), () => g("print-designer", { ref: i });
126
136
  }
127
- }), he = ae, S = "worm-print-canvas-vue3-preview", le = `
137
+ }), ge = ae, A = "worm-print-canvas-vue3-preview", le = `
128
138
  .pcv3-preview.print-html-preview {
129
139
  width: 100%;
130
140
  height: 100%;
@@ -207,11 +217,11 @@ const ae = L({
207
217
  }
208
218
  `;
209
219
  function se() {
210
- if (typeof document > "u" || document.getElementById(S)) return;
220
+ if (typeof document > "u" || document.getElementById(A)) return;
211
221
  const e = document.createElement("style");
212
- e.id = S, e.textContent = le, document.head.appendChild(e);
222
+ e.id = A, e.textContent = le, document.head.appendChild(e);
213
223
  }
214
- const ue = L({
224
+ const ue = B({
215
225
  name: "PrintHtmlPreview",
216
226
  props: {
217
227
  /** 模板 JSON(设计器 TemplateData 结构兼容) */
@@ -239,24 +249,24 @@ const ue = L({
239
249
  error: (e) => typeof e == "string"
240
250
  },
241
251
  setup(e, { emit: a, expose: v }) {
242
- const i = h(), s = h(), r = h(!1), c = h(""), x = h([]);
252
+ const i = y(), s = y(), r = y(!1), c = y(""), x = y([]);
243
253
  let E = 0;
244
- const t = D(() => $(e.templateJson)), o = h(0), p = D(
245
- () => q(t.value, o.value, Y(e.templateJson))
246
- ), f = h(Q(t.value)), P = D(() => X(p.value, f.value)), T = D(() => ee(t.value, f.value));
254
+ const t = D(() => $(e.templateJson)), n = y(0), f = D(
255
+ () => q(t.value, n.value, Y(e.templateJson))
256
+ ), p = y(Q(t.value)), k = D(() => X(f.value, p.value)), T = D(() => ee(t.value, p.value));
247
257
  function O() {
248
- o.value = s.value?.clientWidth ?? 0;
258
+ n.value = s.value?.clientWidth ?? 0;
249
259
  }
250
- function I() {
251
- f.value = ne(p.value, f.value, t.value);
260
+ function S() {
261
+ p.value = ne(f.value, p.value, t.value);
252
262
  }
253
- function R() {
254
- te(i.value?.contentWindow?.document, P.value);
263
+ function P() {
264
+ te(i.value?.contentWindow?.document, k.value);
255
265
  }
256
- function U() {
257
- O(), R();
266
+ function I() {
267
+ O(), P();
258
268
  }
259
- async function n() {
269
+ async function o() {
260
270
  if (!e.templateJson) {
261
271
  c.value = "", r.value = !1;
262
272
  return;
@@ -264,7 +274,7 @@ const ue = L({
264
274
  const l = ++E;
265
275
  r.value = !0, c.value = "", x.value = [];
266
276
  try {
267
- const { html: u, pageCount: b, copies: d, pageLayouts: k } = await K(
277
+ const { html: u, pageCount: b, copies: d, pageLayouts: R } = await K(
268
278
  e.templateJson,
269
279
  e.printData,
270
280
  e.baseUrl,
@@ -272,9 +282,9 @@ const ue = L({
272
282
  { fontBaseUrl: e.fontBaseUrl, renderers: e.renderers }
273
283
  );
274
284
  if (l !== E) return;
275
- x.value = G(k ?? []);
276
- const w = i.value?.contentWindow?.document;
277
- w && (w.open(), w.write(u), w.close()), O(), I(), R(), a("rendered", b, d);
285
+ x.value = G(R ?? []);
286
+ const h = i.value?.contentWindow?.document;
287
+ h && (h.open(), h.write(u), h.close()), O(), S(), P(), a("rendered", b, d);
278
288
  } catch (u) {
279
289
  if (l !== E) return;
280
290
  c.value = u instanceof Error ? u.message : "未知错误", a("error", c.value);
@@ -287,19 +297,19 @@ const ue = L({
287
297
  l && (l.focus(), l.print());
288
298
  }
289
299
  function z(l) {
290
- p.value.some((u) => u.key === l) && (f.value = l);
300
+ f.value.some((u) => u.key === l) && (p.value = l);
291
301
  }
292
- return y(
302
+ return w(
293
303
  () => [e.templateJson, e.printData, e.baseUrl, e.fontBaseUrl, e.renderers],
294
304
  () => {
295
- n();
305
+ o();
296
306
  },
297
307
  { deep: !0 }
298
- ), y(P, () => R()), B(() => {
299
- se(), O(), I(), window.addEventListener("resize", U), n();
308
+ ), w(k, () => P()), L(() => {
309
+ se(), O(), S(), window.addEventListener("resize", I), o();
300
310
  }), H(() => {
301
- E++, window.removeEventListener("resize", U);
302
- }), v({ print: m, rerender: n, setViewZoom: z, zoomKey: f, presets: p, viewHint: T }), () => {
311
+ E++, window.removeEventListener("resize", I);
312
+ }), v({ print: m, rerender: o, setViewZoom: z, zoomKey: p, presets: f, viewHint: T }), () => {
303
313
  const l = r.value || !!c.value, u = [];
304
314
  if (c.value ? u.push(g("div", { key: "error", class: "print-html-preview-error" }, [
305
315
  g("span", null, `预览渲染失败:${c.value}`)
@@ -312,16 +322,16 @@ const ue = L({
312
322
  })), x.value.length && !l && u.push(g("div", { key: "warn", class: "print-html-preview-warn", role: "status" }, [
313
323
  g("span", null, `出纸提示:${x.value.join(";")}`)
314
324
  ])), e.templateJson && !l) {
315
- const b = p.value.map((d) => g("button", {
325
+ const b = f.value.map((d) => g("button", {
316
326
  key: d.key,
317
327
  type: "button",
318
328
  class: {
319
329
  "print-html-preview-zoom-btn": !0,
320
- active: d.key === f.value
330
+ active: d.key === p.value
321
331
  },
322
332
  title: d.tip,
323
333
  onClick: () => {
324
- f.value = d.key;
334
+ p.value = d.key;
325
335
  }
326
336
  }, d.label));
327
337
  T.value && b.push(g("span", { class: "print-html-preview-zoom-hint" }, T.value)), b.push(g("span", { class: "print-html-preview-zoom-note" }, "仅屏幕缩放,打印不受影响")), u.push(g("div", { key: "zoom", class: "print-html-preview-zoom" }, b));
@@ -336,73 +346,73 @@ const ue = L({
336
346
  function be(e) {
337
347
  return `tb-more-slot-${e}`;
338
348
  }
339
- const J = ie, A = 2, de = 74;
349
+ const J = ie, W = 2, de = 74;
340
350
  function ve() {
341
351
  const e = C(null), a = /* @__PURE__ */ new Map(), v = F(/* @__PURE__ */ new Map()), i = /* @__PURE__ */ new Map();
342
352
  let s = 0;
343
- const r = h(/* @__PURE__ */ new Set()), c = h(!1), x = D(() => [...v.values()].sort((n, m) => n.order - m.order)), E = D(() => r.value.size > 0);
353
+ const r = y(/* @__PURE__ */ new Set()), c = y(!1), x = D(() => [...v.values()].sort((o, m) => o.order - m.order)), E = D(() => r.value.size > 0);
344
354
  function t() {
345
- for (const [n, m] of a) {
355
+ for (const [o, m] of a) {
346
356
  const z = m.offsetWidth;
347
- z > 0 && i.set(n, z);
357
+ z > 0 && i.set(o, z);
348
358
  }
349
359
  }
350
- function o(n) {
351
- const m = getComputedStyle(n), z = Number.parseFloat(m.gap) || A, l = Number.parseFloat(m.paddingLeft) || 0, u = Number.parseFloat(m.paddingRight) || 0;
360
+ function n(o) {
361
+ const m = getComputedStyle(o), z = Number.parseFloat(m.gap) || W, l = Number.parseFloat(m.paddingLeft) || 0, u = Number.parseFloat(m.paddingRight) || 0;
352
362
  let b = 0;
353
- for (const d of Array.from(n.children)) {
363
+ for (const d of Array.from(o.children)) {
354
364
  if (d.hasAttribute("data-overflow-more") || d.hasAttribute("data-overflow-spacer")) continue;
355
- const k = Math.max(d.offsetWidth, d.scrollWidth);
356
- k <= 0 || (b += k + z);
365
+ const R = Math.max(d.offsetWidth, d.scrollWidth);
366
+ R <= 0 || (b += R + z);
357
367
  }
358
- return { available: n.clientWidth - l - u, natural: b };
368
+ return { available: o.clientWidth - l - u, natural: b };
359
369
  }
360
- function p() {
361
- const n = e.value;
362
- if (!n) return;
363
- const { available: m, natural: z } = o(n), l = r.value.size > 0;
370
+ function f() {
371
+ const o = e.value;
372
+ if (!o) return;
373
+ const { available: m, natural: z } = n(o), l = r.value.size > 0;
364
374
  l || (s = z, t());
365
- const u = x.value.map((w) => ({
366
- id: w.id,
367
- order: w.order,
368
- width: i.get(w.id) ?? 0
369
- })), b = u.reduce((w, M) => w - M.width - A, s), d = oe({
375
+ const u = x.value.map((h) => ({
376
+ id: h.id,
377
+ order: h.order,
378
+ width: i.get(h.id) ?? 0
379
+ })), b = u.reduce((h, M) => h - M.width - W, s), d = oe({
370
380
  available: m,
371
381
  pinned: b,
372
382
  moreTriggerWidth: de,
373
- gap: A,
383
+ gap: W,
374
384
  units: u
375
385
  });
376
- d.movedIds.length === r.value.size && d.movedIds.every((w) => r.value.has(w)) || (r.value = new Set(d.movedIds)), c.value = d.overflowRemains, l && r.value.size === 0 && W(p);
386
+ d.movedIds.length === r.value.size && d.movedIds.every((h) => r.value.has(h)) || (r.value = new Set(d.movedIds)), c.value = d.overflowRemains, l && r.value.size === 0 && U(f);
377
387
  }
378
- let f = null;
379
- function P(n) {
380
- n !== e.value && (f?.disconnect(), e.value = n, n && typeof ResizeObserver < "u" && (f = new ResizeObserver(() => p()), f.observe(n)), W(p));
388
+ let p = null;
389
+ function k(o) {
390
+ o !== e.value && (p?.disconnect(), e.value = o, o && typeof ResizeObserver < "u" && (p = new ResizeObserver(() => f()), p.observe(o)), U(f));
381
391
  }
382
- function T(n, m) {
383
- v.set(n.id, n), a.set(n.id, m), W(p);
392
+ function T(o, m) {
393
+ v.set(o.id, o), a.set(o.id, m), U(f);
384
394
  }
385
- function O(n) {
386
- a.delete(n), v.delete(n), i.delete(n), W(p);
395
+ function O(o) {
396
+ a.delete(o), v.delete(o), i.delete(o), U(f);
387
397
  }
388
- const I = document.createElement("div");
389
- function R(n) {
390
- return r.value.has(n);
398
+ const S = document.createElement("div");
399
+ function P(o) {
400
+ return r.value.has(o);
391
401
  }
392
- function U(n) {
393
- return r.value, e.value?.querySelector(`[data-overflow-slot="${n}"]`) ?? I;
402
+ function I(o) {
403
+ return r.value, e.value?.querySelector(`[data-overflow-slot="${o}"]`) ?? S;
394
404
  }
395
- return _(() => f?.disconnect()), {
396
- attachRoot: P,
405
+ return _(() => p?.disconnect()), {
406
+ attachRoot: k,
397
407
  registerUnit: T,
398
408
  unregisterUnit: O,
399
- refresh: p,
409
+ refresh: f,
400
410
  movedIds: r,
401
411
  overflowRemains: c,
402
412
  hasMoved: E,
403
413
  chain: x,
404
- moved: R,
405
- slotEl: U
414
+ moved: P,
415
+ slotEl: I
406
416
  };
407
417
  }
408
418
  function xe() {
@@ -413,7 +423,7 @@ function Ee() {
413
423
  return V(J, null);
414
424
  }
415
425
  function ze() {
416
- const e = h(/* @__PURE__ */ new Set()), a = document.createElement("div");
426
+ const e = y(/* @__PURE__ */ new Set()), a = document.createElement("div");
417
427
  return {
418
428
  attachRoot: () => {
419
429
  },
@@ -424,7 +434,7 @@ function ze() {
424
434
  refresh: () => {
425
435
  },
426
436
  movedIds: e,
427
- overflowRemains: h(!1),
437
+ overflowRemains: y(!1),
428
438
  hasMoved: D(() => !1),
429
439
  chain: D(() => []),
430
440
  moved: () => !1,
@@ -442,19 +452,19 @@ function De(e) {
442
452
  };
443
453
  }
444
454
  export {
445
- Ae as DEFAULT_DEMO_DATA,
446
- he as PrintDesigner,
455
+ We as DEFAULT_DEMO_DATA,
456
+ ge as PrintDesigner,
447
457
  ye as PrintHtmlPreview,
448
458
  J as TOOLBAR_OVERFLOW,
449
- Ie as browserCodeRenderer,
450
- Re as createDefaultTemplate,
459
+ Se as browserCodeRenderer,
460
+ Pe as createDefaultTemplate,
451
461
  De as createOverflowUnitDirective,
452
462
  ve as createToolbarOverflow,
453
463
  ze as emptyToolbarOverflow,
454
- Se as getDemoData,
464
+ Ae as getDemoData,
455
465
  be as moreSlotId,
456
466
  xe as provideToolbarOverflow,
457
- Ue as renderHtmlPages,
458
- ke as toRuntimePool,
467
+ Ie as renderHtmlPages,
468
+ Re as toRuntimePool,
459
469
  Ee as useToolbarOverflow
460
470
  };
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @worm-print-platform/canvas v1.5.0
2
+ * @worm-print-platform/canvas v1.5.2
3
3
  * Copyright (c) 2026 worm <liu_long_qqcom@qq.com>
4
4
  * SPDX-FileCopyrightText: 2026 worm <liu_long_qqcom@qq.com>
5
5
  * SPDX-License-Identifier: MIT
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @worm-print-platform/canvas v1.5.0
2
+ * @worm-print-platform/canvas v1.5.2
3
3
  * Copyright (c) 2026 worm <liu_long_qqcom@qq.com>
4
4
  * SPDX-FileCopyrightText: 2026 worm <liu_long_qqcom@qq.com>
5
5
  * SPDX-License-Identifier: MIT
package/package.json CHANGED
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "@worm-print-platform/canvas",
3
- "version": "1.5.0",
3
+ "version": "1.5.2",
4
4
  "publishConfig": {
5
5
  "access": "public",
6
6
  "registry": "https://registry.npmjs.org"
7
7
  },
8
8
  "type": "module",
9
- "description": "【实验性,不建议用于生产】打印模板设计器的通用宿主适配包:主入口为零框架原生 Custom Elements + Shadow DOM,零 Vue/React 依赖,直接消费 @worm-print-platform/core;/vue3 子路径为原本消费 @worm-vue3-print/canvas 的 Vue 3 宿主提供兼容门面(vue 为可选 peer)",
9
+ "description": "打印模板设计器权威实现:零框架原生 Custom Elements + Shadow DOM(vue 为可选 peer,/vue3 子路径提供 Vue 3 门面)",
10
10
  "main": "./dist/index.cjs",
11
11
  "module": "./dist/index.js",
12
12
  "types": "./dist/index.d.ts",
@@ -54,8 +54,8 @@
54
54
  "pretest": "npm run typecheck"
55
55
  },
56
56
  "dependencies": {
57
- "@worm-print-platform/core": "^1.5.0",
58
- "@worm-print-platform/plugin-kit": "^1.5.0",
57
+ "@worm-print-platform/core": "^1.5.2",
58
+ "@worm-print-platform/plugin-kit": "^1.5.2",
59
59
  "dompurify": "^3.4.12",
60
60
  "jsbarcode": "^3.12.3",
61
61
  "qrcode": "^1.5.4"