openclaw
Version:
Multi-channel AI gateway with extensible messaging integrations
1 lines • 1.78 kB
JavaScript
import{n as e}from"./rolldown-runtime-8BhlS34s.js";import{go as t,xo as n,yo as r}from"./control-ui-core-DtLivg_r.js";import{ya as i}from"./ui-CmSP4d14.js";import{n as a,r as o,t as s}from"./slots-DxtX6aTe.js";function c(e){return e===`search`?`settings`:e===`dreaming`?`dreams`:h.find(t=>t===e)??null}function l(e,t=``){let n=e.pathname?r(e.pathname,t):null;if(n&&n!==`overview`)return n;let i=c(e.tab);if(i)return i;let a=e.targetBlockId??``;return e.section===`memory`||a.startsWith(`config-section-memory`)?`settings`:n}function u(e,t=``){let r=new URLSearchParams(e.search),i=r.has(`tab`),a=e.section===`memory`&&r.has(`section`);r.delete(`tab`),a&&(r.delete(`section`),r.delete(`advanced`));let o=r.toString(),s={pathname:n(l(e,t)??`overview`,t),search:o?`?${o}`:``,hash:e.hash};return i||a||s.pathname!==e.pathname?s:null}function d(e){return e.kind===`off`?null:e.pluginId}function f(e){let t=i(i(e.plugins)?.slots);return o(`memory`,t?.memory)}function p(e){let t=i(e),n=i(i(t?.properties)?.memory),r=i(n?.properties);if(!t||!n||!r)return e;let a=_.get(t);if(a!==void 0)return a;let o=Object.fromEntries(g.filter(e=>e in r).map(e=>[e,r[e]])),s={...t,properties:{memory:{...n,properties:o}}};return _.set(t,s),s}var m,h,g,_;function v(){return(v=e((()=>{a(),t(),m=s(`memory`),h=[`overview`,`memories`,`dreams`,`settings`],g=[`citations`,`search`],_=new WeakMap})))()}function y(e){return{...e,properties:Object.fromEntries(Object.entries(e.properties??{}).filter(([e])=>Object.hasOwn(b,e)||x.some(t=>t===e)))}}var b,x;function S(){return(S=e((()=>{b={accessMode:`full`,appRecommendations:!0},x=[`lastRunAt`,`lastRunVersion`,`lastRunCommit`,`lastRunCommand`,`lastRunMode`]})))()}export{m as a,v as c,f as d,d as f,y as i,p as l,x as n,g as o,S as r,u as s,b as t,l as u};