@univerjs/slides 0.1.7 → 0.1.8

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/es/index.js CHANGED
@@ -1,15 +1,15 @@
1
- var De = Object.defineProperty;
2
- var Ce = (a, e, r) => e in a ? De(a, e, { enumerable: !0, configurable: !0, writable: !0, value: r }) : a[e] = r;
3
- var u = (a, e, r) => (Ce(a, typeof e != "symbol" ? e + "" : e, r), r);
4
- import { Registry as Re, LocaleService as te, PageElementType as Y, DocumentDataModel as je, getColorStyle as Q, ShapeType as _e, SlideDataModel as Me, IContextService as Ee, ObjectMatrix as ze, Styles as Xe, Worksheet as Ae, sortRules as Le, OnLifecycle as Ue, LifecycleStages as Ne, RxDisposable as Ve, debounce as We, IUniverInstanceService as be, Plugin as $e, PluginType as He } from "@univerjs/core";
5
- import { Liquid as Ye, DocumentViewModel as Fe, DocumentSkeleton as Be, Documents as Ke, SceneViewer as me, Scene as re, Viewport as L, EVENT_TYPE as ge, ScrollBar as ue, Rect as H, Picture as Ie, PageLayoutType as fe, RichText as ke, Slide as Te, SpreadsheetSkeleton as qe, Spreadsheet as Ge, SpreadsheetRowHeader as Ze, SpreadsheetColumnHeader as Je, getColor as ve, IRenderManagerService as Qe, IRenderingEngine as et } from "@univerjs/engine-render";
6
- import { Inject as U, Injector as ne } from "@wendellhu/redi";
7
- import { takeUntil as we } from "rxjs";
1
+ var Ee = Object.defineProperty;
2
+ var xe = (a, e, r) => e in a ? Ee(a, e, { enumerable: !0, configurable: !0, writable: !0, value: r }) : a[e] = r;
3
+ var p = (a, e, r) => (xe(a, typeof e != "symbol" ? e + "" : e, r), r);
4
+ import { Registry as Ce, LocaleService as ne, PageElementType as F, DocumentDataModel as je, getColorStyle as te, ShapeType as fe, SlideDataModel as Me, IContextService as Le, ObjectMatrix as Ne, Styles as ze, Worksheet as Ve, sortRules as Xe, OnLifecycle as Ae, LifecycleStages as Ue, RxDisposable as We, UniverInstanceType as M, debounce as $e, IUniverInstanceService as be, Plugin as He } from "@univerjs/core";
5
+ import { Liquid as Ye, DocumentViewModel as Fe, DocumentSkeleton as Be, Documents as Ke, SceneViewer as me, Scene as ie, Viewport as X, EVENT_TYPE as pe, ScrollBar as ue, Rect as Y, Picture as Te, PageLayoutType as ve, RichText as ke, Slide as Oe, SpreadsheetSkeleton as qe, Spreadsheet as Ge, SpreadsheetRowHeader as Ze, SpreadsheetColumnHeader as Je, getColor as we, IRenderManagerService as Qe, IRenderingEngine as et } from "@univerjs/engine-render";
6
+ import { Inject as A, Injector as se } from "@wendellhu/redi";
7
+ import { takeUntil as Se } from "rxjs";
8
8
  const Yt = {}, tt = {};
9
- class F {
9
+ class B {
10
10
  constructor() {
11
- u(this, "zIndex", 0);
12
- u(this, "viewKey", null);
11
+ p(this, "zIndex", 0);
12
+ p(this, "viewKey", null);
13
13
  }
14
14
  check(e) {
15
15
  if (e === this.viewKey)
@@ -20,18 +20,18 @@ class F {
20
20
  create(e) {
21
21
  }
22
22
  }
23
- const W = Re.create();
23
+ const $ = Ce.create();
24
24
  var rt = Object.defineProperty, nt = Object.getOwnPropertyDescriptor, it = (a, e, r, n) => {
25
25
  for (var t = n > 1 ? void 0 : n ? nt(e, r) : e, s = a.length - 1, i; s >= 0; s--)
26
26
  (i = a[s]) && (t = (n ? i(e, r, t) : i(t)) || t);
27
27
  return n && t && rt(e, r, t), t;
28
28
  }, st = (a, e) => (r, n) => e(r, n, a);
29
- let oe = class extends F {
29
+ let le = class extends B {
30
30
  constructor(e) {
31
31
  super();
32
- u(this, "zIndex", 5);
33
- u(this, "viewKey", Y.DOCUMENT);
34
- u(this, "_liquid", new Ye());
32
+ p(this, "zIndex", 5);
33
+ p(this, "viewKey", F.DOCUMENT);
34
+ p(this, "_liquid", new Ye());
35
35
  this._localeService = e;
36
36
  }
37
37
  check(e) {
@@ -39,7 +39,7 @@ let oe = class extends F {
39
39
  return this;
40
40
  }
41
41
  convert(e, r) {
42
- var K, pe;
42
+ var k, _e;
43
43
  const {
44
44
  id: n,
45
45
  zIndex: t,
@@ -48,87 +48,87 @@ let oe = class extends F {
48
48
  width: c,
49
49
  height: o,
50
50
  angle: l,
51
- scaleX: p,
51
+ scaleX: u,
52
52
  scaleY: _,
53
53
  skewX: d,
54
54
  skewY: g,
55
55
  flipX: h,
56
56
  flipY: f,
57
- title: y,
58
- description: D,
57
+ title: R,
58
+ description: y,
59
59
  document: T
60
60
  } = e;
61
61
  if (T == null)
62
62
  return;
63
- const m = new je(T), w = new Fe(m), P = Be.create(w, this._localeService), S = new Ke("__DocsRender__", P);
64
- P.calculate();
65
- const x = new me("__DocsViewer__" + n, {
63
+ const b = new je(T), w = new Fe(b), I = Be.create(w, this._localeService), S = new Ke("__DocsRender__", I);
64
+ I.calculate();
65
+ const D = new me("__DocsViewer__" + n, {
66
66
  top: i,
67
67
  left: s,
68
68
  width: c,
69
69
  height: o,
70
70
  zIndex: t,
71
71
  angle: l,
72
- scaleX: p,
72
+ scaleX: u,
73
73
  scaleY: _,
74
74
  skewX: d,
75
75
  skewY: g,
76
76
  flipX: h,
77
77
  flipY: f,
78
78
  isTransformer: !0
79
- }), v = new re("__DocsScene__" + n, x), b = new L("__DocsViewPort_" + n, v, {
79
+ }), v = new ie("__DocsScene__" + n, D), P = new X("__DocsViewPort_" + n, v, {
80
80
  left: 0,
81
81
  top: 0,
82
82
  bottom: 0,
83
83
  right: 0,
84
84
  isWheelPreventDefaultX: !0
85
85
  });
86
- v.attachControl(), v.on(ge.wheel, (z, V) => {
87
- const O = z;
86
+ v.attachControl(), v.on(pe.wheel, (N, W) => {
87
+ const O = N;
88
88
  if (O.ctrlKey) {
89
- const X = Math.abs(O.deltaX);
90
- let R = X < 40 ? 0.2 : X < 80 ? 0.4 : 0.2;
91
- R *= O.deltaY > 0 ? -1 : 1, v.scaleX < 1 && (R /= 2), v.scaleX + R > 4 ? v.scale(4, 4) : v.scaleX + R < 0.1 ? v.scale(0.1, 0.1) : (O.deltaY > 0, O.preventDefault());
89
+ const z = Math.abs(O.deltaX);
90
+ let x = z < 40 ? 0.2 : z < 80 ? 0.4 : 0.2;
91
+ x *= O.deltaY > 0 ? -1 : 1, v.scaleX < 1 && (x /= 2), v.scaleX + x > 4 ? v.scale(4, 4) : v.scaleX + x < 0.1 ? v.scale(0.1, 0.1) : (O.deltaY > 0, O.preventDefault());
92
92
  } else
93
- b.onMouseWheel(O, V);
94
- }), new ue(b, {
93
+ P.onMouseWheel(O, W);
94
+ }), new ue(P, {
95
95
  mainScene: r
96
96
  }), v.addObject(S);
97
- const I = P.getActualSize();
98
- S.resize(I.actualWidth, I.actualHeight), v.resize(I.actualWidth, I.actualHeight + 200);
99
- const C = (K = S.getSkeleton()) == null ? void 0 : K.getPageSize();
100
- S.onPageRenderObservable.add((z) => {
101
- const { page: V, pageLeft: O, pageTop: X, ctx: R } = z, { width: k, height: q, marginBottom: ie, marginLeft: M, marginRight: G, marginTop: Z } = V;
102
- R.save(), R.translate(O - 0.5, X - 0.5), H.drawWith(R, {
103
- width: (C == null ? void 0 : C.width) || k,
104
- height: (C == null ? void 0 : C.height) || q,
97
+ const m = I.getActualSize();
98
+ S.resize(m.actualWidth, m.actualHeight), v.resize(m.actualWidth, m.actualHeight + 200);
99
+ const E = (k = S.getSkeleton()) == null ? void 0 : k.getPageSize();
100
+ S.onPageRenderObservable.add((N) => {
101
+ const { page: W, pageLeft: O, pageTop: z, ctx: x } = N, { width: q, height: G, marginBottom: ae, marginLeft: j, marginRight: Z, marginTop: J } = W;
102
+ x.save(), x.translate(O - 0.5, z - 0.5), Y.drawWith(x, {
103
+ width: (E == null ? void 0 : E.width) || q,
104
+ height: (E == null ? void 0 : E.height) || G,
105
105
  strokeWidth: 1,
106
106
  stroke: "rgba(198,198,198, 1)",
107
107
  fill: "rgba(255,255,255, 1)",
108
108
  zIndex: 3
109
- }), R.restore();
109
+ }), x.restore();
110
110
  });
111
- const { left: $, top: N } = S, E = P.getSkeletonData();
112
- if (E == null)
111
+ const { left: H, top: U } = S, L = I.getSkeletonData();
112
+ if (L == null)
113
113
  return;
114
- const { pages: j } = E, A = [], B = /* @__PURE__ */ new Map();
115
- this._recalculateSizeBySkeleton(S, v, P);
116
- for (let z = 0, V = j.length; z < V; z++) {
117
- const O = j[z], { skeDrawings: X, marginLeft: R, marginTop: k, pageWidth: q, pageHeight: ie } = O;
118
- this._liquid.translatePagePadding(O), X.forEach((M) => {
119
- const { aLeft: G, aTop: Z, height: Oe, width: xe, drawingOrigin: Ut } = M, ye = new Ie(M.objectId, {
114
+ const { pages: C } = L, V = [], K = /* @__PURE__ */ new Map();
115
+ this._recalculateSizeBySkeleton(S, v, I);
116
+ for (let N = 0, W = C.length; N < W; N++) {
117
+ const O = C[N], { skeDrawings: z, marginLeft: x, marginTop: q, pageWidth: G, pageHeight: ae } = O;
118
+ this._liquid.translatePagePadding(O), z.forEach((j) => {
119
+ const { aLeft: Z, aTop: J, height: De, width: Re, drawingOrigin: Xt } = j, ye = new Te(j.objectId, {
120
120
  // url: objectTransform.imageProperties?.contentUrl || '',
121
- left: G + $ + this._liquid.x,
122
- top: Z + N + this._liquid.y,
123
- width: xe,
124
- height: Oe,
121
+ left: Z + H + this._liquid.x,
122
+ top: J + U + this._liquid.y,
123
+ width: Re,
124
+ height: De,
125
125
  zIndex: 11,
126
126
  isTransformer: !0
127
127
  });
128
- B.set(M.objectId, {
128
+ K.set(j.objectId, {
129
129
  marginLeft: this._liquid.x,
130
130
  marginTop: this._liquid.y
131
- }), A.push(ye);
131
+ }), V.push(ye);
132
132
  }), this._liquid.translatePage(
133
133
  O,
134
134
  S.pageLayoutType,
@@ -136,18 +136,18 @@ let oe = class extends F {
136
136
  S.pageMarginTop
137
137
  );
138
138
  }
139
- return v.openTransformer(), v.addObjects(A), (pe = v.getTransformer()) == null || pe.onChangingObservable.add((z) => {
140
- const { objects: V } = z;
141
- V.forEach((O) => {
142
- const { oKey: X, left: R, top: k, height: q, width: ie } = O, M = B.get(X), G = (M == null ? void 0 : M.marginLeft) || 0, Z = (M == null ? void 0 : M.marginTop) || 0;
143
- P == null || P.getViewModel().getDataModel().updateDrawing(X, {
144
- left: R - $ - G,
145
- top: k - N - Z,
146
- height: q,
147
- width: ie
139
+ return v.openTransformer(), v.addObjects(V), (_e = v.getTransformer()) == null || _e.onChangingObservable.add((N) => {
140
+ const { objects: W } = N;
141
+ W.forEach((O) => {
142
+ const { oKey: z, left: x, top: q, height: G, width: ae } = O, j = K.get(z), Z = (j == null ? void 0 : j.marginLeft) || 0, J = (j == null ? void 0 : j.marginTop) || 0;
143
+ I == null || I.getViewModel().getDataModel().updateDrawing(z, {
144
+ left: x - H - Z,
145
+ top: q - U - J,
146
+ height: G,
147
+ width: ae
148
148
  });
149
- }), P == null || P.calculate();
150
- }), v.closeTransformer(), this._calculatePagePosition(S, v, b), x;
149
+ }), I == null || I.calculate();
150
+ }), v.closeTransformer(), this._calculatePagePosition(S, v, P), D;
151
151
  }
152
152
  _recalculateSizeBySkeleton(e, r, n) {
153
153
  var c;
@@ -156,8 +156,8 @@ let oe = class extends F {
156
156
  return;
157
157
  let s = 0, i = 0;
158
158
  for (let o = 0, l = t.length; o < l; o++) {
159
- const p = t[o], { pageWidth: _, pageHeight: d } = p;
160
- e.pageLayoutType === fe.VERTICAL ? (i += d, i += e.pageMarginTop, o === l - 1 && (i += e.pageMarginTop), s = Math.max(s, _)) : e.pageLayoutType === fe.HORIZONTAL && (s += _, o !== l - 1 && (s += e.pageMarginLeft), i = Math.max(i, d));
159
+ const u = t[o], { pageWidth: _, pageHeight: d } = u;
160
+ e.pageLayoutType === ve.VERTICAL ? (i += d, i += e.pageMarginTop, o === l - 1 && (i += e.pageMarginTop), s = Math.max(s, _)) : e.pageLayoutType === ve.HORIZONTAL && (s += _, o !== l - 1 && (s += e.pageMarginLeft), i = Math.max(i, d));
161
161
  }
162
162
  e.resize(s, i), r.resize(s, i);
163
163
  }
@@ -165,34 +165,34 @@ let oe = class extends F {
165
165
  const s = r == null ? void 0 : r.getParent(), { width: i, height: c, pageMarginLeft: o, pageMarginTop: l } = e;
166
166
  if (s == null || i === Number.POSITIVE_INFINITY || c === Number.POSITIVE_INFINITY)
167
167
  return;
168
- const { width: p, height: _ } = s;
169
- let d = 0, g = 0, h = 0, f = 0, y = Number.POSITIVE_INFINITY;
170
- if (p > (i + o * 2) * t ? (d = p / 2 - i * t / 2, d /= t, h = (p - o * 2) / t, y = 0) : (d = o, h = i + o * 2, y = (h - p / t) / 2), _ > c ? (g = _ / 2 - c / 2, f = (_ - l * 2) / t) : (g = l, f = c + l * 2), r.resize(h, f + 200), e.translate(d, g), y !== Number.POSITIVE_INFINITY && n != null) {
171
- const D = n.getBarScroll(y, 0).x;
168
+ const { width: u, height: _ } = s;
169
+ let d = 0, g = 0, h = 0, f = 0, R = Number.POSITIVE_INFINITY;
170
+ if (u > (i + o * 2) * t ? (d = u / 2 - i * t / 2, d /= t, h = (u - o * 2) / t, R = 0) : (d = o, h = i + o * 2, R = (h - u / t) / 2), _ > c ? (g = _ / 2 - c / 2, f = (_ - l * 2) / t) : (g = l, f = c + l * 2), r.resize(h, f + 200), e.translate(d, g), R !== Number.POSITIVE_INFINITY && n != null) {
171
+ const y = n.getBarScroll(R, 0).x;
172
172
  n.scrollTo({
173
- x: D
173
+ x: y
174
174
  });
175
175
  }
176
176
  return this;
177
177
  }
178
178
  };
179
- oe = it([
180
- st(0, U(te))
181
- ], oe);
179
+ le = it([
180
+ st(0, A(ne))
181
+ ], le);
182
182
  class at {
183
183
  constructor() {
184
- u(this, "zIndex", 5);
184
+ p(this, "zIndex", 5);
185
185
  }
186
186
  create(e) {
187
- return e.createInstance(oe);
187
+ return e.createInstance(le);
188
188
  }
189
189
  }
190
- W.add(new at());
191
- class ct extends F {
190
+ $.add(new at());
191
+ class ct extends B {
192
192
  constructor() {
193
193
  super(...arguments);
194
- u(this, "zIndex", 1);
195
- u(this, "viewKey", Y.IMAGE);
194
+ p(this, "zIndex", 1);
195
+ p(this, "viewKey", F.IMAGE);
196
196
  }
197
197
  check(r) {
198
198
  if (r === this.viewKey)
@@ -207,17 +207,17 @@ class ct extends F {
207
207
  width: c,
208
208
  height: o,
209
209
  angle: l,
210
- scaleX: p,
210
+ scaleX: u,
211
211
  scaleY: _,
212
212
  skewX: d,
213
213
  skewY: g,
214
214
  flipX: h,
215
215
  flipY: f,
216
- title: y,
217
- description: D,
216
+ title: R,
217
+ description: y,
218
218
  image: T = {}
219
- } = r, { imageProperties: m, placeholder: w, link: P } = T, S = (m == null ? void 0 : m.contentUrl) || "";
220
- return new Ie(n, {
219
+ } = r, { imageProperties: b, placeholder: w, link: I } = T, S = (b == null ? void 0 : b.contentUrl) || "";
220
+ return new Te(n, {
221
221
  url: S,
222
222
  top: i,
223
223
  left: s,
@@ -225,7 +225,7 @@ class ct extends F {
225
225
  height: o,
226
226
  zIndex: t,
227
227
  angle: l,
228
- scaleX: p,
228
+ scaleX: u,
229
229
  scaleY: _,
230
230
  skewX: d,
231
231
  skewY: g,
@@ -238,23 +238,23 @@ class ct extends F {
238
238
  }
239
239
  class ot {
240
240
  constructor() {
241
- u(this, "zIndex", 4);
241
+ p(this, "zIndex", 4);
242
242
  }
243
243
  create(e) {
244
244
  return e.createInstance(ct);
245
245
  }
246
246
  }
247
- W.add(new ot());
247
+ $.add(new ot());
248
248
  var lt = Object.defineProperty, dt = Object.getOwnPropertyDescriptor, ht = (a, e, r, n) => {
249
249
  for (var t = n > 1 ? void 0 : n ? dt(e, r) : e, s = a.length - 1, i; s >= 0; s--)
250
250
  (i = a[s]) && (t = (n ? i(e, r, t) : i(t)) || t);
251
251
  return n && t && lt(e, r, t), t;
252
252
  }, gt = (a, e) => (r, n) => e(r, n, a);
253
- let le = class extends F {
253
+ let de = class extends B {
254
254
  constructor(e) {
255
255
  super();
256
- u(this, "zIndex", 2);
257
- u(this, "viewKey", Y.TEXT);
256
+ p(this, "zIndex", 2);
257
+ p(this, "viewKey", F.TEXT);
258
258
  this._localeService = e;
259
259
  }
260
260
  check(e) {
@@ -270,24 +270,24 @@ let le = class extends F {
270
270
  width: c,
271
271
  height: o,
272
272
  angle: l,
273
- scaleX: p,
273
+ scaleX: u,
274
274
  scaleY: _,
275
275
  skewX: d,
276
276
  skewY: g,
277
277
  flipX: h,
278
278
  flipY: f,
279
- title: y,
280
- description: D,
279
+ title: R,
280
+ description: y,
281
281
  richText: T = {}
282
- } = e, { text: m, ff: w, fs: P, it: S, bl: x, ul: v, st: b, ol: I, bg: C, bd: $, cl: N, rich: E } = T;
283
- let j = {
282
+ } = e, { text: b, ff: w, fs: I, it: S, bl: D, ul: v, st: P, ol: m, bg: E, bd: H, cl: U, rich: L } = T;
283
+ let C = {
284
284
  top: i,
285
285
  left: s,
286
286
  width: c,
287
287
  height: o,
288
288
  zIndex: t,
289
289
  angle: l,
290
- scaleX: p,
290
+ scaleX: u,
291
291
  scaleY: _,
292
292
  skewX: d,
293
293
  skewY: g,
@@ -295,28 +295,28 @@ let le = class extends F {
295
295
  flipY: f,
296
296
  isTransformer: !0,
297
297
  forceRender: !0
298
- }, A = !1;
299
- if (m != null ? (j = { ...j, text: m, ff: w, fs: P, it: S, bl: x, ul: v, st: b, ol: I, bg: C, bd: $, cl: N }, A = !0) : E != null && (j = { ...j, richText: E }, A = !0), A !== !1)
300
- return new ke(this._localeService, n, j);
298
+ }, V = !1;
299
+ if (b != null ? (C = { ...C, text: b, ff: w, fs: I, it: S, bl: D, ul: v, st: P, ol: m, bg: E, bd: H, cl: U }, V = !0) : L != null && (C = { ...C, richText: L }, V = !0), V !== !1)
300
+ return new ke(this._localeService, n, C);
301
301
  }
302
302
  };
303
- le = ht([
304
- gt(0, U(te))
305
- ], le);
306
- class ut {
303
+ de = ht([
304
+ gt(0, A(ne))
305
+ ], de);
306
+ class pt {
307
307
  constructor() {
308
- u(this, "zIndex", 0);
308
+ p(this, "zIndex", 0);
309
309
  }
310
310
  create(e) {
311
- return e.createInstance(le);
311
+ return e.createInstance(de);
312
312
  }
313
313
  }
314
- W.add(new ut());
315
- class pt extends F {
314
+ $.add(new pt());
315
+ class ut extends B {
316
316
  constructor() {
317
317
  super(...arguments);
318
- u(this, "zIndex", 2);
319
- u(this, "viewKey", Y.SHAPE);
318
+ p(this, "zIndex", 2);
319
+ p(this, "viewKey", F.SHAPE);
320
320
  }
321
321
  check(r) {
322
322
  if (r === this.viewKey)
@@ -331,29 +331,29 @@ class pt extends F {
331
331
  width: c,
332
332
  height: o,
333
333
  angle: l,
334
- scaleX: p,
334
+ scaleX: u,
335
335
  scaleY: _,
336
336
  skewX: d,
337
337
  skewY: g,
338
338
  flipX: h,
339
339
  flipY: f,
340
- title: y,
341
- description: D
342
- } = r, { shapeType: T, text: m, shapeProperties: w, placeholder: P, link: S } = r.shape || {}, x = w == null ? "" : Q(w.shapeBackgroundFill) || "rgba(255,255,255,1)", v = w == null ? void 0 : w.outline, b = {};
340
+ title: R,
341
+ description: y
342
+ } = r, { shapeType: T, text: b, shapeProperties: w, placeholder: I, link: S } = r.shape || {}, D = w == null ? "" : te(w.shapeBackgroundFill) || "rgba(255,255,255,1)", v = w == null ? void 0 : w.outline, P = {};
343
343
  if (v) {
344
- const { outlineFill: I, weight: C } = v;
345
- b.strokeWidth = C, b.stroke = Q(I) || "rgba(0,0,0,1)";
344
+ const { outlineFill: m, weight: E } = v;
345
+ P.strokeWidth = E, P.stroke = te(m) || "rgba(0,0,0,1)";
346
346
  }
347
- if (T === _e.RECTANGLE)
348
- return new H(n, {
349
- fill: x,
347
+ if (T === fe.RECTANGLE)
348
+ return new Y(n, {
349
+ fill: D,
350
350
  top: i,
351
351
  left: s,
352
352
  width: c,
353
353
  height: o,
354
354
  zIndex: t,
355
355
  angle: l,
356
- scaleX: p,
356
+ scaleX: u,
357
357
  scaleY: _,
358
358
  skewX: d,
359
359
  skewY: g,
@@ -361,19 +361,19 @@ class pt extends F {
361
361
  flipY: f,
362
362
  isTransformer: !0,
363
363
  forceRender: !0,
364
- ...b
364
+ ...P
365
365
  });
366
- if (T === _e.ROUND_RECTANGLE) {
367
- const I = (w == null ? void 0 : w.radius) || 0;
368
- return new H(n, {
369
- fill: x,
366
+ if (T === fe.ROUND_RECTANGLE) {
367
+ const m = (w == null ? void 0 : w.radius) || 0;
368
+ return new Y(n, {
369
+ fill: D,
370
370
  top: i,
371
371
  left: s,
372
372
  width: c,
373
373
  height: o,
374
374
  zIndex: t,
375
375
  angle: l,
376
- scaleX: p,
376
+ scaleX: u,
377
377
  scaleY: _,
378
378
  skewX: d,
379
379
  skewY: g,
@@ -381,32 +381,32 @@ class pt extends F {
381
381
  flipY: f,
382
382
  isTransformer: !0,
383
383
  forceRender: !0,
384
- radius: I,
385
- ...b
384
+ radius: m,
385
+ ...P
386
386
  });
387
387
  }
388
388
  }
389
389
  }
390
390
  class _t {
391
391
  constructor() {
392
- u(this, "zIndex", 2);
392
+ p(this, "zIndex", 2);
393
393
  }
394
394
  create(e) {
395
- return e.createInstance(pt);
395
+ return e.createInstance(ut);
396
396
  }
397
397
  }
398
- W.add(new _t());
398
+ $.add(new _t());
399
399
  var ft = Object.defineProperty, vt = Object.getOwnPropertyDescriptor, wt = (a, e, r, n) => {
400
400
  for (var t = n > 1 ? void 0 : n ? vt(e, r) : e, s = a.length - 1, i; s >= 0; s--)
401
401
  (i = a[s]) && (t = (n ? i(e, r, t) : i(t)) || t);
402
402
  return n && t && ft(e, r, t), t;
403
403
  }, St = (a, e) => (r, n) => e(r, n, a);
404
- let de = class extends F {
404
+ let he = class extends B {
405
405
  constructor(e) {
406
406
  super();
407
- u(this, "zIndex", 6);
408
- u(this, "viewKey", Y.SLIDE);
409
- u(this, "_ObjectProvider", null);
407
+ p(this, "zIndex", 6);
408
+ p(this, "viewKey", F.SLIDE);
409
+ p(this, "_ObjectProvider", null);
410
410
  this._injector = e;
411
411
  }
412
412
  check(e) {
@@ -422,26 +422,26 @@ let de = class extends F {
422
422
  width: c,
423
423
  height: o,
424
424
  angle: l,
425
- scaleX: p,
425
+ scaleX: u,
426
426
  scaleY: _,
427
427
  skewX: d,
428
428
  skewY: g,
429
429
  flipX: h,
430
430
  flipY: f,
431
- title: y,
432
- description: D,
431
+ title: R,
432
+ description: y,
433
433
  slide: T
434
434
  } = e;
435
435
  if (T == null)
436
436
  return;
437
- const m = new Me(T), w = new Te("__SLIDERender__" + n, {
437
+ const b = new Me(T), w = new Oe("__SLIDERender__" + n, {
438
438
  top: i,
439
439
  left: s,
440
440
  width: c,
441
441
  height: o,
442
442
  zIndex: t,
443
443
  angle: l,
444
- scaleX: p,
444
+ scaleX: u,
445
445
  scaleY: _,
446
446
  skewX: d,
447
447
  skewY: g,
@@ -451,68 +451,68 @@ let de = class extends F {
451
451
  forceRender: !0
452
452
  });
453
453
  w.enableNav(), w.enableSelectedClipElement();
454
- const P = m.getPageOrder(), S = m.getPages();
455
- if (!P || !S)
454
+ const I = b.getPageOrder(), S = b.getPages();
455
+ if (!I || !S)
456
456
  return w;
457
- this._ObjectProvider = new ee(this._injector);
458
- for (let x = 0, v = P.length; x < v; x++) {
459
- const b = S[P[x]], { id: I } = b;
460
- w.addPage(this._createScene(I, w, b, r, m));
457
+ this._ObjectProvider = new re(this._injector);
458
+ for (let D = 0, v = I.length; D < v; D++) {
459
+ const P = S[I[D]], { id: m } = P;
460
+ w.addPage(this._createScene(m, w, P, r, b));
461
461
  }
462
462
  return w.activeFirstPage(), w;
463
463
  }
464
464
  _createScene(e, r, n, t, s) {
465
465
  var g;
466
- const { width: i, height: c } = r, o = new re(e, r, {
466
+ const { width: i, height: c } = r, o = new ie(e, r, {
467
467
  width: i,
468
468
  height: c
469
469
  });
470
- new L(`PageViewer_${e}`, o, {
470
+ new X(`PageViewer_${e}`, o, {
471
471
  left: 0,
472
472
  top: 0,
473
473
  bottom: 0,
474
474
  right: 0
475
475
  }).closeClip();
476
- const { pageElements: p, pageBackgroundFill: _ } = n, d = (g = this._ObjectProvider) == null ? void 0 : g.convertToRenderObjects(p, t);
476
+ const { pageElements: u, pageBackgroundFill: _ } = n, d = (g = this._ObjectProvider) == null ? void 0 : g.convertToRenderObjects(u, t);
477
477
  return o.openTransformer(), this._addBackgroundRect(o, _, s), o.addObjects(d), o;
478
478
  }
479
479
  _addBackgroundRect(e, r, n) {
480
- const t = n.getPageSize(), { width: s = 0, height: i = 0 } = t, c = new H("canvas", {
480
+ const t = n.getPageSize(), { width: s = 0, height: i = 0 } = t, c = new Y("canvas", {
481
481
  left: 0,
482
482
  top: 0,
483
483
  width: s,
484
484
  height: i,
485
485
  strokeWidth: 1,
486
486
  stroke: "rgba(198,198,198, 1)",
487
- fill: Q(r) || "rgba(255,255,255, 1)",
487
+ fill: te(r) || "rgba(255,255,255, 1)",
488
488
  zIndex: 0,
489
489
  evented: !1
490
490
  });
491
491
  e.addObject(c, 0);
492
492
  }
493
493
  };
494
- de = wt([
495
- St(0, U(ne))
496
- ], de);
497
- class Pt {
494
+ he = wt([
495
+ St(0, A(se))
496
+ ], he);
497
+ class It {
498
498
  constructor() {
499
- u(this, "zIndex", 6);
499
+ p(this, "zIndex", 6);
500
500
  }
501
501
  create(e) {
502
- return e.createInstance(de);
502
+ return e.createInstance(he);
503
503
  }
504
504
  }
505
- W.add(new Pt());
506
- var bt = Object.defineProperty, mt = Object.getOwnPropertyDescriptor, It = (a, e, r, n) => {
507
- for (var t = n > 1 ? void 0 : n ? mt(e, r) : e, s = a.length - 1, i; s >= 0; s--)
505
+ $.add(new It());
506
+ var Pt = Object.defineProperty, bt = Object.getOwnPropertyDescriptor, mt = (a, e, r, n) => {
507
+ for (var t = n > 1 ? void 0 : n ? bt(e, r) : e, s = a.length - 1, i; s >= 0; s--)
508
508
  (i = a[s]) && (t = (n ? i(e, r, t) : i(t)) || t);
509
- return n && t && bt(e, r, t), t;
510
- }, Se = (a, e) => (r, n) => e(r, n, a);
511
- let he = class extends F {
509
+ return n && t && Pt(e, r, t), t;
510
+ }, Ie = (a, e) => (r, n) => e(r, n, a);
511
+ let ge = class extends B {
512
512
  constructor(e, r) {
513
513
  super();
514
- u(this, "zIndex", 4);
515
- u(this, "viewKey", Y.SPREADSHEET);
514
+ p(this, "zIndex", 4);
515
+ p(this, "viewKey", F.SPREADSHEET);
516
516
  this._localeService = e, this._contextService = r;
517
517
  }
518
518
  check(e) {
@@ -528,32 +528,32 @@ let he = class extends F {
528
528
  width: c,
529
529
  height: o,
530
530
  angle: l,
531
- scaleX: p,
531
+ scaleX: u,
532
532
  scaleY: _,
533
533
  skewX: d,
534
534
  skewY: g,
535
535
  flipX: h,
536
536
  flipY: f,
537
- spreadsheet: y
537
+ spreadsheet: R
538
538
  } = e;
539
- if (y == null)
539
+ if (R == null)
540
540
  return;
541
- const { worksheet: D, styles: T } = y, { cellData: m } = D, w = new ze(m), P = new Xe(T), S = new qe(
542
- new Ae(D, P),
541
+ const { worksheet: y, styles: T } = R, { cellData: b } = y, w = new Ne(b), I = new ze(T), S = new qe(
542
+ new Ve(n, y, I),
543
543
  // FIXME: worksheet in slide doesn't has a Worksheet object
544
- D,
544
+ y,
545
545
  w,
546
- P,
546
+ I,
547
547
  this._localeService,
548
548
  this._contextService
549
- ), { rowTotalHeight: x, columnTotalWidth: v, rowHeaderWidth: b, columnHeaderHeight: I } = S, C = v + D.rowHeader.width || 0, $ = x + D.columnHeader.height || 0, N = new me("spreadInSlideSceneViewer" + n, {
549
+ ), { rowTotalHeight: D, columnTotalWidth: v, rowHeaderWidth: P, columnHeaderHeight: m } = S, E = v + y.rowHeader.width || 0, H = D + y.columnHeader.height || 0, U = new me("spreadInSlideSceneViewer" + n, {
550
550
  top: i,
551
551
  left: s,
552
552
  width: c,
553
553
  height: o,
554
554
  zIndex: t,
555
555
  angle: l,
556
- scaleX: p,
556
+ scaleX: u,
557
557
  scaleY: _,
558
558
  skewX: d,
559
559
  skewY: g,
@@ -561,46 +561,46 @@ let he = class extends F {
561
561
  flipY: f,
562
562
  isTransformer: !0,
563
563
  forceRender: !0
564
- }), E = new re("spreadInSlideScene" + n, N, {
565
- width: C,
566
- height: $
564
+ }), L = new ie("spreadInSlideScene" + n, U, {
565
+ width: E,
566
+ height: H
567
567
  });
568
- this._updateViewport(n, b, I, E, r);
569
- const j = new Ge("testSheetViewer", S, !1), A = new Ze("spreadInSlideRow", S), B = new Je("spreadInSlideColumn", S), K = new H("spreadInSlideLeftTop", {
568
+ this._updateViewport(n, P, m, L, r);
569
+ const C = new Ge("testSheetViewer", S, !1), V = new Ze("spreadInSlideRow", S), K = new Je("spreadInSlideColumn", S), k = new Y("spreadInSlideLeftTop", {
570
570
  zIndex: 2,
571
571
  left: -1,
572
572
  top: -1,
573
- width: b,
574
- height: I,
575
- fill: ve([248, 249, 250]),
576
- stroke: ve([217, 217, 217]),
573
+ width: P,
574
+ height: m,
575
+ fill: we([248, 249, 250]),
576
+ stroke: we([217, 217, 217]),
577
577
  strokeWidth: 1
578
578
  });
579
- return j.zIndex = 10, E.addObjects([j], 1), E.addObjects([A, B, K], 2), N;
579
+ return C.zIndex = 10, L.addObjects([C], 1), L.addObjects([V, K, k], 2), U;
580
580
  }
581
581
  _updateViewport(e, r, n, t, s) {
582
582
  if (s == null)
583
583
  return;
584
- const i = r * t.scaleX, c = n * t.scaleY, o = new L("spreadInSlideViewMain" + e, t, {
584
+ const i = r * t.scaleX, c = n * t.scaleY, o = new X("spreadInSlideViewMain" + e, t, {
585
585
  left: i,
586
586
  top: c,
587
587
  bottom: 0,
588
588
  right: 0,
589
589
  isWheelPreventDefaultX: !0
590
- }), l = new L("spreadInSlideViewTop" + e, t, {
590
+ }), l = new X("spreadInSlideViewTop" + e, t, {
591
591
  left: i,
592
592
  height: c,
593
593
  top: 0,
594
594
  right: 0,
595
595
  isWheelPreventDefaultX: !0
596
- }), p = new L("spreadInSlideViewLeft" + e, t, {
596
+ }), u = new X("spreadInSlideViewLeft" + e, t, {
597
597
  left: 0,
598
598
  bottom: 0,
599
599
  top: c,
600
600
  width: i,
601
601
  isWheelPreventDefaultX: !0
602
602
  });
603
- new L("spreadInSlideViewLeftTop" + e, t, {
603
+ new X("spreadInSlideViewLeftTop" + e, t, {
604
604
  left: 0,
605
605
  top: 0,
606
606
  width: i,
@@ -611,13 +611,13 @@ let he = class extends F {
611
611
  l.updateScroll({
612
612
  scrollX: d,
613
613
  actualScrollX: h
614
- }), p.updateScroll({
614
+ }), u.updateScroll({
615
615
  scrollY: g,
616
616
  actualScrollY: f
617
617
  });
618
618
  }), t.attachControl(), new ue(o, {
619
619
  mainScene: s
620
- }), t.on(ge.wheel, (_, d) => {
620
+ }), t.on(pe.wheel, (_, d) => {
621
621
  const g = _;
622
622
  if (g.ctrlKey) {
623
623
  const h = Math.abs(g.deltaX);
@@ -628,27 +628,27 @@ let he = class extends F {
628
628
  });
629
629
  }
630
630
  };
631
- he = It([
632
- Se(0, U(te)),
633
- Se(1, Ee)
634
- ], he);
631
+ ge = mt([
632
+ Ie(0, A(ne)),
633
+ Ie(1, Le)
634
+ ], ge);
635
635
  class Tt {
636
636
  constructor() {
637
- u(this, "zIndex", 4);
637
+ p(this, "zIndex", 4);
638
638
  }
639
639
  create(e) {
640
- return e.createInstance(he);
640
+ return e.createInstance(ge);
641
641
  }
642
642
  }
643
- W.add(new Tt());
644
- var Ot = Object.defineProperty, xt = Object.getOwnPropertyDescriptor, yt = (a, e, r, n) => {
645
- for (var t = n > 1 ? void 0 : n ? xt(e, r) : e, s = a.length - 1, i; s >= 0; s--)
643
+ $.add(new Tt());
644
+ var Ot = Object.defineProperty, Dt = Object.getOwnPropertyDescriptor, Rt = (a, e, r, n) => {
645
+ for (var t = n > 1 ? void 0 : n ? Dt(e, r) : e, s = a.length - 1, i; s >= 0; s--)
646
646
  (i = a[s]) && (t = (n ? i(e, r, t) : i(t)) || t);
647
647
  return n && t && Ot(e, r, t), t;
648
- }, Dt = (a, e) => (r, n) => e(r, n, a);
649
- let ee = class {
648
+ }, yt = (a, e) => (r, n) => e(r, n, a);
649
+ let re = class {
650
650
  constructor(a) {
651
- u(this, "_adaptors", []);
651
+ p(this, "_adaptors", []);
652
652
  this._injector = a, this._adaptorLoader();
653
653
  }
654
654
  convertToRenderObjects(a, e) {
@@ -668,40 +668,40 @@ let ee = class {
668
668
  }
669
669
  }
670
670
  _adaptorLoader() {
671
- W.getData().sort(Le).forEach((a) => {
671
+ $.getData().sort(Xe).forEach((a) => {
672
672
  this._adaptors.push(a.create(this._injector));
673
673
  });
674
674
  }
675
675
  };
676
- ee = yt([
677
- Dt(0, U(ne))
678
- ], ee);
679
- var Ct = Object.defineProperty, Rt = Object.getOwnPropertyDescriptor, jt = (a, e, r, n) => {
680
- for (var t = n > 1 ? void 0 : n ? Rt(e, r) : e, s = a.length - 1, i; s >= 0; s--)
676
+ re = Rt([
677
+ yt(0, A(se))
678
+ ], re);
679
+ var Et = Object.defineProperty, xt = Object.getOwnPropertyDescriptor, Ct = (a, e, r, n) => {
680
+ for (var t = n > 1 ? void 0 : n ? xt(e, r) : e, s = a.length - 1, i; s >= 0; s--)
681
681
  (i = a[s]) && (t = (n ? i(e, r, t) : i(t)) || t);
682
- return n && t && Ct(e, r, t), t;
683
- }, se = (a, e) => (r, n) => e(r, n, a), Mt = /* @__PURE__ */ ((a) => (a.COMPONENT = "__slideRender__", a.SCENE = "__mainScene__", a.VIEW = "__mainView__", a))(Mt || {});
684
- let J = class extends Ve {
682
+ return n && t && Et(e, r, t), t;
683
+ }, ce = (a, e) => (r, n) => e(r, n, a), jt = /* @__PURE__ */ ((a) => (a.COMPONENT = "__slideRender__", a.SCENE = "__mainScene__", a.VIEW = "__mainView__", a))(jt || {});
684
+ let ee = class extends We {
685
685
  constructor(e, r, n) {
686
686
  super();
687
- u(this, "_objectProvider", null);
688
- u(this, "_activePageId", "");
689
- u(this, "_refreshThumb", We(() => {
687
+ p(this, "_objectProvider", null);
688
+ p(this, "_activePageId", "");
689
+ p(this, "_refreshThumb", $e(() => {
690
690
  this.createThumbs();
691
691
  }, 300));
692
- this._currentUniverService = e, this._injector = r, this._renderManagerService = n, this._initializeDependencies(this._injector), this._initialize();
692
+ this._univerInstanceService = e, this._injector = r, this._renderManagerService = n, this._initializeDependencies(this._injector), this._initialize();
693
693
  }
694
694
  _initialize() {
695
- this._renderManagerService.createRender$.pipe(we(this.dispose$)).subscribe((e) => {
695
+ this._renderManagerService.createRender$.pipe(Se(this.dispose$)).subscribe((e) => {
696
696
  this._create(e);
697
- }), this._currentUniverService.currentSlide$.pipe(we(this.dispose$)).subscribe((e) => {
697
+ }), this._univerInstanceService.getCurrentTypeOfUnit$(M.UNIVER_SLIDE).pipe(Se(this.dispose$)).subscribe((e) => {
698
698
  this._create(e == null ? void 0 : e.getUnitId());
699
- }), this._currentUniverService.getAllUniverSlidesInstance().forEach((e) => {
699
+ }), this._univerInstanceService.getAllUnitsForType(M.UNIVER_SLIDE).forEach((e) => {
700
700
  this._create(e.getUnitId());
701
701
  });
702
702
  }
703
703
  activePage(e) {
704
- const r = this._currentUniverService.getCurrentUniverSlideInstance();
704
+ const r = this._univerInstanceService.getCurrentUnitForType(M.UNIVER_SLIDE);
705
705
  let n;
706
706
  if (e)
707
707
  n = r.getPage(e);
@@ -733,14 +733,14 @@ let J = class extends Ve {
733
733
  });
734
734
  }
735
735
  _create(e) {
736
- e == null || this._currentUniverService.getUniverSlideInstance(e) == null || this._renderManagerService.has(e) || this._addNewRender(e);
736
+ e == null || this._univerInstanceService.getUnit(e, M.UNIVER_SLIDE) == null || this._renderManagerService.has(e) || this._addNewRender(e);
737
737
  }
738
738
  _currentRender() {
739
- const e = this._currentUniverService.getCurrentUniverSlideInstance();
739
+ const e = this._univerInstanceService.getCurrentUnitForType(M.UNIVER_SLIDE);
740
740
  return this._renderManagerService.getRenderById(e.getUnitId());
741
741
  }
742
742
  _addNewRender(e) {
743
- const r = this._currentUniverService.getUniverSlideInstance(e);
743
+ const r = this._univerInstanceService.getUnit(e, M.UNIVER_SLIDE);
744
744
  if (r == null)
745
745
  return;
746
746
  const n = r.getContainer(), t = r.getParentRenderUnitId();
@@ -758,15 +758,15 @@ let J = class extends Ve {
758
758
  this.createThumbs();
759
759
  }, 300);
760
760
  }), i.resize(2400, 1800);
761
- const o = new L("__mainView__", i, {
761
+ const o = new X("__mainView__", i, {
762
762
  left: 0,
763
763
  top: 0,
764
764
  bottom: 0,
765
765
  right: 0,
766
766
  isWheelPreventDefaultX: !0
767
767
  });
768
- i.attachControl(), i.on(ge.wheel, (p, _) => {
769
- const d = p;
768
+ i.attachControl(), i.on(pe.wheel, (u, _) => {
769
+ const d = u;
770
770
  if (d.ctrlKey) {
771
771
  const g = Math.abs(d.deltaX);
772
772
  let h = g < 40 ? 0.2 : g < 80 ? 0.4 : 0.2;
@@ -779,12 +779,12 @@ let J = class extends Ve {
779
779
  const l = this._createSlide(i);
780
780
  s.mainComponent = l, s.components.set("__slideRender__", l), this._createSlidePages(r, l), c.runRenderLoop(() => {
781
781
  i.render();
782
- const p = document.getElementById("app");
783
- p && (p.innerText = `fps:${Math.round(c.getFps()).toString()}`);
782
+ const u = document.getElementById("app");
783
+ u && (u.innerText = `fps:${Math.round(c.getFps()).toString()}`);
784
784
  });
785
785
  }
786
786
  _createSlide(e) {
787
- const r = this._currentUniverService.getCurrentUniverSlideInstance(), { width: n, height: t } = e, s = r.getPageSize(), { width: i = 100, height: c = 100 } = s, o = new Te("__slideRender__", {
787
+ const r = this._univerInstanceService.getCurrentUnitForType(M.UNIVER_SLIDE), { width: n, height: t } = e, s = r.getPageSize(), { width: i = 100, height: c = 100 } = s, o = new Oe("__slideRender__", {
788
788
  left: (n - i) / 2,
789
789
  top: (t - c) / 2,
790
790
  width: i,
@@ -794,14 +794,14 @@ let J = class extends Ve {
794
794
  return o.enableNav(), o.enableSelectedClipElement(), e.addObject(o), o;
795
795
  }
796
796
  _addBackgroundRect(e, r) {
797
- const t = this._currentUniverService.getCurrentUniverSlideInstance().getPageSize(), { width: s = 0, height: i = 0 } = t, c = new H("canvas", {
797
+ const t = this._univerInstanceService.getCurrentUnitForType(M.UNIVER_SLIDE).getPageSize(), { width: s = 0, height: i = 0 } = t, c = new Y("canvas", {
798
798
  left: 0,
799
799
  top: 0,
800
800
  width: s,
801
801
  height: i,
802
802
  strokeWidth: 1,
803
803
  stroke: "rgba(198,198,198, 1)",
804
- fill: Q(r) || "rgba(255,255,255, 1)",
804
+ fill: te(r) || "rgba(255,255,255, 1)",
805
805
  zIndex: 0,
806
806
  evented: !1
807
807
  });
@@ -837,7 +837,7 @@ let J = class extends Ve {
837
837
  }
838
838
  }
839
839
  createThumbs() {
840
- const r = this._currentUniverService.getCurrentUniverSlideInstance().getPageOrder(), n = this._currentRender();
840
+ const r = this._univerInstanceService.getCurrentUnitForType(M.UNIVER_SLIDE).getPageOrder(), n = this._currentRender();
841
841
  if (!(!r || !n) && r.length !== 0)
842
842
  for (let t = 0, s = r.length; t < s; t++) {
843
843
  const i = r[t];
@@ -851,11 +851,11 @@ let J = class extends Ve {
851
851
  const n = this._currentRender();
852
852
  if (!n || !this._objectProvider)
853
853
  return;
854
- const { scene: t, mainComponent: s } = n, i = s, { width: c, height: o } = i, l = new re(e, i, {
854
+ const { scene: t, mainComponent: s } = n, i = s, { width: c, height: o } = i, l = new ie(e, i, {
855
855
  width: c,
856
856
  height: o
857
857
  });
858
- new L(`PageViewer_${e}`, l, {
858
+ new X(`PageViewer_${e}`, l, {
859
859
  left: 0,
860
860
  top: 0,
861
861
  bottom: 0,
@@ -873,29 +873,29 @@ let J = class extends Ve {
873
873
  }), i.addPage(l), l;
874
874
  }
875
875
  _initializeDependencies(e) {
876
- this._objectProvider = e.createInstance(ee);
876
+ this._objectProvider = e.createInstance(re);
877
877
  }
878
878
  };
879
- J = jt([
880
- Ue(Ne.Ready, J),
881
- se(0, be),
882
- se(1, U(ne)),
883
- se(2, Qe)
884
- ], J);
885
- var Et = Object.defineProperty, zt = Object.getOwnPropertyDescriptor, Xt = (a, e, r, n) => {
886
- for (var t = n > 1 ? void 0 : n ? zt(e, r) : e, s = a.length - 1, i; s >= 0; s--)
879
+ ee = Ct([
880
+ Ae(Ue.Ready, ee),
881
+ ce(0, be),
882
+ ce(1, A(se)),
883
+ ce(2, Qe)
884
+ ], ee);
885
+ var Mt = Object.defineProperty, Lt = Object.getOwnPropertyDescriptor, Nt = (a, e, r, n) => {
886
+ for (var t = n > 1 ? void 0 : n ? Lt(e, r) : e, s = a.length - 1, i; s >= 0; s--)
887
887
  (i = a[s]) && (t = (n ? i(e, r, t) : i(t)) || t);
888
- return n && t && Et(e, r, t), t;
889
- }, ae = (a, e) => (r, n) => e(r, n, a);
890
- const At = {}, Lt = "slides";
891
- var ce;
892
- let Pe = (ce = class extends $e {
888
+ return n && t && Mt(e, r, t), t;
889
+ }, oe = (a, e) => (r, n) => e(r, n, a);
890
+ const zt = {}, Vt = "slides";
891
+ var Q;
892
+ let Pe = (Q = class extends He {
893
893
  constructor(e = {}, r, n, t) {
894
- super(Lt);
895
- u(this, "_config");
896
- u(this, "_canvasEngine", null);
897
- u(this, "_canvasView", null);
898
- this._currentUniverService = r, this._localeService = n, this._injector = t, this._config = Object.assign(At, e), this._initializeDependencies(this._injector);
894
+ super();
895
+ p(this, "_config");
896
+ p(this, "_canvasEngine", null);
897
+ p(this, "_canvasView", null);
898
+ this._univerInstanceService = r, this._localeService = n, this._injector = t, this._config = Object.assign(zt, e), this._initializeDependencies(this._injector);
899
899
  }
900
900
  initialize() {
901
901
  this._localeService.load({
@@ -911,9 +911,6 @@ let Pe = (ce = class extends $e {
911
911
  onRendered() {
912
912
  this.initialize();
913
913
  }
914
- onDestroy() {
915
- super.onDestroy();
916
- }
917
914
  getCanvasEngine() {
918
915
  return this._canvasEngine;
919
916
  }
@@ -921,19 +918,19 @@ let Pe = (ce = class extends $e {
921
918
  return this._canvasView;
922
919
  }
923
920
  _initializeDependencies(e) {
924
- [[J]].forEach((n) => {
921
+ [[ee]].forEach((n) => {
925
922
  e.add(n);
926
923
  });
927
924
  }
928
- }, u(ce, "type", He.Slide), ce);
929
- Pe = Xt([
930
- ae(1, be),
931
- ae(2, U(te)),
932
- ae(3, U(ne))
925
+ }, p(Q, "pluginName", Vt), p(Q, "type", M.UNIVER_SLIDE), Q);
926
+ Pe = Nt([
927
+ oe(1, be),
928
+ oe(2, A(ne)),
929
+ oe(3, A(se))
933
930
  ], Pe);
934
931
  export {
935
- J as CanvasView,
936
- Mt as SLIDE_KEY,
932
+ ee as CanvasView,
933
+ jt as SLIDE_KEY,
937
934
  Pe as UniverSlidesPlugin,
938
935
  Yt as enUS,
939
936
  tt as zhCN