@googleworkspace/meet-addons 1.2.0-dev-735519468 → 1.2.0-dev-736279196
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.mjs +64 -64
- package/meet.addons.screenshare.mjs +3 -3
- package/package.json +1 -1
package/meet.addons.mjs
CHANGED
|
@@ -5,68 +5,68 @@ function da(a,b){if(b)a:{var c=ca;a=a.split(".");for(var d=0;d<a.length-1;d++){v
|
|
|
5
5
|
SPDX-License-Identifier: Apache-2.0
|
|
6
6
|
*/
|
|
7
7
|
var ea=this||self;function fa(a,b){var c=Array.prototype.slice.call(arguments,1);return function(){var d=c.slice();d.push.apply(d,arguments);return a.apply(this,d)}}function ha(a,b){function c(){}c.prototype=b.prototype;a.qa=b.prototype;a.prototype=new c;a.prototype.constructor=a;a.oa=function(d,e,f){for(var h=Array(arguments.length-2),g=2;g<arguments.length;g++)h[g-2]=arguments[g];return b.prototype[e].apply(d,h)}};function ia(a,b){if(Error.captureStackTrace)Error.captureStackTrace(this,ia);else{const c=Error().stack;c&&(this.stack=c)}a&&(this.message=String(a));b!==void 0&&(this.cause=b)}ha(ia,Error);ia.prototype.name="CustomError";function l(a){ea.setTimeout(()=>{throw a;},0)};function ja(a,b){b=Array.prototype.indexOf.call(a,b,void 0);b>=0&&Array.prototype.splice.call(a,b,1)};const ka=/[-_.]/g,la={"-":"+",_:"/",".":"="};function ma(a){return la[a]||""}var na={};function oa(){return pa||(pa=new m(null,na))}var m=class{constructor(a,b){qa(b);this.g=a;if(a!=null&&a.length===0)throw Error("ByteString should be constructed with non-empty values");}};let pa;function qa(a){if(a!==na)throw Error("illegal external caller");};function ra(a,b){a.__closure__error__context__984382||(a.__closure__error__context__984382={});a.__closure__error__context__984382.severity=b};let sa=void 0;function ta(a){a=Error(a);ra(a,"warning");return a};function ua(a,b=!1){return b&&Symbol.for&&a?Symbol.for(a):a!=null?Symbol(a):Symbol()}var va=ua(),wa=ua();const n=ua("jas",!0);var xa={};function ya(a){return a!==null&&typeof a==="object"&&!Array.isArray(a)&&a.constructor===Object}function za(a,b){if(a!=null)if(typeof a==="string")a=a?new m(a,na):oa();else if(a.constructor!==m)if(a!=null&&a instanceof Uint8Array)a=a.length?new m(new Uint8Array(a),na):oa();else{if(!b)throw Error();a=void 0}return a}var Aa;const Ba=[];Ba[n]=55;Aa=Object.freeze(Ba);function Ca(a){if(a&2)throw Error();}var Da=Object.freeze({});function Ea(){return typeof BigInt==="function"};function Fa(a){a.pa=!0;return a};var Ga=Fa(a=>typeof a==="number"),Ha=Fa(a=>typeof a==="string"),Ia=Fa(a=>typeof a==="boolean");var Ja=typeof ea.BigInt==="function"&&typeof ea.BigInt(0)==="bigint";var Pa=Fa(a=>Ja?a>=Ka&&a<=La:a[0]==="-"?Ma(a,Na):Ma(a,Oa));const Na=Number.MIN_SAFE_INTEGER.toString(),Ka=Ja?BigInt(Number.MIN_SAFE_INTEGER):void 0,Oa=Number.MAX_SAFE_INTEGER.toString(),La=Ja?BigInt(Number.MAX_SAFE_INTEGER):void 0;function Ma(a,b){if(a.length>b.length)return!1;if(a.length<b.length||a===b)return!0;for(let c=0;c<a.length;c++){const d=a[c],e=b[c];if(d>e)return!1;if(d<e)return!0}};let p=0,r=0;function Qa(a){const b=a>>>0;p=b;r=(a-b)/4294967296>>>0}function Ra(a){if(a<0){Qa(-a);const [b,c]=Sa(p,r);p=b>>>0;r=c>>>0}else Qa(a)}function Ta(a,b){b>>>=0;a>>>=0;if(b<=2097151)var c=""+(4294967296*b+a);else Ea()?c=""+(BigInt(b)<<BigInt(32)|BigInt(a)):(c=(a>>>24|b<<8)&16777215,b=b>>16&65535,a=(a&16777215)+c*6777216+b*6710656,c+=b*8147497,b*=2,a>=1E7&&(c+=a/1E7>>>0,a%=1E7),c>=1E7&&(b+=c/1E7>>>0,c%=1E7),c=b+Ua(c)+Ua(a));return c}
|
|
8
|
-
function Ua(a){a=String(a);return"0000000".slice(a.length)+a}function Sa(a,b){b=~b;a?a=~a+1:b+=1;return[a,b]};const Va=typeof BigInt==="function"?BigInt.asIntN:void 0,Wa=Number.isSafeInteger,Xa=Number.isFinite,Za=Math.trunc
|
|
9
|
-
function cb(a){if(a!=null)a:{if(!
|
|
10
|
-
function
|
|
11
|
-
function
|
|
12
|
-
(r+=Math.trunc(p/4294967296),r>>>=0,p>>>=0)}if(b){const [d,e]=Sa(p,r);p=d;r=e}}a=p;b=r;if(b&2147483648)if(Ea())a=""+(BigInt(b|0)<<BigInt(32)|BigInt(a>>>0));else{const [c,d]=Sa(a,b);a="-"+Ta(c,d)}else a=Ta(a,b)}return a}function v(a){if(a!=null&&typeof a!=="string")throw Error();return a}function
|
|
13
|
-
-1]=a;else{let
|
|
14
|
-
function
|
|
15
|
-
b);a=a.g=btoa(c)}return a}return}return a}let
|
|
16
|
-
function
|
|
17
|
-
function
|
|
18
|
-
function
|
|
19
|
-
function
|
|
20
|
-
function
|
|
21
|
-
function H(a,b,c,d){c=z(a,d)===c?c:-1;return
|
|
22
|
-
var I=class{constructor(a){a:{if(a==null){var b=96;a=[]}else{if(!Array.isArray(a))throw Error("narr");b=a[n]|0;8192&b||!(64&b)||2&b||
|
|
23
|
-
I.prototype.H=xa;I.prototype.toString=function(){return this.m.toString()};function
|
|
24
|
-
|
|
25
|
-
message:"This method is not supported in standalone mode.",i:"Do not call this method in standalone mode."},
|
|
26
|
-
|
|
27
|
-
message:"The recipient frame is not connected via the addon SDK and cannot receive the notification.",i:"Make sure the destination frame has connected before sending messages to it."}
|
|
28
|
-
message:"The supplied ActivityStartingState object does not contain any recognized attributes.",i:"Ensure that the ActivityStartingState object contains at least one of the following attributes: mainStageUrl, sidePanelUrl, additionalData."}
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
i:"No further information is available."}),
|
|
32
|
-
message:"This feature is only available to early access partners.",i:"Meet add-on early access enrollment is currently closed."},
|
|
33
|
-
i:"Ensure that the activityStartingState URL size is less than 512 characters and the additional data size is less than 4096 characters."},
|
|
34
|
-
message:"The user cancelled starting an activity.",i:"The user needs to click continue to start the activity."},
|
|
35
|
-
|
|
36
|
-
function
|
|
37
|
-
function
|
|
38
|
-
i:"This method might require EAP enrollment."};case 4:return{errorType:"InternalError",message:`Could not connect to ${a} channel. The addon is not authorized for this ${a}.`,i:"No further information is available."};case 0:return
|
|
39
|
-
i:"No further information is available."}}return c;default:return
|
|
40
|
-
(h===1||h===4&&32&g))){
|
|
41
|
-
"string")throw new J(L("additionalData",typeof a.additionalData,"string | undefined"));if(Object.keys(a).length!==+!!a.mainStageUrl+ +!!a.sidePanelUrl+ +!!a.additionalData)throw new J(
|
|
42
|
-
var
|
|
43
|
-
a:0;let c;return(c=
|
|
44
|
-
d)}on(a,b){this.h[a]=b}async getMeetPlatformInfo(){const a=await
|
|
45
|
-
|
|
46
|
-
function
|
|
47
|
-
function
|
|
48
|
-
function
|
|
49
|
-
function
|
|
50
|
-
function
|
|
51
|
-
function
|
|
52
|
-
function
|
|
53
|
-
var
|
|
54
|
-
|
|
55
|
-
function
|
|
56
|
-
async function
|
|
57
|
-
async function
|
|
58
|
-
async function W(a,b){(a=await a.channel.C(b))||M(K,"Falsy response received from the message channel."+` ${JSON.stringify(a)}`);(b=a.data)||M(K,"Data field in the response from the message channel is falsy."+` ${JSON.stringify(b)}`);(b=b.content)||M(K,"Content field in the response from the message channel is falsy."+` ${JSON.stringify(b)}`);let c=void 0;try{c=
|
|
59
|
-
` ${JSON.stringify(b)}`);b=b==null?void 0:H(b,
|
|
60
|
-
async function
|
|
61
|
-
class
|
|
62
|
-
function
|
|
63
|
-
|
|
64
|
-
function
|
|
65
|
-
class
|
|
66
|
-
e=
|
|
8
|
+
function Ua(a){a=String(a);return"0000000".slice(a.length)+a}function Sa(a,b){b=~b;a?a=~a+1:b+=1;return[a,b]};const Va=typeof BigInt==="function"?BigInt.asIntN:void 0,Wa=Number.isSafeInteger,Xa=Number.isFinite,Za=Math.trunc;function $a(a){if(a==null||typeof a==="number")return a;if(a==="NaN"||a==="Infinity"||a==="-Infinity")return Number(a)}const ab=/^-?([1-9][0-9]*|0)(\.[0-9]+)?$/;function bb(a){switch(typeof a){case "bigint":return!0;case "number":return Xa(a);case "string":return ab.test(a);default:return!1}}function u(a){if(a!=null){if(!Xa(a))throw ta("enum");a|=0}return a}
|
|
9
|
+
function cb(a){if(a!=null){if(typeof a==="string"&&a)a=+a;else if(typeof a!=="number")return;Xa(a)}}function db(a){if(a!=null)a:{if(!bb(a))throw ta("int64");switch(typeof a){case "string":a=eb(a);break a;case "bigint":var b=a=Va(64,a);if(Ha(b)){if(!/^\s*(?:-?[1-9]\d*|0)?\s*$/.test(b))throw Error(String(b));}else if(Ga(b)&&!Number.isSafeInteger(b))throw Error(String(b));Ja?a=BigInt(a):a=Ia(a)?a?"1":"0":Ha(a)?a.trim()||"0":String(a);break a;default:a=fb(a)}}return a}
|
|
10
|
+
function fb(a){a=Za(a);if(!Wa(a)){Ra(a);var b=p,c=r;if(a=c&2147483648)b=~b+1>>>0,c=~c>>>0,b==0&&(c=c+1>>>0);const d=c*4294967296+(b>>>0);b=Number.isSafeInteger(d)?d:Ta(b,c);a=typeof b==="number"?a?-b:b:a?"-"+b:b}return a}
|
|
11
|
+
function eb(a){var b=Za(Number(a));if(Wa(b))return String(b);b=a.indexOf(".");b!==-1&&(a=a.substring(0,b));b=a.length;if(!(a[0]==="-"?b<20||b===20&&Number(a.substring(0,7))>-922337:b<19||b===19&&Number(a.substring(0,6))<922337)){if(a.length<16)Ra(Number(a));else if(Ea())a=BigInt(a),p=Number(a&BigInt(4294967295))>>>0,r=Number(a>>BigInt(32)&BigInt(4294967295));else{b=+(a[0]==="-");r=p=0;const c=a.length;for(let d=b,e=(c-b)%6+b;e<=c;d=e,e+=6){const f=Number(a.slice(d,e));r*=1E6;p=p*1E6+f;p>=4294967296&&
|
|
12
|
+
(r+=Math.trunc(p/4294967296),r>>>=0,p>>>=0)}if(b){const [d,e]=Sa(p,r);p=d;r=e}}a=p;b=r;if(b&2147483648)if(Ea())a=""+(BigInt(b|0)<<BigInt(32)|BigInt(a>>>0));else{const [c,d]=Sa(a,b);a="-"+Ta(c,d)}else a=Ta(a,b)}return a}function v(a){if(a!=null&&typeof a!=="string")throw Error();return a}function gb(a,b,c){if(a!=null&&typeof a==="object"&&a.H===xa)return a;if(Array.isArray(a)){var d=a[n]|0,e=d;e===0&&(e|=c&32);e|=c&2;e!==d&&(a[n]=e);return new b(a)}};function hb(a){return a};function ib(a,b,c,d,e){d=d?!!(b&32):void 0;const f=[];let h=a.length,g,k,w,B=!1;if(b&64){if(b&256?(h--,g=a[h],k=h):(k=4294967295,g=void 0),!(e||b&512)){B=!0;var q;w=((q=jb)!=null?q:hb)(g?k- -1:b>>15&1023||536870912,-1,a,g);k=w+-1}}else k=4294967295,b&1||(g=h&&a[h-1],ya(g)?(h--,k=h,w=0):g=void 0);q=void 0;for(let t=0;t<h;t++){let C=a[t];if(C!=null&&(C=c(C,d))!=null)if(t>=k){var G=void 0;((G=q)!=null?G:q={})[t- -1]=C}else f[t]=C}if(g)for(let t in g)if(a=g[t],a!=null&&(a=c(a,d))!=null)if(G=+t,G<w)f[G+
|
|
13
|
+
-1]=a;else{let C;((C=q)!=null?C:q={})[t]=a}q&&(B?f.push(q):f[k]=q);e&&(f[n]=b&33522241|(q!=null?290:34));return f}
|
|
14
|
+
function kb(a){switch(typeof a){case "number":return Number.isFinite(a)?a:""+a;case "bigint":return Pa(a)?Number(a):""+a;case "boolean":return a?1:0;case "object":if(Array.isArray(a)){var b=a[n]|0;return a.length===0&&b&1?void 0:ib(a,b,kb,!1,!1)}if(a.H===xa)return lb(a);if(a instanceof m){b=a.g;if(b==null)a="";else if(typeof b==="string")a=b;else{let c="",d=0;const e=b.length-10240;for(;d<e;)c+=String.fromCharCode.apply(null,b.subarray(d,d+=10240));c+=String.fromCharCode.apply(null,d?b.subarray(d):
|
|
15
|
+
b);a=a.g=btoa(c)}return a}return}return a}let jb;function lb(a){a=a.m;return ib(a,a[n]|0,kb,void 0,!1)};function mb(){if(wa!=null){var a;var b=(a=sa)!=null?a:sa={};a=b[wa]||0;a>=5||(b[wa]=a+1,b=Error(),ra(b,"incident"),l(b))}};function nb(a,b){if(typeof a!=="object")return a;if(Array.isArray(a)){const d=a[n]|0;if(a.length===0&&d&1)return;if(d&2)return a;var c;if(c=b)c=d===0||!!(d&32)&&!(d&64||!(d&16));return c?(a[n]|=34,d&4&&Object.freeze(a),a):ib(a,d,nb,b!==void 0,!0)}if(a.H===xa)return b=a.m,c=b[n]|0,c&2?a:ib(b,c,nb,!0,!0);if(a instanceof m)return a}function ob(a){var b=a.m;if(!((b[n]|0)&2))return a;a=new a.constructor(ib(b,b[n]|0,nb,!0,!0));b=a.m;b[n]&=-3;return a};function x(a,b){a=a.m;return pb(a,a[n]|0,b)}function pb(a,b,c,d){if(c===-1)return null;const e=c+(b&512?0:-1),f=a.length-1;let h;if(e>=f&&b&256)b=a[f][c],h=!0;else if(e<=f)b=a[e];else return;if(d&&b!=null){d=d(b);if(d==null)return d;if(d!==b)return h?a[f][c]=d:a[e]=d,d}return b}function qb(a,b,c){const d=a.m;let e=d[n]|0;Ca(e);y(d,e,b,c);return a}
|
|
16
|
+
function y(a,b,c,d){const e=b&512?0:-1,f=c+e;var h=a.length-1;if(f>=h&&b&256)return a[h][c]=d,b;if(f<=h)return a[f]=d,b;d!==void 0&&(h=b>>15&1023||536870912,c>=h?d!=null&&(a[h+e]={[c]:d},b|=256,a[n]=b):a[f]=d);return b}function rb(a,b,c,d){c=z(a,d)===c?c:-1;return sb(a,b,c)!==void 0}function tb(a){return!!(2&a)&&!!(4&a)||!!(1024&a)}function ub(a){return za(a,!0)}function A(a,b,c,d){const e=a.m;let f=e[n]|0;Ca(f);y(e,f,b,(d==="0"?Number(c)===0:c===d)?void 0:c);return a}
|
|
17
|
+
function z(a,b){a=a.m;return vb(wb(a),a,a[n]|0,b)}function wb(a){let b;return(b=a[va])!=null?b:a[va]=new Map}function vb(a,b,c,d){let e=a.get(d);if(e!=null)return e;e=0;for(let f=0;f<d.length;f++){const h=d[f];pb(b,c,h)!=null&&(e!==0&&(c=y(b,c,e)),e=h)}a.set(d,e);return e}function sb(a,b,c){a=a.m;let d=a[n]|0;const e=pb(a,d,c);b=gb(e,b,d);b!==e&&b!=null&&y(a,d,c,b);return b}
|
|
18
|
+
function xb(a,b,c){b=sb(a,b,c);if(b==null)return b;a=a.m;let d=a[n]|0;if(!(d&2)){const e=ob(b);e!==b&&(b=e,y(a,d,c,b))}return b}function yb(a,b,c){c==null&&(c=void 0);return qb(a,b,c)}function D(a,b,c,d){d==null&&(d=void 0);a:{const h=a.m;var e=h[n]|0;Ca(e);if(d==null){var f=wb(h);if(vb(f,h,e,c)===b)f.set(c,0);else break a}else{f=h;const g=wb(f),k=vb(g,f,e,c);k!==b&&(k&&(e=y(f,e,k)),g.set(c,b))}y(h,e,b,d)}return a}
|
|
19
|
+
function zb(a,b){const c=a.m;let d=c[n]|0;Ca(d);if(b==null)return y(c,d,1),a;let e=b[n]|0,f=e;const h=tb(e),g=h||Object.isFrozen(b);let k=!0,w=!0;for(let q=0;q<b.length;q++){var B=b[q];h||(B=!!((B.m[n]|0)&2),k&&(k=!B),w&&(w=B))}h||(e=k?13:5,e=w?e|16:e&-17);g&&e===f||(b=Array.prototype.slice.call(b),f=0,e=Ab(e,d),e=Bb(e,d,!0));e!==f&&(b[n]=e);y(c,d,1,b);return a}function Ab(a,b){a=(2&b?a|2:a&-3)|32;return a&=-1025}function Bb(a,b,c){32&b&&c||(a&=-33);return a}
|
|
20
|
+
function Cb(a){a=x(a,1);a=a==null||typeof a==="boolean"?a:typeof a==="number"?!!a:void 0;return a!=null?a:!1}function Db(a){a=x(a,1);a!=null&&(typeof a==="bigint"?Pa(a)?a=Number(a):(a=Va(64,a),a=Pa(a)?Number(a):String(a)):a=bb(a)?typeof a==="number"?fb(a):eb(a):void 0);return a!=null?a:0}function E(a,b){a=x(a,b);a=a==null||typeof a==="string"?a:void 0;return a!=null?a:""}function F(a,b){a=x(a,b);a=a==null?a:Xa(a)?a|0:void 0;return a!=null?a:0}
|
|
21
|
+
function H(a,b,c,d){c=z(a,d)===c?c:-1;return xb(a,b,c)};function Eb(){var a=Fb||(Fb=Gb("[1,2,0]"));a=ob(a);a=qb(a,4,v("dev-736279196"));const b=a.m,c=b[n]|0;return c&2?a:new a.constructor(ib(b,c,nb,!0,!0))}
|
|
22
|
+
var I=class{constructor(a){a:{if(a==null){var b=96;a=[]}else{if(!Array.isArray(a))throw Error("narr");b=a[n]|0;8192&b||!(64&b)||2&b||mb();if(b&1024)throw Error("farr");if(b&64){b&16384||(a[n]=b|16384);var c=a;break a}var d=a;b|=64;var e=d.length;if(e){var f=e-1;e=d[f];if(ya(e)){b|=256;const h=b&512?0:-1;f-=h;if(f>=1024)throw Error("pvtlmt");for(c in e){const g=+c;if(g<f)d[g+h]=e[c],delete e[c];else break}b=b&-33521665|(f&1023)<<15}}}a[n]=b|16384;c=a}this.m=c}toJSON(){return lb(this)}};
|
|
23
|
+
I.prototype.H=xa;I.prototype.toString=function(){return this.m.toString()};function Hb(a){return b=>{if(b==null||b=="")b=new a;else{b=JSON.parse(b);if(!Array.isArray(b))throw Error("dnarr");b[n]|=32;b=new a(b)}return b}};var Gb=function(a){return b=>{b=JSON.parse(b);if(!Array.isArray(b)){var c=typeof b;throw Error("Expected jspb data to be an array, got "+(c!="object"?c:b?Array.isArray(b)?"array":c:"null")+": "+b);}b[n]|=34;return new a(b)}}(class extends I{});var Ib=class extends I{};function Jb(a){var b=new Kb(500);let c=0,d;return(...e)=>{Lb(b)?a(...e):(d=()=>void a(...e),c||(c=setTimeout(()=>{c=0;let f;(f=d)==null||f()},Mb(b))))}}function Nb(a){var b=new Kb(100),c=Promise.resolve();return(...d)=>Lb(b)?a(...d):c};function Lb(a){return Ob(a,a.index)>=a.g?(a.h[a.index]=Date.now(),a.index=(a.index+1)%1,!0):!1}function Mb(a){const b=a.g;a=Ob(a,a.index);return a>=b?0:b-a}function Ob(a,b){let c;return Date.now()-((c=a.h[b])!=null?c:-1*a.g)}var Kb=class{constructor(a){this.g=a;this.h=[];this.index=0}};var Pb=class extends I{},Qb=[2,3];var Rb=class extends I{};var J=class extends Error{constructor({errorType:a,message:b,i:c}){super(`Meet add-on SDK error: ${`${b}${c?` - ${c}`:""}`}`);this.errorType=a}},K={errorType:"InternalError",message:"An unexpected error has occurred.",i:"No further information is available."},Sb={errorType:"MissingUrlParameter",message:"Missing required Meet SDK URL parameter",i:"This parameter is automatically appended by Meet to the iframe URL. Ensure that your infrastructure does not strip URL parameters (e.g. as part of a redirect)."},
|
|
24
|
+
Tb={errorType:"NeedsMainStageContext",message:"This method can only be invoked if the addon is running in the main stage.",i:"Use getFrameType to check whether the addon is running in the main stage before invoking this method."},Ub={errorType:"NeedsSidePanelContext",message:"This method can only be invoked if the addon is running in the side panel.",i:"Use getFrameType to check whether the addon is running in the side panel before invoking this method."},Vb={errorType:"NotSupportedInStandalone",
|
|
25
|
+
message:"This method is not supported in standalone mode.",i:"Do not call this method in standalone mode."},Wb={errorType:"MustBeIframed",message:"The SDK must be run in an iframe as part of a Google Meet add-on.",i:"See https://developers.google.com/meet/add-ons/guides/deploy-add-on to deploy to Meet."},Xb={errorType:"InternalError",message:"The frame type URL parameter is set to an unexpected value.",i:"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)."},
|
|
26
|
+
Yb={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.",i:"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."},Zb={errorType:"DestinationNotReady",
|
|
27
|
+
message:"The recipient frame is not connected via the addon SDK and cannot receive the notification.",i:"Make sure the destination frame has connected before sending messages to it."},$b={errorType:"InvalidActivityStartingState",message:"Origin of the ActivityStartingState iframeURLs does not match the origin of the URLs provided in the add-on manifest.",i:"Ensure that the ActivityStartingState iframeURL origins match the origins of the URLs provided in the add-on manifest."},ac={errorType:"ActivityStartingStateMissingAttributes",
|
|
28
|
+
message:"The supplied ActivityStartingState object does not contain any recognized attributes.",i:"Ensure that the ActivityStartingState object contains at least one of the following attributes: mainStageUrl, sidePanelUrl, additionalData."},bc={errorType:"ActivityStartingStateUnrecognizedAttributes",message:"The supplied ActivityStartingState object contains attributes that are not recognized.",i:"Ensure that the ActivityStartingState object has only the following attributes: mainStageUrl, sidePanelUrl, additionalData."},
|
|
29
|
+
cc={errorType:"AddonStartingStateMissingAttributes",message:"The supplied AddonStartingState object does not contain any recognized attributes.",i:"Ensure that the AddonStartingState object contains at least one of the following attributes: sidePanelUrl, additionalData."},dc={errorType:"AddonStartingStateUnrecognizedAttributes",message:"The supplied AddonStartingState object contains attributes that are not recognized.",i:"Ensure that the AddonStartingState object has only the following attributes: sidePanelUrl, additionalData."},
|
|
30
|
+
fc=a=>({errorType:"ArgumentNullError",message:`The argument supplied for '${a}' was 'null' but a value was expected.`,i:"Ensure you are passing a value of the expected type for the argument."}),L=(a,b,c)=>({errorType:"ArgumentTypeError",message:`The type '${b}' of argument supplied for '${a}' did not match the expected type '${c}'.`,i:"Ensure the type of the argument provided matches the expected type."}),gc=a=>({errorType:"InternalError",message:`Could not connect to ${a} channel. Unknown error`,
|
|
31
|
+
i:"No further information is available."}),hc={errorType:"ActivityIsOngoing",message:"Operation cannot be performed while an activity is ongoing.",i:"Ensure that no activity is ongoing."},ic={errorType:"InternalError",message:"Frame message missing required Meet SDK command.",i:"Send one of the available commands in the frame message."},jc={errorType:"NoActivityFound",message:"No activity found.",i:"Ensure that the activity is started before performing this operation."},kc={errorType:"RequiresEapEnrollment",
|
|
32
|
+
message:"This feature is only available to early access partners.",i:"Meet add-on early access enrollment is currently closed."},lc={errorType:"UserNotInitiator",message:"Operation cannot be performed because the user is not the initiator of the current activity.",i:"Ensure that the user is the initiator of the current activity or that the activity has ended."},mc={errorType:"SizeLimitExceededActivityStartingState",message:"The size of the activityStartingState URLs and/or its data exceed the limits allowed.",
|
|
33
|
+
i:"Ensure that the activityStartingState URL size is less than 512 characters and the additional data size is less than 4096 characters."},nc={errorType:"SizeLimitExceededFrameToFrameMessage",message:"The size of the frame to frame message exceeds the limits allowed.",i:"Ensure that the frame to frame message size is less than 1,000,000 characters."},oc={errorType:"AddonSessionAlreadyCreated",message:"The addon session has already been created.",i:"Only instantiate the AddonSession once."},pc={errorType:"UserCancelled",
|
|
34
|
+
message:"The user cancelled starting an activity.",i:"The user needs to click continue to start the activity."},qc={errorType:"NotSupportedInMeetCall",message:"This method is not supported during a Meet call.",i:"Do not call this method during a Meet call."},rc={errorType:"InvalidAddonStartingState",message:"Origin of the AddonStartingState iframeURLs does not match the origin of the URLs provided in the add-on manifest.",i:"Ensure that the AddonStartingState iframeURL origins match the origins of the URLs provided in the add-on manifest."},
|
|
35
|
+
sc={errorType:"SizeLimitExceededAddonStartingState",message:"The size of the AddonStartingState URLs and/or its data exceed the limits allowed.",i:"Ensure that the AddonStartingState URL size is less than 512 characters and the additional data size is less than 4096 characters."},tc={errorType:"MeetingPolicyPreventsStartingActivity",message:"A meeting policy (such as using host control settings) prevents the user from starting the activity.",i:"Have a meeting host or administrator modify the necessary settings to allow the current user to start the activity."};
|
|
36
|
+
function uc(a){switch(a){case 0:return K;case 1:return Zb;case 2:return $b;case 3:return hc;case 4:return ic;case 5:return kc;case 6:return Vb;case 7:return lc;case 8:return mc;case 9:return nc;case 10:return pc;case 11:return qc;case 12:return rc;case 13:return sc;case 14:return jc;case 15:return tc;default:return K}}
|
|
37
|
+
function vc(a){let b;var c=(b=F(a,1))!=null?b:0;a=wc(z(a,Qb));switch(c){case 1:return{errorType:"InternalError",message:`Could not connect to ${a} channel. Meet did not respond with a MessagePort.`,i:"No further information is available."};case 2:return{errorType:"InternalError",message:`Could not connect to ${a}. A conflicting ${a} exists.`,i:"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}.`,
|
|
38
|
+
i:"This method might require EAP enrollment."};case 4:return{errorType:"InternalError",message:`Could not connect to ${a} channel. The addon is not authorized for this ${a}.`,i:"No further information is available."};case 0:return gc(a);case 5:a:switch(a){case "co":c={errorType:"InternalError",message:`Could not connect to ${a} channel. The coActivity was not found.`,i:`Consider starting the ${a} only after after the startActivity promise returns.`};break a;default:c={errorType:"InternalError",message:`Could not connect to ${a} channel.`,
|
|
39
|
+
i:"No further information is available."}}return c;default:return gc(a)}}function wc(a){switch(a){case 2:return"co";case 3:return"gd";case 0:return"unknown";default:return"unknown"}}function M({errorType:a,message:b,i:c},d=""){throw new J({errorType:a,message:d?`${b} ${d}`:b,i:c});}function xc(a,b){M({...Sb,message:`${Sb.message}: ${a}. In URL ${b}`})};function yc(a){var b=new zc;return A(b,1,u(a),0)}function Ac(a,b){return A(a,2,v(b),"")}function Bc(a,b){return A(a,3,v(b),"")}var zc=class extends I{getFrameType(){return F(this,1)}};function Cc(a){var b=a.m[n]|0,c=b,d=!(2&b),e=zc;b=void 0===Da?2:4;a=a.m;var f=!!(2&c);const h=f?1:b;d&&(d=!f);b=pb(a,c,1);b=Array.isArray(b)?b:Aa;var g=b[n]|0;f=!!(4&g);if(!f){var k=g;k===0&&(k=Ab(k,c));g=b;k|=1;var w=c;const B=!!(2&k);B&&(w|=2);let q=!B,G=!0,t=0,C=0;for(;t<g.length;t++){const Ya=gb(g[t],e,w);if(Ya instanceof e){if(!B){const ec=!!((Ya.m[n]|0)&2);q&&(q=!ec);G&&(G=ec)}g[C++]=Ya}}C<t&&(g.length=C);k|=4;k=G?k|16:k&-17;k=q?k|8:k&-9;g[n]=k;B&&Object.freeze(g);g=k}if(d&&!(8&g||!b.length&&
|
|
40
|
+
(h===1||h===4&&32&g))){tb(g)&&(b=Array.prototype.slice.call(b),g=Ab(g,c),c=y(a,c,1,b));d=b;e=g;for(g=0;g<d.length;g++)k=d[g],w=ob(k),k!==w&&(d[g]=w);e|=8;e=d.length?e&-17:e|16;g=d[n]=e}h===1||h===4&&32&g?tb(g)||(c=g,a=!!(32&g),g|=!b.length||16&g&&(!f||a)?2:1024,g!==c&&(b[n]=g),Object.freeze(b)):(h===2&&tb(g)&&(b=Array.prototype.slice.call(b),g=Ab(g,c),g=Bb(g,c,!1),b[n]=g,c=y(a,c,1,b)),tb(g)||(a=g,g=Bb(g,c,!1),g!==a&&(b[n]=g)));return b}function Dc(a){var b=new Ec;return zb(b,a)}var Ec=class extends I{};var Fc=class extends I{};var Gc=class extends I{};var Hc=class extends I{};var Ic=class extends I{};var Jc=class extends I{};var Kc=class extends I{getMeetPlatformInfo(){return xb(this,Ic,1)}};var Lc=class extends I{getMeetingInfo(){return xb(this,Jc,1)}};var Mc=class extends I{},N=[1,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21];var Nc=class extends I{};var Oc=class extends I{};var Pc=new Map([[2,"MAIN_STAGE"],[1,"SIDE_PANEL"]]),Qc=new Map([[0,"UNKNOWN"],[1,"OPEN_ADDON"],[2,"START_ACTIVITY"],[3,"JOIN_ACTIVITY"]]);function Rc(a){a&&typeof a.dispose=="function"&&a.dispose()};function O(){this.s=this.s;this.g=this.g}O.prototype.s=!1;O.prototype.dispose=function(){this.s||(this.s=!0,this.G())};O.prototype[Symbol.dispose]=function(){this.dispose()};function Sc(a,b){a.s?b():(a.g||(a.g=[]),a.g.push(b))}O.prototype.G=function(){if(this.g)for(;this.g.length;)this.g.shift()()};function Tc({J:a,R:b}){if(a===null)throw new J(fc("activityStartingState"));if(b||a!==void 0){if(typeof a!=="object")throw new J(L("activityStartingState",typeof a,`object${b?"":" | undefined"}`));if(a.mainStageUrl!==void 0&&typeof a.mainStageUrl!=="string")throw new J(L("mainStageUrl",typeof a.mainStageUrl,"string | undefined"));if(a.sidePanelUrl!==void 0&&typeof a.sidePanelUrl!=="string")throw new J(L("sidePanelUrl",typeof a.sidePanelUrl,"string | undefined"));if(a.additionalData!==void 0&&typeof a.additionalData!==
|
|
41
|
+
"string")throw new J(L("additionalData",typeof a.additionalData,"string | undefined"));if(Object.keys(a).length!==+!!a.mainStageUrl+ +!!a.sidePanelUrl+ +!!a.additionalData)throw new J(bc);if(Object.keys(a).length===0)throw new J(ac);}}function Uc(a){const b=[];b.push(Bc(Ac(yc(2),a.mainStageUrl),a.additionalData));b.push(Bc(Ac(yc(1),a.sidePanelUrl),a.additionalData));return b}
|
|
42
|
+
var cd=class extends O{constructor(a){super();this.context=a;this.h={};Vc(this.context.g.U,b=>{switch(z(b.content,N)){case 7:const d=this.h.frameToFrameMessage;b=H(b.content,Hc,7,N);if(d&&b){var c=F(b,1);c=Pc.get(c);if(c===void 0)throw Error("Unknown frame type.");d({originator:c,payload:E(b,2)})}}})}async getMeetingInfo(){const a=await Wc(this.context.g);return{meetingId:E(a.getMeetingInfo(),1),meetingCode:E(a.getMeetingInfo(),2)}}async getFrameOpenReason(){let a;const b=(a=this.context.h.ca)!=null?
|
|
43
|
+
a:0;let c;return(c=Qc.get(b))!=null?c:"UNKNOWN"}async getActivityStartingState(){var a=xb(await Xc(this.context.g),Ec,1);const b=a==null?void 0:Cc(a).find(c=>c.getFrameType()===2);a=a==null?void 0:Cc(a).find(c=>c.getFrameType()===1);return{mainStageUrl:(b==null?void 0:E(b,2))||void 0,sidePanelUrl:(a==null?void 0:E(a,2))||void 0,additionalData:(a==null?void 0:E(a,3))||void 0}}async setActivityStartingState(a){Tc({J:a,R:!0});var b=Uc(a);a=Yc;var c=this.context.g;var d=new Nc;b=Dc(b);d=yb(d,1,b);await a(c,
|
|
44
|
+
d)}on(a,b){this.h[a]=b}async getMeetPlatformInfo(){const a=await Zc(this.context.g);return{isMeetHardware:Cb(a.getMeetPlatformInfo())}}async closeAddon(){await $c(this.context.g)}async startActivity(a){Tc({J:a,R:!1});const b=new Oc;a&&(a=Uc(a),a=Dc(a),yb(b,1,a));await ad(this.context.g,b)}async endActivity(a){var b=bd,c=this.context.g,d=new Fc;a=A(d,1,u(a==="aab61ee0-51b4-475d-aa4d-849f2498640d"?999:0),0);await b(c,a)}};var dd=Hb(class extends I{getFrameOpenReason(){return F(this,5)}});function ed(){var a=window.location.href;var b=window.location.href;var c=(new URL(b)).searchParams.get("meet_sdk");if(c)b=dd(atob(c));else{var d;((d=window.top)!=null?d:window)===window?M(Wb):xc("meet_sdk",b);b=void 0}(c=E(b,1))||xc("meet_addon_frame_type",a);c=Number(c);if(c!==2&&c!==1)throw new J(Xb);(d=E(b,2))||xc("meet_control_channel_name",a);const e=E(b,4);e||xc("addon_cloud_project_number",a);var f;a=(f=b.getFrameOpenReason())!=null?f:0;f=E(b,3)||"https://meet.google.com";return{ca:a,frameType:c,
|
|
45
|
+
ba:d,cloudProjectNumber:e,S:f}};var fd=class extends I{};var gd=class extends I{};var hd=class extends I{};function id(){var a=new jd,b=new hd;return D(a,1,kd,b)}var jd=class extends I{},kd=[1,2];function ld(a){var b=new md;return yb(b,2,a)}function nd(a,b){return A(a,3,v(b),"")}var md=class extends I{};var od=class extends I{};var pd=class extends I{};var qd=class extends I{};var rd=class extends I{};var sd=class extends I{};var td=class extends I{};var ud=class extends I{setAddonStartingState(a){return yb(this,1,a)}};var vd=class extends I{};function wd(a,b){return D(a,2,P,b)}var Q=class extends I{},P=[1,2,5,6,7,8,9,10,11,13,14,15,16,17,18,19,20];function xd(a){return H(a,Mc,2,yd)}var zd=class extends I{},Ad=Hb(zd),yd=[1,2];class Bd{constructor(a,b){this.data=a;this.channel=b}};var Cd=Promise;function Dd(a){const b=new MessageChannel;Ed(b.port1,a);return b}function Fd(a,b){Ed(a,b);return new Gd(a)}class Gd{constructor(a){this.g=a}send(a,b,c=[]){b=Dd(b);this.g.postMessage(a,[b.port2].concat(c))}C(a,b){return new Cd(c=>{this.send(a,c,b)})}}function Ed(a,b){b&&(a.onmessage=c=>{var d=c.data;c=Fd(c.ports[0]);b(new Bd(d,c))})};var Hd=typeof AsyncContext!=="undefined"&&typeof AsyncContext.Snapshot==="function"?a=>a&&AsyncContext.Snapshot.wrap(a):a=>a;function Id(a,b){a.l(b);a.h<100&&(a.h++,b.next=a.g,a.g=b)}class Jd{constructor(a,b){this.j=a;this.l=b;this.h=0;this.g=null}get(){let a;this.h>0?(this.h--,a=this.g,this.g=a.next,a.next=null):a=this.j();return a}};function Kd(){var a=Ld;let b=null;a.g&&(b=a.g,a.g=a.g.next,a.g||(a.h=null),b.next=null);return b}class Md{constructor(){this.h=this.g=null}add(a,b){const c=Nd.get();c.set(a,b);this.h?this.h.next=c:this.g=c;this.h=c}}var Nd=new Jd(()=>new Od,a=>a.reset());class Od{constructor(){this.next=this.g=this.h=null}set(a,b){this.h=a;this.g=b;this.next=null}reset(){this.next=this.g=this.h=null}};let Pd,Qd=!1,Ld=new Md,Sd=(a,b)=>{Pd||Rd();Qd||(Pd(),Qd=!0);Ld.add(a,b)},Rd=()=>{const a=Promise.resolve(void 0);Pd=()=>{a.then(Td)}};function Td(){let a;for(;a=Kd();){try{a.h.call(a.g)}catch(b){l(b)}Id(Nd,a)}Qd=!1};function Ud(){};function R(a){this.g=0;this.T=void 0;this.l=this.h=this.j=null;this.v=this.B=!1;if(a!=Ud)try{const b=this;a.call(void 0,function(c){Vd(b,2,c)},function(c){Vd(b,3,c)})}catch(b){Vd(this,3,b)}}function Wd(){this.next=this.context=this.h=this.l=this.g=null;this.j=!1}Wd.prototype.reset=function(){this.context=this.h=this.l=this.g=null;this.j=!1};var Xd=new Jd(function(){return new Wd},function(a){a.reset()});function Yd(a,b,c){const d=Xd.get();d.l=a;d.h=b;d.context=c;return d}
|
|
46
|
+
function Zd(){let a,b;const c=new R(function(d,e){a=d;b=e});return new $d(c,a,b)}R.prototype.then=function(a,b,c){return ae(this,Hd(typeof a==="function"?a:null),Hd(typeof b==="function"?b:null),c)};R.prototype.$goog_Thenable=!0;function be(a,b){b=Hd(b);b=Yd(b,b);b.j=!0;ce(a,b)}R.prototype.cancel=function(a){if(this.g==0){const b=new S(a);Sd(function(){de(this,b)},this)}};
|
|
47
|
+
function de(a,b){if(a.g==0)if(a.j){var c=a.j;if(c.h){var d=0,e=null,f=null;for(let h=c.h;h&&(h.j||(d++,h.g==a&&(e=h),!(e&&d>1)));h=h.next)e||(f=h);e&&(c.g==0&&d==1?de(c,b):(f?(d=f,d.next==c.l&&(c.l=d),d.next=d.next.next):ee(c),fe(c,e,3,b)))}a.j=null}else Vd(a,3,b)}function ce(a,b){a.h||a.g!=2&&a.g!=3||ge(a);a.l?a.l.next=b:a.h=b;a.l=b}
|
|
48
|
+
function ae(a,b,c,d){const e=Yd(null,null,null);e.g=new R(function(f,h){e.l=b?function(g){try{const k=b.call(d,g);f(k)}catch(k){h(k)}}:f;e.h=c?function(g){try{const k=c.call(d,g);k===void 0&&g instanceof S?h(g):f(k)}catch(k){h(k)}}:h});e.g.j=a;ce(a,e);return e.g}R.prototype.ma=function(a){this.g=0;Vd(this,2,a)};R.prototype.na=function(a){this.g=0;Vd(this,3,a)};
|
|
49
|
+
function Vd(a,b,c){if(a.g==0){a===c&&(b=3,c=new TypeError("Promise cannot resolve to itself"));a.g=1;a:{var d=c,e=a.ma,f=a.na;if(d instanceof R){ce(d,Yd(e||Ud,f||null,a));var h=!0}else{if(d)try{var g=!!d.$goog_Thenable}catch(k){g=!1}else g=!1;if(g)d.then(e,f,a),h=!0;else{g=typeof d;if(g=="object"&&d!=null||g=="function")try{const k=d.then;if(typeof k==="function"){he(d,k,e,f,a);h=!0;break a}}catch(k){f.call(a,k);h=!0;break a}h=!1}}}h||(a.T=c,a.g=b,a.j=null,ge(a),b!=3||c instanceof S||ie(a,c))}}
|
|
50
|
+
function he(a,b,c,d,e){function f(k){g||(g=!0,d.call(e,k))}function h(k){g||(g=!0,c.call(e,k))}let g=!1;try{b.call(a,h,f)}catch(k){f(k)}}function ge(a){a.B||(a.B=!0,Sd(a.la,a))}function ee(a){let b=null;a.h&&(b=a.h,a.h=b.next,b.next=null);a.h||(a.l=null);return b}R.prototype.la=function(){let a;for(;a=ee(this);)fe(this,a,this.g,this.T);this.B=!1};
|
|
51
|
+
function fe(a,b,c,d){if(c==3&&b.h&&!b.j)for(;a&&a.v;a=a.j)a.v=!1;if(b.g)b.g.j=null,je(b,c,d);else try{b.j?b.l.call(b.context):je(b,c,d)}catch(e){ke.call(null,e)}Id(Xd,b)}function je(a,b,c){b==2?a.l.call(a.context,c):a.h&&a.h.call(a.context,c)}function ie(a,b){a.v=!0;Sd(function(){a.v&&ke.call(null,b)})}var ke=l;function S(a){ia.call(this,a)}ha(S,ia);S.prototype.name="cancel";function $d(a,b,c){this.promise=a;this.resolve=b;this.reject=c};let le=1,me=new WeakMap;function ne(a,b,c){var d=oe;a.h.has(b);d(b,c)}var qe=class extends O{constructor(){super();this.h=new Set}signal(){const a=new pe;this.h.add(a);Sc(this,fa(Rc,a));return a}};function oe(a,b){return new Promise(c=>{re(()=>{a.L&&(a.ea=b,a.P=!0);for(const {I:d,slot:e}of a.o.values())try{e(b,{signal:a,I:d})}catch(f){l(f)}for(const d of a.A)d.resolve(b);a.A.clear();c()})})}function Vc(a,b,c){const d=le++;re(()=>{se(a,d,b,c)});return d}
|
|
52
|
+
function se(a,b,c,d){if(!a.s)if(d){if(!d.s){const e=()=>{re(()=>{a.o.delete(b);const f=me.get(d);f&&ja(f,e)})};a.o.set(b,{I:b,slot:c,F:e});te(d,e)}}else a.o.set(b,{I:b,slot:c,F:()=>a.o.delete(b)})}
|
|
53
|
+
var pe=class extends O{constructor(){super();this.L=!1;this.o=new Map;this.A=new Set;this.P=!1}detach(a){re(()=>{const b=this.o.get(a);b&&b.F()})}value(a){return this.promise(!0,a)}next(a){return this.promise(!1,a)}promise(a,b){const c=Zd();re(()=>{if(this.s)c.reject(new S("Signal initially disposed"));else if(b&&b.s)c.reject(new S("Owner initially disposed"));else if(a&&this.L&&this.P)c.resolve(this.ea);else if(this.A.add(c),be(c.promise,()=>{this.A.delete(c)}),b){const d=()=>{c.reject(new S("Owner asynchronously disposed"))};
|
|
54
|
+
be(c.promise,()=>{const e=me.get(b);e&&ja(e,d)});te(b,d)}});return c.promise}G(){super.G();re(()=>{for(const {F:a}of this.o.values())a();this.o.clear();for(const a of this.A)a.reject(new S("Signal asynchronously disposed"));this.A.clear()})}};const ue=[];let ve=!1;function re(a){ue.push(a);we()}async function we(){if(!ve)try{ve=!0;let a=xe(0);for(;a<ue.length;)await Promise.resolve(),a=xe(a)}catch(a){l(a)}finally{ue.length=0,ve=!1}}
|
|
55
|
+
function xe(a){const b=a+100;for(;a<b&&a<ue.length;)try{ue[a++]()}catch(c){l(c)}return a}function te(a,b){if(a.s)b();else{var c=me.get(a);if(c)c.push(b);else{const d=[b];me.set(a,d);Sc(a,()=>{for(const e of[...d])e();me.delete(a)})}}};function T(a){var b=new zd;a=D(b,1,yd,a);return{content:JSON.stringify(lb(a))}}const ye=new qe;function ze(a,b){const c=ye.signal();return{channel:Fd(a,d=>{const e=b(d.data);ne(ye,c,{content:e,ka:d})}),signal:c}};let Fb;var U=class extends I{};var V=class extends I{};var Be=class extends I{h(){return H(this,U,2,Ae)}g(){return rb(this,U,2,Ae)}j(){return H(this,V,3,Ae)}l(){return rb(this,V,3,Ae)}},Ae=[2,3];var Ce=Hb(class extends I{});var De=Hb(class extends I{}),Ee=[1,2];var Fe=({destination:a,origin:b,ra:c,Y:d="ZNWN1d",onMessage:e})=>{if(b==="*")throw Error("Sending to wildcard origin not allowed.");const f=Dd(e);a.postMessage(c?{n:d,t:c}:d,b,[f.port2]);return Fd(f.port1,e)};function Ge(a,b,c){const d=new qe,e=d.signal();a=Fe({destination:window.parent,origin:b,Y:a,onMessage:f=>{const h=Ad(f.data.content);z(h,yd)===2&&ne(d,e,{content:xd(h),ka:f,messagePort:f.data.messagePort})}});return new He(e,a,c)}async function Wc(a){var b=W;var c=new Q;var d=new qd;c=D(c,19,P,d);a=await b(a,T(c));let e;return(e=xd(Ad(a.data.content)))==null?void 0:H(e,Lc,20,N)}
|
|
56
|
+
async function Xc(a){var b=W;var c=new Q;var d=new gd;c=D(c,17,P,d);a=await b(a,T(c));let e;return(e=xd(Ad(a.data.content)))==null?void 0:H(e,Gc,18,N)}async function Yc(a,b){var c=W,d=new Q;b=D(d,8,P,b);await c(a,T(b))}async function Zc(a){var b=W;var c=new Q;var d=new pd;c=D(c,18,P,d);a=await b(a,T(c));let e;return(e=xd(Ad(a.data.content)))==null?void 0:H(e,Kc,19,N)}async function $c(a){var b=W;var c=new Q;var d=new fd;c=D(c,11,P,d);await b(a,T(c))}
|
|
57
|
+
async function ad(a,b){var c=W,d=new Q;b=D(d,14,P,b);await c(a,T(b))}async function bd(a,b){var c=W,d=new Q;b=D(d,15,P,b);await c(a,T(b))}async function Ie(a){await a.h()}
|
|
58
|
+
async function W(a,b){(a=await a.channel.C(b))||M(K,"Falsy response received from the message channel."+` ${JSON.stringify(a)}`);(b=a.data)||M(K,"Data field in the response from the message channel is falsy."+` ${JSON.stringify(b)}`);(b=b.content)||M(K,"Content field in the response from the message channel is falsy."+` ${JSON.stringify(b)}`);let c=void 0;try{c=Ad(b)}catch(d){M(K,"The ControlMessage can't be deserialized."+` ${JSON.stringify(b)}. ${JSON.stringify(d)}`)}(b=xd(c))||M(K,"MeetToAddonMessage field on ControlMessage is falsy."+
|
|
59
|
+
` ${JSON.stringify(b)}`);b=b==null?void 0:H(b,Rb,10,N);if((b==null?void 0:F(b,1))!==void 0)throw new J(uc(F(b,1)));return a}async function Je(a,b,c){var d=W,e=new Q;b=D(e,1,P,b);d=await d(a,T(b));a=d.data.messagePort;var f;(d=(f=xd(Ad(d.data.content)))==null?void 0:H(f,Pb,1,N))!=null?f=d:(f=new Pb,f=A(f,1,u(0),0));return{channel:a?ze(a,c):void 0,response:f}}async function Ke(a){const b=id(),{channel:c,response:d}=await Je(a,b,e=>De(e));if(!c)throw new J(vc(d));return c}
|
|
60
|
+
async function Le(a){var b=W;var c=new Q;var d=new vd;c=D(c,5,P,d);await b(a,T(c))}async function Me(a){var b=W;var c=new Q;var d=new od;c=D(c,6,P,d);await b(a,T(c))}async function Ne(a,b,c){var d=W,e=new Q,f=new rd;b=A(f,1,u(b),0);c=A(b,2,v(c),"");e=D(e,7,P,c);await d(a,T(e))}async function Oe(a,b){var c=W,d=new Q;b=D(d,16,P,b);await c(a,T(b))}
|
|
61
|
+
class He extends O{constructor(a,b,c){super();this.U=a;this.channel=b;this.h=Nb(async()=>{var d=this.channel,e=d.C;var f=new Q;var h=new sd;f=D(f,13,P,h);await e.call(d,T(f))});a=Eb();E(a,4);cb(x(a,1));cb(x(a,2));cb(x(a,3));c=wd(new Q,nd(ld(a),c));this.channel.send(T(c));Vc(this.U,async d=>{switch(z(d.content,N)){case 16:await Ie(this)}})}};let Pe;var Qe=class{constructor(a){var b=Pe;this.h=a;this.g=b}delete(){throw Error("Not implemented.");}};var Se=class extends I{h(){return H(this,U,2,Re)}g(){return rb(this,U,2,Re)}j(){return H(this,V,3,Re)}l(){return rb(this,V,3,Re)}},Re=[2,3];var Te=class extends I{};var Ue=class extends I{};var Ve=class extends I{};var Xe=class extends I{h(){return H(this,U,2,We)}g(){return rb(this,U,2,We)}j(){return H(this,V,3,We)}l(){return rb(this,V,3,We)}},We=[2,3],Ye=[5,6];var Ze=class extends I{};var $e=class extends I{},af=[1,2,3];var bf=class extends Error{constructor(){super("Failed to create CoActivity: Connection refused - Meet refused to begin Live Sharing")}};var cf=class{constructor(a){this.config=a}start(){this.g!=null||(this.g=setInterval(()=>{this.config.ha()},this.config.da));return this}shutdown(){clearInterval(this.g)}};function df(){const a=new Map,b={set(c,d){a.set(c,d);return b},D:()=>a};return b};function ef(a){if(a.g()){a=a.h().m;a=pb(a,a[n]|0,1,ub);var b=a==null?oa():a;a=Uint8Array;qa(na);var c=b.g;if(!(c==null||c!=null&&c instanceof Uint8Array))if(typeof c==="string"){ka.test(c)&&(c=c.replace(ka,ma));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.g=c;return{bytes:new a(b||0)}}}function ff(a,b){b=gf(b);D(a,2,We,b);return a}function hf(a,b){b=gf(b);D(a,2,Re,b);return a}
|
|
62
|
+
function gf(a){var b=new U;return A(b,1,za(a.bytes,!1),oa())}function jf(a){if(a.l()){a=a.j();var b;let e;var c=E(a,1),d=(e=(b=xb(a,Ib,2))==null?void 0:Db(b))!=null?e:0;b=a.m;b=pb(b,b[n]|0,4,$a);return{mediaId:c,mediaPlayoutPosition:d,mediaPlayoutRate:b!=null?b:0,playbackState:kf.get(F(a,3))}}}function lf(a,b){b=mf(b);D(a,3,We,b);return a}function nf(a,b){b=mf(b);D(a,3,Re,b);return a}
|
|
63
|
+
const kf=df().set(0,"INVALID").set(1,"BUFFERING").set(2,"PLAY").set(3,"PAUSE").set(4,"ENDED").D(),of=df().set("INVALID",0).set("BUFFERING",1).set("PLAY",2).set("PAUSE",3).set("ENDED",4).D();
|
|
64
|
+
function mf(a){var b=new V;b=A(b,1,v(a.mediaId),"");var c=a.mediaPlayoutRate;if(c!=null&&typeof c!=="number")throw Error(`Value of float/double field must be a number, found ${typeof c}: ${c}`);b=A(b,4,c,0);c=new Ib;c=A(c,1,db(a.mediaPlayoutPosition),"0");b=yb(b,2,c);a=of.get(a.playbackState);return A(b,3,u(a),0)}function pf({activityTitle:a}){var b=new Ve;return qb(b,4,v(a))}function qf(a,b){var c=new Ue;b=A(c,1,u(b.u),0);D(a,6,Ye,b);return a}function rf(a){var b=new Te;D(a,5,Ye,b);return a};const sf=df().set("co-doing",1).set("co-watching",2).D();async function tf(a,b,c){var d=b.C,e=new $e;var f=new Ze;f=A(f,1,v(a.activityTitle),"");var h=sf.get(a.K);f=A(f,2,u(h),0);e=D(e,3,af,f);d=await d.call(b,e,Ce);let g;if((g=Cb(d))!=null&&g)return new uf(a,b,c,xb(d,Be,2));throw new bf;}function vf(a,b){const c=a.config.N(b);c&&!a.config.M(a.g,c)&&(a.g=c,a.j=Db(b),a.v(a.g))}function X(a,b){const {state:c,fa:d,context:e}=b(a.g);a.g=c;a.notify(a.g,e,d)}
|
|
65
|
+
class uf{constructor(a,b,c,d){this.l=a;this.h=b;this.config=c;this.v=Jb(e=>void this.l.O(e));wf(this.h,e=>{const f=z(e,Ee);switch(f){case 1:vf(this,H(e,Be,1,Ee));break;case 2:case 0:console.warn(`IllegalMessage: ${f} - ${"Unhandled message"} - ${"Please raise a bug with the MeetJS team"}`)}});this.B=(new cf({da:1E3,ha:()=>{var e,f,h=(f=(e=this.l).ja)==null?void 0:f.call(e);if(this.g!==null){this.g={...this.g,...h};e=new $e;f=this.config;h=f.W;var g=new Se;g=A(g,1,db(this.j),"0");f=h.call(f,g,this.g);
|
|
66
|
+
e=D(e,1,af,f);this.h.send(e)}}})).start();this.g=null;this.j=0;d&&vf(this,d)}disconnect(){this.h.shutdown();this.B.shutdown()}notify(a,b,c){var d=c?pf(c):void 0;c=this.config;var e=c.X;var f=new Xe;f=A(f,1,db(this.j),"0");d=yb(f,4,d);a=e.call(c,d,a);a=this.config.V(a,b);b=this.h;c=b.send;e=new $e;a=D(e,2,af,a);c.call(b,a)}};var xf=class{constructor(a){this.g=a}broadcastStateUpdate(a){X(this.g,()=>({state:a,context:{}}))}disconnect(){this.g.disconnect()}};function yf(a,b){return a==null||b==null?!1:a.bytes.length===b.bytes.length&&a.bytes.every((c,d)=>c===b.bytes[d])};var zf=class{constructor(a){this.g=a}notifySwitchedToMedia(a,b,c){X(this.g,()=>({state:{mediaId:b,mediaPlayoutRate:1,mediaPlayoutPosition:c,playbackState:"PLAY"},fa:{activityTitle:a},context:{u:1}}))}notifyPauseState(a,b){X(this.g,c=>{if(c==null)throw Error("Invalid before coWatchingState");return{state:{...c,playbackState:a?"PAUSE":"PLAY",mediaPlayoutPosition:b},context:{u:3}}})}notifySeekToTimestamp(a){X(this.g,b=>{if(b==null)throw Error("Invalid before coWatchingState");return{state:{...b,mediaPlayoutPosition:a},
|
|
67
67
|
context:{u:2}}})}notifyPlayoutRate(a){X(this.g,b=>{if(b==null)throw Error("Invalid before coWatchingState");return{state:{...b,mediaPlayoutRate:a},context:{u:4}}})}notifyBuffering(a){X(this.g,b=>{if(b==null)throw Error("Invalid before coWatchingState");return{state:{...b,mediaPlayoutPosition:a,playbackState:"BUFFERING"},context:{u:3}}})}notifyReady(a){X(this.g,b=>{if(b==null)throw Error("Invalid before coWatchingState");return{state:{...b,mediaPlayoutPosition:a},context:{u:3}}})}disconnect(){this.g.disconnect()}};
|
|
68
|
-
function
|
|
69
|
-
async function
|
|
70
|
-
+!!a.additionalData)throw new J(
|
|
71
|
-
a)}async createRoomsStandaloneClient(){var a=this.g;if(a.h.frameType!==2)throw new J(
|
|
72
|
-
return
|
|
68
|
+
function Af(a,b){if(a==null||b==null)return!1;const c=a.playbackState==="PLAY"?3*Math.max(a.mediaPlayoutRate,1):0,d=Math.abs(a.mediaPlayoutPosition-b.mediaPlayoutPosition);return a.mediaId===b.mediaId&&a.mediaPlayoutRate===b.mediaPlayoutRate&&d<=c&&a.playbackState===b.playbackState};function wf(a,b){const c=Vc(a.signal,d=>{b(d)});a.o.push(c)}var Bf=class{constructor(a,b){this.channel=a;this.signal=b;this.o=[]}send(a){this.channel.send(JSON.stringify(lb(a)))}async C(a,b){a=await this.channel.C(JSON.stringify(lb(a)));return b(a.data)}shutdown(){this.o.forEach(a=>{this.signal.detach(a)})}};function Cf(a,b){var c=Df;const d=a.signal(),e=a.signal();Vc(b,f=>{const h=c(f)?d:e;ne(a,h,f)},a);return{ia:d,ga:e}}function Ef(a,b,c,d=e=>e){Vc(c,e=>{ne(a,b,d(e))},a)};async function Ff(a,b){if(b)return a=await tf({activityTitle:b.activityTitle,K:"co-watching",ja:()=>b.onCoWatchingStateQuery(),O:c=>{b.onCoWatchingStateChanged(c)}},a,{X:lf,W:nf,V:qf,N:jf,M:Af}),new zf(a)}async function Gf(a,b){if(b)return a=await tf({activityTitle:b.activityTitle,K:"co-doing",O:c=>{b.onCoDoingStateChanged(c)}},a,{X:ff,W:hf,V:rf,N:ef,M:yf}),new xf(a)}
|
|
69
|
+
async function Hf(a){const b=new qe,c=b.signal();a=await a;Ef(b,c,a.signal,f=>f.content);const {ia:d,ga:e}=Cf(b,c);return{Z:new Bf(a.channel,d),aa:new Bf(a.channel,e)}}function Df(a){a:switch(z(a,Ee)){case 1:a=H(a,Be,1,Ee);break a;default:throw Error("CA Message arrived with no known content message set");}return a.g()};async function If(a,b){({Z:a}=await Hf(Ke(a.g)));b=await Gf(a,b);if(!b)throw Error("Failed to create co-doing session");return b}async function Jf(a,b){({aa:a}=await Hf(Ke(a.g)));b=await Ff(a,b);if(!b)throw Error("Failed to create co-watching session");return b};var Kf=class extends cd{async notifySidePanel(a){await Ne(this.context.g,1,a)}async unloadSidePanel(){await Le(this.context.g)}async loadSidePanel(){await Me(this.context.g)}};var Lf=class extends cd{async setAddonStartingState(a){if(a===null)throw new J(fc("addonStartingState"));if(typeof a!=="object")throw new J(L("addonStartingState",typeof a,"object | undefined"));if(a.sidePanelUrl!==void 0&&typeof a.sidePanelUrl!=="string")throw new J(L("sidePanelUrl",typeof a.sidePanelUrl,"string | undefined"));if(a.additionalData!==void 0&&typeof a.additionalData!=="string")throw new J(L("additionalData",typeof a.additionalData,"string | undefined"));if(Object.keys(a).length!==+!!a.sidePanelUrl+
|
|
70
|
+
+!!a.additionalData)throw new J(dc);if(Object.keys(a).length===0)throw new J(cc);var b=[];b.push(Bc(Ac(yc(1),a.sidePanelUrl),a.additionalData));a=this.context.g;var c=new ud,d=c.setAddonStartingState,e=new td;b=zb(e,b);await Oe(a,d.call(c,b))}};var Mf=class extends cd{async notifyMainStage(a){await Ne(this.context.g,2,a)}};var Nf=class{constructor(a){a=a.cloudProjectNumber;const b=ed();if(b.cloudProjectNumber!==a)throw new J(Yb);const c=b.S,d=b.ba;let e;Pe=(e=Pe)!=null?e:Ge(d,c,a);this.g=new Qe(b)}async createMainStageClient(){var a=this.g;if(a.h.frameType!==2)throw new J(Tb);return await Promise.resolve(new Kf(a))}async createSidePanelClient(){var a=this.g;if(a.h.frameType!==1)throw new J(Ub);return await Promise.resolve(new Mf(a))}async createCoWatchingClient(a){return await Jf(this.g,a)}async createCoDoingClient(a){return await If(this.g,
|
|
71
|
+
a)}async createRoomsStandaloneClient(){var a=this.g;if(a.h.frameType!==2)throw new J(Tb);return await Promise.resolve(new Lf(a))}};let Of=null;for(var Pf={addon:{getFrameType:function(){a:{var a=ed().frameType;switch(a){case 2:a="MAIN_STAGE";break a;case 1:a="SIDE_PANEL";break a;default:throw Error(`Unknown frame type: ${a}`);}}return a},createAddonSession:async function(a){if(a===null)throw new J(fc("config"));if(typeof a!=="object")throw new J(L("config",typeof a,"object"));if(typeof a.cloudProjectNumber!=="string")throw new J(L("cloudProjectNumber",typeof a.cloudProjectNumber,"string"));if(Of&&ed().S!=="integration.test.google.com")throw new J(oc);
|
|
72
|
+
return Of=new Nf(a)}}},Qf=["meet"],Y=ea,Z;Qf.length&&(Z=Qf.shift());)Qf.length||Pf===void 0?Y[Z]&&Y[Z]!==Object.prototype[Z]?Y=Y[Z]:Y=Y[Z]={}:Y[Z]=Pf;}).apply(topLevel);export const meet = topLevel.meet;
|
|
@@ -11,9 +11,9 @@ function ya(a,b,d,e){if(a==null){var c=96;d?(a=[d],c|=512):a=[];b&&(c=c&-3352166
|
|
|
11
11
|
c=c&-33521665|(g&1023)<<15;break a}}if(b){h=Math.max(b,f-(c&512?0:-1));if(h>1024)throw Error("spvt");c=c&-33521665|(h&1023)<<15}}}e===3&&(c|=16384);a[D]=c;return a}function za(){if(C!=null){var a;var b=(a=z)!=null?a:z={};a=b[C]||0;a>=5||(b[C]=a+1,b=Error(),y(b,"incident"),ea(b))}};function K(a,b,d){const e=a.i;let c=e[D]|0;G(c);L(e,c,b,d);return a}function L(a,b,d,e){const c=b&512?0:-1,f=d+c;var g=a.length-1;if(f>=g&&b&256)return a[g][d]=e,b;if(f<=g)return a[f]=e,b;e!==void 0&&(g=b>>15&1023||536870912,d>=g?e!=null&&(a[g+c]={[d]:e},b|=256,a[D]=b):a[f]=e);return b}function M(a,b,d,e){const c=a.i;let f=c[D]|0;G(f);L(c,f,b,(e==="0"?Number(d)===0:d===e)?void 0:d);return a}function N(a,b){a=(2&b?a|2:a&-3)|32;return a&=-1025}function Aa(a,b){32&b||(a&=-33);return a};var O=class{constructor(a){this.i=ya(a,void 0,void 0,3)}toJSON(){var a=ua(this);return a}};O.prototype.v=fa;O.prototype.toString=function(){return this.i.toString()};function P(a,b){for(;b>127;)a.g.push(b&127|128),b>>>=7;a.g.push(b)}var Ba=class{constructor(){this.g=[]}length(){return this.g.length}end(){const a=this.g;this.g=[];return a}};function Q(a,b){b.length!==0&&(a.l.push(b),a.h+=b.length)}function Ca(a,b){P(a.g,b*8+2);b=a.g.end();Q(a,b);b.push(a.h);return b}function Da(a,b){var d=b.pop();for(d=a.h+a.g.length()-d;d>127;)b.push(d&127|128),d>>>=7,a.h++;b.push(d);a.h++}var Ea=class{constructor(){this.l=[];this.h=0;this.g=new Ba}};function R(){const a=class{constructor(){throw Error();}};Object.setPrototypeOf(a,a.prototype);return a}var S=R(),Fa=R();var U=class{constructor(a,b){this.g=a;a=aa(S);this.h=!!a&&b===a||!1}};function Ga(a,b,d,e,c){b=Ha(b,e);b!=null&&(d=Ca(a,d),c(b,a),Da(a,d))}const Ia=new U(Ga,S),Ja=new U(Ga,S);var Ka=Symbol(),La=Symbol();let Ma,V;
|
|
12
12
|
function W(a){var b=Na,d=Oa,e=a[Ka];if(e)return e;e={};e.B=a;e.m=wa(a[0]);var c=a[1];let f=1;c&&c.constructor===Object&&(e.s=c,c=a[++f],typeof c==="function"&&(e.u=!0,Ma!=null||(Ma=c),V!=null||(V=a[f+1]),c=a[f+=2]));const g={};for(;c&&Array.isArray(c)&&c.length&&typeof c[0]==="number"&&c[0]>0;){for(var h=0;h<c.length;h++)g[c[h]]=c;c=a[++f]}for(h=1;c!==void 0;){typeof c==="number"&&(h+=c,c=a[++f]);let l;var k=void 0;c instanceof U?l=c:(l=Ia,f--);let q;if((q=l)==null?0:q.h){c=a[++f];k=a;var n=f;typeof c===
|
|
13
13
|
"function"&&(c=c(),k[n]=c);k=c}c=a[++f];n=h+1;typeof c==="number"&&c<0&&(n-=c,c=a[++f]);for(;h<n;h++){const m=g[h];k?d(e,h,l,k,m):b(e,h,l,m)}}return a[Ka]=e}function Ha(a,b){if(a instanceof O)return a.i;if(Array.isArray(a))return xa(a,b,!1)};function Na(a,b,d){a[b]=d.g}function Oa(a,b,d,e){let c,f;const g=d.g;a[b]=(h,k,n)=>g(h,k,n,f||(f=W(e).m),c||(c=Pa(e)))}function Pa(a){let b=a[La];if(!b){const d=W(a);b=(e,c)=>Qa(e,c,d);a[La]=b}return b}function Qa(a,b,d){ia(a,a[D]|0|(d.m[1]?512:0),(e,c)=>{if(c!=null){var f=Ra(d,e);f&&f(b,c,e)}})}
|
|
14
|
-
function Ra(a,b){var d=a[b];if(d)return d;if(d=a.s)if(d=d[b]){d=Array.isArray(d)?d[0]instanceof U?d:[Ja,d]:[d,void 0];var e=d[0].g;if(d=d[1]){const c=Pa(d),f=W(d).m;d=a.u?V(f,c):(g,h,k)=>e(g,h,k,f,c)}else d=e;return a[b]=d}};function Sa(a,b,d){b=b==null||typeof b==="string"?b:void 0;b!=null&&(b=(u||(u=new TextEncoder)).encode(b),P(a.g,d*8+2),P(a.g,b.length),Q(a,a.g.end()),Q(a,b))};function Ta(a){var b=new Ua;if(a!=null){if(!oa(a))throw b=Error("enum"),y(b,"warning"),b;a|=0}return M(b,1,a,0)}var Ua=class extends O{};var Va=class extends O{};var Wa=class extends O{};Wa.prototype.g=function(a){return function(){const b=new Ea;Qa(this.i,b,W(a));Q(b,b.g.end());const d=new Uint8Array(b.h),e=b.l,c=e.length;let f=0;for(let g=0;g<c;g++){const h=e[g];d.set(h,f);f+=h.length}b.l=[d];return d}}([0,new U(Sa,Fa),-1,[0,function(a,b,d=S){return new U(b,d)}(function(a,b,d,e,c){if(a.g()!==2)return!1;var f=a.h;e=xa(void 0,e,!0);var g=b[D]|0;G(g);if(d===-1)var h=null;else{h=d+(g&512?0:-1);var k=b.length-1;h
|
|
15
|
-
F;if(64&g||!(8192&g)||!n){let l=k=n?h[D]|0:0;if(!n||2&l||2&l&&4&l||1024&l||4&l&&!(32&l))h=Array.prototype.slice.call(h),l=N(l,g),g=L(b,g,d,h);b=l;b===0&&(b=N(b,g));l=Aa((b|1)&-29,g);l!==k&&(h[D]=l)}h.push(e);f.call(a,e,c);return!0},function(a,b,d,e,c){if(Array.isArray(b))for(let n=0;n<b.length;n++){var f=a,g=d,h=c,k=Ha(b[n],e);k!=null&&(g=Ca(f,g),h(k,f),Da(f,g))}}),[0,new U(function(a,b,d){b=pa(b);if(b!=null)if(b=parseInt(b,10),P(a.g,d*8),a=a.g,d=b,d>=0)P(a,d);else{for(b=0;b<9;b++)a.g.push(d&
|
|
16
|
-
128),d>>=7;a.g.push(1)}},R()),new U(Sa,Fa),-1]],new U(function(a,b,d){b=b==null||typeof b==="boolean"?b:typeof b==="number"?!!b:void 0;b!=null&&(P(a.g,d*8),a.g.g.push(b?1:0))},R())]);function Xa(){let a,b;const d=(b=(a=(new URL(Ya||window.location.href)).searchParams.get("meet_capture_handle_origins"))==null?void 0:a.split(",").filter(e=>{try{return(new URL(e)).origin.endsWith(".google.com")}catch(c){return!1}}))!=null?b:[];return d.length===0?Za:d}let Ya="";const Za=["https://meet.google.com"];for(var $a={exposeToMeetWhenScreensharing:function(a){var b=a.A,d=a.cloudProjectNumber,e=a.additionalData,c=a.mainStageUrl,f=a.sidePanelUrl;a=a.startActivityOnOpen;d||t(ba);var g=new Wa;d=K(g,2,I(d));b&&K(d,1,I(b));b=[];e&&!a&&t(ca);c&&!a&&t(da);if(f){g=b.push;var h=Ta(1);f=M(h,2,I(f),"");f=M(f,3,I(e),"");g.call(b,f)}c&&(f=b.push,g=Ta(2),c=M(g,2,I(c),""),e=M(c,3,I(e),""),f.call(b,e));{e=new Va;c=b;const w=e.i;let B=w[D]|0;G(B);if(c==null)L(w,B,1);else{f=b=c[D]|0;h=(g=!!(2&b)&&!!(4&b)||!!(1024&b))||
|
|
14
|
+
function Ra(a,b){var d=a[b];if(d)return d;if(d=a.s)if(d=d[b]){d=Array.isArray(d)?d[0]instanceof U?d:[Ja,d]:[d,void 0];var e=d[0].g;if(d=d[1]){const c=Pa(d),f=W(d).m;d=a.u?V(f,c):(g,h,k)=>e(g,h,k,f,c)}else d=e;return a[b]=d}};function Sa(a,b,d){b=b==null||typeof b==="string"?b:void 0;b!=null&&(b=(u||(u=new TextEncoder)).encode(b),P(a.g,d*8+2),P(a.g,b.length),Q(a,a.g.end()),Q(a,b))};function Ta(a){var b=new Ua;if(a!=null){if(!oa(a))throw b=Error("enum"),y(b,"warning"),b;a|=0}return M(b,1,a,0)}var Ua=class extends O{};var Va=class extends O{};var Wa=class extends O{};Wa.prototype.g=function(a){return function(){const b=new Ea;Qa(this.i,b,W(a));Q(b,b.g.end());const d=new Uint8Array(b.h),e=b.l,c=e.length;let f=0;for(let g=0;g<c;g++){const h=e[g];d.set(h,f);f+=h.length}b.l=[d];return d}}([0,new U(Sa,Fa),-1,[0,function(a,b,d=S){return new U(b,d)}(function(a,b,d,e,c){if(a.g()!==2)return!1;var f=a.h;e=xa(void 0,e,!0);var g=b[D]|0;G(g);if(d===-1)var h=null;else{h=d+(g&512?0:-1);var k=b.length-1;h>=k&&g&256?h=b[k][d]:h<=k?h=b[h]:h=void 0}h=Array.isArray(h)?h:F;const n=
|
|
15
|
+
h!==F;if(64&g||!(8192&g)||!n){let l=k=n?h[D]|0:0;if(!n||2&l||2&l&&4&l||1024&l||4&l&&!(32&l))h=Array.prototype.slice.call(h),l=N(l,g),g=L(b,g,d,h);b=l;b===0&&(b=N(b,g));l=Aa((b|1)&-29,g);l!==k&&(h[D]=l)}h.push(e);f.call(a,e,c);return!0},function(a,b,d,e,c){if(Array.isArray(b))for(let n=0;n<b.length;n++){var f=a,g=d,h=c,k=Ha(b[n],e);k!=null&&(g=Ca(f,g),h(k,f),Da(f,g))}}),[0,new U(function(a,b,d){b=pa(b);if(b!=null)if(b=parseInt(b,10),P(a.g,d*8),a=a.g,d=b,d>=0)P(a,d);else{for(b=0;b<9;b++)a.g.push(d&
|
|
16
|
+
127|128),d>>=7;a.g.push(1)}},R()),new U(Sa,Fa),-1]],new U(function(a,b,d){b=b==null||typeof b==="boolean"?b:typeof b==="number"?!!b:void 0;b!=null&&(P(a.g,d*8),a.g.g.push(b?1:0))},R())]);function Xa(){let a,b;const d=(b=(a=(new URL(Ya||window.location.href)).searchParams.get("meet_capture_handle_origins"))==null?void 0:a.split(",").filter(e=>{try{return(new URL(e)).origin.endsWith(".google.com")}catch(c){return!1}}))!=null?b:[];return d.length===0?Za:d}let Ya="";const Za=["https://meet.google.com"];for(var $a={exposeToMeetWhenScreensharing:function(a){var b=a.A,d=a.cloudProjectNumber,e=a.additionalData,c=a.mainStageUrl,f=a.sidePanelUrl;a=a.startActivityOnOpen;d||t(ba);var g=new Wa;d=K(g,2,I(d));b&&K(d,1,I(b));b=[];e&&!a&&t(ca);c&&!a&&t(da);if(f){g=b.push;var h=Ta(1);f=M(h,2,I(f),"");f=M(f,3,I(e),"");g.call(b,f)}c&&(f=b.push,g=Ta(2),c=M(g,2,I(c),""),e=M(c,3,I(e),""),f.call(b,e));{e=new Va;c=b;const w=e.i;let B=w[D]|0;G(B);if(c==null)L(w,B,1);else{f=b=c[D]|0;h=(g=!!(2&b)&&!!(4&b)||!!(1024&b))||
|
|
17
17
|
Object.isFrozen(c);var k=!0,n=!0;for(let T=0;T<c.length;T++){var l=c[T];g||(l=!!((l.i[D]|0)&2),k&&(k=!l),n&&(n=l))}g||(b=k?13:5,b=n?b|16:b&-17);h&&b===f||(c=Array.prototype.slice.call(c),f=0,b=N(b,B),b=Aa(b,B));b!==f&&(c[D]=b);L(w,B,1,c)}}e==null&&(e=void 0);e=K(d,3,e);if(a!=null&&typeof a!=="boolean"){var q=typeof a;throw Error(`Expected boolean but got ${q!="object"?q:a?Array.isArray(a)?"array":q:"null"}: ${a}`);}K(e,4,a);a=d.g();var m;m===void 0&&(m=0);if(!x)for(x={},d="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789".split(""),
|
|
18
18
|
e=["+/=","+/","-_=","-_.","-_"],c=0;c<5;c++)for(b=d.concat(e[c].split("")),v[c]=b,f=0;f<b.length;f++)g=b[f],x[g]===void 0&&(x[g]=f);m=v[m];d=Array(Math.floor(a.length/3));e=m[64]||"";for(c=b=0;b<a.length-2;b+=3)h=a[b],k=a[b+1],g=a[b+2],f=m[h>>2],h=m[(h&3)<<4|k>>4],k=m[(k&15)<<2|g>>6],g=m[g&63],d[c++]=f+h+k+g;f=0;g=e;switch(a.length-b){case 2:f=a[b+1],g=m[(f&15)<<2]||e;case 1:a=a[b],d[c]=m[a>>2]+m[(a&3)<<4|f>>4]+g+e}a=d.join("");m=window;m.top===m.self&&(a={handle:a,permittedOrigins:Xa(),exposeOrigin:!0},
|
|
19
19
|
(q=m.navigator.mediaDevices)==null||q.setCaptureHandleConfig(a))}},X=["meet","addon","screensharing"],Y=p,Z;X.length&&(Z=X.shift());)X.length||$a===void 0?Y[Z]&&Y[Z]!==Object.prototype[Z]?Y=Y[Z]:Y=Y[Z]={}:Y[Z]=$a;}).apply(topLevel);export const meet = topLevel.meet;
|
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": "1.2.0-dev-
|
|
4
|
+
"version": "1.2.0-dev-736279196",
|
|
5
5
|
"repository": "googleworkspace/meet",
|
|
6
6
|
"license": "SEE LICENSE IN LICENSE",
|
|
7
7
|
"homepage": "https://developers.google.com/meet/add-ons/guides/overview",
|