@netless/app-slide 0.0.54 → 0.0.55

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/dist/main.es.js CHANGED
@@ -30764,6 +30764,9 @@ void main() {
30764
30764
  set on(t3) {
30765
30765
  this.target.fillActive = t3 === "true";
30766
30766
  }
30767
+ get designColor() {
30768
+ return this.target.fillColorFilter.designColor;
30769
+ }
30767
30770
  }
30768
30771
  class wM {
30769
30772
  constructor(t3, e3) {
@@ -30817,7 +30820,7 @@ void main() {
30817
30820
  }
30818
30821
  execAction(t3) {
30819
30822
  var e3;
30820
- if (t3.action === "ppaction://hlinksldjump") {
30823
+ if (this.ctx.eventHub.emit(zR.userInput), t3.action === "ppaction://hlinksldjump") {
30821
30824
  const n2 = ((e3 = t3 == null ? void 0 : t3.target) !== null && e3 !== void 0 ? e3 : "").match(/slide(\d+)\.xml/);
30822
30825
  n2 && n2[1] && this.ctx.eventHub.emit(zR.requestGotoSlide, Number(n2[1]));
30823
30826
  } else if (t3.action === "ppaction://hlinkshowjump?jump=nextslide")
@@ -30838,7 +30841,11 @@ void main() {
30838
30841
  class SM {
30839
30842
  constructor(t3, e3, n2) {
30840
30843
  var i2, r3, o3, s3, a2, l2;
30841
- this.scaleExt = { x: 1, y: 1 }, this.scaleOrigin = { x: 1, y: 1 }, this.designScale = { x: 1, y: 1 }, this.bound = new d_(0, 0, 1, 1), this.pptX = 0, this.pptY = 0, this.presetSubType = 0, this.designWidth = 0, this.designHeight = 0, this.designX = 0, this.designY = 0, this.hasPreset = false, this.container = new ty(), this.ctx = e3, this.style = new wM(this.container, t3.hardHidden), this.designGlobalPosition = { x: n2.x + ((r3 = (i2 = t3.position) === null || i2 === void 0 ? void 0 : i2.x) !== null && r3 !== void 0 ? r3 : 0), y: n2.y + ((s3 = (o3 = t3.position) === null || o3 === void 0 ? void 0 : o3.y) !== null && s3 !== void 0 ? s3 : 0) }, (t3.hlinkClick || t3.hlinkHover) && (this.hyperlink = new TM(this.container, this.ctx), t3.hlinkHover && ((a2 = this.hyperlink) === null || a2 === void 0 || a2.addAction(t3.hlinkHover, "hover")), t3.hlinkClick && ((l2 = this.hyperlink) === null || l2 === void 0 || l2.addAction(t3.hlinkClick, "click")));
30844
+ this.scaleExt = { x: 1, y: 1 }, this.scaleOrigin = { x: 1, y: 1 }, this.designScale = { x: 1, y: 1 }, this.bound = new d_(0, 0, 1, 1), this.pptX = 0, this.pptY = 0, this.presetSubType = 0, this.designWidth = 0, this.designHeight = 0, this.designX = 0, this.designY = 0, this.hasPreset = false, this.container = new ty(), this.ctx = e3, this.style = new wM(this.container, t3.hardHidden), this.designGlobalPosition = { x: n2.x + ((r3 = (i2 = t3.position) === null || i2 === void 0 ? void 0 : i2.x) !== null && r3 !== void 0 ? r3 : 0), y: n2.y + ((s3 = (o3 = t3.position) === null || o3 === void 0 ? void 0 : o3.y) !== null && s3 !== void 0 ? s3 : 0) }, (t3.hlinkClick || t3.hlinkHover) && (this.hyperlink = new TM(this.container, this.ctx), t3.hlinkHover && ((a2 = this.hyperlink) === null || a2 === void 0 || a2.addAction(t3.hlinkHover, "hover")), t3.hlinkClick && ((l2 = this.hyperlink) === null || l2 === void 0 || l2.addAction(t3.hlinkClick, "click"))), this.ctx.clock.waitUntil(() => !!this.container.width, 3e3).then(() => {
30845
+ this.designWidth = this.designWidth || this.container.width;
30846
+ }), this.ctx.clock.waitUntil(() => !!this.container.height, 3e3).then(() => {
30847
+ this.designHeight = this.designHeight || this.container.height;
30848
+ });
30842
30849
  }
30843
30850
  updateScale() {
30844
30851
  this.container && (this.container.scale.x = this.designScale.x * this.scaleExt.x * this.scaleOrigin.x, this.container.scale.y = this.designScale.y * this.scaleExt.y * this.scaleOrigin.y);
@@ -30875,15 +30882,14 @@ void main() {
30875
30882
  return this.scaleExt.x * this.scaleOrigin.x * this.designWidth / this.ctx.stageWidth;
30876
30883
  }
30877
30884
  set ppt_w(t3) {
30878
- this.scaleExt.x = t3 * this.ctx.stageWidth / this.designWidth, this.updateScale();
30885
+ this.designWidth && (this.scaleExt.x = t3 * this.ctx.stageWidth / this.designWidth, this.updateScale());
30879
30886
  }
30880
30887
  get ppt_h() {
30881
30888
  const t3 = this.designHeight || this.container.height;
30882
30889
  return this.scaleExt.y * this.scaleOrigin.y * t3 / this.ctx.stageHeight;
30883
30890
  }
30884
30891
  set ppt_h(t3) {
30885
- const e3 = this.designHeight || this.container.height;
30886
- this.scaleExt.y = t3 * this.ctx.stageHeight / e3, this.updateScale();
30892
+ this.designHeight && (this.scaleExt.y = t3 * this.ctx.stageHeight / this.designHeight, this.updateScale());
30887
30893
  }
30888
30894
  get ppt_x() {
30889
30895
  return (this.container.position.x - this.container.pivot.x) / this.ctx.stageWidth;
@@ -30907,6 +30913,18 @@ void main() {
30907
30913
  set r(t3) {
30908
30914
  this.container.rotation = t3;
30909
30915
  }
30916
+ set xshear(t3) {
30917
+ this.container.skew.x = t3;
30918
+ }
30919
+ get xshear() {
30920
+ return this.container.skew.x;
30921
+ }
30922
+ set yshear(t3) {
30923
+ this.container.skew.y = t3;
30924
+ }
30925
+ get yshear() {
30926
+ return this.container.skew.y;
30927
+ }
30910
30928
  }
30911
30929
  class EM {
30912
30930
  constructor(t3) {
@@ -30980,7 +30998,7 @@ void main() {
30980
30998
  }
30981
30999
  class IM extends Gx {
30982
31000
  constructor() {
30983
- super(void 0, "\nvarying vec2 vTextureCoord;\n\nuniform vec4 color;\nuniform sampler2D uSampler;\n\nvoid main(void){\n vec4 texColor = texture2D(uSampler, vTextureCoord);\n\n if (texColor.a > 0.0) {\n vec4 resultColor = color;\n resultColor = resultColor * texColor.a;\n gl_FragColor = resultColor;\n } else {\n gl_FragColor = texColor;\n }\n}\n", { color: new Float32Array([0, 0, 0, 0]), active: 0 }), this.currentColor = "#FFFFFFFF";
31001
+ super(void 0, "\nvarying vec2 vTextureCoord;\n\nuniform vec4 color;\nuniform sampler2D uSampler;\n\nvoid main(void){\n vec4 texColor = texture2D(uSampler, vTextureCoord);\n\n if (texColor.a > 0.0) {\n vec4 resultColor = color;\n resultColor = resultColor * texColor.a;\n gl_FragColor = resultColor;\n } else {\n gl_FragColor = texColor;\n }\n}\n", { color: new Float32Array([0, 0, 0, 0]), active: 0 }), this.currentColor = "#FFFFFFFF", this.designColor = "#FFFFFFFF";
30984
31002
  }
30985
31003
  set color(t3) {
30986
31004
  this.currentColor = t3;
@@ -32071,7 +32089,7 @@ void main(void){
32071
32089
  });
32072
32090
  }, this.json = t3, this.json.fillStyle && this.json.fillStyle.fillType === "groupFill" && i2 && (this.json.fillStyle = i2), this.id = t3.id;
32073
32091
  const { fillStyle: o3, lineStyle: s3 } = this.json;
32074
- this.container.name = t3.id, this.renderContainer.name = t3.id + "-render-container", this.backgroundFill = this.createBackgroundFill(), this.backgroundGraphics = this.createBackgroundGraphics(), this.strokeFill = this.createStrokeFill(), this.strokeGraphics = this.createStrokeGraphics(), this.ctx.timingTargets.addTarget(this.id, this), (o3 == null ? void 0 : o3.fillType) === "solidFill" && (this.fillColorFilter.currentColor = o3.color), ((r3 = s3 == null ? void 0 : s3.fill) === null || r3 === void 0 ? void 0 : r3.fillType) === "solidFill" && (this.strokeColorFilter.currentColor = s3.fill.color), this.updateTransform(this.json), t3.textBody && (this.text = new EA(t3.textBody, this.ctx, t3.textBody.iterateType, { x: this.designGlobalPosition.x, y: this.designGlobalPosition.y })), this.container.hitArea = new g_(1, 1, this.json.width, this.json.height);
32092
+ this.container.name = t3.id, this.renderContainer.name = t3.id + "-render-container", this.backgroundFill = this.createBackgroundFill(), this.backgroundGraphics = this.createBackgroundGraphics(), this.strokeFill = this.createStrokeFill(), this.strokeGraphics = this.createStrokeGraphics(), this.ctx.timingTargets.addTarget(this.id, this), (o3 == null ? void 0 : o3.fillType) === "solidFill" && (this.fillColorFilter.currentColor = o3.color, this.fillColorFilter.designColor = o3.color), ((r3 = s3 == null ? void 0 : s3.fill) === null || r3 === void 0 ? void 0 : r3.fillType) === "solidFill" && (this.strokeColorFilter.currentColor = s3.fill.color, this.strokeColorFilter.designColor = s3.fill.color), this.updateTransform(this.json), t3.textBody && (this.text = new EA(t3.textBody, this.ctx, t3.textBody.iterateType, { x: this.designGlobalPosition.x, y: this.designGlobalPosition.y })), this.container.hitArea = new g_(1, 1, this.json.width, this.json.height);
32075
32093
  }
32076
32094
  get interactiveContainer() {
32077
32095
  return this.renderContainer;
@@ -32768,6 +32786,7 @@ void main(void){
32768
32786
  if (t4) {
32769
32787
  t4.interactiveContainer.interactive = true, t4.interactiveContainer.cursor = "pointer";
32770
32788
  const n2 = () => {
32789
+ this.ctx.eventHub.emit(zR.userInput);
32771
32790
  const t5 = `shape ${e3} onClick`, { mode: n3 } = this.ctx;
32772
32791
  n3 !== "interactive" && n3 !== "sync" || this.ctx.eventHub.emit(zR.interactiveSeqAction, { action: t5, seqId: this.json.ctn.id }), n3 !== "sync" && n3 !== "local" || this.globalEventHub.emit(t5);
32773
32792
  };
@@ -33114,7 +33133,7 @@ void main(void){
33114
33133
  class mR extends JA {
33115
33134
  constructor(t3) {
33116
33135
  super(t3), this.isConflict = false, this.activeWhenConflict = "next", this.startColorString = null, this.currentColorString = "#FFFFFFFF", this.onTimelineStart = (t4) => {
33117
- this.from.isInit() || this.from.fromHexString(this.currentColorString), this.to.isInit() || this.from.by(this.by, this.to), t4.isReverse || this.updateCurrentValue();
33136
+ t4.isReverse || this.updateCurrentValue(), this.from.isInit() || this.from.fromHexString(this.currentColorString), this.to.isInit() || this.from.by(this.by, this.to);
33118
33137
  const [e3] = this.json.cBhvr.attrList[0].split(".");
33119
33138
  YA(this.timingTarget, e3 + ".on", "true");
33120
33139
  }, this.onTimeNodeEnd = () => {
@@ -33123,9 +33142,10 @@ void main(void){
33123
33142
  YA(this.timingTarget, t4 + ".on", "false");
33124
33143
  }
33125
33144
  }, this.onSeekToStart = () => {
33126
- if (this.timingTarget) {
33127
- const [t4] = this.json.cBhvr.attrList[0].split(".");
33128
- YA(this.timingTarget, t4 + ".on", "false");
33145
+ var t4;
33146
+ if (this.timingTarget && (this.onTimeUpdate({ duration: 1, delta: 0 }), ((t4 = this.timingTarget.fill) === null || t4 === void 0 ? void 0 : t4.designColor.toUpperCase()) === this.from.toHexString().toUpperCase())) {
33147
+ const [t5] = this.json.cBhvr.attrList[0].split(".");
33148
+ YA(this.timingTarget, t5 + ".on", "false");
33129
33149
  }
33130
33150
  }, this.onTimeNodeStart = () => {
33131
33151
  if (this.timingTarget) {
@@ -34049,7 +34069,7 @@ void main(void){
34049
34069
  });
34050
34070
  };
34051
34071
  r2.skipHello();
34052
- const HR = { randomBar: "RandomLines", circle: "Shape", ripple: "Ripples", wipe: "Erase", dissolve: "Dissolve", morph: "Smooth", fade: "FadeInOut", push: "Push", split: "Separation", reveal: "Display", pull: "Uncover", cover: "Cover", flash: "Flash", checker: "Checkerboard", blinds: "WindowShades", curtains: "Curtain", fallOver: "Fall", drape: "Suspension", wheel: "Clock", comb: "Combing", warp: "Scale", peelOff: "PeelOff", flip: "Flip" }, zR = { mainSeqStepChange: "mainSeqStepChange", mainSeqStateChange: "mainSeqStateChange", interactiveSeqStateChange: "interactiveSeqStateChange", interactiveSeqAction: "interactiveSeqAction", mainSeqStepStart: "mainSeqStepStart", mainSeqStepEnd: "mainSeqStepEnd", slideChange: "slideChange", renderStart: "renderStart", renderEnd: "renderEnd", hyperlinkTrigger: "hyperlinkTrigger", animateStart: "animateStart", animateEnd: "animateEnd", mediaSeek: "mediaSeek", mediaPlay: "mediaPlay", mediaPause: "mediaPause", requestNextSlide: "requestNextSlide", requestPrevSlide: "requestPrevSlide", requestGotoSlide: "requestGotoSlide" };
34072
+ const HR = { randomBar: "RandomLines", circle: "Shape", ripple: "Ripples", wipe: "Erase", dissolve: "Dissolve", morph: "Smooth", fade: "FadeInOut", push: "Push", split: "Separation", reveal: "Display", pull: "Uncover", cover: "Cover", flash: "Flash", checker: "Checkerboard", blinds: "WindowShades", curtains: "Curtain", fallOver: "Fall", drape: "Suspension", wheel: "Clock", comb: "Combing", warp: "Scale", peelOff: "PeelOff", flip: "Flip" }, zR = { mainSeqStepChange: "mainSeqStepChange", mainSeqStateChange: "mainSeqStateChange", interactiveSeqStateChange: "interactiveSeqStateChange", interactiveSeqAction: "interactiveSeqAction", mainSeqStepStart: "mainSeqStepStart", mainSeqStepEnd: "mainSeqStepEnd", slideChange: "slideChange", renderStart: "renderStart", renderEnd: "renderEnd", hyperlinkTrigger: "hyperlinkTrigger", animateStart: "animateStart", animateEnd: "animateEnd", mediaSeek: "mediaSeek", mediaPlay: "mediaPlay", mediaPause: "mediaPause", requestNextSlide: "requestNextSlide", requestPrevSlide: "requestPrevSlide", requestGotoSlide: "requestGotoSlide", userInput: "userInput" };
34053
34073
  class jR extends a.a {
34054
34074
  constructor(t3, e3 = {}) {
34055
34075
  super(), this.loader = new KE(true), this.transactionPlayer = new og(), this.transactionSprite = new OT(), this.isForward = true, this.drawCall = 0, this.scale = 1, this.prevSlideBase64 = null, this.fps = new qE(), this.designWidth = 0, this.designHeight = 0, this.currentIndex = 0, this.slideCount = 0, this.runtime = { drawCall: 0, fps: 0 }, this.mode = t3;
@@ -34122,7 +34142,7 @@ void main(void){
34122
34142
  return GR(this, void 0, void 0, function* () {
34123
34143
  this.emit(zR.renderStart, t3);
34124
34144
  const r3 = yield this.stagePool.getStage(t3);
34125
- this.translateEvent(r3.ctx.eventHub, [zR.mainSeqStepChange, zR.mainSeqStateChange, zR.hyperlinkTrigger, zR.interactiveSeqAction, zR.mainSeqStepStart, zR.mainSeqStepEnd, zR.animateStart, zR.animateEnd, zR.mediaPlay, zR.mediaPause, zR.mediaSeek, zR.requestGotoSlide, zR.requestNextSlide, zR.requestPrevSlide, zR.interactiveSeqStateChange]), this.currentIndex = Number(t3);
34145
+ this.translateEvent(r3.ctx.eventHub, [zR.mainSeqStepChange, zR.mainSeqStateChange, zR.hyperlinkTrigger, zR.interactiveSeqAction, zR.mainSeqStepStart, zR.mainSeqStepEnd, zR.animateStart, zR.animateEnd, zR.mediaPlay, zR.mediaPause, zR.mediaSeek, zR.requestGotoSlide, zR.requestNextSlide, zR.requestPrevSlide, zR.interactiveSeqStateChange, zR.userInput]), this.currentIndex = Number(t3);
34126
34146
  const { width: o3, height: s3, slideCount: a2 } = r3.json;
34127
34147
  this.slideCount = a2, this.designWidth = o3, this.designHeight = s3, r3.json.transition && r3.json.transition.type && !this.prevSlideBase64 && this.currentStage && (this.prevSlideBase64 = this.getBase64(this.currentStage)), (n2 = this.currentStage) === null || n2 === void 0 || n2.clearOnSlideChange();
34128
34148
  const l2 = this.currentStage;
@@ -34154,7 +34174,8 @@ void main(void){
34154
34174
  }, 100), new Promise((o5) => {
34155
34175
  var s4, l2, u2;
34156
34176
  (s4 = this.transactionPlayer) === null || s4 === void 0 || s4.play({ reverse: !this.isForward, prevTextureUrl: t3, nextTextureUrl: e3, textureWidth: this.designWidth, textureHeight: this.designHeight, presetType: HR[n2.type], stageWidth: this.designWidth, stageHeight: this.designHeight, duration: (u2 = (l2 = this.currentStage) === null || l2 === void 0 ? void 0 : l2.json.transition) === null || u2 === void 0 ? void 0 : u2.dur, delay: 0, clearColor: this.config.transactionBgColor, onTransactionEnd: () => {
34157
- o5(), i2.container.visible = false, r3.container.visible = true, this.app.stage.removeChild(this.transactionSprite), this.app.ticker.remove(a2);
34177
+ var t4, e4;
34178
+ o5(), i2.container.visible = false, r3.container.visible = true, (t4 = this.app.stage) === null || t4 === void 0 || t4.removeChild(this.transactionSprite), (e4 = this.app.ticker) === null || e4 === void 0 || e4.remove(a2);
34158
34179
  } });
34159
34180
  });
34160
34181
  }
@@ -35802,18 +35823,26 @@ void main(void){
35802
35823
  }
35803
35824
  var $C = { syncDispatch: "syncDispatch", syncReceive: "syncReceive", renderStart: "renderStart", renderEnd: "renderEnd", renderError: "renderError", slideChange: "slideChange", mainSeqStepStart: "mainSeqStepStart", mainSeqStepEnd: "mainSeqStepEnd", animateStart: "animateStart", animateEnd: "animateEnd", stateChange: "stateChange" }, QC = { taskId: "", url: "", currentSlideIndex: -1, mainSeqStep: -1, mainSeqState: null, mediaState: Object.create(null), interactiveSeqState: Object.create(null) }, tI = "";
35804
35825
  try {
35805
- tI = "0.2.0";
35826
+ tI = "0.2.1";
35806
35827
  } catch (t3) {
35807
35828
  tI = "dev";
35808
35829
  }
35809
35830
  var eI = function(t3) {
35810
35831
  function e3(e4) {
35811
35832
  var n2 = t3.call(this) || this;
35812
- return n2.iosResetCache = [], n2.needClearCacheImage = false, n2.version = tI, n2.__slideState = Object(l.cloneDeep)(QC), n2.resize = false, n2.isAnimating = false, n2.renderingTaskManager = new LP(), n2.isLoading = false, n2.interactive = true, n2.frameWidth = 1, n2.frameHeight = 1, n2.frame = document.createElement("div"), n2.medianController = document.createElement("div"), n2.frameResizeObserver = new ZC(function() {
35833
+ return n2.iosResetCache = [], n2.needClearCacheImage = false, n2.version = tI, n2.__slideState = Object(l.cloneDeep)(QC), n2.isUserInput = false, n2.resize = false, n2.isAnimating = false, n2.renderingTaskManager = new LP(), n2.isLoading = false, n2.interactive = true, n2.frameWidth = 1, n2.frameHeight = 1, n2.frame = document.createElement("div"), n2.medianController = document.createElement("div"), n2.frameResizeObserver = new ZC(function() {
35813
35834
  return n2.frameResizeHandler();
35814
35835
  }), n2.timestamp = function() {
35815
35836
  return Date.now();
35816
- }, n2.mode = "local", n2.log = "", n2.logId = "", n2.lastEmitedState = null, n2.playerController = null, n2.lock = new jC(), n2.isInitResized = false, n2.cacheImage = document.createElement("img"), n2.isFrowning = false, n2.isReleasing = false, n2.designWidth = 0, n2.designHeight = 0, n2._slideCount = 0, n2.persistLog = function() {
35837
+ }, n2.mode = "local", n2.enableGlobalClick = false, n2.log = "", n2.logId = "", n2.lastEmitedState = null, n2.playerController = null, n2.lock = new jC(), n2.isInitResized = false, n2.cacheImage = document.createElement("img"), n2.isFrowning = false, n2.isReleasing = false, n2.designWidth = 0, n2.designHeight = 0, n2._slideCount = 0, n2.userInputHandle = function() {
35838
+ n2.isUserInput = true, setTimeout(function() {
35839
+ n2.isUserInput = false;
35840
+ }, 100);
35841
+ }, n2.handleViewClick = function(t4) {
35842
+ setTimeout(function() {
35843
+ !n2.isUserInput && n2.enableGlobalClick && n2.nextStep();
35844
+ });
35845
+ }, n2.persistLog = function() {
35817
35846
  return XC(n2, void 0, void 0, function() {
35818
35847
  var t4, e5;
35819
35848
  return qC(this, function(n3) {
@@ -35909,7 +35938,7 @@ void main(void){
35909
35938
  n2.renderSlide(t4, e5);
35910
35939
  } else
35911
35940
  t4 === -1 && n2.renderSlide(n2.slideCount, true);
35912
- }, e4.timestamp && (n2.timestamp = e4.timestamp), n2.config = e4, n2.syncQueue = new zC(n2.receiveSyncHandler), n2.mode = e4.mode, n2.anchor = e4.anchor, n2.resize = e4.resize || false, n2.interactive = e4.interactive, n2.cacheImage.style.position = "absolute", n2.cacheImage.style.zIndex = "100", n2.frame.style.cssText = "width:100%;height:100%;display:flex;justify-content:center;align-items:center;visibility:hidden;position:relative;z-index:1;", n2.setMedianControllerAttribute(), n2.frame.appendChild(n2.medianController), n2.anchor.appendChild(n2.frame), n2.frameResizeObserver.observe(n2.frame), n2.on($C.syncReceive, function(t4) {
35941
+ }, e4.timestamp && (n2.timestamp = e4.timestamp), n2.config = e4, n2.syncQueue = new zC(n2.receiveSyncHandler), n2.mode = e4.mode, n2.anchor = e4.anchor, n2.enableGlobalClick = !Object(l.isUndefined)(e4.enableGlobalClick) && e4.enableGlobalClick, n2.resize = e4.resize || false, n2.interactive = e4.interactive, n2.cacheImage.style.position = "absolute", n2.cacheImage.style.zIndex = "100", n2.frame.style.cssText = "width:100%;height:100%;display:flex;justify-content:center;align-items:center;visibility:hidden;position:relative;z-index:1;", n2.setMedianControllerAttribute(), n2.frame.appendChild(n2.medianController), n2.anchor.appendChild(n2.frame), n2.frameResizeObserver.observe(n2.frame), n2.on($C.syncReceive, function(t4) {
35913
35942
  n2.lock.unlock(t4.type, t4.uuid), n2.syncQueue.addTask(t4);
35914
35943
  }), n2.renderingTaskManager.eventHub.on("task-error", function(t4) {
35915
35944
  var e5 = t4.error, i2 = t4.task;
@@ -35917,41 +35946,41 @@ void main(void){
35917
35946
  }), window.addEventListener("__slide_log__", n2.handleLogDownload), window.addEventListener("__slide_state__", n2.handleSlideStateLog), window.addEventListener("__slide_ref__", n2.handleSlideRef), n2.persistLogId = window.setInterval(n2.persistLog, 5e3), n2.resizeView = Object(l.debounce)(n2.resizeView.bind(n2), 50), n2.player = n2.initPlayer(e4), n2.player.view && n2.frame.appendChild(n2.player.view), n2;
35918
35947
  }
35919
35948
  return VC(e3, t3), e3.prototype.initPlayer = function(t4) {
35920
- var e4 = this, n2 = new jR(this.mode);
35921
- return n2.setInteractive(this.interactive), n2.updateConfig(t4.renderOptions || {}), n2.on(zR.renderStart, function(t5) {
35922
- e4.isLoading = true, e4.emit($C.renderStart, t5);
35923
- }), n2.on(zR.renderEnd, function(t5) {
35924
- e4.isLoading = false, e4.player && (e4.designHeight = e4.player.designHeight, e4.designWidth = e4.player.designWidth, e4.cacheImage.style.width = e4.player.designWidth + "px", e4.cacheImage.style.height = e4.player.designHeight + "px", e4._slideCount = e4.player.slideCount), e4.emit($C.renderEnd, t5);
35925
- }), n2.on(zR.slideChange, function(t5) {
35926
- e4.__slideState.currentSlideIndex = t5, e4.emit($C.slideChange, t5);
35927
- }), n2.on(zR.mainSeqStateChange, function(t5) {
35928
- e4.__slideState.mainSeqState = t5, e4.emitStateChange();
35929
- }), n2.on(zR.mainSeqStepChange, function(t5) {
35930
- e4.__slideState.mainSeqStep = t5, e4.emitStateChange();
35931
- }), n2.on(zR.interactiveSeqStateChange, function(t5) {
35932
- var n3 = t5.id, i2 = t5.state;
35933
- e4.__slideState.interactiveSeqState[n3] = i2, e4.emitStateChange();
35934
- }), n2.on(zR.animateStart, function() {
35935
- e4.isAnimating !== true && (e4.isAnimating = true, e4.emit($C.animateStart));
35936
- }), n2.on(zR.animateEnd, function() {
35937
- e4.isAnimating !== false && (e4.isAnimating = false, e4.emit($C.animateEnd));
35938
- }), n2.on(zR.interactiveSeqAction, function(t5) {
35939
- var n3 = t5.action, i2 = t5.seqId;
35940
- e4.emitSyncDispatch({ slideIndex: e4.__slideState.currentSlideIndex, type: "interactiveAnim", action: n3, seqId: i2 }), e4.emitStateChange();
35941
- }), n2.on(zR.mainSeqStepStart, function(t5) {
35942
- e4.emit($C.mainSeqStepStart, t5);
35943
- }), n2.on(zR.mainSeqStepEnd, function(t5) {
35944
- e4.emit($C.mainSeqStepEnd, t5);
35945
- }), n2.on(zR.mediaPlay, function(t5) {
35946
- var n3 = { type: "play", time: e4.timestamp() - 1e3 * t5.time };
35947
- e4.__slideState.mediaState[t5.id] = n3, e4.emitSyncDispatch({ slideIndex: e4.__slideState.currentSlideIndex, type: "mediaPlay", id: t5.id, state: n3 }), e4.emitStateChange();
35948
- }), n2.on(zR.mediaPause, function(t5) {
35949
- var n3 = { type: "pause", time: t5.time };
35950
- e4.__slideState.mediaState[t5.id] = n3, e4.emitSyncDispatch({ slideIndex: e4.__slideState.currentSlideIndex, type: "mediaPause", id: t5.id, state: n3 }), e4.emitStateChange();
35951
- }), n2.on(zR.mediaSeek, function(t5) {
35952
- var n3 = { type: "pause", time: 0 };
35953
- t5.isPlaying ? (n3.type = "play", e4.__slideState.mediaState[t5.id] ? n3.time = e4.__slideState.mediaState[t5.id].time - 1e3 * t5.time : n3.time = e4.timestamp() - 1e3 * t5.time, e4.__slideState.mediaState[t5.id] = n3) : (n3.type = "pause", n3.time = t5.time, e4.__slideState.mediaState[t5.id] = n3), e4.emitSyncDispatch({ slideIndex: e4.__slideState.currentSlideIndex, type: "mediaSeek", id: t5.id, time: t5.time, state: n3 }), e4.emitStateChange();
35954
- }), n2.on(zR.requestPrevSlide, this.handlePrevSlide), n2.on(zR.requestNextSlide, this.handleNextSlide), n2.on(zR.requestGotoSlide, this.handleGotoSlide), (t4 == null ? void 0 : t4.controller) && this.createController(), n2;
35949
+ var e4, n2 = this, i2 = new jR(this.mode);
35950
+ return i2.setInteractive(this.interactive), i2.updateConfig(t4.renderOptions || {}), i2.on(zR.renderStart, function(t5) {
35951
+ n2.isLoading = true, n2.emit($C.renderStart, t5);
35952
+ }), i2.on(zR.renderEnd, function(t5) {
35953
+ n2.isLoading = false, n2.player && (n2.designHeight = n2.player.designHeight, n2.designWidth = n2.player.designWidth, n2.cacheImage.style.width = n2.player.designWidth + "px", n2.cacheImage.style.height = n2.player.designHeight + "px", n2._slideCount = n2.player.slideCount), n2.emit($C.renderEnd, t5);
35954
+ }), i2.on(zR.slideChange, function(t5) {
35955
+ n2.__slideState.currentSlideIndex = t5, n2.emit($C.slideChange, t5);
35956
+ }), i2.on(zR.mainSeqStateChange, function(t5) {
35957
+ n2.__slideState.mainSeqState = t5, n2.emitStateChange();
35958
+ }), i2.on(zR.mainSeqStepChange, function(t5) {
35959
+ n2.__slideState.mainSeqStep = t5, n2.emitStateChange();
35960
+ }), i2.on(zR.interactiveSeqStateChange, function(t5) {
35961
+ var e5 = t5.id, i3 = t5.state;
35962
+ n2.__slideState.interactiveSeqState[e5] = i3, n2.emitStateChange();
35963
+ }), i2.on(zR.animateStart, function() {
35964
+ n2.isAnimating !== true && (n2.isAnimating = true, n2.emit($C.animateStart));
35965
+ }), i2.on(zR.animateEnd, function() {
35966
+ n2.isAnimating !== false && (n2.isAnimating = false, n2.emit($C.animateEnd));
35967
+ }), i2.on(zR.interactiveSeqAction, function(t5) {
35968
+ var e5 = t5.action, i3 = t5.seqId;
35969
+ n2.emitSyncDispatch({ slideIndex: n2.__slideState.currentSlideIndex, type: "interactiveAnim", action: e5, seqId: i3 }), n2.emitStateChange();
35970
+ }), i2.on(zR.mainSeqStepStart, function(t5) {
35971
+ n2.emit($C.mainSeqStepStart, t5);
35972
+ }), i2.on(zR.mainSeqStepEnd, function(t5) {
35973
+ n2.emit($C.mainSeqStepEnd, t5);
35974
+ }), i2.on(zR.mediaPlay, function(t5) {
35975
+ var e5 = { type: "play", time: n2.timestamp() - 1e3 * t5.time };
35976
+ n2.__slideState.mediaState[t5.id] = e5, n2.emitSyncDispatch({ slideIndex: n2.__slideState.currentSlideIndex, type: "mediaPlay", id: t5.id, state: e5 }), n2.emitStateChange();
35977
+ }), i2.on(zR.mediaPause, function(t5) {
35978
+ var e5 = { type: "pause", time: t5.time };
35979
+ n2.__slideState.mediaState[t5.id] = e5, n2.emitSyncDispatch({ slideIndex: n2.__slideState.currentSlideIndex, type: "mediaPause", id: t5.id, state: e5 }), n2.emitStateChange();
35980
+ }), i2.on(zR.mediaSeek, function(t5) {
35981
+ var e5 = { type: "pause", time: 0 };
35982
+ t5.isPlaying ? (e5.type = "play", n2.__slideState.mediaState[t5.id] ? e5.time = n2.__slideState.mediaState[t5.id].time - 1e3 * t5.time : e5.time = n2.timestamp() - 1e3 * t5.time, n2.__slideState.mediaState[t5.id] = e5) : (e5.type = "pause", e5.time = t5.time, n2.__slideState.mediaState[t5.id] = e5), n2.emitSyncDispatch({ slideIndex: n2.__slideState.currentSlideIndex, type: "mediaSeek", id: t5.id, time: t5.time, state: e5 }), n2.emitStateChange();
35983
+ }), i2.on(zR.requestPrevSlide, this.handlePrevSlide), i2.on(zR.requestNextSlide, this.handleNextSlide), i2.on(zR.requestGotoSlide, this.handleGotoSlide), (e4 = i2.view) === null || e4 === void 0 || e4.addEventListener("click", this.handleViewClick), i2.on(zR.userInput, this.userInputHandle), (t4 == null ? void 0 : t4.controller) && this.createController(), i2;
35955
35984
  }, e3.prototype.createController = function() {
35956
35985
  this.player && (this.playerController = new HC({ player: this.player, params: this.player.config || {}, target: this.frame }));
35957
35986
  }, e3.prototype.setMedianControllerAttribute = function() {
@@ -36817,6 +36846,7 @@ class SlideController {
36817
36846
  mode: "interactive",
36818
36847
  resize: true,
36819
36848
  controller: logger.enable,
36849
+ enableGlobalClick: true,
36820
36850
  renderOptions: {
36821
36851
  minFPS: 25,
36822
36852
  maxFPS: 30,
@@ -38051,6 +38081,7 @@ class SlidePreviewer {
38051
38081
  mode: "local",
38052
38082
  resize: true,
38053
38083
  controller: this.debug,
38084
+ enableGlobalClick: true,
38054
38085
  renderOptions: {
38055
38086
  minFPS: 25,
38056
38087
  maxFPS: 30,
@@ -38106,7 +38137,7 @@ class SlidePreviewer {
38106
38137
  return `${this.namespace}-${className}`;
38107
38138
  }
38108
38139
  }
38109
- const version = "0.0.54";
38140
+ const version = "0.0.55";
38110
38141
  const SlideApp = {
38111
38142
  kind: "Slide",
38112
38143
  setup(context) {