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