fiv out of sync speaker view after presentation reloads #2822 #3032

This commit is contained in:
hakimel committed 2022-02-10 13:28:47 +01:00
1 parent 6b535328c0
commit ff20051861
4 files changed
+174 -121

No files matched your search

+1 -1
View File
@@ -1 +1 @@
var t="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},e=function(t){return t&&t.Math==Math&&t},n=e("object"==typeof globalThis&&globalThis)||e("object"==typeof window&&window)||e("object"==typeof self&&self)||e("object"==typeof t&&t)||function(){return this}()||Function("return this")(),r={},u=function(t){try{return!!t()}catch(t){return!0}},i=!u((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]})),a={},o={}.propertyIsEnumerable,l=Object.getOwnPropertyDescriptor,s=l&&!o.call({1:2},1);a.f=s?function(t){var e=l(this,t);return!!e&&e.enumerable}:o;var c=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}},p={}.toString,d=function(t){return p.call(t).slice(8,-1)},f=d,h="".split,g=u((function(){return!Object("z").propertyIsEnumerable(0)}))?function(t){return"String"==f(t)?h.call(t,""):Object(t)}:Object,D=function(t){if(null==t)throw TypeError("Can't call method on "+t);return t},m=g,v=D,y=function(t){return m(v(t))},k=function(t){return"object"==typeof t?null!==t:"function"==typeof t},A=k,E=function(t,e){if(!A(t))return t;var n,r;if(e&&"function"==typeof(n=t.toString)&&!A(r=n.call(t)))return r;if("function"==typeof(n=t.valueOf)&&!A(r=n.call(t)))return r;if(!e&&"function"==typeof(n=t.toString)&&!A(r=n.call(t)))return r;throw TypeError("Can't convert object to primitive value")},b=D,F=function(t){return Object(b(t))},C=F,x={}.hasOwnProperty,w=function(t,e){return x.call(C(t),e)},S=k,B=n.document,_=S(B)&&S(B.createElement),T=function(t){return _?B.createElement(t):{}},z=T,I=!i&&!u((function(){return 7!=Object.defineProperty(z("div"),"a",{get:function(){return 7}}).a})),R=i,$=a,O=c,P=y,L=E,j=w,M=I,N=Object.getOwnPropertyDescriptor;r.f=R?N:function(t,e){if(t=P(t),e=L(e,!0),M)try{return N(t,e)}catch(t){}if(j(t,e))return O(!$.f.call(t,e),t[e])};var U={},q=k,Z=function(t){if(!q(t))throw TypeError(String(t)+" is not an object");return t},K=i,J=I,H=Z,W=E,Y=Object.defineProperty;U.f=K?Y:function(t,e,n){if(H(t),e=W(e,!0),H(n),J)try{return Y(t,e,n)}catch(t){}if("get"in n||"set"in n)throw TypeError("Accessors not supported");return"value"in n&&(t[e]=n.value),t};var V=U,X=c,G=i?function(t,e,n){return V.f(t,e,X(1,n))}:function(t,e,n){return t[e]=n,t},Q={exports:{}},tt=n,et=G,nt=function(t,e){try{et(tt,t,e)}catch(n){tt[t]=e}return e},rt=nt,ut=n["__core-js_shared__"]||rt("__core-js_shared__",{}),it=ut,at=Function.toString;"function"!=typeof it.inspectSource&&(it.inspectSource=function(t){return at.call(t)});var ot=it.inspectSource,lt=ot,st=n.WeakMap,ct="function"==typeof st&&/native code/.test(lt(st)),pt={exports:{}},dt=ut;(pt.exports=function(t,e){return dt[t]||(dt[t]=void 0!==e?e:{})})("versions",[]).push({version:"3.12.1",mode:"global",copyright:"© 2021 Denis Pushkarev (zloirock.ru)"});var ft,ht,gt,Dt=0,mt=Math.random(),vt=function(t){return"Symbol("+String(void 0===t?"":t)+")_"+(++Dt+mt).toString(36)},yt=pt.exports,kt=vt,At=yt("keys"),Et=function(t){return At[t]||(At[t]=kt(t))},bt={},Ft=ct,Ct=k,xt=G,wt=w,St=ut,Bt=Et,_t=bt,Tt=n.WeakMap;if(Ft||St.state){var zt=St.state||(St.state=new Tt),It=zt.get,Rt=zt.has,$t=zt.set;ft=function(t,e){if(Rt.call(zt,t))throw new TypeError("Object already initialized");return e.facade=t,$t.call(zt,t,e),e},ht=function(t){return It.call(zt,t)||{}},gt=function(t){return Rt.call(zt,t)}}else{var Ot=Bt("state");_t[Ot]=!0,ft=function(t,e){if(wt(t,Ot))throw new TypeError("Object already initialized");return e.facade=t,xt(t,Ot,e),e},ht=function(t){return wt(t,Ot)?t[Ot]:{}},gt=function(t){return wt(t,Ot)}}var Pt={set:ft,get:ht,has:gt,enforce:function(t){return gt(t)?ht(t):ft(t,{})},getterFor:function(t){return function(e){var n;if(!Ct(e)||(n=ht(e)).type!==t)throw TypeError("Incompatible receiver, "+t+" required");return n}}},Lt=n,jt=G,Mt=w,Nt=nt,Ut=ot,qt=Pt.get,Zt=Pt.enforce,Kt=String(String).split("String");(Q.exports=function(t,e,n,r){var u,i=!!r&&!!r.unsafe,a=!!r&&!!r.enumerable,o=!!r&&!!r.noTargetGet;"function"==typeof n&&("string"!=typeof e||Mt(n,"name")||jt(n,"name",e),(u=Zt(n)).source||(u.source=Kt.join("string"==typeof e?e:""))),t!==Lt?(i?!o&&t[e]&&(a=!0):delete t[e],a?t[e]=n:jt(t,e,n)):a?t[e]=n:Nt(e,n)})(Function.prototype,"toString",(function(){return"function"==typeof this&&qt(this).source||Ut(this)}));var Jt=n,Ht=n,Wt=function(t){return"function"==typeof t?t:void 0},Yt=function(t,e){return arguments.length<2?Wt(Jt[t])||Wt(Ht[t]):Jt[t]&&Jt[t][e]||Ht[t]&&Ht[t][e]},Vt={},Xt=Math.ceil,Gt=Math.floor,Qt=function(t){return isNaN(t=+t)?0:(t>0?Gt:Xt)(t)},te=Qt,ee=Math.min,ne=function(t){return t>0?ee(te(t),9007199254740991):0},re=Qt,ue=Math.max,ie=Math.min,ae=function(t,e){var n=re(t);return n<0?ue(n+e,0):ie(n,e)},oe=y,le=ne,se=ae,ce=function(t){return function(e,n,r){var u,i=oe(e),a=le(i.length),o=se(r,a);if(t&&n!=n){for(;a>o;)if((u=i[o++])!=u)return!0}else for(;a>o;o++)if((t||o in i)&&i[o]===n)return t||o||0;return!t&&-1}},pe={includes:ce(!0),indexLine truncated
var t="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},e=function(t){return t&&t.Math==Math&&t},n=e("object"==typeof globalThis&&globalThis)||e("object"==typeof window&&window)||e("object"==typeof self&&self)||e("object"==typeof t&&t)||function(){return this}()||Function("return this")(),r={},u=function(t){try{return!!t()}catch(t){return!0}},i=!u((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]})),a={},o={}.propertyIsEnumerable,l=Object.getOwnPropertyDescriptor,s=l&&!o.call({1:2},1);a.f=s?function(t){var e=l(this,t);return!!e&&e.enumerable}:o;var c=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}},p={}.toString,d=function(t){return p.call(t).slice(8,-1)},f=d,h="".split,g=u((function(){return!Object("z").propertyIsEnumerable(0)}))?function(t){return"String"==f(t)?h.call(t,""):Object(t)}:Object,D=function(t){if(null==t)throw TypeError("Can't call method on "+t);return t},m=g,v=D,y=function(t){return m(v(t))},k=function(t){return"object"==typeof t?null!==t:"function"==typeof t},A=k,E=function(t,e){if(!A(t))return t;var n,r;if(e&&"function"==typeof(n=t.toString)&&!A(r=n.call(t)))return r;if("function"==typeof(n=t.valueOf)&&!A(r=n.call(t)))return r;if(!e&&"function"==typeof(n=t.toString)&&!A(r=n.call(t)))return r;throw TypeError("Can't convert object to primitive value")},b=D,F=function(t){return Object(b(t))},C=F,x={}.hasOwnProperty,w=function(t,e){return x.call(C(t),e)},S=k,B=n.document,_=S(B)&&S(B.createElement),T=function(t){return _?B.createElement(t):{}},z=T,I=!i&&!u((function(){return 7!=Object.defineProperty(z("div"),"a",{get:function(){return 7}}).a})),R=i,O=a,$=c,L=y,P=E,j=w,M=I,N=Object.getOwnPropertyDescriptor;r.f=R?N:function(t,e){if(t=L(t),e=P(e,!0),M)try{return N(t,e)}catch(t){}if(j(t,e))return $(!O.f.call(t,e),t[e])};var U={},q=k,Z=function(t){if(!q(t))throw TypeError(String(t)+" is not an object");return t},J=i,K=I,H=Z,W=E,Y=Object.defineProperty;U.f=J?Y:function(t,e,n){if(H(t),e=W(e,!0),H(n),K)try{return Y(t,e,n)}catch(t){}if("get"in n||"set"in n)throw TypeError("Accessors not supported");return"value"in n&&(t[e]=n.value),t};var V=U,X=c,G=i?function(t,e,n){return V.f(t,e,X(1,n))}:function(t,e,n){return t[e]=n,t},Q={exports:{}},tt=n,et=G,nt=function(t,e){try{et(tt,t,e)}catch(n){tt[t]=e}return e},rt=nt,ut=n["__core-js_shared__"]||rt("__core-js_shared__",{}),it=ut,at=Function.toString;"function"!=typeof it.inspectSource&&(it.inspectSource=function(t){return at.call(t)});var ot=it.inspectSource,lt=ot,st=n.WeakMap,ct="function"==typeof st&&/native code/.test(lt(st)),pt={exports:{}},dt=ut;(pt.exports=function(t,e){return dt[t]||(dt[t]=void 0!==e?e:{})})("versions",[]).push({version:"3.12.1",mode:"global",copyright:"© 2021 Denis Pushkarev (zloirock.ru)"});var ft,ht,gt,Dt=0,mt=Math.random(),vt=function(t){return"Symbol("+String(void 0===t?"":t)+")_"+(++Dt+mt).toString(36)},yt=pt.exports,kt=vt,At=yt("keys"),Et=function(t){return At[t]||(At[t]=kt(t))},bt={},Ft=ct,Ct=k,xt=G,wt=w,St=ut,Bt=Et,_t=bt,Tt=n.WeakMap;if(Ft||St.state){var zt=St.state||(St.state=new Tt),It=zt.get,Rt=zt.has,Ot=zt.set;ft=function(t,e){if(Rt.call(zt,t))throw new TypeError("Object already initialized");return e.facade=t,Ot.call(zt,t,e),e},ht=function(t){return It.call(zt,t)||{}},gt=function(t){return Rt.call(zt,t)}}else{var $t=Bt("state");_t[$t]=!0,ft=function(t,e){if(wt(t,$t))throw new TypeError("Object already initialized");return e.facade=t,xt(t,$t,e),e},ht=function(t){return wt(t,$t)?t[$t]:{}},gt=function(t){return wt(t,$t)}}var Lt={set:ft,get:ht,has:gt,enforce:function(t){return gt(t)?ht(t):ft(t,{})},getterFor:function(t){return function(e){var n;if(!Ct(e)||(n=ht(e)).type!==t)throw TypeError("Incompatible receiver, "+t+" required");return n}}},Pt=n,jt=G,Mt=w,Nt=nt,Ut=ot,qt=Lt.get,Zt=Lt.enforce,Jt=String(String).split("String");(Q.exports=function(t,e,n,r){var u,i=!!r&&!!r.unsafe,a=!!r&&!!r.enumerable,o=!!r&&!!r.noTargetGet;"function"==typeof n&&("string"!=typeof e||Mt(n,"name")||jt(n,"name",e),(u=Zt(n)).source||(u.source=Jt.join("string"==typeof e?e:""))),t!==Pt?(i?!o&&t[e]&&(a=!0):delete t[e],a?t[e]=n:jt(t,e,n)):a?t[e]=n:Nt(e,n)})(Function.prototype,"toString",(function(){return"function"==typeof this&&qt(this).source||Ut(this)}));var Kt=n,Ht=n,Wt=function(t){return"function"==typeof t?t:void 0},Yt=function(t,e){return arguments.length<2?Wt(Kt[t])||Wt(Ht[t]):Kt[t]&&Kt[t][e]||Ht[t]&&Ht[t][e]},Vt={},Xt=Math.ceil,Gt=Math.floor,Qt=function(t){return isNaN(t=+t)?0:(t>0?Gt:Xt)(t)},te=Qt,ee=Math.min,ne=function(t){return t>0?ee(te(t),9007199254740991):0},re=Qt,ue=Math.max,ie=Math.min,ae=function(t,e){var n=re(t);return n<0?ue(n+e,0):ie(n,e)},oe=y,le=ne,se=ae,ce=function(t){return function(e,n,r){var u,i=oe(e),a=le(i.length),o=se(r,a);if(t&&n!=n){for(;a>o;)if((u=i[o++])!=u)return!0}else for(;a>o;o++)if((t||o in i)&&i[o]===n)return t||o||0;return!t&&-1}},pe={includes:ce(!0),indexLine truncated
+1 -1
View File
@@ -1 +1 @@
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t="undefined"!=typeof globalThis?globalThis:t||self).RevealNotes=e()}(this,(function(){"use strict";var t="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},e=function(t){return t&&t.Math==Math&&t},n=e("object"==typeof globalThis&&globalThis)||e("object"==typeof window&&window)||e("object"==typeof self&&self)||e("object"==typeof t&&t)||function(){return this}()||Function("return this")(),r={},u=function(t){try{return!!t()}catch(t){return!0}},i=!u((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]})),a={},o={}.propertyIsEnumerable,l=Object.getOwnPropertyDescriptor,s=l&&!o.call({1:2},1);a.f=s?function(t){var e=l(this,t);return!!e&&e.enumerable}:o;var c=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}},p={}.toString,d=function(t){return p.call(t).slice(8,-1)},f=d,h="".split,g=u((function(){return!Object("z").propertyIsEnumerable(0)}))?function(t){return"String"==f(t)?h.call(t,""):Object(t)}:Object,D=function(t){if(null==t)throw TypeError("Can't call method on "+t);return t},m=g,v=D,y=function(t){return m(v(t))},k=function(t){return"object"==typeof t?null!==t:"function"==typeof t},A=k,E=function(t,e){if(!A(t))return t;var n,r;if(e&&"function"==typeof(n=t.toString)&&!A(r=n.call(t)))return r;if("function"==typeof(n=t.valueOf)&&!A(r=n.call(t)))return r;if(!e&&"function"==typeof(n=t.toString)&&!A(r=n.call(t)))return r;throw TypeError("Can't convert object to primitive value")},b=D,F=function(t){return Object(b(t))},C=F,x={}.hasOwnProperty,w=function(t,e){return x.call(C(t),e)},S=k,B=n.document,T=S(B)&&S(B.createElement),_=function(t){return T?B.createElement(t):{}},z=_,I=!i&&!u((function(){return 7!=Object.defineProperty(z("div"),"a",{get:function(){return 7}}).a})),R=i,$=a,O=c,P=y,L=E,j=w,M=I,N=Object.getOwnPropertyDescriptor;r.f=R?N:function(t,e){if(t=P(t),e=L(e,!0),M)try{return N(t,e)}catch(t){}if(j(t,e))return O(!$.f.call(t,e),t[e])};var U={},q=k,Z=function(t){if(!q(t))throw TypeError(String(t)+" is not an object");return t},K=i,J=I,H=Z,W=E,Y=Object.defineProperty;U.f=K?Y:function(t,e,n){if(H(t),e=W(e,!0),H(n),J)try{return Y(t,e,n)}catch(t){}if("get"in n||"set"in n)throw TypeError("Accessors not supported");return"value"in n&&(t[e]=n.value),t};var V=U,X=c,G=i?function(t,e,n){return V.f(t,e,X(1,n))}:function(t,e,n){return t[e]=n,t},Q={exports:{}},tt=n,et=G,nt=function(t,e){try{et(tt,t,e)}catch(n){tt[t]=e}return e},rt=nt,ut="__core-js_shared__",it=n[ut]||rt(ut,{}),at=it,ot=Function.toString;"function"!=typeof at.inspectSource&&(at.inspectSource=function(t){return ot.call(t)});var lt=at.inspectSource,st=lt,ct=n.WeakMap,pt="function"==typeof ct&&/native code/.test(st(ct)),dt={exports:{}},ft=it;(dt.exports=function(t,e){return ft[t]||(ft[t]=void 0!==e?e:{})})("versions",[]).push({version:"3.12.1",mode:"global",copyright:"© 2021 Denis Pushkarev (zloirock.ru)"});var ht,gt,Dt,mt=0,vt=Math.random(),yt=function(t){return"Symbol("+String(void 0===t?"":t)+")_"+(++mt+vt).toString(36)},kt=dt.exports,At=yt,Et=kt("keys"),bt=function(t){return Et[t]||(Et[t]=At(t))},Ft={},Ct=pt,xt=k,wt=G,St=w,Bt=it,Tt=bt,_t=Ft,zt="Object already initialized",It=n.WeakMap;if(Ct||Bt.state){var Rt=Bt.state||(Bt.state=new It),$t=Rt.get,Ot=Rt.has,Pt=Rt.set;ht=function(t,e){if(Ot.call(Rt,t))throw new TypeError(zt);return e.facade=t,Pt.call(Rt,t,e),e},gt=function(t){return $t.call(Rt,t)||{}},Dt=function(t){return Ot.call(Rt,t)}}else{var Lt=Tt("state");_t[Lt]=!0,ht=function(t,e){if(St(t,Lt))throw new TypeError(zt);return e.facade=t,wt(t,Lt,e),e},gt=function(t){return St(t,Lt)?t[Lt]:{}},Dt=function(t){return St(t,Lt)}}var jt={set:ht,get:gt,has:Dt,enforce:function(t){return Dt(t)?gt(t):ht(t,{})},getterFor:function(t){return function(e){var n;if(!xt(e)||(n=gt(e)).type!==t)throw TypeError("Incompatible receiver, "+t+" required");return n}}},Mt=n,Nt=G,Ut=w,qt=nt,Zt=lt,Kt=jt.get,Jt=jt.enforce,Ht=String(String).split("String");(Q.exports=function(t,e,n,r){var u,i=!!r&&!!r.unsafe,a=!!r&&!!r.enumerable,o=!!r&&!!r.noTargetGet;"function"==typeof n&&("string"!=typeof e||Ut(n,"name")||Nt(n,"name",e),(u=Jt(n)).source||(u.source=Ht.join("string"==typeof e?e:""))),t!==Mt?(i?!o&&t[e]&&(a=!0):delete t[e],a?t[e]=n:Nt(t,e,n)):a?t[e]=n:qt(e,n)})(Function.prototype,"toString",(function(){return"function"==typeof this&&Kt(this).source||Zt(this)}));var Wt=n,Yt=n,Vt=function(t){return"function"==typeof t?t:void 0},Xt=function(t,e){return arguments.length<2?Vt(Wt[t])||Vt(Yt[t]):Wt[t]&&Wt[t][e]||Yt[t]&&Yt[t][e]},Gt={},Qt=Math.ceil,te=Math.floor,ee=function(t){return isNaN(t=+t)?0:(t>0?te:Qt)(t)},ne=ee,re=Math.min,ue=function(t){return t>0?re(ne(t),9007199254740991):0},ie=ee,ae=Math.max,oe=Math.min,le=function(t,e){var n=ie(t);return n<0?ae(n+e,0):oe(n,e)},se=y,ce=ue,pe=le,de=function(t){retuLine truncated
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t="undefined"!=typeof globalThis?globalThis:t||self).RevealNotes=e()}(this,(function(){"use strict";var t="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},e=function(t){return t&&t.Math==Math&&t},n=e("object"==typeof globalThis&&globalThis)||e("object"==typeof window&&window)||e("object"==typeof self&&self)||e("object"==typeof t&&t)||function(){return this}()||Function("return this")(),r={},u=function(t){try{return!!t()}catch(t){return!0}},i=!u((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]})),a={},o={}.propertyIsEnumerable,l=Object.getOwnPropertyDescriptor,s=l&&!o.call({1:2},1);a.f=s?function(t){var e=l(this,t);return!!e&&e.enumerable}:o;var c=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}},p={}.toString,d=function(t){return p.call(t).slice(8,-1)},f=d,h="".split,g=u((function(){return!Object("z").propertyIsEnumerable(0)}))?function(t){return"String"==f(t)?h.call(t,""):Object(t)}:Object,D=function(t){if(null==t)throw TypeError("Can't call method on "+t);return t},m=g,v=D,y=function(t){return m(v(t))},k=function(t){return"object"==typeof t?null!==t:"function"==typeof t},A=k,E=function(t,e){if(!A(t))return t;var n,r;if(e&&"function"==typeof(n=t.toString)&&!A(r=n.call(t)))return r;if("function"==typeof(n=t.valueOf)&&!A(r=n.call(t)))return r;if(!e&&"function"==typeof(n=t.toString)&&!A(r=n.call(t)))return r;throw TypeError("Can't convert object to primitive value")},b=D,F=function(t){return Object(b(t))},C=F,x={}.hasOwnProperty,w=function(t,e){return x.call(C(t),e)},S=k,B=n.document,T=S(B)&&S(B.createElement),_=function(t){return T?B.createElement(t):{}},z=_,I=!i&&!u((function(){return 7!=Object.defineProperty(z("div"),"a",{get:function(){return 7}}).a})),R=i,$=a,O=c,L=y,P=E,j=w,M=I,N=Object.getOwnPropertyDescriptor;r.f=R?N:function(t,e){if(t=L(t),e=P(e,!0),M)try{return N(t,e)}catch(t){}if(j(t,e))return O(!$.f.call(t,e),t[e])};var U={},q=k,Z=function(t){if(!q(t))throw TypeError(String(t)+" is not an object");return t},J=i,K=I,H=Z,W=E,Y=Object.defineProperty;U.f=J?Y:function(t,e,n){if(H(t),e=W(e,!0),H(n),K)try{return Y(t,e,n)}catch(t){}if("get"in n||"set"in n)throw TypeError("Accessors not supported");return"value"in n&&(t[e]=n.value),t};var V=U,X=c,G=i?function(t,e,n){return V.f(t,e,X(1,n))}:function(t,e,n){return t[e]=n,t},Q={exports:{}},tt=n,et=G,nt=function(t,e){try{et(tt,t,e)}catch(n){tt[t]=e}return e},rt=nt,ut="__core-js_shared__",it=n[ut]||rt(ut,{}),at=it,ot=Function.toString;"function"!=typeof at.inspectSource&&(at.inspectSource=function(t){return ot.call(t)});var lt=at.inspectSource,st=lt,ct=n.WeakMap,pt="function"==typeof ct&&/native code/.test(st(ct)),dt={exports:{}},ft=it;(dt.exports=function(t,e){return ft[t]||(ft[t]=void 0!==e?e:{})})("versions",[]).push({version:"3.12.1",mode:"global",copyright:"© 2021 Denis Pushkarev (zloirock.ru)"});var ht,gt,Dt,mt=0,vt=Math.random(),yt=function(t){return"Symbol("+String(void 0===t?"":t)+")_"+(++mt+vt).toString(36)},kt=dt.exports,At=yt,Et=kt("keys"),bt=function(t){return Et[t]||(Et[t]=At(t))},Ft={},Ct=pt,xt=k,wt=G,St=w,Bt=it,Tt=bt,_t=Ft,zt="Object already initialized",It=n.WeakMap;if(Ct||Bt.state){var Rt=Bt.state||(Bt.state=new It),$t=Rt.get,Ot=Rt.has,Lt=Rt.set;ht=function(t,e){if(Ot.call(Rt,t))throw new TypeError(zt);return e.facade=t,Lt.call(Rt,t,e),e},gt=function(t){return $t.call(Rt,t)||{}},Dt=function(t){return Ot.call(Rt,t)}}else{var Pt=Tt("state");_t[Pt]=!0,ht=function(t,e){if(St(t,Pt))throw new TypeError(zt);return e.facade=t,wt(t,Pt,e),e},gt=function(t){return St(t,Pt)?t[Pt]:{}},Dt=function(t){return St(t,Pt)}}var jt={set:ht,get:gt,has:Dt,enforce:function(t){return Dt(t)?gt(t):ht(t,{})},getterFor:function(t){return function(e){var n;if(!xt(e)||(n=gt(e)).type!==t)throw TypeError("Incompatible receiver, "+t+" required");return n}}},Mt=n,Nt=G,Ut=w,qt=nt,Zt=lt,Jt=jt.get,Kt=jt.enforce,Ht=String(String).split("String");(Q.exports=function(t,e,n,r){var u,i=!!r&&!!r.unsafe,a=!!r&&!!r.enumerable,o=!!r&&!!r.noTargetGet;"function"==typeof n&&("string"!=typeof e||Ut(n,"name")||Nt(n,"name",e),(u=Kt(n)).source||(u.source=Ht.join("string"==typeof e?e:""))),t!==Mt?(i?!o&&t[e]&&(a=!0):delete t[e],a?t[e]=n:Nt(t,e,n)):a?t[e]=n:qt(e,n)})(Function.prototype,"toString",(function(){return"function"==typeof this&&Jt(this).source||Zt(this)}));var Wt=n,Yt=n,Vt=function(t){return"function"==typeof t?t:void 0},Xt=function(t,e){return arguments.length<2?Vt(Wt[t])||Vt(Yt[t]):Wt[t]&&Wt[t][e]||Yt[t]&&Yt[t][e]},Gt={},Qt=Math.ceil,te=Math.floor,ee=function(t){return isNaN(t=+t)?0:(t>0?te:Qt)(t)},ne=ee,re=Math.min,ue=function(t){return t>0?re(ne(t),9007199254740991):0},ie=ee,ae=Math.max,oe=Math.min,le=function(t,e){var n=ie(t);return n<0?ae(n+e,0):oe(n,e)},se=y,ce=ue,pe=le,de=function(t){retuLine truncated
+159 -119
View File
@@ -15,141 +15,167 @@ import marked from 'marked';
*/
const Plugin = () => {
let popup = null;
let connectInterval;
let speakerWindow = null;
let deck;
let deck;
/**
* Opens a new speaker view window.
*/
function openSpeakerWindow() {
function openNotes() {
// If a window is already open, focus it
if( speakerWindow && !speakerWindow.closed ) {
speakerWindow.focus();
}
else {
speakerWindow = window.open( 'about:blank', 'reveal.js - Notes', 'width=1100,height=700' );
speakerWindow.marked = marked;
speakerWindow.document.write( speakerViewHTML );
if (popup && !popup.closed) {
popup.focus();
return;
}
if( !speakerWindow ) {
alert( 'Speaker view popup failed to open. Please make sure popups are allowed and reopen the speaker view.' );
return;
}
popup = window.open( 'about:blank', 'reveal.js - Notes', 'width=1100,height=700' );
popup.marked = marked;
popup.document.write( speakerViewHTML );
if( !popup ) {
alert( 'Speaker view popup failed to open. Please make sure popups are allowed and reopen the speaker view.' );
return;
connect();
}
/**
* Connect to the notes window through a postmessage handshake.
* Using postmessage enables us to work in situations where the
* origins differ, such as a presentation being opened from the
* file system.
*/
function connect() {
// Keep trying to connect until we get a 'connected' message back
let connectInterval = setInterval( function() {
popup.postMessage( JSON.stringify( {
namespace: 'reveal-notes',
type: 'connect',
url: window.location.protocol + '//' + window.location.host + window.location.pathname + window.location.search,
state: deck.getState()
} ), '*' );
}, 500 );
}
window.addEventListener( 'message', function( event ) {
let data = JSON.parse( event.data );
if( data && data.namespace === 'reveal-notes' && data.type === 'connected' ) {
clearInterval( connectInterval );
onConnected();
}
if( data && data.namespace === 'reveal-notes' && data.type === 'call' ) {
callRevealApi( data.methodName, data.arguments, data.callId );
}
} );
/**
* Reconnect with an existing speaker view window.
*/
function reconnectSpeakerWindow( reconnectWindow ) {
if( speakerWindow && !speakerWindow.closed ) {
speakerWindow.focus();
}
else {
speakerWindow = reconnectWindow;
window.addEventListener( 'message', onPostMessage );
onConnected();
}
/**
* Calls the specified Reveal.js method with the provided argument
* and then pushes the result to the notes frame.
*/
function callRevealApi( methodName, methodArguments, callId ) {
}
let result = deck[methodName].apply( deck, methodArguments );
popup.postMessage( JSON.stringify( {
/**
* Connect to the notes window through a postmessage handshake.
* Using postmessage enables us to work in situations where the
* origins differ, such as a presentation being opened from the
* file system.
*/
function connect() {
// Keep trying to connect until we get a 'connected' message back
connectInterval = setInterval( function() {
speakerWindow.postMessage( JSON.stringify( {
namespace: 'reveal-notes',
type: 'return',
result: result,
callId: callId
} ), '*' );
}
/**
* Posts the current slide data to the notes window
*/
function post( event ) {
let slideElement = deck.getCurrentSlide(),
notesElement = slideElement.querySelector( 'aside.notes' ),
fragmentElement = slideElement.querySelector( '.current-fragment' );
let messageData = {
namespace: 'reveal-notes',
type: 'state',
notes: '',
markdown: false,
whitespace: 'normal',
type: 'connect',
url: window.location.protocol + '//' + window.location.host + window.location.pathname + window.location.search,
state: deck.getState()
};
} ), '*' );
}, 500 );
// Look for notes defined in a slide attribute
if( slideElement.hasAttribute( 'data-notes' ) ) {
messageData.notes = slideElement.getAttribute( 'data-notes' );
window.addEventListener( 'message', onPostMessage );
}
/**
* Calls the specified Reveal.js method with the provided argument
* and then pushes the result to the notes frame.
*/
function callRevealApi( methodName, methodArguments, callId ) {
let result = deck[methodName].apply( deck, methodArguments );
speakerWindow.postMessage( JSON.stringify( {
namespace: 'reveal-notes',
type: 'return',
result,
callId
} ), '*' );
}
/**
* Posts the current slide data to the notes window.
*/
function post( event ) {
let slideElement = deck.getCurrentSlide(),
notesElement = slideElement.querySelector( 'aside.notes' ),
fragmentElement = slideElement.querySelector( '.current-fragment' );
let messageData = {
namespace: 'reveal-notes',
type: 'state',
notes: '',
markdown: false,
whitespace: 'normal',
state: deck.getState()
};
// Look for notes defined in a slide attribute
if( slideElement.hasAttribute( 'data-notes' ) ) {
messageData.notes = slideElement.getAttribute( 'data-notes' );
messageData.whitespace = 'pre-wrap';
}
// Look for notes defined in a fragment
if( fragmentElement ) {
let fragmentNotes = fragmentElement.querySelector( 'aside.notes' );
if( fragmentNotes ) {
notesElement = fragmentNotes;
}
else if( fragmentElement.hasAttribute( 'data-notes' ) ) {
messageData.notes = fragmentElement.getAttribute( 'data-notes' );
messageData.whitespace = 'pre-wrap';
// In case there are slide notes
notesElement = null;
}
// Look for notes defined in a fragment
if( fragmentElement ) {
let fragmentNotes = fragmentElement.querySelector( 'aside.notes' );
if( fragmentNotes ) {
notesElement = fragmentNotes;
}
else if( fragmentElement.hasAttribute( 'data-notes' ) ) {
messageData.notes = fragmentElement.getAttribute( 'data-notes' );
messageData.whitespace = 'pre-wrap';
// In case there are slide notes
notesElement = null;
}
}
// Look for notes defined in an aside element
if( notesElement ) {
messageData.notes = notesElement.innerHTML;
messageData.markdown = typeof notesElement.getAttribute( 'data-markdown' ) === 'string';
}
popup.postMessage( JSON.stringify( messageData ), '*' );
}
/**
* Called once we have established a connection to the notes
* window.
*/
function onConnected() {
// Monitor events that trigger a change in state
deck.on( 'slidechanged', post );
deck.on( 'fragmentshown', post );
deck.on( 'fragmenthidden', post );
deck.on( 'overviewhidden', post );
deck.on( 'overviewshown', post );
deck.on( 'paused', post );
deck.on( 'resumed', post );
// Post the initial state
post();
// Look for notes defined in an aside element
if( notesElement ) {
messageData.notes = notesElement.innerHTML;
messageData.markdown = typeof notesElement.getAttribute( 'data-markdown' ) === 'string';
}
connect();
speakerWindow.postMessage( JSON.stringify( messageData ), '*' );
}
function onPostMessage( event ) {
let data = JSON.parse( event.data );
if( data && data.namespace === 'reveal-notes' && data.type === 'connected' ) {
clearInterval( connectInterval );
onConnected();
}
else if( data && data.namespace === 'reveal-notes' && data.type === 'call' ) {
callRevealApi( data.methodName, data.arguments, data.callId );
}
}
/**
* Called once we have established a connection to the notes
* window.
*/
function onConnected() {
// Monitor events that trigger a change in state
deck.on( 'slidechanged', post );
deck.on( 'fragmentshown', post );
deck.on( 'fragmenthidden', post );
deck.on( 'overviewhidden', post );
deck.on( 'overviewshown', post );
deck.on( 'paused', post );
deck.on( 'resumed', post );
// Post the initial state
post();
}
@@ -164,19 +190,33 @@ const Plugin = () => {
// If the there's a 'notes' query set, open directly
if( window.location.search.match( /(\?|\&)notes/gi ) !== null ) {
openNotes();
openSpeakerWindow();
}
else {
// Keep listening for speaker view hearbeats. If we receive a
// heartbeat from an orphaned window, reconnect it. This ensures
// that we remain connected to the notes even if the presentation
// is reloaded.
window.addEventListener( 'message', event => {
if( !speakerWindow ) {
let data = JSON.parse( event.data );
if( data && data.namespace === 'reveal-notes' && data.type === 'heartbeat' ) {
reconnectSpeakerWindow( event.source );
}
}
});
}
// Open the notes when the 's' key is hit
deck.addKeyBinding({keyCode: 83, key: 'S', description: 'Speaker notes view'}, function() {
openNotes();
openSpeakerWindow();
} );
}
},
open: openNotes
open: openSpeakerWindow
};
};
+13
View File
@@ -435,6 +435,7 @@
setupKeyboard();
setupNotes();
setupTimer();
setupHeartbeat();
}
}
@@ -536,6 +537,18 @@
}
/**
* We send out a heartbeat at all times to ensure we can
* reconnect with the main presentation window after reloads.
*/
function setupHeartbeat() {
setInterval( () => {
window.opener.postMessage( JSON.stringify({ namespace: 'reveal-notes', type: 'heartbeat'} ), '*' );
}, 1000 );
}
function getTimings( callback ) {
callRevealApi( 'getSlidesAttributes', [], function ( slideAttributes ) {