"use strict";(self.webpackChunk_kb_labs_quality_entry=self.webpackChunk_kb_labs_quality_entry||[]).push([["50"],{572(e,s,t){var r=t(5259),o=Symbol.for("react.element"),i=Symbol.for("react.fragment"),n=Object.prototype.hasOwnProperty,u=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,l={key:!0,ref:!0,__self:!0,__source:!0};function a(e,s,t){var r,i={},a=null,h=null;for(r in void 0!==t&&(a=""+t),void 0!==s.key&&(a=""+s.key),void 0!==s.ref&&(h=s.ref),s)n.call(s,r)&&!l.hasOwnProperty(r)&&(i[r]=s[r]);if(e&&e.defaultProps)for(r in s=e.defaultProps)void 0===i[r]&&(i[r]=s[r]);return{$$typeof:o,type:e,key:a,ref:h,props:i,_owner:u.current}}s.Fragment=i,s.jsx=a,s.jsxs=a},8048(e,s,t){e.exports=t(572)},4332(e,s,t){t.r(s),t.d(s,{EventBusProvider:()=>l,StudioEventBus:()=>i,eventBus:()=>n,useEventBusContext:()=>a});var r=t(5259),o=t(8048),i=class{subscriptions=new Map;history=[];devToolsObserver;subscribe(e,s,t,r){let o={event:e,handler:s,pluginId:t,pageId:r};return this.subscriptions.has(e)||this.subscriptions.set(e,new Set),this.subscriptions.get(e).add(o),()=>{this.subscriptions.get(e)?.delete(o)}}publish(e,s,t,r){let o={sourcePluginId:t,sourcePageId:r,timestamp:Date.now()},i={event:e,payload:s,meta:o};this.history.push(i),this.history.length>100&&this.history.shift(),this.devToolsObserver?.(i);let n=this.subscriptions.get(e);if(n)for(let t of n)try{t.handler(s,o)}catch(s){console.error(`[StudioEventBus] Handler error for "${e}" in ${t.pluginId}:${t.pageId}:`,s)}}unsubscribeAll(e,s){for(let[,t]of this.subscriptions)for(let r of t)r.pluginId===e&&r.pageId===s&&t.delete(r)}getHistory(){return this.history}setDevToolsObserver(e){this.devToolsObserver=e}clearDevToolsObserver(){this.devToolsObserver=void 0}reset(){this.subscriptions.clear(),this.history=[]}},n=new i,u=(0,r.createContext)(n);function l({children:e,bus:s}){return(0,o.jsx)(u.Provider,{value:s??n,children:e})}function a(){return(0,r.useContext)(u)}}}]);
//# sourceMappingURL=50.js.map