@streamlayer/react 1.14.2 → 1.14.3
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/lib/cjs/useStreamLayerApp2.js +1 -1
- package/lib/classic/cjs/useStreamLayerApp2.js +1 -1
- package/lib/classic/es/useStreamLayerApp2.js +1 -1
- package/lib/classic/style.css +1 -1
- package/lib/dist/cjs/masters.js +1 -1
- package/lib/dist/es/masters.js +1 -1
- package/lib/dist/style.css +1 -1
- package/lib/es/useStreamLayerApp2.js +1 -1
- package/lib/style.css +1 -1
- package/package.json +14 -14
package/lib/dist/cjs/masters.js
CHANGED
|
@@ -73,4 +73,4 @@ Error generating stack: `+s.message+`
|
|
|
73
73
|
`),o=`
|
|
74
74
|
`+n+(s.length?r("│"):" ")+" ";return n+i.join(o)+`
|
|
75
75
|
`+s.map(function(l,c){var d=c===s.length-1,p=l.nodes&&l.nodes.length,f=n+(d?" ":r("│"))+" ";return n+r(d?"└":"├")+r("─")+r(p?"┬":"─")+" "+e(l,f,a).slice(n.length+2)}).join("")};const iH=sH,y6=Symbol("avvio.TimeTree.untrackNode"),Pc=Symbol("avvio.TimeTree.trackNode"),T6=Symbol("avvio.TimeTree.getParent"),v6=Symbol("avvio.TimeTree.getNode"),k6=Symbol("avvio.TimeTree.addNode");let oH=class{constructor(){this.root=null,this.tableId=new Map,this.tableLabel=new Map}[Pc](e){this.tableId.set(e.id,e),this.tableLabel.has(e.label)?this.tableLabel.get(e.label).push(e):this.tableLabel.set(e.label,[e])}[y6](e){this.tableId.delete(e.id);const t=this.tableLabel.get(e.label);if(t.id){this.tableLabel.delete(e.label);return}t.pop(),t.length===0&&this.tableLabel.delete(e.label)}[T6](e){if(e===null)return this.root;const t=this.tableLabel.get(e);return t.id?t:t[t.length-1]}[v6](e){return this.tableId.get(e)}[k6](e,t,n){if(e===null)return this.root={id:"root",label:t,start:n,nodes:[]},this[Pc](this.root),this.root.id;const a=this[T6](e),r=`${t}-${Math.random()}`,s={id:r,parent:e,start:n,label:t,nodes:[]};return a.nodes.push(s),this[Pc](s),r}start(e,t,n=Date.now()){return this[k6](e,t,n)}stop(e,t=Date.now()){const n=this[v6](e);n&&(n.stop=t,n.diff=n.stop-n.start||0,this[y6](n))}toJSON(){return Object.assign({},this.root)}prittyPrint(){const e=n=>(n.label=`${n.label} ${n.diff} ms`,n.nodes.length>0&&(n.nodes=n.nodes.map(a=>e(a))),n),t=e(this.toJSON());return iH(t)}};var lH=oH,i0={exports:{}},k2={exports:{}},Mc,b6;function cH(){if(b6)return Mc;b6=1;var e=1e3,t=e*60,n=t*60,a=n*24,r=a*7,s=a*365.25;Mc=function(d,p){p=p||{};var f=typeof d;if(f==="string"&&d.length>0)return i(d);if(f==="number"&&isFinite(d))return p.long?l(d):o(d);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(d))};function i(d){if(d=String(d),!(d.length>100)){var p=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(d);if(p){var f=parseFloat(p[1]),y=(p[2]||"ms").toLowerCase();switch(y){case"years":case"year":case"yrs":case"yr":case"y":return f*s;case"weeks":case"week":case"w":return f*r;case"days":case"day":case"d":return f*a;case"hours":case"hour":case"hrs":case"hr":case"h":return f*n;case"minutes":case"minute":case"mins":case"min":case"m":return f*t;case"seconds":case"second":case"secs":case"sec":case"s":return f*e;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return f;default:return}}}}function o(d){var p=Math.abs(d);return p>=a?Math.round(d/a)+"d":p>=n?Math.round(d/n)+"h":p>=t?Math.round(d/t)+"m":p>=e?Math.round(d/e)+"s":d+"ms"}function l(d){var p=Math.abs(d);return p>=a?c(d,p,a,"day"):p>=n?c(d,p,n,"hour"):p>=t?c(d,p,t,"minute"):p>=e?c(d,p,e,"second"):d+" ms"}function c(d,p,f,y){var T=p>=f*1.5;return Math.round(d/f)+" "+y+(T?"s":"")}return Mc}function uH(e){n.debug=n,n.default=n,n.coerce=l,n.disable=s,n.enable=r,n.enabled=i,n.humanize=cH(),n.destroy=c,Object.keys(e).forEach(d=>{n[d]=e[d]}),n.names=[],n.skips=[],n.formatters={};function t(d){let p=0;for(let f=0;f<d.length;f++)p=(p<<5)-p+d.charCodeAt(f),p|=0;return n.colors[Math.abs(p)%n.colors.length]}n.selectColor=t;function n(d){let p,f=null,y,T;function v(...C){if(!v.enabled)return;const h=v,g=Number(new Date),k=g-(p||g);h.diff=k,h.prev=p,h.curr=g,p=g,C[0]=n.coerce(C[0]),typeof C[0]!="string"&&C.unshift("%O");let _=0;C[0]=C[0].replace(/%([a-zA-Z%])/g,(I,O)=>{if(I==="%%")return"%";_++;const N=n.formatters[O];if(typeof N=="function"){const x=C[_];I=N.call(h,x),C.splice(_,1),_--}return I}),n.formatArgs.call(h,C),(h.log||n.log).apply(h,C)}return v.namespace=d,v.useColors=n.useColors(),v.color=n.selectColor(d),v.extend=a,v.destroy=n.destroy,Object.defineProperty(v,"enabled",{enumerable:!0,configurable:!1,get:()=>f!==null?f:(y!==n.namespaces&&(y=n.namespaces,T=n.enabled(d)),T),set:C=>{f=C}}),typeof n.init=="function"&&n.init(v),v}function a(d,p){const f=n(this.namespace+(typeof p>"u"?":":p)+d);return f.log=this.log,f}function r(d){n.save(d),n.namespaces=d,n.names=[],n.skips=[];let p;const f=(typeof d=="string"?d:"").split(/[\s,]+/),y=f.length;for(p=0;p<y;p++)f[p]&&(d=f[p].replace(/\*/g,".*?"),d[0]==="-"?n.skips.push(new RegExp("^"+d.slice(1)+"$")):n.names.push(new RegExp("^"+d+"$")))}function s(){const d=[...n.names.map(o),...n.skips.map(o).map(p=>"-"+p)].join(",");return n.enable(""),d}function i(d){if(d[d.length-1]==="*")return!0;let p,f;for(p=0,f=n.skips.length;p<f;p++)if(n.skips[p].test(d))return!1;for(p=0,f=n.names.length;p<f;p++)if(n.names[p].test(d))return!0;return!1}function o(d){return d.toString().substring(2,d.toString().length-2).replace(/\.\*\?$/,"*")}function l(d){return d instanceof Error?d.stack||d.message:d}function c(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")}return n.enable(n.load()),n}var dH=uH;(function(e,t){t.formatArgs=a,t.save=r,t.load=s,t.useColors=n,t.storage=i(),t.destroy=(()=>{let l=!1;return()=>{l||(l=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"];function n(){return typeof window<"u"&&window.process&&(window.process.type==="renderer"||window.process.__nwjs)?!0:typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/)?!1:typeof document<"u"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window<"u"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)}function a(l){if(l[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+l[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),!this.useColors)return;const c="color: "+this.color;l.splice(1,0,c,"color: inherit");let d=0,p=0;l[0].replace(/%[a-zA-Z%]/g,f=>{f!=="%%"&&(d++,f==="%c"&&(p=d))}),l.splice(p,0,c)}t.log=console.debug||console.log||(()=>{});function r(l){try{l?t.storage.setItem("debug",l):t.storage.removeItem("debug")}catch{}}function s(){let l;try{l=t.storage.getItem("debug")}catch{}return!l&&typeof re<"u"&&"env"in re&&(l=re.env.DEBUG),l}function i(){try{return localStorage}catch{}}e.exports=dH(t);const{formatters:o}=e.exports;o.j=function(l){try{return JSON.stringify(l)}catch(c){return"[UnexpectedJSONParseError]: "+c.message}}})(k2,k2.exports);var a7=k2.exports;const mH=L9,pH=F9.EventEmitter,fH=f1.inherits,et=a7("avvio"),{AVV_ERR_READY_TIMEOUT:hH}=n7,Dc=Symbol.for("plugin-meta");function gH(e,t){return e[Dc]&&e[Dc].name?e[Dc].name:typeof t<"u"&&typeof t!="function"&&t.name?t.name:e.name?e.name:e.toString().split(`
|
|
76
|
-
`).slice(0,2).map(n=>n.trim()).join(" -- ")}function yH(){const e={};return e.promise=new Promise((t,n)=>{e.resolve=t,e.reject=n}),e}function ps(e,t,n,a,r){this.started=!1,this.func=t,this.opts=n,this.onFinish=null,this.parent=e,this.timeout=r===void 0?e._timeout:r,this.name=gH(t,n),this.isAfter=a,this.q=mH(e,TH,1),this.q.pause(),this._error=null,this.loaded=!1,this._promise=null}fH(ps,pH);ps.prototype.exec=function(e,t){const n=this.func;let a=!1;const r=this.name;if(this.parent._error&&!this.isAfter){et("skipping loading of plugin as parent errored and it is not an after",r),re.nextTick(t);return}if(this.isAfter)this.server=e;else try{this.server=this.parent.override(e,n,this.opts)}catch(l){return et("override errored",r),t(l)}this.opts=typeof this.opts=="function"?this.opts(this.server):this.opts,et("exec",r);let s;const i=l=>{if(a){et("loading complete",r);return}this._error=l,et(l?"exec errored":"exec completed",r),a=!0,s&&clearTimeout(s),t(l)};this.timeout>0&&(et("setting up timeout",r,this.timeout),s=setTimeout(function(){et("timed out",r),s=null;const l=new hH(r);l.fn=n,i(l)},this.timeout)),this.started=!0,this.emit("start",this.server?this.server.name:null,this.name,Date.now());const o=n(this.server,this.opts,i);o&&typeof o.then=="function"&&(et("exec: resolving promise",r),o.then(()=>re.nextTick(i),l=>re.nextTick(i,l)))};ps.prototype.loadedSoFar=function(){if(this.loaded)return Promise.resolve();const e=()=>{this.server.after((n,a)=>{this._error=n,this.q.pause(),n?(et("rejecting promise",this.name,n),this._promise.reject(n)):(et("resolving promise",this.name),this._promise.resolve()),this._promise=null,re.nextTick(a,n)}),this.q.resume()};let t;return this._promise?t=Promise.resolve():(this._promise=yH(),t=this._promise.promise,this.server?e():this.on("start",e)),t};ps.prototype.enqueue=function(e,t){et("enqueue",this.name,e.name),this.emit("enqueue",this.server?this.server.name:null,this.name,Date.now()),this.q.push(e,t)};ps.prototype.finish=function(e,t){et("finish",this.name,e);const n=()=>{this.loaded||(et("loaded",this.name),this.emit("loaded",this.server?this.server.name:null,this.name,Date.now()),this.loaded=!0,t(e))};if(e){this._promise&&(this._promise.reject(e),this._promise=null),n();return}const a=()=>{if(et("check",this.name,this.q.length(),this.q.running(),this._promise),this.q.length()===0&&this.q.running()===0)if(this._promise){const r=()=>{et("wrap"),queueMicrotask(a)};this._promise.resolve(),this._promise.promise.then(r,r),this._promise=null}else n();else et("delayed",this.name),this.q.drain=()=>{et("drain",this.name),this.q.drain=vH,queueMicrotask(a)}};queueMicrotask(a),this.q.resume()};function TH(e,t){const n=this;re.nextTick(o0.bind(n),e,t)}function o0(e,t){if(typeof e.func.then=="function"){e.func.then(a=>{typeof a.default=="function"&&(a=a.default),e.func=a,o0.call(this,e,t)},t);return}const n=this._current[0];this._current.unshift(e),e.exec(n&&n.server||this._server,a=>{e.finish(a,r=>{this._current.shift(),t(r)})})}function vH(){}i0.exports=ps;i0.exports.loadPlugin=o0;var kH=i0.exports;const C6=L9,bH=F9.EventEmitter,CH=f1.inherits,{AVV_ERR_EXPOSE_ALREADY_DEFINED:$c,AVV_ERR_CALLBACK_NOT_FN:Qs,AVV_ERR_PLUGIN_NOT_VALID:SH,AVV_ERR_ROOT_PLG_BOOTED:EH,AVV_ERR_READY_TIMEOUT:_H}=n7,wH=lH,b2=kH,os=a7("avvio"),Pl=Symbol("kAvvio"),jc=Symbol("kThenifyDoNotWrap");function IH(e,t,n){const a=t.expose||{},r=a.use||"use",s=a.after||"after",i=a.ready||"ready",o=a.onClose||"onClose",l=a.close||"close";if(e[r])throw new $c(r);if(e[s])throw new $c(s);if(e[i])throw new $c(i);e[r]=function(c,d){return n.use(c,d),this},Object.defineProperty(e,"then",{get:r7.bind(n)}),e[Pl]=!0,e[s]=function(c){return typeof c!="function"?n._loadRegistered():(n.after(Fc(c,this)),this)},e[i]=function(c){if(c&&typeof c!="function")throw new Qs(i,typeof c);return n.ready(c?Fc(c,this):void 0)},e[o]=function(c){if(typeof c!="function")throw new Qs(o,typeof c);return n.onClose(RH(c,this)),this},e[l]=function(c){if(c&&typeof c!="function")throw new Qs(l,typeof c);return c?(n.close(Fc(c,this)),this):n.close()}}function Ke(e,t,n){if(typeof e=="function"&&arguments.length===1&&(n=e,t={},e=null),typeof t=="function"&&(n=t,t={}),t=t||{},!(this instanceof Ke)){const a=new Ke(e,t,n);return e&&IH(e,t,a),a}t.autostart!==!1&&(t.autostart=!0),e=e||this,this._timeout=Number(t.timeout)||0,this._server=e,this._current=[],this._error=null,this._isOnCloseHandlerKey=Symbol("isOnCloseHandler"),this._lastUsed=null,this.setMaxListeners(0),n&&this.once("start",n),this.started=!1,this.booted=!1,this.pluginTree=new wH,this._readyQ=C6(this,s7,1),this._readyQ.pause(),this._readyQ.drain=()=>{this.emit("start"),this._readyQ.drain=S6},this._closeQ=C6(this,AH,1),this._closeQ.pause(),this._closeQ.drain=()=>{this.emit("close"),this._closeQ.drain=S6},this._doStart=null,this._root=new b2(this,OH.bind(this),t,!1,0),this._root.once("start",(a,r,s)=>{const i=this.pluginTree.start(null,r,s);this._root.once("loaded",(o,l,c)=>{this.pluginTree.stop(i,c)})}),b2.loadPlugin.call(this,this._root,a=>{os("root plugin ready");try{this.emit("preReady"),this._root=null}catch(r){a=a||this._error||r}if(a){if(this._error=a,this._readyQ.length()===0)throw a}else this.booted=!0;this._readyQ.resume()})}function OH(e,t,n){this._doStart=n,t.autostart&&this.start()}CH(Ke,bH);Ke.prototype.start=function(){return this.started=!0,re.nextTick(this._doStart),this};Ke.prototype.override=function(e,t,n){return e};function NH(e){if(e&&typeof e=="object"&&typeof e.default=="function"&&(e=e.default),!(e&&(typeof e=="function"||typeof e.then=="function")))throw new SH(typeof e);return e}Ke.prototype[Pl]=!0;Ke.prototype.use=function(e,t){return this._lastUsed=this._addPlugin(e,t,!1),this};Ke.prototype._loadRegistered=function(){const e=this._current[0];return!this.started&&!this.booted&&re.nextTick(()=>this._root.q.resume()),e?e.loadedSoFar():Promise.resolve()};Object.defineProperty(Ke.prototype,"then",{get:r7});Ke.prototype._addPlugin=function(e,t,n){if(e=NH(e),t=t||{},this.booted)throw new EH;const a=this._current[0],r=new b2(this,e,t,n);if(r.once("start",(s,i,o)=>{const l=this.pluginTree.start(a.name,i,o);r.once("loaded",(c,d,p)=>{this.pluginTree.stop(l,p)})}),a.loaded)throw new Error(r.name,a.name);return a.enqueue(r,s=>{s&&(this._error=s)}),r};Ke.prototype.after=function(e){if(!e)return this._loadRegistered();this._addPlugin(t.bind(this),{},!0);function t(n,a,r){s7.call(this,e,r)}return this};Ke.prototype.onClose=function(e){if(typeof e!="function")throw new Error("not a function");e[this._isOnCloseHandlerKey]=!0,this._closeQ.unshift(e,t.bind(this));function t(n){n&&(this._error=n)}return this};Ke.prototype.close=function(e){let t;if(e){if(typeof e!="function")throw new Qs("close",typeof e)}else t=new Promise(function(n,a){e=function(r){if(r)return a(r);n()}});return this.ready(()=>{this._error=null,this._closeQ.push(e),re.nextTick(this._closeQ.resume.bind(this._closeQ))}),t};Ke.prototype.ready=function(e){if(e){if(typeof e!="function")throw new Qs("ready",typeof e);this._readyQ.push(e),queueMicrotask(this.start.bind(this));return}return new Promise((t,n)=>{this._readyQ.push(r),this.start();const a=this._current[0].server;function r(s,i,o){s?n(s):t(a),re.nextTick(o)}})};Ke.prototype.prettyPrint=function(){return this.pluginTree.prittyPrint()};Ke.prototype.toJSON=function(){return this.pluginTree.toJSON()};function S6(){}function r7(){if(this.booted){os("thenify returning null because we are already booted");return}if(this[jc]){this[jc]=!1;return}return os("thenify"),(e,t)=>this._loadRegistered().then(()=>(this[jc]=!0,e(this._server)),t)}function s7(e,t){const n=this._server,a=this._error;let r;if(this._error=null,e.length===0)this._error=a,r=e(),r&&!r[Pl]&&typeof r.then=="function"?r.then(()=>re.nextTick(t),s=>re.nextTick(t,s)):re.nextTick(t);else if(e.length===1)r=e(a),r&&!r[Pl]&&typeof r.then=="function"?r.then(()=>re.nextTick(t),s=>re.nextTick(t,s)):re.nextTick(t);else if(this._timeout===0){const s=i=>{this._error=i,t(this._error)};e.length===2?e(a,s):e(a,n,s)}else LH.call(this,e,a,n,t)}function LH(e,t,n,a){const r=e.name;os("setting up ready timeout",r,this._timeout);let s=setTimeout(()=>{os("timed out",r),s=null;const o=new _H(r);o.fn=e,this._error=o,a(o)},this._timeout);e.length===2?e(t,i.bind(this)):e(t,n,i.bind(this));function i(o){s&&(clearTimeout(s),this._error=o,a(this._error))}}function AH(e,t){const n=this._server,a=e[this._isOnCloseHandlerKey];if(e.length===0||e.length===1){let r;a?r=e(n):r=e(this._error),r&&typeof r.then=="function"?(os("resolving close/onClose promise"),r.then(()=>re.nextTick(t),s=>re.nextTick(t,s))):re.nextTick(t)}else e.length===2?e(a?n:this._error,t):a?e(n,t):e(this._error,n,t)}function RH(e,t){return n.bind(t);function n(a,r){let s;e.length===0?(s=e(),s&&s.then?s.then(function(){re.nextTick(r)},r):re.nextTick(r)):e.length===1?(s=e(this),s&&s.then?s.then(function(){re.nextTick(r)},r):re.nextTick(r)):e(this,r)}}function Fc(e,t){return n.bind(t);function n(a,r){let s;e?e.length===0?(s=e(),s&&s.then?s.then(function(){re.nextTick(r,a)},r):re.nextTick(r,a)):e.length===1?(s=e(a),s&&s.then?s.then(function(){re.nextTick(r)},r):re.nextTick(r)):e.length===2?e(a,r):e(a,this,r):re.nextTick(r)}}Yd.exports=Ke;Yd.exports.express=function(e){return Ke(e,{expose:{use:"load"}})};var xH=Yd.exports;const PH=lU(xH);(function(){if(window.requestAnimationFrame&&window.cancelAnimationFrame)return;const e=["webkit","moz","ms","o"];for(const t of e)window.requestAnimationFrame=window.requestAnimationFrame||window[`${t}RequestAnimationFrame`],window.cancelAnimationFrame=window.cancelAnimationFrame||window[`${t}CancelAnimationFrame`]||window[`${t}CancelRequestAnimationFrame`];if(/iP(ad|hone|od).*OS 6/.test(window.navigator.userAgent)||!window.requestAnimationFrame||!window.cancelAnimationFrame){let t=0;const n=!!(window.performance&&window.performance.now);window.requestAnimationFrame=function(a){const r=n?window.performance.now():new Date().getTime(),s=Math.max(0,16-(r-t)),i=window.setTimeout(function(){a(r+s)},s);return t=r+s,i},window.cancelAnimationFrame=clearTimeout}})();function MH(e,t=!0,n=!0,a={friendsTab:"enabled"}){const r=t?"https://grpc-sdk.streamlayer.io:443":"https://grpc-sdk.next.streamlayer.io:443",s=t?"https://grpc.streamlayer.io:443":"https://grpc.next.streamlayer.io:443",i=PH(Object.create({}),{autostart:!1});return i.use(VV,{hideFriends:a.hideFriends,skipOnboarding:a.skipOnboarding,betPack:a.betPack,friendsTab:a.friendsTab,theme:a.theme,themeMode:a.themeMode}),i.use(xV,{onDeepLinkHandled:a==null?void 0:a.onDeepLinkHandled}),i.use($V,{videoPlayerController:a==null?void 0:a.videoPlayerController}),i.use(FV,{onContentActivate:a==null?void 0:a.onContentActivate,withAd:a==null?void 0:a.withAd,withAdNotification:a==null?void 0:a.withAdNotification}),i.use(XF,{sdkKey:e,host:r,analyticsHost:s,version:a==null?void 0:a.version}),i.use(rV),i.use(DV),i.use(ZV),i.use(wV),i.use(oU),i.after((o,l,c)=>{if(o)throw o;l.ready(),c()}),n&&i.after(async(o,l,c)=>{if(o)throw o;await l.sdk.initializeApp(),c()}),i.onClose(()=>{console.log("close")}),i}const DH=({sdkKey:e,plugins:t,production:n,autoEnable:a,onDeepLinkHandled:r,videoPlayerController:s,onContentActivate:i,hideFriends:o,skipOnboarding:l,withAdNotification:c,withAd:d,friendsTab:p,betPack:f})=>{const[y,T]=w.useState(null);return w.useEffect(()=>{let v=!1;if(!e)return console.error("streamlayer sdk key should be provided"),T(h=>(h!==null&&typeof h.disableApp=="function"&&h.disableApp(),null)),()=>{v=!0};const C=MH(e,n,a,{version:"1.14.2",onDeepLinkHandled:r,videoPlayerController:s,onContentActivate:i,skipOnboarding:l,withAdNotification:c,withAd:d,hideFriends:o,friendsTab:p,betPack:f});if(t)for(const h of t)C.use(h);return C.ready().then(h=>{v||(T(h.sdk),typeof window<"u")}).catch(h=>console.log(h)),()=>{v=!0,C.close(function(h){if(h)throw h})}},[e,n]),y},i7=({event:e})=>{const t=fs(),n=jH();return w.useEffect(()=>(t&&(e&&(t.createEventSession(e),n&&(n.current=e)),!e&&(n!=null&&n.current)&&(t.createEventSession(""),n.current="")),()=>{t&&t.disableApp()}),[e,n,t]),null};var o7=(e=>(e[e.UNSET=0]="UNSET",e[e.CONNECTED=1]="CONNECTED",e[e.READY=2]="READY",e))(o7||{});const $H={status:0,sdk:null},v1=w.createContext($H),l7=({sdkKey:e,theme:t,themeMode:n,plugins:a,children:r,event:s,production:i=!0,autoEnable:o=!0,withAdNotification:l,withAd:c=!0,betPack:d=!1,hideFriends:p,skipOnboarding:f,friendsTab:y="enabled",onDeepLinkHandled:T,videoPlayerController:v,onContentActivate:C})=>{const h=DH({sdkKey:e,plugins:a,production:i,autoEnable:o,onDeepLinkHandled:T,videoPlayerController:v,onContentActivate:C,hideFriends:p,skipOnboarding:f,withAdNotification:l,withAd:c,friendsTab:y,betPack:d}),g=w.useRef(""),k=w.useMemo(()=>h?{sdk:h,status:2,event:g}:{status:1,sdk:null,event:g},[h]);return w.useEffect(()=>{h&&(h.options.setKey("friendsTab",y),h.options.setKey("theme",t),h.options.setKey("themeMode",n),h.options.setKey("skipOnboarding",f),h.options.setKey("betPack",d))},[h,y,t,n,f,d]),w.useEffect(()=>()=>{T&&(h==null||h.removeDeepLinkHandler(T)),v&&(h==null||h.removeVideoPlayerController(v))},[h]),w.useEffect(()=>{localStorage.getItem("SL_DEBUG")&&console.log("StreamLayerProvider mounted with props:",{sdkKey:!!e,onDeepLinkHandled:!!T,videoPlayerController:!!v})},[e,T,v]),u.jsxs(v1.Provider,{value:k,children:[s!==void 0&&u.jsx(i7,{event:s}),r]})},fs=()=>{const{sdk:e}=w.useContext(v1);return e},jH=()=>{const{event:e}=w.useContext(v1);return e},FH=()=>{const e=fs();return e?u.jsx(x8,{sdk:e}):null},VH=({close:e,onEvent:t})=>{const n=fs();return n?u.jsx(R8,{sdk:n,onEvent:t,close:e}):null},UH=({sdkKey:e,plugins:t,children:n,event:a,onDeepLinkHandled:r,videoPlayerController:s,production:i=!0})=>u.jsxs(l7,{sdkKey:e,plugins:t,production:i,autoEnable:!0,onDeepLinkHandled:r,videoPlayerController:s,friendsTab:"disabled",skipOnboarding:!0,hideFriends:!0,children:[u.jsx(i7,{event:a}),n]}),BH=({betPack:e})=>{const{sdk:t,status:n}=w.useContext(v1);return n===o7.UNSET?(console.error("Wrap app in `StreamLayerProvider`"),null):t?u.jsx("div",{className:"StreamLayerSDK",children:u.jsx(Bd,{style:{height:"100%"},children:u.jsx(SP,{sdk:t,betPack:e})})}):null};class HH extends w.Component{constructor(t){super(t),this.state={hasError:!1}}static getDerivedStateFromError(){return{hasError:!0}}componentDidCatch(t,n){console.error(t,n.componentStack)}render(){return this.state.hasError?null:u.jsx(BH,{...this.props})}}const qH=({token:e,schema:t})=>{const n=fs();return w.useEffect(()=>{e&&t&&n&&n.authorizationBypass(t,e),n&&(n.withAuth=!0)},[e,t,n]),null},c7=({event:e,sdkKey:t,token:n,deviceId:a,production:r=!1,theme:s,themeMode:i="light",children:o})=>{const[l,c]=w.useState(!1);return w.useEffect(()=>{n&&(new J5().setToken(n),c(!0))},[n]),w.useEffect(()=>{a&&localStorage.setItem("sl-device-id",a)},[a]),l?u.jsx(l7,{sdkKey:t,event:e,production:r,theme:s,themeMode:i,betPack:!0,skipOnboarding:!0,autoEnable:!0,children:u.jsx("div",{className:"StreamLayerSDK",children:u.jsx(Bd,{children:o})})}):null},GH=({onEvent:e,close:t,...n})=>u.jsx(c7,{...n,children:u.jsx(VH,{close:t,onEvent:e})}),zH=({production:e})=>{const[t,n]=w.useState();return w.useEffect(()=>{const{hostname:a,search:r}=window.location,s=new URLSearchParams(r);n({sdkKey:s.get("_slrk")||"",event:s.get("_slre")||"",token:s.get("_slrt")||"",deviceId:s.get("_slrd")||"",theme:s.get("theme")||"",themeMode:s.get("themeMode")==="dark"?"dark":"light",production:e??!(a.includes("next.")||a==="localhost")})},[e]),t?u.jsx(c7,{...t,children:u.jsx(FH,{})}):null},WH=()=>{const e=fs();return e?u.jsx("div",{className:"StreamLayerSDK",children:u.jsx(Bd,{children:u.jsx(xP,{sdk:e})})}):null};exports.A=uA;exports.A$1=Nt;exports.BetPack=GH;exports.BetPackStandalone=zH;exports.C=jC;exports.I=Fd;exports.InfiniteScroll=a2;exports.InvitationFrom=Zs;exports.M=K5;exports.MastersStreamLayerProvider=UH;exports.MastersStreamLayerSDKReact=HH;exports.S=VC;exports.StreamLayerLogin=qH;exports.StreamLayerSDKPoints=WH;exports.T=Y5;exports.cx_default=Ye;exports.d=UC;exports.f=S4;exports.k=z5;exports.k1=ee;exports.l=DC;exports.m=MC;exports.n=U2;exports.p=MP;exports.s=H5;exports.styled_default=b;exports.useStore=Te;exports.useStreamLayer=fs;exports.useTransition=mh;exports.z=W5;
|
|
76
|
+
`).slice(0,2).map(n=>n.trim()).join(" -- ")}function yH(){const e={};return e.promise=new Promise((t,n)=>{e.resolve=t,e.reject=n}),e}function ps(e,t,n,a,r){this.started=!1,this.func=t,this.opts=n,this.onFinish=null,this.parent=e,this.timeout=r===void 0?e._timeout:r,this.name=gH(t,n),this.isAfter=a,this.q=mH(e,TH,1),this.q.pause(),this._error=null,this.loaded=!1,this._promise=null}fH(ps,pH);ps.prototype.exec=function(e,t){const n=this.func;let a=!1;const r=this.name;if(this.parent._error&&!this.isAfter){et("skipping loading of plugin as parent errored and it is not an after",r),re.nextTick(t);return}if(this.isAfter)this.server=e;else try{this.server=this.parent.override(e,n,this.opts)}catch(l){return et("override errored",r),t(l)}this.opts=typeof this.opts=="function"?this.opts(this.server):this.opts,et("exec",r);let s;const i=l=>{if(a){et("loading complete",r);return}this._error=l,et(l?"exec errored":"exec completed",r),a=!0,s&&clearTimeout(s),t(l)};this.timeout>0&&(et("setting up timeout",r,this.timeout),s=setTimeout(function(){et("timed out",r),s=null;const l=new hH(r);l.fn=n,i(l)},this.timeout)),this.started=!0,this.emit("start",this.server?this.server.name:null,this.name,Date.now());const o=n(this.server,this.opts,i);o&&typeof o.then=="function"&&(et("exec: resolving promise",r),o.then(()=>re.nextTick(i),l=>re.nextTick(i,l)))};ps.prototype.loadedSoFar=function(){if(this.loaded)return Promise.resolve();const e=()=>{this.server.after((n,a)=>{this._error=n,this.q.pause(),n?(et("rejecting promise",this.name,n),this._promise.reject(n)):(et("resolving promise",this.name),this._promise.resolve()),this._promise=null,re.nextTick(a,n)}),this.q.resume()};let t;return this._promise?t=Promise.resolve():(this._promise=yH(),t=this._promise.promise,this.server?e():this.on("start",e)),t};ps.prototype.enqueue=function(e,t){et("enqueue",this.name,e.name),this.emit("enqueue",this.server?this.server.name:null,this.name,Date.now()),this.q.push(e,t)};ps.prototype.finish=function(e,t){et("finish",this.name,e);const n=()=>{this.loaded||(et("loaded",this.name),this.emit("loaded",this.server?this.server.name:null,this.name,Date.now()),this.loaded=!0,t(e))};if(e){this._promise&&(this._promise.reject(e),this._promise=null),n();return}const a=()=>{if(et("check",this.name,this.q.length(),this.q.running(),this._promise),this.q.length()===0&&this.q.running()===0)if(this._promise){const r=()=>{et("wrap"),queueMicrotask(a)};this._promise.resolve(),this._promise.promise.then(r,r),this._promise=null}else n();else et("delayed",this.name),this.q.drain=()=>{et("drain",this.name),this.q.drain=vH,queueMicrotask(a)}};queueMicrotask(a),this.q.resume()};function TH(e,t){const n=this;re.nextTick(o0.bind(n),e,t)}function o0(e,t){if(typeof e.func.then=="function"){e.func.then(a=>{typeof a.default=="function"&&(a=a.default),e.func=a,o0.call(this,e,t)},t);return}const n=this._current[0];this._current.unshift(e),e.exec(n&&n.server||this._server,a=>{e.finish(a,r=>{this._current.shift(),t(r)})})}function vH(){}i0.exports=ps;i0.exports.loadPlugin=o0;var kH=i0.exports;const C6=L9,bH=F9.EventEmitter,CH=f1.inherits,{AVV_ERR_EXPOSE_ALREADY_DEFINED:$c,AVV_ERR_CALLBACK_NOT_FN:Qs,AVV_ERR_PLUGIN_NOT_VALID:SH,AVV_ERR_ROOT_PLG_BOOTED:EH,AVV_ERR_READY_TIMEOUT:_H}=n7,wH=lH,b2=kH,os=a7("avvio"),Pl=Symbol("kAvvio"),jc=Symbol("kThenifyDoNotWrap");function IH(e,t,n){const a=t.expose||{},r=a.use||"use",s=a.after||"after",i=a.ready||"ready",o=a.onClose||"onClose",l=a.close||"close";if(e[r])throw new $c(r);if(e[s])throw new $c(s);if(e[i])throw new $c(i);e[r]=function(c,d){return n.use(c,d),this},Object.defineProperty(e,"then",{get:r7.bind(n)}),e[Pl]=!0,e[s]=function(c){return typeof c!="function"?n._loadRegistered():(n.after(Fc(c,this)),this)},e[i]=function(c){if(c&&typeof c!="function")throw new Qs(i,typeof c);return n.ready(c?Fc(c,this):void 0)},e[o]=function(c){if(typeof c!="function")throw new Qs(o,typeof c);return n.onClose(RH(c,this)),this},e[l]=function(c){if(c&&typeof c!="function")throw new Qs(l,typeof c);return c?(n.close(Fc(c,this)),this):n.close()}}function Ke(e,t,n){if(typeof e=="function"&&arguments.length===1&&(n=e,t={},e=null),typeof t=="function"&&(n=t,t={}),t=t||{},!(this instanceof Ke)){const a=new Ke(e,t,n);return e&&IH(e,t,a),a}t.autostart!==!1&&(t.autostart=!0),e=e||this,this._timeout=Number(t.timeout)||0,this._server=e,this._current=[],this._error=null,this._isOnCloseHandlerKey=Symbol("isOnCloseHandler"),this._lastUsed=null,this.setMaxListeners(0),n&&this.once("start",n),this.started=!1,this.booted=!1,this.pluginTree=new wH,this._readyQ=C6(this,s7,1),this._readyQ.pause(),this._readyQ.drain=()=>{this.emit("start"),this._readyQ.drain=S6},this._closeQ=C6(this,AH,1),this._closeQ.pause(),this._closeQ.drain=()=>{this.emit("close"),this._closeQ.drain=S6},this._doStart=null,this._root=new b2(this,OH.bind(this),t,!1,0),this._root.once("start",(a,r,s)=>{const i=this.pluginTree.start(null,r,s);this._root.once("loaded",(o,l,c)=>{this.pluginTree.stop(i,c)})}),b2.loadPlugin.call(this,this._root,a=>{os("root plugin ready");try{this.emit("preReady"),this._root=null}catch(r){a=a||this._error||r}if(a){if(this._error=a,this._readyQ.length()===0)throw a}else this.booted=!0;this._readyQ.resume()})}function OH(e,t,n){this._doStart=n,t.autostart&&this.start()}CH(Ke,bH);Ke.prototype.start=function(){return this.started=!0,re.nextTick(this._doStart),this};Ke.prototype.override=function(e,t,n){return e};function NH(e){if(e&&typeof e=="object"&&typeof e.default=="function"&&(e=e.default),!(e&&(typeof e=="function"||typeof e.then=="function")))throw new SH(typeof e);return e}Ke.prototype[Pl]=!0;Ke.prototype.use=function(e,t){return this._lastUsed=this._addPlugin(e,t,!1),this};Ke.prototype._loadRegistered=function(){const e=this._current[0];return!this.started&&!this.booted&&re.nextTick(()=>this._root.q.resume()),e?e.loadedSoFar():Promise.resolve()};Object.defineProperty(Ke.prototype,"then",{get:r7});Ke.prototype._addPlugin=function(e,t,n){if(e=NH(e),t=t||{},this.booted)throw new EH;const a=this._current[0],r=new b2(this,e,t,n);if(r.once("start",(s,i,o)=>{const l=this.pluginTree.start(a.name,i,o);r.once("loaded",(c,d,p)=>{this.pluginTree.stop(l,p)})}),a.loaded)throw new Error(r.name,a.name);return a.enqueue(r,s=>{s&&(this._error=s)}),r};Ke.prototype.after=function(e){if(!e)return this._loadRegistered();this._addPlugin(t.bind(this),{},!0);function t(n,a,r){s7.call(this,e,r)}return this};Ke.prototype.onClose=function(e){if(typeof e!="function")throw new Error("not a function");e[this._isOnCloseHandlerKey]=!0,this._closeQ.unshift(e,t.bind(this));function t(n){n&&(this._error=n)}return this};Ke.prototype.close=function(e){let t;if(e){if(typeof e!="function")throw new Qs("close",typeof e)}else t=new Promise(function(n,a){e=function(r){if(r)return a(r);n()}});return this.ready(()=>{this._error=null,this._closeQ.push(e),re.nextTick(this._closeQ.resume.bind(this._closeQ))}),t};Ke.prototype.ready=function(e){if(e){if(typeof e!="function")throw new Qs("ready",typeof e);this._readyQ.push(e),queueMicrotask(this.start.bind(this));return}return new Promise((t,n)=>{this._readyQ.push(r),this.start();const a=this._current[0].server;function r(s,i,o){s?n(s):t(a),re.nextTick(o)}})};Ke.prototype.prettyPrint=function(){return this.pluginTree.prittyPrint()};Ke.prototype.toJSON=function(){return this.pluginTree.toJSON()};function S6(){}function r7(){if(this.booted){os("thenify returning null because we are already booted");return}if(this[jc]){this[jc]=!1;return}return os("thenify"),(e,t)=>this._loadRegistered().then(()=>(this[jc]=!0,e(this._server)),t)}function s7(e,t){const n=this._server,a=this._error;let r;if(this._error=null,e.length===0)this._error=a,r=e(),r&&!r[Pl]&&typeof r.then=="function"?r.then(()=>re.nextTick(t),s=>re.nextTick(t,s)):re.nextTick(t);else if(e.length===1)r=e(a),r&&!r[Pl]&&typeof r.then=="function"?r.then(()=>re.nextTick(t),s=>re.nextTick(t,s)):re.nextTick(t);else if(this._timeout===0){const s=i=>{this._error=i,t(this._error)};e.length===2?e(a,s):e(a,n,s)}else LH.call(this,e,a,n,t)}function LH(e,t,n,a){const r=e.name;os("setting up ready timeout",r,this._timeout);let s=setTimeout(()=>{os("timed out",r),s=null;const o=new _H(r);o.fn=e,this._error=o,a(o)},this._timeout);e.length===2?e(t,i.bind(this)):e(t,n,i.bind(this));function i(o){s&&(clearTimeout(s),this._error=o,a(this._error))}}function AH(e,t){const n=this._server,a=e[this._isOnCloseHandlerKey];if(e.length===0||e.length===1){let r;a?r=e(n):r=e(this._error),r&&typeof r.then=="function"?(os("resolving close/onClose promise"),r.then(()=>re.nextTick(t),s=>re.nextTick(t,s))):re.nextTick(t)}else e.length===2?e(a?n:this._error,t):a?e(n,t):e(this._error,n,t)}function RH(e,t){return n.bind(t);function n(a,r){let s;e.length===0?(s=e(),s&&s.then?s.then(function(){re.nextTick(r)},r):re.nextTick(r)):e.length===1?(s=e(this),s&&s.then?s.then(function(){re.nextTick(r)},r):re.nextTick(r)):e(this,r)}}function Fc(e,t){return n.bind(t);function n(a,r){let s;e?e.length===0?(s=e(),s&&s.then?s.then(function(){re.nextTick(r,a)},r):re.nextTick(r,a)):e.length===1?(s=e(a),s&&s.then?s.then(function(){re.nextTick(r)},r):re.nextTick(r)):e.length===2?e(a,r):e(a,this,r):re.nextTick(r)}}Yd.exports=Ke;Yd.exports.express=function(e){return Ke(e,{expose:{use:"load"}})};var xH=Yd.exports;const PH=lU(xH);(function(){if(window.requestAnimationFrame&&window.cancelAnimationFrame)return;const e=["webkit","moz","ms","o"];for(const t of e)window.requestAnimationFrame=window.requestAnimationFrame||window[`${t}RequestAnimationFrame`],window.cancelAnimationFrame=window.cancelAnimationFrame||window[`${t}CancelAnimationFrame`]||window[`${t}CancelRequestAnimationFrame`];if(/iP(ad|hone|od).*OS 6/.test(window.navigator.userAgent)||!window.requestAnimationFrame||!window.cancelAnimationFrame){let t=0;const n=!!(window.performance&&window.performance.now);window.requestAnimationFrame=function(a){const r=n?window.performance.now():new Date().getTime(),s=Math.max(0,16-(r-t)),i=window.setTimeout(function(){a(r+s)},s);return t=r+s,i},window.cancelAnimationFrame=clearTimeout}})();function MH(e,t=!0,n=!0,a={friendsTab:"enabled"}){const r=t?"https://grpc-sdk.streamlayer.io:443":"https://grpc-sdk.next.streamlayer.io:443",s=t?"https://grpc.streamlayer.io:443":"https://grpc.next.streamlayer.io:443",i=PH(Object.create({}),{autostart:!1});return i.use(VV,{hideFriends:a.hideFriends,skipOnboarding:a.skipOnboarding,betPack:a.betPack,friendsTab:a.friendsTab,theme:a.theme,themeMode:a.themeMode}),i.use(xV,{onDeepLinkHandled:a==null?void 0:a.onDeepLinkHandled}),i.use($V,{videoPlayerController:a==null?void 0:a.videoPlayerController}),i.use(FV,{onContentActivate:a==null?void 0:a.onContentActivate,withAd:a==null?void 0:a.withAd,withAdNotification:a==null?void 0:a.withAdNotification}),i.use(XF,{sdkKey:e,host:r,analyticsHost:s,version:a==null?void 0:a.version}),i.use(rV),i.use(DV),i.use(ZV),i.use(wV),i.use(oU),i.after((o,l,c)=>{if(o)throw o;l.ready(),c()}),n&&i.after(async(o,l,c)=>{if(o)throw o;await l.sdk.initializeApp(),c()}),i.onClose(()=>{console.log("close")}),i}const DH=({sdkKey:e,plugins:t,production:n,autoEnable:a,onDeepLinkHandled:r,videoPlayerController:s,onContentActivate:i,hideFriends:o,skipOnboarding:l,withAdNotification:c,withAd:d,friendsTab:p,betPack:f})=>{const[y,T]=w.useState(null);return w.useEffect(()=>{let v=!1;if(!e)return console.error("streamlayer sdk key should be provided"),T(h=>(h!==null&&typeof h.disableApp=="function"&&h.disableApp(),null)),()=>{v=!0};const C=MH(e,n,a,{version:"1.14.3",onDeepLinkHandled:r,videoPlayerController:s,onContentActivate:i,skipOnboarding:l,withAdNotification:c,withAd:d,hideFriends:o,friendsTab:p,betPack:f});if(t)for(const h of t)C.use(h);return C.ready().then(h=>{v||(T(h.sdk),typeof window<"u")}).catch(h=>console.log(h)),()=>{v=!0,C.close(function(h){if(h)throw h})}},[e,n]),y},i7=({event:e})=>{const t=fs(),n=jH();return w.useEffect(()=>(t&&(e&&(t.createEventSession(e),n&&(n.current=e)),!e&&(n!=null&&n.current)&&(t.createEventSession(""),n.current="")),()=>{t&&t.disableApp()}),[e,n,t]),null};var o7=(e=>(e[e.UNSET=0]="UNSET",e[e.CONNECTED=1]="CONNECTED",e[e.READY=2]="READY",e))(o7||{});const $H={status:0,sdk:null},v1=w.createContext($H),l7=({sdkKey:e,theme:t,themeMode:n,plugins:a,children:r,event:s,production:i=!0,autoEnable:o=!0,withAdNotification:l,withAd:c=!0,betPack:d=!1,hideFriends:p,skipOnboarding:f,friendsTab:y="enabled",onDeepLinkHandled:T,videoPlayerController:v,onContentActivate:C})=>{const h=DH({sdkKey:e,plugins:a,production:i,autoEnable:o,onDeepLinkHandled:T,videoPlayerController:v,onContentActivate:C,hideFriends:p,skipOnboarding:f,withAdNotification:l,withAd:c,friendsTab:y,betPack:d}),g=w.useRef(""),k=w.useMemo(()=>h?{sdk:h,status:2,event:g}:{status:1,sdk:null,event:g},[h]);return w.useEffect(()=>{h&&(h.options.setKey("friendsTab",y),h.options.setKey("theme",t),h.options.setKey("themeMode",n),h.options.setKey("skipOnboarding",f),h.options.setKey("betPack",d))},[h,y,t,n,f,d]),w.useEffect(()=>()=>{T&&(h==null||h.removeDeepLinkHandler(T)),v&&(h==null||h.removeVideoPlayerController(v))},[h]),w.useEffect(()=>{localStorage.getItem("SL_DEBUG")&&console.log("StreamLayerProvider mounted with props:",{sdkKey:!!e,onDeepLinkHandled:!!T,videoPlayerController:!!v})},[e,T,v]),u.jsxs(v1.Provider,{value:k,children:[s!==void 0&&u.jsx(i7,{event:s}),r]})},fs=()=>{const{sdk:e}=w.useContext(v1);return e},jH=()=>{const{event:e}=w.useContext(v1);return e},FH=()=>{const e=fs();return e?u.jsx(x8,{sdk:e}):null},VH=({close:e,onEvent:t})=>{const n=fs();return n?u.jsx(R8,{sdk:n,onEvent:t,close:e}):null},UH=({sdkKey:e,plugins:t,children:n,event:a,onDeepLinkHandled:r,videoPlayerController:s,production:i=!0})=>u.jsxs(l7,{sdkKey:e,plugins:t,production:i,autoEnable:!0,onDeepLinkHandled:r,videoPlayerController:s,friendsTab:"disabled",skipOnboarding:!0,hideFriends:!0,children:[u.jsx(i7,{event:a}),n]}),BH=({betPack:e})=>{const{sdk:t,status:n}=w.useContext(v1);return n===o7.UNSET?(console.error("Wrap app in `StreamLayerProvider`"),null):t?u.jsx("div",{className:"StreamLayerSDK",children:u.jsx(Bd,{style:{height:"100%"},children:u.jsx(SP,{sdk:t,betPack:e})})}):null};class HH extends w.Component{constructor(t){super(t),this.state={hasError:!1}}static getDerivedStateFromError(){return{hasError:!0}}componentDidCatch(t,n){console.error(t,n.componentStack)}render(){return this.state.hasError?null:u.jsx(BH,{...this.props})}}const qH=({token:e,schema:t})=>{const n=fs();return w.useEffect(()=>{e&&t&&n&&n.authorizationBypass(t,e),n&&(n.withAuth=!0)},[e,t,n]),null},c7=({event:e,sdkKey:t,token:n,deviceId:a,production:r=!1,theme:s,themeMode:i="light",children:o})=>{const[l,c]=w.useState(!1);return w.useEffect(()=>{n&&(new J5().setToken(n),c(!0))},[n]),w.useEffect(()=>{a&&localStorage.setItem("sl-device-id",a)},[a]),l?u.jsx(l7,{sdkKey:t,event:e,production:r,theme:s,themeMode:i,betPack:!0,skipOnboarding:!0,autoEnable:!0,children:u.jsx("div",{className:"StreamLayerSDK",children:u.jsx(Bd,{children:o})})}):null},GH=({onEvent:e,close:t,...n})=>u.jsx(c7,{...n,children:u.jsx(VH,{close:t,onEvent:e})}),zH=({production:e})=>{const[t,n]=w.useState();return w.useEffect(()=>{const{hostname:a,search:r}=window.location,s=new URLSearchParams(r);n({sdkKey:s.get("_slrk")||"",event:s.get("_slre")||"",token:s.get("_slrt")||"",deviceId:s.get("_slrd")||"",theme:s.get("theme")||"",themeMode:s.get("themeMode")==="dark"?"dark":"light",production:e??!(a.includes("next.")||a==="localhost")})},[e]),t?u.jsx(c7,{...t,children:u.jsx(FH,{})}):null},WH=()=>{const e=fs();return e?u.jsx("div",{className:"StreamLayerSDK",children:u.jsx(Bd,{children:u.jsx(xP,{sdk:e})})}):null};exports.A=uA;exports.A$1=Nt;exports.BetPack=GH;exports.BetPackStandalone=zH;exports.C=jC;exports.I=Fd;exports.InfiniteScroll=a2;exports.InvitationFrom=Zs;exports.M=K5;exports.MastersStreamLayerProvider=UH;exports.MastersStreamLayerSDKReact=HH;exports.S=VC;exports.StreamLayerLogin=qH;exports.StreamLayerSDKPoints=WH;exports.T=Y5;exports.cx_default=Ye;exports.d=UC;exports.f=S4;exports.k=z5;exports.k1=ee;exports.l=DC;exports.m=MC;exports.n=U2;exports.p=MP;exports.s=H5;exports.styled_default=b;exports.useStore=Te;exports.useStreamLayer=fs;exports.useTransition=mh;exports.z=W5;
|
package/lib/dist/es/masters.js
CHANGED
|
@@ -32060,7 +32060,7 @@ const zq = ({
|
|
|
32060
32060
|
v = !0;
|
|
32061
32061
|
};
|
|
32062
32062
|
const C = Gq(e, n, a, {
|
|
32063
|
-
version: "1.14.
|
|
32063
|
+
version: "1.14.3",
|
|
32064
32064
|
onDeepLinkHandled: r,
|
|
32065
32065
|
videoPlayerController: s,
|
|
32066
32066
|
onContentActivate: i,
|