@googleworkspace/meet-addons 0.8.0-653010203 → 0.8.0-653364875
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/meet.addons.js +4 -4
- package/package.json +1 -1
package/meet.addons.js
CHANGED
|
@@ -33,9 +33,9 @@ ed={errorType:"NeedsMainStageContext",message:"This method can only be invoked i
|
|
|
33
33
|
message:"This method is not supported in standalone mode.",g:"Do not call this method in standalone mode."},hd={errorType:"InternalError",message:"The frame type URL parameter is set to an unexpected value.",g:"This parameter is automatically appended by Meet to the iframe URL. Ensure that your infrastructure does not modify URL parameters (e.g. as part of a redirect)."},id={errorType:"InvalidCloudProjectNumber",message:"Cloud Project Number provided by meet does not match the one passed in by the SDK. Ensure that the correct Cloud Project Number is passed to the SDK as a string.",
|
|
34
34
|
g:"This parameter is automatically appended by Meet to the iframe URL. Ensure that your infrastructure does not modify URL parameters (e.g. as part of a redirect) and ensure that the correct Cloud Project Number was passed into the SDK as a string."},jd={errorType:"DestinationNotReady",message:"The recipient frame is not connected via the addon SDK and cannot receive the notification.",g:"Make sure the destination frame has connected before sending messages to it."},kd={errorType:"InvalidCollaborationStartingState",
|
|
35
35
|
message:"Origin of the CollaborationStartingState iframeURLs does not match the origin of the URLs provided in the Add-on manifest.",g:"Ensure that the CollaborationStartingState iframeURL origins match the origins of the URLs provided in the Add-on manifest."},ld=a=>({errorType:"InternalError",message:`Could not connect to ${a} channel. Unknown error`,g:"No further information is available."}),md={errorType:"CoactivityIsOngoing",message:"Operation cannot be performed while a collaboration is ongoing.",
|
|
36
|
-
g:"Ensure that no collaboration is ongoing."},nd={errorType:"InternalError",message:"Frame message missing required Meet SDK command.",g:"Send one of the available commands in the frame message."},od={errorType:"RequiresEapEnrollment",message:"
|
|
37
|
-
qd={errorType:"SizeLimitExceededCollaborationStartingState",message:"The size of the collaborationStartingState URLs and/or its data exceed the limits allowed.",g:"Ensure that the collaborationStartingState URL size is less than 512 characters and the data size is less than 4096 characters."},rd={errorType:"SizeLimitExceededFrameToFrameMessage",message:"The size of the frame to frame message exceeds the limits allowed.",
|
|
38
|
-
function sd(a){switch(a){case 0:return ad;case 1:return jd;case 2:return kd;case 3:return md;case 4:return nd;case 5:return od;case 6:return gd;case 7:return pd;case 8:return qd;case 9:return rd;default:return bd}}
|
|
36
|
+
g:"Ensure that no collaboration is ongoing."},nd={errorType:"InternalError",message:"Frame message missing required Meet SDK command.",g:"Send one of the available commands in the frame message."},od={errorType:"RequiresEapEnrollment",message:"This feature is only available to early access partners.",g:"Meet add-on early access enrollment is currently closed."},pd={errorType:"UserNotInitiator",message:"Operation cannot be performed because the user is not the initiator of the current collaboration.",
|
|
37
|
+
g:"Ensure that the user is the initiator of the current collaboration or that the collaboration has ended."},qd={errorType:"SizeLimitExceededCollaborationStartingState",message:"The size of the collaborationStartingState URLs and/or its data exceed the limits allowed.",g:"Ensure that the collaborationStartingState URL size is less than 512 characters and the data size is less than 4096 characters."},rd={errorType:"SizeLimitExceededFrameToFrameMessage",message:"The size of the frame to frame message exceeds the limits allowed.",
|
|
38
|
+
g:"Ensure that the frame to frame message size is less than 1 megabyte."};function sd(a){switch(a){case 0:return ad;case 1:return jd;case 2:return kd;case 3:return md;case 4:return nd;case 5:return od;case 6:return gd;case 7:return pd;case 8:return qd;case 9:return rd;default:return bd}}
|
|
39
39
|
function td(a){let b;var c=(b=F(a,1))!=null?b:0;a=ud(a.ab());switch(c){case 1:return{errorType:"InternalError",message:`Could not connect to ${a} channel. Meet did not respond with a MessagePort.`,g:"No further information is available."};case 2:return{errorType:"InternalError",message:`Could not connect to ${a}. A conflicting ${a} exists.`,g:"No further information is available."};case 3:return{errorType:"InternalError",message:`Could not connect to ${a} channel. The addon does not have permission to open a ${a}.`,
|
|
40
40
|
g:"No further information is available."};case 4:return{errorType:"InternalError",message:`Could not connect to ${a} channel. The addon is not authorized for this ${a}.`,g:"No further information is available."};case 0:return ld(a);case 5:a:switch(a){case "coActivity":c={errorType:"InternalError",message:`Could not connect to ${a} channel. The coActivity was not found.`,g:`Consider starting the ${a} only after receiving a callback from the 'userInitiatedCollaboration' callback.`};break a;default:c=
|
|
41
41
|
{errorType:"InternalError",message:`Could not connect to ${a} channel.`,g:"No further information is available."}}return c;default:return ld(a)}}function ud(a){switch(a){case 2:return"coActivity";case 3:return"guaranteed delivery";case 0:return"unknown";default:return"unknown"}}function vd(a=""){({errorType:d,message:c,g:b}=bd);var b,c,d;throw new N({errorType:d,message:a?`${c} ${a}`:c,g:b});};class wd{constructor(a,b){this.ub=a[m.Symbol.iterator]();this.Ib=b}[Symbol.iterator](){return this}next(){const a=this.ub.next();return{value:a.done?void 0:this.Ib.call(void 0,a.value),done:a.done}}}var xd=function(a,b){return new wd(a,b)};var yd=function(){};function zd(a,b){for(const c in a)if(b.call(void 0,a[c],c,a))return!0;return!1}const Ad="constructor hasOwnProperty isPrototypeOf propertyIsEnumerable toLocaleString toString valueOf".split(" ");function Bd(a,b){let c,d;for(let e=1;e<arguments.length;e++){d=arguments[e];for(c in d)a[c]=d[c];for(let f=0;f<Ad.length;f++)c=Ad[f],Object.prototype.hasOwnProperty.call(d,c)&&(a[c]=d[c])}};var Cd=function(){var a=document;var b="IFRAME";a.contentType==="application/xhtml+xml"&&(b=b.toLowerCase());return a.createElement(b)};const Dd=m.URL;function Ed(){var a=window.location.href,b;(b=(new Dd(a)).searchParams.get("meet_sdk"))?b=$c(Ga(b)):(Fd("meet_sdk",a),b=void 0);var c=E(b,1);c||Fd("meet_addon_frame_type",a);c=Number(c);if(c!==2&&c!==1)throw new N(hd);const d=E(b,2);d||Fd("meet_control_channel_name",a);const e=E(b,4);e||Fd("addon_cloud_project_number",a);var f;a=(f=b.getFrameOpenReason())!=null?f:0;f=E(b,3)||"https://meet.google.com";return{Bb:a,frameType:c,xb:d,cloudProjectNumber:e,jb:f}}
|
|
@@ -72,7 +72,7 @@ var Sc=async function(a){a=a.channel;var b=a.da;var c=new P;var d=new Rd;c=C(c,1
|
|
|
72
72
|
b){var c=Y,d=new P;b=C(d,14,O,b);await c(a,S(b))},Yc=async function(a,b){var c=Y,d=new P;b=C(d,15,O,b);await c(a,S(b))},Vf=async function(a){Rf(async()=>{await Sc(a)})},Y=async function(a,b){(a=await a.channel.da(b))||vd("Falsy response received from the message channel."+` ${JSON.stringify(a)}`);(b=a.data)||vd("Data field in the response from the message channel is falsy."+` ${JSON.stringify(b)}`);(b=b.content)||vd("Content field in the response from the message channel is falsy."+` ${JSON.stringify(b)}`);
|
|
73
73
|
let c=void 0;try{c=Ud(b)}catch(d){vd("The ControlMessage can't be deserialized."+` ${JSON.stringify(b)}. ${JSON.stringify(d)}`)}(b=G(c,Ic,2,Vd))||vd("MeetToAddonMessage field on ControlMessage is falsy."+` ${JSON.stringify(b)}`);b=b==null?void 0:G(b,zc,10,Hc);if((b==null?void 0:F(b,1))!==void 0)throw new N(sd(F(b,1)));return a},Wf=async function(a,b,c){var d=Y,e=new P;b=C(e,1,O,b);d=await d(a,S(b));a=d.data.messagePort;var f;(d=(f=G(Ud(d.data.content),Ic,2,Vd))==null?void 0:G(f,yc,1,Hc))!=null?f=
|
|
74
74
|
d:(f=new yc,f=J(f,1,0));return{channel:a?Se(a,c):void 0,response:f}},Xf=async function(a){const b=Md(),{channel:c,response:d}=await Wf(a,b,e=>df(e));if(!c)throw new N(td(d));return c},Yf=async function(a){const b=Nd(),{channel:c,response:d}=await Wf(a,b,e=>Ye(e));if(!c)throw new N(td(d));return{channel:c,response:d}},Zf=async function(a){var b=Y;var c=new P;var d=new Sd;c=C(c,5,O,d);await b(a,S(c))},$f=async function(a){var b=Y;var c=new P;var d=new Pd;c=C(c,6,O,d);await b(a,S(c))},ag=async function(a,
|
|
75
|
-
b,c){var d=Y,e=new P,f=new Qd;b=J(f,1,b).ob(c);e=C(e,7,O,b);await d(a,S(e))};class Uf extends M{constructor(a,b){super();this.Nb=a;this.channel=b;a=Ze||(Ze=mc("[0,8,0]"));a=Tb(a);a=Xb(a,4,zb("
|
|
75
|
+
b,c){var d=Y,e=new P,f=new Qd;b=J(f,1,b).ob(c);e=C(e,7,O,b);await d(a,S(e))};class Uf extends M{constructor(a,b){super();this.Nb=a;this.channel=b;a=Ze||(Ze=mc("[0,8,0]"));a=Tb(a);a=Xb(a,4,zb("653364875"));b=a.h;var c=b[v];b=c&2?a:Cb(a.constructor,Sb(b,c,!0));a=new P;c=new Od;b=B(c,2,b);a=C(a,2,O,b);this.channel.send(S(a));Vf(this)}};let bg;function cg(a){var b=a.cloudProjectNumber;a=Ed();if(a.cloudProjectNumber!==b)throw new N(id);b=a.jb;const c=a.xb;let d;bg=(d=bg)!=null?d:Tf(c,b);return new dg(a)}var dg=class{constructor(a){var b=bg;this.xa=a;this.i=b}delete(){throw Error("Not implemented.");}};var eg=class extends K{constructor(){super()}};var fg=class extends K{constructor(){super()}};var hg=class extends K{constructor(){super()}H(){return y(this,gg)}Ga(){return G(this,Ve,1,gg)}ta(a){return C(this,1,gg,a)}},gg=[1,2,3];var kg=async function(a,b){switch(b.H()){case 1:var c=ig;b=b.Ga();await c(a,b);break;case 2:return c=jg,b=G(b,We,2,Xe),await c(a,b)}},mg=function(a){a.Ja=setTimeout(async()=>{await lg(a)},3E3)},ig=async function(a,b){a.Ja&&(clearTimeout(a.Ja),mg(a));let c;((c=A(b,Ue,1))==null?void 0:F(c,1))!==F(a.ya,1)?(a.Oa++,await ng(a)):a.Oa=0},jg=async function(a,b){var c=new fg;b=A(b,Ue,1);if(!b)return c=new hg,a=new fg,a=J(a,1,4),C(c,2,gg,a);var d;const e=(d=Nc.get(F(b,1)))!=null?d:"RECORDING_STATUS_UNKNOWN";
|
|
76
76
|
d=await og(a,e);J(c,1,d);d===2&&Te(a.ya,F(b,1));a=new hg;return C(a,2,gg,c)},ng=async function(a){if(a.Oa>3)try{await a.N.onRecordingStatusChanged({recordingStatus:"RECORDING_STATUS_UNKNOWN"})}catch(b){}},og=async function(a,b){const c=new Promise((d,e)=>{setTimeout(()=>{e(new pg)},5E3)});try{return await Promise.race([c,(async()=>a.N.onRecordingStatusChanged({recordingStatus:b}))()])?2:3}catch(d){return d instanceof pg?5:4}},lg=async function(a){try{await a.N.onRecordingStatusChanged({recordingStatus:"RECORDING_STATUS_UNKNOWN"})}catch(b){}},
|
|
77
77
|
qg=class extends M{constructor(a,b){super();this.eb=a;this.N=b;this.oa=new Of(1E3);this.Oa=0;a=this.eb.response;this.ja=this.eb.channel;this.Cb=Rc(this.ja.signal,async e=>{var f=await kg(this,e.content);f&&(e=e.kb,f=kc(f),e.channel.send(f,void 0,void 0))},this);let c,d;a=(d=(c=G(a,wc,3,xc))==null?void 0:F(c,1))!=null?d:0;this.ya=Te(new Ue,a);Pc(this,ma(Oc,this.oa));vf(this.oa,"tick",()=>{this.ja.channel.send(kc((new hg).ta((new Ve).nb(this.ya))))});this.oa.start();mg(this)}disconnect(){var a=this.ja.channel,
|
|
78
78
|
b=a.send;var c=new hg;var d=new eg;c=C(c,3,gg,d);b.call(a,kc(c));this.oa.stop();clearTimeout(this.Ja);this.ja.signal.detach(this.Cb)}},pg=class extends Error{constructor(){super("Timed out waiting for guaranteed delivery delegate method to return")}};async function rg(a,b){a=await Yf(a.i);return new qg(a,b)};var tg=class extends K{Ra(a){return hc(this,a)}Ea(){return G(this,T,2,sg)}ra(a){C(this,2,sg,a)}ma(){return z(this,T,2,sg)}Fa(){return G(this,U,3,sg)}sa(a){C(this,3,sg,a)}Ia(){return z(this,U,3,sg)}},sg=[2,3];var ug=class extends K{constructor(){super()}};var vg=class extends K{constructor(){super()}};var wg=class extends K{constructor(){super()}Qa(a){return Xb(this,4,zb(a))}};var yg=class extends K{constructor(){super()}Ra(a){return hc(this,a)}Ea(){return G(this,T,2,xg)}ra(a){C(this,2,xg,a)}ma(){return z(this,T,2,xg)}Fa(){return G(this,U,3,xg)}sa(a){C(this,3,xg,a)}Ia(){return z(this,U,3,xg)}},xg=[2,3],zg=[5,6];var Ag=class extends K{constructor(){super()}Qa(a){return H(this,1,a)}};var Cg=class extends K{constructor(){super()}H(){return y(this,Bg)}Ga(){return G(this,tg,1,Bg)}ta(a){return C(this,1,Bg,a)}},Bg=[1,2,3];function Dg(a){var b=new Eg;let c=0,d;return(...e)=>{if(Fg(b)){Gg(b);var f=!0}else f=!1;f?a(...e):(d=()=>void a(...e),c||(c=setTimeout(()=>{c=0;let g;(g=d)==null||g()},Hg(b))))}};var Hg=function(a){const b=a.Ya;let c;a=Date.now()-((c=a.La[a.index])!=null?c:0);return a>=b?0:b-a},Fg=function(a){const b=a.Ya;let c;return Date.now()-((c=a.La[a.index])!=null?c:0)>=b},Gg=function(a){a.La[a.index]=Date.now();a.index=(a.index+1)%a.Jb},Eg=class{constructor(){this.Jb=1;this.Ya=500;this.La=[];this.index=0}};var Ig=class extends Error{constructor(){super("Failed to create CoActivity: Connection refused - Meet refused to begin Live Sharing")}};var Jg=class{constructor(a){this.config=a}start(){this.hb!=null||(this.hb=setInterval(()=>{this.config.Mb()},this.config.Eb));return this}shutdown(){clearInterval(this.hb)}};function Kg(){const a=new Map,b={set(c,d){a.set(c,d);return b},wa:()=>a};return b};function Lg(a){if(a.ma()){var b=a.Ea().getState();a=Uint8Array;Pa(Na);var c=b.ua;if(c!=null&&!Ma(c))if(typeof c==="string"){Ja.test(c)&&(c=c.replace(Ja,La));c=atob(c);const d=new Uint8Array(c.length);for(let e=0;e<c.length;e++)d[e]=c.charCodeAt(e);c=d}else c=null;b=c==null?c:b.ua=c;return{bytes:new a(b||0)}}}function Mg(a,b){a.ra(Ng(b));return a}function Og(a,b){a.ra(Ng(b));return a}function Ng(a){var b=new T;return $b(b,1,ib(a.bytes,!1,!1),Ra())}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@googleworkspace/meet-addons",
|
|
3
3
|
"description": "The Google Meet Add-ons SDK lets you embed your app into Google Meet as an add-on where users can discover, share, and collaborate in the app without leaving Meet",
|
|
4
|
-
"version": "0.8.0-
|
|
4
|
+
"version": "0.8.0-653364875",
|
|
5
5
|
"repository": "googleworkspace/meet",
|
|
6
6
|
"license": "SEE LICENSE IN LICENSE",
|
|
7
7
|
"homepage": "https://developers.google.com/meet/add-ons/guides/overview",
|