@shahmilsaari/memory-core 1.0.19 → 1.0.20
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/dist/{chunk-VQEIQHK6.js → chunk-UZDALJVQ.js} +6 -3
- package/dist/cli.js +3 -4
- package/dist/dashboard/assets/index-BRqvIBnm.js +2 -0
- package/dist/dashboard/assets/{index-Bz-Tzypa.css → index-DXXHB1Ik.css} +1 -1
- package/dist/dashboard/index.html +2 -2
- package/dist/{dashboard-server-ZERRHWQS.js → dashboard-server-VOT2ZRVN.js} +1 -1
- package/package.json +1 -1
- package/dist/dashboard/assets/index-CaevtejN.js +0 -2
|
@@ -2640,7 +2640,7 @@ async function runSnapshotScan(projectRoot, watchPath, config2, verbose, debug,
|
|
|
2640
2640
|
const rel = normalizeForGit(relative2(projectRoot, filePath));
|
|
2641
2641
|
const timestamp = (/* @__PURE__ */ new Date()).toISOString();
|
|
2642
2642
|
onEvent?.({ type: "saved", timestamp, file: rel });
|
|
2643
|
-
const result = await checkFile(filePath, projectRoot, config2, verbose, debug, "snapshot");
|
|
2643
|
+
const result = await checkFile(filePath, projectRoot, config2, verbose, debug, "snapshot", onEvent);
|
|
2644
2644
|
if (result.type !== "checked") {
|
|
2645
2645
|
if (result.type === "skipped") {
|
|
2646
2646
|
onEvent?.({ type: "skipped", timestamp: (/* @__PURE__ */ new Date()).toISOString(), file: rel, reason: result.reason });
|
|
@@ -2660,7 +2660,7 @@ async function runSnapshotScan(projectRoot, watchPath, config2, verbose, debug,
|
|
|
2660
2660
|
}
|
|
2661
2661
|
return summary;
|
|
2662
2662
|
}
|
|
2663
|
-
async function checkFile(filePath, projectRoot, config2, verbose, debug, mode = "diff") {
|
|
2663
|
+
async function checkFile(filePath, projectRoot, config2, verbose, debug, mode = "diff", onEvent) {
|
|
2664
2664
|
const rel = relative2(projectRoot, filePath).split(sep).join("/");
|
|
2665
2665
|
if (rel.startsWith("..")) return { type: "skipped", reason: "File is outside project root" };
|
|
2666
2666
|
let inputText;
|
|
@@ -2739,6 +2739,7 @@ No text outside the JSON.`;
|
|
|
2739
2739
|
${inputToSend}` : `Review this diff for ${rel}:
|
|
2740
2740
|
|
|
2741
2741
|
${inputToSend}`;
|
|
2742
|
+
onEvent?.({ type: "log", timestamp: (/* @__PURE__ */ new Date()).toISOString(), file: rel, message: `checking with ${getChatProviderLabel()} | ${rules.length} rule${rules.length === 1 ? "" : "s"}` });
|
|
2742
2743
|
const raw = await callChatModel([
|
|
2743
2744
|
{ role: "system", content: systemPrompt },
|
|
2744
2745
|
{ role: "user", content: reviewPrompt }
|
|
@@ -2761,6 +2762,7 @@ ${inputToSend}`;
|
|
|
2761
2762
|
} catch {
|
|
2762
2763
|
violations = [];
|
|
2763
2764
|
}
|
|
2765
|
+
onEvent?.({ type: "log", timestamp: (/* @__PURE__ */ new Date()).toISOString(), file: rel, message: `model returned ${violations.length} candidate violation${violations.length === 1 ? "" : "s"}` });
|
|
2764
2766
|
violations = await verifyViolations(inputText, violations, allowPatterns, debug, mode);
|
|
2765
2767
|
violations = [...astViolations, ...violations];
|
|
2766
2768
|
violations = applyAllowPatterns(violations, allowPatterns);
|
|
@@ -2954,7 +2956,8 @@ async function startWatch(options = {}) {
|
|
|
2954
2956
|
config2,
|
|
2955
2957
|
options.verbose ?? false,
|
|
2956
2958
|
options.debug ?? false,
|
|
2957
|
-
"diff"
|
|
2959
|
+
"diff",
|
|
2960
|
+
options.onEvent
|
|
2958
2961
|
);
|
|
2959
2962
|
if (result.type === "skipped") {
|
|
2960
2963
|
if (result.reason === "No changes compared with HEAD") {
|
package/dist/cli.js
CHANGED
|
@@ -20,7 +20,7 @@ import {
|
|
|
20
20
|
retrieveMemorySelection,
|
|
21
21
|
runMigrations,
|
|
22
22
|
seeds
|
|
23
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-UZDALJVQ.js";
|
|
24
24
|
|
|
25
25
|
// src/cli.ts
|
|
26
26
|
import { Command } from "commander";
|
|
@@ -232,7 +232,6 @@ function resetViolationStats(cwd = process.cwd()) {
|
|
|
232
232
|
}
|
|
233
233
|
stats.rules = {};
|
|
234
234
|
stats.files = {};
|
|
235
|
-
stats.recentViolations = [];
|
|
236
235
|
writeFileSync2(statsPath, JSON.stringify(stats, null, 2) + "\n", "utf-8");
|
|
237
236
|
}
|
|
238
237
|
async function promptToSaveViolations(violations) {
|
|
@@ -1935,7 +1934,7 @@ program.command("init").description("Initialize memory-core in the current proje
|
|
|
1935
1934
|
let pgOk = false;
|
|
1936
1935
|
let ollamaOk = false;
|
|
1937
1936
|
const envPath = join3(process.cwd(), ".memory-core.env");
|
|
1938
|
-
const hasEnv = existsSync3(envPath)
|
|
1937
|
+
const hasEnv = existsSync3(envPath);
|
|
1939
1938
|
if (skipEnv) {
|
|
1940
1939
|
try {
|
|
1941
1940
|
const { Pool } = (await import("pg")).default;
|
|
@@ -2948,7 +2947,7 @@ program.command("dashboard").description("Start the live Svelte dashboard with W
|
|
|
2948
2947
|
}
|
|
2949
2948
|
return void 0;
|
|
2950
2949
|
};
|
|
2951
|
-
const { startDashboard } = await import("./dashboard-server-
|
|
2950
|
+
const { startDashboard } = await import("./dashboard-server-VOT2ZRVN.js");
|
|
2952
2951
|
await startDashboard({
|
|
2953
2952
|
port: parseInt(opts.port, 10),
|
|
2954
2953
|
path: resolveDashboardPath(),
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
var mi=Object.defineProperty;var rl=e=>{throw TypeError(e)};var wi=(e,t,s)=>t in e?mi(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s;var We=(e,t,s)=>wi(e,typeof t!="symbol"?t+"":t,s),Rn=(e,t,s)=>t.has(e)||rl("Cannot "+s);var o=(e,t,s)=>(Rn(e,t,"read from private field"),s?s.call(e):t.get(e)),T=(e,t,s)=>t.has(e)?rl("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,s),O=(e,t,s,n)=>(Rn(e,t,"write to private field"),n?n.call(e,s):t.set(e,s),s),z=(e,t,s)=>(Rn(e,t,"access private method"),s);(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const l of document.querySelectorAll('link[rel="modulepreload"]'))n(l);new MutationObserver(l=>{for(const a of l)if(a.type==="childList")for(const c of a.addedNodes)c.tagName==="LINK"&&c.rel==="modulepreload"&&n(c)}).observe(document,{childList:!0,subtree:!0});function s(l){const a={};return l.integrity&&(a.integrity=l.integrity),l.referrerPolicy&&(a.referrerPolicy=l.referrerPolicy),l.crossOrigin==="use-credentials"?a.credentials="include":l.crossOrigin==="anonymous"?a.credentials="omit":a.credentials="same-origin",a}function n(l){if(l.ep)return;l.ep=!0;const a=s(l);fetch(l.href,a)}})();const yi=!1;var sr=Array.isArray,Ei=Array.prototype.indexOf,us=Array.prototype.includes,gn=Array.from,ki=Object.defineProperty,Ns=Object.getOwnPropertyDescriptor,yl=Object.getOwnPropertyDescriptors,xi=Object.prototype,Si=Array.prototype,nr=Object.getPrototypeOf,ll=Object.isExtensible;const Mi=()=>{};function Ci(e){return e()}function Vn(e){for(var t=0;t<e.length;t++)e[t]()}function El(){var e,t,s=new Promise((n,l)=>{e=n,t=l});return{promise:s,resolve:e,reject:t}}const ve=2,vs=4,qs=8,kl=1<<24,nt=16,Ye=32,Mt=64,Hn=128,Fe=512,X=1024,ce=2048,Ge=4096,he=8192,Pe=16384,Xt=32768,al=1<<25,ds=65536,Wn=1<<17,Ti=1<<18,bs=1<<19,xl=1<<20,st=1<<25,Yt=65536,dn=1<<21,Rs=1<<22,xt=1<<23,qt=Symbol("$state"),ft=new class extends Error{constructor(){super(...arguments);We(this,"name","StaleReactionError");We(this,"message","The reaction that called `getAbortSignal()` was re-run or destroyed")}};function Sl(e){throw new Error("https://svelte.dev/e/lifecycle_outside_component")}function Ai(){throw new Error("https://svelte.dev/e/async_derived_orphan")}function Oi(e,t,s){throw new Error("https://svelte.dev/e/each_key_duplicate")}function Ni(e){throw new Error("https://svelte.dev/e/effect_in_teardown")}function Ii(){throw new Error("https://svelte.dev/e/effect_in_unowned_derived")}function Di(e){throw new Error("https://svelte.dev/e/effect_orphan")}function Li(){throw new Error("https://svelte.dev/e/effect_update_depth_exceeded")}function Ri(){throw new Error("https://svelte.dev/e/state_descriptors_fixed")}function Fi(){throw new Error("https://svelte.dev/e/state_prototype_fixed")}function Pi(){throw new Error("https://svelte.dev/e/state_unsafe_mutation")}function ji(){throw new Error("https://svelte.dev/e/svelte_boundary_reset_onerror")}const $i=1,Bi=2,Ml=4,Vi=8,Hi=16,Wi=1,qi=2,le=Symbol(),Cl="http://www.w3.org/1999/xhtml";function Ui(){console.warn("https://svelte.dev/e/derived_inert")}function zi(){console.warn("https://svelte.dev/e/select_multiple_invalid_value")}function Ki(){console.warn("https://svelte.dev/e/svelte_boundary_reset_noop")}function Tl(e){return e===this.v}function Yi(e,t){return e!=e?t==t:e!==t||e!==null&&typeof e=="object"||typeof e=="function"}function Al(e){return!Yi(e,this.v)}let Us=!1,Gi=!1;function Ji(){Us=!0}let Y=null;function ps(e){Y=e}function Ol(e,t=!1,s){Y={p:Y,i:!1,c:null,e:null,s:e,x:null,r:I,l:Us&&!t?{s:null,u:null,$:[]}:null}}function Nl(e){var t=Y,s=t.e;if(s!==null){t.e=null;for(var n of s)Xl(n)}return t.i=!0,Y=t.p,{}}function zs(){return!Us||Y!==null&&Y.l===null}let Pt=[];function Il(){var e=Pt;Pt=[],Vn(e)}function St(e){if(Pt.length===0&&!Is){var t=Pt;queueMicrotask(()=>{t===Pt&&Il()})}Pt.push(e)}function Qi(){for(;Pt.length>0;)Il()}function Dl(e){var t=I;if(t===null)return D.f|=xt,e;if(!(t.f&Xt)&&!(t.f&vs))throw e;kt(e,t)}function kt(e,t){for(;t!==null;){if(t.f&Hn){if(!(t.f&Xt))throw e;try{t.b.error(e);return}catch(s){e=s}}t=t.parent}throw e}const Xi=-7169;function G(e,t){e.f=e.f&Xi|t}function rr(e){e.f&Fe||e.deps===null?G(e,X):G(e,Ge)}function Ll(e){if(e!==null)for(const t of e)!(t.f&ve)||!(t.f&Yt)||(t.f^=Yt,Ll(t.deps))}function Rl(e,t,s){e.f&ce?t.add(e):e.f&Ge&&s.add(e),Ll(e.deps),G(e,X)}const Ft=new Set;let S=null,oe=null,qn=null,Is=!1,Fn=!1,ls=null,ln=null;var il=0;let Zi=1;var as,is,$t,ut,Ze,js,xe,$s,yt,vt,et,os,cs,Bt,Z,an,Fl,on,Un,cn,eo;const hn=class hn{constructor(){T(this,Z);We(this,"id",Zi++);We(this,"current",new Map);We(this,"previous",new Map);T(this,as,new Set);T(this,is,new Set);T(this,$t,new Set);T(this,ut,new Map);T(this,Ze,new Map);T(this,js,null);T(this,xe,[]);T(this,$s,[]);T(this,yt,new Set);T(this,vt,new Set);T(this,et,new Map);T(this,os,new Set);We(this,"is_fork",!1);T(this,cs,!1);T(this,Bt,new Set)}skip_effect(t){o(this,et).has(t)||o(this,et).set(t,{d:[],m:[]}),o(this,os).delete(t)}unskip_effect(t,s=n=>this.schedule(n)){var n=o(this,et).get(t);if(n){o(this,et).delete(t);for(var l of n.d)G(l,ce),s(l);for(l of n.m)G(l,Ge),s(l)}o(this,os).add(t)}capture(t,s,n=!1){t.v!==le&&!this.previous.has(t)&&this.previous.set(t,t.v),t.f&xt||(this.current.set(t,[s,n]),oe==null||oe.set(t,s)),this.is_fork||(t.v=s)}activate(){S=this}deactivate(){S=null,oe=null}flush(){try{Fn=!0,S=this,z(this,Z,on).call(this)}finally{il=0,qn=null,ls=null,ln=null,Fn=!1,S=null,oe=null,Ut.clear()}}discard(){for(const t of o(this,is))t(this);o(this,is).clear(),o(this,$t).clear(),Ft.delete(this)}register_created_effect(t){o(this,$s).push(t)}increment(t,s){let n=o(this,ut).get(s)??0;if(o(this,ut).set(s,n+1),t){let l=o(this,Ze).get(s)??0;o(this,Ze).set(s,l+1)}}decrement(t,s,n){let l=o(this,ut).get(s)??0;if(l===1?o(this,ut).delete(s):o(this,ut).set(s,l-1),t){let a=o(this,Ze).get(s)??0;a===1?o(this,Ze).delete(s):o(this,Ze).set(s,a-1)}o(this,cs)||n||(O(this,cs,!0),St(()=>{O(this,cs,!1),this.flush()}))}transfer_effects(t,s){for(const n of t)o(this,yt).add(n);for(const n of s)o(this,vt).add(n);t.clear(),s.clear()}oncommit(t){o(this,as).add(t)}ondiscard(t){o(this,is).add(t)}on_fork_commit(t){o(this,$t).add(t)}run_fork_commit_callbacks(){for(const t of o(this,$t))t(this);o(this,$t).clear()}settled(){return(o(this,js)??O(this,js,El())).promise}static ensure(){if(S===null){const t=S=new hn;Fn||(Ft.add(S),Is||St(()=>{S===t&&t.flush()}))}return S}apply(){{oe=null;return}}schedule(t){var l;if(qn=t,(l=t.b)!=null&&l.is_pending&&t.f&(vs|qs|kl)&&!(t.f&Xt)){t.b.defer_effect(t);return}for(var s=t;s.parent!==null;){s=s.parent;var n=s.f;if(ls!==null&&s===I&&(D===null||!(D.f&ve)))return;if(n&(Mt|Ye)){if(!(n&X))return;s.f^=X}}o(this,xe).push(s)}};as=new WeakMap,is=new WeakMap,$t=new WeakMap,ut=new WeakMap,Ze=new WeakMap,js=new WeakMap,xe=new WeakMap,$s=new WeakMap,yt=new WeakMap,vt=new WeakMap,et=new WeakMap,os=new WeakMap,cs=new WeakMap,Bt=new WeakMap,Z=new WeakSet,an=function(){return this.is_fork||o(this,Ze).size>0},Fl=function(){for(const n of o(this,Bt))for(const l of o(n,Ze).keys()){for(var t=!1,s=l;s.parent!==null;){if(o(this,et).has(s)){t=!0;break}s=s.parent}if(!t)return!0}return!1},on=function(){var u,f;if(il++>1e3&&(Ft.delete(this),so()),!z(this,Z,an).call(this)){for(const v of o(this,yt))o(this,vt).delete(v),G(v,ce),this.schedule(v);for(const v of o(this,vt))G(v,Ge),this.schedule(v)}const t=o(this,xe);O(this,xe,[]),this.apply();var s=ls=[],n=[],l=ln=[];for(const v of t)try{z(this,Z,Un).call(this,v,s,n)}catch(p){throw $l(v),p}if(S=null,l.length>0){var a=hn.ensure();for(const v of l)a.schedule(v)}if(ls=null,ln=null,z(this,Z,an).call(this)||z(this,Z,Fl).call(this)){z(this,Z,cn).call(this,n),z(this,Z,cn).call(this,s);for(const[v,p]of o(this,et))jl(v,p)}else{o(this,ut).size===0&&Ft.delete(this),o(this,yt).clear(),o(this,vt).clear();for(const v of o(this,as))v(this);o(this,as).clear(),ol(n),ol(s),(u=o(this,js))==null||u.resolve()}var c=S;if(o(this,xe).length>0){const v=c??(c=this);o(v,xe).push(...o(this,xe).filter(p=>!o(v,xe).includes(p)))}c!==null&&(Ft.add(c),z(f=c,Z,on).call(f))},Un=function(t,s,n){t.f^=X;for(var l=t.first;l!==null;){var a=l.f,c=(a&(Ye|Mt))!==0,u=c&&(a&X)!==0,f=u||(a&he)!==0||o(this,et).has(l);if(!f&&l.fn!==null){c?l.f^=X:a&vs?s.push(l):gs(l)&&(a&nt&&o(this,vt).add(l),Qt(l));var v=l.first;if(v!==null){l=v;continue}}for(;l!==null;){var p=l.next;if(p!==null){l=p;break}l=l.parent}}},cn=function(t){for(var s=0;s<t.length;s+=1)Rl(t[s],o(this,yt),o(this,vt))},eo=function(){var p,k,b;for(const m of Ft){var t=m.id<this.id,s=[];for(const[g,[C,d]]of this.current){if(m.current.has(g)){var n=m.current.get(g)[0];if(t&&C!==n)m.current.set(g,[C,d]);else continue}s.push(g)}var l=[...m.current.keys()].filter(g=>!this.current.has(g));if(l.length===0)t&&m.discard();else if(s.length>0){if(t)for(const g of o(this,os))m.unskip_effect(g,C=>{var d;C.f&(nt|Rs)?m.schedule(C):z(d=m,Z,cn).call(d,[C])});m.activate();var a=new Set,c=new Map;for(var u of s)Pl(u,l,a,c);c=new Map;var f=[...m.current.keys()].filter(g=>this.current.has(g)?this.current.get(g)[0]!==g:!0);for(const g of o(this,$s))!(g.f&(Pe|he|Wn))&&lr(g,f,c)&&(g.f&(Rs|nt)?(G(g,ce),m.schedule(g)):o(m,yt).add(g));if(o(m,xe).length>0){m.apply();for(var v of o(m,xe))z(p=m,Z,Un).call(p,v,[],[]);O(m,xe,[])}m.deactivate()}}for(const m of Ft)o(m,Bt).has(this)&&(o(m,Bt).delete(this),o(m,Bt).size===0&&!z(k=m,Z,an).call(k)&&(m.activate(),z(b=m,Z,on).call(b)))};let Gt=hn;function to(e){var t=Is;Is=!0;try{for(var s;;){if(Qi(),S===null)return s;S.flush()}}finally{Is=t}}function so(){try{Li()}catch(e){kt(e,qn)}}let Ue=null;function ol(e){var t=e.length;if(t!==0){for(var s=0;s<t;){var n=e[s++];if(!(n.f&(Pe|he))&&gs(n)&&(Ue=new Set,Qt(n),n.deps===null&&n.first===null&&n.nodes===null&&n.teardown===null&&n.ac===null&&ea(n),(Ue==null?void 0:Ue.size)>0)){Ut.clear();for(const l of Ue){if(l.f&(Pe|he))continue;const a=[l];let c=l.parent;for(;c!==null;)Ue.has(c)&&(Ue.delete(c),a.push(c)),c=c.parent;for(let u=a.length-1;u>=0;u--){const f=a[u];f.f&(Pe|he)||Qt(f)}}Ue.clear()}}Ue=null}}function Pl(e,t,s,n){if(!s.has(e)&&(s.add(e),e.reactions!==null))for(const l of e.reactions){const a=l.f;a&ve?Pl(l,t,s,n):a&(Rs|nt)&&!(a&ce)&&lr(l,t,n)&&(G(l,ce),ar(l))}}function lr(e,t,s){const n=s.get(e);if(n!==void 0)return n;if(e.deps!==null)for(const l of e.deps){if(us.call(t,l))return!0;if(l.f&ve&&lr(l,t,s))return s.set(l,!0),!0}return s.set(e,!1),!1}function ar(e){S.schedule(e)}function jl(e,t){if(!(e.f&Ye&&e.f&X)){e.f&ce?t.d.push(e):e.f&Ge&&t.m.push(e),G(e,X);for(var s=e.first;s!==null;)jl(s,t),s=s.next}}function $l(e){G(e,X);for(var t=e.first;t!==null;)$l(t),t=t.next}function no(e){let t=0,s=Jt(0),n;return()=>{cr()&&(r(s),wn(()=>(t===0&&(n=y(()=>e(()=>Ds(s)))),t+=1,()=>{St(()=>{t-=1,t===0&&(n==null||n(),n=void 0,Ds(s))})})))}}var ro=ds|bs;function lo(e,t,s,n){new ao(e,t,s,n)}var Ie,tr,De,Vt,ge,Le,pe,Se,dt,Ht,Et,fs,Bs,Vs,pt,_n,J,io,oo,co,zn,fn,un,Kn,Yn;class ao{constructor(t,s,n,l){T(this,J);We(this,"parent");We(this,"is_pending",!1);We(this,"transform_error");T(this,Ie);T(this,tr,null);T(this,De);T(this,Vt);T(this,ge);T(this,Le,null);T(this,pe,null);T(this,Se,null);T(this,dt,null);T(this,Ht,0);T(this,Et,0);T(this,fs,!1);T(this,Bs,new Set);T(this,Vs,new Set);T(this,pt,null);T(this,_n,no(()=>(O(this,pt,Jt(o(this,Ht))),()=>{O(this,pt,null)})));var a;O(this,Ie,t),O(this,De,s),O(this,Vt,c=>{var u=I;u.b=this,u.f|=Hn,n(c)}),this.parent=I.b,this.transform_error=l??((a=this.parent)==null?void 0:a.transform_error)??(c=>c),O(this,ge,ur(()=>{z(this,J,zn).call(this)},ro))}defer_effect(t){Rl(t,o(this,Bs),o(this,Vs))}is_rendered(){return!this.is_pending&&(!this.parent||this.parent.is_rendered())}has_pending_snippet(){return!!o(this,De).pending}update_pending_count(t,s){z(this,J,Kn).call(this,t,s),O(this,Ht,o(this,Ht)+t),!(!o(this,pt)||o(this,fs))&&(O(this,fs,!0),St(()=>{O(this,fs,!1),o(this,pt)&&hs(o(this,pt),o(this,Ht))}))}get_effect_pending(){return o(this,_n).call(this),r(o(this,pt))}error(t){if(!o(this,De).onerror&&!o(this,De).failed)throw t;S!=null&&S.is_fork?(o(this,Le)&&S.skip_effect(o(this,Le)),o(this,pe)&&S.skip_effect(o(this,pe)),o(this,Se)&&S.skip_effect(o(this,Se)),S.on_fork_commit(()=>{z(this,J,Yn).call(this,t)})):z(this,J,Yn).call(this,t)}}Ie=new WeakMap,tr=new WeakMap,De=new WeakMap,Vt=new WeakMap,ge=new WeakMap,Le=new WeakMap,pe=new WeakMap,Se=new WeakMap,dt=new WeakMap,Ht=new WeakMap,Et=new WeakMap,fs=new WeakMap,Bs=new WeakMap,Vs=new WeakMap,pt=new WeakMap,_n=new WeakMap,J=new WeakSet,io=function(){try{O(this,Le,Re(()=>o(this,Vt).call(this,o(this,Ie))))}catch(t){this.error(t)}},oo=function(t){const s=o(this,De).failed;s&&O(this,Se,Re(()=>{s(o(this,Ie),()=>t,()=>()=>{})}))},co=function(){const t=o(this,De).pending;t&&(this.is_pending=!0,O(this,pe,Re(()=>t(o(this,Ie)))),St(()=>{var s=O(this,dt,document.createDocumentFragment()),n=ht();s.append(n),O(this,Le,z(this,J,un).call(this,()=>Re(()=>o(this,Vt).call(this,n)))),o(this,Et)===0&&(o(this,Ie).before(s),O(this,dt,null),zt(o(this,pe),()=>{O(this,pe,null)}),z(this,J,fn).call(this,S))}))},zn=function(){try{if(this.is_pending=this.has_pending_snippet(),O(this,Et,0),O(this,Ht,0),O(this,Le,Re(()=>{o(this,Vt).call(this,o(this,Ie))})),o(this,Et)>0){var t=O(this,dt,document.createDocumentFragment());pr(o(this,Le),t);const s=o(this,De).pending;O(this,pe,Re(()=>s(o(this,Ie))))}else z(this,J,fn).call(this,S)}catch(s){this.error(s)}},fn=function(t){this.is_pending=!1,t.transfer_effects(o(this,Bs),o(this,Vs))},un=function(t){var s=I,n=D,l=Y;Be(o(this,ge)),$e(o(this,ge)),ps(o(this,ge).ctx);try{return Gt.ensure(),t()}catch(a){return Dl(a),null}finally{Be(s),$e(n),ps(l)}},Kn=function(t,s){var n;if(!this.has_pending_snippet()){this.parent&&z(n=this.parent,J,Kn).call(n,t,s);return}O(this,Et,o(this,Et)+t),o(this,Et)===0&&(z(this,J,fn).call(this,s),o(this,pe)&&zt(o(this,pe),()=>{O(this,pe,null)}),o(this,dt)&&(o(this,Ie).before(o(this,dt)),O(this,dt,null)))},Yn=function(t){o(this,Le)&&(we(o(this,Le)),O(this,Le,null)),o(this,pe)&&(we(o(this,pe)),O(this,pe,null)),o(this,Se)&&(we(o(this,Se)),O(this,Se,null));var s=o(this,De).onerror;let n=o(this,De).failed;var l=!1,a=!1;const c=()=>{if(l){Ki();return}l=!0,a&&ji(),o(this,Se)!==null&&zt(o(this,Se),()=>{O(this,Se,null)}),z(this,J,un).call(this,()=>{z(this,J,zn).call(this)})},u=f=>{try{a=!0,s==null||s(f,c),a=!1}catch(v){kt(v,o(this,ge)&&o(this,ge).parent)}n&&O(this,Se,z(this,J,un).call(this,()=>{try{return Re(()=>{var v=I;v.b=this,v.f|=Hn,n(o(this,Ie),()=>f,()=>c)})}catch(v){return kt(v,o(this,ge).parent),null}}))};St(()=>{var f;try{f=this.transform_error(t)}catch(v){kt(v,o(this,ge)&&o(this,ge).parent);return}f!==null&&typeof f=="object"&&typeof f.then=="function"?f.then(u,v=>kt(v,o(this,ge)&&o(this,ge).parent)):u(f)})};function fo(e,t,s,n){const l=zs()?ir:Vl;var a=e.filter(b=>!b.settled);if(s.length===0&&a.length===0){n(t.map(l));return}var c=I,u=uo(),f=a.length===1?a[0].promise:a.length>1?Promise.all(a.map(b=>b.promise)):null;function v(b){u();try{n(b)}catch(m){c.f&Pe||kt(m,c)}pn()}if(s.length===0){f.then(()=>v(t.map(l)));return}var p=Bl();function k(){Promise.all(s.map(b=>vo(b))).then(b=>v([...t.map(l),...b])).catch(b=>kt(b,c)).finally(()=>p())}f?f.then(()=>{u(),k(),pn()}):k()}function uo(){var e=I,t=D,s=Y,n=S;return function(a=!0){Be(e),$e(t),ps(s),a&&!(e.f&Pe)&&(n==null||n.activate(),n==null||n.apply())}}function pn(e=!0){Be(null),$e(null),ps(null),e&&(S==null||S.deactivate())}function Bl(){var e=I,t=e.b,s=S,n=t.is_rendered();return t.update_pending_count(1,s),s.increment(n,e),(l=!1)=>{t.update_pending_count(-1,s),s.decrement(n,e,l)}}function ir(e){var t=ve|ce;return I!==null&&(I.f|=bs),{ctx:Y,deps:null,effects:null,equals:Tl,f:t,fn:e,reactions:null,rv:0,v:le,wv:0,parent:I,ac:null}}function vo(e,t,s){let n=I;n===null&&Ai();var l=void 0,a=Jt(le),c=!D,u=new Map;return Co(()=>{var m;var f=I,v=El();l=v.promise;try{Promise.resolve(e()).then(v.resolve,v.reject).finally(pn)}catch(g){v.reject(g),pn()}var p=S;if(c){if(f.f&Xt)var k=Bl();if(n.b.is_rendered())(m=u.get(p))==null||m.reject(ft),u.delete(p);else{for(const g of u.values())g.reject(ft);u.clear()}u.set(p,v)}const b=(g,C=void 0)=>{if(k){var d=C===ft;k(d)}if(!(C===ft||f.f&Pe)){if(p.activate(),C)a.f|=xt,hs(a,C);else{a.f&xt&&(a.f^=xt),hs(a,g);for(const[M,H]of u){if(u.delete(M),M===p)break;H.reject(ft)}}p.deactivate()}};v.promise.then(b,g=>b(null,g||"unknown"))}),fr(()=>{for(const f of u.values())f.reject(ft)}),new Promise(f=>{function v(p){function k(){p===l?f(a):v(l)}p.then(k,k)}v(l)})}function Vl(e){const t=ir(e);return t.equals=Al,t}function po(e){var t=e.effects;if(t!==null){e.effects=null;for(var s=0;s<t.length;s+=1)we(t[s])}}function or(e){var t,s=I,n=e.parent;if(!Ct&&n!==null&&n.f&(Pe|he))return Ui(),e.v;Be(n);try{e.f&=~Yt,po(e),t=aa(e)}finally{Be(s)}return t}function Hl(e){var t=or(e);if(!e.equals(t)&&(e.wv=ra(),(!(S!=null&&S.is_fork)||e.deps===null)&&(S!==null?S.capture(e,t,!0):e.v=t,e.deps===null))){G(e,X);return}Ct||(oe!==null?(cr()||S!=null&&S.is_fork)&&oe.set(e,t):rr(e))}function ho(e){var t,s;if(e.effects!==null)for(const n of e.effects)(n.teardown||n.ac)&&((t=n.teardown)==null||t.call(n),(s=n.ac)==null||s.abort(ft),n.teardown=Mi,n.ac=null,Fs(n,0),vr(n))}function Wl(e){if(e.effects!==null)for(const t of e.effects)t.teardown&&Qt(t)}let Gn=new Set;const Ut=new Map;let ql=!1;function Jt(e,t){var s={f:0,v:e,reactions:null,equals:Tl,rv:0,wv:0};return s}function mt(e,t){const s=Jt(e);return Oo(s),s}function $(e,t=!1,s=!0){var l;const n=Jt(e);return t||(n.equals=Al),Us&&s&&Y!==null&&Y.l!==null&&((l=Y.l).s??(l.s=[])).push(n),n}function Ms(e,t){return x(e,y(()=>r(e))),t}function x(e,t,s=!1){D!==null&&(!Ke||D.f&Wn)&&zs()&&D.f&(ve|nt|Rs|Wn)&&(je===null||!us.call(je,e))&&Pi();let n=s?As(t):t;return hs(e,n,ln)}function hs(e,t,s=null){if(!e.equals(t)){Ut.set(e,Ct?t:e.v);var n=Gt.ensure();if(n.capture(e,t),e.f&ve){const l=e;e.f&ce&&or(l),oe===null&&rr(l)}e.wv=ra(),Ul(e,ce,s),zs()&&I!==null&&I.f&X&&!(I.f&(Ye|Mt))&&(Ne===null?No([e]):Ne.push(e)),!n.is_fork&&Gn.size>0&&!ql&&_o()}return t}function _o(){ql=!1;for(const e of Gn)e.f&X&&G(e,Ge),gs(e)&&Qt(e);Gn.clear()}function Ds(e){x(e,e.v+1)}function Ul(e,t,s){var n=e.reactions;if(n!==null)for(var l=zs(),a=n.length,c=0;c<a;c++){var u=n[c],f=u.f;if(!(!l&&u===I)){var v=(f&ce)===0;if(v&&G(u,t),f&ve){var p=u;oe==null||oe.delete(p),f&Yt||(f&Fe&&(I===null||!(I.f&dn))&&(u.f|=Yt),Ul(p,Ge,s))}else if(v){var k=u;f&nt&&Ue!==null&&Ue.add(k),s!==null?s.push(k):ar(k)}}}}function As(e){if(typeof e!="object"||e===null||qt in e)return e;const t=nr(e);if(t!==xi&&t!==Si)return e;var s=new Map,n=sr(e),l=mt(0),a=Kt,c=u=>{if(Kt===a)return u();var f=D,v=Kt;$e(null),vl(a);var p=u();return $e(f),vl(v),p};return n&&s.set("length",mt(e.length)),new Proxy(e,{defineProperty(u,f,v){(!("value"in v)||v.configurable===!1||v.enumerable===!1||v.writable===!1)&&Ri();var p=s.get(f);return p===void 0?c(()=>{var k=mt(v.value);return s.set(f,k),k}):x(p,v.value,!0),!0},deleteProperty(u,f){var v=s.get(f);if(v===void 0){if(f in u){const p=c(()=>mt(le));s.set(f,p),Ds(l)}}else x(v,le),Ds(l);return!0},get(u,f,v){var m;if(f===qt)return e;var p=s.get(f),k=f in u;if(p===void 0&&(!k||(m=Ns(u,f))!=null&&m.writable)&&(p=c(()=>{var g=As(k?u[f]:le),C=mt(g);return C}),s.set(f,p)),p!==void 0){var b=r(p);return b===le?void 0:b}return Reflect.get(u,f,v)},getOwnPropertyDescriptor(u,f){var v=Reflect.getOwnPropertyDescriptor(u,f);if(v&&"value"in v){var p=s.get(f);p&&(v.value=r(p))}else if(v===void 0){var k=s.get(f),b=k==null?void 0:k.v;if(k!==void 0&&b!==le)return{enumerable:!0,configurable:!0,value:b,writable:!0}}return v},has(u,f){var b;if(f===qt)return!0;var v=s.get(f),p=v!==void 0&&v.v!==le||Reflect.has(u,f);if(v!==void 0||I!==null&&(!p||(b=Ns(u,f))!=null&&b.writable)){v===void 0&&(v=c(()=>{var m=p?As(u[f]):le,g=mt(m);return g}),s.set(f,v));var k=r(v);if(k===le)return!1}return p},set(u,f,v,p){var P;var k=s.get(f),b=f in u;if(n&&f==="length")for(var m=v;m<k.v;m+=1){var g=s.get(m+"");g!==void 0?x(g,le):m in u&&(g=c(()=>mt(le)),s.set(m+"",g))}if(k===void 0)(!b||(P=Ns(u,f))!=null&&P.writable)&&(k=c(()=>mt(void 0)),x(k,As(v)),s.set(f,k));else{b=k.v!==le;var C=c(()=>As(v));x(k,C)}var d=Reflect.getOwnPropertyDescriptor(u,f);if(d!=null&&d.set&&d.set.call(p,v),!b){if(n&&typeof f=="string"){var M=s.get("length"),H=Number(f);Number.isInteger(H)&&H>=M.v&&x(M,H+1)}Ds(l)}return!0},ownKeys(u){r(l);var f=Reflect.ownKeys(u).filter(k=>{var b=s.get(k);return b===void 0||b.v!==le});for(var[v,p]of s)p.v!==le&&!(v in u)&&f.push(v);return f},setPrototypeOf(){Fi()}})}function cl(e){try{if(e!==null&&typeof e=="object"&&qt in e)return e[qt]}catch{}return e}function bo(e,t){return Object.is(cl(e),cl(t))}var Jn,zl,Kl,Yl;function go(){if(Jn===void 0){Jn=window,zl=/Firefox/.test(navigator.userAgent);var e=Element.prototype,t=Node.prototype,s=Text.prototype;Kl=Ns(t,"firstChild").get,Yl=Ns(t,"nextSibling").get,ll(e)&&(e.__click=void 0,e.__className=void 0,e.__attributes=null,e.__style=void 0,e.__e=void 0),ll(s)&&(s.__t=void 0)}}function ht(e=""){return document.createTextNode(e)}function _s(e){return Kl.call(e)}function Ks(e){return Yl.call(e)}function h(e,t){return _s(e)}function qe(e,t=!1){{var s=_s(e);return s instanceof Comment&&s.data===""?Ks(s):s}}function _(e,t=1,s=!1){let n=e;for(;t--;)n=Ks(n);return n}function mo(e){e.textContent=""}function Gl(){return!1}function wo(e,t,s){return document.createElementNS(Cl,e,void 0)}let fl=!1;function yo(){fl||(fl=!0,document.addEventListener("reset",e=>{Promise.resolve().then(()=>{var t;if(!e.defaultPrevented)for(const s of e.target.elements)(t=s.__on_r)==null||t.call(s)})},{capture:!0}))}function mn(e){var t=D,s=I;$e(null),Be(null);try{return e()}finally{$e(t),Be(s)}}function Jl(e,t,s,n=s){e.addEventListener(t,()=>mn(s));const l=e.__on_r;l?e.__on_r=()=>{l(),n(!0)}:e.__on_r=()=>n(!0),yo()}function Ql(e){I===null&&(D===null&&Di(),Ii()),Ct&&Ni()}function Eo(e,t){var s=t.last;s===null?t.last=t.first=e:(s.next=e,e.prev=s,t.last=e)}function rt(e,t){var s=I;s!==null&&s.f&he&&(e|=he);var n={ctx:Y,deps:null,nodes:null,f:e|ce|Fe,first:null,fn:t,last:null,next:null,parent:s,b:s&&s.b,prev:null,teardown:null,wv:0,ac:null};S==null||S.register_created_effect(n);var l=n;if(e&vs)ls!==null?ls.push(n):Gt.ensure().schedule(n);else if(t!==null){try{Qt(n)}catch(c){throw we(n),c}l.deps===null&&l.teardown===null&&l.nodes===null&&l.first===l.last&&!(l.f&bs)&&(l=l.first,e&nt&&e&ds&&l!==null&&(l.f|=ds))}if(l!==null&&(l.parent=s,s!==null&&Eo(l,s),D!==null&&D.f&ve&&!(e&Mt))){var a=D;(a.effects??(a.effects=[])).push(l)}return n}function cr(){return D!==null&&!Ke}function fr(e){const t=rt(qs,null);return G(t,X),t.teardown=e,t}function Qn(e){Ql();var t=I.f,s=!D&&(t&Ye)!==0&&(t&Xt)===0;if(s){var n=Y;(n.e??(n.e=[])).push(e)}else return Xl(e)}function Xl(e){return rt(vs|xl,e)}function ko(e){return Ql(),rt(qs|xl,e)}function xo(e){Gt.ensure();const t=rt(Mt|bs,e);return(s={})=>new Promise(n=>{s.outro?zt(t,()=>{we(t),n(void 0)}):(we(t),n(void 0))})}function So(e){return rt(vs,e)}function be(e,t){var s=Y,n={effect:null,ran:!1,deps:e};s.l.$.push(n),n.effect=wn(()=>{if(e(),!n.ran){n.ran=!0;var l=I;try{Be(l.parent),y(t)}finally{Be(l)}}})}function Mo(){var e=Y;wn(()=>{for(var t of e.l.$){t.deps();var s=t.effect;s.f&X&&s.deps!==null&&G(s,Ge),gs(s)&&Qt(s),t.ran=!1}})}function Co(e){return rt(Rs|bs,e)}function wn(e,t=0){return rt(qs|t,e)}function K(e,t=[],s=[],n=[]){fo(n,t,s,l=>{rt(qs,()=>e(...l.map(r)))})}function ur(e,t=0){var s=rt(nt|t,e);return s}function Re(e){return rt(Ye|bs,e)}function Zl(e){var t=e.teardown;if(t!==null){const s=Ct,n=D;ul(!0),$e(null);try{t.call(null)}finally{ul(s),$e(n)}}}function vr(e,t=!1){var s=e.first;for(e.first=e.last=null;s!==null;){const l=s.ac;l!==null&&mn(()=>{l.abort(ft)});var n=s.next;s.f&Mt?s.parent=null:we(s,t),s=n}}function To(e){for(var t=e.first;t!==null;){var s=t.next;t.f&Ye||we(t),t=s}}function we(e,t=!0){var s=!1;(t||e.f&Ti)&&e.nodes!==null&&e.nodes.end!==null&&(Ao(e.nodes.start,e.nodes.end),s=!0),G(e,al),vr(e,t&&!s),Fs(e,0);var n=e.nodes&&e.nodes.t;if(n!==null)for(const a of n)a.stop();Zl(e),e.f^=al,e.f|=Pe;var l=e.parent;l!==null&&l.first!==null&&ea(e),e.next=e.prev=e.teardown=e.ctx=e.deps=e.fn=e.nodes=e.ac=e.b=null}function Ao(e,t){for(;e!==null;){var s=e===t?null:Ks(e);e.remove(),e=s}}function ea(e){var t=e.parent,s=e.prev,n=e.next;s!==null&&(s.next=n),n!==null&&(n.prev=s),t!==null&&(t.first===e&&(t.first=n),t.last===e&&(t.last=s))}function zt(e,t,s=!0){var n=[];ta(e,n,!0);var l=()=>{s&&we(e),t&&t()},a=n.length;if(a>0){var c=()=>--a||l();for(var u of n)u.out(c)}else l()}function ta(e,t,s){if(!(e.f&he)){e.f^=he;var n=e.nodes&&e.nodes.t;if(n!==null)for(const u of n)(u.is_global||s)&&t.push(u);for(var l=e.first;l!==null;){var a=l.next;if(!(l.f&Mt)){var c=(l.f&ds)!==0||(l.f&Ye)!==0&&(e.f&nt)!==0;ta(l,t,c?s:!1)}l=a}}}function dr(e){sa(e,!0)}function sa(e,t){if(e.f&he){e.f^=he,e.f&X||(G(e,ce),Gt.ensure().schedule(e));for(var s=e.first;s!==null;){var n=s.next,l=(s.f&ds)!==0||(s.f&Ye)!==0;sa(s,l?t:!1),s=n}var a=e.nodes&&e.nodes.t;if(a!==null)for(const c of a)(c.is_global||t)&&c.in()}}function pr(e,t){if(e.nodes)for(var s=e.nodes.start,n=e.nodes.end;s!==null;){var l=s===n?null:Ks(s);t.append(s),s=l}}let vn=!1,Ct=!1;function ul(e){Ct=e}let D=null,Ke=!1;function $e(e){D=e}let I=null;function Be(e){I=e}let je=null;function Oo(e){D!==null&&(je===null?je=[e]:je.push(e))}let me=null,ke=0,Ne=null;function No(e){Ne=e}let na=1,jt=0,Kt=jt;function vl(e){Kt=e}function ra(){return++na}function gs(e){var t=e.f;if(t&ce)return!0;if(t&ve&&(e.f&=~Yt),t&Ge){for(var s=e.deps,n=s.length,l=0;l<n;l++){var a=s[l];if(gs(a)&&Hl(a),a.wv>e.wv)return!0}t&Fe&&oe===null&&G(e,X)}return!1}function la(e,t,s=!0){var n=e.reactions;if(n!==null&&!(je!==null&&us.call(je,e)))for(var l=0;l<n.length;l++){var a=n[l];a.f&ve?la(a,t,!1):t===a&&(s?G(a,ce):a.f&X&&G(a,Ge),ar(a))}}function aa(e){var C;var t=me,s=ke,n=Ne,l=D,a=je,c=Y,u=Ke,f=Kt,v=e.f;me=null,ke=0,Ne=null,D=v&(Ye|Mt)?null:e,je=null,ps(e.ctx),Ke=!1,Kt=++jt,e.ac!==null&&(mn(()=>{e.ac.abort(ft)}),e.ac=null);try{e.f|=dn;var p=e.fn,k=p();e.f|=Xt;var b=e.deps,m=S==null?void 0:S.is_fork;if(me!==null){var g;if(m||Fs(e,ke),b!==null&&ke>0)for(b.length=ke+me.length,g=0;g<me.length;g++)b[ke+g]=me[g];else e.deps=b=me;if(cr()&&e.f&Fe)for(g=ke;g<b.length;g++)((C=b[g]).reactions??(C.reactions=[])).push(e)}else!m&&b!==null&&ke<b.length&&(Fs(e,ke),b.length=ke);if(zs()&&Ne!==null&&!Ke&&b!==null&&!(e.f&(ve|Ge|ce)))for(g=0;g<Ne.length;g++)la(Ne[g],e);if(l!==null&&l!==e){if(jt++,l.deps!==null)for(let d=0;d<s;d+=1)l.deps[d].rv=jt;if(t!==null)for(const d of t)d.rv=jt;Ne!==null&&(n===null?n=Ne:n.push(...Ne))}return e.f&xt&&(e.f^=xt),k}catch(d){return Dl(d)}finally{e.f^=dn,me=t,ke=s,Ne=n,D=l,je=a,ps(c),Ke=u,Kt=f}}function Io(e,t){let s=t.reactions;if(s!==null){var n=Ei.call(s,e);if(n!==-1){var l=s.length-1;l===0?s=t.reactions=null:(s[n]=s[l],s.pop())}}if(s===null&&t.f&ve&&(me===null||!us.call(me,t))){var a=t;a.f&Fe&&(a.f^=Fe,a.f&=~Yt),a.v!==le&&rr(a),ho(a),Fs(a,0)}}function Fs(e,t){var s=e.deps;if(s!==null)for(var n=t;n<s.length;n++)Io(e,s[n])}function Qt(e){var t=e.f;if(!(t&Pe)){G(e,X);var s=I,n=vn;I=e,vn=!0;try{t&(nt|kl)?To(e):vr(e),Zl(e);var l=aa(e);e.teardown=typeof l=="function"?l:null,e.wv=na;var a;yi&&Gi&&e.f&ce&&e.deps}finally{vn=n,I=s}}}async function Do(){await Promise.resolve(),to()}function r(e){var t=e.f,s=(t&ve)!==0;if(D!==null&&!Ke){var n=I!==null&&(I.f&Pe)!==0;if(!n&&(je===null||!us.call(je,e))){var l=D.deps;if(D.f&dn)e.rv<jt&&(e.rv=jt,me===null&&l!==null&&l[ke]===e?ke++:me===null?me=[e]:me.push(e));else{(D.deps??(D.deps=[])).push(e);var a=e.reactions;a===null?e.reactions=[D]:us.call(a,D)||a.push(D)}}}if(Ct&&Ut.has(e))return Ut.get(e);if(s){var c=e;if(Ct){var u=c.v;return(!(c.f&X)&&c.reactions!==null||oa(c))&&(u=or(c)),Ut.set(c,u),u}var f=(c.f&Fe)===0&&!Ke&&D!==null&&(vn||(D.f&Fe)!==0),v=(c.f&Xt)===0;gs(c)&&(f&&(c.f|=Fe),Hl(c)),f&&!v&&(Wl(c),ia(c))}if(oe!=null&&oe.has(e))return oe.get(e);if(e.f&xt)throw e.v;return e.v}function ia(e){if(e.f|=Fe,e.deps!==null)for(const t of e.deps)(t.reactions??(t.reactions=[])).push(e),t.f&ve&&!(t.f&Fe)&&(Wl(t),ia(t))}function oa(e){if(e.v===le)return!0;if(e.deps===null)return!1;for(const t of e.deps)if(Ut.has(t)||t.f&ve&&oa(t))return!0;return!1}function y(e){var t=Ke;try{return Ke=!0,e()}finally{Ke=t}}function Lo(e){if(!(typeof e!="object"||!e||e instanceof EventTarget)){if(qt in e)Xn(e);else if(!Array.isArray(e))for(let t in e){const s=e[t];typeof s=="object"&&s&&qt in s&&Xn(s)}}}function Xn(e,t=new Set){if(typeof e=="object"&&e!==null&&!(e instanceof EventTarget)&&!t.has(e)){t.add(e),e instanceof Date&&e.getTime();for(let n in e)try{Xn(e[n],t)}catch{}const s=nr(e);if(s!==Object.prototype&&s!==Array.prototype&&s!==Map.prototype&&s!==Set.prototype&&s!==Date.prototype){const n=yl(s);for(let l in n){const a=n[l].get;if(a)try{a.call(e)}catch{}}}}}const Ro=["touchstart","touchmove"];function Fo(e){return Ro.includes(e)}const en=Symbol("events"),Po=new Set,dl=new Set;function jo(e,t,s,n={}){function l(a){if(n.capture||Zn.call(t,a),!a.cancelBubble)return mn(()=>s==null?void 0:s.call(this,a))}return e.startsWith("pointer")||e.startsWith("touch")||e==="wheel"?St(()=>{t.addEventListener(e,l,n)}):t.addEventListener(e,l,n),l}function ie(e,t,s,n,l){var a={capture:n,passive:l},c=jo(e,t,s,a);(t===document.body||t===window||t===document||t instanceof HTMLMediaElement)&&fr(()=>{t.removeEventListener(e,c,a)})}let pl=null;function Zn(e){var d,M;var t=this,s=t.ownerDocument,n=e.type,l=((d=e.composedPath)==null?void 0:d.call(e))||[],a=l[0]||e.target;pl=e;var c=0,u=pl===e&&e[en];if(u){var f=l.indexOf(u);if(f!==-1&&(t===document||t===window)){e[en]=t;return}var v=l.indexOf(t);if(v===-1)return;f<=v&&(c=f)}if(a=l[c]||e.target,a!==t){ki(e,"currentTarget",{configurable:!0,get(){return a||s}});var p=D,k=I;$e(null),Be(null);try{for(var b,m=[];a!==null;){var g=a.assignedSlot||a.parentNode||a.host||null;try{var C=(M=a[en])==null?void 0:M[n];C!=null&&(!a.disabled||e.target===a)&&C.call(a,e)}catch(H){b?m.push(H):b=H}if(e.cancelBubble||g===t||g===null)break;a=g}if(b){for(let H of m)queueMicrotask(()=>{throw H});throw b}}finally{e[en]=t,delete e.currentTarget,$e(p),Be(k)}}}var ml;const Pn=((ml=globalThis==null?void 0:globalThis.window)==null?void 0:ml.trustedTypes)&&globalThis.window.trustedTypes.createPolicy("svelte-trusted-html",{createHTML:e=>e});function $o(e){return(Pn==null?void 0:Pn.createHTML(e))??e}function ca(e){var t=wo("template");return t.innerHTML=$o(e.replaceAll("<!>","<!---->")),t.content}function Ps(e,t){var s=I;s.nodes===null&&(s.nodes={start:e,end:t,a:null,t:null})}function te(e,t){var s=(t&Wi)!==0,n=(t&qi)!==0,l,a=!e.startsWith("<!>");return()=>{l===void 0&&(l=ca(a?e:"<!>"+e),s||(l=_s(l)));var c=n||zl?document.importNode(l,!0):l.cloneNode(!0);if(s){var u=_s(c),f=c.lastChild;Ps(u,f)}else Ps(c,c);return c}}function Bo(e,t,s="svg"){var n=!e.startsWith("<!>"),l=`<${s}>${n?e:"<!>"+e}</${s}>`,a;return()=>{if(!a){var c=ca(l),u=_s(c);a=_s(u)}var f=a.cloneNode(!0);return Ps(f,f),f}}function yn(e,t){return Bo(e,t,"svg")}function ct(e=""){{var t=ht(e+"");return Ps(t,t),t}}function tn(){var e=document.createDocumentFragment(),t=document.createComment(""),s=ht();return e.append(t,s),Ps(t,s),e}function N(e,t){e!==null&&e.before(t)}function A(e,t){var s=t==null?"":typeof t=="object"?`${t}`:t;s!==(e.__t??(e.__t=e.nodeValue))&&(e.__t=s,e.nodeValue=`${s}`)}function Vo(e,t){return Ho(e,t)}const sn=new Map;function Ho(e,{target:t,anchor:s,props:n={},events:l,context:a,intro:c=!0,transformError:u}){go();var f=void 0,v=xo(()=>{var p=s??t.appendChild(ht());lo(p,{pending:()=>{}},m=>{Ol({});var g=Y;a&&(g.c=a),l&&(n.$$events=l),f=e(m,n)||{},Nl()},u);var k=new Set,b=m=>{for(var g=0;g<m.length;g++){var C=m[g];if(!k.has(C)){k.add(C);var d=Fo(C);for(const P of[t,document]){var M=sn.get(P);M===void 0&&(M=new Map,sn.set(P,M));var H=M.get(C);H===void 0?(P.addEventListener(C,Zn,{passive:d}),M.set(C,1)):M.set(C,H+1)}}}};return b(gn(Po)),dl.add(b),()=>{var d;for(var m of k)for(const M of[t,document]){var g=sn.get(M),C=g.get(m);--C==0?(M.removeEventListener(m,Zn),g.delete(m),g.size===0&&sn.delete(M)):g.set(m,C)}dl.delete(b),p!==s&&((d=p.parentNode)==null||d.removeChild(p))}});return Wo.set(f,v),f}let Wo=new WeakMap;var ze,tt,Me,Wt,Hs,Ws,bn;class qo{constructor(t,s=!0){We(this,"anchor");T(this,ze,new Map);T(this,tt,new Map);T(this,Me,new Map);T(this,Wt,new Set);T(this,Hs,!0);T(this,Ws,t=>{if(o(this,ze).has(t)){var s=o(this,ze).get(t),n=o(this,tt).get(s);if(n)dr(n),o(this,Wt).delete(s);else{var l=o(this,Me).get(s);l&&(o(this,tt).set(s,l.effect),o(this,Me).delete(s),l.fragment.lastChild.remove(),this.anchor.before(l.fragment),n=l.effect)}for(const[a,c]of o(this,ze)){if(o(this,ze).delete(a),a===t)break;const u=o(this,Me).get(c);u&&(we(u.effect),o(this,Me).delete(c))}for(const[a,c]of o(this,tt)){if(a===s||o(this,Wt).has(a))continue;const u=()=>{if(Array.from(o(this,ze).values()).includes(a)){var v=document.createDocumentFragment();pr(c,v),v.append(ht()),o(this,Me).set(a,{effect:c,fragment:v})}else we(c);o(this,Wt).delete(a),o(this,tt).delete(a)};o(this,Hs)||!n?(o(this,Wt).add(a),zt(c,u,!1)):u()}}});T(this,bn,t=>{o(this,ze).delete(t);const s=Array.from(o(this,ze).values());for(const[n,l]of o(this,Me))s.includes(n)||(we(l.effect),o(this,Me).delete(n))});this.anchor=t,O(this,Hs,s)}ensure(t,s){var n=S,l=Gl();if(s&&!o(this,tt).has(t)&&!o(this,Me).has(t))if(l){var a=document.createDocumentFragment(),c=ht();a.append(c),o(this,Me).set(t,{effect:Re(()=>s(c)),fragment:a})}else o(this,tt).set(t,Re(()=>s(this.anchor)));if(o(this,ze).set(n,t),l){for(const[u,f]of o(this,tt))u===t?n.unskip_effect(f):n.skip_effect(f);for(const[u,f]of o(this,Me))u===t?n.unskip_effect(f.effect):n.skip_effect(f.effect);n.oncommit(o(this,Ws)),n.ondiscard(o(this,bn))}else o(this,Ws).call(this,n)}}ze=new WeakMap,tt=new WeakMap,Me=new WeakMap,Wt=new WeakMap,Hs=new WeakMap,Ws=new WeakMap,bn=new WeakMap;function ee(e,t,s=!1){var n=new qo(e),l=s?ds:0;function a(c,u){n.ensure(c,u)}ur(()=>{var c=!1;t((u,f=0)=>{c=!0,a(f,u)}),c||a(-1,null)},l)}function Uo(e,t,s){for(var n=[],l=t.length,a,c=t.length,u=0;u<l;u++){let k=t[u];zt(k,()=>{if(a){if(a.pending.delete(k),a.done.add(k),a.pending.size===0){var b=e.outrogroups;er(e,gn(a.done)),b.delete(a),b.size===0&&(e.outrogroups=null)}}else c-=1},!1)}if(c===0){var f=n.length===0&&s!==null;if(f){var v=s,p=v.parentNode;mo(p),p.append(v),e.items.clear()}er(e,t,!f)}else a={pending:new Set(t),done:new Set},(e.outrogroups??(e.outrogroups=new Set)).add(a)}function er(e,t,s=!0){var n;if(e.pending.size>0){n=new Set;for(const c of e.pending.values())for(const u of c)n.add(e.items.get(u).e)}for(var l=0;l<t.length;l++){var a=t[l];if(n!=null&&n.has(a)){a.f|=st;const c=document.createDocumentFragment();pr(a,c)}else we(t[l],s)}}var hl;function nn(e,t,s,n,l,a=null){var c=e,u=new Map,f=(t&Ml)!==0;if(f){var v=e;c=v.appendChild(ht())}var p=null,k=Vl(()=>{var P=s();return sr(P)?P:P==null?[]:gn(P)}),b,m=new Map,g=!0;function C(P){H.effect.f&Pe||(H.pending.delete(P),H.fallback=p,zo(H,b,c,t,n),p!==null&&(b.length===0?p.f&st?(p.f^=st,Os(p,null,c)):dr(p):zt(p,()=>{p=null})))}function d(P){H.pending.delete(P)}var M=ur(()=>{b=r(k);for(var P=b.length,se=new Set,de=S,fe=Gl(),Q=0;Q<P;Q+=1){var Ve=b[Q],W=n(Ve,Q),q=g?null:u.get(W);q?(q.v&&hs(q.v,Ve),q.i&&hs(q.i,Q),fe&&de.unskip_effect(q.e)):(q=Ko(u,g?c:hl??(hl=ht()),Ve,W,Q,l,t,s),g||(q.e.f|=st),u.set(W,q)),se.add(W)}if(P===0&&a&&!p&&(g?p=Re(()=>a(c)):(p=Re(()=>a(hl??(hl=ht()))),p.f|=st)),P>se.size&&Oi(),!g)if(m.set(de,se),fe){for(const[Ce,Te]of u)se.has(Ce)||de.skip_effect(Te.e);de.oncommit(C),de.ondiscard(d)}else C(de);r(k)}),H={effect:M,items:u,pending:m,outrogroups:null,fallback:p};g=!1}function Cs(e){for(;e!==null&&!(e.f&Ye);)e=e.next;return e}function zo(e,t,s,n,l){var q,Ce,Te,_t,lt,ms,Ys,Zt,ws;var a=(n&Vi)!==0,c=t.length,u=e.items,f=Cs(e.effect.first),v,p=null,k,b=[],m=[],g,C,d,M;if(a)for(M=0;M<c;M+=1)g=t[M],C=l(g,M),d=u.get(C).e,d.f&st||((Ce=(q=d.nodes)==null?void 0:q.a)==null||Ce.measure(),(k??(k=new Set)).add(d));for(M=0;M<c;M+=1){if(g=t[M],C=l(g,M),d=u.get(C).e,e.outrogroups!==null)for(const _e of e.outrogroups)_e.pending.delete(d),_e.done.delete(d);if(d.f&he&&(dr(d),a&&((_t=(Te=d.nodes)==null?void 0:Te.a)==null||_t.unfix(),(k??(k=new Set)).delete(d))),d.f&st)if(d.f^=st,d===f)Os(d,null,s);else{var H=p?p.next:f;d===e.effect.last&&(e.effect.last=d.prev),d.prev&&(d.prev.next=d.next),d.next&&(d.next.prev=d.prev),wt(e,p,d),wt(e,d,H),Os(d,H,s),p=d,b=[],m=[],f=Cs(p.next);continue}if(d!==f){if(v!==void 0&&v.has(d)){if(b.length<m.length){var P=m[0],se;p=P.prev;var de=b[0],fe=b[b.length-1];for(se=0;se<b.length;se+=1)Os(b[se],P,s);for(se=0;se<m.length;se+=1)v.delete(m[se]);wt(e,de.prev,fe.next),wt(e,p,de),wt(e,fe,P),f=P,p=fe,M-=1,b=[],m=[]}else v.delete(d),Os(d,f,s),wt(e,d.prev,d.next),wt(e,d,p===null?e.effect.first:p.next),wt(e,p,d),p=d;continue}for(b=[],m=[];f!==null&&f!==d;)(v??(v=new Set)).add(f),m.push(f),f=Cs(f.next);if(f===null)continue}d.f&st||b.push(d),p=d,f=Cs(d.next)}if(e.outrogroups!==null){for(const _e of e.outrogroups)_e.pending.size===0&&(er(e,gn(_e.done)),(lt=e.outrogroups)==null||lt.delete(_e));e.outrogroups.size===0&&(e.outrogroups=null)}if(f!==null||v!==void 0){var Q=[];if(v!==void 0)for(d of v)d.f&he||Q.push(d);for(;f!==null;)!(f.f&he)&&f!==e.fallback&&Q.push(f),f=Cs(f.next);var Ve=Q.length;if(Ve>0){var W=n&Ml&&c===0?s:null;if(a){for(M=0;M<Ve;M+=1)(Ys=(ms=Q[M].nodes)==null?void 0:ms.a)==null||Ys.measure();for(M=0;M<Ve;M+=1)(ws=(Zt=Q[M].nodes)==null?void 0:Zt.a)==null||ws.fix()}Uo(e,Q,W)}}a&&St(()=>{var _e,Gs;if(k!==void 0)for(d of k)(Gs=(_e=d.nodes)==null?void 0:_e.a)==null||Gs.apply()})}function Ko(e,t,s,n,l,a,c,u){var f=c&$i?c&Hi?Jt(s):$(s,!1,!1):null,v=c&Bi?Jt(l):null;return{v:f,i:v,e:Re(()=>(a(t,f??s,v??l,u),()=>{e.delete(n)}))}}function Os(e,t,s){if(e.nodes)for(var n=e.nodes.start,l=e.nodes.end,a=t&&!(t.f&st)?t.nodes.start:s;n!==null;){var c=Ks(n);if(a.before(n),n===l)return;n=c}}function wt(e,t,s){t===null?e.effect.first=s:t.next=s,s===null?e.effect.last=t:s.prev=t}const _l=[...`
|
|
2
|
+
\r\f \v\uFEFF`];function Yo(e,t,s){var n=e==null?"":""+e;if(t&&(n=n?n+" "+t:t),s){for(var l of Object.keys(s))if(s[l])n=n?n+" "+l:l;else if(n.length)for(var a=l.length,c=0;(c=n.indexOf(l,c))>=0;){var u=c+a;(c===0||_l.includes(n[c-1]))&&(u===n.length||_l.includes(n[u]))?n=(c===0?"":n.substring(0,c))+n.substring(u+1):c=u}}return n===""?null:n}function Go(e,t){return e==null?null:String(e)}function ue(e,t,s,n,l,a){var c=e.__className;if(c!==s||c===void 0){var u=Yo(s,n,a);u==null?e.removeAttribute("class"):t?e.className=u:e.setAttribute("class",u),e.__className=s}else if(a&&l!==a)for(var f in a){var v=!!a[f];(l==null||v!==!!l[f])&&e.classList.toggle(f,v)}return a}function Jo(e,t,s,n){var l=e.__style;if(l!==t){var a=Go(t);a==null?e.removeAttribute("style"):e.style.cssText=a,e.__style=t}return n}function fa(e,t,s=!1){if(e.multiple){if(t==null)return;if(!sr(t))return zi();for(var n of e.options)n.selected=t.includes(Ls(n));return}for(n of e.options){var l=Ls(n);if(bo(l,t)){n.selected=!0;return}}(!s||t!==void 0)&&(e.selectedIndex=-1)}function Qo(e){var t=new MutationObserver(()=>{fa(e,e.__value)});t.observe(e,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["value"]}),fr(()=>{t.disconnect()})}function jn(e,t,s=t){var n=new WeakSet,l=!0;Jl(e,"change",a=>{var c=a?"[selected]":":checked",u;if(e.multiple)u=[].map.call(e.querySelectorAll(c),Ls);else{var f=e.querySelector(c)??e.querySelector("option:not([disabled])");u=f&&Ls(f)}s(u),e.__value=u,S!==null&&n.add(S)}),So(()=>{var a=t();if(e===document.activeElement){var c=S;if(n.has(c))return}if(fa(e,a,l),l&&a===void 0){var u=e.querySelector(":checked");u!==null&&(a=Ls(u),s(a))}e.__value=a,l=!1}),Qo(e)}function Ls(e){return"__value"in e?e.__value:e.value}const Xo=Symbol("is custom element"),Zo=Symbol("is html");function rn(e,t,s,n){var l=ec(e);l[t]!==(l[t]=s)&&(s==null?e.removeAttribute(t):typeof s!="string"&&tc(e).includes(t)?e[t]=s:e.setAttribute(t,s))}function ec(e){return e.__attributes??(e.__attributes={[Xo]:e.nodeName.includes("-"),[Zo]:e.namespaceURI===Cl})}var bl=new Map;function tc(e){var t=e.getAttribute("is")||e.nodeName,s=bl.get(t);if(s)return s;bl.set(t,s=[]);for(var n,l=e,a=Element.prototype;a!==l;){n=yl(l);for(var c in n)n[c].set&&s.push(c);l=nr(l)}return s}function Ts(e,t,s=t){var n=new WeakSet;Jl(e,"input",async l=>{var a=l?e.defaultValue:e.value;if(a=$n(e)?Bn(a):a,s(a),S!==null&&n.add(S),await Do(),a!==(a=t())){var c=e.selectionStart,u=e.selectionEnd,f=e.value.length;if(e.value=a??"",u!==null){var v=e.value.length;c===u&&u===f&&v>f?(e.selectionStart=v,e.selectionEnd=v):(e.selectionStart=c,e.selectionEnd=Math.min(u,v))}}}),y(t)==null&&e.value&&(s($n(e)?Bn(e.value):e.value),S!==null&&n.add(S)),wn(()=>{var l=t();if(e===document.activeElement){var a=S;if(n.has(a))return}$n(e)&&l===Bn(e.value)||e.type==="date"&&!l&&!e.value||l!==e.value&&(e.value=l??"")})}function $n(e){var t=e.type;return t==="number"||t==="range"}function Bn(e){return e===""?null:+e}function sc(e){return function(...t){var s=t[0];return s.stopPropagation(),e==null?void 0:e.apply(this,t)}}function nc(e){return function(...t){var s=t[0];return s.preventDefault(),e==null?void 0:e.apply(this,t)}}function rc(e=!1){const t=Y,s=t.l.u;if(!s)return;let n=()=>Lo(t.s);if(e){let l=0,a={};const c=ir(()=>{let u=!1;const f=t.s;for(const v in f)f[v]!==a[v]&&(a[v]=f[v],u=!0);return u&&l++,l});n=()=>r(c)}s.b.length&&ko(()=>{gl(t,n),Vn(s.b)}),Qn(()=>{const l=y(()=>s.m.map(Ci));return()=>{for(const a of l)typeof a=="function"&&a()}}),s.a.length&&Qn(()=>{gl(t,n),Vn(s.a)})}function gl(e,t){if(e.l.s)for(const s of e.l.s)r(s);t()}function lc(e){Y===null&&Sl(),Us&&Y.l!==null?ic(Y).m.push(e):Qn(()=>{const t=y(e);if(typeof t=="function")return t})}function ac(e){Y===null&&Sl(),lc(()=>()=>y(e))}function ic(e){var t=e.l;return t.u??(t.u={a:[],b:[],m:[]})}const oc="5";var wl;typeof window<"u"&&((wl=window.__svelte??(window.__svelte={})).v??(wl.v=new Set)).add(oc);Ji();var cc=yn('<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.8" class="svelte-d3ct2b"><circle cx="12" cy="12" r="5" class="svelte-d3ct2b"></circle><line x1="12" y1="1" x2="12" y2="3" class="svelte-d3ct2b"></line><line x1="12" y1="21" x2="12" y2="23" class="svelte-d3ct2b"></line><line x1="4.22" y1="4.22" x2="5.64" y2="5.64" class="svelte-d3ct2b"></line><line x1="18.36" y1="18.36" x2="19.78" y2="19.78" class="svelte-d3ct2b"></line><line x1="1" y1="12" x2="3" y2="12" class="svelte-d3ct2b"></line><line x1="21" y1="12" x2="23" y2="12" class="svelte-d3ct2b"></line><line x1="4.22" y1="19.78" x2="5.64" y2="18.36" class="svelte-d3ct2b"></line><line x1="18.36" y1="5.64" x2="19.78" y2="4.22" class="svelte-d3ct2b"></line></svg>'),fc=yn('<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.8" class="svelte-d3ct2b"><path d="M21 12.79A9 9 0 1 1 11.21 3 7 7 0 0 0 21 12.79z" class="svelte-d3ct2b"></path></svg>'),uc=te('<span class="health-error svelte-d3ct2b"> </span>'),vc=te('<span class="health-error svelte-d3ct2b"> </span>'),dc=te('<span class="dropdown-badge svelte-d3ct2b"> </span>'),pc=te('<div class="dropdown svelte-d3ct2b"><button><svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" class="svelte-d3ct2b"><circle cx="12" cy="12" r="3" class="svelte-d3ct2b"></circle><path d="M12 1v4M12 19v4M4.22 4.22l2.83 2.83M16.95 16.95l2.83 2.83M1 12h4M19 12h4" class="svelte-d3ct2b"></path></svg> Core Engine</button> <button><svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" class="svelte-d3ct2b"><circle cx="12" cy="12" r="4" class="svelte-d3ct2b"></circle><path d="M4 12H2M22 12h-2M12 4V2M12 22v-2" class="svelte-d3ct2b"></path><path d="m6.34 6.34-1.41-1.42M19.07 19.07l-1.41-1.41" class="svelte-d3ct2b"></path></svg> Commit Hook <!></button></div>'),hc=yn('<svg width="16" height="16" viewBox="0 0 24 24" fill="currentColor" class="svelte-d3ct2b"><polygon points="5 3 19 12 5 21 5 3" class="svelte-d3ct2b"></polygon></svg>'),_c=yn('<svg width="16" height="16" viewBox="0 0 24 24" fill="currentColor" class="svelte-d3ct2b"><rect x="6" y="4" width="4" height="16" class="svelte-d3ct2b"></rect><rect x="14" y="4" width="4" height="16" class="svelte-d3ct2b"></rect></svg>'),bc=te('<div class="log-row svelte-d3ct2b"><span class="log-time svelte-d3ct2b">--:--:--</span> <span class="log-label label-sys svelte-d3ct2b">SYS</span> <span class="log-msg svelte-d3ct2b">Initialization sequence started for memory-core...</span></div> <div class="log-row svelte-d3ct2b"><span class="log-time svelte-d3ct2b">--:--:--</span> <span class="log-label label-ok svelte-d3ct2b">DB</span> <span class="log-msg svelte-d3ct2b">Waiting for PostgreSQL connection...</span></div> <div class="log-row log-row-warn svelte-d3ct2b"><span class="log-time svelte-d3ct2b">--:--:--</span> <span class="log-label label-warn svelte-d3ct2b">WARN</span> <span class="log-msg svelte-d3ct2b">No architecture rules configured in .memory-core.json — nothing to watch.</span></div> <div class="log-row svelte-d3ct2b"><span class="log-time svelte-d3ct2b">--:--:--</span> <span class="log-label label-sys svelte-d3ct2b">SYS</span> <span class="log-msg svelte-d3ct2b">Awaiting manual rule configuration...</span></div> <div class="log-row svelte-d3ct2b"><span class="log-time svelte-d3ct2b"></span> <span class="log-label svelte-d3ct2b"></span> <span class="log-msg cursor-blink svelte-d3ct2b">_</span></div>',1),gc=te('· <em class="svelte-d3ct2b"> </em>',1),mc=te('<br class="svelte-d3ct2b"/><span class="detail-fix svelte-d3ct2b"> </span>',1),wc=te('<div class="log-detail svelte-d3ct2b"><span class="detail-index svelte-d3ct2b"> </span> <span class="detail-body svelte-d3ct2b"><strong class="svelte-d3ct2b"> </strong> <!> <!> <!></span></div>'),yc=te('<div><span class="log-time svelte-d3ct2b"> </span> <span> </span> <span class="log-msg svelte-d3ct2b"><!></span> <button class="copy-btn svelte-d3ct2b" title="Copy">⎘</button></div> <!>',1),Ec=te('<div class="log-row svelte-d3ct2b"><span class="log-time svelte-d3ct2b">--:--:--</span> <span class="log-label label-ok svelte-d3ct2b">[OK]</span> <span class="log-msg svelte-d3ct2b">No commit hook violations in the last 24 hours.</span></div> <div class="log-row svelte-d3ct2b"><span class="log-time svelte-d3ct2b"></span> <span class="log-label svelte-d3ct2b"></span> <span class="log-msg cursor-blink svelte-d3ct2b">_</span></div>',1),kc=te('<br class="svelte-d3ct2b"/><span class="detail-fix svelte-d3ct2b"> </span>',1),xc=te('<div class="log-detail svelte-d3ct2b"><span class="detail-index svelte-d3ct2b"></span> <span class="detail-body svelte-d3ct2b"><!> <!></span></div>'),Sc=te('<div class="log-row log-row-fail svelte-d3ct2b"><span class="log-time svelte-d3ct2b"> </span> <span class="log-label label-hook svelte-d3ct2b"> </span> <span class="log-msg svelte-d3ct2b"><strong class="svelte-d3ct2b"> </strong> <!></span></div> <!>',1),Mc=te('<div class="section-header svelte-d3ct2b"><span class="section-title svelte-d3ct2b">Commit Hook</span> <span class="section-meta svelte-d3ct2b"> </span></div> <!>',1),Cc=te('<span class="rule-reason svelte-d3ct2b"> </span>'),Tc=te('<div class="rule-row svelte-d3ct2b"><span class="rule-badge svelte-d3ct2b"> </span> <span class="rule-scope svelte-d3ct2b"> </span> <span class="rule-content svelte-d3ct2b"> </span> <!> <button class="del-btn svelte-d3ct2b">✕</button></div>'),Ac=te('<div class="log-row svelte-d3ct2b"><span class="log-msg svelte-d3ct2b" style="color: var(--outline)">No rules match the current filters.</span></div>'),Oc=te('<div class="section-header svelte-d3ct2b"><span class="section-title svelte-d3ct2b">Rule Engine</span> <span class="section-meta svelte-d3ct2b"> </span></div> <div class="rules-toolbar svelte-d3ct2b"><select class="rules-select svelte-d3ct2b"><option class="svelte-d3ct2b">All types</option><option class="svelte-d3ct2b">Rules</option><option class="svelte-d3ct2b">Decisions</option><option class="svelte-d3ct2b">Patterns</option><option class="svelte-d3ct2b">Ignores</option></select> <input class="rules-search svelte-d3ct2b" placeholder="Search rules..."/></div> <div class="rule-form-wrap svelte-d3ct2b"><form class="rule-form svelte-d3ct2b"><div class="rule-form-row svelte-d3ct2b"><select class="rules-select svelte-d3ct2b"><option class="svelte-d3ct2b">Rule</option><option class="svelte-d3ct2b">Decision</option><option class="svelte-d3ct2b">Pattern</option><option class="svelte-d3ct2b">Ignore</option></select> <select class="rules-select svelte-d3ct2b"><option class="svelte-d3ct2b">Project</option><option class="svelte-d3ct2b">Global</option></select> <input class="rules-input svelte-d3ct2b" placeholder="Reason"/> <input class="rules-input svelte-d3ct2b" placeholder="Tags"/></div> <div class="rule-form-row svelte-d3ct2b"><textarea rows="2" class="rules-textarea svelte-d3ct2b" placeholder="Rule or decision content..."></textarea> <button class="add-btn svelte-d3ct2b"> </button></div></form></div> <div class="rule-list svelte-d3ct2b"></div>',1),Nc=te('<div><header class="topbar svelte-d3ct2b"><div class="topbar-brand svelte-d3ct2b"><span class="brand-name svelte-d3ct2b">memory-core</span> <nav class="topbar-nav svelte-d3ct2b"><button>Dashboard</button> <button>Live Feed</button> <button>Metrics</button></nav></div> <div class="topbar-search svelte-d3ct2b"><span class="search-icon svelte-d3ct2b">⌕</span> <input class="search-input svelte-d3ct2b" placeholder="Search system logs, traces, and metrics..." type="text"/></div> <div class="topbar-actions svelte-d3ct2b"><button class="icon-btn svelte-d3ct2b" title="Notifications"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.8" class="svelte-d3ct2b"><path d="M18 8A6 6 0 0 0 6 8c0 7-3 9-3 9h18s-3-2-3-9" class="svelte-d3ct2b"></path><path d="M13.73 21a2 2 0 0 1-3.46 0" class="svelte-d3ct2b"></path></svg></button> <button><svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.8" class="svelte-d3ct2b"><rect x="2" y="3" width="20" height="14" rx="2" class="svelte-d3ct2b"></rect><path d="m7 21 5-5 5 5" class="svelte-d3ct2b"></path><path d="m7 8 3 3-3 3" class="svelte-d3ct2b"></path><path d="M13 14h4" class="svelte-d3ct2b"></path></svg></button> <button class="icon-btn svelte-d3ct2b" title="Settings"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.8" class="svelte-d3ct2b"><circle cx="12" cy="12" r="3" class="svelte-d3ct2b"></circle><path d="M19.07 4.93a10 10 0 0 1 0 14.14M4.93 4.93a10 10 0 0 0 0 14.14" class="svelte-d3ct2b"></path><path d="M12 2v2M12 20v2M2 12h2M20 12h2" class="svelte-d3ct2b"></path></svg></button> <button class="icon-btn svelte-d3ct2b"><!></button> <div class="avatar svelte-d3ct2b" title="System Administrator">S</div></div></header> <div class="body svelte-d3ct2b"><aside class="sidebar svelte-d3ct2b"><div class="sidebar-logo svelte-d3ct2b"><svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" class="svelte-d3ct2b"><circle cx="12" cy="12" r="3" class="svelte-d3ct2b"></circle><path d="M12 1v4M12 19v4M4.22 4.22l2.83 2.83M16.95 16.95l2.83 2.83M1 12h4M19 12h4M4.22 19.78l2.83-2.83M16.95 7.05l2.83-2.83" class="svelte-d3ct2b"></path></svg></div> <nav class="sidebar-nav svelte-d3ct2b"><button class="side-btn side-btn-active svelte-d3ct2b" title="Live Feed"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.8" class="svelte-d3ct2b"><rect x="2" y="3" width="20" height="14" rx="2" class="svelte-d3ct2b"></rect><path d="m7 21 5-5 5 5" class="svelte-d3ct2b"></path><path d="m7 8 3 3-3 3" class="svelte-d3ct2b"></path><path d="M13 14h4" class="svelte-d3ct2b"></path></svg></button></nav> <div></div></aside> <main class="content svelte-d3ct2b"><div class="health-bar svelte-d3ct2b"><span class="health-label svelte-d3ct2b">System Health:</span> <div class="health-badge health-green svelte-d3ct2b"><i class="dot dot-green svelte-d3ct2b"></i> <span class="svelte-d3ct2b"> </span></div> <div><i></i> <span class="svelte-d3ct2b"> </span></div> <div class="health-badge health-blue svelte-d3ct2b"><i class="dot dot-blue svelte-d3ct2b"></i> <span class="svelte-d3ct2b"> </span></div> <!> <!></div> <div class="filter-bar svelte-d3ct2b"><div class="filter-left svelte-d3ct2b"><div class="chip chip-primary svelte-d3ct2b"><span class="svelte-d3ct2b">LEVEL: ALL</span> <button class="chip-close svelte-d3ct2b" title="Clear cache">✕</button></div> <div class="service-dropdown-wrap svelte-d3ct2b"><button class="chip chip-outline svelte-d3ct2b"><span class="svelte-d3ct2b"> </span> <svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5"><polyline points="6 9 12 15 18 9" class="svelte-d3ct2b"></polyline></svg></button> <!></div> <div class="divider-v svelte-d3ct2b"></div> <div class="metrics-strip svelte-d3ct2b"><div class="metric-item svelte-d3ct2b"><span class="metric-label svelte-d3ct2b">VIOLATIONS</span> <span> </span></div> <div class="metric-item svelte-d3ct2b"><span class="metric-label svelte-d3ct2b">FILES</span> <span class="metric-value svelte-d3ct2b"> </span></div> <div class="metric-item svelte-d3ct2b"><span class="metric-label svelte-d3ct2b">RULES</span> <span class="metric-value svelte-d3ct2b"> </span></div></div></div> <div class="filter-right svelte-d3ct2b"><div class="live-badge svelte-d3ct2b"><i></i> <span class="svelte-d3ct2b"> </span></div> <button><!></button> <button class="icon-btn svelte-d3ct2b" title="Download snapshot"><svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" class="svelte-d3ct2b"><path d="M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4" class="svelte-d3ct2b"></path><polyline points="7 10 12 15 17 10" class="svelte-d3ct2b"></polyline><line x1="12" y1="15" x2="12" y2="3" class="svelte-d3ct2b"></line></svg></button></div></div> <div class="feed-area svelte-d3ct2b"><!></div> <footer class="metrics-footer svelte-d3ct2b"><div class="footer-left svelte-d3ct2b"><div class="footer-metric svelte-d3ct2b"><span class="footer-label svelte-d3ct2b">Throughput</span> <span class="footer-val svelte-d3ct2b"> </span> <span class="footer-unit svelte-d3ct2b">EVENTS/SESSION</span></div> <div class="footer-metric svelte-d3ct2b"><span class="footer-label svelte-d3ct2b">Error Rate</span> <span class="footer-val footer-val-error svelte-d3ct2b"> </span> <svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="#ba1a1a" stroke-width="2" class="svelte-d3ct2b"><polyline points="23 6 13.5 15.5 8.5 10.5 1 18" class="svelte-d3ct2b"></polyline><polyline points="17 6 23 6 23 12" class="svelte-d3ct2b"></polyline></svg></div> <div class="footer-metric svelte-d3ct2b"><span class="footer-label svelte-d3ct2b">Latency (P99)</span> <span class="footer-val svelte-d3ct2b">—</span></div></div> <div class="footer-right svelte-d3ct2b"><div class="storage-bar-wrap svelte-d3ct2b"><div class="storage-bar svelte-d3ct2b"><div class="storage-fill svelte-d3ct2b"></div></div> <span class="footer-label svelte-d3ct2b"> </span></div> <button class="cli-btn svelte-d3ct2b"><svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" class="svelte-d3ct2b"><rect x="2" y="3" width="20" height="14" rx="2" class="svelte-d3ct2b"></rect><path d="m7 8 3 3-3 3" class="svelte-d3ct2b"></path><path d="M13 14h4" class="svelte-d3ct2b"></path></svg> CLI CONSOLE</button></div></footer></main></div></div>');function Ic(e,t){Ol(t,!1);const s=$(),n=$(),l=$(),a=$(),c=$(),u=$(),f=$(),v=$(),p=$(),k=$(),b=$(),m=$(),g=$(),C=$();let d=$({config:null,stats:{rules:{},files:{},topRules:[],topFiles:[]},files:[],memories:[]}),M=$([]),H=$(!1),P=$("all"),se=$(""),de=$(!1),fe=$(""),Q,Ve=!1,W=$({type:"rule",scope:"project",content:"",reason:"",tags:"dashboard"}),q=$("live-feed"),Ce=$("live-feed"),Te=$(!1),_t=$("core-engine"),lt=$(!1),ms=$("");const Ys=24*60*60*1e3;function Zt(i){r(lt)||x(M,[{...i,id:crypto.randomUUID()},...r(M)].slice(0,80))}function ws(i){return i.type==="saved"?{type:"saved",timestamp:i.timestamp,file:i.file}:i.type==="clean"?{type:"clean",timestamp:i.timestamp,file:i.file}:i.type==="skipped"?{type:"skipped",timestamp:i.timestamp,file:i.file,reason:i.reason}:i.type==="violations"?{type:"violations",timestamp:i.timestamp,file:i.file,violations:i.violations}:i.type==="log"?{type:"log",timestamp:i.timestamp,file:i.file,message:i.message}:i.type==="error"?{type:"error",timestamp:i.timestamp,message:i.message}:i.type==="ready"?{type:"system",timestamp:i.timestamp,message:`Watching ${i.path} | ${i.rules} rules | ${i.model}`}:{type:"system",timestamp:i.timestamp,message:"Watch stopped"}}function _e(i){const w=r(d).files??[],L=w.findIndex(ae=>ae.file===i.file),V=w.slice();return L===-1?V.push(i):V[L]=i,V.sort((ae,ne)=>ne.lastSeen.localeCompare(ae.lastSeen))}function Gs(i){const w=r(d).watcher??{enabled:!0,running:!1,path:void 0,model:void 0,rules:void 0,lastEventAt:void 0,error:void 0};let L=r(d).files,V={...w,lastEventAt:i.timestamp,enabled:!0};i.type==="ready"&&(V={...V,running:!0,error:void 0,path:i.path,model:i.model,rules:i.rules}),i.type==="saved"&&(L=_e({file:i.file,status:"checking",lastSeen:i.timestamp,violations:[]})),i.type==="clean"&&(L=_e({file:i.file,status:"clean",lastSeen:i.timestamp,violations:[]})),i.type==="skipped"&&(L=_e({file:i.file,status:"skipped",lastSeen:i.timestamp,violations:[],message:i.reason})),i.type==="violations"&&(L=_e({file:i.file,status:"violations",lastSeen:i.timestamp,violations:i.violations})),i.type==="error"&&(V={...V,running:!1,error:i.message}),i.type==="stopped"&&(V={...V,running:!1});const ae=[i,...r(d).events??[]].slice(0,100);x(d,{...r(d),files:L,events:ae,watcher:V})}function En(i=[]){x(M,i.map(ws).map(w=>({...w,id:crypto.randomUUID()})).reverse().slice(0,80))}function hr(i){return new Intl.DateTimeFormat(void 0,{hour:"2-digit",minute:"2-digit",second:"2-digit"}).format(new Date(i))}function _r(i,w){const L=i.file||w;return i.line?`${L}:${i.line}`:L}function ua(i){return i.type==="saved"?"SAVE":i.type==="clean"?"OK":i.type==="skipped"?"SKIP":i.type==="violations"?"FAIL":i.type==="log"?"CHCK":i.type==="error"?"WARN":"SYS"}function va(i){return i.type==="clean"?"label-ok":i.type==="violations"||i.type==="error"?"label-warn":i.type==="log"?"label-chck":i.type==="system"?"label-sys":"label-info"}async function Js(){const i=await fetch(`/api/snapshot?t=${Date.now()}`,{cache:"no-store"});x(d,await i.json()),En(r(d).events)}async function da(){x(fe,"");try{const i=await fetch("/api/refresh",{method:"POST",headers:{"content-type":"application/json"},cache:"no-store"});if(!i.ok)throw new Error((await i.json()).error??"Refresh failed");const w=await i.json();w.snapshot?(x(d,w.snapshot),En(r(d).events)):await Js()}catch(i){x(fe,i.message)}}function pa(){try{localStorage.clear(),sessionStorage.clear()}finally{location.reload()}}async function ha(){if(!Ve&&document.visibilityState!=="hidden"){Ve=!0;try{const i=await fetch("/api/stats",{cache:"no-store"});if(!i.ok)return;const w=await i.json();if(!w.stats)return;x(d,{...r(d),stats:w.stats})}catch{}finally{Ve=!1}}}function _a(){Q&&clearInterval(Q),Q=setInterval(()=>{ha()},2e3)}function br(){const i=location.protocol==="https:"?"wss:":"ws:",w=new WebSocket(`${i}//${location.host}/ws`);w.addEventListener("open",()=>{x(H,!0),Zt({type:"system",timestamp:new Date().toISOString(),message:"Dashboard connected"})}),w.addEventListener("close",()=>{x(H,!1),Zt({type:"error",timestamp:new Date().toISOString(),message:"Dashboard disconnected"}),setTimeout(br,1500)}),w.addEventListener("message",L=>{const V=JSON.parse(L.data);if(V.type==="snapshot"){x(d,V.snapshot),r(M).length===0&&En(r(d).events);return}V.type==="watch"&&(Gs(V.event),Zt(ws(V.event)))})}async function ba(){if(r(W).content.trim()){x(de,!0),x(fe,"");try{const i=await fetch("/api/memories",{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify(r(W))});if(!i.ok)throw new Error((await i.json()).error??"Save failed");x(W,{type:"rule",scope:"project",content:"",reason:"",tags:"dashboard"}),await Js()}catch(i){x(fe,i.message)}finally{x(de,!1)}}}async function ga(i){x(fe,"");const w=await fetch(`/api/memories/${i}`,{method:"DELETE"});if(!w.ok){x(fe,(await w.json()).error??"Delete failed");return}await Js()}function gr(i){x(_t,i),x(Te,!1),i==="commit-hook"?x(q,"commit-hook"):x(q,"live-feed")}function ma(){x(q,r(q)==="commit-hook"?"live-feed":"commit-hook"),x(_t,r(q)==="commit-hook"?"commit-hook":"core-engine")}function wa(i){r(Te)&&(i.target.closest(".service-dropdown-wrap")||x(Te,!1))}let es=$(localStorage.getItem("mc-theme")==="dark"||!localStorage.getItem("mc-theme")&&window.matchMedia("(prefers-color-scheme: dark)").matches);function ya(){x(es,!r(es)),localStorage.setItem("mc-theme",r(es)?"dark":"light")}Js().catch(i=>{x(fe,i.message)}),br(),_a(),ac(()=>{Q&&(clearInterval(Q),Q=void 0)}),be(()=>(r(d),r(P),r(se)),()=>{x(s,r(d).memories.filter(i=>{const w=r(P)==="all"||i.type===r(P),L=`${i.type} ${i.scope} ${i.content} ${i.reason??""} ${i.tags.join(" ")}`.toLowerCase();return w&&L.includes(r(se).toLowerCase())}))}),be(()=>r(d),()=>{x(n,r(d).files.reduce((i,w)=>i+w.violations.length,0))}),be(()=>r(d),()=>{x(l,r(d).files.filter(i=>i.status==="clean").length)}),be(()=>r(d),()=>{x(a,Object.values(r(d).stats.rules).reduce((i,w)=>i+w,0))}),be(()=>r(d),()=>{x(c,r(d).stats.recentViolations??[])}),be(()=>r(c),()=>{x(u,r(c).filter(i=>{if(!(i.source==="hook"||i.source==="ci"))return!1;const w=Date.parse(i.timestamp);return Number.isNaN(w)?!1:Date.now()-w<=Ys}))}),be(()=>r(n),()=>{x(f,r(n))}),be(()=>r(d),()=>{x(v,r(d).files.filter(i=>i.status!=="checking").length)}),be(()=>r(d),()=>{x(p,r(d).memories.filter(i=>["rule","pattern","decision"].includes(i.type)).length)}),be(()=>r(d),()=>{var i;x(k,((i=r(d).memoryCount)==null?void 0:i.total)??r(d).memories.length)}),be(()=>(r(H),r(d)),()=>{var i,w;x(b,r(H)?((i=r(d).watcher)==null?void 0:i.enabled)===!1?{live:!1,label:"Watch off"}:(w=r(d).watcher)!=null&&w.running?{live:!0,label:"Watcher live"}:{live:!1,label:"Watcher idle"}:{live:!1,label:"Disconnected"})}),be(()=>r(d),()=>{var i;x(m,((i=r(d).runtime)==null?void 0:i.postgres.connected)??!1)}),be(()=>r(d),()=>{var i;x(g,((i=r(d).runtime)==null?void 0:i.model.ollamaReachable)??!1)}),be(()=>r(d),()=>{var i,w;x(C,(((i=r(d).runtime)==null?void 0:i.model.checkModelResolved)??((w=r(d).runtime)==null?void 0:w.model.chatModel)??"unknown").toUpperCase())}),Mo(),rc();var kn=Nc();ie("click",Jn,wa);let mr;var wr=h(kn),yr=h(wr),Ea=_(h(yr),2),xn=h(Ea);let Er;var Sn=_(xn,2);let kr;var xr=_(Sn,2);let Sr;var Mr=_(yr,2),ka=_(h(Mr),2),xa=_(Mr,2),Qs=_(h(xa),2);let Cr;var Tr=_(Qs,2),Mn=_(Tr,2),Sa=h(Mn);{var Ma=i=>{var w=cc();N(i,w)},Ca=i=>{var w=fc();N(i,w)};ee(Sa,i=>{r(es)?i(Ma):i(Ca,-1)})}var Ta=_(wr,2),Ar=h(Ta),Or=_(h(Ar),4);let Nr;var Aa=_(Ar,2),Ir=h(Aa),Dr=_(h(Ir),2),Oa=_(h(Dr),2),Na=h(Oa),Cn=_(Dr,2);let Lr;var Rr=h(Cn);let Fr;var Ia=_(Rr,2),Da=h(Ia),Pr=_(Cn,2),La=_(h(Pr),2),Ra=h(La),jr=_(Pr,2);{var Fa=i=>{var w=uc(),L=h(w);K(()=>A(L,(r(d),y(()=>r(d).dbError)))),N(i,w)};ee(jr,i=>{r(d),y(()=>r(d).dbError)&&i(Fa)})}var Pa=_(jr,2);{var ja=i=>{var w=vc(),L=h(w);K(()=>A(L,r(fe))),N(i,w)};ee(Pa,i=>{r(fe)&&i(ja)})}var $r=_(Ir,2),Br=h($r),Vr=h(Br),$a=_(h(Vr),2),Hr=_(Vr,2),Tn=h(Hr),Wr=h(Tn),Ba=h(Wr),Va=_(Wr,2);let qr;var Ha=_(Tn,2);{var Wa=i=>{var w=pc(),L=h(w);let V;var ae=_(L,2);let ne;var Ae=_(h(ae),2);{var at=re=>{var E=dc(),Je=h(E);K(()=>A(Je,(r(u),y(()=>r(u).length)))),N(re,E)};ee(Ae,re=>{r(u),y(()=>r(u).length>0)&&re(at)})}K(()=>{V=ue(L,1,"dropdown-item svelte-d3ct2b",null,V,{"dropdown-item-active":r(_t)==="core-engine"}),ne=ue(ae,1,"dropdown-item svelte-d3ct2b",null,ne,{"dropdown-item-active":r(_t)==="commit-hook"})}),ie("click",L,()=>gr("core-engine")),ie("click",ae,()=>gr("commit-hook")),N(i,w)};ee(Ha,i=>{r(Te)&&i(Wa)})}var qa=_(Hr,4),Ur=h(qa),zr=_(h(Ur),2);let Kr;var Ua=h(zr),Yr=_(Ur,2),za=_(h(Yr),2),Ka=h(za),Ya=_(Yr,2),Ga=_(h(Ya),2),Ja=h(Ga),Qa=_(Br,2),Gr=h(Qa),Jr=h(Gr);let Qr;var Xa=_(Jr,2),Za=h(Xa),ys=_(Gr,2);let Xr;var ei=h(ys);{var ti=i=>{var w=hc();N(i,w)},si=i=>{var w=_c();N(i,w)};ee(ei,i=>{r(lt)?i(ti):i(si,-1)})}var ni=_(ys,2),Zr=_($r,2),ri=h(Zr);{var li=i=>{var w=tn(),L=qe(w);{var V=ne=>{var Ae=bc();N(ne,Ae)},ae=ne=>{var Ae=tn(),at=qe(Ae);nn(at,1,()=>(r(M),y(()=>[...r(M)].reverse())),re=>re.id,(re,E)=>{var Je=yc(),Qe=qe(Je);let B;var bt=h(Qe),Tt=h(bt),it=_(bt,2),At=h(it),ot=_(it,2),Ot=h(ot);{var Nt=R=>{var j=ct();K(()=>A(j,(r(E),y(()=>r(E).message)))),N(R,j)},It=R=>{var j=ct();K(()=>A(j,`saved: ${r(E),y(()=>r(E).file)??""}`)),N(R,j)},Dt=R=>{var j=ct();K(()=>A(j,`${r(E),y(()=>r(E).file)??""} — no violations`)),N(R,j)},Lt=R=>{var j=ct();K(()=>A(j,`${r(E),y(()=>r(E).file)??""} — skipped: ${r(E),y(()=>r(E).reason)??""}`)),N(R,j)},ts=R=>{var j=ct();K(()=>A(j,`${r(E),y(()=>r(E).file)??""} — ${r(E),y(()=>r(E).message)??""}`)),N(R,j)},ss=R=>{var j=ct();K(()=>A(j,`${r(E),y(()=>r(E).violations.length)??""} violation${r(E),y(()=>r(E).violations.length===1?"":"s")??""} in ${r(E),y(()=>r(E).file)??""}`)),N(R,j)};ee(Ot,R=>{r(E),y(()=>r(E).type==="system"||r(E).type==="error")?R(Nt):(r(E),y(()=>r(E).type==="saved")?R(It,1):(r(E),y(()=>r(E).type==="clean")?R(Dt,2):(r(E),y(()=>r(E).type==="skipped")?R(Lt,3):(r(E),y(()=>r(E).type==="log")?R(ts,4):R(ss,-1)))))})}var Es=_(ot,2),ye=_(Qe,2);{var Xe=R=>{var j=tn(),Rt=qe(j);nn(Rt,3,()=>(r(E),y(()=>r(E).violations)),(U,F)=>`${r(E).id}-${F}`,(U,F,Oe)=>{var He=wc(),ns=h(He),rs=h(ns),An=_(ns,2),ks=h(An),On=h(ks),xs=_(ks,2);{var Nn=Ee=>{var gt=gc(),Dn=_(qe(gt)),Ln=h(Dn);K(()=>A(Ln,(r(F),y(()=>r(F).rule)))),N(Ee,gt)};ee(xs,Ee=>{r(F),y(()=>r(F).rule)&&Ee(Nn)})}var Xs=_(xs,2);{var Ss=Ee=>{var gt=ct();K(()=>A(gt,`— ${r(F),y(()=>r(F).issue)??""}`)),N(Ee,gt)};ee(Xs,Ee=>{r(F),y(()=>r(F).issue)&&Ee(Ss)})}var Zs=_(Xs,2);{var In=Ee=>{var gt=mc(),Dn=_(qe(gt)),Ln=h(Dn);K(()=>A(Ln,`→ ${r(F),y(()=>r(F).suggestion)??""}`)),N(Ee,gt)};ee(Zs,Ee=>{r(F),y(()=>r(F).suggestion)&&Ee(In)})}K(Ee=>{A(rs,`[${r(Oe)+1}]`),A(On,Ee)},[()=>(r(F),r(E),y(()=>_r(r(F),r(E).file)))]),N(U,He)}),N(R,j)};ee(ye,R=>{r(E),y(()=>r(E).type==="violations")&&R(Xe)})}K((R,j,Rt)=>{B=ue(Qe,1,"log-row svelte-d3ct2b",null,B,{"log-row-warn":r(E).type==="error","log-row-ok":r(E).type==="clean","log-row-fail":r(E).type==="violations"}),A(Tt,R),ue(it,1,`log-label ${j??""}`,"svelte-d3ct2b"),A(At,`[${Rt??""}]`)},[()=>(r(E),y(()=>hr(r(E).timestamp))),()=>(r(E),y(()=>va(r(E)))),()=>(r(E),y(()=>ua(r(E))))]),ie("click",Es,()=>{var j;const R=r(E).type==="system"||r(E).type==="error"?r(E).message:r(E).type==="saved"?`saved: ${r(E).file}`:r(E).file;(j=navigator.clipboard)==null||j.writeText(R)}),N(re,Je)}),N(ne,Ae)};ee(L,ne=>{r(M),y(()=>r(M).length===0)?ne(V):ne(ae,-1)})}N(i,w)},ai=i=>{var w=Mc(),L=qe(w),V=_(h(L),2),ae=h(V),ne=_(L,2);{var Ae=re=>{var E=Ec();N(re,E)},at=re=>{var E=tn(),Je=qe(E);nn(Je,3,()=>(r(u),y(()=>r(u).slice(0,20))),(Qe,B)=>`${Qe.timestamp}-${B}`,(Qe,B)=>{var bt=Sc(),Tt=qe(bt),it=h(Tt),At=h(it),ot=_(it,2),Ot=h(ot),Nt=_(ot,2),It=h(Nt),Dt=h(It),Lt=_(It,2);{var ts=ye=>{var Xe=ct();K(R=>A(Xe,`— ${R??""}`),[()=>(r(B),y(()=>_r(r(B),r(B).file)))]),N(ye,Xe)};ee(Lt,ye=>{r(B),y(()=>r(B).file)&&ye(ts)})}var ss=_(Tt,2);{var Es=ye=>{var Xe=xc(),R=_(h(Xe),2),j=h(R);{var Rt=Oe=>{var He=ct();K(()=>A(He,(r(B),y(()=>r(B).issue)))),N(Oe,He)};ee(j,Oe=>{r(B),y(()=>r(B).issue)&&Oe(Rt)})}var U=_(j,2);{var F=Oe=>{var He=kc(),ns=_(qe(He)),rs=h(ns);K(()=>A(rs,`→ ${r(B),y(()=>r(B).suggestion)??""}`)),N(Oe,He)};ee(U,Oe=>{r(B),y(()=>r(B).suggestion)&&Oe(F)})}N(ye,Xe)};ee(ss,ye=>{r(B),y(()=>r(B).issue||r(B).suggestion)&&ye(Es)})}K(ye=>{A(At,ye),A(Ot,`[${r(B),y(()=>r(B).source==="ci"?"CI":"HOOK")??""}]`),A(Dt,(r(B),y(()=>r(B).rule)))},[()=>(r(B),y(()=>hr(r(B).timestamp)))]),N(Qe,bt)}),N(re,E)};ee(ne,re=>{r(u),y(()=>r(u).length===0)?re(Ae):re(at,-1)})}K(()=>A(ae,`${r(u),y(()=>r(u).length)??""} violation${r(u),y(()=>r(u).length===1?"":"s")??""} in last 24h`)),N(i,w)},ii=i=>{var w=Oc(),L=qe(w),V=_(h(L),2),ae=h(V),ne=_(L,2),Ae=h(ne),at=h(Ae);at.value=at.__value="all";var re=_(at);re.value=re.__value="rule";var E=_(re);E.value=E.__value="decision";var Je=_(E);Je.value=Je.__value="pattern";var Qe=_(Je);Qe.value=Qe.__value="ignore";var B=_(Ae,2),bt=_(ne,2),Tt=h(bt),it=h(Tt),At=h(it),ot=h(At);ot.value=ot.__value="rule";var Ot=_(ot);Ot.value=Ot.__value="decision";var Nt=_(Ot);Nt.value=Nt.__value="pattern";var It=_(Nt);It.value=It.__value="ignore";var Dt=_(At,2),Lt=h(Dt);Lt.value=Lt.__value="project";var ts=_(Lt);ts.value=ts.__value="global";var ss=_(Dt,2),Es=_(ss,2),ye=_(it,2),Xe=h(ye),R=_(Xe,2),j=h(R),Rt=_(bt,2);nn(Rt,5,()=>r(s),U=>U.id,(U,F)=>{var Oe=Tc(),He=h(Oe),ns=h(He),rs=_(He,2),An=h(rs),ks=_(rs,2),On=h(ks),xs=_(ks,2);{var Nn=Ss=>{var Zs=Cc(),In=h(Zs);K(()=>A(In,(r(F),y(()=>r(F).reason)))),N(Ss,Zs)};ee(xs,Ss=>{r(F),y(()=>r(F).reason)&&Ss(Nn)})}var Xs=_(xs,2);K(()=>{A(ns,(r(F),y(()=>r(F).type))),A(An,(r(F),y(()=>r(F).scope))),A(On,(r(F),y(()=>r(F).content)))}),ie("click",Xs,()=>ga(r(F).id)),N(U,Oe)},U=>{var F=Ac();N(U,F)}),K(U=>{A(ae,`${r(p)??""} rules active`),R.disabled=U,A(j,r(de)?"Saving…":"+ Add Rule")},[()=>(r(de),r(W),y(()=>r(de)||!r(W).content.trim()))]),jn(Ae,()=>r(P),U=>x(P,U)),Ts(B,()=>r(se),U=>x(se,U)),jn(At,()=>r(W).type,U=>Ms(W,r(W).type=U)),jn(Dt,()=>r(W).scope,U=>Ms(W,r(W).scope=U)),Ts(ss,()=>r(W).reason,U=>Ms(W,r(W).reason=U)),Ts(Es,()=>r(W).tags,U=>Ms(W,r(W).tags=U)),Ts(Xe,()=>r(W).content,U=>Ms(W,r(W).content=U)),ie("submit",Tt,nc(ba)),N(i,w)};ee(ri,i=>{r(q)==="live-feed"?i(li):r(q)==="commit-hook"?i(ai,1):r(q)==="rules"&&i(ii,2)})}var oi=_(Zr,2),el=h(oi),tl=h(el),ci=_(h(tl),2),fi=h(ci),ui=_(tl,2),vi=_(h(ui),2),di=h(vi),pi=_(el,2),sl=h(pi),nl=h(sl),hi=h(nl),_i=_(nl,2),bi=h(_i),gi=_(sl,2);K((i,w,L,V,ae,ne)=>{mr=ue(kn,1,"shell svelte-d3ct2b",null,mr,{dark:r(es)}),Er=ue(xn,1,"tab-btn svelte-d3ct2b",null,Er,{"tab-active":r(Ce)==="dashboard"}),kr=ue(Sn,1,"tab-btn svelte-d3ct2b",null,kr,{"tab-active":r(Ce)==="live-feed"}),Sr=ue(xr,1,"tab-btn svelte-d3ct2b",null,Sr,{"tab-active":r(Ce)==="metrics"}),Cr=ue(Qs,1,"icon-btn svelte-d3ct2b",null,Cr,{"icon-btn-active":r(q)==="commit-hook"}),rn(Qs,"title",r(q)==="commit-hook"?"Switch to Live Feed":"Switch to Commit Hook"),rn(Mn,"title",r(es)?"Switch to light mode":"Switch to dark mode"),Nr=ue(Or,1,"sidebar-footer-dot svelte-d3ct2b",null,Nr,{"dot-live":r(b).live}),rn(Or,"title",(r(b),y(()=>r(b).label))),A(Na,`CORE ${r(b),y(()=>r(b).live?"LIVE":"IDLE")??""}`),Lr=ue(Cn,1,"health-badge svelte-d3ct2b",null,Lr,{"health-green":r(m),"health-warn":!r(m)}),Fr=ue(Rr,1,"dot svelte-d3ct2b",null,Fr,{"dot-green":r(m),"dot-warn":!r(m)}),A(Da,`DB ${r(m)?"CONNECTED":"DISCONNECTED"}`),A(Ra,`OLLAMA READY: ${r(C)??""}`),A(Ba,`SERVICE: ${r(_t)==="commit-hook"?"COMMIT HOOK":"CORE-ENGINE"}`),qr=ue(Va,0,"chevron svelte-d3ct2b",null,qr,{"chevron-open":r(Te)}),Kr=ue(zr,1,"metric-value svelte-d3ct2b",null,Kr,{"metric-value-warn":r(f)>0}),A(Ua,r(f)),A(Ka,i),A(Ja,w),Qr=ue(Jr,1,"dot dot-green svelte-d3ct2b",null,Qr,{"dot-pulse":r(b).live}),A(Za,L),Xr=ue(ys,1,"icon-btn svelte-d3ct2b",null,Xr,{"icon-btn-active":r(lt)}),rn(ys,"title",r(lt)?"Resume":"Pause"),A(fi,`${V??""}K`),A(di,ae),Jo(hi,`width: ${ne??""}%`),A(bi,`Storage: ${r(k)??""} memories`)},[()=>(r(v),y(()=>r(v).toLocaleString())),()=>(r(p),y(()=>r(p).toLocaleString())),()=>(r(b),y(()=>r(b).live?"LIVE STREAMING":r(b).label.toUpperCase())),()=>(r(a),r(M),y(()=>(r(a)/Math.max(1,r(M).length)*100).toFixed(1))),()=>(r(f),r(v),y(()=>r(f)===0?"0.00%":(r(f)/Math.max(1,r(v))*100).toFixed(2)+"%")),()=>(r(k),y(()=>Math.min(100,r(k)/Math.max(1,r(k)+100)*100+20)))]),ie("click",xn,()=>{x(Ce,"dashboard"),x(q,"live-feed")}),ie("click",Sn,()=>{x(Ce,"live-feed"),x(q,"live-feed")}),ie("click",xr,()=>{x(Ce,"metrics"),x(q,"rules")}),Ts(ka,()=>r(ms),i=>x(ms,i)),ie("click",Qs,ma),ie("click",Tr,da),ie("click",Mn,ya),ie("click",$a,pa),ie("click",Tn,sc(()=>x(Te,!r(Te)))),ie("click",ys,()=>x(lt,!r(lt))),ie("click",ni,()=>{const i=new Blob([JSON.stringify(r(d),null,2)],{type:"application/json"}),w=document.createElement("a");w.href=URL.createObjectURL(i),w.download="memory-core-snapshot.json",w.click()}),ie("click",gi,()=>{x(q,"live-feed"),x(Ce,"live-feed")}),N(e,kn),Nl()}Vo(Ic,{target:document.getElementById("app")});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
:root{color-scheme:light;font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,sans-serif;background:#f5f7f8;color:#172026;font-synthesis:none;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased}body{margin:0;min-width:320px;min-height:100vh}button,input,select,textarea{font:inherit}button{border:0}:root{--primary: #0040e0;--primary-dim: #2e5bff;--primary-container: #efefff;--on-primary: #ffffff;--surface: #f8f9fb;--surface-low: #f3f4f6;--surface-mid: #edeef0;--surface-high: #e7e8ea;--surface-highest: #e1e2e4;--on-surface: #191c1e;--on-surface-var: #434656;--outline: #747688;--outline-var: #c4c5d9;--error: #ba1a1a;--error-bg: #ffdad6;--tertiary: #993100;--green: #10b981;--green-bg: rgba(16,185,129,.1);--green-border: rgba(16,185,129,.3);--mono: "JetBrains Mono", "SFMono-Regular", Consolas, monospace;--sans: "Hanken Grotesk", Inter, ui-sans-serif, system-ui, sans-serif}body{margin:0;background:var(--surface);color:var(--on-surface);font-family:var(--sans);font-size:14px;overflow:hidden;height:100vh}*{box-sizing:border-box}::-webkit-scrollbar{width:5px;height:5px}::-webkit-scrollbar-track{background:var(--surface-low)}::-webkit-scrollbar-thumb{background:var(--outline-var);border-radius:4px}.shell.svelte-d3ct2b{display:flex;flex-direction:column;height:100vh;overflow:hidden}.topbar.svelte-d3ct2b{display:flex;align-items:center;gap:16px;height:64px;padding:0 24px;background:var(--surface);border-bottom:1px solid var(--outline-var);flex-shrink:0;z-index:30}.topbar-brand.svelte-d3ct2b{display:flex;align-items:center;gap:24px;flex-shrink:0}.brand-name.svelte-d3ct2b{font-size:18px;font-weight:700;color:var(--on-surface);font-family:var(--sans);letter-spacing:-.02em}.topbar-nav.svelte-d3ct2b{display:flex;gap:2px}.tab-btn.svelte-d3ct2b{padding:6px 12px;background:transparent;border:none;border-bottom:2px solid transparent;color:var(--on-surface-var);font-family:var(--mono);font-size:11px;font-weight:600;letter-spacing:.04em;cursor:pointer;text-transform:uppercase;transition:color .15s,border-color .15s}.tab-btn.svelte-d3ct2b:hover{color:var(--primary)}.tab-active.svelte-d3ct2b{color:var(--primary)!important;border-bottom-color:var(--primary);font-weight:700}.topbar-search.svelte-d3ct2b{flex:1;max-width:480px;margin:0 auto;position:relative}.search-icon.svelte-d3ct2b{position:absolute;left:12px;top:50%;transform:translateY(-50%);color:var(--on-surface-var);font-size:18px;pointer-events:none;line-height:1}.search-input.svelte-d3ct2b{width:100%;height:36px;padding:0 12px 0 36px;background:var(--surface-mid);border:1px solid var(--outline-var);border-radius:8px;color:var(--on-surface);font-family:var(--sans);font-size:13px;outline:none;transition:border-color .15s}.search-input.svelte-d3ct2b:focus{border-color:var(--primary-dim)}.topbar-actions.svelte-d3ct2b{display:flex;align-items:center;gap:4px;flex-shrink:0}.icon-btn.svelte-d3ct2b{width:34px;height:34px;display:flex;align-items:center;justify-content:center;background:transparent;border:none;border-radius:8px;color:var(--on-surface-var);cursor:pointer;transition:background .15s,color .15s}.icon-btn.svelte-d3ct2b:hover{background:var(--surface-low);color:var(--primary)}.icon-btn-active.svelte-d3ct2b{color:var(--primary)!important;background:var(--primary-container)!important}.avatar.svelte-d3ct2b{width:32px;height:32px;border-radius:50%;background:var(--primary-dim);color:#fff;display:flex;align-items:center;justify-content:center;font-weight:700;font-size:13px;margin-left:8px;border:1px solid var(--outline-var);flex-shrink:0;cursor:default}.body.svelte-d3ct2b{display:flex;flex:1;min-height:0;overflow:hidden}.sidebar.svelte-d3ct2b{width:64px;flex-shrink:0;display:flex;flex-direction:column;align-items:center;padding:16px 0;background:#fff;border-right:1px solid var(--outline-var);z-index:20}.sidebar-logo.svelte-d3ct2b{width:40px;height:40px;background:var(--primary-dim);border-radius:4px;display:flex;align-items:center;justify-content:center;color:#fff;margin-bottom:24px}.sidebar-nav.svelte-d3ct2b{display:flex;flex-direction:column;gap:8px}.side-btn.svelte-d3ct2b{width:36px;height:36px;display:flex;align-items:center;justify-content:center;background:transparent;border:none;border-right:2px solid transparent;color:var(--on-surface-var);cursor:pointer;transition:color .15s;margin-right:-1px}.side-btn.svelte-d3ct2b:hover{color:var(--primary)}.side-btn-active.svelte-d3ct2b{color:var(--primary)!important;background:#0040e014;border-right-color:var(--primary)}.sidebar-footer-dot.svelte-d3ct2b{margin-top:auto;width:8px;height:8px;border-radius:50%;background:var(--outline)}.dot-live.svelte-d3ct2b{background:var(--green)!important;box-shadow:0 0 6px var(--green)}.content.svelte-d3ct2b{flex:1;min-width:0;display:flex;flex-direction:column;overflow:hidden;background:var(--surface)}.health-bar.svelte-d3ct2b{display:flex;align-items:center;gap:8px;padding:6px 24px;border-bottom:1px solid var(--outline-var);background:#fff;flex-shrink:0;flex-wrap:wrap}.health-label.svelte-d3ct2b{font-family:var(--mono);font-size:10px;font-weight:700;color:var(--outline);text-transform:uppercase;letter-spacing:.06em;margin-right:4px}.health-badge.svelte-d3ct2b{display:flex;align-items:center;gap:4px;padding:2px 8px;border-radius:4px;font-family:var(--mono);font-size:10px;font-weight:700}.health-green.svelte-d3ct2b{background:var(--green-bg);color:var(--green);border:1px solid var(--green-border)}.health-blue.svelte-d3ct2b{background:#0040e014;color:var(--primary);border:1px solid rgba(0,64,224,.2)}.health-warn.svelte-d3ct2b{background:#ba1a1a14;color:var(--error);border:1px solid rgba(186,26,26,.25)}.health-error.svelte-d3ct2b{font-family:var(--mono);font-size:10px;color:var(--error);font-weight:700}.dot.svelte-d3ct2b{width:6px;height:6px;border-radius:50%;flex-shrink:0}.dot-green.svelte-d3ct2b{background:var(--green)}.dot-blue.svelte-d3ct2b{background:var(--primary)}.dot-warn.svelte-d3ct2b{background:var(--error)}.dot-pulse.svelte-d3ct2b{animation:svelte-d3ct2b-pulse 1.4s ease-in-out infinite}@keyframes svelte-d3ct2b-pulse{0%,to{opacity:1}50%{opacity:.35}}.filter-bar.svelte-d3ct2b{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:8px 24px;background:var(--surface-low);border-bottom:1px solid var(--outline-var);flex-shrink:0}.filter-left.svelte-d3ct2b,.filter-right.svelte-d3ct2b{display:flex;align-items:center;gap:8px}.chip.svelte-d3ct2b{display:flex;align-items:center;gap:4px;padding:4px 10px;border-radius:8px;font-family:var(--mono);font-size:11px;font-weight:600;cursor:pointer;white-space:nowrap;border:none}.chip-primary.svelte-d3ct2b{background:var(--primary-dim);color:#fff}.chip-close.svelte-d3ct2b{background:transparent;border:none;color:#fffc;cursor:pointer;padding:0;font-size:10px;line-height:1}.chip-outline.svelte-d3ct2b{background:var(--surface);color:var(--on-surface-var);border:1px solid var(--outline-var);transition:border-color .15s}.chip-outline.svelte-d3ct2b:hover{border-color:var(--primary-dim)}.chevron.svelte-d3ct2b{transition:transform .2s}.chevron-open.svelte-d3ct2b{transform:rotate(180deg)}.service-dropdown-wrap.svelte-d3ct2b{position:relative}.dropdown.svelte-d3ct2b{position:absolute;top:calc(100% + 4px);left:0;min-width:180px;background:#fff;border:1px solid var(--outline-var);border-radius:8px;box-shadow:0 8px 24px #0000001f;z-index:100;overflow:hidden;animation:svelte-d3ct2b-dropIn .12s ease}@keyframes svelte-d3ct2b-dropIn{0%{opacity:0;transform:translateY(-4px)}to{opacity:1;transform:translateY(0)}}.dropdown-item.svelte-d3ct2b{display:flex;align-items:center;gap:8px;width:100%;padding:10px 14px;background:transparent;border:none;color:var(--on-surface-var);font-family:var(--sans);font-size:13px;font-weight:500;cursor:pointer;transition:background .12s;text-align:left}.dropdown-item.svelte-d3ct2b:hover{background:var(--surface-low)}.dropdown-item-active.svelte-d3ct2b{color:var(--primary);background:var(--primary-container)}.dropdown-item-active.svelte-d3ct2b:hover{background:var(--primary-container)}.dropdown-badge.svelte-d3ct2b{margin-left:auto;background:var(--error);color:#fff;border-radius:999px;padding:1px 6px;font-size:10px;font-weight:700}.divider-v.svelte-d3ct2b{width:1px;height:28px;background:var(--outline-var);margin:0 4px}.metrics-strip.svelte-d3ct2b{display:flex;align-items:center;gap:24px}.metric-item.svelte-d3ct2b{display:flex;flex-direction:column;align-items:center}.metric-label.svelte-d3ct2b{font-family:var(--mono);font-size:9px;font-weight:700;color:var(--outline);text-transform:uppercase;letter-spacing:.05em;line-height:1}.metric-value.svelte-d3ct2b{font-family:var(--mono);font-size:14px;font-weight:700;color:var(--on-surface);line-height:1.4}.metric-value-warn.svelte-d3ct2b{color:var(--error)}.live-badge.svelte-d3ct2b{display:flex;align-items:center;gap:6px;padding:4px 10px;border:1px solid var(--outline-var);border-radius:8px;background:#fff;font-family:var(--mono);font-size:11px;font-weight:600;color:var(--on-surface);white-space:nowrap}.feed-area.svelte-d3ct2b{flex:1;min-height:0;overflow-y:auto;padding:12px 24px;background:#fff;font-family:var(--mono);font-size:12px}.log-row.svelte-d3ct2b{display:flex;align-items:baseline;gap:12px;padding:3px 8px;border-radius:4px;transition:background .1s;min-height:22px}.log-row.svelte-d3ct2b:hover{background:var(--surface-low)}.log-row-warn.svelte-d3ct2b{background:#ba1a1a0a}.log-row-fail.svelte-d3ct2b{background:#9931000a}.log-time.svelte-d3ct2b{width:80px;flex-shrink:0;color:var(--outline)}.log-label.svelte-d3ct2b{width:56px;flex-shrink:0;font-weight:700}.label-sys.svelte-d3ct2b{color:var(--primary)}.label-ok.svelte-d3ct2b{color:var(--green)}.label-warn.svelte-d3ct2b{color:var(--tertiary)}.label-info.svelte-d3ct2b{color:var(--on-surface-var)}.label-hook.svelte-d3ct2b{color:var(--error)}.log-msg.svelte-d3ct2b{flex:1;min-width:0;color:var(--on-surface-var);word-break:break-all;line-height:1.5}.log-msg.svelte-d3ct2b strong:where(.svelte-d3ct2b){color:var(--on-surface);font-weight:600}.copy-btn.svelte-d3ct2b{opacity:0;background:transparent;border:none;color:var(--outline);cursor:pointer;font-size:14px;padding:0 4px;transition:opacity .15s,color .15s;flex-shrink:0}.log-row.svelte-d3ct2b:hover .copy-btn:where(.svelte-d3ct2b){opacity:1}.copy-btn.svelte-d3ct2b:hover{color:var(--primary)}.log-detail.svelte-d3ct2b{display:flex;gap:8px;padding:3px 8px 3px 148px;font-size:11px;border-left:2px solid rgba(153,49,0,.3);margin-left:8px;margin-bottom:2px}.detail-index.svelte-d3ct2b{color:var(--outline);flex-shrink:0;width:24px}.detail-body.svelte-d3ct2b{color:var(--on-surface-var);flex:1;min-width:0;line-height:1.5}.detail-fix.svelte-d3ct2b{color:var(--primary)}.cursor-blink.svelte-d3ct2b{animation:svelte-d3ct2b-blink 1s step-start infinite}@keyframes svelte-d3ct2b-blink{0%,to{opacity:1}50%{opacity:0}}.section-header.svelte-d3ct2b{display:flex;align-items:baseline;gap:12px;padding:8px 8px 10px;border-bottom:1px solid var(--outline-var);margin-bottom:8px}.section-title.svelte-d3ct2b{font-family:var(--sans);font-size:14px;font-weight:700;color:var(--on-surface)}.section-meta.svelte-d3ct2b{font-size:11px;color:var(--outline);font-family:var(--mono)}.rules-toolbar.svelte-d3ct2b{display:flex;gap:8px;padding:8px;margin-bottom:4px}.rules-select.svelte-d3ct2b,.rules-input.svelte-d3ct2b,.rules-textarea.svelte-d3ct2b{padding:6px 10px;background:var(--surface-low);border:1px solid var(--outline-var);border-radius:6px;color:var(--on-surface);font-family:var(--sans);font-size:13px;outline:none;transition:border-color .15s}.rules-select.svelte-d3ct2b:focus,.rules-input.svelte-d3ct2b:focus,.rules-textarea.svelte-d3ct2b:focus{border-color:var(--primary-dim)}.rules-textarea.svelte-d3ct2b{resize:vertical;flex:1;min-width:0}.rule-form-wrap.svelte-d3ct2b{padding:0 8px 8px;border-bottom:1px solid var(--outline-var);margin-bottom:8px}.rule-form.svelte-d3ct2b{display:flex;flex-direction:column;gap:8px}.rule-form-row.svelte-d3ct2b{display:flex;gap:8px;align-items:flex-start}.add-btn.svelte-d3ct2b{padding:8px 16px;background:var(--primary);color:#fff;border:none;border-radius:6px;font-family:var(--mono);font-size:12px;font-weight:700;cursor:pointer;white-space:nowrap;transition:background .15s;align-self:flex-end}.add-btn.svelte-d3ct2b:hover:not(:disabled){background:var(--primary-dim)}.add-btn.svelte-d3ct2b:disabled{opacity:.5;cursor:not-allowed}.rule-list.svelte-d3ct2b{display:flex;flex-direction:column;gap:4px;overflow-y:auto;max-height:400px;padding:0 8px}.rule-row.svelte-d3ct2b{display:flex;align-items:center;gap:10px;padding:8px 10px;border:1px solid var(--outline-var);border-radius:6px;background:var(--surface-low);font-size:12px;min-width:0;transition:background .1s}.rule-row.svelte-d3ct2b:hover{background:var(--surface-mid)}.rule-badge.svelte-d3ct2b{padding:2px 7px;background:var(--primary-container);color:var(--primary);border-radius:4px;font-family:var(--mono);font-size:10px;font-weight:700;text-transform:uppercase;flex-shrink:0}.rule-scope.svelte-d3ct2b{color:var(--outline);font-family:var(--mono);font-size:10px;font-weight:600;flex-shrink:0}.rule-content.svelte-d3ct2b{flex:1;min-width:0;color:var(--on-surface);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.rule-reason.svelte-d3ct2b{color:var(--on-surface-var);font-size:11px;flex-shrink:0;max-width:180px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.del-btn.svelte-d3ct2b{background:transparent;border:none;color:var(--outline);cursor:pointer;font-size:12px;padding:2px 6px;border-radius:4px;flex-shrink:0;transition:background .1s,color .1s}.del-btn.svelte-d3ct2b:hover{background:var(--error-bg);color:var(--error)}.metrics-footer.svelte-d3ct2b{display:flex;align-items:center;justify-content:space-between;height:48px;padding:0 24px;border-top:1px solid var(--outline-var);background:var(--surface);flex-shrink:0}.footer-left.svelte-d3ct2b,.footer-right.svelte-d3ct2b{display:flex;align-items:center;gap:24px}.footer-metric.svelte-d3ct2b{display:flex;align-items:center;gap:6px}.footer-label.svelte-d3ct2b{font-family:var(--mono);font-size:10px;font-weight:700;color:var(--outline);text-transform:uppercase;letter-spacing:.04em}.footer-val.svelte-d3ct2b{font-family:var(--mono);font-size:14px;font-weight:700;color:var(--on-surface)}.footer-val-error.svelte-d3ct2b{color:var(--error)}.footer-unit.svelte-d3ct2b{font-family:var(--mono);font-size:9px;color:var(--outline);text-transform:uppercase}.storage-bar-wrap.svelte-d3ct2b{display:flex;align-items:center;gap:8px}.storage-bar.svelte-d3ct2b{width:96px;height:6px;background:var(--surface-mid);border-radius:999px;overflow:hidden}.storage-fill.svelte-d3ct2b{height:100%;background:var(--primary-dim);border-radius:999px;transition:width .6s ease}.cli-btn.svelte-d3ct2b{display:flex;align-items:center;gap:6px;padding:5px 12px;background:var(--surface-high);border:none;border-radius:4px;color:var(--on-surface);font-family:var(--mono);font-size:11px;font-weight:700;cursor:pointer;transition:background .15s}.cli-btn.svelte-d3ct2b:hover{background:var(--outline-var)}.dark.svelte-d3ct2b{--primary: #b8c3ff;--primary-dim: #4d6dff;--primary-container: #1a2340;--on-primary: #ffffff;--surface: #111318;--surface-low: #0c0e12;--surface-mid: #1e2024;--surface-high: #282a2e;--surface-highest: #37393e;--on-surface: #e2e2e8;--on-surface-var: #c4c5d9;--outline: #747688;--outline-var: #3a3c4a;--error: #ffb4ab;--error-bg: rgba(147,0,10,.22);--tertiary: #ffb59b;--green: #03f59b;--green-bg: rgba(3,245,155,.1);--green-border: rgba(3,245,155,.28)}.dark.svelte-d3ct2b body{background:var(--surface)}.dark.svelte-d3ct2b .topbar:where(.svelte-d3ct2b){background:#1a1c20;border-bottom-color:var(--outline-var)}.dark.svelte-d3ct2b .sidebar:where(.svelte-d3ct2b){background:#0c0e12;border-right-color:var(--outline-var)}.dark.svelte-d3ct2b .health-bar:where(.svelte-d3ct2b){background:#1a1c20;border-bottom-color:var(--outline-var)}.dark.svelte-d3ct2b .filter-bar:where(.svelte-d3ct2b){background:#111318;border-bottom-color:var(--outline-var)}.dark.svelte-d3ct2b .feed-area:where(.svelte-d3ct2b){background:#0c0e12}.dark.svelte-d3ct2b .metrics-footer:where(.svelte-d3ct2b){background:#111318;border-top-color:var(--outline-var)}.dark.svelte-d3ct2b .search-input:where(.svelte-d3ct2b){background:#1e2024;border-color:var(--outline-var);color:var(--on-surface)}.dark.svelte-d3ct2b .dropdown:where(.svelte-d3ct2b){background:#1e2024;border-color:var(--outline-var);box-shadow:0 8px 24px #00000073}.dark.svelte-d3ct2b .dropdown-item:where(.svelte-d3ct2b):hover{background:#282a2e}.dark.svelte-d3ct2b .dropdown-item-active:where(.svelte-d3ct2b){background:var(--primary-container);color:var(--primary)}.dark.svelte-d3ct2b .chip-outline:where(.svelte-d3ct2b){background:#1e2024}.dark.svelte-d3ct2b .live-badge:where(.svelte-d3ct2b){background:#1e2024}.dark.svelte-d3ct2b .rule-row:where(.svelte-d3ct2b){background:#1e2024;border-color:var(--outline-var)}.dark.svelte-d3ct2b .rule-row:where(.svelte-d3ct2b):hover{background:#282a2e}.dark.svelte-d3ct2b .rules-select:where(.svelte-d3ct2b),.dark.svelte-d3ct2b .rules-input:where(.svelte-d3ct2b),.dark.svelte-d3ct2b .rules-textarea:where(.svelte-d3ct2b){background:#1e2024;border-color:var(--outline-var);color:var(--on-surface)}.dark.svelte-d3ct2b .log-row:where(.svelte-d3ct2b):hover{background:#1e2024}.dark.svelte-d3ct2b .log-row-warn:where(.svelte-d3ct2b){background:#ffb4ab0d}.dark.svelte-d3ct2b .log-row-fail:where(.svelte-d3ct2b){background:#ffba200a}.dark.svelte-d3ct2b .section-header:where(.svelte-d3ct2b){border-bottom-color:var(--outline-var)}.dark.svelte-d3ct2b .storage-bar:where(.svelte-d3ct2b){background:#282a2e}@media (max-width: 768px){.sidebar.svelte-d3ct2b,.topbar-nav.svelte-d3ct2b,.metrics-strip.svelte-d3ct2b{display:none}.filter-bar.svelte-d3ct2b,.feed-area.svelte-d3ct2b{padding:8px 12px}.metrics-footer.svelte-d3ct2b{padding:0 12px;gap:12px}.footer-metric.svelte-d3ct2b:nth-child(n+2){display:none}}
|
|
1
|
+
:root{color-scheme:light;font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,sans-serif;background:#f5f7f8;color:#172026;font-synthesis:none;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased}body{margin:0;min-width:320px;min-height:100vh}button,input,select,textarea{font:inherit}button{border:0}:root{--primary: #0040e0;--primary-dim: #2e5bff;--primary-container: #efefff;--on-primary: #ffffff;--surface: #f8f9fb;--surface-low: #f3f4f6;--surface-mid: #edeef0;--surface-high: #e7e8ea;--surface-highest: #e1e2e4;--on-surface: #191c1e;--on-surface-var: #434656;--outline: #747688;--outline-var: #c4c5d9;--error: #ba1a1a;--error-bg: #ffdad6;--tertiary: #993100;--green: #10b981;--green-bg: rgba(16,185,129,.1);--green-border: rgba(16,185,129,.3);--mono: "JetBrains Mono", "SFMono-Regular", Consolas, monospace;--sans: "Hanken Grotesk", Inter, ui-sans-serif, system-ui, sans-serif}body{margin:0;background:var(--surface);color:var(--on-surface);font-family:var(--sans);font-size:14px;overflow:hidden;height:100vh}*{box-sizing:border-box}::-webkit-scrollbar{width:5px;height:5px}::-webkit-scrollbar-track{background:var(--surface-low)}::-webkit-scrollbar-thumb{background:var(--outline-var);border-radius:4px}.shell.svelte-d3ct2b{display:flex;flex-direction:column;height:100vh;overflow:hidden}.topbar.svelte-d3ct2b{display:flex;align-items:center;gap:16px;height:64px;padding:0 24px;background:var(--surface);border-bottom:1px solid var(--outline-var);flex-shrink:0;z-index:30}.topbar-brand.svelte-d3ct2b{display:flex;align-items:center;gap:24px;flex-shrink:0}.brand-name.svelte-d3ct2b{font-size:18px;font-weight:700;color:var(--on-surface);font-family:var(--sans);letter-spacing:-.02em}.topbar-nav.svelte-d3ct2b{display:flex;gap:2px}.tab-btn.svelte-d3ct2b{padding:6px 12px;background:transparent;border:none;border-bottom:2px solid transparent;color:var(--on-surface-var);font-family:var(--mono);font-size:11px;font-weight:600;letter-spacing:.04em;cursor:pointer;text-transform:uppercase;transition:color .15s,border-color .15s}.tab-btn.svelte-d3ct2b:hover{color:var(--primary)}.tab-active.svelte-d3ct2b{color:var(--primary)!important;border-bottom-color:var(--primary);font-weight:700}.topbar-search.svelte-d3ct2b{flex:1;max-width:480px;margin:0 auto;position:relative}.search-icon.svelte-d3ct2b{position:absolute;left:12px;top:50%;transform:translateY(-50%);color:var(--on-surface-var);font-size:18px;pointer-events:none;line-height:1}.search-input.svelte-d3ct2b{width:100%;height:36px;padding:0 12px 0 36px;background:var(--surface-mid);border:1px solid var(--outline-var);border-radius:8px;color:var(--on-surface);font-family:var(--sans);font-size:13px;outline:none;transition:border-color .15s}.search-input.svelte-d3ct2b:focus{border-color:var(--primary-dim)}.topbar-actions.svelte-d3ct2b{display:flex;align-items:center;gap:4px;flex-shrink:0}.icon-btn.svelte-d3ct2b{width:34px;height:34px;display:flex;align-items:center;justify-content:center;background:transparent;border:none;border-radius:8px;color:var(--on-surface-var);cursor:pointer;transition:background .15s,color .15s}.icon-btn.svelte-d3ct2b:hover{background:var(--surface-low);color:var(--primary)}.icon-btn-active.svelte-d3ct2b{color:var(--primary)!important;background:var(--primary-container)!important}.avatar.svelte-d3ct2b{width:32px;height:32px;border-radius:50%;background:var(--primary-dim);color:#fff;display:flex;align-items:center;justify-content:center;font-weight:700;font-size:13px;margin-left:8px;border:1px solid var(--outline-var);flex-shrink:0;cursor:default}.body.svelte-d3ct2b{display:flex;flex:1;min-height:0;overflow:hidden}.sidebar.svelte-d3ct2b{width:64px;flex-shrink:0;display:flex;flex-direction:column;align-items:center;padding:16px 0;background:#fff;border-right:1px solid var(--outline-var);z-index:20}.sidebar-logo.svelte-d3ct2b{width:40px;height:40px;background:var(--primary-dim);border-radius:4px;display:flex;align-items:center;justify-content:center;color:#fff;margin-bottom:24px}.sidebar-nav.svelte-d3ct2b{display:flex;flex-direction:column;gap:8px}.side-btn.svelte-d3ct2b{width:36px;height:36px;display:flex;align-items:center;justify-content:center;background:transparent;border:none;border-right:2px solid transparent;color:var(--on-surface-var);cursor:pointer;transition:color .15s;margin-right:-1px}.side-btn.svelte-d3ct2b:hover{color:var(--primary)}.side-btn-active.svelte-d3ct2b{color:var(--primary)!important;background:#0040e014;border-right-color:var(--primary)}.sidebar-footer-dot.svelte-d3ct2b{margin-top:auto;width:8px;height:8px;border-radius:50%;background:var(--outline)}.dot-live.svelte-d3ct2b{background:var(--green)!important;box-shadow:0 0 6px var(--green)}.content.svelte-d3ct2b{flex:1;min-width:0;display:flex;flex-direction:column;overflow:hidden;background:var(--surface)}.health-bar.svelte-d3ct2b{display:flex;align-items:center;gap:8px;padding:6px 24px;border-bottom:1px solid var(--outline-var);background:#fff;flex-shrink:0;flex-wrap:wrap}.health-label.svelte-d3ct2b{font-family:var(--mono);font-size:10px;font-weight:700;color:var(--outline);text-transform:uppercase;letter-spacing:.06em;margin-right:4px}.health-badge.svelte-d3ct2b{display:flex;align-items:center;gap:4px;padding:2px 8px;border-radius:4px;font-family:var(--mono);font-size:10px;font-weight:700}.health-green.svelte-d3ct2b{background:var(--green-bg);color:var(--green);border:1px solid var(--green-border)}.health-blue.svelte-d3ct2b{background:#0040e014;color:var(--primary);border:1px solid rgba(0,64,224,.2)}.health-warn.svelte-d3ct2b{background:#ba1a1a14;color:var(--error);border:1px solid rgba(186,26,26,.25)}.health-error.svelte-d3ct2b{font-family:var(--mono);font-size:10px;color:var(--error);font-weight:700}.dot.svelte-d3ct2b{width:6px;height:6px;border-radius:50%;flex-shrink:0}.dot-green.svelte-d3ct2b{background:var(--green)}.dot-blue.svelte-d3ct2b{background:var(--primary)}.dot-warn.svelte-d3ct2b{background:var(--error)}.dot-pulse.svelte-d3ct2b{animation:svelte-d3ct2b-pulse 1.4s ease-in-out infinite}@keyframes svelte-d3ct2b-pulse{0%,to{opacity:1}50%{opacity:.35}}.filter-bar.svelte-d3ct2b{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:8px 24px;background:var(--surface-low);border-bottom:1px solid var(--outline-var);flex-shrink:0}.filter-left.svelte-d3ct2b,.filter-right.svelte-d3ct2b{display:flex;align-items:center;gap:8px}.chip.svelte-d3ct2b{display:flex;align-items:center;gap:4px;padding:4px 10px;border-radius:8px;font-family:var(--mono);font-size:11px;font-weight:600;cursor:pointer;white-space:nowrap;border:none}.chip-primary.svelte-d3ct2b{background:var(--primary-dim);color:#fff}.chip-close.svelte-d3ct2b{background:transparent;border:none;color:#fffc;cursor:pointer;padding:0;font-size:10px;line-height:1}.chip-outline.svelte-d3ct2b{background:var(--surface);color:var(--on-surface-var);border:1px solid var(--outline-var);transition:border-color .15s}.chip-outline.svelte-d3ct2b:hover{border-color:var(--primary-dim)}.chevron.svelte-d3ct2b{transition:transform .2s}.chevron-open.svelte-d3ct2b{transform:rotate(180deg)}.service-dropdown-wrap.svelte-d3ct2b{position:relative}.dropdown.svelte-d3ct2b{position:absolute;top:calc(100% + 4px);left:0;min-width:180px;background:#fff;border:1px solid var(--outline-var);border-radius:8px;box-shadow:0 8px 24px #0000001f;z-index:100;overflow:hidden;animation:svelte-d3ct2b-dropIn .12s ease}@keyframes svelte-d3ct2b-dropIn{0%{opacity:0;transform:translateY(-4px)}to{opacity:1;transform:translateY(0)}}.dropdown-item.svelte-d3ct2b{display:flex;align-items:center;gap:8px;width:100%;padding:10px 14px;background:transparent;border:none;color:var(--on-surface-var);font-family:var(--sans);font-size:13px;font-weight:500;cursor:pointer;transition:background .12s;text-align:left}.dropdown-item.svelte-d3ct2b:hover{background:var(--surface-low)}.dropdown-item-active.svelte-d3ct2b{color:var(--primary);background:var(--primary-container)}.dropdown-item-active.svelte-d3ct2b:hover{background:var(--primary-container)}.dropdown-badge.svelte-d3ct2b{margin-left:auto;background:var(--error);color:#fff;border-radius:999px;padding:1px 6px;font-size:10px;font-weight:700}.divider-v.svelte-d3ct2b{width:1px;height:28px;background:var(--outline-var);margin:0 4px}.metrics-strip.svelte-d3ct2b{display:flex;align-items:center;gap:24px}.metric-item.svelte-d3ct2b{display:flex;flex-direction:column;align-items:center}.metric-label.svelte-d3ct2b{font-family:var(--mono);font-size:9px;font-weight:700;color:var(--outline);text-transform:uppercase;letter-spacing:.05em;line-height:1}.metric-value.svelte-d3ct2b{font-family:var(--mono);font-size:14px;font-weight:700;color:var(--on-surface);line-height:1.4}.metric-value-warn.svelte-d3ct2b{color:var(--error)}.live-badge.svelte-d3ct2b{display:flex;align-items:center;gap:6px;padding:4px 10px;border:1px solid var(--outline-var);border-radius:8px;background:#fff;font-family:var(--mono);font-size:11px;font-weight:600;color:var(--on-surface);white-space:nowrap}.feed-area.svelte-d3ct2b{flex:1;min-height:0;overflow-y:auto;padding:12px 24px;background:#fff;font-family:var(--mono);font-size:12px}.log-row.svelte-d3ct2b{display:flex;align-items:baseline;gap:12px;padding:3px 8px;border-radius:4px;transition:background .1s;min-height:22px}.log-row.svelte-d3ct2b:hover{background:var(--surface-low)}.log-row-warn.svelte-d3ct2b{background:#ba1a1a0a}.log-row-fail.svelte-d3ct2b{background:#9931000a}.log-time.svelte-d3ct2b{width:80px;flex-shrink:0;color:var(--outline)}.log-label.svelte-d3ct2b{width:56px;flex-shrink:0;font-weight:700}.label-sys.svelte-d3ct2b{color:var(--primary)}.label-ok.svelte-d3ct2b{color:var(--green)}.label-warn.svelte-d3ct2b{color:var(--tertiary)}.label-info.svelte-d3ct2b{color:var(--on-surface-var)}.label-hook.svelte-d3ct2b{color:var(--error)}.label-chck.svelte-d3ct2b{color:var(--outline)}.log-msg.svelte-d3ct2b{flex:1;min-width:0;color:var(--on-surface-var);word-break:break-all;line-height:1.5}.log-msg.svelte-d3ct2b strong:where(.svelte-d3ct2b){color:var(--on-surface);font-weight:600}.copy-btn.svelte-d3ct2b{opacity:0;background:transparent;border:none;color:var(--outline);cursor:pointer;font-size:14px;padding:0 4px;transition:opacity .15s,color .15s;flex-shrink:0}.log-row.svelte-d3ct2b:hover .copy-btn:where(.svelte-d3ct2b){opacity:1}.copy-btn.svelte-d3ct2b:hover{color:var(--primary)}.log-detail.svelte-d3ct2b{display:flex;gap:8px;padding:3px 8px 3px 148px;font-size:11px;border-left:2px solid rgba(153,49,0,.3);margin-left:8px;margin-bottom:2px}.detail-index.svelte-d3ct2b{color:var(--outline);flex-shrink:0;width:24px}.detail-body.svelte-d3ct2b{color:var(--on-surface-var);flex:1;min-width:0;line-height:1.5}.detail-fix.svelte-d3ct2b{color:var(--primary)}.cursor-blink.svelte-d3ct2b{animation:svelte-d3ct2b-blink 1s step-start infinite}@keyframes svelte-d3ct2b-blink{0%,to{opacity:1}50%{opacity:0}}.section-header.svelte-d3ct2b{display:flex;align-items:baseline;gap:12px;padding:8px 8px 10px;border-bottom:1px solid var(--outline-var);margin-bottom:8px}.section-title.svelte-d3ct2b{font-family:var(--sans);font-size:14px;font-weight:700;color:var(--on-surface)}.section-meta.svelte-d3ct2b{font-size:11px;color:var(--outline);font-family:var(--mono)}.rules-toolbar.svelte-d3ct2b{display:flex;gap:8px;padding:8px;margin-bottom:4px}.rules-select.svelte-d3ct2b,.rules-input.svelte-d3ct2b,.rules-textarea.svelte-d3ct2b{padding:6px 10px;background:var(--surface-low);border:1px solid var(--outline-var);border-radius:6px;color:var(--on-surface);font-family:var(--sans);font-size:13px;outline:none;transition:border-color .15s}.rules-select.svelte-d3ct2b:focus,.rules-input.svelte-d3ct2b:focus,.rules-textarea.svelte-d3ct2b:focus{border-color:var(--primary-dim)}.rules-textarea.svelte-d3ct2b{resize:vertical;flex:1;min-width:0}.rule-form-wrap.svelte-d3ct2b{padding:0 8px 8px;border-bottom:1px solid var(--outline-var);margin-bottom:8px}.rule-form.svelte-d3ct2b{display:flex;flex-direction:column;gap:8px}.rule-form-row.svelte-d3ct2b{display:flex;gap:8px;align-items:flex-start}.add-btn.svelte-d3ct2b{padding:8px 16px;background:var(--primary);color:#fff;border:none;border-radius:6px;font-family:var(--mono);font-size:12px;font-weight:700;cursor:pointer;white-space:nowrap;transition:background .15s;align-self:flex-end}.add-btn.svelte-d3ct2b:hover:not(:disabled){background:var(--primary-dim)}.add-btn.svelte-d3ct2b:disabled{opacity:.5;cursor:not-allowed}.rule-list.svelte-d3ct2b{display:flex;flex-direction:column;gap:4px;overflow-y:auto;max-height:400px;padding:0 8px}.rule-row.svelte-d3ct2b{display:flex;align-items:center;gap:10px;padding:8px 10px;border:1px solid var(--outline-var);border-radius:6px;background:var(--surface-low);font-size:12px;min-width:0;transition:background .1s}.rule-row.svelte-d3ct2b:hover{background:var(--surface-mid)}.rule-badge.svelte-d3ct2b{padding:2px 7px;background:var(--primary-container);color:var(--primary);border-radius:4px;font-family:var(--mono);font-size:10px;font-weight:700;text-transform:uppercase;flex-shrink:0}.rule-scope.svelte-d3ct2b{color:var(--outline);font-family:var(--mono);font-size:10px;font-weight:600;flex-shrink:0}.rule-content.svelte-d3ct2b{flex:1;min-width:0;color:var(--on-surface);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.rule-reason.svelte-d3ct2b{color:var(--on-surface-var);font-size:11px;flex-shrink:0;max-width:180px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.del-btn.svelte-d3ct2b{background:transparent;border:none;color:var(--outline);cursor:pointer;font-size:12px;padding:2px 6px;border-radius:4px;flex-shrink:0;transition:background .1s,color .1s}.del-btn.svelte-d3ct2b:hover{background:var(--error-bg);color:var(--error)}.metrics-footer.svelte-d3ct2b{display:flex;align-items:center;justify-content:space-between;height:48px;padding:0 24px;border-top:1px solid var(--outline-var);background:var(--surface);flex-shrink:0}.footer-left.svelte-d3ct2b,.footer-right.svelte-d3ct2b{display:flex;align-items:center;gap:24px}.footer-metric.svelte-d3ct2b{display:flex;align-items:center;gap:6px}.footer-label.svelte-d3ct2b{font-family:var(--mono);font-size:10px;font-weight:700;color:var(--outline);text-transform:uppercase;letter-spacing:.04em}.footer-val.svelte-d3ct2b{font-family:var(--mono);font-size:14px;font-weight:700;color:var(--on-surface)}.footer-val-error.svelte-d3ct2b{color:var(--error)}.footer-unit.svelte-d3ct2b{font-family:var(--mono);font-size:9px;color:var(--outline);text-transform:uppercase}.storage-bar-wrap.svelte-d3ct2b{display:flex;align-items:center;gap:8px}.storage-bar.svelte-d3ct2b{width:96px;height:6px;background:var(--surface-mid);border-radius:999px;overflow:hidden}.storage-fill.svelte-d3ct2b{height:100%;background:var(--primary-dim);border-radius:999px;transition:width .6s ease}.cli-btn.svelte-d3ct2b{display:flex;align-items:center;gap:6px;padding:5px 12px;background:var(--surface-high);border:none;border-radius:4px;color:var(--on-surface);font-family:var(--mono);font-size:11px;font-weight:700;cursor:pointer;transition:background .15s}.cli-btn.svelte-d3ct2b:hover{background:var(--outline-var)}.dark.svelte-d3ct2b{--primary: #b8c3ff;--primary-dim: #4d6dff;--primary-container: #1a2340;--on-primary: #ffffff;--surface: #111318;--surface-low: #0c0e12;--surface-mid: #1e2024;--surface-high: #282a2e;--surface-highest: #37393e;--on-surface: #e2e2e8;--on-surface-var: #c4c5d9;--outline: #747688;--outline-var: #3a3c4a;--error: #ffb4ab;--error-bg: rgba(147,0,10,.22);--tertiary: #ffb59b;--green: #03f59b;--green-bg: rgba(3,245,155,.1);--green-border: rgba(3,245,155,.28)}.dark.svelte-d3ct2b body{background:var(--surface)}.dark.svelte-d3ct2b .topbar:where(.svelte-d3ct2b){background:#1a1c20;border-bottom-color:var(--outline-var)}.dark.svelte-d3ct2b .sidebar:where(.svelte-d3ct2b){background:#0c0e12;border-right-color:var(--outline-var)}.dark.svelte-d3ct2b .health-bar:where(.svelte-d3ct2b){background:#1a1c20;border-bottom-color:var(--outline-var)}.dark.svelte-d3ct2b .filter-bar:where(.svelte-d3ct2b){background:#111318;border-bottom-color:var(--outline-var)}.dark.svelte-d3ct2b .feed-area:where(.svelte-d3ct2b){background:#0c0e12}.dark.svelte-d3ct2b .metrics-footer:where(.svelte-d3ct2b){background:#111318;border-top-color:var(--outline-var)}.dark.svelte-d3ct2b .search-input:where(.svelte-d3ct2b){background:#1e2024;border-color:var(--outline-var);color:var(--on-surface)}.dark.svelte-d3ct2b .dropdown:where(.svelte-d3ct2b){background:#1e2024;border-color:var(--outline-var);box-shadow:0 8px 24px #00000073}.dark.svelte-d3ct2b .dropdown-item:where(.svelte-d3ct2b):hover{background:#282a2e}.dark.svelte-d3ct2b .dropdown-item-active:where(.svelte-d3ct2b){background:var(--primary-container);color:var(--primary)}.dark.svelte-d3ct2b .chip-outline:where(.svelte-d3ct2b){background:#1e2024}.dark.svelte-d3ct2b .live-badge:where(.svelte-d3ct2b){background:#1e2024}.dark.svelte-d3ct2b .rule-row:where(.svelte-d3ct2b){background:#1e2024;border-color:var(--outline-var)}.dark.svelte-d3ct2b .rule-row:where(.svelte-d3ct2b):hover{background:#282a2e}.dark.svelte-d3ct2b .rules-select:where(.svelte-d3ct2b),.dark.svelte-d3ct2b .rules-input:where(.svelte-d3ct2b),.dark.svelte-d3ct2b .rules-textarea:where(.svelte-d3ct2b){background:#1e2024;border-color:var(--outline-var);color:var(--on-surface)}.dark.svelte-d3ct2b .log-row:where(.svelte-d3ct2b):hover{background:#1e2024}.dark.svelte-d3ct2b .log-row-warn:where(.svelte-d3ct2b){background:#ffb4ab0d}.dark.svelte-d3ct2b .log-row-fail:where(.svelte-d3ct2b){background:#ffba200a}.dark.svelte-d3ct2b .section-header:where(.svelte-d3ct2b){border-bottom-color:var(--outline-var)}.dark.svelte-d3ct2b .storage-bar:where(.svelte-d3ct2b){background:#282a2e}@media (max-width: 768px){.sidebar.svelte-d3ct2b,.topbar-nav.svelte-d3ct2b,.metrics-strip.svelte-d3ct2b{display:none}.filter-bar.svelte-d3ct2b,.feed-area.svelte-d3ct2b{padding:8px 12px}.metrics-footer.svelte-d3ct2b{padding:0 12px;gap:12px}.footer-metric.svelte-d3ct2b:nth-child(n+2){display:none}}
|
|
@@ -7,8 +7,8 @@
|
|
|
7
7
|
<link rel="preconnect" href="https://fonts.googleapis.com">
|
|
8
8
|
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
|
9
9
|
<link href="https://fonts.googleapis.com/css2?family=Hanken+Grotesk:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500;700&display=swap" rel="stylesheet">
|
|
10
|
-
<script type="module" crossorigin src="/assets/index-
|
|
11
|
-
<link rel="stylesheet" crossorigin href="/assets/index-
|
|
10
|
+
<script type="module" crossorigin src="/assets/index-BRqvIBnm.js"></script>
|
|
11
|
+
<link rel="stylesheet" crossorigin href="/assets/index-DXXHB1Ik.css">
|
|
12
12
|
</head>
|
|
13
13
|
<body>
|
|
14
14
|
<div id="app"></div>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@shahmilsaari/memory-core",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.20",
|
|
4
4
|
"description": "Universal AI memory core — generate AI context files from architecture profiles with RAG support",
|
|
5
5
|
"homepage": "https://memory-core.shahmilsaari.my/",
|
|
6
6
|
"type": "module",
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
var gi=Object.defineProperty;var nl=e=>{throw TypeError(e)};var mi=(e,t,s)=>t in e?gi(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s;var We=(e,t,s)=>mi(e,typeof t!="symbol"?t+"":t,s),Ln=(e,t,s)=>t.has(e)||nl("Cannot "+s);var o=(e,t,s)=>(Ln(e,t,"read from private field"),s?s.call(e):t.get(e)),A=(e,t,s)=>t.has(e)?nl("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,s),N=(e,t,s,n)=>(Ln(e,t,"write to private field"),n?n.call(e,s):t.set(e,s),s),U=(e,t,s)=>(Ln(e,t,"access private method"),s);(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const r of document.querySelectorAll('link[rel="modulepreload"]'))n(r);new MutationObserver(r=>{for(const a of r)if(a.type==="childList")for(const c of a.addedNodes)c.tagName==="LINK"&&c.rel==="modulepreload"&&n(c)}).observe(document,{childList:!0,subtree:!0});function s(r){const a={};return r.integrity&&(a.integrity=r.integrity),r.referrerPolicy&&(a.referrerPolicy=r.referrerPolicy),r.crossOrigin==="use-credentials"?a.credentials="include":r.crossOrigin==="anonymous"?a.credentials="omit":a.credentials="same-origin",a}function n(r){if(r.ep)return;r.ep=!0;const a=s(r);fetch(r.href,a)}})();const wi=!1;var tr=Array.isArray,yi=Array.prototype.indexOf,fs=Array.prototype.includes,wn=Array.from,Ei=Object.defineProperty,As=Object.getOwnPropertyDescriptor,wl=Object.getOwnPropertyDescriptors,ki=Object.prototype,xi=Array.prototype,sr=Object.getPrototypeOf,rl=Object.isExtensible;const Si=()=>{};function Mi(e){return e()}function Bn(e){for(var t=0;t<e.length;t++)e[t]()}function yl(){var e,t,s=new Promise((n,r)=>{e=n,t=r});return{promise:s,resolve:e,reject:t}}const ve=2,us=4,Hs=8,El=1<<24,st=16,Ye=32,Mt=64,Vn=128,Fe=512,Q=1024,ce=2048,Ge=4096,_e=8192,Pe=16384,Qt=32768,ll=1<<25,vs=65536,Hn=1<<17,Ci=1<<18,_s=1<<19,kl=1<<20,tt=1<<25,Kt=65536,hn=1<<21,Ds=1<<22,xt=1<<23,Wt=Symbol("$state"),ot=new class extends Error{constructor(){super(...arguments);We(this,"name","StaleReactionError");We(this,"message","The reaction that called `getAbortSignal()` was re-run or destroyed")}};function xl(e){throw new Error("https://svelte.dev/e/lifecycle_outside_component")}function Ti(){throw new Error("https://svelte.dev/e/async_derived_orphan")}function Ai(e,t,s){throw new Error("https://svelte.dev/e/each_key_duplicate")}function Oi(e){throw new Error("https://svelte.dev/e/effect_in_teardown")}function Ni(){throw new Error("https://svelte.dev/e/effect_in_unowned_derived")}function Ii(e){throw new Error("https://svelte.dev/e/effect_orphan")}function Di(){throw new Error("https://svelte.dev/e/effect_update_depth_exceeded")}function Li(){throw new Error("https://svelte.dev/e/state_descriptors_fixed")}function Ri(){throw new Error("https://svelte.dev/e/state_prototype_fixed")}function Fi(){throw new Error("https://svelte.dev/e/state_unsafe_mutation")}function Pi(){throw new Error("https://svelte.dev/e/svelte_boundary_reset_onerror")}const ji=1,$i=2,Sl=4,Bi=8,Vi=16,Hi=1,Wi=2,re=Symbol(),Ml="http://www.w3.org/1999/xhtml";function qi(){console.warn("https://svelte.dev/e/derived_inert")}function Ui(){console.warn("https://svelte.dev/e/select_multiple_invalid_value")}function zi(){console.warn("https://svelte.dev/e/svelte_boundary_reset_noop")}function Cl(e){return e===this.v}function Ki(e,t){return e!=e?t==t:e!==t||e!==null&&typeof e=="object"||typeof e=="function"}function Tl(e){return!Ki(e,this.v)}let Ws=!1,Yi=!1;function Gi(){Ws=!0}let z=null;function ds(e){z=e}function Al(e,t=!1,s){z={p:z,i:!1,c:null,e:null,s:e,x:null,r:I,l:Ws&&!t?{s:null,u:null,$:[]}:null}}function Ol(e){var t=z,s=t.e;if(s!==null){t.e=null;for(var n of s)Ql(n)}return t.i=!0,z=t.p,{}}function qs(){return!Ws||z!==null&&z.l===null}let Ft=[];function Nl(){var e=Ft;Ft=[],Bn(e)}function St(e){if(Ft.length===0&&!Os){var t=Ft;queueMicrotask(()=>{t===Ft&&Nl()})}Ft.push(e)}function Ji(){for(;Ft.length>0;)Nl()}function Il(e){var t=I;if(t===null)return L.f|=xt,e;if(!(t.f&Qt)&&!(t.f&us))throw e;kt(e,t)}function kt(e,t){for(;t!==null;){if(t.f&Vn){if(!(t.f&Qt))throw e;try{t.b.error(e);return}catch(s){e=s}}t=t.parent}throw e}const Qi=-7169;function Y(e,t){e.f=e.f&Qi|t}function nr(e){e.f&Fe||e.deps===null?Y(e,Q):Y(e,Ge)}function Dl(e){if(e!==null)for(const t of e)!(t.f&ve)||!(t.f&Kt)||(t.f^=Kt,Dl(t.deps))}function Ll(e,t,s){e.f&ce?t.add(e):e.f&Ge&&s.add(e),Dl(e.deps),Y(e,Q)}const Rt=new Set;let S=null,oe=null,Wn=null,Os=!1,Rn=!1,rs=null,on=null;var al=0;let Xi=1;var ls,as,jt,ct,Xe,Fs,Se,Ps,yt,ft,Ze,is,os,$t,X,cn,Rl,fn,qn,un,Zi;const bn=class bn{constructor(){A(this,X);We(this,"id",Xi++);We(this,"current",new Map);We(this,"previous",new Map);A(this,ls,new Set);A(this,as,new Set);A(this,jt,new Set);A(this,ct,new Map);A(this,Xe,new Map);A(this,Fs,null);A(this,Se,[]);A(this,Ps,[]);A(this,yt,new Set);A(this,ft,new Set);A(this,Ze,new Map);A(this,is,new Set);We(this,"is_fork",!1);A(this,os,!1);A(this,$t,new Set)}skip_effect(t){o(this,Ze).has(t)||o(this,Ze).set(t,{d:[],m:[]}),o(this,is).delete(t)}unskip_effect(t,s=n=>this.schedule(n)){var n=o(this,Ze).get(t);if(n){o(this,Ze).delete(t);for(var r of n.d)Y(r,ce),s(r);for(r of n.m)Y(r,Ge),s(r)}o(this,is).add(t)}capture(t,s,n=!1){t.v!==re&&!this.previous.has(t)&&this.previous.set(t,t.v),t.f&xt||(this.current.set(t,[s,n]),oe==null||oe.set(t,s)),this.is_fork||(t.v=s)}activate(){S=this}deactivate(){S=null,oe=null}flush(){try{Rn=!0,S=this,U(this,X,fn).call(this)}finally{al=0,Wn=null,rs=null,on=null,Rn=!1,S=null,oe=null,qt.clear()}}discard(){for(const t of o(this,as))t(this);o(this,as).clear(),o(this,jt).clear(),Rt.delete(this)}register_created_effect(t){o(this,Ps).push(t)}increment(t,s){let n=o(this,ct).get(s)??0;if(o(this,ct).set(s,n+1),t){let r=o(this,Xe).get(s)??0;o(this,Xe).set(s,r+1)}}decrement(t,s,n){let r=o(this,ct).get(s)??0;if(r===1?o(this,ct).delete(s):o(this,ct).set(s,r-1),t){let a=o(this,Xe).get(s)??0;a===1?o(this,Xe).delete(s):o(this,Xe).set(s,a-1)}o(this,os)||n||(N(this,os,!0),St(()=>{N(this,os,!1),this.flush()}))}transfer_effects(t,s){for(const n of t)o(this,yt).add(n);for(const n of s)o(this,ft).add(n);t.clear(),s.clear()}oncommit(t){o(this,ls).add(t)}ondiscard(t){o(this,as).add(t)}on_fork_commit(t){o(this,jt).add(t)}run_fork_commit_callbacks(){for(const t of o(this,jt))t(this);o(this,jt).clear()}settled(){return(o(this,Fs)??N(this,Fs,yl())).promise}static ensure(){if(S===null){const t=S=new bn;Rn||(Rt.add(S),Os||St(()=>{S===t&&t.flush()}))}return S}apply(){{oe=null;return}}schedule(t){var r;if(Wn=t,(r=t.b)!=null&&r.is_pending&&t.f&(us|Hs|El)&&!(t.f&Qt)){t.b.defer_effect(t);return}for(var s=t;s.parent!==null;){s=s.parent;var n=s.f;if(rs!==null&&s===I&&(L===null||!(L.f&ve)))return;if(n&(Mt|Ye)){if(!(n&Q))return;s.f^=Q}}o(this,Se).push(s)}};ls=new WeakMap,as=new WeakMap,jt=new WeakMap,ct=new WeakMap,Xe=new WeakMap,Fs=new WeakMap,Se=new WeakMap,Ps=new WeakMap,yt=new WeakMap,ft=new WeakMap,Ze=new WeakMap,is=new WeakMap,os=new WeakMap,$t=new WeakMap,X=new WeakSet,cn=function(){return this.is_fork||o(this,Xe).size>0},Rl=function(){for(const n of o(this,$t))for(const r of o(n,Xe).keys()){for(var t=!1,s=r;s.parent!==null;){if(o(this,Ze).has(s)){t=!0;break}s=s.parent}if(!t)return!0}return!1},fn=function(){var u,f;if(al++>1e3&&(Rt.delete(this),to()),!U(this,X,cn).call(this)){for(const v of o(this,yt))o(this,ft).delete(v),Y(v,ce),this.schedule(v);for(const v of o(this,ft))Y(v,Ge),this.schedule(v)}const t=o(this,Se);N(this,Se,[]),this.apply();var s=rs=[],n=[],r=on=[];for(const v of t)try{U(this,X,qn).call(this,v,s,n)}catch(p){throw jl(v),p}if(S=null,r.length>0){var a=bn.ensure();for(const v of r)a.schedule(v)}if(rs=null,on=null,U(this,X,cn).call(this)||U(this,X,Rl).call(this)){U(this,X,un).call(this,n),U(this,X,un).call(this,s);for(const[v,p]of o(this,Ze))Pl(v,p)}else{o(this,ct).size===0&&Rt.delete(this),o(this,yt).clear(),o(this,ft).clear();for(const v of o(this,ls))v(this);o(this,ls).clear(),il(n),il(s),(u=o(this,Fs))==null||u.resolve()}var c=S;if(o(this,Se).length>0){const v=c??(c=this);o(v,Se).push(...o(this,Se).filter(p=>!o(v,Se).includes(p)))}c!==null&&(Rt.add(c),U(f=c,X,fn).call(f))},qn=function(t,s,n){t.f^=Q;for(var r=t.first;r!==null;){var a=r.f,c=(a&(Ye|Mt))!==0,u=c&&(a&Q)!==0,f=u||(a&_e)!==0||o(this,Ze).has(r);if(!f&&r.fn!==null){c?r.f^=Q:a&us?s.push(r):bs(r)&&(a&st&&o(this,ft).add(r),Jt(r));var v=r.first;if(v!==null){r=v;continue}}for(;r!==null;){var p=r.next;if(p!==null){r=p;break}r=r.parent}}},un=function(t){for(var s=0;s<t.length;s+=1)Ll(t[s],o(this,yt),o(this,ft))},Zi=function(){var p,E,b;for(const m of Rt){var t=m.id<this.id,s=[];for(const[g,[C,d]]of this.current){if(m.current.has(g)){var n=m.current.get(g)[0];if(t&&C!==n)m.current.set(g,[C,d]);else continue}s.push(g)}var r=[...m.current.keys()].filter(g=>!this.current.has(g));if(r.length===0)t&&m.discard();else if(s.length>0){if(t)for(const g of o(this,is))m.unskip_effect(g,C=>{var d;C.f&(st|Ds)?m.schedule(C):U(d=m,X,un).call(d,[C])});m.activate();var a=new Set,c=new Map;for(var u of s)Fl(u,r,a,c);c=new Map;var f=[...m.current.keys()].filter(g=>this.current.has(g)?this.current.get(g)[0]!==g:!0);for(const g of o(this,Ps))!(g.f&(Pe|_e|Hn))&&rr(g,f,c)&&(g.f&(Ds|st)?(Y(g,ce),m.schedule(g)):o(m,yt).add(g));if(o(m,Se).length>0){m.apply();for(var v of o(m,Se))U(p=m,X,qn).call(p,v,[],[]);N(m,Se,[])}m.deactivate()}}for(const m of Rt)o(m,$t).has(this)&&(o(m,$t).delete(this),o(m,$t).size===0&&!U(E=m,X,cn).call(E)&&(m.activate(),U(b=m,X,fn).call(b)))};let Yt=bn;function eo(e){var t=Os;Os=!0;try{for(var s;;){if(Ji(),S===null)return s;S.flush()}}finally{Os=t}}function to(){try{Di()}catch(e){kt(e,Wn)}}let Ue=null;function il(e){var t=e.length;if(t!==0){for(var s=0;s<t;){var n=e[s++];if(!(n.f&(Pe|_e))&&bs(n)&&(Ue=new Set,Jt(n),n.deps===null&&n.first===null&&n.nodes===null&&n.teardown===null&&n.ac===null&&Zl(n),(Ue==null?void 0:Ue.size)>0)){qt.clear();for(const r of Ue){if(r.f&(Pe|_e))continue;const a=[r];let c=r.parent;for(;c!==null;)Ue.has(c)&&(Ue.delete(c),a.push(c)),c=c.parent;for(let u=a.length-1;u>=0;u--){const f=a[u];f.f&(Pe|_e)||Jt(f)}}Ue.clear()}}Ue=null}}function Fl(e,t,s,n){if(!s.has(e)&&(s.add(e),e.reactions!==null))for(const r of e.reactions){const a=r.f;a&ve?Fl(r,t,s,n):a&(Ds|st)&&!(a&ce)&&rr(r,t,n)&&(Y(r,ce),lr(r))}}function rr(e,t,s){const n=s.get(e);if(n!==void 0)return n;if(e.deps!==null)for(const r of e.deps){if(fs.call(t,r))return!0;if(r.f&ve&&rr(r,t,s))return s.set(r,!0),!0}return s.set(e,!1),!1}function lr(e){S.schedule(e)}function Pl(e,t){if(!(e.f&Ye&&e.f&Q)){e.f&ce?t.d.push(e):e.f&Ge&&t.m.push(e),Y(e,Q);for(var s=e.first;s!==null;)Pl(s,t),s=s.next}}function jl(e){Y(e,Q);for(var t=e.first;t!==null;)jl(t),t=t.next}function so(e){let t=0,s=Gt(0),n;return()=>{or()&&(l(s),En(()=>(t===0&&(n=y(()=>e(()=>Ns(s)))),t+=1,()=>{St(()=>{t-=1,t===0&&(n==null||n(),n=void 0,Ns(s))})})))}}var no=vs|_s;function ro(e,t,s,n){new lo(e,t,s,n)}var Ie,er,De,Bt,me,Le,he,Me,ut,Vt,Et,cs,js,$s,vt,gn,G,ao,io,oo,Un,vn,dn,zn,Kn;class lo{constructor(t,s,n,r){A(this,G);We(this,"parent");We(this,"is_pending",!1);We(this,"transform_error");A(this,Ie);A(this,er,null);A(this,De);A(this,Bt);A(this,me);A(this,Le,null);A(this,he,null);A(this,Me,null);A(this,ut,null);A(this,Vt,0);A(this,Et,0);A(this,cs,!1);A(this,js,new Set);A(this,$s,new Set);A(this,vt,null);A(this,gn,so(()=>(N(this,vt,Gt(o(this,Vt))),()=>{N(this,vt,null)})));var a;N(this,Ie,t),N(this,De,s),N(this,Bt,c=>{var u=I;u.b=this,u.f|=Vn,n(c)}),this.parent=I.b,this.transform_error=r??((a=this.parent)==null?void 0:a.transform_error)??(c=>c),N(this,me,fr(()=>{U(this,G,Un).call(this)},no))}defer_effect(t){Ll(t,o(this,js),o(this,$s))}is_rendered(){return!this.is_pending&&(!this.parent||this.parent.is_rendered())}has_pending_snippet(){return!!o(this,De).pending}update_pending_count(t,s){U(this,G,zn).call(this,t,s),N(this,Vt,o(this,Vt)+t),!(!o(this,vt)||o(this,cs))&&(N(this,cs,!0),St(()=>{N(this,cs,!1),o(this,vt)&&ps(o(this,vt),o(this,Vt))}))}get_effect_pending(){return o(this,gn).call(this),l(o(this,vt))}error(t){if(!o(this,De).onerror&&!o(this,De).failed)throw t;S!=null&&S.is_fork?(o(this,Le)&&S.skip_effect(o(this,Le)),o(this,he)&&S.skip_effect(o(this,he)),o(this,Me)&&S.skip_effect(o(this,Me)),S.on_fork_commit(()=>{U(this,G,Kn).call(this,t)})):U(this,G,Kn).call(this,t)}}Ie=new WeakMap,er=new WeakMap,De=new WeakMap,Bt=new WeakMap,me=new WeakMap,Le=new WeakMap,he=new WeakMap,Me=new WeakMap,ut=new WeakMap,Vt=new WeakMap,Et=new WeakMap,cs=new WeakMap,js=new WeakMap,$s=new WeakMap,vt=new WeakMap,gn=new WeakMap,G=new WeakSet,ao=function(){try{N(this,Le,Re(()=>o(this,Bt).call(this,o(this,Ie))))}catch(t){this.error(t)}},io=function(t){const s=o(this,De).failed;s&&N(this,Me,Re(()=>{s(o(this,Ie),()=>t,()=>()=>{})}))},oo=function(){const t=o(this,De).pending;t&&(this.is_pending=!0,N(this,he,Re(()=>t(o(this,Ie)))),St(()=>{var s=N(this,ut,document.createDocumentFragment()),n=dt();s.append(n),N(this,Le,U(this,G,dn).call(this,()=>Re(()=>o(this,Bt).call(this,n)))),o(this,Et)===0&&(o(this,Ie).before(s),N(this,ut,null),Ut(o(this,he),()=>{N(this,he,null)}),U(this,G,vn).call(this,S))}))},Un=function(){try{if(this.is_pending=this.has_pending_snippet(),N(this,Et,0),N(this,Vt,0),N(this,Le,Re(()=>{o(this,Bt).call(this,o(this,Ie))})),o(this,Et)>0){var t=N(this,ut,document.createDocumentFragment());dr(o(this,Le),t);const s=o(this,De).pending;N(this,he,Re(()=>s(o(this,Ie))))}else U(this,G,vn).call(this,S)}catch(s){this.error(s)}},vn=function(t){this.is_pending=!1,t.transfer_effects(o(this,js),o(this,$s))},dn=function(t){var s=I,n=L,r=z;Be(o(this,me)),$e(o(this,me)),ds(o(this,me).ctx);try{return Yt.ensure(),t()}catch(a){return Il(a),null}finally{Be(s),$e(n),ds(r)}},zn=function(t,s){var n;if(!this.has_pending_snippet()){this.parent&&U(n=this.parent,G,zn).call(n,t,s);return}N(this,Et,o(this,Et)+t),o(this,Et)===0&&(U(this,G,vn).call(this,s),o(this,he)&&Ut(o(this,he),()=>{N(this,he,null)}),o(this,ut)&&(o(this,Ie).before(o(this,ut)),N(this,ut,null)))},Kn=function(t){o(this,Le)&&(ye(o(this,Le)),N(this,Le,null)),o(this,he)&&(ye(o(this,he)),N(this,he,null)),o(this,Me)&&(ye(o(this,Me)),N(this,Me,null));var s=o(this,De).onerror;let n=o(this,De).failed;var r=!1,a=!1;const c=()=>{if(r){zi();return}r=!0,a&&Pi(),o(this,Me)!==null&&Ut(o(this,Me),()=>{N(this,Me,null)}),U(this,G,dn).call(this,()=>{U(this,G,Un).call(this)})},u=f=>{try{a=!0,s==null||s(f,c),a=!1}catch(v){kt(v,o(this,me)&&o(this,me).parent)}n&&N(this,Me,U(this,G,dn).call(this,()=>{try{return Re(()=>{var v=I;v.b=this,v.f|=Vn,n(o(this,Ie),()=>f,()=>c)})}catch(v){return kt(v,o(this,me).parent),null}}))};St(()=>{var f;try{f=this.transform_error(t)}catch(v){kt(v,o(this,me)&&o(this,me).parent);return}f!==null&&typeof f=="object"&&typeof f.then=="function"?f.then(u,v=>kt(v,o(this,me)&&o(this,me).parent)):u(f)})};function co(e,t,s,n){const r=qs()?ar:Bl;var a=e.filter(b=>!b.settled);if(s.length===0&&a.length===0){n(t.map(r));return}var c=I,u=fo(),f=a.length===1?a[0].promise:a.length>1?Promise.all(a.map(b=>b.promise)):null;function v(b){u();try{n(b)}catch(m){c.f&Pe||kt(m,c)}_n()}if(s.length===0){f.then(()=>v(t.map(r)));return}var p=$l();function E(){Promise.all(s.map(b=>uo(b))).then(b=>v([...t.map(r),...b])).catch(b=>kt(b,c)).finally(()=>p())}f?f.then(()=>{u(),E(),_n()}):E()}function fo(){var e=I,t=L,s=z,n=S;return function(a=!0){Be(e),$e(t),ds(s),a&&!(e.f&Pe)&&(n==null||n.activate(),n==null||n.apply())}}function _n(e=!0){Be(null),$e(null),ds(null),e&&(S==null||S.deactivate())}function $l(){var e=I,t=e.b,s=S,n=t.is_rendered();return t.update_pending_count(1,s),s.increment(n,e),(r=!1)=>{t.update_pending_count(-1,s),s.decrement(n,e,r)}}function ar(e){var t=ve|ce;return I!==null&&(I.f|=_s),{ctx:z,deps:null,effects:null,equals:Cl,f:t,fn:e,reactions:null,rv:0,v:re,wv:0,parent:I,ac:null}}function uo(e,t,s){let n=I;n===null&&Ti();var r=void 0,a=Gt(re),c=!L,u=new Map;return Mo(()=>{var m;var f=I,v=yl();r=v.promise;try{Promise.resolve(e()).then(v.resolve,v.reject).finally(_n)}catch(g){v.reject(g),_n()}var p=S;if(c){if(f.f&Qt)var E=$l();if(n.b.is_rendered())(m=u.get(p))==null||m.reject(ot),u.delete(p);else{for(const g of u.values())g.reject(ot);u.clear()}u.set(p,v)}const b=(g,C=void 0)=>{if(E){var d=C===ot;E(d)}if(!(C===ot||f.f&Pe)){if(p.activate(),C)a.f|=xt,ps(a,C);else{a.f&xt&&(a.f^=xt),ps(a,g);for(const[M,H]of u){if(u.delete(M),M===p)break;H.reject(ot)}}p.deactivate()}};v.promise.then(b,g=>b(null,g||"unknown"))}),cr(()=>{for(const f of u.values())f.reject(ot)}),new Promise(f=>{function v(p){function E(){p===r?f(a):v(r)}p.then(E,E)}v(r)})}function Bl(e){const t=ar(e);return t.equals=Tl,t}function vo(e){var t=e.effects;if(t!==null){e.effects=null;for(var s=0;s<t.length;s+=1)ye(t[s])}}function ir(e){var t,s=I,n=e.parent;if(!Ct&&n!==null&&n.f&(Pe|_e))return qi(),e.v;Be(n);try{e.f&=~Kt,vo(e),t=la(e)}finally{Be(s)}return t}function Vl(e){var t=ir(e);if(!e.equals(t)&&(e.wv=na(),(!(S!=null&&S.is_fork)||e.deps===null)&&(S!==null?S.capture(e,t,!0):e.v=t,e.deps===null))){Y(e,Q);return}Ct||(oe!==null?(or()||S!=null&&S.is_fork)&&oe.set(e,t):nr(e))}function po(e){var t,s;if(e.effects!==null)for(const n of e.effects)(n.teardown||n.ac)&&((t=n.teardown)==null||t.call(n),(s=n.ac)==null||s.abort(ot),n.teardown=Si,n.ac=null,Ls(n,0),ur(n))}function Hl(e){if(e.effects!==null)for(const t of e.effects)t.teardown&&Jt(t)}let Yn=new Set;const qt=new Map;let Wl=!1;function Gt(e,t){var s={f:0,v:e,reactions:null,equals:Cl,rv:0,wv:0};return s}function gt(e,t){const s=Gt(e);return Ao(s),s}function j(e,t=!1,s=!0){var r;const n=Gt(e);return t||(n.equals=Tl),Ws&&s&&z!==null&&z.l!==null&&((r=z.l).s??(r.s=[])).push(n),n}function xs(e,t){return k(e,y(()=>l(e))),t}function k(e,t,s=!1){L!==null&&(!Ke||L.f&Hn)&&qs()&&L.f&(ve|st|Ds|Hn)&&(je===null||!fs.call(je,e))&&Fi();let n=s?Cs(t):t;return ps(e,n,on)}function ps(e,t,s=null){if(!e.equals(t)){qt.set(e,Ct?t:e.v);var n=Yt.ensure();if(n.capture(e,t),e.f&ve){const r=e;e.f&ce&&ir(r),oe===null&&nr(r)}e.wv=na(),ql(e,ce,s),qs()&&I!==null&&I.f&Q&&!(I.f&(Ye|Mt))&&(Ne===null?Oo([e]):Ne.push(e)),!n.is_fork&&Yn.size>0&&!Wl&&ho()}return t}function ho(){Wl=!1;for(const e of Yn)e.f&Q&&Y(e,Ge),bs(e)&&Jt(e);Yn.clear()}function Ns(e){k(e,e.v+1)}function ql(e,t,s){var n=e.reactions;if(n!==null)for(var r=qs(),a=n.length,c=0;c<a;c++){var u=n[c],f=u.f;if(!(!r&&u===I)){var v=(f&ce)===0;if(v&&Y(u,t),f&ve){var p=u;oe==null||oe.delete(p),f&Kt||(f&Fe&&(I===null||!(I.f&hn))&&(u.f|=Kt),ql(p,Ge,s))}else if(v){var E=u;f&st&&Ue!==null&&Ue.add(E),s!==null?s.push(E):lr(E)}}}}function Cs(e){if(typeof e!="object"||e===null||Wt in e)return e;const t=sr(e);if(t!==ki&&t!==xi)return e;var s=new Map,n=tr(e),r=gt(0),a=zt,c=u=>{if(zt===a)return u();var f=L,v=zt;$e(null),ul(a);var p=u();return $e(f),ul(v),p};return n&&s.set("length",gt(e.length)),new Proxy(e,{defineProperty(u,f,v){(!("value"in v)||v.configurable===!1||v.enumerable===!1||v.writable===!1)&&Li();var p=s.get(f);return p===void 0?c(()=>{var E=gt(v.value);return s.set(f,E),E}):k(p,v.value,!0),!0},deleteProperty(u,f){var v=s.get(f);if(v===void 0){if(f in u){const p=c(()=>gt(re));s.set(f,p),Ns(r)}}else k(v,re),Ns(r);return!0},get(u,f,v){var m;if(f===Wt)return e;var p=s.get(f),E=f in u;if(p===void 0&&(!E||(m=As(u,f))!=null&&m.writable)&&(p=c(()=>{var g=Cs(E?u[f]:re),C=gt(g);return C}),s.set(f,p)),p!==void 0){var b=l(p);return b===re?void 0:b}return Reflect.get(u,f,v)},getOwnPropertyDescriptor(u,f){var v=Reflect.getOwnPropertyDescriptor(u,f);if(v&&"value"in v){var p=s.get(f);p&&(v.value=l(p))}else if(v===void 0){var E=s.get(f),b=E==null?void 0:E.v;if(E!==void 0&&b!==re)return{enumerable:!0,configurable:!0,value:b,writable:!0}}return v},has(u,f){var b;if(f===Wt)return!0;var v=s.get(f),p=v!==void 0&&v.v!==re||Reflect.has(u,f);if(v!==void 0||I!==null&&(!p||(b=As(u,f))!=null&&b.writable)){v===void 0&&(v=c(()=>{var m=p?Cs(u[f]):re,g=gt(m);return g}),s.set(f,v));var E=l(v);if(E===re)return!1}return p},set(u,f,v,p){var P;var E=s.get(f),b=f in u;if(n&&f==="length")for(var m=v;m<E.v;m+=1){var g=s.get(m+"");g!==void 0?k(g,re):m in u&&(g=c(()=>gt(re)),s.set(m+"",g))}if(E===void 0)(!b||(P=As(u,f))!=null&&P.writable)&&(E=c(()=>gt(void 0)),k(E,Cs(v)),s.set(f,E));else{b=E.v!==re;var C=c(()=>Cs(v));k(E,C)}var d=Reflect.getOwnPropertyDescriptor(u,f);if(d!=null&&d.set&&d.set.call(p,v),!b){if(n&&typeof f=="string"){var M=s.get("length"),H=Number(f);Number.isInteger(H)&&H>=M.v&&k(M,H+1)}Ns(r)}return!0},ownKeys(u){l(r);var f=Reflect.ownKeys(u).filter(E=>{var b=s.get(E);return b===void 0||b.v!==re});for(var[v,p]of s)p.v!==re&&!(v in u)&&f.push(v);return f},setPrototypeOf(){Ri()}})}function ol(e){try{if(e!==null&&typeof e=="object"&&Wt in e)return e[Wt]}catch{}return e}function _o(e,t){return Object.is(ol(e),ol(t))}var Gn,Ul,zl,Kl;function bo(){if(Gn===void 0){Gn=window,Ul=/Firefox/.test(navigator.userAgent);var e=Element.prototype,t=Node.prototype,s=Text.prototype;zl=As(t,"firstChild").get,Kl=As(t,"nextSibling").get,rl(e)&&(e.__click=void 0,e.__className=void 0,e.__attributes=null,e.__style=void 0,e.__e=void 0),rl(s)&&(s.__t=void 0)}}function dt(e=""){return document.createTextNode(e)}function hs(e){return zl.call(e)}function Us(e){return Kl.call(e)}function h(e,t){return hs(e)}function qe(e,t=!1){{var s=hs(e);return s instanceof Comment&&s.data===""?Us(s):s}}function _(e,t=1,s=!1){let n=e;for(;t--;)n=Us(n);return n}function go(e){e.textContent=""}function Yl(){return!1}function mo(e,t,s){return document.createElementNS(Ml,e,void 0)}let cl=!1;function wo(){cl||(cl=!0,document.addEventListener("reset",e=>{Promise.resolve().then(()=>{var t;if(!e.defaultPrevented)for(const s of e.target.elements)(t=s.__on_r)==null||t.call(s)})},{capture:!0}))}function yn(e){var t=L,s=I;$e(null),Be(null);try{return e()}finally{$e(t),Be(s)}}function Gl(e,t,s,n=s){e.addEventListener(t,()=>yn(s));const r=e.__on_r;r?e.__on_r=()=>{r(),n(!0)}:e.__on_r=()=>n(!0),wo()}function Jl(e){I===null&&(L===null&&Ii(),Ni()),Ct&&Oi()}function yo(e,t){var s=t.last;s===null?t.last=t.first=e:(s.next=e,e.prev=s,t.last=e)}function nt(e,t){var s=I;s!==null&&s.f&_e&&(e|=_e);var n={ctx:z,deps:null,nodes:null,f:e|ce|Fe,first:null,fn:t,last:null,next:null,parent:s,b:s&&s.b,prev:null,teardown:null,wv:0,ac:null};S==null||S.register_created_effect(n);var r=n;if(e&us)rs!==null?rs.push(n):Yt.ensure().schedule(n);else if(t!==null){try{Jt(n)}catch(c){throw ye(n),c}r.deps===null&&r.teardown===null&&r.nodes===null&&r.first===r.last&&!(r.f&_s)&&(r=r.first,e&st&&e&vs&&r!==null&&(r.f|=vs))}if(r!==null&&(r.parent=s,s!==null&&yo(r,s),L!==null&&L.f&ve&&!(e&Mt))){var a=L;(a.effects??(a.effects=[])).push(r)}return n}function or(){return L!==null&&!Ke}function cr(e){const t=nt(Hs,null);return Y(t,Q),t.teardown=e,t}function Jn(e){Jl();var t=I.f,s=!L&&(t&Ye)!==0&&(t&Qt)===0;if(s){var n=z;(n.e??(n.e=[])).push(e)}else return Ql(e)}function Ql(e){return nt(us|kl,e)}function Eo(e){return Jl(),nt(Hs|kl,e)}function ko(e){Yt.ensure();const t=nt(Mt|_s,e);return(s={})=>new Promise(n=>{s.outro?Ut(t,()=>{ye(t),n(void 0)}):(ye(t),n(void 0))})}function xo(e){return nt(us,e)}function ge(e,t){var s=z,n={effect:null,ran:!1,deps:e};s.l.$.push(n),n.effect=En(()=>{if(e(),!n.ran){n.ran=!0;var r=I;try{Be(r.parent),y(t)}finally{Be(r)}}})}function So(){var e=z;En(()=>{for(var t of e.l.$){t.deps();var s=t.effect;s.f&Q&&s.deps!==null&&Y(s,Ge),bs(s)&&Jt(s),t.ran=!1}})}function Mo(e){return nt(Ds|_s,e)}function En(e,t=0){return nt(Hs|t,e)}function K(e,t=[],s=[],n=[]){co(n,t,s,r=>{nt(Hs,()=>e(...r.map(l)))})}function fr(e,t=0){var s=nt(st|t,e);return s}function Re(e){return nt(Ye|_s,e)}function Xl(e){var t=e.teardown;if(t!==null){const s=Ct,n=L;fl(!0),$e(null);try{t.call(null)}finally{fl(s),$e(n)}}}function ur(e,t=!1){var s=e.first;for(e.first=e.last=null;s!==null;){const r=s.ac;r!==null&&yn(()=>{r.abort(ot)});var n=s.next;s.f&Mt?s.parent=null:ye(s,t),s=n}}function Co(e){for(var t=e.first;t!==null;){var s=t.next;t.f&Ye||ye(t),t=s}}function ye(e,t=!0){var s=!1;(t||e.f&Ci)&&e.nodes!==null&&e.nodes.end!==null&&(To(e.nodes.start,e.nodes.end),s=!0),Y(e,ll),ur(e,t&&!s),Ls(e,0);var n=e.nodes&&e.nodes.t;if(n!==null)for(const a of n)a.stop();Xl(e),e.f^=ll,e.f|=Pe;var r=e.parent;r!==null&&r.first!==null&&Zl(e),e.next=e.prev=e.teardown=e.ctx=e.deps=e.fn=e.nodes=e.ac=e.b=null}function To(e,t){for(;e!==null;){var s=e===t?null:Us(e);e.remove(),e=s}}function Zl(e){var t=e.parent,s=e.prev,n=e.next;s!==null&&(s.next=n),n!==null&&(n.prev=s),t!==null&&(t.first===e&&(t.first=n),t.last===e&&(t.last=s))}function Ut(e,t,s=!0){var n=[];ea(e,n,!0);var r=()=>{s&&ye(e),t&&t()},a=n.length;if(a>0){var c=()=>--a||r();for(var u of n)u.out(c)}else r()}function ea(e,t,s){if(!(e.f&_e)){e.f^=_e;var n=e.nodes&&e.nodes.t;if(n!==null)for(const u of n)(u.is_global||s)&&t.push(u);for(var r=e.first;r!==null;){var a=r.next;if(!(r.f&Mt)){var c=(r.f&vs)!==0||(r.f&Ye)!==0&&(e.f&st)!==0;ea(r,t,c?s:!1)}r=a}}}function vr(e){ta(e,!0)}function ta(e,t){if(e.f&_e){e.f^=_e,e.f&Q||(Y(e,ce),Yt.ensure().schedule(e));for(var s=e.first;s!==null;){var n=s.next,r=(s.f&vs)!==0||(s.f&Ye)!==0;ta(s,r?t:!1),s=n}var a=e.nodes&&e.nodes.t;if(a!==null)for(const c of a)(c.is_global||t)&&c.in()}}function dr(e,t){if(e.nodes)for(var s=e.nodes.start,n=e.nodes.end;s!==null;){var r=s===n?null:Us(s);t.append(s),s=r}}let pn=!1,Ct=!1;function fl(e){Ct=e}let L=null,Ke=!1;function $e(e){L=e}let I=null;function Be(e){I=e}let je=null;function Ao(e){L!==null&&(je===null?je=[e]:je.push(e))}let we=null,xe=0,Ne=null;function Oo(e){Ne=e}let sa=1,Pt=0,zt=Pt;function ul(e){zt=e}function na(){return++sa}function bs(e){var t=e.f;if(t&ce)return!0;if(t&ve&&(e.f&=~Kt),t&Ge){for(var s=e.deps,n=s.length,r=0;r<n;r++){var a=s[r];if(bs(a)&&Vl(a),a.wv>e.wv)return!0}t&Fe&&oe===null&&Y(e,Q)}return!1}function ra(e,t,s=!0){var n=e.reactions;if(n!==null&&!(je!==null&&fs.call(je,e)))for(var r=0;r<n.length;r++){var a=n[r];a.f&ve?ra(a,t,!1):t===a&&(s?Y(a,ce):a.f&Q&&Y(a,Ge),lr(a))}}function la(e){var C;var t=we,s=xe,n=Ne,r=L,a=je,c=z,u=Ke,f=zt,v=e.f;we=null,xe=0,Ne=null,L=v&(Ye|Mt)?null:e,je=null,ds(e.ctx),Ke=!1,zt=++Pt,e.ac!==null&&(yn(()=>{e.ac.abort(ot)}),e.ac=null);try{e.f|=hn;var p=e.fn,E=p();e.f|=Qt;var b=e.deps,m=S==null?void 0:S.is_fork;if(we!==null){var g;if(m||Ls(e,xe),b!==null&&xe>0)for(b.length=xe+we.length,g=0;g<we.length;g++)b[xe+g]=we[g];else e.deps=b=we;if(or()&&e.f&Fe)for(g=xe;g<b.length;g++)((C=b[g]).reactions??(C.reactions=[])).push(e)}else!m&&b!==null&&xe<b.length&&(Ls(e,xe),b.length=xe);if(qs()&&Ne!==null&&!Ke&&b!==null&&!(e.f&(ve|Ge|ce)))for(g=0;g<Ne.length;g++)ra(Ne[g],e);if(r!==null&&r!==e){if(Pt++,r.deps!==null)for(let d=0;d<s;d+=1)r.deps[d].rv=Pt;if(t!==null)for(const d of t)d.rv=Pt;Ne!==null&&(n===null?n=Ne:n.push(...Ne))}return e.f&xt&&(e.f^=xt),E}catch(d){return Il(d)}finally{e.f^=hn,we=t,xe=s,Ne=n,L=r,je=a,ds(c),Ke=u,zt=f}}function No(e,t){let s=t.reactions;if(s!==null){var n=yi.call(s,e);if(n!==-1){var r=s.length-1;r===0?s=t.reactions=null:(s[n]=s[r],s.pop())}}if(s===null&&t.f&ve&&(we===null||!fs.call(we,t))){var a=t;a.f&Fe&&(a.f^=Fe,a.f&=~Kt),a.v!==re&&nr(a),po(a),Ls(a,0)}}function Ls(e,t){var s=e.deps;if(s!==null)for(var n=t;n<s.length;n++)No(e,s[n])}function Jt(e){var t=e.f;if(!(t&Pe)){Y(e,Q);var s=I,n=pn;I=e,pn=!0;try{t&(st|El)?Co(e):ur(e),Xl(e);var r=la(e);e.teardown=typeof r=="function"?r:null,e.wv=sa;var a;wi&&Yi&&e.f&ce&&e.deps}finally{pn=n,I=s}}}async function Io(){await Promise.resolve(),eo()}function l(e){var t=e.f,s=(t&ve)!==0;if(L!==null&&!Ke){var n=I!==null&&(I.f&Pe)!==0;if(!n&&(je===null||!fs.call(je,e))){var r=L.deps;if(L.f&hn)e.rv<Pt&&(e.rv=Pt,we===null&&r!==null&&r[xe]===e?xe++:we===null?we=[e]:we.push(e));else{(L.deps??(L.deps=[])).push(e);var a=e.reactions;a===null?e.reactions=[L]:fs.call(a,L)||a.push(L)}}}if(Ct&&qt.has(e))return qt.get(e);if(s){var c=e;if(Ct){var u=c.v;return(!(c.f&Q)&&c.reactions!==null||ia(c))&&(u=ir(c)),qt.set(c,u),u}var f=(c.f&Fe)===0&&!Ke&&L!==null&&(pn||(L.f&Fe)!==0),v=(c.f&Qt)===0;bs(c)&&(f&&(c.f|=Fe),Vl(c)),f&&!v&&(Hl(c),aa(c))}if(oe!=null&&oe.has(e))return oe.get(e);if(e.f&xt)throw e.v;return e.v}function aa(e){if(e.f|=Fe,e.deps!==null)for(const t of e.deps)(t.reactions??(t.reactions=[])).push(e),t.f&ve&&!(t.f&Fe)&&(Hl(t),aa(t))}function ia(e){if(e.v===re)return!0;if(e.deps===null)return!1;for(const t of e.deps)if(qt.has(t)||t.f&ve&&ia(t))return!0;return!1}function y(e){var t=Ke;try{return Ke=!0,e()}finally{Ke=t}}function Do(e){if(!(typeof e!="object"||!e||e instanceof EventTarget)){if(Wt in e)Qn(e);else if(!Array.isArray(e))for(let t in e){const s=e[t];typeof s=="object"&&s&&Wt in s&&Qn(s)}}}function Qn(e,t=new Set){if(typeof e=="object"&&e!==null&&!(e instanceof EventTarget)&&!t.has(e)){t.add(e),e instanceof Date&&e.getTime();for(let n in e)try{Qn(e[n],t)}catch{}const s=sr(e);if(s!==Object.prototype&&s!==Array.prototype&&s!==Map.prototype&&s!==Set.prototype&&s!==Date.prototype){const n=wl(s);for(let r in n){const a=n[r].get;if(a)try{a.call(e)}catch{}}}}}const Lo=["touchstart","touchmove"];function Ro(e){return Lo.includes(e)}const sn=Symbol("events"),Fo=new Set,vl=new Set;function Po(e,t,s,n={}){function r(a){if(n.capture||Xn.call(t,a),!a.cancelBubble)return yn(()=>s==null?void 0:s.call(this,a))}return e.startsWith("pointer")||e.startsWith("touch")||e==="wheel"?St(()=>{t.addEventListener(e,r,n)}):t.addEventListener(e,r,n),r}function ie(e,t,s,n,r){var a={capture:n,passive:r},c=Po(e,t,s,a);(t===document.body||t===window||t===document||t instanceof HTMLMediaElement)&&cr(()=>{t.removeEventListener(e,c,a)})}let dl=null;function Xn(e){var d,M;var t=this,s=t.ownerDocument,n=e.type,r=((d=e.composedPath)==null?void 0:d.call(e))||[],a=r[0]||e.target;dl=e;var c=0,u=dl===e&&e[sn];if(u){var f=r.indexOf(u);if(f!==-1&&(t===document||t===window)){e[sn]=t;return}var v=r.indexOf(t);if(v===-1)return;f<=v&&(c=f)}if(a=r[c]||e.target,a!==t){Ei(e,"currentTarget",{configurable:!0,get(){return a||s}});var p=L,E=I;$e(null),Be(null);try{for(var b,m=[];a!==null;){var g=a.assignedSlot||a.parentNode||a.host||null;try{var C=(M=a[sn])==null?void 0:M[n];C!=null&&(!a.disabled||e.target===a)&&C.call(a,e)}catch(H){b?m.push(H):b=H}if(e.cancelBubble||g===t||g===null)break;a=g}if(b){for(let H of m)queueMicrotask(()=>{throw H});throw b}}finally{e[sn]=t,delete e.currentTarget,$e(p),Be(E)}}}var gl;const Fn=((gl=globalThis==null?void 0:globalThis.window)==null?void 0:gl.trustedTypes)&&globalThis.window.trustedTypes.createPolicy("svelte-trusted-html",{createHTML:e=>e});function jo(e){return(Fn==null?void 0:Fn.createHTML(e))??e}function oa(e){var t=mo("template");return t.innerHTML=jo(e.replaceAll("<!>","<!---->")),t.content}function Rs(e,t){var s=I;s.nodes===null&&(s.nodes={start:e,end:t,a:null,t:null})}function ee(e,t){var s=(t&Hi)!==0,n=(t&Wi)!==0,r,a=!e.startsWith("<!>");return()=>{r===void 0&&(r=oa(a?e:"<!>"+e),s||(r=hs(r)));var c=n||Ul?document.importNode(r,!0):r.cloneNode(!0);if(s){var u=hs(c),f=c.lastChild;Rs(u,f)}else Rs(c,c);return c}}function $o(e,t,s="svg"){var n=!e.startsWith("<!>"),r=`<${s}>${n?e:"<!>"+e}</${s}>`,a;return()=>{if(!a){var c=oa(r),u=hs(c);a=hs(u)}var f=a.cloneNode(!0);return Rs(f,f),f}}function kn(e,t){return $o(e,t,"svg")}function mt(e=""){{var t=dt(e+"");return Rs(t,t),t}}function nn(){var e=document.createDocumentFragment(),t=document.createComment(""),s=dt();return e.append(t,s),Rs(t,s),e}function D(e,t){e!==null&&e.before(t)}function O(e,t){var s=t==null?"":typeof t=="object"?`${t}`:t;s!==(e.__t??(e.__t=e.nodeValue))&&(e.__t=s,e.nodeValue=`${s}`)}function Bo(e,t){return Vo(e,t)}const rn=new Map;function Vo(e,{target:t,anchor:s,props:n={},events:r,context:a,intro:c=!0,transformError:u}){bo();var f=void 0,v=ko(()=>{var p=s??t.appendChild(dt());ro(p,{pending:()=>{}},m=>{Al({});var g=z;a&&(g.c=a),r&&(n.$$events=r),f=e(m,n)||{},Ol()},u);var E=new Set,b=m=>{for(var g=0;g<m.length;g++){var C=m[g];if(!E.has(C)){E.add(C);var d=Ro(C);for(const P of[t,document]){var M=rn.get(P);M===void 0&&(M=new Map,rn.set(P,M));var H=M.get(C);H===void 0?(P.addEventListener(C,Xn,{passive:d}),M.set(C,1)):M.set(C,H+1)}}}};return b(wn(Fo)),vl.add(b),()=>{var d;for(var m of E)for(const M of[t,document]){var g=rn.get(M),C=g.get(m);--C==0?(M.removeEventListener(m,Xn),g.delete(m),g.size===0&&rn.delete(M)):g.set(m,C)}vl.delete(b),p!==s&&((d=p.parentNode)==null||d.removeChild(p))}});return Ho.set(f,v),f}let Ho=new WeakMap;var ze,et,Ce,Ht,Bs,Vs,mn;class Wo{constructor(t,s=!0){We(this,"anchor");A(this,ze,new Map);A(this,et,new Map);A(this,Ce,new Map);A(this,Ht,new Set);A(this,Bs,!0);A(this,Vs,t=>{if(o(this,ze).has(t)){var s=o(this,ze).get(t),n=o(this,et).get(s);if(n)vr(n),o(this,Ht).delete(s);else{var r=o(this,Ce).get(s);r&&(o(this,et).set(s,r.effect),o(this,Ce).delete(s),r.fragment.lastChild.remove(),this.anchor.before(r.fragment),n=r.effect)}for(const[a,c]of o(this,ze)){if(o(this,ze).delete(a),a===t)break;const u=o(this,Ce).get(c);u&&(ye(u.effect),o(this,Ce).delete(c))}for(const[a,c]of o(this,et)){if(a===s||o(this,Ht).has(a))continue;const u=()=>{if(Array.from(o(this,ze).values()).includes(a)){var v=document.createDocumentFragment();dr(c,v),v.append(dt()),o(this,Ce).set(a,{effect:c,fragment:v})}else ye(c);o(this,Ht).delete(a),o(this,et).delete(a)};o(this,Bs)||!n?(o(this,Ht).add(a),Ut(c,u,!1)):u()}}});A(this,mn,t=>{o(this,ze).delete(t);const s=Array.from(o(this,ze).values());for(const[n,r]of o(this,Ce))s.includes(n)||(ye(r.effect),o(this,Ce).delete(n))});this.anchor=t,N(this,Bs,s)}ensure(t,s){var n=S,r=Yl();if(s&&!o(this,et).has(t)&&!o(this,Ce).has(t))if(r){var a=document.createDocumentFragment(),c=dt();a.append(c),o(this,Ce).set(t,{effect:Re(()=>s(c)),fragment:a})}else o(this,et).set(t,Re(()=>s(this.anchor)));if(o(this,ze).set(n,t),r){for(const[u,f]of o(this,et))u===t?n.unskip_effect(f):n.skip_effect(f);for(const[u,f]of o(this,Ce))u===t?n.unskip_effect(f.effect):n.skip_effect(f.effect);n.oncommit(o(this,Vs)),n.ondiscard(o(this,mn))}else o(this,Vs).call(this,n)}}ze=new WeakMap,et=new WeakMap,Ce=new WeakMap,Ht=new WeakMap,Bs=new WeakMap,Vs=new WeakMap,mn=new WeakMap;function Z(e,t,s=!1){var n=new Wo(e),r=s?vs:0;function a(c,u){n.ensure(c,u)}fr(()=>{var c=!1;t((u,f=0)=>{c=!0,a(f,u)}),c||a(-1,null)},r)}function qo(e,t,s){for(var n=[],r=t.length,a,c=t.length,u=0;u<r;u++){let E=t[u];Ut(E,()=>{if(a){if(a.pending.delete(E),a.done.add(E),a.pending.size===0){var b=e.outrogroups;Zn(e,wn(a.done)),b.delete(a),b.size===0&&(e.outrogroups=null)}}else c-=1},!1)}if(c===0){var f=n.length===0&&s!==null;if(f){var v=s,p=v.parentNode;go(p),p.append(v),e.items.clear()}Zn(e,t,!f)}else a={pending:new Set(t),done:new Set},(e.outrogroups??(e.outrogroups=new Set)).add(a)}function Zn(e,t,s=!0){var n;if(e.pending.size>0){n=new Set;for(const c of e.pending.values())for(const u of c)n.add(e.items.get(u).e)}for(var r=0;r<t.length;r++){var a=t[r];if(n!=null&&n.has(a)){a.f|=tt;const c=document.createDocumentFragment();dr(a,c)}else ye(t[r],s)}}var pl;function ln(e,t,s,n,r,a=null){var c=e,u=new Map,f=(t&Sl)!==0;if(f){var v=e;c=v.appendChild(dt())}var p=null,E=Bl(()=>{var P=s();return tr(P)?P:P==null?[]:wn(P)}),b,m=new Map,g=!0;function C(P){H.effect.f&Pe||(H.pending.delete(P),H.fallback=p,Uo(H,b,c,t,n),p!==null&&(b.length===0?p.f&tt?(p.f^=tt,Ts(p,null,c)):vr(p):Ut(p,()=>{p=null})))}function d(P){H.pending.delete(P)}var M=fr(()=>{b=l(E);for(var P=b.length,te=new Set,de=S,fe=Yl(),J=0;J<P;J+=1){var Ve=b[J],W=n(Ve,J),q=g?null:u.get(W);q?(q.v&&ps(q.v,Ve),q.i&&ps(q.i,J),fe&&de.unskip_effect(q.e)):(q=zo(u,g?c:pl??(pl=dt()),Ve,W,J,r,t,s),g||(q.e.f|=tt),u.set(W,q)),te.add(W)}if(P===0&&a&&!p&&(g?p=Re(()=>a(c)):(p=Re(()=>a(pl??(pl=dt()))),p.f|=tt)),P>te.size&&Ai(),!g)if(m.set(de,te),fe){for(const[Te,Ae]of u)te.has(Te)||de.skip_effect(Ae.e);de.oncommit(C),de.ondiscard(d)}else C(de);l(E)}),H={effect:M,items:u,pending:m,outrogroups:null,fallback:p};g=!1}function Ss(e){for(;e!==null&&!(e.f&Ye);)e=e.next;return e}function Uo(e,t,s,n,r){var q,Te,Ae,pt,rt,gs,zs,Xt,ms;var a=(n&Bi)!==0,c=t.length,u=e.items,f=Ss(e.effect.first),v,p=null,E,b=[],m=[],g,C,d,M;if(a)for(M=0;M<c;M+=1)g=t[M],C=r(g,M),d=u.get(C).e,d.f&tt||((Te=(q=d.nodes)==null?void 0:q.a)==null||Te.measure(),(E??(E=new Set)).add(d));for(M=0;M<c;M+=1){if(g=t[M],C=r(g,M),d=u.get(C).e,e.outrogroups!==null)for(const be of e.outrogroups)be.pending.delete(d),be.done.delete(d);if(d.f&_e&&(vr(d),a&&((pt=(Ae=d.nodes)==null?void 0:Ae.a)==null||pt.unfix(),(E??(E=new Set)).delete(d))),d.f&tt)if(d.f^=tt,d===f)Ts(d,null,s);else{var H=p?p.next:f;d===e.effect.last&&(e.effect.last=d.prev),d.prev&&(d.prev.next=d.next),d.next&&(d.next.prev=d.prev),wt(e,p,d),wt(e,d,H),Ts(d,H,s),p=d,b=[],m=[],f=Ss(p.next);continue}if(d!==f){if(v!==void 0&&v.has(d)){if(b.length<m.length){var P=m[0],te;p=P.prev;var de=b[0],fe=b[b.length-1];for(te=0;te<b.length;te+=1)Ts(b[te],P,s);for(te=0;te<m.length;te+=1)v.delete(m[te]);wt(e,de.prev,fe.next),wt(e,p,de),wt(e,fe,P),f=P,p=fe,M-=1,b=[],m=[]}else v.delete(d),Ts(d,f,s),wt(e,d.prev,d.next),wt(e,d,p===null?e.effect.first:p.next),wt(e,p,d),p=d;continue}for(b=[],m=[];f!==null&&f!==d;)(v??(v=new Set)).add(f),m.push(f),f=Ss(f.next);if(f===null)continue}d.f&tt||b.push(d),p=d,f=Ss(d.next)}if(e.outrogroups!==null){for(const be of e.outrogroups)be.pending.size===0&&(Zn(e,wn(be.done)),(rt=e.outrogroups)==null||rt.delete(be));e.outrogroups.size===0&&(e.outrogroups=null)}if(f!==null||v!==void 0){var J=[];if(v!==void 0)for(d of v)d.f&_e||J.push(d);for(;f!==null;)!(f.f&_e)&&f!==e.fallback&&J.push(f),f=Ss(f.next);var Ve=J.length;if(Ve>0){var W=n&Sl&&c===0?s:null;if(a){for(M=0;M<Ve;M+=1)(zs=(gs=J[M].nodes)==null?void 0:gs.a)==null||zs.measure();for(M=0;M<Ve;M+=1)(ms=(Xt=J[M].nodes)==null?void 0:Xt.a)==null||ms.fix()}qo(e,J,W)}}a&&St(()=>{var be,Ks;if(E!==void 0)for(d of E)(Ks=(be=d.nodes)==null?void 0:be.a)==null||Ks.apply()})}function zo(e,t,s,n,r,a,c,u){var f=c&ji?c&Vi?Gt(s):j(s,!1,!1):null,v=c&$i?Gt(r):null;return{v:f,i:v,e:Re(()=>(a(t,f??s,v??r,u),()=>{e.delete(n)}))}}function Ts(e,t,s){if(e.nodes)for(var n=e.nodes.start,r=e.nodes.end,a=t&&!(t.f&tt)?t.nodes.start:s;n!==null;){var c=Us(n);if(a.before(n),n===r)return;n=c}}function wt(e,t,s){t===null?e.effect.first=s:t.next=s,s===null?e.effect.last=t:s.prev=t}const hl=[...`
|
|
2
|
-
\r\f \v\uFEFF`];function Ko(e,t,s){var n=e==null?"":""+e;if(t&&(n=n?n+" "+t:t),s){for(var r of Object.keys(s))if(s[r])n=n?n+" "+r:r;else if(n.length)for(var a=r.length,c=0;(c=n.indexOf(r,c))>=0;){var u=c+a;(c===0||hl.includes(n[c-1]))&&(u===n.length||hl.includes(n[u]))?n=(c===0?"":n.substring(0,c))+n.substring(u+1):c=u}}return n===""?null:n}function Yo(e,t){return e==null?null:String(e)}function ue(e,t,s,n,r,a){var c=e.__className;if(c!==s||c===void 0){var u=Ko(s,n,a);u==null?e.removeAttribute("class"):t?e.className=u:e.setAttribute("class",u),e.__className=s}else if(a&&r!==a)for(var f in a){var v=!!a[f];(r==null||v!==!!r[f])&&e.classList.toggle(f,v)}return a}function Go(e,t,s,n){var r=e.__style;if(r!==t){var a=Yo(t);a==null?e.removeAttribute("style"):e.style.cssText=a,e.__style=t}return n}function ca(e,t,s=!1){if(e.multiple){if(t==null)return;if(!tr(t))return Ui();for(var n of e.options)n.selected=t.includes(Is(n));return}for(n of e.options){var r=Is(n);if(_o(r,t)){n.selected=!0;return}}(!s||t!==void 0)&&(e.selectedIndex=-1)}function Jo(e){var t=new MutationObserver(()=>{ca(e,e.__value)});t.observe(e,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["value"]}),cr(()=>{t.disconnect()})}function Pn(e,t,s=t){var n=new WeakSet,r=!0;Gl(e,"change",a=>{var c=a?"[selected]":":checked",u;if(e.multiple)u=[].map.call(e.querySelectorAll(c),Is);else{var f=e.querySelector(c)??e.querySelector("option:not([disabled])");u=f&&Is(f)}s(u),e.__value=u,S!==null&&n.add(S)}),xo(()=>{var a=t();if(e===document.activeElement){var c=S;if(n.has(c))return}if(ca(e,a,r),r&&a===void 0){var u=e.querySelector(":checked");u!==null&&(a=Is(u),s(a))}e.__value=a,r=!1}),Jo(e)}function Is(e){return"__value"in e?e.__value:e.value}const Qo=Symbol("is custom element"),Xo=Symbol("is html");function an(e,t,s,n){var r=Zo(e);r[t]!==(r[t]=s)&&(s==null?e.removeAttribute(t):typeof s!="string"&&ec(e).includes(t)?e[t]=s:e.setAttribute(t,s))}function Zo(e){return e.__attributes??(e.__attributes={[Qo]:e.nodeName.includes("-"),[Xo]:e.namespaceURI===Ml})}var _l=new Map;function ec(e){var t=e.getAttribute("is")||e.nodeName,s=_l.get(t);if(s)return s;_l.set(t,s=[]);for(var n,r=e,a=Element.prototype;a!==r;){n=wl(r);for(var c in n)n[c].set&&s.push(c);r=sr(r)}return s}function Ms(e,t,s=t){var n=new WeakSet;Gl(e,"input",async r=>{var a=r?e.defaultValue:e.value;if(a=jn(e)?$n(a):a,s(a),S!==null&&n.add(S),await Io(),a!==(a=t())){var c=e.selectionStart,u=e.selectionEnd,f=e.value.length;if(e.value=a??"",u!==null){var v=e.value.length;c===u&&u===f&&v>f?(e.selectionStart=v,e.selectionEnd=v):(e.selectionStart=c,e.selectionEnd=Math.min(u,v))}}}),y(t)==null&&e.value&&(s(jn(e)?$n(e.value):e.value),S!==null&&n.add(S)),En(()=>{var r=t();if(e===document.activeElement){var a=S;if(n.has(a))return}jn(e)&&r===$n(e.value)||e.type==="date"&&!r&&!e.value||r!==e.value&&(e.value=r??"")})}function jn(e){var t=e.type;return t==="number"||t==="range"}function $n(e){return e===""?null:+e}function tc(e){return function(...t){var s=t[0];return s.stopPropagation(),e==null?void 0:e.apply(this,t)}}function sc(e){return function(...t){var s=t[0];return s.preventDefault(),e==null?void 0:e.apply(this,t)}}function nc(e=!1){const t=z,s=t.l.u;if(!s)return;let n=()=>Do(t.s);if(e){let r=0,a={};const c=ar(()=>{let u=!1;const f=t.s;for(const v in f)f[v]!==a[v]&&(a[v]=f[v],u=!0);return u&&r++,r});n=()=>l(c)}s.b.length&&Eo(()=>{bl(t,n),Bn(s.b)}),Jn(()=>{const r=y(()=>s.m.map(Mi));return()=>{for(const a of r)typeof a=="function"&&a()}}),s.a.length&&Jn(()=>{bl(t,n),Bn(s.a)})}function bl(e,t){if(e.l.s)for(const s of e.l.s)l(s);t()}function rc(e){z===null&&xl(),Ws&&z.l!==null?ac(z).m.push(e):Jn(()=>{const t=y(e);if(typeof t=="function")return t})}function lc(e){z===null&&xl(),rc(()=>()=>y(e))}function ac(e){var t=e.l;return t.u??(t.u={a:[],b:[],m:[]})}const ic="5";var ml;typeof window<"u"&&((ml=window.__svelte??(window.__svelte={})).v??(ml.v=new Set)).add(ic);Gi();var oc=kn('<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.8" class="svelte-d3ct2b"><circle cx="12" cy="12" r="5" class="svelte-d3ct2b"></circle><line x1="12" y1="1" x2="12" y2="3" class="svelte-d3ct2b"></line><line x1="12" y1="21" x2="12" y2="23" class="svelte-d3ct2b"></line><line x1="4.22" y1="4.22" x2="5.64" y2="5.64" class="svelte-d3ct2b"></line><line x1="18.36" y1="18.36" x2="19.78" y2="19.78" class="svelte-d3ct2b"></line><line x1="1" y1="12" x2="3" y2="12" class="svelte-d3ct2b"></line><line x1="21" y1="12" x2="23" y2="12" class="svelte-d3ct2b"></line><line x1="4.22" y1="19.78" x2="5.64" y2="18.36" class="svelte-d3ct2b"></line><line x1="18.36" y1="5.64" x2="19.78" y2="4.22" class="svelte-d3ct2b"></line></svg>'),cc=kn('<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.8" class="svelte-d3ct2b"><path d="M21 12.79A9 9 0 1 1 11.21 3 7 7 0 0 0 21 12.79z" class="svelte-d3ct2b"></path></svg>'),fc=ee('<span class="health-error svelte-d3ct2b"> </span>'),uc=ee('<span class="health-error svelte-d3ct2b"> </span>'),vc=ee('<span class="dropdown-badge svelte-d3ct2b"> </span>'),dc=ee('<div class="dropdown svelte-d3ct2b"><button><svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" class="svelte-d3ct2b"><circle cx="12" cy="12" r="3" class="svelte-d3ct2b"></circle><path d="M12 1v4M12 19v4M4.22 4.22l2.83 2.83M16.95 16.95l2.83 2.83M1 12h4M19 12h4" class="svelte-d3ct2b"></path></svg> Core Engine</button> <button><svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" class="svelte-d3ct2b"><circle cx="12" cy="12" r="4" class="svelte-d3ct2b"></circle><path d="M4 12H2M22 12h-2M12 4V2M12 22v-2" class="svelte-d3ct2b"></path><path d="m6.34 6.34-1.41-1.42M19.07 19.07l-1.41-1.41" class="svelte-d3ct2b"></path></svg> Commit Hook <!></button></div>'),pc=kn('<svg width="16" height="16" viewBox="0 0 24 24" fill="currentColor" class="svelte-d3ct2b"><polygon points="5 3 19 12 5 21 5 3" class="svelte-d3ct2b"></polygon></svg>'),hc=kn('<svg width="16" height="16" viewBox="0 0 24 24" fill="currentColor" class="svelte-d3ct2b"><rect x="6" y="4" width="4" height="16" class="svelte-d3ct2b"></rect><rect x="14" y="4" width="4" height="16" class="svelte-d3ct2b"></rect></svg>'),_c=ee('<div class="log-row svelte-d3ct2b"><span class="log-time svelte-d3ct2b">--:--:--</span> <span class="log-label label-sys svelte-d3ct2b">SYS</span> <span class="log-msg svelte-d3ct2b">Initialization sequence started for memory-core...</span></div> <div class="log-row svelte-d3ct2b"><span class="log-time svelte-d3ct2b">--:--:--</span> <span class="log-label label-ok svelte-d3ct2b">DB</span> <span class="log-msg svelte-d3ct2b">Waiting for PostgreSQL connection...</span></div> <div class="log-row log-row-warn svelte-d3ct2b"><span class="log-time svelte-d3ct2b">--:--:--</span> <span class="log-label label-warn svelte-d3ct2b">WARN</span> <span class="log-msg svelte-d3ct2b">No architecture rules configured in .memory-core.json — nothing to watch.</span></div> <div class="log-row svelte-d3ct2b"><span class="log-time svelte-d3ct2b">--:--:--</span> <span class="log-label label-sys svelte-d3ct2b">SYS</span> <span class="log-msg svelte-d3ct2b">Awaiting manual rule configuration...</span></div> <div class="log-row svelte-d3ct2b"><span class="log-time svelte-d3ct2b"></span> <span class="log-label svelte-d3ct2b"></span> <span class="log-msg cursor-blink svelte-d3ct2b">_</span></div>',1),bc=ee('· <em class="svelte-d3ct2b"> </em>',1),gc=ee('<br class="svelte-d3ct2b"/><span class="detail-fix svelte-d3ct2b"> </span>',1),mc=ee('<div class="log-detail svelte-d3ct2b"><span class="detail-index svelte-d3ct2b"> </span> <span class="detail-body svelte-d3ct2b"><strong class="svelte-d3ct2b"> </strong> <!> <!> <!></span></div>'),wc=ee('<div><span class="log-time svelte-d3ct2b"> </span> <span> </span> <span class="log-msg svelte-d3ct2b"><!></span> <button class="copy-btn svelte-d3ct2b" title="Copy">⎘</button></div> <!>',1),yc=ee('<div class="log-row svelte-d3ct2b"><span class="log-time svelte-d3ct2b">--:--:--</span> <span class="log-label label-ok svelte-d3ct2b">[OK]</span> <span class="log-msg svelte-d3ct2b">No commit hook violations in the last 24 hours.</span></div> <div class="log-row svelte-d3ct2b"><span class="log-time svelte-d3ct2b"></span> <span class="log-label svelte-d3ct2b"></span> <span class="log-msg cursor-blink svelte-d3ct2b">_</span></div>',1),Ec=ee('<br class="svelte-d3ct2b"/><span class="detail-fix svelte-d3ct2b"> </span>',1),kc=ee('<div class="log-detail svelte-d3ct2b"><span class="detail-index svelte-d3ct2b"></span> <span class="detail-body svelte-d3ct2b"><!> <!></span></div>'),xc=ee('<div class="log-row log-row-fail svelte-d3ct2b"><span class="log-time svelte-d3ct2b"> </span> <span class="log-label label-hook svelte-d3ct2b"> </span> <span class="log-msg svelte-d3ct2b"><strong class="svelte-d3ct2b"> </strong> <!></span></div> <!>',1),Sc=ee('<div class="section-header svelte-d3ct2b"><span class="section-title svelte-d3ct2b">Commit Hook</span> <span class="section-meta svelte-d3ct2b"> </span></div> <!>',1),Mc=ee('<span class="rule-reason svelte-d3ct2b"> </span>'),Cc=ee('<div class="rule-row svelte-d3ct2b"><span class="rule-badge svelte-d3ct2b"> </span> <span class="rule-scope svelte-d3ct2b"> </span> <span class="rule-content svelte-d3ct2b"> </span> <!> <button class="del-btn svelte-d3ct2b">✕</button></div>'),Tc=ee('<div class="log-row svelte-d3ct2b"><span class="log-msg svelte-d3ct2b" style="color: var(--outline)">No rules match the current filters.</span></div>'),Ac=ee('<div class="section-header svelte-d3ct2b"><span class="section-title svelte-d3ct2b">Rule Engine</span> <span class="section-meta svelte-d3ct2b"> </span></div> <div class="rules-toolbar svelte-d3ct2b"><select class="rules-select svelte-d3ct2b"><option class="svelte-d3ct2b">All types</option><option class="svelte-d3ct2b">Rules</option><option class="svelte-d3ct2b">Decisions</option><option class="svelte-d3ct2b">Patterns</option><option class="svelte-d3ct2b">Ignores</option></select> <input class="rules-search svelte-d3ct2b" placeholder="Search rules..."/></div> <div class="rule-form-wrap svelte-d3ct2b"><form class="rule-form svelte-d3ct2b"><div class="rule-form-row svelte-d3ct2b"><select class="rules-select svelte-d3ct2b"><option class="svelte-d3ct2b">Rule</option><option class="svelte-d3ct2b">Decision</option><option class="svelte-d3ct2b">Pattern</option><option class="svelte-d3ct2b">Ignore</option></select> <select class="rules-select svelte-d3ct2b"><option class="svelte-d3ct2b">Project</option><option class="svelte-d3ct2b">Global</option></select> <input class="rules-input svelte-d3ct2b" placeholder="Reason"/> <input class="rules-input svelte-d3ct2b" placeholder="Tags"/></div> <div class="rule-form-row svelte-d3ct2b"><textarea rows="2" class="rules-textarea svelte-d3ct2b" placeholder="Rule or decision content..."></textarea> <button class="add-btn svelte-d3ct2b"> </button></div></form></div> <div class="rule-list svelte-d3ct2b"></div>',1),Oc=ee('<div><header class="topbar svelte-d3ct2b"><div class="topbar-brand svelte-d3ct2b"><span class="brand-name svelte-d3ct2b">memory-core</span> <nav class="topbar-nav svelte-d3ct2b"><button>Dashboard</button> <button>Live Feed</button> <button>Metrics</button></nav></div> <div class="topbar-search svelte-d3ct2b"><span class="search-icon svelte-d3ct2b">⌕</span> <input class="search-input svelte-d3ct2b" placeholder="Search system logs, traces, and metrics..." type="text"/></div> <div class="topbar-actions svelte-d3ct2b"><button class="icon-btn svelte-d3ct2b" title="Notifications"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.8" class="svelte-d3ct2b"><path d="M18 8A6 6 0 0 0 6 8c0 7-3 9-3 9h18s-3-2-3-9" class="svelte-d3ct2b"></path><path d="M13.73 21a2 2 0 0 1-3.46 0" class="svelte-d3ct2b"></path></svg></button> <button><svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.8" class="svelte-d3ct2b"><rect x="2" y="3" width="20" height="14" rx="2" class="svelte-d3ct2b"></rect><path d="m7 21 5-5 5 5" class="svelte-d3ct2b"></path><path d="m7 8 3 3-3 3" class="svelte-d3ct2b"></path><path d="M13 14h4" class="svelte-d3ct2b"></path></svg></button> <button class="icon-btn svelte-d3ct2b" title="Settings"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.8" class="svelte-d3ct2b"><circle cx="12" cy="12" r="3" class="svelte-d3ct2b"></circle><path d="M19.07 4.93a10 10 0 0 1 0 14.14M4.93 4.93a10 10 0 0 0 0 14.14" class="svelte-d3ct2b"></path><path d="M12 2v2M12 20v2M2 12h2M20 12h2" class="svelte-d3ct2b"></path></svg></button> <button class="icon-btn svelte-d3ct2b"><!></button> <div class="avatar svelte-d3ct2b" title="System Administrator">S</div></div></header> <div class="body svelte-d3ct2b"><aside class="sidebar svelte-d3ct2b"><div class="sidebar-logo svelte-d3ct2b"><svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" class="svelte-d3ct2b"><circle cx="12" cy="12" r="3" class="svelte-d3ct2b"></circle><path d="M12 1v4M12 19v4M4.22 4.22l2.83 2.83M16.95 16.95l2.83 2.83M1 12h4M19 12h4M4.22 19.78l2.83-2.83M16.95 7.05l2.83-2.83" class="svelte-d3ct2b"></path></svg></div> <nav class="sidebar-nav svelte-d3ct2b"><button class="side-btn side-btn-active svelte-d3ct2b" title="Live Feed"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.8" class="svelte-d3ct2b"><rect x="2" y="3" width="20" height="14" rx="2" class="svelte-d3ct2b"></rect><path d="m7 21 5-5 5 5" class="svelte-d3ct2b"></path><path d="m7 8 3 3-3 3" class="svelte-d3ct2b"></path><path d="M13 14h4" class="svelte-d3ct2b"></path></svg></button></nav> <div></div></aside> <main class="content svelte-d3ct2b"><div class="health-bar svelte-d3ct2b"><span class="health-label svelte-d3ct2b">System Health:</span> <div class="health-badge health-green svelte-d3ct2b"><i class="dot dot-green svelte-d3ct2b"></i> <span class="svelte-d3ct2b"> </span></div> <div><i></i> <span class="svelte-d3ct2b"> </span></div> <div class="health-badge health-blue svelte-d3ct2b"><i class="dot dot-blue svelte-d3ct2b"></i> <span class="svelte-d3ct2b"> </span></div> <!> <!></div> <div class="filter-bar svelte-d3ct2b"><div class="filter-left svelte-d3ct2b"><div class="chip chip-primary svelte-d3ct2b"><span class="svelte-d3ct2b">LEVEL: ALL</span> <button class="chip-close svelte-d3ct2b" title="Clear cache">✕</button></div> <div class="service-dropdown-wrap svelte-d3ct2b"><button class="chip chip-outline svelte-d3ct2b"><span class="svelte-d3ct2b"> </span> <svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5"><polyline points="6 9 12 15 18 9" class="svelte-d3ct2b"></polyline></svg></button> <!></div> <div class="divider-v svelte-d3ct2b"></div> <div class="metrics-strip svelte-d3ct2b"><div class="metric-item svelte-d3ct2b"><span class="metric-label svelte-d3ct2b">VIOLATIONS</span> <span> </span></div> <div class="metric-item svelte-d3ct2b"><span class="metric-label svelte-d3ct2b">FILES</span> <span class="metric-value svelte-d3ct2b"> </span></div> <div class="metric-item svelte-d3ct2b"><span class="metric-label svelte-d3ct2b">RULES</span> <span class="metric-value svelte-d3ct2b"> </span></div></div></div> <div class="filter-right svelte-d3ct2b"><div class="live-badge svelte-d3ct2b"><i></i> <span class="svelte-d3ct2b"> </span></div> <button><!></button> <button class="icon-btn svelte-d3ct2b" title="Download snapshot"><svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" class="svelte-d3ct2b"><path d="M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4" class="svelte-d3ct2b"></path><polyline points="7 10 12 15 17 10" class="svelte-d3ct2b"></polyline><line x1="12" y1="15" x2="12" y2="3" class="svelte-d3ct2b"></line></svg></button></div></div> <div class="feed-area svelte-d3ct2b"><!></div> <footer class="metrics-footer svelte-d3ct2b"><div class="footer-left svelte-d3ct2b"><div class="footer-metric svelte-d3ct2b"><span class="footer-label svelte-d3ct2b">Throughput</span> <span class="footer-val svelte-d3ct2b"> </span> <span class="footer-unit svelte-d3ct2b">EVENTS/SESSION</span></div> <div class="footer-metric svelte-d3ct2b"><span class="footer-label svelte-d3ct2b">Error Rate</span> <span class="footer-val footer-val-error svelte-d3ct2b"> </span> <svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="#ba1a1a" stroke-width="2" class="svelte-d3ct2b"><polyline points="23 6 13.5 15.5 8.5 10.5 1 18" class="svelte-d3ct2b"></polyline><polyline points="17 6 23 6 23 12" class="svelte-d3ct2b"></polyline></svg></div> <div class="footer-metric svelte-d3ct2b"><span class="footer-label svelte-d3ct2b">Latency (P99)</span> <span class="footer-val svelte-d3ct2b">—</span></div></div> <div class="footer-right svelte-d3ct2b"><div class="storage-bar-wrap svelte-d3ct2b"><div class="storage-bar svelte-d3ct2b"><div class="storage-fill svelte-d3ct2b"></div></div> <span class="footer-label svelte-d3ct2b"> </span></div> <button class="cli-btn svelte-d3ct2b"><svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" class="svelte-d3ct2b"><rect x="2" y="3" width="20" height="14" rx="2" class="svelte-d3ct2b"></rect><path d="m7 8 3 3-3 3" class="svelte-d3ct2b"></path><path d="M13 14h4" class="svelte-d3ct2b"></path></svg> CLI CONSOLE</button></div></footer></main></div></div>');function Nc(e,t){Al(t,!1);const s=j(),n=j(),r=j(),a=j(),c=j(),u=j(),f=j(),v=j(),p=j(),E=j(),b=j(),m=j(),g=j(),C=j();let d=j({config:null,stats:{rules:{},files:{},topRules:[],topFiles:[]},files:[],memories:[]}),M=j([]),H=j(!1),P=j("all"),te=j(""),de=j(!1),fe=j(""),J,Ve=!1,W=j({type:"rule",scope:"project",content:"",reason:"",tags:"dashboard"}),q=j("live-feed"),Te=j("live-feed"),Ae=j(!1),pt=j("core-engine"),rt=j(!1),gs=j("");const zs=24*60*60*1e3;function Xt(i){l(rt)||k(M,[{...i,id:crypto.randomUUID()},...l(M)].slice(0,80))}function ms(i){return i.type==="saved"?{type:"saved",timestamp:i.timestamp,file:i.file}:i.type==="clean"?{type:"clean",timestamp:i.timestamp,file:i.file}:i.type==="skipped"?{type:"skipped",timestamp:i.timestamp,file:i.file,reason:i.reason}:i.type==="violations"?{type:"violations",timestamp:i.timestamp,file:i.file,violations:i.violations}:i.type==="error"?{type:"error",timestamp:i.timestamp,message:i.message}:i.type==="ready"?{type:"system",timestamp:i.timestamp,message:`Watching ${i.path} | ${i.rules} rules | ${i.model}`}:{type:"system",timestamp:i.timestamp,message:"Watch stopped"}}function be(i){const w=l(d).files??[],R=w.findIndex(le=>le.file===i.file),V=w.slice();return R===-1?V.push(i):V[R]=i,V.sort((le,se)=>se.lastSeen.localeCompare(le.lastSeen))}function Ks(i){const w=l(d).watcher??{enabled:!0,running:!1,path:void 0,model:void 0,rules:void 0,lastEventAt:void 0,error:void 0};let R=l(d).files,V={...w,lastEventAt:i.timestamp,enabled:!0};i.type==="ready"&&(V={...V,running:!0,error:void 0,path:i.path,model:i.model,rules:i.rules}),i.type==="saved"&&(R=be({file:i.file,status:"checking",lastSeen:i.timestamp,violations:[]})),i.type==="clean"&&(R=be({file:i.file,status:"clean",lastSeen:i.timestamp,violations:[]})),i.type==="skipped"&&(R=be({file:i.file,status:"skipped",lastSeen:i.timestamp,violations:[],message:i.reason})),i.type==="violations"&&(R=be({file:i.file,status:"violations",lastSeen:i.timestamp,violations:i.violations})),i.type==="error"&&(V={...V,running:!1,error:i.message}),i.type==="stopped"&&(V={...V,running:!1});const le=[i,...l(d).events??[]].slice(0,100);k(d,{...l(d),files:R,events:le,watcher:V})}function xn(i=[]){k(M,i.map(ms).map(w=>({...w,id:crypto.randomUUID()})).reverse().slice(0,80))}function pr(i){return new Intl.DateTimeFormat(void 0,{hour:"2-digit",minute:"2-digit",second:"2-digit"}).format(new Date(i))}function hr(i,w){const R=i.file||w;return i.line?`${R}:${i.line}`:R}function fa(i){return i.type==="saved"?"SAVE":i.type==="clean"?"OK":i.type==="skipped"?"SKIP":i.type==="violations"?"FAIL":i.type==="error"?"WARN":"SYS"}function ua(i){return i.type==="clean"?"label-ok":i.type==="violations"||i.type==="error"?"label-warn":i.type==="system"?"label-sys":"label-info"}async function Ys(){const i=await fetch(`/api/snapshot?t=${Date.now()}`,{cache:"no-store"});k(d,await i.json()),xn(l(d).events)}async function va(){k(fe,"");try{const i=await fetch("/api/refresh",{method:"POST",headers:{"content-type":"application/json"},cache:"no-store"});if(!i.ok)throw new Error((await i.json()).error??"Refresh failed");const w=await i.json();w.snapshot?(k(d,w.snapshot),xn(l(d).events)):await Ys()}catch(i){k(fe,i.message)}}function da(){try{localStorage.clear(),sessionStorage.clear()}finally{location.reload()}}async function pa(){if(!Ve&&document.visibilityState!=="hidden"){Ve=!0;try{const i=await fetch("/api/stats",{cache:"no-store"});if(!i.ok)return;const w=await i.json();if(!w.stats)return;k(d,{...l(d),stats:w.stats})}catch{}finally{Ve=!1}}}function ha(){J&&clearInterval(J),J=setInterval(()=>{pa()},2e3)}function _r(){const i=location.protocol==="https:"?"wss:":"ws:",w=new WebSocket(`${i}//${location.host}/ws`);w.addEventListener("open",()=>{k(H,!0),Xt({type:"system",timestamp:new Date().toISOString(),message:"Dashboard connected"})}),w.addEventListener("close",()=>{k(H,!1),Xt({type:"error",timestamp:new Date().toISOString(),message:"Dashboard disconnected"}),setTimeout(_r,1500)}),w.addEventListener("message",R=>{const V=JSON.parse(R.data);if(V.type==="snapshot"){k(d,V.snapshot),l(M).length===0&&xn(l(d).events);return}V.type==="watch"&&(Ks(V.event),Xt(ms(V.event)))})}async function _a(){if(l(W).content.trim()){k(de,!0),k(fe,"");try{const i=await fetch("/api/memories",{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify(l(W))});if(!i.ok)throw new Error((await i.json()).error??"Save failed");k(W,{type:"rule",scope:"project",content:"",reason:"",tags:"dashboard"}),await Ys()}catch(i){k(fe,i.message)}finally{k(de,!1)}}}async function ba(i){k(fe,"");const w=await fetch(`/api/memories/${i}`,{method:"DELETE"});if(!w.ok){k(fe,(await w.json()).error??"Delete failed");return}await Ys()}function br(i){k(pt,i),k(Ae,!1),i==="commit-hook"?k(q,"commit-hook"):k(q,"live-feed")}function ga(){k(q,l(q)==="commit-hook"?"live-feed":"commit-hook"),k(pt,l(q)==="commit-hook"?"commit-hook":"core-engine")}function ma(i){l(Ae)&&(i.target.closest(".service-dropdown-wrap")||k(Ae,!1))}let Zt=j(localStorage.getItem("mc-theme")==="dark"||!localStorage.getItem("mc-theme")&&window.matchMedia("(prefers-color-scheme: dark)").matches);function wa(){k(Zt,!l(Zt)),localStorage.setItem("mc-theme",l(Zt)?"dark":"light")}Ys().catch(i=>{k(fe,i.message)}),_r(),ha(),lc(()=>{J&&(clearInterval(J),J=void 0)}),ge(()=>(l(d),l(P),l(te)),()=>{k(s,l(d).memories.filter(i=>{const w=l(P)==="all"||i.type===l(P),R=`${i.type} ${i.scope} ${i.content} ${i.reason??""} ${i.tags.join(" ")}`.toLowerCase();return w&&R.includes(l(te).toLowerCase())}))}),ge(()=>l(d),()=>{k(n,Object.values(l(d).stats.files??{}).reduce((i,w)=>i+w,0))}),ge(()=>l(d),()=>{k(r,l(d).files.filter(i=>i.status==="clean").length)}),ge(()=>l(d),()=>{k(a,Object.values(l(d).stats.rules).reduce((i,w)=>i+w,0))}),ge(()=>l(d),()=>{k(c,l(d).stats.recentViolations??[])}),ge(()=>l(c),()=>{k(u,l(c).filter(i=>{if(!(i.source==="hook"||i.source==="ci"))return!1;const w=Date.parse(i.timestamp);return Number.isNaN(w)?!1:Date.now()-w<=zs}))}),ge(()=>l(n),()=>{k(f,l(n))}),ge(()=>l(d),()=>{k(v,Object.keys(l(d).stats.files??{}).length)}),ge(()=>l(d),()=>{k(p,l(d).memories.filter(i=>["rule","pattern","decision"].includes(i.type)).length)}),ge(()=>l(d),()=>{var i;k(E,((i=l(d).memoryCount)==null?void 0:i.total)??l(d).memories.length)}),ge(()=>(l(H),l(d)),()=>{var i,w;k(b,l(H)?((i=l(d).watcher)==null?void 0:i.enabled)===!1?{live:!1,label:"Watch off"}:(w=l(d).watcher)!=null&&w.running?{live:!0,label:"Watcher live"}:{live:!1,label:"Watcher idle"}:{live:!1,label:"Disconnected"})}),ge(()=>l(d),()=>{var i;k(m,((i=l(d).runtime)==null?void 0:i.postgres.connected)??!1)}),ge(()=>l(d),()=>{var i;k(g,((i=l(d).runtime)==null?void 0:i.model.ollamaReachable)??!1)}),ge(()=>l(d),()=>{var i,w;k(C,(((i=l(d).runtime)==null?void 0:i.model.checkModelResolved)??((w=l(d).runtime)==null?void 0:w.model.chatModel)??"unknown").toUpperCase())}),So(),nc();var Sn=Oc();ie("click",Gn,ma);let gr;var mr=h(Sn),wr=h(mr),ya=_(h(wr),2),Mn=h(ya);let yr;var Cn=_(Mn,2);let Er;var kr=_(Cn,2);let xr;var Sr=_(wr,2),Ea=_(h(Sr),2),ka=_(Sr,2),Gs=_(h(ka),2);let Mr;var Cr=_(Gs,2),Tn=_(Cr,2),xa=h(Tn);{var Sa=i=>{var w=oc();D(i,w)},Ma=i=>{var w=cc();D(i,w)};Z(xa,i=>{l(Zt)?i(Sa):i(Ma,-1)})}var Ca=_(mr,2),Tr=h(Ca),Ar=_(h(Tr),4);let Or;var Ta=_(Tr,2),Nr=h(Ta),Ir=_(h(Nr),2),Aa=_(h(Ir),2),Oa=h(Aa),An=_(Ir,2);let Dr;var Lr=h(An);let Rr;var Na=_(Lr,2),Ia=h(Na),Fr=_(An,2),Da=_(h(Fr),2),La=h(Da),Pr=_(Fr,2);{var Ra=i=>{var w=fc(),R=h(w);K(()=>O(R,(l(d),y(()=>l(d).dbError)))),D(i,w)};Z(Pr,i=>{l(d),y(()=>l(d).dbError)&&i(Ra)})}var Fa=_(Pr,2);{var Pa=i=>{var w=uc(),R=h(w);K(()=>O(R,l(fe))),D(i,w)};Z(Fa,i=>{l(fe)&&i(Pa)})}var jr=_(Nr,2),$r=h(jr),Br=h($r),ja=_(h(Br),2),Vr=_(Br,2),On=h(Vr),Hr=h(On),$a=h(Hr),Ba=_(Hr,2);let Wr;var Va=_(On,2);{var Ha=i=>{var w=dc(),R=h(w);let V;var le=_(R,2);let se;var Oe=_(h(le),2);{var lt=ne=>{var x=vc(),Je=h(x);K(()=>O(Je,(l(u),y(()=>l(u).length)))),D(ne,x)};Z(Oe,ne=>{l(u),y(()=>l(u).length>0)&&ne(lt)})}K(()=>{V=ue(R,1,"dropdown-item svelte-d3ct2b",null,V,{"dropdown-item-active":l(pt)==="core-engine"}),se=ue(le,1,"dropdown-item svelte-d3ct2b",null,se,{"dropdown-item-active":l(pt)==="commit-hook"})}),ie("click",R,()=>br("core-engine")),ie("click",le,()=>br("commit-hook")),D(i,w)};Z(Va,i=>{l(Ae)&&i(Ha)})}var Wa=_(Vr,4),qr=h(Wa),Ur=_(h(qr),2);let zr;var qa=h(Ur),Kr=_(qr,2),Ua=_(h(Kr),2),za=h(Ua),Ka=_(Kr,2),Ya=_(h(Ka),2),Ga=h(Ya),Ja=_($r,2),Yr=h(Ja),Gr=h(Yr);let Jr;var Qa=_(Gr,2),Xa=h(Qa),ws=_(Yr,2);let Qr;var Za=h(ws);{var ei=i=>{var w=pc();D(i,w)},ti=i=>{var w=hc();D(i,w)};Z(Za,i=>{l(rt)?i(ei):i(ti,-1)})}var si=_(ws,2),Xr=_(jr,2),ni=h(Xr);{var ri=i=>{var w=nn(),R=qe(w);{var V=se=>{var Oe=_c();D(se,Oe)},le=se=>{var Oe=nn(),lt=qe(Oe);ln(lt,1,()=>(l(M),y(()=>[...l(M)].reverse())),ne=>ne.id,(ne,x)=>{var Je=wc(),Qe=qe(Je);let $;var ht=h(Qe),Tt=h(ht),at=_(ht,2),At=h(at),it=_(at,2),Ot=h(it);{var Nt=F=>{var B=mt();K(()=>O(B,(l(x),y(()=>l(x).message)))),D(F,B)},It=F=>{var B=mt();K(()=>O(B,`saved: ${l(x),y(()=>l(x).file)??""}`)),D(F,B)},Dt=F=>{var B=mt();K(()=>O(B,`${l(x),y(()=>l(x).file)??""} — no violations`)),D(F,B)},Lt=F=>{var B=mt();K(()=>O(B,`${l(x),y(()=>l(x).file)??""} — skipped: ${l(x),y(()=>l(x).reason)??""}`)),D(F,B)},es=F=>{var B=mt();K(()=>O(B,`${l(x),y(()=>l(x).violations.length)??""} violation${l(x),y(()=>l(x).violations.length===1?"":"s")??""} in ${l(x),y(()=>l(x).file)??""}`)),D(F,B)};Z(Ot,F=>{l(x),y(()=>l(x).type==="system"||l(x).type==="error")?F(Nt):(l(x),y(()=>l(x).type==="saved")?F(It,1):(l(x),y(()=>l(x).type==="clean")?F(Dt,2):(l(x),y(()=>l(x).type==="skipped")?F(Lt,3):F(es,-1))))})}var ts=_(it,2),ys=_(Qe,2);{var Ee=F=>{var B=nn(),_t=qe(B);ln(_t,3,()=>(l(x),y(()=>l(x).violations)),(ss,T)=>`${l(x).id}-${T}`,(ss,T,ae)=>{var ke=mc(),He=h(ke),Es=h(He),ns=_(He,2),Js=h(ns),Qs=h(Js),Xs=_(Js,2);{var Zs=pe=>{var bt=bc(),In=_(qe(bt)),Dn=h(In);K(()=>O(Dn,(l(T),y(()=>l(T).rule)))),D(pe,bt)};Z(Xs,pe=>{l(T),y(()=>l(T).rule)&&pe(Zs)})}var en=_(Xs,2);{var Nn=pe=>{var bt=mt();K(()=>O(bt,`— ${l(T),y(()=>l(T).issue)??""}`)),D(pe,bt)};Z(en,pe=>{l(T),y(()=>l(T).issue)&&pe(Nn)})}var ks=_(en,2);{var tn=pe=>{var bt=gc(),In=_(qe(bt)),Dn=h(In);K(()=>O(Dn,`→ ${l(T),y(()=>l(T).suggestion)??""}`)),D(pe,bt)};Z(ks,pe=>{l(T),y(()=>l(T).suggestion)&&pe(tn)})}K(pe=>{O(Es,`[${l(ae)+1}]`),O(Qs,pe)},[()=>(l(T),l(x),y(()=>hr(l(T),l(x).file)))]),D(ss,ke)}),D(F,B)};Z(ys,F=>{l(x),y(()=>l(x).type==="violations")&&F(Ee)})}K((F,B,_t)=>{$=ue(Qe,1,"log-row svelte-d3ct2b",null,$,{"log-row-warn":l(x).type==="error","log-row-ok":l(x).type==="clean","log-row-fail":l(x).type==="violations"}),O(Tt,F),ue(at,1,`log-label ${B??""}`,"svelte-d3ct2b"),O(At,`[${_t??""}]`)},[()=>(l(x),y(()=>pr(l(x).timestamp))),()=>(l(x),y(()=>ua(l(x)))),()=>(l(x),y(()=>fa(l(x))))]),ie("click",ts,()=>{var B;const F=l(x).type==="system"||l(x).type==="error"?l(x).message:l(x).type==="saved"?`saved: ${l(x).file}`:l(x).file;(B=navigator.clipboard)==null||B.writeText(F)}),D(ne,Je)}),D(se,Oe)};Z(R,se=>{l(M),y(()=>l(M).length===0)?se(V):se(le,-1)})}D(i,w)},li=i=>{var w=Sc(),R=qe(w),V=_(h(R),2),le=h(V),se=_(R,2);{var Oe=ne=>{var x=yc();D(ne,x)},lt=ne=>{var x=nn(),Je=qe(x);ln(Je,3,()=>(l(u),y(()=>l(u).slice(0,20))),(Qe,$)=>`${Qe.timestamp}-${$}`,(Qe,$)=>{var ht=xc(),Tt=qe(ht),at=h(Tt),At=h(at),it=_(at,2),Ot=h(it),Nt=_(it,2),It=h(Nt),Dt=h(It),Lt=_(It,2);{var es=Ee=>{var F=mt();K(B=>O(F,`— ${B??""}`),[()=>(l($),y(()=>hr(l($),l($).file)))]),D(Ee,F)};Z(Lt,Ee=>{l($),y(()=>l($).file)&&Ee(es)})}var ts=_(Tt,2);{var ys=Ee=>{var F=kc(),B=_(h(F),2),_t=h(B);{var ss=ke=>{var He=mt();K(()=>O(He,(l($),y(()=>l($).issue)))),D(ke,He)};Z(_t,ke=>{l($),y(()=>l($).issue)&&ke(ss)})}var T=_(_t,2);{var ae=ke=>{var He=Ec(),Es=_(qe(He)),ns=h(Es);K(()=>O(ns,`→ ${l($),y(()=>l($).suggestion)??""}`)),D(ke,He)};Z(T,ke=>{l($),y(()=>l($).suggestion)&&ke(ae)})}D(Ee,F)};Z(ts,Ee=>{l($),y(()=>l($).issue||l($).suggestion)&&Ee(ys)})}K(Ee=>{O(At,Ee),O(Ot,`[${l($),y(()=>l($).source==="ci"?"CI":"HOOK")??""}]`),O(Dt,(l($),y(()=>l($).rule)))},[()=>(l($),y(()=>pr(l($).timestamp)))]),D(Qe,ht)}),D(ne,x)};Z(se,ne=>{l(u),y(()=>l(u).length===0)?ne(Oe):ne(lt,-1)})}K(()=>O(le,`${l(u),y(()=>l(u).length)??""} violation${l(u),y(()=>l(u).length===1?"":"s")??""} in last 24h`)),D(i,w)},ai=i=>{var w=Ac(),R=qe(w),V=_(h(R),2),le=h(V),se=_(R,2),Oe=h(se),lt=h(Oe);lt.value=lt.__value="all";var ne=_(lt);ne.value=ne.__value="rule";var x=_(ne);x.value=x.__value="decision";var Je=_(x);Je.value=Je.__value="pattern";var Qe=_(Je);Qe.value=Qe.__value="ignore";var $=_(Oe,2),ht=_(se,2),Tt=h(ht),at=h(Tt),At=h(at),it=h(At);it.value=it.__value="rule";var Ot=_(it);Ot.value=Ot.__value="decision";var Nt=_(Ot);Nt.value=Nt.__value="pattern";var It=_(Nt);It.value=It.__value="ignore";var Dt=_(At,2),Lt=h(Dt);Lt.value=Lt.__value="project";var es=_(Lt);es.value=es.__value="global";var ts=_(Dt,2),ys=_(ts,2),Ee=_(at,2),F=h(Ee),B=_(F,2),_t=h(B),ss=_(ht,2);ln(ss,5,()=>l(s),T=>T.id,(T,ae)=>{var ke=Cc(),He=h(ke),Es=h(He),ns=_(He,2),Js=h(ns),Qs=_(ns,2),Xs=h(Qs),Zs=_(Qs,2);{var en=ks=>{var tn=Mc(),pe=h(tn);K(()=>O(pe,(l(ae),y(()=>l(ae).reason)))),D(ks,tn)};Z(Zs,ks=>{l(ae),y(()=>l(ae).reason)&&ks(en)})}var Nn=_(Zs,2);K(()=>{O(Es,(l(ae),y(()=>l(ae).type))),O(Js,(l(ae),y(()=>l(ae).scope))),O(Xs,(l(ae),y(()=>l(ae).content)))}),ie("click",Nn,()=>ba(l(ae).id)),D(T,ke)},T=>{var ae=Tc();D(T,ae)}),K(T=>{O(le,`${l(p)??""} rules active`),B.disabled=T,O(_t,l(de)?"Saving…":"+ Add Rule")},[()=>(l(de),l(W),y(()=>l(de)||!l(W).content.trim()))]),Pn(Oe,()=>l(P),T=>k(P,T)),Ms($,()=>l(te),T=>k(te,T)),Pn(At,()=>l(W).type,T=>xs(W,l(W).type=T)),Pn(Dt,()=>l(W).scope,T=>xs(W,l(W).scope=T)),Ms(ts,()=>l(W).reason,T=>xs(W,l(W).reason=T)),Ms(ys,()=>l(W).tags,T=>xs(W,l(W).tags=T)),Ms(F,()=>l(W).content,T=>xs(W,l(W).content=T)),ie("submit",Tt,sc(_a)),D(i,w)};Z(ni,i=>{l(q)==="live-feed"?i(ri):l(q)==="commit-hook"?i(li,1):l(q)==="rules"&&i(ai,2)})}var ii=_(Xr,2),Zr=h(ii),el=h(Zr),oi=_(h(el),2),ci=h(oi),fi=_(el,2),ui=_(h(fi),2),vi=h(ui),di=_(Zr,2),tl=h(di),sl=h(tl),pi=h(sl),hi=_(sl,2),_i=h(hi),bi=_(tl,2);K((i,w,R,V,le,se)=>{gr=ue(Sn,1,"shell svelte-d3ct2b",null,gr,{dark:l(Zt)}),yr=ue(Mn,1,"tab-btn svelte-d3ct2b",null,yr,{"tab-active":l(Te)==="dashboard"}),Er=ue(Cn,1,"tab-btn svelte-d3ct2b",null,Er,{"tab-active":l(Te)==="live-feed"}),xr=ue(kr,1,"tab-btn svelte-d3ct2b",null,xr,{"tab-active":l(Te)==="metrics"}),Mr=ue(Gs,1,"icon-btn svelte-d3ct2b",null,Mr,{"icon-btn-active":l(q)==="commit-hook"}),an(Gs,"title",l(q)==="commit-hook"?"Switch to Live Feed":"Switch to Commit Hook"),an(Tn,"title",l(Zt)?"Switch to light mode":"Switch to dark mode"),Or=ue(Ar,1,"sidebar-footer-dot svelte-d3ct2b",null,Or,{"dot-live":l(b).live}),an(Ar,"title",(l(b),y(()=>l(b).label))),O(Oa,`CORE ${l(b),y(()=>l(b).live?"LIVE":"IDLE")??""}`),Dr=ue(An,1,"health-badge svelte-d3ct2b",null,Dr,{"health-green":l(m),"health-warn":!l(m)}),Rr=ue(Lr,1,"dot svelte-d3ct2b",null,Rr,{"dot-green":l(m),"dot-warn":!l(m)}),O(Ia,`DB ${l(m)?"CONNECTED":"DISCONNECTED"}`),O(La,`OLLAMA READY: ${l(C)??""}`),O($a,`SERVICE: ${l(pt)==="commit-hook"?"COMMIT HOOK":"CORE-ENGINE"}`),Wr=ue(Ba,0,"chevron svelte-d3ct2b",null,Wr,{"chevron-open":l(Ae)}),zr=ue(Ur,1,"metric-value svelte-d3ct2b",null,zr,{"metric-value-warn":l(f)>0}),O(qa,l(f)),O(za,i),O(Ga,w),Jr=ue(Gr,1,"dot dot-green svelte-d3ct2b",null,Jr,{"dot-pulse":l(b).live}),O(Xa,R),Qr=ue(ws,1,"icon-btn svelte-d3ct2b",null,Qr,{"icon-btn-active":l(rt)}),an(ws,"title",l(rt)?"Resume":"Pause"),O(ci,`${V??""}K`),O(vi,le),Go(pi,`width: ${se??""}%`),O(_i,`Storage: ${l(E)??""} memories`)},[()=>(l(v),y(()=>l(v).toLocaleString())),()=>(l(p),y(()=>l(p).toLocaleString())),()=>(l(b),y(()=>l(b).live?"LIVE STREAMING":l(b).label.toUpperCase())),()=>(l(a),l(M),y(()=>(l(a)/Math.max(1,l(M).length)*100).toFixed(1))),()=>(l(f),l(v),y(()=>l(f)===0?"0.00%":(l(f)/Math.max(1,l(v))*100).toFixed(2)+"%")),()=>(l(E),y(()=>Math.min(100,l(E)/Math.max(1,l(E)+100)*100+20)))]),ie("click",Mn,()=>{k(Te,"dashboard"),k(q,"live-feed")}),ie("click",Cn,()=>{k(Te,"live-feed"),k(q,"live-feed")}),ie("click",kr,()=>{k(Te,"metrics"),k(q,"rules")}),Ms(Ea,()=>l(gs),i=>k(gs,i)),ie("click",Gs,ga),ie("click",Cr,va),ie("click",Tn,wa),ie("click",ja,da),ie("click",On,tc(()=>k(Ae,!l(Ae)))),ie("click",ws,()=>k(rt,!l(rt))),ie("click",si,()=>{const i=new Blob([JSON.stringify(l(d),null,2)],{type:"application/json"}),w=document.createElement("a");w.href=URL.createObjectURL(i),w.download="memory-core-snapshot.json",w.click()}),ie("click",bi,()=>{k(q,"live-feed"),k(Te,"live-feed")}),D(e,Sn),Ol()}Bo(Nc,{target:document.getElementById("app")});
|