openclaw
Version:
Multi-channel AI gateway with extensible messaging integrations
5 lines • 3.62 kB
JavaScript
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./debug-overlay-content-DWYSWns0.js","./gateway-runtime-C77LeWZN.js","./session-snapshot-database-BBKeXATO.js","./control-ui-boot-shared-UG5ko-VG.js","./control-ui-boot-shared-gZIpWrfw.js","./control-ui-boot-shared-CkXlyZBY.js","./control-ui-boot-shared-SQHdJTzb.js","./control-ui-boot-shared-VLPz5vN2.js","./plugin-contracts-runtime-ByiEPbv_.js","./control-ui-boot-shared-Q8KG_noF.js","./config-runtime-BecGLziM.js","./markdown-runtime-ORQpioyT.js","./control-ui-boot-shared-XreXSF7h.js","./control-ui-boot-shared-dOnP4mAA.js","./control-ui-boot-shared-styles-BXPMRytW.js","./sidebar-update-runtime-DQZboSgD.js","./gateway-vitals-BOFaPBKC.js","./en-debug-BZ7m3IAp.js","./sparkline-tile-D8lJjcld.js","./lane-table-BUumSF5I.js","./control-ui-core-DI-Q_yCI.css","./control-ui-boot-shared-styles-DUf4zEvn.css","./control-ui-boot-shared-DIWJGbGi.css","./sidebar-update-runtime-Bpn2ByHA.css","./sparkline-tile-CaHeaFDQ.css","./lane-table-CSTpz4OW.css"])))=>i.map(i=>d[i]);
import{n as e}from"./rolldown-runtime-8BhlS34s.js";import{C as t,Nu as n,Pu as r,b as i,ju as a,v as o,x as s,zu as c}from"./control-ui-core-CBJ5efDh.js";import{Ai as l,B as u,Hi as d,L as f,R as p,Ui as m,Vi as h,di as g,fi as _,ki as v,qi as y,ti as b,ui as x,z as S,zi as C}from"./control-ui-core-DtLivg_r.js";import{G as w,J as T,W as E,Z as D,c as O,l as k,rt as A}from"./lit-runtime-IOnANfcZ.js";import{Ur as j,Wr as M,Zr as N,ma as P,pa as F}from"./ui-CmSP4d14.js";var I,L;function R(){return(R=e((()=>{M(),E(),D(),O(),l(),h(),p(),m(),g(),x(),r(),n(),o(),P(),I={tagName:`openclaw-debug-overlay-content`,get label(){return c(`debug.overlay.title`)},loadModule:()=>F(()=>import(`./debug-overlay-content-DWYSWns0.js`),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25]),import.meta.url)},L=class extends a{constructor(...e){super(...e),this.mode=`closed`,this.contentKey=0,this.recoveryActionPending=!1,this.content=new C(this,void 0,e=>y({canReload:()=>e()?(this.recoveryActionPending=S({eventType:b}),this.recoveryActionPending):!1})),this.handleKeydown=e=>{t(e,this.mode,this)&&(e.preventDefault(),this.close())},this.close=()=>{this.mode=`closed`,document.removeEventListener(`keydown`,this.handleKeydown,!0),this.content.close(),this.clearRecoveryAction()}}disconnectedCallback(){this.close(),super.disconnectedCallback()}toggle(){this.mode===`expanded`?this.close():this.open(`expanded`)}open(e){if(this.mode!==`closed`){this.mode=e;return}this.mode=e,this.contentKey+=1,document.addEventListener(`keydown`,this.handleKeydown,!0),d(I)||(this.recoveryActionPending=S({eventType:b}),this.content.request(I,()=>this.clearRecoveryAction()))}clearRecoveryAction(){this.recoveryActionPending&&=(u()?.eventType===`openclaw:debug-overlay-request`&&f(),!1)}renderContent(){let e=this.content.visibleState;return e?.status===`error`?_({actionLabel:c(`common.retry`),error:e.error,stale:e.stale,subtitle:e.element.label,onRetry:()=>this.content.retry()}):d(I)?k(this.contentKey,T`<openclaw-debug-overlay-content
.context=${this.context}
.minimized=${this.mode===`minimized`}
></openclaw-debug-overlay-content>`):s(this.mode)}render(){return this.mode===`closed`?w:i({mode:this.mode,body:this.renderContent(),onToggleMode:()=>{this.mode=this.mode===`minimized`?`expanded`:`minimized`},onClose:this.close})}},N([j({context:v,subscribe:!0})],L.prototype,`context`,void 0),N([A()],L.prototype,`mode`,void 0),customElements.get(`openclaw-debug-overlay`)||customElements.define(`openclaw-debug-overlay`,L)})))()}R();export{L as DebugOverlay};