All Downloads are FREE. Search and download functionalities are using the official Maven repository.

webapp.index.12604118.js Maven / Gradle / Ivy

There is a newer version: 1.0-20241113
Show newest version
var e=globalThis,t={},s={},a=e.parcelRequire0031;null==a&&((a=function(e){if(e in t)return t[e].exports;if(e in s){var a=s[e];delete s[e];var i={id:e,exports:{}};return t[e]=i,a.call(i.exports,i,i.exports),i.exports}var l=Error("Cannot find module '"+e+"'");throw l.code="MODULE_NOT_FOUND",l}).register=function(e,t){s[e]=t},e.parcelRequire0031=a),a.register;var i=a("hNeh9"),l=a("800sp");class d extends l.LitElement{static styles=[i.default,(0,l.css)`
  json-viewer {
    --font-size: .8rem;
  }`];static properties={};threadMap=new Map;#e;get selectedTab(){return this.#e}set selectedTab(e){this.#e=e,this.dispatchEvent(new CustomEvent("thread-updated",{detail:e,bubbles:!0,composed:!0,cancelable:!0}))}constructor(){super()}connectedCallback(){super.connectedCallback(),this.addEventListener("result",this.#t),this.addEventListener("init-threads",this.#s),this.addEventListener("node-updated",this.#a)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("result",this.#t),this.removeEventListener("init-threads",this.#s),this.removeEventListener("node-updated",this.#a)}#s=e=>{let{detail:t=[]}=e;console.debug("threads",t),this.threadMap=new Map(t),t&&t.length>0&&(this.selectedTab=t[0][0],this.requestUpdate())};#t=e=>{let[t,s]=e.detail;if(console.debug("onResult",t,s),!this.threadMap.has(t))throw Error("result doesn't contain a valid thread!");console.debug("onResult",t);let a=this.threadMap.get(t),i=a.push(s);this.threadMap.set(t,a),this.dispatchEvent(new CustomEvent("graph-active",{detail:s.node,bubbles:!0,composed:!0,cancelable:!0})),this.requestUpdate(),this.updateComplete.then(()=>{let e=`#json${i-1}`,t=this.shadowRoot.querySelectorAll(e);for(let s of(console.debug(e,t),t))s.expandAll()})};#i(e){console.debug(e.target.id),this.selectedTab=e.target.id,this.requestUpdate()}#l(e){console.debug("NEW TAB",e);let t=`Thread-${this.threadMap.size+1}`;this.threadMap.set(t,[]),this.selectedTab=t,this.requestUpdate()}#a(e){console.debug("onNodeUpdated",e)}#d(e,t){return(0,l.html)`
    
${e.node}
${JSON.stringify(e).trim()}
`}#r(){let e=[...this.threadMap.keys()];return(0,l.html)` ${e.map(e=>(0,l.html)`${e}`)} `}render(){return(0,l.html)`
${this.#r()}
${this.threadMap.get(this.selectedTab)?.map((e,t)=>l.html``)}
${this.#d(e,t)}
`}#o(e,t){return(0,l.html)`
${e.node}
${Object.entries(e.state).map(([e,s])=>(0,l.html)`

${e}

${JSON.stringify(s)}

`)}
`}#n(e,t){return(0,l.html)`

${e.node}

${Object.entries(e.state).map(([e,s])=>(0,l.html)`

${e}

${JSON.stringify(s)}

`)}
`}}window.customElements.define("lg4j-result",d); //# sourceMappingURL=index.12604118.js.map




© 2015 - 2024 Weber Informatics LLC | Privacy Policy